	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	___sdhci_add_host               ## -- Begin function __sdhci_add_host
	.p2align	4, 0x90
___sdhci_add_host:                      ## @__sdhci_add_host
	.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	%rdi, %rbx
	movq	_WQ_UNBOUND@GOTPCREL(%rip), %rax
	movq	_WQ_MEM_RECLAIM@GOTPCREL(%rip), %rcx
	movl	(%rcx), %esi
	orl	(%rax), %esi
	movq	_WQ_HIGHPRI@GOTPCREL(%rip), %rax
	orl	(%rax), %esi
	movq	32(%rdi), %r12
	leaq	L_.str(%rip), %rdi
	xorl	%r14d, %r14d
	xorl	%edx, %edx
	callq	_alloc_workqueue
	movl	%eax, 4(%rbx)
	testl	%eax, %eax
	je	LBB0_1
## %bb.2:
	leaq	28(%rbx), %rdi
	movq	_sdhci_complete_work@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_INIT_WORK
	leaq	24(%rbx), %rdi
	movq	_sdhci_timeout_timer@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	xorl	%edx, %edx
	callq	_timer_setup
	leaq	20(%rbx), %rdi
	movq	_sdhci_timeout_data_timer@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	xorl	%edx, %edx
	callq	_timer_setup
	leaq	16(%rbx), %rdi
	callq	_init_waitqueue_head
	movq	%rbx, %rdi
	xorl	%esi, %esi
	callq	_sdhci_init
	movl	8(%rbx), %eax
	movl	%eax, -44(%rbp)                 ## 4-byte Spill
	movq	_sdhci_irq@GOTPCREL(%rip), %rax
	movl	(%rax), %r14d
	movq	_sdhci_thread_irq@GOTPCREL(%rip), %rax
	movl	(%rax), %r13d
	movq	_IRQF_SHARED@GOTPCREL(%rip), %rax
	movl	(%rax), %r15d
	movq	%r12, %rdi
	callq	_mmc_hostname
	movl	-44(%rbp), %edi                 ## 4-byte Reload
	movl	%r14d, %esi
	movl	%r13d, %edx
	movl	%r15d, %ecx
	movl	%eax, %r8d
	movq	%rbx, %r9
	callq	_request_threaded_irq
	testl	%eax, %eax
	je	LBB0_4
## %bb.3:
	movl	%eax, %r14d
	movq	%r12, %rdi
	callq	_mmc_hostname
	movl	8(%rbx), %edx
	leaq	L_.str.1(%rip), %rdi
	movl	%eax, %esi
	movl	%r14d, %ecx
	xorl	%eax, %eax
	callq	_pr_err
	jmp	LBB0_13
LBB0_1:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	subl	(%rax), %r14d
	jmp	LBB0_14
LBB0_4:
	movq	%rbx, %rdi
	callq	_sdhci_led_register
	testl	%eax, %eax
	je	LBB0_6
## %bb.5:
	movl	%eax, %r14d
	movq	%r12, %rdi
	callq	_mmc_hostname
	leaq	L_.str.2(%rip), %rdi
	movl	%eax, %esi
	movl	%r14d, %edx
	xorl	%eax, %eax
	callq	_pr_err
	jmp	LBB0_12
LBB0_6:
	movq	%r12, %r15
	movq	%r12, %rdi
	callq	_mmc_add_host
	testl	%eax, %eax
	je	LBB0_7
## %bb.11:
	movl	%eax, %r14d
	movq	%rbx, %rdi
	callq	_sdhci_led_unregister
LBB0_12:
	movq	_SDHCI_RESET_ALL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdi
	callq	_sdhci_do_reset
	movq	_SDHCI_INT_ENABLE@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%rbx, %rdi
	xorl	%esi, %esi
	callq	_sdhci_writel
	movq	_SDHCI_SIGNAL_ENABLE@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%rbx, %rdi
	xorl	%esi, %esi
	callq	_sdhci_writel
	movl	8(%rbx), %edi
	movq	%rbx, %rsi
	callq	_free_irq
LBB0_13:
	movl	4(%rbx), %edi
	callq	_destroy_workqueue
LBB0_14:
	movl	%r14d, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_7:
	movq	%r15, %rdi
	callq	_mmc_hostname
	movl	%eax, %r14d
	movl	12(%rbx), %r12d
	movq	%r15, %rdi
	callq	_mmc_dev
	movl	%eax, %edi
	callq	_dev_name
	movl	(%rbx), %ecx
	movq	_SDHCI_USE_ADMA@GOTPCREL(%rip), %rdx
	testl	%ecx, (%rdx)
	je	LBB0_9
## %bb.8:
	movq	_SDHCI_USE_64_BIT_DMA@GOTPCREL(%rip), %rdx
	testl	%ecx, (%rdx)
	leaq	L_.str.5(%rip), %rcx
	leaq	L_.str.4(%rip), %r8
	jmp	LBB0_10
