	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function upstream_bridge_distance_warn
_upstream_bridge_distance_warn:         ## @upstream_bridge_distance_warn
	.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	$32, %rsp
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdx, %r12
	movq	%rsi, %r15
	movq	%rdi, %r14
	movq	_PAGE_SIZE@GOTPCREL(%rip), %rbx
	movl	(%rbx), %edi
	movq	_GFP_KERNEL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_kmalloc
	movl	(%rbx), %edx
	leaq	-56(%rbp), %rdi
	movl	%eax, %esi
	callq	_seq_buf_init
	cmpq	$0, -48(%rbp)
	je	LBB0_1
## %bb.2:
	leaq	-36(%rbp), %rcx
	leaq	-56(%rbp), %r8
	movq	%r14, %rdi
	movq	%r15, %rsi
	movq	%r12, %rdx
	callq	_upstream_bridge_distance
	movl	%eax, %ebx
	cmpl	$0, -36(%rbp)
	je	LBB0_4
## %bb.3:
	movq	%r14, %rdi
	callq	_pci_name
	leaq	L_.str(%rip), %rsi
	movq	%r15, %rdi
	movq	%rax, %rdx
	callq	_pci_warn
	movq	-48(%rbp), %rdx
	movslq	-56(%rbp), %rax
	movq	$0, -8(%rdx,%rax,8)
	leaq	L_.str.1(%rip), %rsi
	movq	%r15, %rdi
	callq	_pci_warn
LBB0_4:
	movq	_PCI_P2PDMA_MAP_NOT_SUPPORTED@GOTPCREL(%rip), %rax
	cmpl	(%rax), %ebx
	jne	LBB0_6
## %bb.5:
	movq	%r14, %rdi
	callq	_pci_name
	leaq	L_.str.2(%rip), %rsi
	movq	%r15, %rdi
	movq	%rax, %rdx
	callq	_pci_warn
LBB0_6:
	movq	-48(%rbp), %rdi
	callq	_kfree
	jmp	LBB0_7
LBB0_1:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
LBB0_7:
	movl	%ebx, %eax
	addq	$32, %rsp
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_PAGE_SIZE,4,2                  ## @PAGE_SIZE
	.comm	_GFP_KERNEL,4,2                 ## @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"ACS redirect is set between the client and provider (%s)\n"

L_.str.1:                               ## @.str.1
	.asciz	"to disable ACS redirect for this path, add the kernel parameter: pci=disable_acs_redir=%s\n"

	.comm	_PCI_P2PDMA_MAP_NOT_SUPPORTED,4,2 ## @PCI_P2PDMA_MAP_NOT_SUPPORTED
L_.str.2:                               ## @.str.2
	.asciz	"cannot be used for peer-to-peer DMA as the client and provider (%s) do not share an upstream bridge or whitelisted host bridge\n"

	.no_dead_strip	_upstream_bridge_distance_warn
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function upstream_bridge_distance_warn
_upstream_bridge_distance_warn:         ; @upstream_bridge_distance_warn
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #80
	.cfi_def_cfa_offset 80
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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	x21, x2
	mov	x19, x1
	mov	x20, x0
Lloh0:
	adrp	x22, _PAGE_SIZE@GOTPAGE
Lloh1:
	ldr	x22, [x22, _PAGE_SIZE@GOTPAGEOFF]
	ldr	w0, [x22]
Lloh2:
	adrp	x8, _GFP_KERNEL@GOTPAGE
Lloh3:
	ldr	x8, [x8, _GFP_KERNEL@GOTPAGEOFF]
Lloh4:
	ldr	w1, [x8]
	bl	_kmalloc
	mov	x1, x0
	ldr	w2, [x22]
	add	x0, sp, #16
	bl	_seq_buf_init
	ldr	x8, [sp, #24]
	cbz	x8, LBB0_6
; %bb.1:
	add	x3, sp, #12
	add	x4, sp, #16
	mov	x0, x20
	mov	x1, x19
	mov	x2, x21
	bl	_upstream_bridge_distance
	mov	x21, x0
	ldr	w8, [sp, #12]
	cbz	w8, LBB0_3
; %bb.2:
	mov	x0, x20
	bl	_pci_name
	mov	x2, x0
Lloh5:
	adrp	x1, l_.str@PAGE
Lloh6:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x19
	bl	_pci_warn
	ldr	x2, [sp, #24]
	ldrsw	x8, [sp, #16]
	add	x8, x2, x8, lsl #3
	stur	xzr, [x8, #-8]
Lloh7:
	adrp	x1, l_.str.1@PAGE
Lloh8:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x0, x19
	bl	_pci_warn
LBB0_3:
Lloh9:
	adrp	x8, _PCI_P2PDMA_MAP_NOT_SUPPORTED@GOTPAGE
Lloh10:
	ldr	x8, [x8, _PCI_P2PDMA_MAP_NOT_SUPPORTED@GOTPAGEOFF]
Lloh11:
	ldr	w8, [x8]
	cmp	w21, w8
	b.ne	LBB0_5
; %bb.4:
	mov	x0, x20
	bl	_pci_name
	mov	x2, x0
Lloh12:
	adrp	x1, l_.str.2@PAGE
Lloh13:
	add	x1, x1, l_.str.2@PAGEOFF
	mov	x0, x19
	bl	_pci_warn
LBB0_5:
	ldr	x0, [sp, #24]
	bl	_kfree
	b	LBB0_7
LBB0_6:
Lloh14:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh15:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh16:
	ldr	w8, [x8]
	neg	w21, w8
LBB0_7:
	mov	x0, x21
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #80
	ret
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpAdd	Lloh7, Lloh8
	.loh AdrpAdd	Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.cfi_endproc
                                        ; -- End function
	.comm	_PAGE_SIZE,4,2                  ; @PAGE_SIZE
	.comm	_GFP_KERNEL,4,2                 ; @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"ACS redirect is set between the client and provider (%s)\n"

l_.str.1:                               ; @.str.1
	.asciz	"to disable ACS redirect for this path, add the kernel parameter: pci=disable_acs_redir=%s\n"

	.comm	_PCI_P2PDMA_MAP_NOT_SUPPORTED,4,2 ; @PCI_P2PDMA_MAP_NOT_SUPPORTED
l_.str.2:                               ; @.str.2
	.asciz	"cannot be used for peer-to-peer DMA as the client and provider (%s) do not share an upstream bridge or whitelisted host bridge\n"

	.no_dead_strip	_upstream_bridge_distance_warn
.subsections_via_symbols
