	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function wmt_mci_remove
_wmt_mci_remove:                        ## @wmt_mci_remove
	.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
	callq	_platform_get_drvdata
	movq	%rax, %r14
	movq	%rax, %rdi
	callq	_mmc_priv
	movq	%rax, %rbx
	movq	_SDMMC_BUSMODE@GOTPCREL(%rip), %r12
	movq	(%r12), %rdi
	addq	8(%rax), %rdi
	callq	_readb
	movq	_BM_SOFT_RESET@GOTPCREL(%rip), %rcx
	orl	(%rcx), %eax
	movq	(%r12), %rsi
	addq	8(%rbx), %rsi
	movl	%eax, %edi
	callq	_writel
	movq	_SDMMC_BLKLEN@GOTPCREL(%rip), %r12
	movq	(%r12), %rdi
	addq	8(%rbx), %rdi
	callq	_readw
	andl	$-40961, %eax                   ## imm = 0xFFFF5FFF
	movq	(%r12), %rsi
	addq	8(%rbx), %rsi
	movl	%eax, %edi
	callq	_writew
	movq	_SDMMC_STS0@GOTPCREL(%rip), %rax
	movq	(%rax), %rsi
	addq	8(%rbx), %rsi
	movl	$255, %edi
	callq	_writeb
	movq	_SDMMC_STS1@GOTPCREL(%rip), %rax
	movq	(%rax), %rsi
	addq	8(%rbx), %rsi
	movl	$255, %edi
	callq	_writeb
	movq	32(%rbx), %rax
	movl	(%rax), %esi
	shll	$4, %esi
	movl	24(%rbx), %ecx
	movl	28(%rbx), %edx
	movq	%r15, %rdi
	callq	_dma_free_coherent
	movq	%r14, %rdi
	callq	_mmc_remove_host
	movl	20(%rbx), %edi
	movq	%rbx, %rsi
	callq	_free_irq
	movl	16(%rbx), %edi
	movq	%rbx, %rsi
	callq	_free_irq
	movq	8(%rbx), %rdi
	callq	_iounmap
	movl	(%rbx), %edi
	callq	_clk_disable_unprepare
	movl	(%rbx), %edi
	callq	_clk_put
	movq	_IORESOURCE_MEM@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r15, %rdi
	xorl	%edx, %edx
	callq	_platform_get_resource
	movl	(%rax), %ebx
	movq	%rax, %rdi
	callq	_resource_size
	movl	%ebx, %edi
	movl	%eax, %esi
	callq	_release_mem_region
	movq	%r14, %rdi
	callq	_mmc_free_host
	leaq	L_.str(%rip), %rsi
	movq	%r15, %rdi
	callq	_dev_info
	xorl	%eax, %eax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_SDMMC_BUSMODE,8,3              ## @SDMMC_BUSMODE
	.comm	_BM_SOFT_RESET,4,2              ## @BM_SOFT_RESET
	.comm	_SDMMC_BLKLEN,8,3               ## @SDMMC_BLKLEN
	.comm	_SDMMC_STS0,8,3                 ## @SDMMC_STS0
	.comm	_SDMMC_STS1,8,3                 ## @SDMMC_STS1
	.comm	_IORESOURCE_MEM,4,2             ## @IORESOURCE_MEM
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"WMT MCI device removed\n"

	.no_dead_strip	_wmt_mci_remove
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function wmt_mci_remove
_wmt_mci_remove:                        ; @wmt_mci_remove
	.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	x19, x0
	bl	_platform_get_drvdata
	mov	x20, x0
	bl	_mmc_priv
	mov	x21, x0
	ldr	x8, [x0, #8]
Lloh0:
	adrp	x22, _SDMMC_BUSMODE@GOTPAGE
Lloh1:
	ldr	x22, [x22, _SDMMC_BUSMODE@GOTPAGEOFF]
	ldr	x9, [x22]
	add	x0, x9, x8
	bl	_readb
Lloh2:
	adrp	x8, _BM_SOFT_RESET@GOTPAGE
Lloh3:
	ldr	x8, [x8, _BM_SOFT_RESET@GOTPAGEOFF]
Lloh4:
	ldr	w8, [x8]
	orr	w0, w8, w0
	ldr	x8, [x21, #8]
	ldr	x9, [x22]
	add	x1, x9, x8
	bl	_writel
	ldr	x8, [x21, #8]
Lloh5:
	adrp	x22, _SDMMC_BLKLEN@GOTPAGE
Lloh6:
	ldr	x22, [x22, _SDMMC_BLKLEN@GOTPAGEOFF]
	ldr	x9, [x22]
	add	x0, x9, x8
	bl	_readw
	mov	w8, #-40961
	and	w0, w0, w8
	ldr	x8, [x21, #8]
	ldr	x9, [x22]
	add	x1, x9, x8
	bl	_writew
	ldr	x8, [x21, #8]
Lloh7:
	adrp	x9, _SDMMC_STS0@GOTPAGE
Lloh8:
	ldr	x9, [x9, _SDMMC_STS0@GOTPAGEOFF]
Lloh9:
	ldr	x9, [x9]
	add	x1, x9, x8
	mov	w0, #255
	bl	_writeb
	ldr	x8, [x21, #8]
Lloh10:
	adrp	x9, _SDMMC_STS1@GOTPAGE
Lloh11:
	ldr	x9, [x9, _SDMMC_STS1@GOTPAGEOFF]
Lloh12:
	ldr	x9, [x9]
	add	x1, x9, x8
	mov	w0, #255
	bl	_writeb
	ldr	x8, [x21, #32]
	ldr	w8, [x8]
	lsl	w1, w8, #4
	ldp	w3, w2, [x21, #24]
	mov	x0, x19
	bl	_dma_free_coherent
	mov	x0, x20
	bl	_mmc_remove_host
	ldr	w0, [x21, #20]
	mov	x1, x21
	bl	_free_irq
	ldr	w0, [x21, #16]
	mov	x1, x21
	bl	_free_irq
	ldr	x0, [x21, #8]
	bl	_iounmap
	ldr	w0, [x21]
	bl	_clk_disable_unprepare
	ldr	w0, [x21]
	bl	_clk_put
Lloh13:
	adrp	x8, _IORESOURCE_MEM@GOTPAGE
Lloh14:
	ldr	x8, [x8, _IORESOURCE_MEM@GOTPAGEOFF]
Lloh15:
	ldr	w1, [x8]
	mov	x0, x19
	mov	w2, #0
	bl	_platform_get_resource
	ldr	w21, [x0]
	bl	_resource_size
	mov	x1, x0
	mov	x0, x21
	bl	_release_mem_region
	mov	x0, x20
	bl	_mmc_free_host
Lloh16:
	adrp	x1, l_.str@PAGE
Lloh17:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x19
	bl	_dev_info
	mov	w0, #0
	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
	.loh AdrpAdd	Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh0, Lloh1
	.cfi_endproc
                                        ; -- End function
	.comm	_SDMMC_BUSMODE,8,3              ; @SDMMC_BUSMODE
	.comm	_BM_SOFT_RESET,4,2              ; @BM_SOFT_RESET
	.comm	_SDMMC_BLKLEN,8,3               ; @SDMMC_BLKLEN
	.comm	_SDMMC_STS0,8,3                 ; @SDMMC_STS0
	.comm	_SDMMC_STS1,8,3                 ; @SDMMC_STS1
	.comm	_IORESOURCE_MEM,4,2             ; @IORESOURCE_MEM
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"WMT MCI device removed\n"

	.no_dead_strip	_wmt_mci_remove
.subsections_via_symbols
