	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function mmc_spi_response_get
_mmc_spi_response_get:                  ## @mmc_spi_response_get
	.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
	subq	$72, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%edx, -100(%rbp)                ## 4-byte Spill
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	movq	8(%rdi), %rax
	movq	(%rax), %r13
	movq	%rdi, -96(%rbp)                 ## 8-byte Spill
	movslq	16(%rdi), %rbx
	movl	(%rsi), %r14d
	movq	%rsi, -88(%rbp)                 ## 8-byte Spill
	movq	%rsi, %rdi
	callq	_maptype
	leaq	L_.str(%rip), %rdx
	leaq	-80(%rbp), %rdi
	movl	$32, %esi
	movl	%r14d, %ecx
	movq	%rax, %r8
	callq	_snprintf
	leaq	32(%r13), %r15
	leaq	(,%rbx,4), %r14
	addq	%r13, %r14
	cmpq	$9, %rbx
	jl	LBB0_1
## %bb.2:
	movq	-88(%rbp), %rdi                 ## 8-byte Reload
	.p2align	4, 0x90
LBB0_3:                                 ## =>This Inner Loop Header: Depth=1
	cmpl	$255, (%r15)
	jne	LBB0_5
## %bb.4:                               ##   in Loop: Header=BB0_3 Depth=1
	addq	$4, %r15
	cmpq	%r14, %r15
	jb	LBB0_3
LBB0_5:
	cmpq	%r14, %r15
	je	LBB0_13
LBB0_6:
	movl	(%r15), %r12d
	xorl	%r13d, %r13d
	jmp	LBB0_7
LBB0_1:
	movq	-88(%rbp), %rdi                 ## 8-byte Reload
	cmpq	%r14, %r15
	jne	LBB0_6
LBB0_13:
	movq	-96(%rbp), %r14                 ## 8-byte Reload
	movq	8(%r14), %rax
	movq	(%rax), %r15
	movq	%r14, %rdi
	movl	$1, %esi
	callq	_mmc_spi_readbytes
	movl	%eax, %r13d
	testl	%eax, %eax
	js	LBB0_101
## %bb.14:
	leaq	4(%r15), %r14
	movl	(%r15), %r12d
	cmpl	$255, %r12d
	jne	LBB0_31
## %bb.15:
	movq	-96(%rbp), %rdi                 ## 8-byte Reload
	movl	$1, %esi
	callq	_mmc_spi_readbytes
	movl	%eax, %r13d
	testl	%eax, %eax
	js	LBB0_16
## %bb.17:
	movl	(%r15), %r12d
	cmpl	$255, %r12d
	jne	LBB0_31
## %bb.18:
	movq	-96(%rbp), %rdi                 ## 8-byte Reload
	movl	$1, %esi
	callq	_mmc_spi_readbytes
	movl	%eax, %r13d
	testl	%eax, %eax
	js	LBB0_16
## %bb.19:
	movl	(%r15), %r12d
	cmpl	$255, %r12d
	jne	LBB0_31
## %bb.20:
	movq	-96(%rbp), %rdi                 ## 8-byte Reload
	movl	$1, %esi
	callq	_mmc_spi_readbytes
	movl	%eax, %r13d
	testl	%eax, %eax
	js	LBB0_16
## %bb.21:
	movl	(%r15), %r12d
	cmpl	$255, %r12d
	jne	LBB0_31
## %bb.22:
	movq	-96(%rbp), %rdi                 ## 8-byte Reload
	movl	$1, %esi
	callq	_mmc_spi_readbytes
	movl	%eax, %r13d
	testl	%eax, %eax
	js	LBB0_16
## %bb.23:
	movl	(%r15), %r12d
	cmpl	$255, %r12d
	jne	LBB0_31
## %bb.24:
	movq	-96(%rbp), %rdi                 ## 8-byte Reload
	movl	$1, %esi
	callq	_mmc_spi_readbytes
	movl	%eax, %r13d
	testl	%eax, %eax
	js	LBB0_16
## %bb.25:
	movl	(%r15), %r12d
	cmpl	$255, %r12d
	jne	LBB0_31
## %bb.26:
	movq	-96(%rbp), %rdi                 ## 8-byte Reload
	movl	$1, %esi
	callq	_mmc_spi_readbytes
	movl	%eax, %r13d
	testl	%eax, %eax
	js	LBB0_16
## %bb.27:
	movl	(%r15), %r12d
	cmpl	$255, %r12d
	jne	LBB0_31
## %bb.28:
	movq	-96(%rbp), %rdi                 ## 8-byte Reload
	movl	$1, %esi
	callq	_mmc_spi_readbytes
	movl	%eax, %r13d
	testl	%eax, %eax
	js	LBB0_16
## %bb.29:
	movl	(%r15), %eax
	cmpl	$255, %eax
	jne	LBB0_30
## %bb.32:
	movq	-96(%rbp), %rdi                 ## 8-byte Reload
	movl	$1, %esi
	callq	_mmc_spi_readbytes
	movl	%eax, %r13d
	testl	%eax, %eax
	js	LBB0_16
## %bb.33:
	movl	(%r15), %eax
	cmpl	$255, %eax
	jne	LBB0_30
## %bb.34:
	movq	-96(%rbp), %rdi                 ## 8-byte Reload
	movl	$1, %esi
	callq	_mmc_spi_readbytes
	movl	%eax, %r13d
	testl	%eax, %eax
	js	LBB0_16
## %bb.35:
	movl	(%r15), %eax
	cmpl	$255, %eax
	jne	LBB0_30
