	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function sdhci_allocate_bounce_buffer
_sdhci_allocate_bounce_buffer:          ## @sdhci_allocate_bounce_buffer
	.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
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r15
	movq	16(%rdi), %r14
	movq	_SZ_64K@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	movl	(%r14), %eax
	movl	12(%r14), %edi
	cmpl	%ebx, %eax
	cmovbl	%eax, %ebx
	movq	_GFP_KERNEL@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movl	%ebx, %esi
	callq	_devm_kmalloc
	movl	%eax, 8(%r15)
	testl	%eax, %eax
	je	LBB0_3
## %bb.1:
	movl	12(%r14), %edi
	movq	_DMA_BIDIRECTIONAL@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	movl	%eax, %esi
	movl	%ebx, %edx
	callq	_dma_map_single
	movl	%eax, 4(%r15)
	movl	12(%r14), %edi
	movl	%eax, %esi
	callq	_dma_mapping_error
	testl	%eax, %eax
	je	LBB0_4
## %bb.2:
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_3:
	movq	%r14, %rdi
	callq	_mmc_hostname
	leaq	L_.str(%rip), %rdi
	movl	%eax, %esi
	movl	%ebx, %edx
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_pr_err                         ## TAILCALL
LBB0_4:
	movl	%ebx, %r12d
	shrl	$9, %r12d
	movl	%ebx, (%r15)
	movl	%r12d, 4(%r14)
	movl	%ebx, 8(%r14)
	movl	%ebx, (%r14)
	movq	%r14, %rdi
	callq	_mmc_hostname
	leaq	L_.str.1(%rip), %rdi
	movl	%eax, %esi
	movl	%r12d, %edx
	movl	%ebx, %ecx
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_pr_info                        ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_SZ_64K,4,2                     ## @SZ_64K
	.comm	_GFP_KERNEL,4,2                 ## @GFP_KERNEL
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"%s: failed to allocate %u bytes for bounce buffer, falling back to single segments\n"

	.comm	_DMA_BIDIRECTIONAL,4,2          ## @DMA_BIDIRECTIONAL
L_.str.1:                               ## @.str.1
	.asciz	"%s bounce up to %u segments into one, max segment size %u bytes\n"

	.no_dead_strip	_sdhci_allocate_bounce_buffer
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function sdhci_allocate_bounce_buffer
_sdhci_allocate_bounce_buffer:          ; @sdhci_allocate_bounce_buffer
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.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, x0
	ldr	x20, [x0, #16]
Lloh0:
	adrp	x8, _SZ_64K@GOTPAGE
Lloh1:
	ldr	x8, [x8, _SZ_64K@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	ldr	w9, [x20]
	cmp	w9, w8
	csel	w19, w9, w8, lo
	ldr	w0, [x20, #12]
Lloh3:
	adrp	x8, _GFP_KERNEL@GOTPAGE
Lloh4:
	ldr	x8, [x8, _GFP_KERNEL@GOTPAGEOFF]
Lloh5:
	ldr	w2, [x8]
	mov	x1, x19
	bl	_devm_kmalloc
	str	w0, [x21, #8]
	cbz	w0, LBB0_3
; %bb.1:
	mov	x1, x0
	ldr	w0, [x20, #12]
Lloh6:
	adrp	x8, _DMA_BIDIRECTIONAL@GOTPAGE
Lloh7:
	ldr	x8, [x8, _DMA_BIDIRECTIONAL@GOTPAGEOFF]
Lloh8:
	ldr	w3, [x8]
	mov	x2, x19
	bl	_dma_map_single
	mov	x1, x0
	str	w0, [x21, #4]
	ldr	w0, [x20, #12]
	bl	_dma_mapping_error
	cbz	w0, LBB0_4
; %bb.2:
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	ret
LBB0_3:
	mov	x0, x20
	bl	_mmc_hostname
	mov	x1, x0
Lloh9:
	adrp	x0, l_.str@PAGE
Lloh10:
	add	x0, x0, l_.str@PAGEOFF
	mov	x2, x19
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	b	_pr_err
LBB0_4:
	str	w19, [x21]
	lsr	w21, w19, #9
	stp	w21, w19, [x20, #4]
	str	w19, [x20]
	mov	x0, x20
	bl	_mmc_hostname
	mov	x1, x0
Lloh11:
	adrp	x0, l_.str.1@PAGE
Lloh12:
	add	x0, x0, l_.str.1@PAGEOFF
	mov	x2, x21
	mov	x3, x19
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	b	_pr_info
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpAdd	Lloh9, Lloh10
	.loh AdrpAdd	Lloh11, Lloh12
	.cfi_endproc
                                        ; -- End function
	.comm	_SZ_64K,4,2                     ; @SZ_64K
	.comm	_GFP_KERNEL,4,2                 ; @GFP_KERNEL
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"%s: failed to allocate %u bytes for bounce buffer, falling back to single segments\n"

	.comm	_DMA_BIDIRECTIONAL,4,2          ; @DMA_BIDIRECTIONAL
l_.str.1:                               ; @.str.1
	.asciz	"%s bounce up to %u segments into one, max segment size %u bytes\n"

	.no_dead_strip	_sdhci_allocate_bounce_buffer
.subsections_via_symbols
