	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function hmc5843_init
_hmc5843_init:                          ## @hmc5843_init
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r15
	pushq	%r14
	pushq	%r12
	pushq	%rbx
	subq	$16, %rsp
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r14
	movl	4(%rdi), %r15d
	movq	_HMC5843_ID_REG@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	leaq	-35(%rbp), %r12
	movq	%r12, %rdi
	callq	_ARRAY_SIZE
	movl	%r15d, %edi
	movl	%ebx, %esi
	movq	%r12, %rdx
	movl	%eax, %ecx
	callq	_regmap_bulk_read
	testl	%eax, %eax
	js	LBB0_9
## %bb.1:
	cmpb	$72, -35(%rbp)
	jne	LBB0_4
## %bb.2:
	cmpb	$52, -34(%rbp)
	jne	LBB0_4
## %bb.3:
	cmpb	$51, -33(%rbp)
	jne	LBB0_4
## %bb.5:
	movq	_HMC5843_MEAS_CONF_NORMAL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r14, %rdi
	callq	_hmc5843_set_meas_conf
	testl	%eax, %eax
	js	LBB0_9
## %bb.6:
	movq	_HMC5843_RATE_DEFAULT@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r14, %rdi
	callq	_hmc5843_set_samp_freq
	testl	%eax, %eax
	js	LBB0_9
## %bb.7:
	movq	_HMC5843_RANGE_GAIN_DEFAULT@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r14, %rdi
	callq	_hmc5843_set_range_gain
	testl	%eax, %eax
	js	LBB0_9
## %bb.8:
	movq	_HMC5843_MODE_CONVERSION_CONTINUOUS@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r14, %rdi
	callq	_hmc5843_set_mode
	jmp	LBB0_9
LBB0_4:
	movl	(%r14), %edi
	leaq	L_.str(%rip), %rsi
	callq	_dev_err
	movq	_ENODEV@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
LBB0_9:
	addq	$16, %rsp
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_HMC5843_ID_REG,4,2             ## @HMC5843_ID_REG
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"no HMC5843/5883/5883L/5983 sensor\n"

	.comm	_ENODEV,4,2                     ## @ENODEV
	.comm	_HMC5843_MEAS_CONF_NORMAL,4,2   ## @HMC5843_MEAS_CONF_NORMAL
	.comm	_HMC5843_RATE_DEFAULT,4,2       ## @HMC5843_RATE_DEFAULT
	.comm	_HMC5843_RANGE_GAIN_DEFAULT,4,2 ## @HMC5843_RANGE_GAIN_DEFAULT
	.comm	_HMC5843_MODE_CONVERSION_CONTINUOUS,4,2 ## @HMC5843_MODE_CONVERSION_CONTINUOUS
	.no_dead_strip	_hmc5843_init
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function hmc5843_init
_hmc5843_init:                          ; @hmc5843_init
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	.cfi_offset w21, -40
	.cfi_offset w22, -48
	mov	x19, x0
	ldr	w20, [x0, #4]
Lloh0:
	adrp	x8, _HMC5843_ID_REG@GOTPAGE
Lloh1:
	ldr	x8, [x8, _HMC5843_ID_REG@GOTPAGEOFF]
Lloh2:
	ldr	w21, [x8]
	add	x0, sp, #13
	bl	_ARRAY_SIZE
	mov	x3, x0
	add	x2, sp, #13
	mov	x0, x20
	mov	x1, x21
	bl	_regmap_bulk_read
	tbnz	w0, #31, LBB0_9
; %bb.1:
	ldrb	w8, [sp, #13]
	cmp	w8, #72
	b.ne	LBB0_8
; %bb.2:
	ldrb	w8, [sp, #14]
	cmp	w8, #52
	b.ne	LBB0_8
; %bb.3:
	ldrb	w8, [sp, #15]
	cmp	w8, #51
	b.ne	LBB0_8
; %bb.4:
Lloh3:
	adrp	x8, _HMC5843_MEAS_CONF_NORMAL@GOTPAGE
Lloh4:
	ldr	x8, [x8, _HMC5843_MEAS_CONF_NORMAL@GOTPAGEOFF]
Lloh5:
	ldr	w1, [x8]
	mov	x0, x19
	bl	_hmc5843_set_meas_conf
	tbnz	w0, #31, LBB0_9
; %bb.5:
Lloh6:
	adrp	x8, _HMC5843_RATE_DEFAULT@GOTPAGE
Lloh7:
	ldr	x8, [x8, _HMC5843_RATE_DEFAULT@GOTPAGEOFF]
Lloh8:
	ldr	w1, [x8]
	mov	x0, x19
	bl	_hmc5843_set_samp_freq
	tbnz	w0, #31, LBB0_9
; %bb.6:
Lloh9:
	adrp	x8, _HMC5843_RANGE_GAIN_DEFAULT@GOTPAGE
Lloh10:
	ldr	x8, [x8, _HMC5843_RANGE_GAIN_DEFAULT@GOTPAGEOFF]
Lloh11:
	ldr	w1, [x8]
	mov	x0, x19
	bl	_hmc5843_set_range_gain
	tbnz	w0, #31, LBB0_9
; %bb.7:
Lloh12:
	adrp	x8, _HMC5843_MODE_CONVERSION_CONTINUOUS@GOTPAGE
Lloh13:
	ldr	x8, [x8, _HMC5843_MODE_CONVERSION_CONTINUOUS@GOTPAGEOFF]
Lloh14:
	ldr	w1, [x8]
	mov	x0, x19
	bl	_hmc5843_set_mode
	b	LBB0_9
LBB0_8:
	ldr	w0, [x19]
Lloh15:
	adrp	x1, l_.str@PAGE
Lloh16:
	add	x1, x1, l_.str@PAGEOFF
	bl	_dev_err
Lloh17:
	adrp	x8, _ENODEV@GOTPAGE
Lloh18:
	ldr	x8, [x8, _ENODEV@GOTPAGEOFF]
Lloh19:
	ldr	w8, [x8]
	neg	w0, w8
LBB0_9:
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #64
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpAdd	Lloh15, Lloh16
	.cfi_endproc
                                        ; -- End function
	.comm	_HMC5843_ID_REG,4,2             ; @HMC5843_ID_REG
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"no HMC5843/5883/5883L/5983 sensor\n"

	.comm	_ENODEV,4,2                     ; @ENODEV
	.comm	_HMC5843_MEAS_CONF_NORMAL,4,2   ; @HMC5843_MEAS_CONF_NORMAL
	.comm	_HMC5843_RATE_DEFAULT,4,2       ; @HMC5843_RATE_DEFAULT
	.comm	_HMC5843_RANGE_GAIN_DEFAULT,4,2 ; @HMC5843_RANGE_GAIN_DEFAULT
	.comm	_HMC5843_MODE_CONVERSION_CONTINUOUS,4,2 ; @HMC5843_MODE_CONVERSION_CONTINUOUS
	.no_dead_strip	_hmc5843_init
.subsections_via_symbols
