	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function lm3646_get_ctrl
_lm3646_get_ctrl:                       ## @lm3646_get_ctrl
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%rbx
	pushq	%rax
	.cfi_offset %rbx, -24
	movq	%rdi, %rbx
	callq	_to_lm3646_flash
	movq	(%rbx), %rcx
	movq	_V4L2_CID_FLASH_FAULT@GOTPCREL(%rip), %rdx
	cmpq	(%rdx), %rcx
	jne	LBB0_1
## %bb.2:
	movl	(%rax), %edi
	movq	_REG_FLAG@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	-12(%rbp), %rdx
	callq	_regmap_read
	testl	%eax, %eax
	js	LBB0_20
## %bb.3:
	movl	$0, 8(%rbx)
	movl	-12(%rbp), %ecx
	movq	_FAULT_TIMEOUT@GOTPCREL(%rip), %rax
	testl	%ecx, (%rax)
	je	LBB0_4
## %bb.5:
	movq	_V4L2_FLASH_FAULT_TIMEOUT@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movl	%edx, 8(%rbx)
	jmp	LBB0_6
LBB0_1:
	movq	_EINVAL@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
	jmp	LBB0_20
LBB0_4:
	xorl	%edx, %edx
LBB0_6:
	movq	_FAULT_SHORT_CIRCUIT@GOTPCREL(%rip), %rax
	testl	%ecx, (%rax)
	je	LBB0_8
## %bb.7:
	movq	_V4L2_FLASH_FAULT_SHORT_CIRCUIT@GOTPCREL(%rip), %rax
	orl	(%rax), %edx
	movl	%edx, 8(%rbx)
LBB0_8:
	movq	_FAULT_UVLO@GOTPCREL(%rip), %rax
	testl	%ecx, (%rax)
	je	LBB0_10
## %bb.9:
	movq	_V4L2_FLASH_FAULT_UNDER_VOLTAGE@GOTPCREL(%rip), %rax
	orl	(%rax), %edx
	movl	%edx, 8(%rbx)
LBB0_10:
	movq	_FAULT_IVFM@GOTPCREL(%rip), %rax
	testl	%ecx, (%rax)
	je	LBB0_12
## %bb.11:
	movq	_V4L2_FLASH_FAULT_INPUT_VOLTAGE@GOTPCREL(%rip), %rax
	orl	(%rax), %edx
	movl	%edx, 8(%rbx)
LBB0_12:
	movq	_FAULT_OCP@GOTPCREL(%rip), %rax
	testl	%ecx, (%rax)
	je	LBB0_14
## %bb.13:
	movq	_V4L2_FLASH_FAULT_OVER_CURRENT@GOTPCREL(%rip), %rax
	orl	(%rax), %edx
	movl	%edx, 8(%rbx)
LBB0_14:
	movq	_FAULT_OVERTEMP@GOTPCREL(%rip), %rax
	testl	%ecx, (%rax)
	je	LBB0_16
## %bb.15:
	movq	_V4L2_FLASH_FAULT_OVER_TEMPERATURE@GOTPCREL(%rip), %rax
	orl	(%rax), %edx
	movl	%edx, 8(%rbx)
LBB0_16:
	movq	_FAULT_NTC_TRIP@GOTPCREL(%rip), %rax
	testl	%ecx, (%rax)
	je	LBB0_18
## %bb.17:
	movq	_V4L2_FLASH_FAULT_LED_OVER_TEMPERATURE@GOTPCREL(%rip), %rax
	orl	(%rax), %edx
	movl	%edx, 8(%rbx)
LBB0_18:
	movq	_FAULT_OVP@GOTPCREL(%rip), %rsi
	xorl	%eax, %eax
	testl	%ecx, (%rsi)
	je	LBB0_20
## %bb.19:
	movq	_V4L2_FLASH_FAULT_OVER_VOLTAGE@GOTPCREL(%rip), %rcx
	orl	(%rcx), %edx
	movl	%edx, 8(%rbx)