## %bb.36:
	movq	-96(%rbp), %rdi                 ## 8-byte Reload
	movl	$1, %esi
	callq	_mmc_spi_readbytes
	movl	%eax, %r13d
	testl	%eax, %eax
	js	LBB0_16
## %bb.37:
	movl	(%r15), %eax
	cmpl	$255, %eax
	jne	LBB0_30
## %bb.38:
	movq	-96(%rbp), %rdi                 ## 8-byte Reload
	movl	$1, %esi
	callq	_mmc_spi_readbytes
	movl	%eax, %r13d
	testl	%eax, %eax
	js	LBB0_16
## %bb.39:
	movl	(%r15), %eax
	cmpl	$255, %eax
	jne	LBB0_30
## %bb.40:
	movq	-96(%rbp), %rdi                 ## 8-byte Reload
	movl	$1, %esi
	callq	_mmc_spi_readbytes
	movl	%eax, %r13d
	testl	%eax, %eax
	js	LBB0_16
## %bb.41:
	movl	(%r15), %eax
	cmpl	$255, %eax
	jne	LBB0_30
## %bb.42:
	movq	-96(%rbp), %rdi                 ## 8-byte Reload
	movl	$1, %esi
	callq	_mmc_spi_readbytes
	movl	%eax, %r13d
	testl	%eax, %eax
	js	LBB0_16
## %bb.43:
	movl	(%r15), %r12d
	cmpl	$255, %r12d
	movq	-88(%rbp), %rdi                 ## 8-byte Reload
	jne	LBB0_7
## %bb.44:
	movq	_ETIMEDOUT@GOTPCREL(%rip), %rax
	movq	-96(%rbp), %r14                 ## 8-byte Reload
	jmp	LBB0_45
LBB0_16:
	movq	-96(%rbp), %r14                 ## 8-byte Reload
	jmp	LBB0_101
LBB0_30:
	movl	%eax, %r12d
LBB0_31:
	movq	-88(%rbp), %rdi                 ## 8-byte Reload
LBB0_7:
	testb	$-128, %r12b
	jne	LBB0_8
## %bb.49:
	movq	8(%rdi), %rax
	movw	%r12w, (%rax)
	xorl	%ebx, %ebx
	movl	%r12d, %eax
	xorl	%r12d, %r12d
	jmp	LBB0_50
LBB0_8:
	addq	$4, %r15
	cmpq	%r14, %r15
	jne	LBB0_11
## %bb.9:
	movq	-96(%rbp), %r14                 ## 8-byte Reload
	movq	%r14, %rdi
	movl	$1, %esi
	callq	_mmc_spi_readbytes
	movl	%eax, %r13d
	testl	%eax, %eax
	js	LBB0_101
## %bb.10:
	movq	8(%r14), %rax
	movq	(%rax), %r15
	leaq	4(%r15), %r14
	movq	-88(%rbp), %rdi                 ## 8-byte Reload
LBB0_11:
	shll	$8, %r12d
	orl	(%r15), %r12d
	movzwl	%r12w, %ecx
	xorl	%ebx, %ebx
	testl	$32768, %r12d                   ## imm = 0x8000
	jne	LBB0_46
## %bb.12:
	movl	%ecx, %eax
	jmp	LBB0_48
LBB0_46:
	xorl	%ebx, %ebx
	.p2align	4, 0x90
LBB0_47:                                ## =>This Inner Loop Header: Depth=1
	incl	%ebx
	leal	(%rcx,%rcx), %r12d
	movzwl	%r12w, %eax
	testl	$16384, %ecx                    ## imm = 0x4000
	movl	%eax, %ecx
	jne	LBB0_47
LBB0_48:
	shrl	$8, %eax
	movq	8(%rdi), %rcx
	movw	%ax, (%rcx)
	shll	$8, %r12d
LBB0_50:
	movl	$0, 16(%rdi)
	testw	%ax, %ax
	je	LBB0_60
## %bb.51:
	movzwl	%ax, %eax
	movq	_R1_SPI_PARAMETER@GOTPCREL(%rip), %rcx
	movq	_R1_SPI_ADDRESS@GOTPCREL(%rip), %rdx
	movl	(%rdx), %edx
	orl	(%rcx), %edx
	testl	%eax, %edx
	je	LBB0_53
## %bb.52:
	movq	_EFAULT@GOTPCREL(%rip), %rax
	jmp	LBB0_59
LBB0_53:
	movq	_R1_SPI_ILLEGAL_COMMAND@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	je	LBB0_55
## %bb.54:
	movq	_ENOSYS@GOTPCREL(%rip), %rax
	jmp	LBB0_59
LBB0_55:
	movq	_R1_SPI_COM_CRC@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	je	LBB0_57
## %bb.56:
	movq	_EILSEQ@GOTPCREL(%rip), %rax
	jmp	LBB0_59
LBB0_57:
	movq	_R1_SPI_ERASE_SEQ@GOTPCREL(%rip), %rcx
	movq	_R1_SPI_ERASE_RESET@GOTPCREL(%rip), %rdx
	movl	(%rdx), %edx
	orl	(%rcx), %edx
	testl	%eax, %edx
	je	LBB0_60
## %bb.58:
	movq	_EIO@GOTPCREL(%rip), %rax
LBB0_59:
	xorl	%r13d, %r13d
	subl	(%rax), %r13d
LBB0_60:
	callq	_mmc_spi_resp_type
                                        ## kill: def $eax killed $eax def $rax
	addl	$-128, %eax
	cmpl	$3, %eax
	ja	LBB0_96
