	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ak8975_setup
_ak8975_setup:                          ## @ak8975_setup
	.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	%rbx
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r14
	callq	_i2c_get_clientdata
	movq	%rax, %rdi
	callq	_iio_priv
	movq	%rax, %r15
	movq	_FUSE_ROM@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r15, %rdi
	callq	_ak8975_set_mode
	testl	%eax, %eax
	js	LBB0_1
## %bb.3:
	movq	8(%r15), %rcx
	movq	16(%r15), %rax
	movq	8(%rax), %rax
	movq	_ASA_BASE@GOTPCREL(%rip), %rdx
	movq	(%rdx), %rdx
	movl	(%rax,%rdx,4), %esi
	movq	%r14, %rdi
	movl	$3, %edx
	callq	_i2c_smbus_read_i2c_block_data_or_emulated
	testl	%eax, %eax
	js	LBB0_4
## %bb.5:
	movq	_POWER_DOWN@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r15, %rdi
	callq	_ak8975_set_mode
	testl	%eax, %eax
	js	LBB0_6
## %bb.7:
	cmpq	$0, (%r15)
	jg	LBB0_9
## %bb.8:
	cmpq	$0, (%r14)
	jle	LBB0_11
LBB0_9:
	movq	%r15, %rdi
	callq	_ak8975_setup_irq
	testl	%eax, %eax
	js	LBB0_10
LBB0_11:
	movq	8(%r15), %rax
	movq	16(%r15), %rcx
	movl	(%rax), %edi
	callq	*(%rcx)
	movq	24(%r15), %rcx
	movl	%eax, (%rcx)
	movq	8(%r15), %rax
	movq	16(%r15), %rcx
	movl	4(%rax), %edi
	callq	*(%rcx)
	movq	24(%r15), %rcx
	movl	%eax, 4(%rcx)
	movq	8(%r15), %rax
	movq	16(%r15), %rcx
	movl	8(%rax), %edi
	callq	*(%rcx)
	movq	24(%r15), %rcx
	movl	%eax, 8(%rcx)
	xorl	%ebx, %ebx
	jmp	LBB0_12
LBB0_1:
	movl	%eax, %ebx
	addq	$8, %r14
	leaq	L_.str(%rip), %rsi
	jmp	LBB0_2
LBB0_4:
	movl	%eax, %ebx
	addq	$8, %r14
	leaq	L_.str.1(%rip), %rsi
	jmp	LBB0_2
LBB0_6:
	movl	%eax, %ebx
	addq	$8, %r14
	leaq	L_.str.2(%rip), %rsi
	jmp	LBB0_2
LBB0_10:
	movl	%eax, %ebx
	addq	$8, %r14
	leaq	L_.str.3(%rip), %rsi
LBB0_2:
	movq	%r14, %rdi
	callq	_dev_err
LBB0_12:
	movl	%ebx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_FUSE_ROM,4,2                   ## @FUSE_ROM
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Error in setting fuse access mode\n"

	.comm	_ASA_BASE,8,3                   ## @ASA_BASE
L_.str.1:                               ## @.str.1
	.asciz	"Not able to read asa data\n"

	.comm	_POWER_DOWN,4,2                 ## @POWER_DOWN
L_.str.2:                               ## @.str.2
	.asciz	"Error in setting power-down mode\n"

L_.str.3:                               ## @.str.3
	.asciz	"Error setting data ready interrupt\n"

	.no_dead_strip	_ak8975_setup
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ak8975_setup
_ak8975_setup:                          ; @ak8975_setup
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.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	x20, x0
	bl	_i2c_get_clientdata
	bl	_iio_priv
	mov	x19, x0
Lloh0:
	adrp	x8, _FUSE_ROM@GOTPAGE
