	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function dmard10_reset
_dmard10_reset:                         ## @dmard10_reset
	.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	$16, %rsp
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movq	%rdi, %rbx
	movq	_DMARD10_REG_PD@GOTPCREL(%rip), %rax
	movzbl	(%rax), %esi
	movq	_DMARD10_VALUE_PD_RST@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	callq	_i2c_smbus_write_byte_data
	testl	%eax, %eax
	js	LBB0_5
## %bb.1:
	movq	_DMARD10_REG_ACTR@GOTPCREL(%rip), %r14
	movb	(%r14), %al
	movb	%al, -23(%rbp)
	movq	_DMARD10_MODE_STANDBY@GOTPCREL(%rip), %rax
	movb	(%rax), %al
	movb	%al, -22(%rbp)
	movq	_DMARD10_MODE_READ_OTP@GOTPCREL(%rip), %rcx
	movb	(%rcx), %cl
	movb	%cl, -21(%rbp)
	movb	%al, -20(%rbp)
	movq	_DMARD10_MODE_RESET_DATA_PATH@GOTPCREL(%rip), %rcx
	movb	(%rcx), %cl
	movb	%cl, -19(%rbp)
	movb	%al, -18(%rbp)
	leaq	-23(%rbp), %rsi
	movq	%rbx, %rdi
	movl	$6, %edx
	callq	_i2c_master_send
	testl	%eax, %eax
	js	LBB0_5
## %bb.2:
	movq	_DMARD10_REG_MISC2@GOTPCREL(%rip), %rax
	movzbl	(%rax), %esi
	movq	_DMARD10_VALUE_MISC2_OSCA_EN@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%rbx, %rdi
	callq	_i2c_smbus_write_byte_data
	testl	%eax, %eax
	js	LBB0_5
## %bb.3:
	movq	_DMARD10_REG_AFEM@GOTPCREL(%rip), %rax
	movb	(%rax), %al
	movb	%al, -23(%rbp)
	movq	_DMARD10_VALUE_AFEM_AFEN_NORMAL@GOTPCREL(%rip), %rax
	movb	(%rax), %al
	movb	%al, -22(%rbp)
	movq	_DMARD10_VALUE_CKSEL_ODR_100_204@GOTPCREL(%rip), %rax
	movb	(%rax), %al
	movb	%al, -21(%rbp)
	movq	_DMARD10_VALUE_INTC@GOTPCREL(%rip), %rax
	movb	(%rax), %al
	movb	%al, -20(%rbp)
	movq	_DMARD10_VALUE_TAPNS_AVE_2@GOTPCREL(%rip), %rax
	movb	(%rax), %al
	movb	%al, -19(%rbp)
	movw	$1792, -18(%rbp)                ## imm = 0x700
	leaq	-23(%rbp), %rsi
	movq	%rbx, %rdi
	movl	$7, %edx
	callq	_i2c_master_send
	testl	%eax, %eax
	js	LBB0_5
## %bb.4:
	movzbl	(%r14), %esi
	movq	_DMARD10_MODE_ACTIVE@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%rbx, %rdi
	callq	_i2c_smbus_write_byte_data
	movl	%eax, %ecx
	sarl	$31, %eax
	andl	%ecx, %eax
LBB0_5:
	addq	$16, %rsp
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_DMARD10_REG_PD,1,0             ## @DMARD10_REG_PD
	.comm	_DMARD10_VALUE_PD_RST,4,2       ## @DMARD10_VALUE_PD_RST
	.comm	_DMARD10_REG_ACTR,1,0           ## @DMARD10_REG_ACTR
	.comm	_DMARD10_MODE_STANDBY,1,0       ## @DMARD10_MODE_STANDBY
	.comm	_DMARD10_MODE_READ_OTP,1,0      ## @DMARD10_MODE_READ_OTP
	.comm	_DMARD10_MODE_RESET_DATA_PATH,1,0 ## @DMARD10_MODE_RESET_DATA_PATH
	.comm	_DMARD10_REG_MISC2,1,0          ## @DMARD10_REG_MISC2
	.comm	_DMARD10_VALUE_MISC2_OSCA_EN,4,2 ## @DMARD10_VALUE_MISC2_OSCA_EN
	.comm	_DMARD10_REG_AFEM,1,0           ## @DMARD10_REG_AFEM
	.comm	_DMARD10_VALUE_AFEM_AFEN_NORMAL,1,0 ## @DMARD10_VALUE_AFEM_AFEN_NORMAL
	.comm	_DMARD10_VALUE_CKSEL_ODR_100_204,1,0 ## @DMARD10_VALUE_CKSEL_ODR_100_204
	.comm	_DMARD10_VALUE_INTC,1,0         ## @DMARD10_VALUE_INTC
	.comm	_DMARD10_VALUE_TAPNS_AVE_2,1,0  ## @DMARD10_VALUE_TAPNS_AVE_2
	.comm	_DMARD10_MODE_ACTIVE,4,2        ## @DMARD10_MODE_ACTIVE
	.no_dead_strip	_dmard10_reset
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function dmard10_reset
_dmard10_reset:                         ; @dmard10_reset
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #48
	.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
	mov	x19, x0