## %bb.61:
	addq	$4, %r15
	leaq	LJTI0_0(%rip), %rcx
	movslq	(%rcx,%rax,4), %rax
	addq	%rcx, %rax
	movl	%r12d, %edx
	movq	-88(%rbp), %rsi                 ## 8-byte Reload
	jmpq	*%rax
LBB0_72:
	movq	8(%rsi), %rax
	movw	$0, 2(%rax)
	cmpq	%r14, %r15
	jne	LBB0_75
## %bb.73:
	movq	-96(%rbp), %r14                 ## 8-byte Reload
	movq	%r14, %rdi
	movl	$1, %esi
	callq	_mmc_spi_readbytes
	movl	%eax, %r13d
	testl	%eax, %eax
	js	LBB0_101
## %bb.74:
	movq	8(%r14), %rax
	movq	(%rax), %r15
	leaq	4(%r15), %r14
	movl	%r12d, %edx
	movq	-88(%rbp), %rsi                 ## 8-byte Reload
LBB0_75:
	movl	(%r15), %eax
	testl	%ebx, %ebx
	je	LBB0_77
## %bb.76:
	movl	%ebx, %ecx
	shll	%cl, %eax
	orl	%eax, %edx
	movzbl	%dh, %edx
	movq	8(%rsi), %rcx
	orw	2(%rcx), %dx
	movw	%dx, 2(%rcx)
	shll	$8, %eax
	movl	%eax, %r12d
	jmp	LBB0_78
	.p2align	4, 0x90
LBB0_62:                                ## =>This Inner Loop Header: Depth=1
	cmpq	%r14, %r15
	jae	LBB0_65
## %bb.63:                              ##   in Loop: Header=BB0_62 Depth=1
	cmpl	$0, (%r15)
	jne	LBB0_65
## %bb.64:                              ##   in Loop: Header=BB0_62 Depth=1
	addq	$4, %r15
	jmp	LBB0_62
LBB0_96:
	movq	-96(%rbp), %r14                 ## 8-byte Reload
	movq	(%r14), %r15
	movq	-88(%rbp), %rbx                 ## 8-byte Reload
	movq	%rbx, %rdi
	callq	_mmc_spi_resp_type
	leaq	L_.str.1(%rip), %rsi
	movq	%r15, %rdi
	movl	%eax, %edx
	xorl	%eax, %eax
	callq	_dev_dbg
	movq	%rbx, %rdi
	testl	%r13d, %r13d
	js	LBB0_102
## %bb.97:
	movq	_EINVAL@GOTPCREL(%rip), %rax
LBB0_45:
	movl	(%rax), %eax
	movl	%eax, %r13d
	negl	%r13d
	testl	%eax, %eax
	jg	LBB0_102
	jmp	LBB0_104
LBB0_67:
	cmpq	%r14, %r15
	jne	LBB0_70
## %bb.68:
	movq	-96(%rbp), %r14                 ## 8-byte Reload
	movq	%r14, %rdi
	movl	$1, %esi
	callq	_mmc_spi_readbytes
	movl	%eax, %r13d
	testl	%eax, %eax
	js	LBB0_101
## %bb.69:
	movq	8(%r14), %rax
	movq	(%rax), %r15
	movl	%r12d, %edx
	movq	-88(%rbp), %rsi                 ## 8-byte Reload
LBB0_70:
	movl	(%r15), %eax
	testl	%ebx, %ebx
	je	LBB0_98
## %bb.71:
	movl	%ebx, %ecx
	shll	%cl, %eax
	andl	$-256, %eax
	movq	8(%rsi), %rcx
	orw	(%rcx), %dx
	orl	%eax, %edx
	movw	%dx, (%rcx)
	testl	%r13d, %r13d
	jns	LBB0_103
	jmp	LBB0_100
LBB0_65:
	cmpq	%r14, %r15
	jne	LBB0_99
## %bb.66:
	movq	_r1b_timeout@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	-96(%rbp), %rdi                 ## 8-byte Reload
	callq	_mmc_spi_wait_unbusy
	movq	-88(%rbp), %rsi                 ## 8-byte Reload
	testl	%r13d, %r13d
	jns	LBB0_103
	jmp	LBB0_100
LBB0_77:
	movq	8(%rsi), %rcx
	orw	2(%rcx), %ax
	movw	%ax, 2(%rcx)
	movl	%eax, %edx
LBB0_78:
	addq	$4, %r15
	shll	$8, %edx
	movw	%dx, 2(%rcx)
	cmpq	%r14, %r15
	jne	LBB0_81
## %bb.79:
	movq	-96(%rbp), %r14                 ## 8-byte Reload
	movq	%r14, %rdi
	movl	$1, %esi
	callq	_mmc_spi_readbytes
	movl	%eax, %r13d
	testl	%eax, %eax
	js	LBB0_101
## %bb.80:
	movq	8(%r14), %rax
	movq	(%rax), %r15
	leaq	4(%r15), %r14
	movq	-88(%rbp), %rsi                 ## 8-byte Reload
LBB0_81:
	movl	(%r15), %eax
	testl	%ebx, %ebx
	je	LBB0_83
## %bb.82:
	movl	%ebx, %ecx
	shll	%cl, %eax
	movl	%r12d, %edx
	orl	%eax, %edx
	movzbl	%dh, %eax
	movq	8(%rsi), %rcx
	orw	2(%rcx), %ax
	movw	%ax, 2(%rcx)
	shll	$8, %edx
	jmp	LBB0_84