LBB0_9:
	movq	_SDHCI_USE_SDMA@GOTPCREL(%rip), %rdx
	testl	%ecx, (%rdx)
	leaq	L_.str.7(%rip), %rcx
	leaq	L_.str.6(%rip), %r8
LBB0_10:
	cmoveq	%rcx, %r8
	leaq	L_.str.3(%rip), %rdi
	movl	%r14d, %esi
	movl	%r12d, %edx
	movl	%eax, %ecx
	callq	_pr_info
	movq	%rbx, %rdi
	callq	_sdhci_enable_card_detection
	xorl	%r14d, %r14d
	jmp	LBB0_14
	.cfi_endproc
                                        ## -- End function
	.comm	_WQ_UNBOUND,4,2                 ## @WQ_UNBOUND
	.comm	_WQ_MEM_RECLAIM,4,2             ## @WQ_MEM_RECLAIM
	.comm	_WQ_HIGHPRI,4,2                 ## @WQ_HIGHPRI
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"sdhci"

	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.comm	_sdhci_complete_work,4,2        ## @sdhci_complete_work
	.comm	_sdhci_timeout_timer,4,2        ## @sdhci_timeout_timer
	.comm	_sdhci_timeout_data_timer,4,2   ## @sdhci_timeout_data_timer
	.comm	_sdhci_irq,4,2                  ## @sdhci_irq
	.comm	_sdhci_thread_irq,4,2           ## @sdhci_thread_irq
	.comm	_IRQF_SHARED,4,2                ## @IRQF_SHARED
L_.str.1:                               ## @.str.1
	.asciz	"%s: Failed to request IRQ %d: %d\n"

L_.str.2:                               ## @.str.2
	.asciz	"%s: Failed to register LED device: %d\n"

L_.str.3:                               ## @.str.3
	.asciz	"%s: SDHCI controller on %s [%s] using %s\n"

	.comm	_SDHCI_USE_ADMA,4,2             ## @SDHCI_USE_ADMA
	.comm	_SDHCI_USE_64_BIT_DMA,4,2       ## @SDHCI_USE_64_BIT_DMA
L_.str.4:                               ## @.str.4
	.asciz	"ADMA 64-bit"

L_.str.5:                               ## @.str.5
	.asciz	"ADMA"

	.comm	_SDHCI_USE_SDMA,4,2             ## @SDHCI_USE_SDMA
L_.str.6:                               ## @.str.6
	.asciz	"DMA"

L_.str.7:                               ## @.str.7
	.asciz	"PIO"

	.comm	_SDHCI_RESET_ALL,4,2            ## @SDHCI_RESET_ALL
	.comm	_SDHCI_INT_ENABLE,4,2           ## @SDHCI_INT_ENABLE
	.comm	_SDHCI_SIGNAL_ENABLE,4,2        ## @SDHCI_SIGNAL_ENABLE
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	___sdhci_add_host               ; -- Begin function __sdhci_add_host
	.p2align	2
___sdhci_add_host:                      ; @__sdhci_add_host
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #80
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	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
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	mov	x19, x0
Lloh0:
	adrp	x8, _WQ_UNBOUND@GOTPAGE
