	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function msdc_drv_probe
_msdc_drv_probe:                        ## @msdc_drv_probe
	.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, %r13
	cmpl	$0, (%rdi)
	je	LBB0_1
## %bb.2:
	movl	$168, %edi
	movq	%r13, %rsi
	callq	_mmc_alloc_host
	testq	%rax, %rax
	je	LBB0_3
## %bb.5:
	movq	%rax, %r14
	movq	%rax, %rdi
	callq	_mmc_priv
	movq	%rax, %r15
	movq	%r14, %rdi
	callq	_mmc_of_parse
	movl	%eax, %ebx
	testl	%eax, %eax
	jne	LBB0_51
## %bb.6:
	movq	_IORESOURCE_MEM@GOTPCREL(%rip), %rbx
	movl	(%rbx), %esi
	movq	%r13, %rdi
	xorl	%edx, %edx
	callq	_platform_get_resource
	movq	%r13, %rdi
	movq	%rax, %rsi
	callq	_devm_ioremap_resource
	movq	%rax, 160(%r15)
	movq	%rax, %rdi
	callq	_IS_ERR
	testq	%rax, %rax
	je	LBB0_9
## %bb.7:
	movq	160(%r15), %rdi
LBB0_8:
	callq	_PTR_ERR
	movl	%eax, %ebx
	jmp	LBB0_51
LBB0_1:
	leaq	L_.str(%rip), %rsi
	movq	%r13, %rdi
	callq	_dev_err
	movq	_EINVAL@GOTPCREL(%rip), %rax
	jmp	LBB0_4
LBB0_3:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
LBB0_4:
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
	jmp	LBB0_52
LBB0_9:
	movl	(%rbx), %esi
	movq	%r13, %rdi
	movl	$1, %edx
	callq	_platform_get_resource
	testq	%rax, %rax
	je	LBB0_12
## %bb.10:
	movq	%r13, %rdi
	movq	%rax, %rsi
	callq	_devm_ioremap_resource
	movq	%rax, 152(%r15)
	movq	%rax, %rdi
	callq	_IS_ERR
	testq	%rax, %rax
	je	LBB0_12
## %bb.11:
	movq	$0, 152(%r15)
LBB0_12:
	movq	%r14, %rdi
	callq	_mmc_regulator_get_supply
	movl	%eax, %ebx
	testl	%eax, %eax
	je	LBB0_13
LBB0_51:
	movq	%r14, %rdi
	callq	_mmc_free_host
LBB0_52:
	movl	%ebx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_13:
	leaq	L_.str.1(%rip), %rsi
	movq	%r13, %rdi
	callq	_devm_clk_get
	movq	%rax, 88(%r15)
	movq	%rax, %rdi
	callq	_IS_ERR
	testq	%rax, %rax
	je	LBB0_15
## %bb.14:
	movq	88(%r15), %rdi
	jmp	LBB0_8
LBB0_15:
	leaq	L_.str.2(%rip), %rsi
	movq	%r13, %rdi
	callq	_devm_clk_get
	movq	%rax, 144(%r15)
	movq	%rax, %rdi
	callq	_IS_ERR
	testq	%rax, %rax
	je	LBB0_17
## %bb.16:
	movq	144(%r15), %rdi
	jmp	LBB0_8
LBB0_17:
	leaq	L_.str.3(%rip), %rsi
	movq	%r13, %rdi
	callq	_devm_clk_get
	movq	%rax, 136(%r15)
	movq	%rax, %rdi
	callq	_IS_ERR
	testq	%rax, %rax
	je	LBB0_19
## %bb.18:
	movq	$0, 136(%r15)
LBB0_19:
	leaq	L_.str.4(%rip), %rsi
	movq	%r13, %rdi
	callq	_devm_clk_get
	movq	%rax, 128(%r15)
	movq	%rax, %rdi
	callq	_IS_ERR
	testq	%rax, %rax
	je	LBB0_21
## %bb.20:
	movq	$0, 128(%r15)
LBB0_21:
	xorl	%ebx, %ebx
	movq	%r13, %rdi
	xorl	%esi, %esi
	callq	_platform_get_irq
	movq	%rax, (%r15)
	testq	%rax, %rax
	js	LBB0_22