LBB0_98:
	movq	8(%rsi), %rcx
	shll	$8, %eax
	orw	%ax, (%rcx)
LBB0_99:
	testl	%r13d, %r13d
	js	LBB0_100
LBB0_103:
	cmpl	$0, -100(%rbp)                  ## 4-byte Folded Reload
	movq	-96(%rbp), %r14                 ## 8-byte Reload
	jne	LBB0_105
	jmp	LBB0_104
LBB0_83:
	movq	8(%rsi), %rcx
	orw	2(%rcx), %ax
	movw	%ax, 2(%rcx)
	movl	%r12d, %edx
LBB0_84:
	addq	$4, %r15
	shll	$8, %eax
	movw	%ax, 2(%rcx)
	cmpq	%r14, %r15
	jne	LBB0_87
## %bb.85:
	movl	%edx, %r12d
	movq	-96(%rbp), %r14                 ## 8-byte Reload
	movq	%r14, %rdi
	movl	$1, %esi
	callq	_mmc_spi_readbytes
	movl	%eax, %r13d
	testl	%eax, %eax
	js	LBB0_101
## %bb.86:
	movq	8(%r14), %rax
	movq	(%rax), %r15
	leaq	4(%r15), %r14
	movl	%r12d, %edx
	movq	-88(%rbp), %rsi                 ## 8-byte Reload
LBB0_87:
	movl	(%r15), %eax
	testl	%ebx, %ebx
	je	LBB0_89
## %bb.88:
	movl	%ebx, %ecx
	shll	%cl, %eax
	orl	%eax, %edx
	movzbl	%dh, %eax
	movq	8(%rsi), %rcx
	orw	2(%rcx), %ax
	movw	%ax, 2(%rcx)
	shll	$8, %edx
	jmp	LBB0_90
LBB0_89:
	movq	8(%rsi), %rcx
	orw	2(%rcx), %ax
	movw	%ax, 2(%rcx)
LBB0_90:
	addq	$4, %r15
	shll	$8, %eax
	movw	%ax, 2(%rcx)
	cmpq	%r14, %r15
	jne	LBB0_93
## %bb.91:
	movl	%edx, %r12d
	movq	-96(%rbp), %r14                 ## 8-byte Reload
	movq	%r14, %rdi
	movl	$1, %esi
	callq	_mmc_spi_readbytes
	movl	%eax, %r13d
	testl	%eax, %eax
	js	LBB0_101
## %bb.92:
	movq	8(%r14), %rax
	movq	(%rax), %r15
	movl	%r12d, %edx
	movq	-88(%rbp), %rsi                 ## 8-byte Reload
LBB0_93:
	movl	(%r15), %eax
	testl	%ebx, %ebx
	je	LBB0_95
## %bb.94:
	movl	%ebx, %ecx
	shll	%cl, %eax
	orl	%eax, %edx
	movzbl	%dh, %eax
LBB0_95:
	movq	8(%rsi), %rcx
	orw	%ax, 2(%rcx)
	testl	%r13d, %r13d
	jns	LBB0_103
LBB0_100:
	movq	-96(%rbp), %r14                 ## 8-byte Reload
	movq	(%r14), %rdi
	movq	8(%rsi), %rax
	movzwl	(%rax), %ecx
	movzwl	2(%rax), %r8d
	leaq	L_.str.2(%rip), %rsi
	leaq	-80(%rbp), %rdx
	xorl	%eax, %eax
	callq	_dev_dbg
LBB0_101:
	movq	-88(%rbp), %rdi                 ## 8-byte Reload
LBB0_102:
	movl	%r13d, 16(%rdi)
LBB0_104:
	movq	%r14, %rdi
	callq	_mmc_cs_off
LBB0_105:
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_107
## %bb.106:
	movl	%r13d, %eax
	addq	$72, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_107:
	callq	___stack_chk_fail
	.cfi_endproc
	.p2align	2, 0x90
	.data_region jt32
.set L0_0_set_72, LBB0_72-LJTI0_0
.set L0_0_set_67, LBB0_67-LJTI0_0
.set L0_0_set_62, LBB0_62-LJTI0_0
.set L0_0_set_99, LBB0_99-LJTI0_0
LJTI0_0:
	.long	L0_0_set_72
	.long	L0_0_set_67
	.long	L0_0_set_62
	.long	L0_0_set_99
	.end_data_region
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"  ... CMD%d response SPI_%s"

	.comm	_ETIMEDOUT,4,2                  ## @ETIMEDOUT
	.comm	_R1_SPI_PARAMETER,4,2           ## @R1_SPI_PARAMETER
	.comm	_R1_SPI_ADDRESS,4,2             ## @R1_SPI_ADDRESS
	.comm	_EFAULT,4,2                     ## @EFAULT
	.comm	_R1_SPI_ILLEGAL_COMMAND,4,2     ## @R1_SPI_ILLEGAL_COMMAND
	.comm	_ENOSYS,4,2                     ## @ENOSYS
	.comm	_R1_SPI_COM_CRC,4,2             ## @R1_SPI_COM_CRC
	.comm	_EILSEQ,4,2                     ## @EILSEQ
	.comm	_R1_SPI_ERASE_SEQ,4,2           ## @R1_SPI_ERASE_SEQ
	.comm	_R1_SPI_ERASE_RESET,4,2         ## @R1_SPI_ERASE_RESET
	.comm	_EIO,4,2                        ## @EIO
	.comm	_r1b_timeout,4,2                ## @r1b_timeout
