	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function _mmc_suspend
__mmc_suspend:                          ## @_mmc_suspend
	.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
	movl	%esi, %r15d
	movq	%rdi, %r12
	testl	%esi, %esi
	je	LBB0_1
## %bb.2:
	movq	_EXT_CSD_POWER_OFF_SHORT@GOTPCREL(%rip), %rax
	jmp	LBB0_3
LBB0_1:
	movq	_EXT_CSD_POWER_OFF_LONG@GOTPCREL(%rip), %rax
LBB0_3:
	movl	(%rax), %r14d
	movq	%r12, %rdi
	callq	_mmc_claim_host
	movl	4(%r12), %edi
	callq	_mmc_card_suspended
	xorl	%ebx, %ebx
	testq	%rax, %rax
	jne	LBB0_15
## %bb.4:
	movl	4(%r12), %edi
	callq	_mmc_flush_cache
	movl	%eax, %ebx
	testl	%eax, %eax
	jne	LBB0_15
## %bb.5:
	movl	4(%r12), %edi
	callq	_mmc_can_poweroff_notify
	testq	%rax, %rax
	je	LBB0_9
## %bb.6:
	testl	%r15d, %r15d
	je	LBB0_8
## %bb.7:
	movq	_MMC_CAP2_FULL_PWR_CYCLE@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	andl	(%r12), %eax
	jne	LBB0_8
LBB0_9:
	movl	4(%r12), %edi
	callq	_mmc_can_sleep
	movq	%r12, %rdi
	testq	%rax, %rax
	je	LBB0_11
## %bb.10:
	callq	_mmc_sleep
	jmp	LBB0_13
LBB0_8:
	movl	4(%r12), %edi
	movl	%r14d, %esi
	callq	_mmc_poweroff_notify
	jmp	LBB0_13
LBB0_11:
	callq	_mmc_host_is_spi
	testl	%eax, %eax
	jne	LBB0_14
## %bb.12:
	movq	%r12, %rdi
	callq	_mmc_deselect_cards
LBB0_13:
	movl	%eax, %ebx
	testl	%eax, %eax
	jne	LBB0_15
LBB0_14:
	movq	%r12, %rdi
	callq	_mmc_power_off
	movl	4(%r12), %edi
	callq	_mmc_card_set_suspended
	xorl	%ebx, %ebx
LBB0_15:
	movq	%r12, %rdi
	callq	_mmc_release_host
	movl	%ebx, %eax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_EXT_CSD_POWER_OFF_SHORT,4,2    ## @EXT_CSD_POWER_OFF_SHORT
	.comm	_EXT_CSD_POWER_OFF_LONG,4,2     ## @EXT_CSD_POWER_OFF_LONG
	.comm	_MMC_CAP2_FULL_PWR_CYCLE,4,2    ## @MMC_CAP2_FULL_PWR_CYCLE
	.no_dead_strip	__mmc_suspend
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function _mmc_suspend
__mmc_suspend:                          ; @_mmc_suspend
	.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, x1
	mov	x19, x0
Lloh0:
	adrp	x8, _EXT_CSD_POWER_OFF_SHORT@GOTPAGE
Lloh1:
	ldr	x8, [x8, _EXT_CSD_POWER_OFF_SHORT@GOTPAGEOFF]
Lloh2:
	adrp	x9, _EXT_CSD_POWER_OFF_LONG@GOTPAGE
Lloh3:
	ldr	x9, [x9, _EXT_CSD_POWER_OFF_LONG@GOTPAGEOFF]
	cmp	w1, #0
	csel	x8, x8, x9, ne
	ldr	w20, [x8]
	bl	_mmc_claim_host
	ldr	w0, [x19, #4]
	bl	_mmc_card_suspended
	cbz	x0, LBB0_2
LBB0_1:
	mov	w22, #0
	b	LBB0_12
LBB0_2:
	ldr	w0, [x19, #4]
	bl	_mmc_flush_cache
	mov	x22, x0
	cbnz	w0, LBB0_12
; %bb.3:
	ldr	w0, [x19, #4]
	bl	_mmc_can_poweroff_notify
	cbz	x0, LBB0_6
; %bb.4:
	cbz	w21, LBB0_8
; %bb.5:
	ldr	w8, [x19]
Lloh4:
	adrp	x9, _MMC_CAP2_FULL_PWR_CYCLE@GOTPAGE
Lloh5:
	ldr	x9, [x9, _MMC_CAP2_FULL_PWR_CYCLE@GOTPAGEOFF]
Lloh6:
	ldr	w9, [x9]
	and	w8, w9, w8
	cbnz	w8, LBB0_8
LBB0_6:
	ldr	w0, [x19, #4]
	bl	_mmc_can_sleep
	cbz	x0, LBB0_9
; %bb.7:
	mov	x0, x19
	bl	_mmc_sleep
	mov	x22, x0
	cbnz	w0, LBB0_12
	b	LBB0_10
LBB0_8:
	ldr	w0, [x19, #4]
	mov	x1, x20
	bl	_mmc_poweroff_notify
	mov	x22, x0
	cbnz	w0, LBB0_12
	b	LBB0_10
LBB0_9:
	mov	x0, x19
	bl	_mmc_host_is_spi
	cbz	w0, LBB0_11
LBB0_10:
	mov	x0, x19
	bl	_mmc_power_off
	ldr	w0, [x19, #4]
	bl	_mmc_card_set_suspended
	b	LBB0_1
LBB0_11:
	mov	x0, x19
	bl	_mmc_deselect_cards
	mov	x22, x0
	cbz	w0, LBB0_10
LBB0_12:
	mov	x0, x19
	bl	_mmc_release_host
	mov	x0, x22
	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 AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh4, Lloh5, Lloh6
	.cfi_endproc
                                        ; -- End function
	.comm	_EXT_CSD_POWER_OFF_SHORT,4,2    ; @EXT_CSD_POWER_OFF_SHORT
	.comm	_EXT_CSD_POWER_OFF_LONG,4,2     ; @EXT_CSD_POWER_OFF_LONG
	.comm	_MMC_CAP2_FULL_PWR_CYCLE,4,2    ; @MMC_CAP2_FULL_PWR_CYCLE
	.no_dead_strip	__mmc_suspend
.subsections_via_symbols