Lloh0:
	adrp	x8, _DMARD10_REG_PD@GOTPAGE
Lloh1:
	ldr	x8, [x8, _DMARD10_REG_PD@GOTPAGEOFF]
	ldrb	w1, [x8]
Lloh2:
	adrp	x8, _DMARD10_VALUE_PD_RST@GOTPAGE
Lloh3:
	ldr	x8, [x8, _DMARD10_VALUE_PD_RST@GOTPAGEOFF]
Lloh4:
	ldr	w2, [x8]
	bl	_i2c_smbus_write_byte_data
	tbnz	w0, #31, LBB0_5
; %bb.1:
Lloh5:
	adrp	x20, _DMARD10_REG_ACTR@GOTPAGE
Lloh6:
	ldr	x20, [x20, _DMARD10_REG_ACTR@GOTPAGEOFF]
	ldrb	w8, [x20]
	strb	w8, [sp, #9]
Lloh7:
	adrp	x8, _DMARD10_MODE_STANDBY@GOTPAGE
Lloh8:
	ldr	x8, [x8, _DMARD10_MODE_STANDBY@GOTPAGEOFF]
	ldrb	w8, [x8]
	strb	w8, [sp, #10]
Lloh9:
	adrp	x9, _DMARD10_MODE_READ_OTP@GOTPAGE
Lloh10:
	ldr	x9, [x9, _DMARD10_MODE_READ_OTP@GOTPAGEOFF]
	ldrb	w9, [x9]
	strb	w9, [sp, #11]
	strb	w8, [sp, #12]
Lloh11:
	adrp	x9, _DMARD10_MODE_RESET_DATA_PATH@GOTPAGE
Lloh12:
	ldr	x9, [x9, _DMARD10_MODE_RESET_DATA_PATH@GOTPAGEOFF]
	ldrb	w9, [x9]
	strb	w9, [sp, #13]
	strb	w8, [sp, #14]
	add	x1, sp, #9
	mov	x0, x19
	mov	w2, #6
	bl	_i2c_master_send
	tbnz	w0, #31, LBB0_5
; %bb.2:
Lloh13:
	adrp	x8, _DMARD10_REG_MISC2@GOTPAGE
Lloh14:
	ldr	x8, [x8, _DMARD10_REG_MISC2@GOTPAGEOFF]
	ldrb	w1, [x8]
Lloh15:
	adrp	x8, _DMARD10_VALUE_MISC2_OSCA_EN@GOTPAGE
Lloh16:
	ldr	x8, [x8, _DMARD10_VALUE_MISC2_OSCA_EN@GOTPAGEOFF]
Lloh17:
	ldr	w2, [x8]
	mov	x0, x19
	bl	_i2c_smbus_write_byte_data
	tbnz	w0, #31, LBB0_5
; %bb.3:
Lloh18:
	adrp	x8, _DMARD10_REG_AFEM@GOTPAGE
Lloh19:
	ldr	x8, [x8, _DMARD10_REG_AFEM@GOTPAGEOFF]
	ldrb	w8, [x8]
	strb	w8, [sp, #9]
Lloh20:
	adrp	x8, _DMARD10_VALUE_AFEM_AFEN_NORMAL@GOTPAGE
Lloh21:
	ldr	x8, [x8, _DMARD10_VALUE_AFEM_AFEN_NORMAL@GOTPAGEOFF]
	ldrb	w8, [x8]
	strb	w8, [sp, #10]
Lloh22:
	adrp	x8, _DMARD10_VALUE_CKSEL_ODR_100_204@GOTPAGE
Lloh23:
	ldr	x8, [x8, _DMARD10_VALUE_CKSEL_ODR_100_204@GOTPAGEOFF]
	ldrb	w8, [x8]
	strb	w8, [sp, #11]
Lloh24:
	adrp	x8, _DMARD10_VALUE_INTC@GOTPAGE
Lloh25:
	ldr	x8, [x8, _DMARD10_VALUE_INTC@GOTPAGEOFF]
	ldrb	w8, [x8]
	strb	w8, [sp, #12]
Lloh26:
	adrp	x8, _DMARD10_VALUE_TAPNS_AVE_2@GOTPAGE
Lloh27:
	ldr	x8, [x8, _DMARD10_VALUE_TAPNS_AVE_2@GOTPAGEOFF]
	ldrb	w8, [x8]
	strb	w8, [sp, #13]
	mov	w8, #1792
	sturh	w8, [sp, #14]
	add	x1, sp, #9
	mov	x0, x19
	mov	w2, #7
	bl	_i2c_master_send
	tbnz	w0, #31, LBB0_5
; %bb.4:
	ldrb	w1, [x20]
Lloh28:
	adrp	x8, _DMARD10_MODE_ACTIVE@GOTPAGE
Lloh29:
	ldr	x8, [x8, _DMARD10_MODE_ACTIVE@GOTPAGEOFF]
Lloh30:
	ldr	w2, [x8]
	mov	x0, x19
	bl	_i2c_smbus_write_byte_data
	cmp	w0, #0
	csel	w0, w0, wzr, lt
LBB0_5:
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #48
	ret
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh11, Lloh12
	.loh AdrpLdrGot	Lloh9, Lloh10
	.loh AdrpLdrGot	Lloh7, Lloh8
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGot	Lloh13, Lloh14
	.loh AdrpLdrGot	Lloh26, Lloh27
	.loh AdrpLdrGot	Lloh24, Lloh25
	.loh AdrpLdrGot	Lloh22, Lloh23
	.loh AdrpLdrGot	Lloh20, Lloh21
	.loh AdrpLdrGot	Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh28, Lloh29, Lloh30
	.cfi_endproc
                                        ; -- End function
	.comm	_DMARD10_REG_PD,1,0             ; @DMARD10_REG_PD
	.comm	_DMARD10_VALUE_PD_RST,4,2       ; @DMARD10_VALUE_PD_RST
	.comm	_DMARD10_REG_ACTR,1,0           ; @DMARD10_REG_ACTR
	.comm	_DMARD10_MODE_STANDBY,1,0       ; @DMARD10_MODE_STANDBY
	.comm	_DMARD10_MODE_READ_OTP,1,0      ; @DMARD10_MODE_READ_OTP
	.comm	_DMARD10_MODE_RESET_DATA_PATH,1,0 ; @DMARD10_MODE_RESET_DATA_PATH
	.comm	_DMARD10_REG_MISC2,1,0          ; @DMARD10_REG_MISC2
	.comm	_DMARD10_VALUE_MISC2_OSCA_EN,4,2 ; @DMARD10_VALUE_MISC2_OSCA_EN
	.comm	_DMARD10_REG_AFEM,1,0           ; @DMARD10_REG_AFEM
	.comm	_DMARD10_VALUE_AFEM_AFEN_NORMAL,1,0 ; @DMARD10_VALUE_AFEM_AFEN_NORMAL
	.comm	_DMARD10_VALUE_CKSEL_ODR_100_204,1,0 ; @DMARD10_VALUE_CKSEL_ODR_100_204
	.comm	_DMARD10_VALUE_INTC,1,0         ; @DMARD10_VALUE_INTC
	.comm	_DMARD10_VALUE_TAPNS_AVE_2,1,0  ; @DMARD10_VALUE_TAPNS_AVE_2
	.comm	_DMARD10_MODE_ACTIVE,4,2        ; @DMARD10_MODE_ACTIVE
	.no_dead_strip	_dmard10_reset
.subsections_via_symbols