LBB0_20:
	addq	$8, %rsp
	popq	%rbx
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_V4L2_CID_FLASH_FAULT,8,3       ## @V4L2_CID_FLASH_FAULT
	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_REG_FLAG,4,2                   ## @REG_FLAG
	.comm	_FAULT_TIMEOUT,4,2              ## @FAULT_TIMEOUT
	.comm	_V4L2_FLASH_FAULT_TIMEOUT,4,2   ## @V4L2_FLASH_FAULT_TIMEOUT
	.comm	_FAULT_SHORT_CIRCUIT,4,2        ## @FAULT_SHORT_CIRCUIT
	.comm	_V4L2_FLASH_FAULT_SHORT_CIRCUIT,4,2 ## @V4L2_FLASH_FAULT_SHORT_CIRCUIT
	.comm	_FAULT_UVLO,4,2                 ## @FAULT_UVLO
	.comm	_V4L2_FLASH_FAULT_UNDER_VOLTAGE,4,2 ## @V4L2_FLASH_FAULT_UNDER_VOLTAGE
	.comm	_FAULT_IVFM,4,2                 ## @FAULT_IVFM
	.comm	_V4L2_FLASH_FAULT_INPUT_VOLTAGE,4,2 ## @V4L2_FLASH_FAULT_INPUT_VOLTAGE
	.comm	_FAULT_OCP,4,2                  ## @FAULT_OCP
	.comm	_V4L2_FLASH_FAULT_OVER_CURRENT,4,2 ## @V4L2_FLASH_FAULT_OVER_CURRENT
	.comm	_FAULT_OVERTEMP,4,2             ## @FAULT_OVERTEMP
	.comm	_V4L2_FLASH_FAULT_OVER_TEMPERATURE,4,2 ## @V4L2_FLASH_FAULT_OVER_TEMPERATURE
	.comm	_FAULT_NTC_TRIP,4,2             ## @FAULT_NTC_TRIP
	.comm	_V4L2_FLASH_FAULT_LED_OVER_TEMPERATURE,4,2 ## @V4L2_FLASH_FAULT_LED_OVER_TEMPERATURE
	.comm	_FAULT_OVP,4,2                  ## @FAULT_OVP
	.comm	_V4L2_FLASH_FAULT_OVER_VOLTAGE,4,2 ## @V4L2_FLASH_FAULT_OVER_VOLTAGE
	.no_dead_strip	_lm3646_get_ctrl
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function lm3646_get_ctrl
_lm3646_get_ctrl:                       ; @lm3646_get_ctrl
	.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
	bl	_to_lm3646_flash
	ldr	x8, [x19]
Lloh0:
	adrp	x9, _V4L2_CID_FLASH_FAULT@GOTPAGE
Lloh1:
	ldr	x9, [x9, _V4L2_CID_FLASH_FAULT@GOTPAGEOFF]
Lloh2:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_4
; %bb.1:
	ldr	w0, [x0]
Lloh3:
	adrp	x8, _REG_FLAG@GOTPAGE
Lloh4:
	ldr	x8, [x8, _REG_FLAG@GOTPAGEOFF]
Lloh5:
	ldr	w1, [x8]
	add	x2, sp, #12
	bl	_regmap_read
	tbnz	w0, #31, LBB0_21
