	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function cs5520_set_pio_mode
_cs5520_set_pio_mode:                   ## @cs5520_set_pio_mode
	.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	%r13
	pushq	%r12
	pushq	%rbx
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %r15
	movl	(%rdi), %edi
	callq	_to_pci_dev
	xorl	%r12d, %r12d
	cmpl	$2, (%r15)
	setge	%r12b
	movq	8(%r15), %rbx
	movq	_XFER_PIO_0@GOTPCREL(%rip), %rcx
	subq	(%rcx), %rbx
	movq	%rax, %r14
	leal	98(%r12), %esi
	movq	_cs5520_pio_clocks@GOTPCREL(%rip), %r13
	movq	(%r13), %rax
	movl	(%rax,%rbx,8), %edx
	shll	$4, %edx
	orl	4(%rax,%rbx,8), %edx
	movq	%r14, %rdi
	callq	_pci_write_config_byte
	movl	(%r15), %eax
	andl	$1, %eax
	leal	(%rax,%r12,4), %esi
	addl	$100, %esi
	movq	(%r13), %rax
	movl	(%rax,%rbx,8), %edx
	shll	$4, %edx
	orl	4(%rax,%rbx,8), %edx
	movq	%r14, %rdi
	callq	_pci_write_config_byte
	movl	(%r15), %eax
	andl	$1, %eax
	leal	(%rax,%r12,4), %esi
	addl	$102, %esi
	movq	(%r13), %rax
	movl	(%rax,%rbx,8), %edx
	shll	$4, %edx
	orl	4(%rax,%rbx,8), %edx
	movq	%r14, %rdi
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_pci_write_config_byte          ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_XFER_PIO_0,8,3                 ## @XFER_PIO_0
	.comm	_cs5520_pio_clocks,8,3          ## @cs5520_pio_clocks
	.no_dead_strip	_cs5520_set_pio_mode
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function cs5520_set_pio_mode
_cs5520_set_pio_mode:                   ; @cs5520_set_pio_mode
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.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
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	mov	x19, x1
	ldr	w0, [x0]
	bl	_to_pci_dev
	mov	x20, x0
	ldr	w8, [x19]
	ldr	x9, [x19, #8]
Lloh0:
	adrp	x10, _XFER_PIO_0@GOTPAGE
Lloh1:
	ldr	x10, [x10, _XFER_PIO_0@GOTPAGEOFF]
Lloh2:
	ldr	x10, [x10]
	sub	x9, x9, x10
	cmp	w8, #1
	cset	w21, gt
	mov	w8, #98
	cinc	w1, w8, gt
Lloh3:
	adrp	x22, _cs5520_pio_clocks@GOTPAGE
Lloh4:
	ldr	x22, [x22, _cs5520_pio_clocks@GOTPAGEOFF]
	ldr	x8, [x22]
	lsl	x23, x9, #3
	add	x8, x8, x23
	ldp	w9, w8, [x8]
	orr	w2, w8, w9, lsl #4
	bl	_pci_write_config_byte
	ldr	w8, [x19]
	and	w8, w8, #0x1
	bfi	w8, w21, #2, #1
	add	w1, w8, #100
	ldr	x8, [x22]
	add	x8, x8, x23
	ldp	w9, w8, [x8]
	orr	w2, w8, w9, lsl #4
	mov	x0, x20
	bl	_pci_write_config_byte
	ldr	w8, [x19]
	and	w8, w8, #0x1
	bfi	w8, w21, #2, #1
	add	w1, w8, #102
	ldr	x8, [x22]
	add	x8, x8, x23
	ldp	w9, w8, [x8]
	orr	w2, w8, w9, lsl #4
	mov	x0, x20
	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
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	b	_pci_write_config_byte
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.cfi_endproc
                                        ; -- End function
	.comm	_XFER_PIO_0,8,3                 ; @XFER_PIO_0
	.comm	_cs5520_pio_clocks,8,3          ; @cs5520_pio_clocks
	.no_dead_strip	_cs5520_set_pio_mode
.subsections_via_symbols
