	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function soc_common_pcmcia_skt_state
_soc_common_pcmcia_skt_state:           ## @soc_common_pcmcia_skt_state
	.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
	subq	$40, %rsp
	.cfi_offset %rbx, -24
	movq	%rdi, %rbx
	leaq	-40(%rbp), %rdi
	xorl	%esi, %esi
	movl	$32, %edx
	callq	_memset
	movabsq	$4294967297, %rax               ## imm = 0x100000001
	movq	%rax, -40(%rbp)
	movq	24(%rbx), %rax
	movq	_SOC_STAT_CD@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	movq	(%rax,%rcx,8), %rdi
	testq	%rdi, %rdi
	je	LBB0_2
## %bb.1:
	callq	_gpiod_get_value
	xorl	%ecx, %ecx
	testl	%eax, %eax
	setne	%cl
	movl	%ecx, -32(%rbp)
	movq	24(%rbx), %rax
LBB0_2:
	movq	_SOC_STAT_RDY@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	movq	(%rax,%rcx,8), %rdi
	testq	%rdi, %rdi
	je	LBB0_4
## %bb.3:
	callq	_gpiod_get_value
	xorl	%ecx, %ecx
	testl	%eax, %eax
	setne	%cl
	movl	%ecx, -28(%rbp)
	movq	24(%rbx), %rax
LBB0_4:
	movq	_SOC_STAT_BVD1@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	movq	(%rax,%rcx,8), %rdi
	testq	%rdi, %rdi
	je	LBB0_6
## %bb.5:
	callq	_gpiod_get_value
	xorl	%ecx, %ecx
	testl	%eax, %eax
	setne	%cl
	movl	%ecx, -40(%rbp)
	movq	24(%rbx), %rax
LBB0_6:
	movq	_SOC_STAT_BVD2@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	movq	(%rax,%rcx,8), %rdi
	testq	%rdi, %rdi
	je	LBB0_8
## %bb.7:
	callq	_gpiod_get_value
	xorl	%ecx, %ecx
	testl	%eax, %eax
	setne	%cl
	movl	%ecx, -36(%rbp)
	movq	24(%rbx), %rax
LBB0_8:
	movq	_SOC_STAT_VS1@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	movq	(%rax,%rcx,8), %rdi
	testq	%rdi, %rdi
	je	LBB0_10
## %bb.9:
	callq	_gpiod_get_value
	xorl	%ecx, %ecx
	testl	%eax, %eax
	setne	%cl
	movl	%ecx, -24(%rbp)
	movq	24(%rbx), %rax
LBB0_10:
	movq	_SOC_STAT_VS2@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	movq	(%rax,%rcx,8), %rdi
	testq	%rdi, %rdi
	je	LBB0_12
## %bb.11:
	callq	_gpiod_get_value
	xorl	%ecx, %ecx
	testl	%eax, %eax
	setne	%cl
	movl	%ecx, -20(%rbp)
LBB0_12:
	movq	16(%rbx), %rax
	leaq	-40(%rbp), %rsi
	movq	%rbx, %rdi
	callq	*(%rax)
	movl	-32(%rbp), %edx
	testl	%edx, %edx
	je	LBB0_14
## %bb.13:
	movq	_SS_DETECT@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
LBB0_14:
	movl	-28(%rbp), %eax
	testl	%eax, %eax
	je	LBB0_16
## %bb.15:
	movq	_SS_READY@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
LBB0_16:
	xorl	%ecx, %ecx
	cmpq	$0, -16(%rbp)
	movl	$0, %esi
	je	LBB0_18
## %bb.17:
	movq	_SS_WRPROT@GOTPCREL(%rip), %rsi
	movl	(%rsi), %esi
LBB0_18:
	movl	-24(%rbp), %edi
	testl	%edi, %edi
	je	LBB0_20
## %bb.19:
	movq	_SS_3VCARD@GOTPCREL(%rip), %rdi
	movl	(%rdi), %edi
LBB0_20:
	orl	%edi, %esi
	orl	%edx, %eax
	movl	-20(%rbp), %edx
	testl	%edx, %edx
	je	LBB0_22
