	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function mxl111sf_get_gpi_state
_mxl111sf_get_gpi_state:                ## @mxl111sf_get_gpi_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	%r15
	pushq	%r14
	pushq	%rbx
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdx, %r14
	movl	%esi, %ebx
	movq	%rdi, %r15
	leaq	L_.str(%rip), %rdi
	callq	_mxl_debug
	movl	$0, (%r14)
	cmpl	$10, %ebx
	ja	LBB0_10
## %bb.1:
	movl	$15, %eax
	btl	%ebx, %eax
	jb	LBB0_5
## %bb.2:
	movl	$240, %eax
	leaq	-28(%rbp), %rdx
	movq	%r15, %rdi
	btl	%ebx, %eax
	jae	LBB0_8
## %bb.3:
	movl	$47, %esi
	callq	_mxl111sf_read_reg
	movl	%eax, %r15d
	movl	%eax, %edi
	callq	_mxl_fail
	testl	%eax, %eax
	jne	LBB0_11
## %bb.4:
	movl	-28(%rbp), %eax
	xorl	%ecx, %ecx
	btl	%ebx, %eax
	setb	%cl
	movl	%ecx, (%r14)
	jmp	LBB0_11
LBB0_5:
	leaq	-28(%rbp), %rdx
	movq	%r15, %rdi
	movl	$35, %esi
	callq	_mxl111sf_read_reg
	movl	%eax, %r15d
	movl	%eax, %edi
	callq	_mxl_fail
	testl	%eax, %eax
	jne	LBB0_11
## %bb.6:
	movl	-28(%rbp), %eax
	addb	$4, %bl
	jmp	LBB0_7
LBB0_8:
	movl	$34, %esi
	callq	_mxl111sf_read_reg
	movl	%eax, %r15d
	movl	%eax, %edi
	callq	_mxl_fail
	testl	%eax, %eax
	jne	LBB0_11
## %bb.9:
	movl	-28(%rbp), %eax
	addb	$-3, %bl
LBB0_7:
	movzbl	%bl, %ecx
	xorl	%edx, %edx
	btl	%ecx, %eax
	setb	%dl
	movl	%edx, (%r14)
	jmp	LBB0_11
LBB0_10:
	movq	_EINVAL@GOTPCREL(%rip), %rax
	xorl	%r15d, %r15d
	subl	(%rax), %r15d
LBB0_11:
	movl	%r15d, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"(0x%02x)"

	.comm	_EINVAL,4,2                     ## @EINVAL
	.no_dead_strip	_mxl111sf_get_gpi_state
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function mxl111sf_get_gpi_state
_mxl111sf_get_gpi_state:                ; @mxl111sf_get_gpi_state
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	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
	.cfi_offset w21, -40
	.cfi_offset w22, -48
	mov	x19, x2
	mov	x20, x1
	mov	x21, x0
Lloh0:
	adrp	x0, l_.str@PAGE
Lloh1:
	add	x0, x0, l_.str@PAGEOFF
	bl	_mxl_debug
	str	wzr, [x19]
	cmp	w20, #10
	b.hi	LBB0_11
; %bb.1:
	mov	w8, #1
	lsl	w8, w8, w20
	add	x2, sp, #12
	mov	x0, x21
	tst	w8, #0xf
	b.ne	LBB0_5
; %bb.2:
	tst	w8, #0xf0
	b.eq	LBB0_7
; %bb.3:
	mov	w1, #47
	bl	_mxl111sf_read_reg
	mov	x21, x0
	bl	_mxl_fail
	cbnz	w0, LBB0_12
; %bb.4:
	ldr	w8, [sp, #12]
	lsr	w8, w8, w20
	b	LBB0_10
LBB0_5:
	mov	w1, #35
	bl	_mxl111sf_read_reg
	mov	x21, x0
	bl	_mxl_fail
	cbnz	w0, LBB0_12
; %bb.6:
	ldr	w8, [sp, #12]
	add	w9, w20, #4
	b	LBB0_9
LBB0_7:
	mov	w1, #34
	bl	_mxl111sf_read_reg
	mov	x21, x0
	bl	_mxl_fail
	cbnz	w0, LBB0_12
; %bb.8:
	ldr	w8, [sp, #12]
	sub	w9, w20, #3
LBB0_9:
	lsr	w8, w8, w9
LBB0_10:
	and	w8, w8, #0x1
	str	w8, [x19]
	b	LBB0_12
LBB0_11:
Lloh2:
	adrp	x8, _EINVAL@GOTPAGE
Lloh3:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh4:
	ldr	w8, [x8]
	neg	w21, w8
LBB0_12:
	mov	x0, x21
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #64
	ret
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"(0x%02x)"

	.comm	_EINVAL,4,2                     ; @EINVAL
	.no_dead_strip	_mxl111sf_get_gpi_state
.subsections_via_symbols