; %bb.2:
	str	wzr, [x19, #8]
	ldr	w8, [sp, #12]
Lloh6:
	adrp	x9, _FAULT_TIMEOUT@GOTPAGE
Lloh7:
	ldr	x9, [x9, _FAULT_TIMEOUT@GOTPAGEOFF]
Lloh8:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_5
; %bb.3:
Lloh9:
	adrp	x9, _V4L2_FLASH_FAULT_TIMEOUT@GOTPAGE
Lloh10:
	ldr	x9, [x9, _V4L2_FLASH_FAULT_TIMEOUT@GOTPAGEOFF]
Lloh11:
	ldr	w9, [x9]
	str	w9, [x19, #8]
	b	LBB0_6
LBB0_4:
Lloh12:
	adrp	x8, _EINVAL@GOTPAGE
Lloh13:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh14:
	ldr	w8, [x8]
	neg	w0, w8
	b	LBB0_21
LBB0_5:
	mov	w9, #0
LBB0_6:
Lloh15:
	adrp	x10, _FAULT_SHORT_CIRCUIT@GOTPAGE
Lloh16:
	ldr	x10, [x10, _FAULT_SHORT_CIRCUIT@GOTPAGEOFF]
Lloh17:
	ldr	w10, [x10]
	tst	w10, w8
	b.eq	LBB0_8
; %bb.7:
Lloh18:
	adrp	x10, _V4L2_FLASH_FAULT_SHORT_CIRCUIT@GOTPAGE
Lloh19:
	ldr	x10, [x10, _V4L2_FLASH_FAULT_SHORT_CIRCUIT@GOTPAGEOFF]
Lloh20:
	ldr	w10, [x10]
	orr	w9, w9, w10
	str	w9, [x19, #8]
LBB0_8:
Lloh21:
	adrp	x10, _FAULT_UVLO@GOTPAGE
Lloh22:
	ldr	x10, [x10, _FAULT_UVLO@GOTPAGEOFF]
Lloh23:
	ldr	w10, [x10]
	tst	w10, w8
	b.eq	LBB0_10
; %bb.9:
Lloh24:
	adrp	x10, _V4L2_FLASH_FAULT_UNDER_VOLTAGE@GOTPAGE
Lloh25:
	ldr	x10, [x10, _V4L2_FLASH_FAULT_UNDER_VOLTAGE@GOTPAGEOFF]
Lloh26:
	ldr	w10, [x10]
	orr	w9, w9, w10
	str	w9, [x19, #8]
LBB0_10:
Lloh27:
	adrp	x10, _FAULT_IVFM@GOTPAGE
Lloh28:
	ldr	x10, [x10, _FAULT_IVFM@GOTPAGEOFF]
Lloh29:
	ldr	w10, [x10]
	tst	w10, w8
	b.eq	LBB0_12
; %bb.11:
Lloh30:
	adrp	x10, _V4L2_FLASH_FAULT_INPUT_VOLTAGE@GOTPAGE
Lloh31:
	ldr	x10, [x10, _V4L2_FLASH_FAULT_INPUT_VOLTAGE@GOTPAGEOFF]
Lloh32:
	ldr	w10, [x10]
	orr	w9, w9, w10
	str	w9, [x19, #8]
LBB0_12:
Lloh33:
	adrp	x10, _FAULT_OCP@GOTPAGE
Lloh34:
	ldr	x10, [x10, _FAULT_OCP@GOTPAGEOFF]
Lloh35:
	ldr	w10, [x10]
	tst	w10, w8
	b.eq	LBB0_14
; %bb.13:
Lloh36:
	adrp	x10, _V4L2_FLASH_FAULT_OVER_CURRENT@GOTPAGE
Lloh37:
	ldr	x10, [x10, _V4L2_FLASH_FAULT_OVER_CURRENT@GOTPAGEOFF]
Lloh38:
	ldr	w10, [x10]
	orr	w9, w9, w10
	str	w9, [x19, #8]
LBB0_14:
Lloh39:
	adrp	x10, _FAULT_OVERTEMP@GOTPAGE
Lloh40:
	ldr	x10, [x10, _FAULT_OVERTEMP@GOTPAGEOFF]
Lloh41:
	ldr	w10, [x10]
	tst	w10, w8
	b.eq	LBB0_16
; %bb.15:
Lloh42:
	adrp	x10, _V4L2_FLASH_FAULT_OVER_TEMPERATURE@GOTPAGE
Lloh43:
	ldr	x10, [x10, _V4L2_FLASH_FAULT_OVER_TEMPERATURE@GOTPAGEOFF]
Lloh44:
	ldr	w10, [x10]
	orr	w9, w9, w10
	str	w9, [x19, #8]
LBB0_16:
Lloh45:
	adrp	x10, _FAULT_NTC_TRIP@GOTPAGE
Lloh46:
	ldr	x10, [x10, _FAULT_NTC_TRIP@GOTPAGEOFF]
Lloh47:
	ldr	w10, [x10]
	tst	w10, w8
	b.eq	LBB0_18
; %bb.17:
Lloh48:
	adrp	x10, _V4L2_FLASH_FAULT_LED_OVER_TEMPERATURE@GOTPAGE
Lloh49:
	ldr	x10, [x10, _V4L2_FLASH_FAULT_LED_OVER_TEMPERATURE@GOTPAGEOFF]
Lloh50:
	ldr	w10, [x10]
	orr	w9, w9, w10
	str	w9, [x19, #8]
LBB0_18:
Lloh51:
	adrp	x10, _FAULT_OVP@GOTPAGE
Lloh52:
	ldr	x10, [x10, _FAULT_OVP@GOTPAGEOFF]
Lloh53:
	ldr	w10, [x10]
	tst	w10, w8
	b.eq	LBB0_20
; %bb.19:
	mov	w0, #0
Lloh54:
	adrp	x8, _V4L2_FLASH_FAULT_OVER_VOLTAGE@GOTPAGE
Lloh55:
	ldr	x8, [x8, _V4L2_FLASH_FAULT_OVER_VOLTAGE@GOTPAGEOFF]
Lloh56:
	ldr	w8, [x8]
	orr	w8, w9, w8
	str	w8, [x19, #8]
	b	LBB0_21
LBB0_20:
	mov	w0, #0
LBB0_21:
	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	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	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpLdrGotLdr	Lloh24, Lloh25, Lloh26
	.loh AdrpLdrGotLdr	Lloh27, Lloh28, Lloh29
	.loh AdrpLdrGotLdr	Lloh30, Lloh31, Lloh32
	.loh AdrpLdrGotLdr	Lloh33, Lloh34, Lloh35
	.loh AdrpLdrGotLdr	Lloh36, Lloh37, Lloh38
	.loh AdrpLdrGotLdr	Lloh39, Lloh40, Lloh41
	.loh AdrpLdrGotLdr	Lloh42, Lloh43, Lloh44
	.loh AdrpLdrGotLdr	Lloh45, Lloh46, Lloh47
	.loh AdrpLdrGotLdr	Lloh48, Lloh49, Lloh50
	.loh AdrpLdrGotLdr	Lloh51, Lloh52, Lloh53
	.loh AdrpLdrGotLdr	Lloh54, Lloh55, Lloh56
	.cfi_endproc
                                        ; -- End function
	.comm	_V4L2_CID_FLASH_FAULT,8,3       ; @V4L2_CID_FLASH_FAULT
	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_REG_FLAG,4,2                   ; @REG_FLAG
	.comm	_FAULT_TIMEOUT,4,2              ; @FAULT_TIMEOUT
	.comm	_V4L2_FLASH_FAULT_TIMEOUT,4,2   ; @V4L2_FLASH_FAULT_TIMEOUT
	.comm	_FAULT_SHORT_CIRCUIT,4,2        ; @FAULT_SHORT_CIRCUIT
	.comm	_V4L2_FLASH_FAULT_SHORT_CIRCUIT,4,2 ; @V4L2_FLASH_FAULT_SHORT_CIRCUIT
	.comm	_FAULT_UVLO,4,2                 ; @FAULT_UVLO
	.comm	_V4L2_FLASH_FAULT_UNDER_VOLTAGE,4,2 ; @V4L2_FLASH_FAULT_UNDER_VOLTAGE
	.comm	_FAULT_IVFM,4,2                 ; @FAULT_IVFM
	.comm	_V4L2_FLASH_FAULT_INPUT_VOLTAGE,4,2 ; @V4L2_FLASH_FAULT_INPUT_VOLTAGE
	.comm	_FAULT_OCP,4,2                  ; @FAULT_OCP
	.comm	_V4L2_FLASH_FAULT_OVER_CURRENT,4,2 ; @V4L2_FLASH_FAULT_OVER_CURRENT
	.comm	_FAULT_OVERTEMP,4,2             ; @FAULT_OVERTEMP
	.comm	_V4L2_FLASH_FAULT_OVER_TEMPERATURE,4,2 ; @V4L2_FLASH_FAULT_OVER_TEMPERATURE
	.comm	_FAULT_NTC_TRIP,4,2             ; @FAULT_NTC_TRIP
	.comm	_V4L2_FLASH_FAULT_LED_OVER_TEMPERATURE,4,2 ; @V4L2_FLASH_FAULT_LED_OVER_TEMPERATURE
	.comm	_FAULT_OVP,4,2                  ; @FAULT_OVP
	.comm	_V4L2_FLASH_FAULT_OVER_VOLTAGE,4,2 ; @V4L2_FLASH_FAULT_OVER_VOLTAGE
	.no_dead_strip	_lm3646_get_ctrl
.subsections_via_symbols