## %bb.23:
	movq	%r13, %rdi
	callq	_devm_pinctrl_get
	movq	%rax, 112(%r15)
	movq	%rax, %rdi
	callq	_IS_ERR
	movq	112(%r15), %rdi
	testq	%rax, %rax
	je	LBB0_26
## %bb.24:
	callq	_PTR_ERR
	movl	%eax, %ebx
	leaq	L_.str.5(%rip), %rsi
	jmp	LBB0_25
LBB0_22:
	movq	_EINVAL@GOTPCREL(%rip), %rax
	subl	(%rax), %ebx
	jmp	LBB0_51
LBB0_26:
	leaq	L_.str.6(%rip), %rsi
	callq	_pinctrl_lookup_state
	movq	%rax, 120(%r15)
	movq	%rax, %rdi
	callq	_IS_ERR
	testq	%rax, %rax
	je	LBB0_28
## %bb.27:
	movq	120(%r15), %rdi
	callq	_PTR_ERR
	movl	%eax, %ebx
	leaq	L_.str.7(%rip), %rsi
	jmp	LBB0_25
LBB0_28:
	movq	112(%r15), %rdi
	leaq	L_.str.8(%rip), %rsi
	callq	_pinctrl_lookup_state
	movq	%rax, 104(%r15)
	movq	%rax, %rdi
	callq	_IS_ERR
	testq	%rax, %rax
	je	LBB0_30
## %bb.29:
	movq	104(%r15), %rdi
	callq	_PTR_ERR
	movl	%eax, %ebx
	leaq	L_.str.9(%rip), %rsi
LBB0_25:
	movq	%r13, %rdi
	callq	_dev_err
	jmp	LBB0_51
LBB0_30:
	movq	%r13, %rdi
	movq	%r15, %rsi
	callq	_msdc_of_property_parse
	movq	%r13, 48(%r15)
	movq	%r13, %rdi
	callq	_of_device_get_match_data
	movq	%rax, 72(%r15)
	movq	%r14, 96(%r15)
	movq	88(%r15), %rdi
	callq	_clk_get_rate
	movl	%eax, 80(%r15)
	movq	_mt_msdc_ops@GOTPCREL(%rip), %rcx
	movq	%rcx, 40(%r14)
	movq	72(%r15), %rcx
	cmpl	$8, (%rcx)
	movl	$1020, %ecx                     ## imm = 0x3FC
	movl	$16380, %esi                    ## imm = 0x3FFC
	cmovel	%ecx, %esi
	movl	%eax, %edi
	callq	_DIV_ROUND_UP
	movq	%rax, 32(%r14)
	movq	_MMC_CAP_NONREMOVABLE@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	testl	%eax, (%r14)
	jne	LBB0_34
## %bb.31:
	movq	%r14, %rdi
	callq	_mmc_can_gpio_cd
	testl	%eax, %eax
	jne	LBB0_34
## %bb.32:
	movq	72(%r15), %rax
	cmpq	$0, 16(%rax)
	je	LBB0_34
## %bb.33:
	movl	$1, 8(%r15)
LBB0_34:
	movl	(%r14), %eax
	movq	_MMC_CAP_SDIO_IRQ@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	je	LBB0_36
## %bb.35:
	movq	_MMC_CAP2_SDIO_IRQ_NOTHREAD@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	orl	%ecx, 24(%r14)
LBB0_36:
	movq	_MMC_CAP_ERASE@GOTPCREL(%rip), %rcx
	movq	_MMC_CAP_CMD23@GOTPCREL(%rip), %rdx
	orl	(%rcx), %eax
	orl	(%rdx), %eax
	movl	%eax, (%r14)
	movq	_MAX_BD_NUM@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 4(%r14)
	movq	72(%r15), %rax
	xorl	%ecx, %ecx
	cmpq	$0, 8(%rax)
	setne	%cl
	leal	32(,%rcx,4), %edi
	jne	LBB0_37
## %bb.38:
	movq	_BDMA_DESC_BUFLEN@GOTPCREL(%rip), %rax
	jmp	LBB0_39
LBB0_37:
	movq	_BDMA_DESC_BUFLEN_EXT@GOTPCREL(%rip), %rax