## %bb.21:
	movq	_SS_XVCARD@GOTPCREL(%rip), %rdx
	movl	(%rdx), %edx
LBB0_22:
	orl	%esi, %eax
	cmpq	$0, 8(%rbx)
	je	LBB0_24
## %bb.23:
	movq	_SS_POWERON@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
LBB0_24:
	orl	%ecx, %edx
	orl	%edx, %eax
	movl	-40(%rbp), %ecx
	movq	_SS_IOCARD@GOTPCREL(%rip), %rdx
	movl	(%rdx), %edx
	testl	%edx, (%rbx)
	je	LBB0_28
## %bb.25:
	xorl	%edx, %edx
	testl	%ecx, %ecx
	jne	LBB0_27
## %bb.26:
	movq	_SS_STSCHG@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edx
LBB0_27:
	orl	%edx, %eax
	jmp	LBB0_33
LBB0_28:
	testl	%ecx, %ecx
	je	LBB0_29
## %bb.30:
	cmpl	$0, -36(%rbp)
	jne	LBB0_33
## %bb.31:
	movq	_SS_BATWARN@GOTPCREL(%rip), %rcx
	jmp	LBB0_32
LBB0_29:
	movq	_SS_BATDEAD@GOTPCREL(%rip), %rcx
LBB0_32:
	orl	(%rcx), %eax