Lloh1:
	ldr	x8, [x8, _WQ_UNBOUND@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
Lloh3:
	adrp	x9, _WQ_MEM_RECLAIM@GOTPAGE
Lloh4:
	ldr	x9, [x9, _WQ_MEM_RECLAIM@GOTPAGEOFF]
Lloh5:
	ldr	w9, [x9]
	orr	w8, w9, w8
Lloh6:
	adrp	x9, _WQ_HIGHPRI@GOTPAGE
Lloh7:
	ldr	x9, [x9, _WQ_HIGHPRI@GOTPAGEOFF]
Lloh8:
	ldr	w9, [x9]
	orr	w1, w8, w9
	ldr	x20, [x0, #32]
Lloh9:
	adrp	x0, l_.str@PAGE
Lloh10:
	add	x0, x0, l_.str@PAGEOFF
	mov	w2, #0
	bl	_alloc_workqueue
	str	w0, [x19, #4]
	cbz	w0, LBB0_3
; %bb.1:
	add	x0, x19, #28
Lloh11:
	adrp	x8, _sdhci_complete_work@GOTPAGE
Lloh12:
	ldr	x8, [x8, _sdhci_complete_work@GOTPAGEOFF]
Lloh13:
	ldr	w1, [x8]
	bl	_INIT_WORK
	add	x0, x19, #24
Lloh14:
	adrp	x8, _sdhci_timeout_timer@GOTPAGE
Lloh15:
	ldr	x8, [x8, _sdhci_timeout_timer@GOTPAGEOFF]
Lloh16:
	ldr	w1, [x8]
	mov	w2, #0
	bl	_timer_setup
	add	x0, x19, #20
Lloh17:
	adrp	x8, _sdhci_timeout_data_timer@GOTPAGE
Lloh18:
	ldr	x8, [x8, _sdhci_timeout_data_timer@GOTPAGEOFF]
Lloh19:
	ldr	w1, [x8]
	mov	w2, #0
	bl	_timer_setup
	add	x0, x19, #16
	bl	_init_waitqueue_head
	mov	x0, x19
	mov	w1, #0
	bl	_sdhci_init
	ldr	w21, [x19, #8]
Lloh20:
	adrp	x8, _sdhci_irq@GOTPAGE
Lloh21:
	ldr	x8, [x8, _sdhci_irq@GOTPAGEOFF]
Lloh22:
	ldr	w22, [x8]
Lloh23:
	adrp	x8, _sdhci_thread_irq@GOTPAGE
Lloh24:
	ldr	x8, [x8, _sdhci_thread_irq@GOTPAGEOFF]
Lloh25:
	ldr	w23, [x8]
Lloh26:
	adrp	x8, _IRQF_SHARED@GOTPAGE
Lloh27:
	ldr	x8, [x8, _IRQF_SHARED@GOTPAGEOFF]
Lloh28:
	ldr	w24, [x8]
	mov	x0, x20
	bl	_mmc_hostname
	mov	x4, x0
	mov	x0, x21
	mov	x1, x22
	mov	x2, x23
	mov	x3, x24
	mov	x5, x19
	bl	_request_threaded_irq
	cbz	w0, LBB0_4
; %bb.2:
	mov	x21, x0
	mov	x0, x20
	bl	_mmc_hostname
	mov	x1, x0
	ldr	w2, [x19, #8]
	str	x21, [sp]
Lloh29:
	adrp	x0, l_.str.1@PAGE
Lloh30:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	_pr_err
	b	LBB0_9
LBB0_3:
Lloh31:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh32:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh33:
	ldr	w8, [x8]
	neg	w21, w8
	b	LBB0_10
LBB0_4:
	mov	x0, x19
	bl	_sdhci_led_register
	cbz	w0, LBB0_6
; %bb.5:
	mov	x21, x0
	mov	x0, x20
	bl	_mmc_hostname
	mov	x1, x0
Lloh34:
	adrp	x0, l_.str.2@PAGE
Lloh35:
	add	x0, x0, l_.str.2@PAGEOFF
	mov	x2, x21
	bl	_pr_err
	b	LBB0_8
LBB0_6:
	mov	x0, x20
	bl	_mmc_add_host
	cbz	w0, LBB0_11
; %bb.7:
	mov	x21, x0
	mov	x0, x19
	bl	_sdhci_led_unregister
LBB0_8:
Lloh36:
	adrp	x8, _SDHCI_RESET_ALL@GOTPAGE
Lloh37:
	ldr	x8, [x8, _SDHCI_RESET_ALL@GOTPAGEOFF]
Lloh38:
	ldr	w1, [x8]
	mov	x0, x19
	bl	_sdhci_do_reset
Lloh39:
	adrp	x8, _SDHCI_INT_ENABLE@GOTPAGE
Lloh40:
	ldr	x8, [x8, _SDHCI_INT_ENABLE@GOTPAGEOFF]
Lloh41:
	ldr	w2, [x8]
	mov	x0, x19
	mov	w1, #0
	bl	_sdhci_writel
Lloh42:
	adrp	x8, _SDHCI_SIGNAL_ENABLE@GOTPAGE
Lloh43:
	ldr	x8, [x8, _SDHCI_SIGNAL_ENABLE@GOTPAGEOFF]
Lloh44:
	ldr	w2, [x8]
	mov	x0, x19
	mov	w1, #0
	bl	_sdhci_writel
	ldr	w0, [x19, #8]
	mov	x1, x19
	bl	_free_irq
LBB0_9:
	ldr	w0, [x19, #4]
	bl	_destroy_workqueue
LBB0_10:
	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
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #80
	ret
LBB0_11:
	mov	x0, x20
	bl	_mmc_hostname
	mov	x21, x0
	ldr	w22, [x19, #12]
	mov	x0, x20
	bl	_mmc_dev
	bl	_dev_name
	mov	x3, x0
	ldr	w8, [x19]
Lloh45:
	adrp	x9, _SDHCI_USE_ADMA@GOTPAGE
Lloh46:
	ldr	x9, [x9, _SDHCI_USE_ADMA@GOTPAGEOFF]
Lloh47:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_13
; %bb.12:
Lloh48:
	adrp	x9, _SDHCI_USE_64_BIT_DMA@GOTPAGE
Lloh49:
	ldr	x9, [x9, _SDHCI_USE_64_BIT_DMA@GOTPAGEOFF]
Lloh50:
	ldr	w9, [x9]
Lloh51:
	adrp	x10, l_.str.4@PAGE
Lloh52:
	add	x10, x10, l_.str.4@PAGEOFF
Lloh53:
	adrp	x11, l_.str.5@PAGE
Lloh54:
	add	x11, x11, l_.str.5@PAGEOFF
	b	LBB0_14
LBB0_13:
Lloh55:
	adrp	x9, _SDHCI_USE_SDMA@GOTPAGE
Lloh56:
	ldr	x9, [x9, _SDHCI_USE_SDMA@GOTPAGEOFF]
Lloh57:
	ldr	w9, [x9]
Lloh58:
	adrp	x10, l_.str.6@PAGE
Lloh59:
	add	x10, x10, l_.str.6@PAGEOFF
Lloh60:
	adrp	x11, l_.str.7@PAGE
Lloh61:
	add	x11, x11, l_.str.7@PAGEOFF
LBB0_14:
	tst	w9, w8
	csel	x4, x11, x10, eq
Lloh62:
	adrp	x0, l_.str.3@PAGE
Lloh63:
	add	x0, x0, l_.str.3@PAGEOFF
	mov	x1, x21
	mov	x2, x22
	bl	_pr_info
	mov	x0, x19
	bl	_sdhci_enable_card_detection
	mov	w21, #0
	b	LBB0_10
	.loh AdrpAdd	Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh26, Lloh27, Lloh28
	.loh AdrpLdrGotLdr	Lloh23, Lloh24, Lloh25
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpAdd	Lloh29, Lloh30
	.loh AdrpLdrGotLdr	Lloh31, Lloh32, Lloh33
	.loh AdrpAdd	Lloh34, Lloh35
	.loh AdrpLdrGotLdr	Lloh42, Lloh43, Lloh44
	.loh AdrpLdrGotLdr	Lloh39, Lloh40, Lloh41
	.loh AdrpLdrGotLdr	Lloh36, Lloh37, Lloh38
	.loh AdrpLdrGotLdr	Lloh45, Lloh46, Lloh47
	.loh AdrpAdd	Lloh53, Lloh54
	.loh AdrpAdd	Lloh51, Lloh52
	.loh AdrpLdrGotLdr	Lloh48, Lloh49, Lloh50
	.loh AdrpAdd	Lloh60, Lloh61
	.loh AdrpAdd	Lloh58, Lloh59
	.loh AdrpLdrGotLdr	Lloh55, Lloh56, Lloh57
	.loh AdrpAdd	Lloh62, Lloh63
	.cfi_endproc
                                        ; -- End function
	.comm	_WQ_UNBOUND,4,2                 ; @WQ_UNBOUND
	.comm	_WQ_MEM_RECLAIM,4,2             ; @WQ_MEM_RECLAIM
	.comm	_WQ_HIGHPRI,4,2                 ; @WQ_HIGHPRI
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"sdhci"

	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.comm	_sdhci_complete_work,4,2        ; @sdhci_complete_work
	.comm	_sdhci_timeout_timer,4,2        ; @sdhci_timeout_timer
	.comm	_sdhci_timeout_data_timer,4,2   ; @sdhci_timeout_data_timer
	.comm	_sdhci_irq,4,2                  ; @sdhci_irq
	.comm	_sdhci_thread_irq,4,2           ; @sdhci_thread_irq
	.comm	_IRQF_SHARED,4,2                ; @IRQF_SHARED
l_.str.1:                               ; @.str.1
	.asciz	"%s: Failed to request IRQ %d: %d\n"

l_.str.2:                               ; @.str.2
	.asciz	"%s: Failed to register LED device: %d\n"

l_.str.3:                               ; @.str.3
	.asciz	"%s: SDHCI controller on %s [%s] using %s\n"

	.comm	_SDHCI_USE_ADMA,4,2             ; @SDHCI_USE_ADMA
	.comm	_SDHCI_USE_64_BIT_DMA,4,2       ; @SDHCI_USE_64_BIT_DMA
l_.str.4:                               ; @.str.4
	.asciz	"ADMA 64-bit"

l_.str.5:                               ; @.str.5
	.asciz	"ADMA"

	.comm	_SDHCI_USE_SDMA,4,2             ; @SDHCI_USE_SDMA
l_.str.6:                               ; @.str.6
	.asciz	"DMA"

l_.str.7:                               ; @.str.7
	.asciz	"PIO"

	.comm	_SDHCI_RESET_ALL,4,2            ; @SDHCI_RESET_ALL
	.comm	_SDHCI_INT_ENABLE,4,2           ; @SDHCI_INT_ENABLE
	.comm	_SDHCI_SIGNAL_ENABLE,4,2        ; @SDHCI_SIGNAL_ENABLE
.subsections_via_symbols