LBB0_39:
	movl	(%rax), %eax
	movl	%eax, 20(%r14)
	movabsq	$2251799813687296, %rax         ## imm = 0x8000000000800
	movq	%rax, 8(%r14)
	movl	$1024, 16(%r14)                 ## imm = 0x400
	callq	_DMA_BIT_MASK
	leaq	64(%r15), %rbx
	movq	%rax, 64(%r15)
	movq	%r14, %rdi
	callq	_mmc_dev
	movq	%rbx, (%rax)
	movl	$3145728, 12(%r15)              ## imm = 0x300000
	leaq	16(%r15), %r12
	leaq	32(%r15), %rdx
	movq	_GFP_KERNEL@GOTPCREL(%rip), %rbx
	movl	(%rbx), %ecx
	movq	%r13, %rdi
	movl	$8, %esi
	movq	%rdx, -48(%rbp)                 ## 8-byte Spill
	callq	_dma_alloc_coherent
	movq	%rax, 40(%r15)
	movq	_MAX_BD_NUM@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	shll	$2, %esi
	movl	(%rbx), %ecx
	movq	%r13, %rdi
	movq	%r12, %rdx
	callq	_dma_alloc_coherent
	movq	%rax, 24(%r15)
	movq	40(%r15), %rdx
	testq	%rdx, %rdx
	je	LBB0_41
## %bb.40:
	testq	%rax, %rax
	je	LBB0_41
## %bb.42:
	movq	%r15, %rdi
	movq	%r12, %rsi
	callq	_msdc_init_gpd_bd
	leaq	60(%r15), %rdi
	movq	_msdc_request_timeout@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_INIT_DELAYED_WORK
	movq	%r15, %rdi
	addq	$56, %rdi
	callq	_spin_lock_init
	movq	%r13, %rdi
	movq	%r14, %rsi
	callq	_platform_set_drvdata
	movq	%r15, %rdi
	callq	_msdc_ungate_clock
	movq	%r15, %rdi
	callq	_msdc_init_hw
	movq	(%r15), %rsi
	movq	_msdc_irq@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	_IRQF_TRIGGER_NONE@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movl	4(%r13), %r8d
	movq	%r13, %rdi
	movq	%r15, %r9
	callq	_devm_request_irq
	movl	%eax, %ebx
	testl	%eax, %eax
	jne	LBB0_46
## %bb.43:
	movq	48(%r15), %rdi
	callq	_pm_runtime_set_active
	movq	48(%r15), %rdi
	movq	_MTK_MMC_AUTOSUSPEND_DELAY@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_pm_runtime_set_autosuspend_delay
	movq	48(%r15), %rdi
	callq	_pm_runtime_use_autosuspend
	movq	48(%r15), %rdi
	callq	_pm_runtime_enable
	movq	%r14, %rdi
	callq	_mmc_add_host
	testl	%eax, %eax
	je	LBB0_44
## %bb.45:
	movl	%eax, %ebx
	movq	48(%r15), %rdi
	callq	_pm_runtime_disable
LBB0_46:
	movq	%r13, %rdi
	xorl	%esi, %esi
	callq	_platform_set_drvdata
	movq	%r15, %rdi
	callq	_msdc_deinit_hw
	movq	%r15, %rdi
	callq	_msdc_gate_clock
	movq	40(%r15), %rdx
	jmp	LBB0_47
LBB0_41:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
LBB0_47:
	testq	%rdx, %rdx
	je	LBB0_49
## %bb.48:
	movq	-48(%rbp), %rax                 ## 8-byte Reload
	movl	(%rax), %ecx
	movq	%r13, %rdi
	movl	$8, %esi
	callq	_dma_free_coherent
LBB0_49:
	movq	24(%r15), %rdx
	testq	%rdx, %rdx
	je	LBB0_51
## %bb.50:
	movq	_MAX_BD_NUM@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	shll	$2, %esi
	movl	(%r12), %ecx
	movq	%r13, %rdi
	callq	_dma_free_coherent
	jmp	LBB0_51
LBB0_44:
	xorl	%ebx, %ebx
	jmp	LBB0_52
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"No DT found\n"

	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.comm	_IORESOURCE_MEM,4,2             ## @IORESOURCE_MEM
L_.str.1:                               ## @.str.1
	.asciz	"source"

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

L_.str.3:                               ## @.str.3
	.asciz	"bus_clk"

L_.str.4:                               ## @.str.4
	.asciz	"source_cg"