LBB0_33:
	addq	$40, %rsp
	popq	%rbx
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_SOC_STAT_CD,8,3                ## @SOC_STAT_CD
	.comm	_SOC_STAT_RDY,8,3               ## @SOC_STAT_RDY
	.comm	_SOC_STAT_BVD1,8,3              ## @SOC_STAT_BVD1
	.comm	_SOC_STAT_BVD2,8,3              ## @SOC_STAT_BVD2
	.comm	_SOC_STAT_VS1,8,3               ## @SOC_STAT_VS1
	.comm	_SOC_STAT_VS2,8,3               ## @SOC_STAT_VS2
	.comm	_SS_DETECT,4,2                  ## @SS_DETECT
	.comm	_SS_READY,4,2                   ## @SS_READY
	.comm	_SS_WRPROT,4,2                  ## @SS_WRPROT
	.comm	_SS_3VCARD,4,2                  ## @SS_3VCARD
	.comm	_SS_XVCARD,4,2                  ## @SS_XVCARD
	.comm	_SS_POWERON,4,2                 ## @SS_POWERON
	.comm	_SS_IOCARD,4,2                  ## @SS_IOCARD
	.comm	_SS_STSCHG,4,2                  ## @SS_STSCHG
	.comm	_SS_BATDEAD,4,2                 ## @SS_BATDEAD
	.comm	_SS_BATWARN,4,2                 ## @SS_BATWARN
	.no_dead_strip	_soc_common_pcmcia_skt_state
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function soc_common_pcmcia_skt_state
_soc_common_pcmcia_skt_state:           ; @soc_common_pcmcia_skt_state
	.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	x0, sp
	mov	w1, #0
	mov	w2, #32
	bl	_memset
	movi.2s	v0, #1
	str	d0, [sp]
	ldr	x8, [x19, #24]
Lloh0:
	adrp	x9, _SOC_STAT_CD@GOTPAGE
Lloh1:
	ldr	x9, [x9, _SOC_STAT_CD@GOTPAGEOFF]
Lloh2:
	ldr	x9, [x9]
	ldr	x0, [x8, x9, lsl #3]
	cbz	x0, LBB0_2
; %bb.1:
	bl	_gpiod_get_value
	cmp	w0, #0
	cset	w8, ne
	str	w8, [sp, #8]
	ldr	x8, [x19, #24]
LBB0_2:
Lloh3:
	adrp	x9, _SOC_STAT_RDY@GOTPAGE
Lloh4:
	ldr	x9, [x9, _SOC_STAT_RDY@GOTPAGEOFF]
Lloh5:
	ldr	x9, [x9]
	ldr	x0, [x8, x9, lsl #3]
	cbz	x0, LBB0_4
; %bb.3:
	bl	_gpiod_get_value
	cmp	w0, #0
	cset	w8, ne
	str	w8, [sp, #12]
	ldr	x8, [x19, #24]
LBB0_4:
Lloh6:
	adrp	x9, _SOC_STAT_BVD1@GOTPAGE
Lloh7:
	ldr	x9, [x9, _SOC_STAT_BVD1@GOTPAGEOFF]
Lloh8:
	ldr	x9, [x9]
	ldr	x0, [x8, x9, lsl #3]
	cbz	x0, LBB0_6
; %bb.5:
	bl	_gpiod_get_value
	cmp	w0, #0
	cset	w8, ne
	str	w8, [sp]
	ldr	x8, [x19, #24]
LBB0_6:
Lloh9:
	adrp	x9, _SOC_STAT_BVD2@GOTPAGE
Lloh10:
	ldr	x9, [x9, _SOC_STAT_BVD2@GOTPAGEOFF]
Lloh11:
	ldr	x9, [x9]
	ldr	x0, [x8, x9, lsl #3]
	cbz	x0, LBB0_8
; %bb.7:
	bl	_gpiod_get_value
	cmp	w0, #0
	cset	w8, ne
	str	w8, [sp, #4]
	ldr	x8, [x19, #24]
LBB0_8:
Lloh12:
	adrp	x9, _SOC_STAT_VS1@GOTPAGE
Lloh13:
	ldr	x9, [x9, _SOC_STAT_VS1@GOTPAGEOFF]
Lloh14:
	ldr	x9, [x9]
	ldr	x0, [x8, x9, lsl #3]
	cbz	x0, LBB0_10
; %bb.9:
	bl	_gpiod_get_value
	cmp	w0, #0
	cset	w8, ne
	str	w8, [sp, #16]
	ldr	x8, [x19, #24]
LBB0_10:
Lloh15:
	adrp	x9, _SOC_STAT_VS2@GOTPAGE
Lloh16:
	ldr	x9, [x9, _SOC_STAT_VS2@GOTPAGEOFF]
Lloh17:
	ldr	x9, [x9]
	ldr	x0, [x8, x9, lsl #3]
	cbz	x0, LBB0_12
; %bb.11:
	bl	_gpiod_get_value
	cmp	w0, #0
	cset	w8, ne
	str	w8, [sp, #20]
LBB0_12:
	ldr	x8, [x19, #16]
	ldr	x8, [x8]
	mov	x1, sp
	mov	x0, x19
	blr	x8
Lloh18:
	adrp	x8, _SS_DETECT@GOTPAGE
Lloh19:
	ldr	x8, [x8, _SS_DETECT@GOTPAGEOFF]
Lloh20:
	ldr	w9, [x8]
	ldp	w10, w11, [sp, #8]
	ldr	w8, [sp]
	cmp	w10, #0
	csel	w9, wzr, w9, eq
Lloh21:
	adrp	x10, _SS_READY@GOTPAGE
Lloh22:
	ldr	x10, [x10, _SS_READY@GOTPAGEOFF]
Lloh23:
	ldr	w10, [x10]
	ldr	w12, [sp, #16]
	cmp	w11, #0
	csel	w10, wzr, w10, eq
	orr	w9, w10, w9
Lloh24:
	adrp	x10, _SS_WRPROT@GOTPAGE
Lloh25:
	ldr	x10, [x10, _SS_WRPROT@GOTPAGEOFF]
	ldr	x11, [sp, #24]
Lloh26:
	ldr	w10, [x10]
	cmp	x11, #0
	csel	w10, wzr, w10, eq
Lloh27:
	adrp	x11, _SS_3VCARD@GOTPAGE
Lloh28:
	ldr	x11, [x11, _SS_3VCARD@GOTPAGEOFF]
	orr	w9, w9, w10
Lloh29:
	ldr	w10, [x11]
	cmp	w12, #0
	csel	w10, wzr, w10, eq
	orr	w9, w9, w10
	ldr	w10, [sp, #20]
Lloh30:
	adrp	x11, _SS_XVCARD@GOTPAGE
Lloh31:
	ldr	x11, [x11, _SS_XVCARD@GOTPAGEOFF]
Lloh32:
	ldr	w11, [x11]
	cmp	w10, #0
	csel	w10, wzr, w11, eq
	orr	w9, w9, w10
	ldr	x10, [x19, #8]
	cmp	x10, #0
Lloh33:
	adrp	x10, _SS_POWERON@GOTPAGE
Lloh34:
	ldr	x10, [x10, _SS_POWERON@GOTPAGEOFF]
Lloh35:
	ldr	w10, [x10]
	csel	w10, wzr, w10, eq
	orr	w0, w9, w10
	ldr	w9, [x19]
Lloh36:
	adrp	x10, _SS_IOCARD@GOTPAGE
Lloh37:
	ldr	x10, [x10, _SS_IOCARD@GOTPAGEOFF]
Lloh38:
	ldr	w10, [x10]
	tst	w10, w9
	b.eq	LBB0_14
; %bb.13:
Lloh39:
	adrp	x9, _SS_STSCHG@GOTPAGE
Lloh40:
	ldr	x9, [x9, _SS_STSCHG@GOTPAGEOFF]
Lloh41:
	ldr	w9, [x9]
	cmp	w8, #0
	csel	w8, w9, wzr, eq
	b	LBB0_19
LBB0_14:
	cbz	w8, LBB0_17
; %bb.15:
	ldr	w8, [sp, #4]
	cbnz	w8, LBB0_20
; %bb.16:
Lloh42:
	adrp	x8, _SS_BATWARN@GOTPAGE
Lloh43:
	ldr	x8, [x8, _SS_BATWARN@GOTPAGEOFF]
	b	LBB0_18
LBB0_17:
Lloh44:
	adrp	x8, _SS_BATDEAD@GOTPAGE
Lloh45:
	ldr	x8, [x8, _SS_BATDEAD@GOTPAGEOFF]
LBB0_18:
	ldr	w8, [x8]
LBB0_19:
	orr	w0, w8, w0
LBB0_20:
	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
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh36, Lloh37, Lloh38
	.loh AdrpLdrGotLdr	Lloh33, Lloh34, Lloh35
	.loh AdrpLdrGotLdr	Lloh30, Lloh31, Lloh32
	.loh AdrpLdrGotLdr	Lloh27, Lloh28, Lloh29
	.loh AdrpLdrGotLdr	Lloh24, Lloh25, Lloh26
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh39, Lloh40, Lloh41
	.loh AdrpLdrGot	Lloh42, Lloh43
	.loh AdrpLdrGot	Lloh44, Lloh45
	.cfi_endproc
                                        ; -- End function
	.comm	_SOC_STAT_CD,8,3                ; @SOC_STAT_CD
	.comm	_SOC_STAT_RDY,8,3               ; @SOC_STAT_RDY
	.comm	_SOC_STAT_BVD1,8,3              ; @SOC_STAT_BVD1
	.comm	_SOC_STAT_BVD2,8,3              ; @SOC_STAT_BVD2
	.comm	_SOC_STAT_VS1,8,3               ; @SOC_STAT_VS1
	.comm	_SOC_STAT_VS2,8,3               ; @SOC_STAT_VS2
	.comm	_SS_DETECT,4,2                  ; @SS_DETECT
	.comm	_SS_READY,4,2                   ; @SS_READY
	.comm	_SS_WRPROT,4,2                  ; @SS_WRPROT
	.comm	_SS_3VCARD,4,2                  ; @SS_3VCARD
	.comm	_SS_XVCARD,4,2                  ; @SS_XVCARD
	.comm	_SS_POWERON,4,2                 ; @SS_POWERON
	.comm	_SS_IOCARD,4,2                  ; @SS_IOCARD
	.comm	_SS_STSCHG,4,2                  ; @SS_STSCHG
	.comm	_SS_BATDEAD,4,2                 ; @SS_BATDEAD
	.comm	_SS_BATWARN,4,2                 ; @SS_BATWARN
	.no_dead_strip	_soc_common_pcmcia_skt_state
.subsections_via_symbols