Lloh1:
	ldr	x8, [x8, _FUSE_ROM@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	bl	_ak8975_set_mode
	tbnz	w0, #31, LBB0_7
; %bb.1:
	ldp	x3, x8, [x19, #8]
	ldr	x8, [x8, #8]
Lloh3:
	adrp	x9, _ASA_BASE@GOTPAGE
Lloh4:
	ldr	x9, [x9, _ASA_BASE@GOTPAGEOFF]
Lloh5:
	ldr	x9, [x9]
	ldr	w1, [x8, x9, lsl #2]
	mov	x0, x20
	mov	w2, #3
	bl	_i2c_smbus_read_i2c_block_data_or_emulated
	tbnz	w0, #31, LBB0_8
; %bb.2:
Lloh6:
	adrp	x8, _POWER_DOWN@GOTPAGE
Lloh7:
	ldr	x8, [x8, _POWER_DOWN@GOTPAGEOFF]
Lloh8:
	ldr	w1, [x8]
	mov	x0, x19
	bl	_ak8975_set_mode
	tbnz	w0, #31, LBB0_9
; %bb.3:
	ldr	x8, [x19]
	cmp	x8, #0
	b.gt	LBB0_5
; %bb.4:
	ldr	x8, [x20]
	cmp	x8, #1
	b.lt	LBB0_6
LBB0_5:
	mov	x0, x19
	bl	_ak8975_setup_irq
	tbnz	w0, #31, LBB0_10
LBB0_6:
	ldp	x9, x8, [x19, #8]
	ldr	x8, [x8]
	ldr	w0, [x9]
	blr	x8
	ldr	x8, [x19, #24]
	str	w0, [x8]
	ldp	x9, x8, [x19, #8]
	ldr	x8, [x8]
	ldr	w0, [x9, #4]
	blr	x8
	ldr	x8, [x19, #24]
	str	w0, [x8, #4]
	ldp	x9, x8, [x19, #8]
	ldr	x8, [x8]
	ldr	w0, [x9, #8]
	blr	x8
	mov	w21, #0
	ldr	x8, [x19, #24]
	str	w0, [x8, #8]
	b	LBB0_12
LBB0_7:
	mov	x21, x0
	add	x0, x20, #8
Lloh9:
	adrp	x1, l_.str@PAGE
Lloh10:
	add	x1, x1, l_.str@PAGEOFF
	b	LBB0_11
LBB0_8:
	mov	x21, x0
	add	x0, x20, #8
Lloh11:
	adrp	x1, l_.str.1@PAGE
Lloh12:
	add	x1, x1, l_.str.1@PAGEOFF
	b	LBB0_11
LBB0_9:
	mov	x21, x0
	add	x0, x20, #8
Lloh13:
	adrp	x1, l_.str.2@PAGE
Lloh14:
	add	x1, x1, l_.str.2@PAGEOFF
	b	LBB0_11
LBB0_10:
	mov	x21, x0
	add	x0, x20, #8
Lloh15:
	adrp	x1, l_.str.3@PAGE
Lloh16:
	add	x1, x1, l_.str.3@PAGEOFF
LBB0_11:
	bl	_dev_err
LBB0_12:
	mov	x0, x21
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpAdd	Lloh9, Lloh10
	.loh AdrpAdd	Lloh11, Lloh12
	.loh AdrpAdd	Lloh13, Lloh14
	.loh AdrpAdd	Lloh15, Lloh16
	.cfi_endproc
                                        ; -- End function
	.comm	_FUSE_ROM,4,2                   ; @FUSE_ROM
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Error in setting fuse access mode\n"

	.comm	_ASA_BASE,8,3                   ; @ASA_BASE
l_.str.1:                               ; @.str.1
	.asciz	"Not able to read asa data\n"

	.comm	_POWER_DOWN,4,2                 ; @POWER_DOWN
l_.str.2:                               ; @.str.2
	.asciz	"Error in setting power-down mode\n"

l_.str.3:                               ; @.str.3
	.asciz	"Error setting data ready interrupt\n"

	.no_dead_strip	_ak8975_setup
.subsections_via_symbols
