	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ad7949_spi_write_cfg
_ad7949_spi_write_cfg:                  ## @ad7949_spi_write_cfg
	.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
	subq	$40, %rsp
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%edx, %r14d
	movl	%esi, %ebx
	movq	%rdi, %r15
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -32(%rbp)
	callq	_ad7949_spi_bits_per_word
	movq	_AD7949_CFG_REG_SIZE_BITS@GOTPCREL(%rip), %rdx
	movq	%r15, -48(%rbp)
	movl	$4, -40(%rbp)
	movl	%eax, -36(%rbp)
	movl	%eax, %ecx
	subl	(%rdx), %ecx
	movl	4(%r15), %eax
	xorl	%eax, %ebx
	andl	%r14d, %ebx
	xorl	%eax, %ebx
	movl	%ebx, 4(%r15)
                                        ## kill: def $cl killed $cl killed $ecx
	shll	%cl, %ebx
	movl	%ebx, (%r15)
	leaq	-56(%rbp), %rbx
	leaq	-48(%rbp), %rsi
	movq	%rbx, %rdi
	movl	$1, %edx
	callq	_spi_message_init_with_transfers
	movl	8(%r15), %edi
	movq	%rbx, %rsi
	callq	_spi_sync
	movl	%eax, %ebx
	movl	$2, %edi
	callq	_udelay
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-32(%rbp), %rax
	jne	LBB0_2
## %bb.1:
	movl	%ebx, %eax
	addq	$40, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_2:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_AD7949_CFG_REG_SIZE_BITS,4,2   ## @AD7949_CFG_REG_SIZE_BITS
	.no_dead_strip	_ad7949_spi_write_cfg
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ad7949_spi_write_cfg
_ad7949_spi_write_cfg:                  ; @ad7949_spi_write_cfg
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #80
	.cfi_def_cfa_offset 80
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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, x2
	mov	x20, x1
	mov	x21, x0
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	str	x8, [sp, #24]
	bl	_ad7949_spi_bits_per_word
Lloh3:
	adrp	x8, _AD7949_CFG_REG_SIZE_BITS@GOTPAGE
Lloh4:
	ldr	x8, [x8, _AD7949_CFG_REG_SIZE_BITS@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	sub	w8, w0, w8
	str	x21, [sp, #8]
	mov	w9, #4
	stp	w9, w0, [sp, #16]
	and	w9, w19, w20
	ldr	w10, [x21, #4]
	bic	w10, w10, w19
	orr	w9, w10, w9
	lsl	w8, w9, w8
	stp	w8, w9, [x21]
	mov	x0, sp
	add	x1, sp, #8
	mov	w2, #1
	bl	_spi_message_init_with_transfers
	ldr	w0, [x21, #8]
	mov	x1, sp
	bl	_spi_sync
	mov	x19, x0
	mov	w0, #2
	bl	_udelay
	ldr	x8, [sp, #24]
Lloh6:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh7:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh8:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_2
; %bb.1:
	mov	x0, x19
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #80
	ret
LBB0_2:
	bl	___stack_chk_fail
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.cfi_endproc
                                        ; -- End function
	.comm	_AD7949_CFG_REG_SIZE_BITS,4,2   ; @AD7949_CFG_REG_SIZE_BITS
	.no_dead_strip	_ad7949_spi_write_cfg
.subsections_via_symbols
