	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ad5504_spi_read
_ad5504_spi_read:                       ## @ad5504_spi_read
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r14
	pushq	%rbx
	subq	$32, %rsp
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movq	%rdi, %r14
	movl	$2, -40(%rbp)
	movq	(%rdi), %rax
	leaq	4(%rax), %rcx
	movq	%rcx, -32(%rbp)
	movq	%rax, -24(%rbp)
	movq	_AD5504_CMD_READ@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	movl	%esi, %edi
	callq	_AD5504_ADDR
	orl	%eax, %ebx
	movl	%ebx, %edi
	callq	_cpu_to_be16
	movq	(%r14), %rcx
	movl	%eax, (%rcx)
	movl	8(%r14), %edi
	leaq	-40(%rbp), %rsi
	movl	$1, %edx
	callq	_spi_sync_transfer
	testl	%eax, %eax
	js	LBB0_2
## %bb.1:
	movq	(%r14), %rax
	movl	4(%rax), %edi
	callq	_be16_to_cpu
	movq	_AD5504_RES_MASK@GOTPCREL(%rip), %rcx
	andl	(%rcx), %eax
LBB0_2:
	addq	$32, %rsp
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_AD5504_CMD_READ,4,2            ## @AD5504_CMD_READ
	.comm	_AD5504_RES_MASK,4,2            ## @AD5504_RES_MASK
	.no_dead_strip	_ad5504_spi_read
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ad5504_spi_read
_ad5504_spi_read:                       ; @ad5504_spi_read
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.cfi_def_cfa_offset 64
	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
	mov	x19, x0
	mov	w8, #2
	str	w8, [sp, #8]
	ldr	x8, [x0]
	add	x9, x8, #4
	stp	x9, x8, [sp, #16]
Lloh0:
	adrp	x8, _AD5504_CMD_READ@GOTPAGE
Lloh1:
	ldr	x8, [x8, _AD5504_CMD_READ@GOTPAGEOFF]
Lloh2:
	ldr	w20, [x8]
	mov	x0, x1
	bl	_AD5504_ADDR
	orr	w0, w0, w20
	bl	_cpu_to_be16
	ldr	x8, [x19]
	str	w0, [x8]
	ldr	w0, [x19, #8]
	add	x1, sp, #8
	mov	w2, #1
	bl	_spi_sync_transfer
	tbnz	w0, #31, LBB0_2
; %bb.1:
	ldr	x8, [x19]
	ldr	w0, [x8, #4]
	bl	_be16_to_cpu
Lloh3:
	adrp	x8, _AD5504_RES_MASK@GOTPAGE
Lloh4:
	ldr	x8, [x8, _AD5504_RES_MASK@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	and	w0, w8, w0
LBB0_2:
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #64
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.cfi_endproc
                                        ; -- End function
	.comm	_AD5504_CMD_READ,4,2            ; @AD5504_CMD_READ
	.comm	_AD5504_RES_MASK,4,2            ; @AD5504_RES_MASK
	.no_dead_strip	_ad5504_spi_read
.subsections_via_symbols