L_.str.5:                               ## @.str.5
	.asciz	"Cannot find pinctrl!\n"

L_.str.6:                               ## @.str.6
	.asciz	"default"

L_.str.7:                               ## @.str.7
	.asciz	"Cannot find pinctrl default!\n"

L_.str.8:                               ## @.str.8
	.asciz	"state_uhs"

L_.str.9:                               ## @.str.9
	.asciz	"Cannot find pinctrl uhs!\n"

	.comm	_mt_msdc_ops,4,2                ## @mt_msdc_ops
	.comm	_MMC_CAP_NONREMOVABLE,4,2       ## @MMC_CAP_NONREMOVABLE
	.comm	_MMC_CAP_SDIO_IRQ,4,2           ## @MMC_CAP_SDIO_IRQ
	.comm	_MMC_CAP2_SDIO_IRQ_NOTHREAD,4,2 ## @MMC_CAP2_SDIO_IRQ_NOTHREAD
	.comm	_MMC_CAP_ERASE,4,2              ## @MMC_CAP_ERASE
	.comm	_MMC_CAP_CMD23,4,2              ## @MMC_CAP_CMD23
	.comm	_MAX_BD_NUM,4,2                 ## @MAX_BD_NUM
	.comm	_BDMA_DESC_BUFLEN_EXT,4,2       ## @BDMA_DESC_BUFLEN_EXT
	.comm	_BDMA_DESC_BUFLEN,4,2           ## @BDMA_DESC_BUFLEN
	.comm	_GFP_KERNEL,4,2                 ## @GFP_KERNEL
	.comm	_msdc_request_timeout,4,2       ## @msdc_request_timeout
	.comm	_msdc_irq,4,2                   ## @msdc_irq
	.comm	_IRQF_TRIGGER_NONE,4,2          ## @IRQF_TRIGGER_NONE
	.comm	_MTK_MMC_AUTOSUSPEND_DELAY,4,2  ## @MTK_MMC_AUTOSUSPEND_DELAY
	.no_dead_strip	_msdc_drv_probe
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.section	__TEXT,__literal8,8byte_literals
	.p2align	3                               ; -- Begin function msdc_drv_probe
lCPI0_0:
	.long	2048                            ; 0x800
	.long	524288                          ; 0x80000
	.section	__TEXT,__text,regular,pure_instructions
	.p2align	2
_msdc_drv_probe:                        ; @msdc_drv_probe
	.cfi_startproc
