	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function imxmci_stop_clock
_imxmci_stop_clock:                     ## @imxmci_stop_clock
	.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, %r15
	movq	_MMC_REG_STR_STP_CLK@GOTPCREL(%rip), %r14
	movq	(%r14), %rdi
	addq	8(%r15), %rdi
	callq	_readw
	movq	_STR_STP_CLK_START_CLK@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edi
	notl	%edi
	andl	%eax, %edi
	movq	(%r14), %rsi
	addq	8(%r15), %rsi
	callq	_writew
	xorl	%ebx, %ebx
	movq	_MMC_REG_STATUS@GOTPCREL(%rip), %r13
	movq	_STATUS_CARD_BUS_CLK_RUN@GOTPCREL(%rip), %r12
	jmp	LBB0_1
	.p2align	4, 0x90
LBB0_5:                                 ##   in Loop: Header=BB0_1 Depth=1
	incl	%ebx
	cmpl	$4096, %ebx                     ## imm = 0x1000
	je	LBB0_6
LBB0_1:                                 ## =>This Inner Loop Header: Depth=1
	testb	$127, %bl
	jne	LBB0_3
## %bb.2:                               ##   in Loop: Header=BB0_1 Depth=1
	movq	(%r14), %rdi
	addq	8(%r15), %rdi
	callq	_readw
	movq	_STR_STP_CLK_STOP_CLK@GOTPCREL(%rip), %rcx
	orl	(%rcx), %eax
	movq	(%r14), %rsi
	addq	8(%r15), %rsi
	movl	%eax, %edi
	callq	_writew
LBB0_3:                                 ##   in Loop: Header=BB0_1 Depth=1
	movq	(%r13), %rdi
	addq	8(%r15), %rdi
	callq	_readw
	testl	%eax, (%r12)
	jne	LBB0_5
## %bb.4:                               ##   in Loop: Header=BB0_1 Depth=1
	movq	(%r13), %rdi
	addq	8(%r15), %rdi
	callq	_readw
	testl	%eax, (%r12)
	jne	LBB0_5
## %bb.7:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_6:
	movl	(%r15), %edi
	callq	_mmc_dev
	leaq	L_.str(%rip), %rsi
	movl	%eax, %edi
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_dev_dbg                        ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_MMC_REG_STR_STP_CLK,8,3        ## @MMC_REG_STR_STP_CLK
	.comm	_STR_STP_CLK_START_CLK,4,2      ## @STR_STP_CLK_START_CLK
	.comm	_STR_STP_CLK_STOP_CLK,4,2       ## @STR_STP_CLK_STOP_CLK
	.comm	_MMC_REG_STATUS,8,3             ## @MMC_REG_STATUS
	.comm	_STATUS_CARD_BUS_CLK_RUN,4,2    ## @STATUS_CARD_BUS_CLK_RUN
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"imxmci_stop_clock blocked, no luck\n"

	.no_dead_strip	_imxmci_stop_clock
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function imxmci_stop_clock
_imxmci_stop_clock:                     ; @imxmci_stop_clock
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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
	ldr	x8, [x0, #8]
Lloh0:
	adrp	x20, _MMC_REG_STR_STP_CLK@GOTPAGE
Lloh1:
	ldr	x20, [x20, _MMC_REG_STR_STP_CLK@GOTPAGEOFF]
	ldr	x9, [x20]
	add	x0, x9, x8
	bl	_readw
Lloh2:
	adrp	x8, _STR_STP_CLK_START_CLK@GOTPAGE
Lloh3:
	ldr	x8, [x8, _STR_STP_CLK_START_CLK@GOTPAGEOFF]
Lloh4:
	ldr	w8, [x8]
	bic	w0, w0, w8
	ldr	x8, [x19, #8]
	ldr	x9, [x20]
	add	x1, x9, x8
	bl	_writew
	mov	w21, #0
Lloh5:
	adrp	x22, _STR_STP_CLK_STOP_CLK@GOTPAGE
Lloh6:
	ldr	x22, [x22, _STR_STP_CLK_STOP_CLK@GOTPAGEOFF]
Lloh7:
	adrp	x23, _MMC_REG_STATUS@GOTPAGE
Lloh8:
	ldr	x23, [x23, _MMC_REG_STATUS@GOTPAGEOFF]
Lloh9:
	adrp	x24, _STATUS_CARD_BUS_CLK_RUN@GOTPAGE
Lloh10:
	ldr	x24, [x24, _STATUS_CARD_BUS_CLK_RUN@GOTPAGEOFF]
	b	LBB0_2
LBB0_1:                                 ;   in Loop: Header=BB0_2 Depth=1
	add	w21, w21, #1
	cmp	w21, #1, lsl #12                ; =4096
	b.eq	LBB0_7
LBB0_2:                                 ; =>This Inner Loop Header: Depth=1
	tst	w21, #0x7f
	b.ne	LBB0_4
; %bb.3:                                ;   in Loop: Header=BB0_2 Depth=1
	ldr	x8, [x19, #8]
	ldr	x9, [x20]
	add	x0, x9, x8
	bl	_readw
	ldr	w8, [x22]
	orr	w0, w8, w0
	ldr	x8, [x19, #8]
	ldr	x9, [x20]
	add	x1, x9, x8
	bl	_writew
LBB0_4:                                 ;   in Loop: Header=BB0_2 Depth=1
	ldr	x8, [x19, #8]
	ldr	x9, [x23]
	add	x0, x9, x8
	bl	_readw
	ldr	w8, [x24]
	tst	w8, w0
	b.ne	LBB0_1
; %bb.5:                                ;   in Loop: Header=BB0_2 Depth=1
	ldr	x8, [x19, #8]
	ldr	x9, [x23]
	add	x0, x9, x8
	bl	_readw
	ldr	w8, [x24]
	tst	w8, w0
	b.ne	LBB0_1
; %bb.6:
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	ret
LBB0_7:
	ldr	w0, [x19]
	bl	_mmc_dev
Lloh11:
	adrp	x1, l_.str@PAGE
Lloh12:
	add	x1, x1, l_.str@PAGEOFF
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	b	_dev_dbg
	.loh AdrpLdrGot	Lloh9, Lloh10
	.loh AdrpLdrGot	Lloh7, Lloh8
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpAdd	Lloh11, Lloh12
	.cfi_endproc
                                        ; -- End function
	.comm	_MMC_REG_STR_STP_CLK,8,3        ; @MMC_REG_STR_STP_CLK
	.comm	_STR_STP_CLK_START_CLK,4,2      ; @STR_STP_CLK_START_CLK
	.comm	_STR_STP_CLK_STOP_CLK,4,2       ; @STR_STP_CLK_STOP_CLK
	.comm	_MMC_REG_STATUS,8,3             ; @MMC_REG_STATUS
	.comm	_STATUS_CARD_BUS_CLK_RUN,4,2    ; @STATUS_CARD_BUS_CLK_RUN
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"imxmci_stop_clock blocked, no luck\n"

	.no_dead_strip	_imxmci_stop_clock
.subsections_via_symbols
