	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function __pci_set_master
___pci_set_master:                      ## @__pci_set_master
	.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	%r12
	pushq	%rbx
	subq	$16, %rsp
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%esi, %r14d
	movq	%rdi, %r15
	movq	_PCI_COMMAND@GOTPCREL(%rip), %r12
	movl	(%r12), %esi
	leaq	-36(%rbp), %rdx
	callq	_pci_read_config_word
	movl	-36(%rbp), %eax
	movq	_PCI_COMMAND_MASTER@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ebx
	movl	%ebx, %ecx
	orl	%eax, %ecx
	notl	%ebx
	andl	%eax, %ebx
	testl	%r14d, %r14d
	cmovnel	%ecx, %ebx
	cmpl	%eax, %ebx
	je	LBB0_2
## %bb.1:
	testl	%r14d, %r14d
	leaq	L_.str.2(%rip), %rax
	leaq	L_.str.1(%rip), %rdx
	cmoveq	%rax, %rdx
	leaq	L_.str(%rip), %rsi
	movq	%r15, %rdi
	callq	_pci_dbg
	movl	(%r12), %esi
	movq	%r15, %rdi
	movl	%ebx, %edx
	callq	_pci_write_config_word
LBB0_2:
	movl	%r14d, (%r15)
	addq	$16, %rsp
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_PCI_COMMAND,4,2                ## @PCI_COMMAND
	.comm	_PCI_COMMAND_MASTER,4,2         ## @PCI_COMMAND_MASTER
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"%s bus mastering\n"

L_.str.1:                               ## @.str.1
	.asciz	"enabling"

L_.str.2:                               ## @.str.2
	.asciz	"disabling"

	.no_dead_strip	___pci_set_master
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function __pci_set_master
___pci_set_master:                      ; @__pci_set_master
	.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, x1
	mov	x20, x0
Lloh0:
	adrp	x22, _PCI_COMMAND@GOTPAGE
Lloh1:
	ldr	x22, [x22, _PCI_COMMAND@GOTPAGEOFF]
	ldr	w1, [x22]
	add	x2, sp, #12
	bl	_pci_read_config_word
	ldr	w8, [sp, #12]
Lloh2:
	adrp	x9, _PCI_COMMAND_MASTER@GOTPAGE
Lloh3:
	ldr	x9, [x9, _PCI_COMMAND_MASTER@GOTPAGEOFF]
Lloh4:
	ldr	w9, [x9]
	orr	w10, w9, w8
	bic	w9, w8, w9
	cmp	w19, #0
	csel	w21, w9, w10, eq
	cmp	w21, w8
	b.eq	LBB0_2
; %bb.1:
Lloh5:
	adrp	x8, l_.str.1@PAGE
Lloh6:
	add	x8, x8, l_.str.1@PAGEOFF
Lloh7:
	adrp	x9, l_.str.2@PAGE
Lloh8:
	add	x9, x9, l_.str.2@PAGEOFF
	cmp	w19, #0
	csel	x2, x9, x8, eq
Lloh9:
	adrp	x1, l_.str@PAGE
Lloh10:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x20
	bl	_pci_dbg
	ldr	w1, [x22]
	mov	x0, x20
	mov	x2, x21
	bl	_pci_write_config_word
LBB0_2:
	str	w19, [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
	add	sp, sp, #64
	ret
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpAdd	Lloh9, Lloh10
	.loh AdrpAdd	Lloh7, Lloh8
	.loh AdrpAdd	Lloh5, Lloh6
	.cfi_endproc
                                        ; -- End function
	.comm	_PCI_COMMAND,4,2                ; @PCI_COMMAND
	.comm	_PCI_COMMAND_MASTER,4,2         ; @PCI_COMMAND_MASTER
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"%s bus mastering\n"

l_.str.1:                               ; @.str.1
	.asciz	"enabling"

l_.str.2:                               ; @.str.2
	.asciz	"disabling"

	.no_dead_strip	___pci_set_master
.subsections_via_symbols