; %bb.0:
	stp	x26, x25, [sp, #-80]!           ; 16-byte Folded Spill
	.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
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	mov	x20, x0
	ldr	w8, [x0]
	cbz	w8, LBB0_6
; %bb.1:
	mov	w0, #168
	mov	x1, x20
	bl	_mmc_alloc_host
	cbz	x0, LBB0_7
; %bb.2:
	mov	x19, x0
	bl	_mmc_priv
	mov	x21, x0
	mov	x0, x19
	bl	_mmc_of_parse
	mov	x22, x0
	cbnz	w0, LBB0_13
; %bb.3:
Lloh0:
	adrp	x22, _IORESOURCE_MEM@GOTPAGE
Lloh1:
	ldr	x22, [x22, _IORESOURCE_MEM@GOTPAGEOFF]
	ldr	w1, [x22]
	mov	x0, x20
	mov	w2, #0
	bl	_platform_get_resource
	mov	x1, x0
	mov	x0, x20
	bl	_devm_ioremap_resource
	str	x0, [x21, #160]
	bl	_IS_ERR
	cbz	x0, LBB0_9
; %bb.4:
	ldr	x0, [x21, #160]
LBB0_5:
	bl	_PTR_ERR
	mov	x22, x0
	b	LBB0_13
LBB0_6:
Lloh2:
	adrp	x1, l_.str@PAGE
Lloh3:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x20
	bl	_dev_err
Lloh4:
	adrp	x8, _EINVAL@GOTPAGE
Lloh5:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
	b	LBB0_8
LBB0_7:
Lloh6:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh7:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
LBB0_8:
	ldr	w8, [x8]
	neg	w22, w8
	b	LBB0_14
LBB0_9:
	ldr	w1, [x22]
	mov	x0, x20
	mov	w2, #1
	bl	_platform_get_resource
	cbz	x0, LBB0_12
; %bb.10:
	mov	x1, x0
	mov	x0, x20
	bl	_devm_ioremap_resource
	str	x0, [x21, #152]
	bl	_IS_ERR
	cbz	x0, LBB0_12
; %bb.11:
	str	xzr, [x21, #152]
LBB0_12:
	mov	x0, x19
	bl	_mmc_regulator_get_supply
	mov	x22, x0
	cbz	w0, LBB0_15
LBB0_13:
	mov	x0, x19
	bl	_mmc_free_host
LBB0_14:
	mov	x0, x22
	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
	ldp	x26, x25, [sp], #80             ; 16-byte Folded Reload
	ret
LBB0_15:
Lloh8:
	adrp	x1, l_.str.1@PAGE
Lloh9:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x0, x20
	bl	_devm_clk_get
	str	x0, [x21, #88]
	bl	_IS_ERR
	cbz	x0, LBB0_17
; %bb.16:
	ldr	x0, [x21, #88]
	b	LBB0_5
LBB0_17:
Lloh10:
	adrp	x1, l_.str.2@PAGE
Lloh11:
	add	x1, x1, l_.str.2@PAGEOFF
	mov	x0, x20
	bl	_devm_clk_get
	str	x0, [x21, #144]
	bl	_IS_ERR
	cbz	x0, LBB0_19
; %bb.18:
	ldr	x0, [x21, #144]
	b	LBB0_5
LBB0_19:
Lloh12:
	adrp	x1, l_.str.3@PAGE
Lloh13:
	add	x1, x1, l_.str.3@PAGEOFF
	mov	x0, x20
	bl	_devm_clk_get
	str	x0, [x21, #136]
	bl	_IS_ERR
	cbz	x0, LBB0_21
; %bb.20:
	str	xzr, [x21, #136]
LBB0_21:
Lloh14:
	adrp	x1, l_.str.4@PAGE
Lloh15:
	add	x1, x1, l_.str.4@PAGEOFF
	mov	x0, x20
	bl	_devm_clk_get
	str	x0, [x21, #128]
	bl	_IS_ERR
	cbz	x0, LBB0_23
; %bb.22:
	str	xzr, [x21, #128]
LBB0_23:
	mov	x0, x20
	mov	w1, #0
	bl	_platform_get_irq
	str	x0, [x21]
	tbnz	x0, #63, LBB0_26
; %bb.24:
	mov	x0, x20
	bl	_devm_pinctrl_get
	str	x0, [x21, #112]
	bl	_IS_ERR
	mov	x8, x0
	ldr	x0, [x21, #112]
	cbz	x8, LBB0_27
; %bb.25:
	bl	_PTR_ERR
	mov	x22, x0
Lloh16:
	adrp	x1, l_.str.5@PAGE
Lloh17:
	add	x1, x1, l_.str.5@PAGEOFF
	b	LBB0_31
LBB0_26:
Lloh18:
	adrp	x8, _EINVAL@GOTPAGE
Lloh19:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh20:
	ldr	w8, [x8]
	neg	w22, w8
	b	LBB0_13
LBB0_27:
Lloh21:
	adrp	x1, l_.str.6@PAGE
Lloh22:
	add	x1, x1, l_.str.6@PAGEOFF
	bl	_pinctrl_lookup_state
	str	x0, [x21, #120]
	bl	_IS_ERR
	cbz	x0, LBB0_29
; %bb.28:
	ldr	x0, [x21, #120]
	bl	_PTR_ERR
	mov	x22, x0
Lloh23:
	adrp	x1, l_.str.7@PAGE
Lloh24:
	add	x1, x1, l_.str.7@PAGEOFF
	b	LBB0_31
LBB0_29:
	ldr	x0, [x21, #112]
Lloh25:
	adrp	x1, l_.str.8@PAGE
Lloh26:
	add	x1, x1, l_.str.8@PAGEOFF
	bl	_pinctrl_lookup_state
	str	x0, [x21, #104]
	bl	_IS_ERR
	cbz	x0, LBB0_32
; %bb.30:
	ldr	x0, [x21, #104]
	bl	_PTR_ERR
	mov	x22, x0
Lloh27:
	adrp	x1, l_.str.9@PAGE
Lloh28:
	add	x1, x1, l_.str.9@PAGEOFF
LBB0_31:
	mov	x0, x20
	bl	_dev_err
	b	LBB0_13
LBB0_32:
	mov	x0, x20
	mov	x1, x21
	bl	_msdc_of_property_parse
	str	x20, [x21, #48]
	mov	x0, x20
	bl	_of_device_get_match_data
	str	x0, [x21, #72]
	str	x19, [x21, #96]
	ldr	x0, [x21, #88]
	bl	_clk_get_rate
	str	w0, [x21, #80]
Lloh29:
	adrp	x8, _mt_msdc_ops@GOTPAGE
Lloh30:
	ldr	x8, [x8, _mt_msdc_ops@GOTPAGEOFF]
	str	x8, [x19, #40]
	ldr	x8, [x21, #72]
	ldr	w8, [x8]
	mov	w9, #16380
	mov	w10, #1020
	cmp	w8, #8
	csel	w1, w10, w9, eq
	bl	_DIV_ROUND_UP
	str	x0, [x19, #32]
	ldr	w8, [x19]
Lloh31:
	adrp	x9, _MMC_CAP_NONREMOVABLE@GOTPAGE
Lloh32:
	ldr	x9, [x9, _MMC_CAP_NONREMOVABLE@GOTPAGEOFF]
Lloh33:
	ldr	w9, [x9]
	tst	w9, w8
	b.ne	LBB0_36
; %bb.33:
	mov	x0, x19
	bl	_mmc_can_gpio_cd
	cbnz	w0, LBB0_36
; %bb.34:
	ldr	x8, [x21, #72]
	ldr	x8, [x8, #16]
	cbz	x8, LBB0_36
; %bb.35:
	mov	w8, #1
	str	w8, [x21, #8]
LBB0_36:
	ldr	w8, [x19]
Lloh34:
	adrp	x9, _MMC_CAP_SDIO_IRQ@GOTPAGE
Lloh35:
	ldr	x9, [x9, _MMC_CAP_SDIO_IRQ@GOTPAGEOFF]
Lloh36:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_38
; %bb.37:
Lloh37:
	adrp	x9, _MMC_CAP2_SDIO_IRQ_NOTHREAD@GOTPAGE
Lloh38:
	ldr	x9, [x9, _MMC_CAP2_SDIO_IRQ_NOTHREAD@GOTPAGEOFF]
Lloh39:
	ldr	w9, [x9]
	ldr	w10, [x19, #24]
	orr	w9, w10, w9
	str	w9, [x19, #24]
LBB0_38:
Lloh40:
	adrp	x9, _MMC_CAP_ERASE@GOTPAGE
Lloh41:
	ldr	x9, [x9, _MMC_CAP_ERASE@GOTPAGEOFF]
Lloh42:
	ldr	w9, [x9]
Lloh43:
	adrp	x10, _MMC_CAP_CMD23@GOTPAGE
Lloh44:
	ldr	x10, [x10, _MMC_CAP_CMD23@GOTPAGEOFF]
Lloh45:
	ldr	w10, [x10]
	orr	w8, w9, w8
	orr	w8, w8, w10
	str	w8, [x19]
Lloh46:
	adrp	x24, _MAX_BD_NUM@GOTPAGE
Lloh47:
	ldr	x24, [x24, _MAX_BD_NUM@GOTPAGEOFF]
	ldr	w8, [x24]
	str	w8, [x19, #4]
	ldr	x8, [x21, #72]
	ldr	x8, [x8, #8]
Lloh48:
	adrp	x9, _BDMA_DESC_BUFLEN@GOTPAGE
Lloh49:
	ldr	x9, [x9, _BDMA_DESC_BUFLEN@GOTPAGEOFF]
Lloh50:
	adrp	x10, _BDMA_DESC_BUFLEN_EXT@GOTPAGE
Lloh51:
	ldr	x10, [x10, _BDMA_DESC_BUFLEN_EXT@GOTPAGEOFF]
	mov	w11, #36
	cmp	x8, #0
	csel	x8, x9, x10, eq
	mov	w9, #32
	csel	w0, w9, w11, eq
	ldr	w8, [x8]
Lloh52:
	adrp	x9, lCPI0_0@PAGE
Lloh53:
	ldr	d0, [x9, lCPI0_0@PAGEOFF]
	str	d0, [x19, #8]
	mov	w9, #1024
	stp	w9, w8, [x19, #16]
	bl	_DMA_BIT_MASK
	mov	x22, x21
	str	x0, [x22, #64]!
	mov	x0, x19
	bl	_mmc_dev
	str	x22, [x0]
	mov	w8, #3145728
	stur	w8, [x22, #-52]
	sub	x25, x22, #48
	sub	x23, x22, #32
Lloh54:
	adrp	x26, _GFP_KERNEL@GOTPAGE
Lloh55:
	ldr	x26, [x26, _GFP_KERNEL@GOTPAGEOFF]
	ldr	w3, [x26]
	mov	x0, x20
	mov	w1, #8
	mov	x2, x23
	bl	_dma_alloc_coherent
	stur	x0, [x22, #-24]
	ldr	w8, [x24]
	lsl	w1, w8, #2
	ldr	w3, [x26]
	mov	x0, x20
	mov	x2, x25
	bl	_dma_alloc_coherent
	stur	x0, [x22, #-40]
	ldur	x2, [x22, #-24]
	cbz	x2, LBB0_44
; %bb.39:
	cbz	x0, LBB0_44
; %bb.40:
	mov	x0, x21
	mov	x1, x25
	bl	_msdc_init_gpd_bd
	add	x0, x21, #60
Lloh56:
	adrp	x8, _msdc_request_timeout@GOTPAGE
Lloh57:
	ldr	x8, [x8, _msdc_request_timeout@GOTPAGEOFF]
Lloh58:
	ldr	w1, [x8]
	bl	_INIT_DELAYED_WORK
	add	x0, x21, #56
	bl	_spin_lock_init
	mov	x0, x20
	mov	x1, x19
	bl	_platform_set_drvdata
	mov	x0, x21
	bl	_msdc_ungate_clock
	mov	x0, x21
	bl	_msdc_init_hw
Lloh59:
	adrp	x8, _msdc_irq@GOTPAGE
Lloh60:
	ldr	x8, [x8, _msdc_irq@GOTPAGEOFF]
	ldr	x1, [x21]
Lloh61:
	ldr	w2, [x8]
Lloh62:
	adrp	x8, _IRQF_TRIGGER_NONE@GOTPAGE
Lloh63:
	ldr	x8, [x8, _IRQF_TRIGGER_NONE@GOTPAGEOFF]
Lloh64:
	ldr	w3, [x8]
	ldr	w4, [x20, #4]
	mov	x0, x20
	mov	x5, x21
	bl	_devm_request_irq
	mov	x22, x0
	cbnz	w0, LBB0_43
; %bb.41:
	ldr	x0, [x21, #48]
	bl	_pm_runtime_set_active
	ldr	x0, [x21, #48]
Lloh65:
	adrp	x8, _MTK_MMC_AUTOSUSPEND_DELAY@GOTPAGE
Lloh66:
	ldr	x8, [x8, _MTK_MMC_AUTOSUSPEND_DELAY@GOTPAGEOFF]
Lloh67:
	ldr	w1, [x8]
	bl	_pm_runtime_set_autosuspend_delay
	ldr	x0, [x21, #48]
	bl	_pm_runtime_use_autosuspend
	ldr	x0, [x21, #48]
	bl	_pm_runtime_enable
	mov	x0, x19
	bl	_mmc_add_host
	mov	x22, x0
	cbz	w0, LBB0_14
; %bb.42:
	ldr	x0, [x21, #48]
	bl	_pm_runtime_disable
LBB0_43:
	mov	x0, x20
	mov	x1, #0
	bl	_platform_set_drvdata
	mov	x0, x21
	bl	_msdc_deinit_hw
	mov	x0, x21
	bl	_msdc_gate_clock
	ldr	x2, [x21, #40]
	b	LBB0_45
LBB0_44:
Lloh68:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh69:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh70:
	ldr	w8, [x8]
	neg	w22, w8
LBB0_45:
	cbz	x2, LBB0_47
; %bb.46:
	ldr	w3, [x23]
	mov	x0, x20
	mov	w1, #8
	bl	_dma_free_coherent
LBB0_47:
	ldr	x2, [x21, #24]
	cbz	x2, LBB0_13
; %bb.48:
	ldr	w8, [x24]
	lsl	w1, w8, #2
	ldr	w3, [x25]
	mov	x0, x20
	bl	_dma_free_coherent
	b	LBB0_13
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpAdd	Lloh8, Lloh9
	.loh AdrpAdd	Lloh10, Lloh11
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpAdd	Lloh14, Lloh15
	.loh AdrpAdd	Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpAdd	Lloh21, Lloh22
	.loh AdrpAdd	Lloh23, Lloh24
	.loh AdrpAdd	Lloh25, Lloh26
	.loh AdrpAdd	Lloh27, Lloh28
	.loh AdrpLdrGotLdr	Lloh31, Lloh32, Lloh33
	.loh AdrpLdrGot	Lloh29, Lloh30
	.loh AdrpLdrGotLdr	Lloh34, Lloh35, Lloh36
	.loh AdrpLdrGotLdr	Lloh37, Lloh38, Lloh39
	.loh AdrpLdrGot	Lloh54, Lloh55
	.loh AdrpLdr	Lloh52, Lloh53
	.loh AdrpLdrGot	Lloh50, Lloh51
	.loh AdrpLdrGot	Lloh48, Lloh49
	.loh AdrpLdrGot	Lloh46, Lloh47
	.loh AdrpLdrGotLdr	Lloh43, Lloh44, Lloh45
	.loh AdrpLdrGotLdr	Lloh40, Lloh41, Lloh42
	.loh AdrpLdrGotLdr	Lloh62, Lloh63, Lloh64
	.loh AdrpLdrGotLdr	Lloh59, Lloh60, Lloh61
	.loh AdrpLdrGotLdr	Lloh56, Lloh57, Lloh58
	.loh AdrpLdrGotLdr	Lloh65, Lloh66, Lloh67
	.loh AdrpLdrGotLdr	Lloh68, Lloh69, Lloh70
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"No DT found\n"

	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.comm	_IORESOURCE_MEM,4,2             ; @IORESOURCE_MEM
l_.str.1:                               ; @.str.1
	.asciz	"source"

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

l_.str.3:                               ; @.str.3
	.asciz	"bus_clk"

l_.str.4:                               ; @.str.4
	.asciz	"source_cg"

l_.str.5:                               ; @.str.5
	.asciz	"Cannot find pinctrl!\n"

l_.str.6:                               ; @.str.6
	.asciz	"default"

l_.str.7:                               ; @.str.7
	.asciz	"Cannot find pinctrl default!\n"

l_.str.8:                               ; @.str.8
	.asciz	"state_uhs"

l_.str.9:                               ; @.str.9
	.asciz	"Cannot find pinctrl uhs!\n"

	.comm	_mt_msdc_ops,4,2                ; @mt_msdc_ops
	.comm	_MMC_CAP_NONREMOVABLE,4,2       ; @MMC_CAP_NONREMOVABLE
	.comm	_MMC_CAP_SDIO_IRQ,4,2           ; @MMC_CAP_SDIO_IRQ
	.comm	_MMC_CAP2_SDIO_IRQ_NOTHREAD,4,2 ; @MMC_CAP2_SDIO_IRQ_NOTHREAD
	.comm	_MMC_CAP_ERASE,4,2              ; @MMC_CAP_ERASE
	.comm	_MMC_CAP_CMD23,4,2              ; @MMC_CAP_CMD23
	.comm	_MAX_BD_NUM,4,2                 ; @MAX_BD_NUM
	.comm	_BDMA_DESC_BUFLEN_EXT,4,2       ; @BDMA_DESC_BUFLEN_EXT
	.comm	_BDMA_DESC_BUFLEN,4,2           ; @BDMA_DESC_BUFLEN
	.comm	_GFP_KERNEL,4,2                 ; @GFP_KERNEL
	.comm	_msdc_request_timeout,4,2       ; @msdc_request_timeout
	.comm	_msdc_irq,4,2                   ; @msdc_irq
	.comm	_IRQF_TRIGGER_NONE,4,2          ; @IRQF_TRIGGER_NONE
	.comm	_MTK_MMC_AUTOSUSPEND_DELAY,4,2  ; @MTK_MMC_AUTOSUSPEND_DELAY
	.no_dead_strip	_msdc_drv_probe
.subsections_via_symbols