L_.str.1:                               ## @.str.1
	.asciz	"bad response type %04x\n"

	.comm	_EINVAL,4,2                     ## @EINVAL
L_.str.2:                               ## @.str.2
	.asciz	"%s: resp %04x %08x\n"

	.no_dead_strip	_mmc_spi_response_get
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function mmc_spi_response_get
_mmc_spi_response_get:                  ; @mmc_spi_response_get
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #160
	.cfi_def_cfa_offset 160
	stp	x28, x27, [sp, #64]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #80]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #96]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #112]            ; 16-byte Folded Spill
	stp	x20, x19, [sp, #128]            ; 16-byte Folded Spill
	stp	x29, x30, [sp, #144]            ; 16-byte Folded Spill
	add	x29, sp, #144
	.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
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	mov	x21, x2
	mov	x20, x1
	mov	x19, x0
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	str	x8, [sp, #56]
	ldr	x8, [x0, #8]
	ldr	x24, [x8]
	ldrsw	x25, [x0, #16]
	add	x23, x24, x25, lsl #2
	ldr	w22, [x1]
	mov	x0, x1
	bl	_maptype
	mov	x4, x0
Lloh3:
	adrp	x2, l_.str@PAGE
Lloh4:
	add	x2, x2, l_.str@PAGEOFF
	add	x0, sp, #24
	mov	w1, #32
	mov	x3, x22
	bl	_snprintf
	add	x24, x24, #32
	cmp	w25, #9
	b.lt	LBB0_3
LBB0_1:                                 ; =>This Inner Loop Header: Depth=1
	ldr	w8, [x24]
	cmp	w8, #255
	b.ne	LBB0_3
; %bb.2:                                ;   in Loop: Header=BB0_1 Depth=1
	add	x24, x24, #4
	cmp	x24, x23
	b.lo	LBB0_1
LBB0_3:
	cmp	x24, x23
	b.eq	LBB0_15
; %bb.4:
	mov	w22, #0
	ldr	w27, [x24]
LBB0_5:
	tbnz	w27, #7, LBB0_7
; %bb.6:
	mov	w25, #0
	mov	w26, #0
	and	w8, w27, #0xffff
	ldr	x9, [x20, #8]
	strh	w27, [x9]
	str	wzr, [x20, #16]
	cbnz	w8, LBB0_13
	b	LBB0_51
LBB0_7:
	add	x24, x24, #4
	cmp	x24, x23
	b.ne	LBB0_10
; %bb.8:
	mov	x0, x19
	mov	w1, #1
	bl	_mmc_spi_readbytes
	mov	x22, x0
	tbnz	w0, #31, LBB0_95
; %bb.9:
	ldr	x8, [x19, #8]
	ldr	x24, [x8]
	add	x23, x24, #4
LBB0_10:
	lsl	w8, w27, #8
	ldr	w9, [x24]
	orr	w9, w9, w8
	and	w8, w9, #0xffff
	mov	w25, #0
	tbz	w9, #15, LBB0_12
LBB0_11:                                ; =>This Inner Loop Header: Depth=1
	mov	x10, x8
	add	w25, w25, #1
	lsl	w9, w8, #1
	and	w8, w9, #0xfffe
	tbnz	w10, #14, LBB0_11
LBB0_12:
	lsr	w8, w8, #8
	ldr	x10, [x20, #8]
	strh	w8, [x10]
	lsl	w26, w9, #8
	str	wzr, [x20, #16]
	cbz	w8, LBB0_51
LBB0_13:
Lloh5:
	adrp	x9, _R1_SPI_PARAMETER@GOTPAGE
Lloh6:
	ldr	x9, [x9, _R1_SPI_PARAMETER@GOTPAGEOFF]
Lloh7:
	ldr	w9, [x9]
Lloh8:
	adrp	x10, _R1_SPI_ADDRESS@GOTPAGE
Lloh9:
	ldr	x10, [x10, _R1_SPI_ADDRESS@GOTPAGEOFF]
Lloh10:
	ldr	w10, [x10]
	orr	w9, w10, w9
	tst	w9, w8
	b.eq	LBB0_44
; %bb.14:
Lloh11:
	adrp	x8, _EFAULT@GOTPAGE
Lloh12:
	ldr	x8, [x8, _EFAULT@GOTPAGEOFF]
	b	LBB0_50
LBB0_15:
	ldr	x8, [x19, #8]
	ldr	x24, [x8]
	mov	x0, x19
	mov	w1, #1
	bl	_mmc_spi_readbytes
	mov	x22, x0
	tbnz	w0, #31, LBB0_95
; %bb.16:
	add	x23, x24, #4
	ldr	w27, [x24]
	cmp	w27, #255
	b.ne	LBB0_5
; %bb.17:
	mov	x0, x19
	mov	w1, #1
	bl	_mmc_spi_readbytes
	mov	x22, x0
	tbnz	w0, #31, LBB0_95
; %bb.18:
	ldr	w27, [x24]
	cmp	w27, #255
	b.ne	LBB0_5
; %bb.19:
	mov	x0, x19
	mov	w1, #1
	bl	_mmc_spi_readbytes
	mov	x22, x0
	tbnz	w0, #31, LBB0_95
; %bb.20:
	ldr	w27, [x24]
	cmp	w27, #255
	b.ne	LBB0_5
; %bb.21:
	mov	x0, x19
	mov	w1, #1
	bl	_mmc_spi_readbytes
	mov	x22, x0
	tbnz	w0, #31, LBB0_95
; %bb.22:
	ldr	w27, [x24]
	cmp	w27, #255
	b.ne	LBB0_5
; %bb.23:
	mov	x0, x19
	mov	w1, #1
	bl	_mmc_spi_readbytes
	mov	x22, x0
	tbnz	w0, #31, LBB0_95
; %bb.24:
	ldr	w27, [x24]
	cmp	w27, #255
	b.ne	LBB0_5
; %bb.25:
	mov	x0, x19
	mov	w1, #1
	bl	_mmc_spi_readbytes
	mov	x22, x0
	tbnz	w0, #31, LBB0_95
; %bb.26:
	ldr	w27, [x24]
	cmp	w27, #255
	b.ne	LBB0_5
; %bb.27:
	mov	x0, x19
	mov	w1, #1
	bl	_mmc_spi_readbytes
	mov	x22, x0
	tbnz	w0, #31, LBB0_95
; %bb.28:
	ldr	w27, [x24]
	cmp	w27, #255
	b.ne	LBB0_5
; %bb.29:
	mov	x0, x19
	mov	w1, #1
	bl	_mmc_spi_readbytes
	mov	x22, x0
	tbnz	w0, #31, LBB0_95
; %bb.30:
	ldr	w27, [x24]
	cmp	w27, #255
	b.ne	LBB0_5
; %bb.31:
	mov	x0, x19
	mov	w1, #1
	bl	_mmc_spi_readbytes
	mov	x22, x0
	tbnz	w0, #31, LBB0_95
; %bb.32:
	ldr	w27, [x24]
	cmp	w27, #255
	b.ne	LBB0_5
; %bb.33:
	mov	x0, x19
	mov	w1, #1
	bl	_mmc_spi_readbytes
	mov	x22, x0
	tbnz	w0, #31, LBB0_95
; %bb.34:
	ldr	w27, [x24]
	cmp	w27, #255
	b.ne	LBB0_5
; %bb.35:
	mov	x0, x19
	mov	w1, #1
	bl	_mmc_spi_readbytes
	mov	x22, x0
	tbnz	w0, #31, LBB0_95
; %bb.36:
	ldr	w27, [x24]
	cmp	w27, #255
	b.ne	LBB0_5
; %bb.37:
	mov	x0, x19
	mov	w1, #1
	bl	_mmc_spi_readbytes
	mov	x22, x0
	tbnz	w0, #31, LBB0_95
; %bb.38:
	ldr	w27, [x24]
	cmp	w27, #255
	b.ne	LBB0_5
; %bb.39:
	mov	x0, x19
	mov	w1, #1
	bl	_mmc_spi_readbytes
	mov	x22, x0
	tbnz	w0, #31, LBB0_95
; %bb.40:
	ldr	w27, [x24]
	cmp	w27, #255
	b.ne	LBB0_5
; %bb.41:
	mov	x0, x19
	mov	w1, #1
	bl	_mmc_spi_readbytes
	mov	x22, x0
	tbnz	w0, #31, LBB0_95
; %bb.42:
	ldr	w27, [x24]
	cmp	w27, #255
	b.ne	LBB0_5
; %bb.43:
Lloh13:
	adrp	x8, _ETIMEDOUT@GOTPAGE
Lloh14:
	ldr	x8, [x8, _ETIMEDOUT@GOTPAGEOFF]
	b	LBB0_61
LBB0_44:
Lloh15:
	adrp	x9, _R1_SPI_ILLEGAL_COMMAND@GOTPAGE
Lloh16:
	ldr	x9, [x9, _R1_SPI_ILLEGAL_COMMAND@GOTPAGEOFF]
Lloh17:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_46
; %bb.45:
Lloh18:
	adrp	x8, _ENOSYS@GOTPAGE
Lloh19:
	ldr	x8, [x8, _ENOSYS@GOTPAGEOFF]
	b	LBB0_50
LBB0_46:
Lloh20:
	adrp	x9, _R1_SPI_COM_CRC@GOTPAGE
Lloh21:
	ldr	x9, [x9, _R1_SPI_COM_CRC@GOTPAGEOFF]
Lloh22:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_48
; %bb.47:
Lloh23:
	adrp	x8, _EILSEQ@GOTPAGE
Lloh24:
	ldr	x8, [x8, _EILSEQ@GOTPAGEOFF]
	b	LBB0_50
LBB0_48:
Lloh25:
	adrp	x9, _R1_SPI_ERASE_SEQ@GOTPAGE
Lloh26:
	ldr	x9, [x9, _R1_SPI_ERASE_SEQ@GOTPAGEOFF]
Lloh27:
	ldr	w9, [x9]
Lloh28:
	adrp	x10, _R1_SPI_ERASE_RESET@GOTPAGE
Lloh29:
	ldr	x10, [x10, _R1_SPI_ERASE_RESET@GOTPAGEOFF]
Lloh30:
	ldr	w10, [x10]
	orr	w9, w10, w9
	tst	w9, w8
	b.eq	LBB0_51
; %bb.49:
Lloh31:
	adrp	x8, _EIO@GOTPAGE
Lloh32:
	ldr	x8, [x8, _EIO@GOTPAGEOFF]
LBB0_50:
	ldr	w8, [x8]
	neg	w22, w8
LBB0_51:
	mov	x0, x20
	bl	_mmc_spi_resp_type
	sub	w9, w0, #128
	cmp	w9, #3
	b.hi	LBB0_59
; %bb.52:
	add	x8, x24, #4
Lloh33:
	adrp	x10, lJTI0_0@PAGE
Lloh34:
	add	x10, x10, lJTI0_0@PAGEOFF
	adr	x11, LBB0_53
	ldrb	w12, [x10, x9]
	add	x11, x11, x12, lsl #2
	br	x11
LBB0_53:
	ldr	x9, [x20, #8]
	strh	wzr, [x9, #2]
	cmp	x8, x23
	b.eq	LBB0_67
; %bb.54:
	ldr	w10, [x8]
	cbz	w25, LBB0_69
LBB0_55:
	lsl	w11, w10, w25
	orr	w9, w26, w11
	and	w10, w9, #0xff00
	ldr	x9, [x20, #8]
	ldrh	w12, [x9, #2]
	orr	w10, w12, w10, lsr #8
	strh	w10, [x9, #2]
	lsl	w26, w11, #8
	b	LBB0_70
LBB0_56:                                ; =>This Inner Loop Header: Depth=1
	cmp	x8, x23
	b.hs	LBB0_65
; %bb.57:                               ;   in Loop: Header=BB0_56 Depth=1
	ldr	w9, [x8]
	cbnz	w9, LBB0_65
; %bb.58:                               ;   in Loop: Header=BB0_56 Depth=1
	add	x8, x8, #4
	b	LBB0_56
LBB0_59:
	ldr	x21, [x19]
	mov	x0, x20
	bl	_mmc_spi_resp_type
                                        ; kill: def $w0 killed $w0 def $x0
	str	x0, [sp]
Lloh35:
	adrp	x1, l_.str.1@PAGE
Lloh36:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x0, x21
	bl	_dev_dbg
	tbnz	w22, #31, LBB0_95
; %bb.60:
Lloh37:
	adrp	x8, _EINVAL@GOTPAGE
Lloh38:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
LBB0_61:
	ldr	w8, [x8]
	neg	w22, w8
	cmp	w8, #1
	b.ge	LBB0_95
	b	LBB0_96
LBB0_62:
	cmp	x8, x23
	b.eq	LBB0_73
; %bb.63:
	ldr	w8, [x8]
	cbz	w25, LBB0_75
LBB0_64:
	lsl	w8, w8, w25
	and	w8, w8, #0xff00
	ldr	x9, [x20, #8]
	ldrh	w10, [x9]
	orr	w10, w10, w26
	orr	w8, w10, w8
	b	LBB0_76
LBB0_65:
	cmp	x8, x23
	b.ne	LBB0_91
; %bb.66:
Lloh39:
	adrp	x8, _r1b_timeout@GOTPAGE
Lloh40:
	ldr	x8, [x8, _r1b_timeout@GOTPAGEOFF]
Lloh41:
	ldr	w1, [x8]
	mov	x0, x19
	bl	_mmc_spi_wait_unbusy
	tbz	w22, #31, LBB0_92
	b	LBB0_94
LBB0_67:
	mov	x0, x19
	mov	w1, #1
	bl	_mmc_spi_readbytes
	mov	x22, x0
	tbnz	w0, #31, LBB0_95
; %bb.68:
	ldr	x8, [x19, #8]
	ldr	x8, [x8]
	add	x23, x8, #4
	ldr	w10, [x8]
	cbnz	w25, LBB0_55
LBB0_69:
	ldr	x9, [x20, #8]
	ldrh	w11, [x9, #2]
	orr	w10, w11, w10
	strh	w10, [x9, #2]
LBB0_70:
	add	x8, x8, #4
	lsl	w10, w10, #8
	strh	w10, [x9, #2]
	cmp	x8, x23
	b.eq	LBB0_77
; %bb.71:
	ldr	w10, [x8]
	cbz	w25, LBB0_79
LBB0_72:
	lsl	w9, w10, w25
	orr	w11, w26, w9
	and	w10, w11, #0xff00
	ldr	x9, [x20, #8]
	ldrh	w12, [x9, #2]
	orr	w10, w12, w10, lsr #8
	strh	w10, [x9, #2]
	lsl	w26, w11, #8
	b	LBB0_80
LBB0_73:
	mov	x0, x19
	mov	w1, #1
	bl	_mmc_spi_readbytes
	mov	x22, x0
	tbnz	w0, #31, LBB0_95
; %bb.74:
	ldr	x8, [x19, #8]
	ldr	x8, [x8]
	ldr	w8, [x8]
	cbnz	w25, LBB0_64
LBB0_75:
	ldr	x9, [x20, #8]
	ldrh	w10, [x9]
	orr	w8, w10, w8, lsl #8
LBB0_76:
	strh	w8, [x9]
	tbz	w22, #31, LBB0_92
	b	LBB0_94
LBB0_77:
	mov	x0, x19
	mov	w1, #1
	bl	_mmc_spi_readbytes
	mov	x22, x0
	tbnz	w0, #31, LBB0_95
; %bb.78:
	ldr	x8, [x19, #8]
	ldr	x8, [x8]
	add	x23, x8, #4
	ldr	w10, [x8]
	cbnz	w25, LBB0_72
LBB0_79:
	ldr	x9, [x20, #8]
	ldrh	w11, [x9, #2]
	orr	w10, w11, w10
	strh	w10, [x9, #2]
LBB0_80:
	add	x8, x8, #4
	lsl	w10, w10, #8
	strh	w10, [x9, #2]
	cmp	x8, x23
	b.eq	LBB0_83
; %bb.81:
	ldr	w10, [x8]
	cbz	w25, LBB0_85
LBB0_82:
	lsl	w9, w10, w25
	orr	w11, w26, w9
	and	w10, w11, #0xff00
	ldr	x9, [x20, #8]
	ldrh	w12, [x9, #2]
	orr	w10, w12, w10, lsr #8
	strh	w10, [x9, #2]
	lsl	w26, w11, #8
	b	LBB0_86
LBB0_83:
	mov	x0, x19
	mov	w1, #1
	bl	_mmc_spi_readbytes
	mov	x22, x0
	tbnz	w0, #31, LBB0_95
; %bb.84:
	ldr	x8, [x19, #8]
	ldr	x8, [x8]
	add	x23, x8, #4
	ldr	w10, [x8]
	cbnz	w25, LBB0_82
LBB0_85:
	ldr	x9, [x20, #8]
	ldrh	w11, [x9, #2]
	orr	w10, w11, w10
	strh	w10, [x9, #2]
LBB0_86:
	add	x8, x8, #4
	lsl	w10, w10, #8
	strh	w10, [x9, #2]
	cmp	x8, x23
	b.ne	LBB0_89
; %bb.87:
	mov	x0, x19
	mov	w1, #1
	bl	_mmc_spi_readbytes
	mov	x22, x0
	tbnz	w0, #31, LBB0_95
; %bb.88:
	ldr	x8, [x19, #8]
	ldr	x8, [x8]
LBB0_89:
	ldr	w8, [x8]
	cbz	w25, LBB0_93
; %bb.90:
	lsl	w8, w8, w25
	orr	w8, w26, w8
	and	w8, w8, #0xff00
	ldr	x9, [x20, #8]
	ldrh	w10, [x9, #2]
	orr	w8, w10, w8, lsr #8
	strh	w8, [x9, #2]
LBB0_91:
	tbnz	w22, #31, LBB0_94
LBB0_92:
	cbnz	w21, LBB0_97
	b	LBB0_96
LBB0_93:
	ldr	x9, [x20, #8]
	ldrh	w10, [x9, #2]
	orr	w8, w10, w8
	strh	w8, [x9, #2]
	tbz	w22, #31, LBB0_92
LBB0_94:
	ldr	x0, [x19]
	ldr	x8, [x20, #8]
	ldrh	w9, [x8]
	ldrh	w8, [x8, #2]
	stp	x9, x8, [sp, #8]
	add	x8, sp, #24
	str	x8, [sp]
Lloh42:
	adrp	x1, l_.str.2@PAGE
Lloh43:
	add	x1, x1, l_.str.2@PAGEOFF
	bl	_dev_dbg
LBB0_95:
	str	w22, [x20, #16]
LBB0_96:
	mov	x0, x19
	bl	_mmc_cs_off
LBB0_97:
	ldr	x8, [sp, #56]
Lloh44:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh45:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh46:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_99
; %bb.98:
	mov	x0, x22
	ldp	x29, x30, [sp, #144]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #128]            ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #112]            ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #96]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #80]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #64]             ; 16-byte Folded Reload
	add	sp, sp, #160
	ret
LBB0_99:
	bl	___stack_chk_fail
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh11, Lloh12
	.loh AdrpLdrGot	Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGot	Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.loh AdrpLdrGot	Lloh23, Lloh24
	.loh AdrpLdrGotLdr	Lloh28, Lloh29, Lloh30
	.loh AdrpLdrGotLdr	Lloh25, Lloh26, Lloh27
	.loh AdrpLdrGot	Lloh31, Lloh32
	.loh AdrpAdd	Lloh33, Lloh34
	.loh AdrpAdd	Lloh35, Lloh36
	.loh AdrpLdrGot	Lloh37, Lloh38
	.loh AdrpLdrGotLdr	Lloh39, Lloh40, Lloh41
	.loh AdrpAdd	Lloh42, Lloh43
	.loh AdrpLdrGotLdr	Lloh44, Lloh45, Lloh46
	.cfi_endproc
	.section	__TEXT,__const
lJTI0_0:
	.byte	(LBB0_53-LBB0_53)>>2
	.byte	(LBB0_62-LBB0_53)>>2
	.byte	(LBB0_56-LBB0_53)>>2
	.byte	(LBB0_91-LBB0_53)>>2
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"  ... CMD%d response SPI_%s"

	.comm	_ETIMEDOUT,4,2                  ; @ETIMEDOUT
	.comm	_R1_SPI_PARAMETER,4,2           ; @R1_SPI_PARAMETER
	.comm	_R1_SPI_ADDRESS,4,2             ; @R1_SPI_ADDRESS
	.comm	_EFAULT,4,2                     ; @EFAULT
	.comm	_R1_SPI_ILLEGAL_COMMAND,4,2     ; @R1_SPI_ILLEGAL_COMMAND
	.comm	_ENOSYS,4,2                     ; @ENOSYS
	.comm	_R1_SPI_COM_CRC,4,2             ; @R1_SPI_COM_CRC
	.comm	_EILSEQ,4,2                     ; @EILSEQ
	.comm	_R1_SPI_ERASE_SEQ,4,2           ; @R1_SPI_ERASE_SEQ
	.comm	_R1_SPI_ERASE_RESET,4,2         ; @R1_SPI_ERASE_RESET
	.comm	_EIO,4,2                        ; @EIO
	.comm	_r1b_timeout,4,2                ; @r1b_timeout
l_.str.1:                               ; @.str.1
	.asciz	"bad response type %04x\n"

	.comm	_EINVAL,4,2                     ; @EINVAL
l_.str.2:                               ; @.str.2
	.asciz	"%s: resp %04x %08x\n"

	.no_dead_strip	_mmc_spi_response_get
.subsections_via_symbols
