	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function pci_vc_load_arb_table
_pci_vc_load_arb_table:                 ## @pci_vc_load_arb_table
	.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	%rdi, %r14
	movslq	%esi, %rbx
	movq	_PCI_VC_PORT_CTRL@GOTPCREL(%rip), %r15
	movq	(%r15), %rsi
	addq	%rbx, %rsi
	leaq	-28(%rbp), %rdx
	callq	_pci_read_config_word
	movq	(%r15), %rsi
	addq	%rbx, %rsi
	movq	_PCI_VC_PORT_CTRL_LOAD_TABLE@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	orl	-28(%rbp), %edx
	movq	%r14, %rdi
	callq	_pci_write_config_word
	movq	_PCI_VC_PORT_STATUS@GOTPCREL(%rip), %rax
	addq	(%rax), %rbx
	movq	_PCI_VC_PORT_STATUS_TABLE@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r14, %rdi
	movq	%rbx, %rsi
	callq	_pci_wait_for_pending
	testq	%rax, %rax
	jne	LBB0_2
## %bb.1:
	leaq	L_.str(%rip), %rsi
	movq	%r14, %rdi
	callq	_pci_err
LBB0_2:
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_PCI_VC_PORT_CTRL,8,3           ## @PCI_VC_PORT_CTRL
	.comm	_PCI_VC_PORT_CTRL_LOAD_TABLE,4,2 ## @PCI_VC_PORT_CTRL_LOAD_TABLE
	.comm	_PCI_VC_PORT_STATUS,8,3         ## @PCI_VC_PORT_STATUS
	.comm	_PCI_VC_PORT_STATUS_TABLE,4,2   ## @PCI_VC_PORT_STATUS_TABLE
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"VC arbitration table failed to load\n"

	.no_dead_strip	_pci_vc_load_arb_table
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function pci_vc_load_arb_table
_pci_vc_load_arb_table:                 ; @pci_vc_load_arb_table
	.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
                                        ; kill: def $w1 killed $w1 def $x1
	mov	x19, x0
	sxtw	x20, w1
Lloh0:
	adrp	x21, _PCI_VC_PORT_CTRL@GOTPAGE
Lloh1:
	ldr	x21, [x21, _PCI_VC_PORT_CTRL@GOTPAGEOFF]
	ldr	x8, [x21]
	add	x1, x8, x20
	add	x2, sp, #12
	bl	_pci_read_config_word
	ldr	x8, [x21]
	add	x1, x8, x20
	ldr	w8, [sp, #12]
Lloh2:
	adrp	x9, _PCI_VC_PORT_CTRL_LOAD_TABLE@GOTPAGE
Lloh3:
	ldr	x9, [x9, _PCI_VC_PORT_CTRL_LOAD_TABLE@GOTPAGEOFF]
Lloh4:
	ldr	w9, [x9]
	orr	w2, w9, w8
	mov	x0, x19
	bl	_pci_write_config_word
Lloh5:
	adrp	x8, _PCI_VC_PORT_STATUS@GOTPAGE
Lloh6:
	ldr	x8, [x8, _PCI_VC_PORT_STATUS@GOTPAGEOFF]
Lloh7:
	ldr	x8, [x8]
	add	x1, x8, x20
Lloh8:
	adrp	x8, _PCI_VC_PORT_STATUS_TABLE@GOTPAGE
Lloh9:
	ldr	x8, [x8, _PCI_VC_PORT_STATUS_TABLE@GOTPAGEOFF]
Lloh10:
	ldr	w2, [x8]
	mov	x0, x19
	bl	_pci_wait_for_pending
	cbnz	x0, LBB0_2
; %bb.1:
Lloh11:
	adrp	x1, l_.str@PAGE
Lloh12:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x19
	bl	_pci_err
LBB0_2:
	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 AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpAdd	Lloh11, Lloh12
	.cfi_endproc
                                        ; -- End function
	.comm	_PCI_VC_PORT_CTRL,8,3           ; @PCI_VC_PORT_CTRL
	.comm	_PCI_VC_PORT_CTRL_LOAD_TABLE,4,2 ; @PCI_VC_PORT_CTRL_LOAD_TABLE
	.comm	_PCI_VC_PORT_STATUS,8,3         ; @PCI_VC_PORT_STATUS
	.comm	_PCI_VC_PORT_STATUS_TABLE,4,2   ; @PCI_VC_PORT_STATUS_TABLE
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"VC arbitration table failed to load\n"

	.no_dead_strip	_pci_vc_load_arb_table
.subsections_via_symbols
