	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function set_cmd_regs
_set_cmd_regs:                          ## @set_cmd_regs
	.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
	movl	%edx, %r14d
	movl	%esi, %r13d
	callq	_mtd_to_flctl
	movq	%rax, %r15
	movq	_SEL_16BIT@GOTPCREL(%rip), %rax
	movl	(%rax), %r9d
	movl	%r9d, %ebx
	notl	%ebx
	andl	(%r15), %ebx
	movq	_SNAND_E@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	%esi, %eax
	orl	%ebx, %eax
	notl	%esi
	andl	%esi, %ebx
	cmpq	$0, 16(%r15)
	cmovnel	%eax, %ebx
	movq	_DOCMD1_E@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	_DOADR_E@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	%edi, %r12d
	orl	%edx, %r12d
	xorl	%r8d, %r8d
	addl	$-128, %r13d
	cmpl	$8, %r13d
	ja	LBB0_9
## %bb.1:
	leaq	LJTI0_0(%rip), %rax
	movslq	(%rax,%r13,4), %rcx
	addq	%rax, %rcx
	jmpq	*%rcx
LBB0_3:
	movq	_CDSRC_E@GOTPCREL(%rip), %rax
	orl	(%rax), %r12d
	jmp	LBB0_4
LBB0_7:
	andl	%esi, %ebx
	movq	_DOSR_E@GOTPCREL(%rip), %rax
	orl	(%rax), %edi
LBB0_8:
	notl	%edi
	andl	%edi, %edx
	movl	%edx, %r12d
	jmp	LBB0_9
LBB0_6:
	andl	%esi, %ebx
	movq	_CDSRC_E@GOTPCREL(%rip), %rax
	orl	(%rax), %r12d
	movq	_ADRCNT_1@GOTPCREL(%rip), %rax
	movl	(%rax), %r8d
	jmp	LBB0_9
LBB0_5:
	movq	_DOCMD2_E@GOTPCREL(%rip), %rax
	movq	_CDSRC_E@GOTPCREL(%rip), %rcx
	movq	_SELRW@GOTPCREL(%rip), %rdx
	orl	(%rax), %r12d
	orl	(%rcx), %r12d
	orl	(%rdx), %r12d
LBB0_4:
	movq	_NAND_BUSWIDTH_16@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	andl	12(%r15), %eax
	movl	8(%r15), %r8d
	cmovel	%eax, %r9d
	orl	%r9d, %ebx
	jmp	LBB0_9
LBB0_2:
	movl	4(%r15), %r8d
	movq	_DOCMD2_E@GOTPCREL(%rip), %rax
	orl	(%rax), %r12d
LBB0_9:
	orl	%r8d, %r12d
	movq	%r15, %rdi
	callq	_FLCMNCR
	movl	%ebx, %edi
	movl	%eax, %esi
	callq	_writel
	movq	%r15, %rdi
	callq	_FLCMDCR
	movl	%r12d, %edi
	movl	%eax, %esi
	callq	_writel
	movq	%r15, %rdi
	callq	_FLCMCDR
	movl	%r14d, %edi
	movl	%eax, %esi
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_writel                         ## TAILCALL
	.cfi_endproc
	.p2align	2, 0x90
	.data_region jt32
.set L0_0_set_7, LBB0_7-LJTI0_0
.set L0_0_set_8, LBB0_8-LJTI0_0
.set L0_0_set_3, LBB0_3-LJTI0_0
.set L0_0_set_6, LBB0_6-LJTI0_0
.set L0_0_set_5, LBB0_5-LJTI0_0
.set L0_0_set_2, LBB0_2-LJTI0_0
LJTI0_0:
	.long	L0_0_set_7
	.long	L0_0_set_8
	.long	L0_0_set_3
	.long	L0_0_set_7
	.long	L0_0_set_3
	.long	L0_0_set_6
	.long	L0_0_set_3
	.long	L0_0_set_5
	.long	L0_0_set_2
	.end_data_region
                                        ## -- End function
	.comm	_SEL_16BIT,4,2                  ## @SEL_16BIT
	.comm	_SNAND_E,4,2                    ## @SNAND_E
	.comm	_DOCMD1_E,4,2                   ## @DOCMD1_E
	.comm	_DOADR_E,4,2                    ## @DOADR_E
	.comm	_DOCMD2_E,4,2                   ## @DOCMD2_E
	.comm	_CDSRC_E,4,2                    ## @CDSRC_E
	.comm	_NAND_BUSWIDTH_16,4,2           ## @NAND_BUSWIDTH_16
	.comm	_SELRW,4,2                      ## @SELRW
	.comm	_ADRCNT_1,4,2                   ## @ADRCNT_1
	.comm	_DOSR_E,4,2                     ## @DOSR_E
	.no_dead_strip	_set_cmd_regs
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function set_cmd_regs
_set_cmd_regs:                          ; @set_cmd_regs
	.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, x2
	mov	x22, x1
	bl	_mtd_to_flctl
	mov	x20, x0
	ldr	w8, [x0]
Lloh0:
	adrp	x9, _SEL_16BIT@GOTPAGE
Lloh1:
	ldr	x9, [x9, _SEL_16BIT@GOTPAGEOFF]
Lloh2:
	ldr	w10, [x9]
	bic	w8, w8, w10
	ldr	x11, [x0, #16]
Lloh3:
	adrp	x9, _SNAND_E@GOTPAGE
Lloh4:
	ldr	x9, [x9, _SNAND_E@GOTPAGEOFF]
Lloh5:
	ldr	w9, [x9]
	orr	w12, w9, w8
	bic	w8, w8, w9
	cmp	x11, #0
	csel	w21, w8, w12, eq
Lloh6:
	adrp	x8, _DOCMD1_E@GOTPAGE
Lloh7:
	ldr	x8, [x8, _DOCMD1_E@GOTPAGEOFF]
Lloh8:
	ldr	w11, [x8]
Lloh9:
	adrp	x8, _DOADR_E@GOTPAGE
Lloh10:
	ldr	x8, [x8, _DOADR_E@GOTPAGEOFF]
Lloh11:
	ldr	w12, [x8]
	orr	w8, w12, w11
	sub	w14, w22, #128
	cmp	w14, #8
	b.hi	LBB0_4
; %bb.1:
	mvn	w13, w9
Lloh12:
	adrp	x9, lJTI0_0@PAGE
Lloh13:
	add	x9, x9, lJTI0_0@PAGEOFF
	adr	x15, LBB0_2
	ldrb	w16, [x9, x14]
	add	x15, x15, x16, lsl #2
	br	x15
LBB0_2:
Lloh14:
	adrp	x9, _CDSRC_E@GOTPAGE
Lloh15:
	ldr	x9, [x9, _CDSRC_E@GOTPAGEOFF]
Lloh16:
	ldr	w9, [x9]
	orr	w8, w9, w8
	b	LBB0_8
LBB0_3:
	mov	w9, #0
	and	w21, w21, w13
Lloh17:
	adrp	x8, _DOSR_E@GOTPAGE
Lloh18:
	ldr	x8, [x8, _DOSR_E@GOTPAGEOFF]
Lloh19:
	ldr	w8, [x8]
	orr	w8, w8, w12
	bic	w8, w11, w8
	b	LBB0_10
LBB0_4:
	mov	w9, #0
	b	LBB0_10
LBB0_5:
	mov	w9, #0
	bic	w8, w11, w12
	b	LBB0_10
LBB0_6:
Lloh20:
	adrp	x9, _CDSRC_E@GOTPAGE
Lloh21:
	ldr	x9, [x9, _CDSRC_E@GOTPAGEOFF]
	and	w21, w21, w13
Lloh22:
	ldr	w9, [x9]
	orr	w8, w9, w8
Lloh23:
	adrp	x9, _ADRCNT_1@GOTPAGE
Lloh24:
	ldr	x9, [x9, _ADRCNT_1@GOTPAGEOFF]
Lloh25:
	ldr	w9, [x9]
	b	LBB0_10
LBB0_7:
Lloh26:
	adrp	x9, _DOCMD2_E@GOTPAGE
Lloh27:
	ldr	x9, [x9, _DOCMD2_E@GOTPAGEOFF]
Lloh28:
	ldr	w9, [x9]
Lloh29:
	adrp	x11, _CDSRC_E@GOTPAGE
Lloh30:
	ldr	x11, [x11, _CDSRC_E@GOTPAGEOFF]
Lloh31:
	ldr	w11, [x11]
Lloh32:
	adrp	x12, _SELRW@GOTPAGE
Lloh33:
	ldr	x12, [x12, _SELRW@GOTPAGEOFF]
Lloh34:
	ldr	w12, [x12]
	orr	w8, w9, w8
	orr	w8, w8, w11
	orr	w8, w8, w12
LBB0_8:
	ldp	w9, w11, [x20, #8]
Lloh35:
	adrp	x12, _NAND_BUSWIDTH_16@GOTPAGE
Lloh36:
	ldr	x12, [x12, _NAND_BUSWIDTH_16@GOTPAGEOFF]
Lloh37:
	ldr	w12, [x12]
	tst	w12, w11
	csel	w10, wzr, w10, eq
	orr	w21, w10, w21
	b	LBB0_10
LBB0_9:
	ldr	w9, [x20, #4]
Lloh38:
	adrp	x10, _DOCMD2_E@GOTPAGE
Lloh39:
	ldr	x10, [x10, _DOCMD2_E@GOTPAGEOFF]
Lloh40:
	ldr	w10, [x10]
	orr	w8, w10, w8
LBB0_10:
	orr	w22, w9, w8
	mov	x0, x20
	bl	_FLCMNCR
	mov	x1, x0
	mov	x0, x21
	bl	_writel
	mov	x0, x20
	bl	_FLCMDCR
	mov	x1, x0
	mov	x0, x22
	bl	_writel
	mov	x0, x20
	bl	_FLCMCDR
	mov	x1, x0
	mov	x0, x19
	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
	b	_writel
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh23, Lloh24, Lloh25
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.loh AdrpLdrGotLdr	Lloh32, Lloh33, Lloh34
	.loh AdrpLdrGotLdr	Lloh29, Lloh30, Lloh31
	.loh AdrpLdrGotLdr	Lloh26, Lloh27, Lloh28
	.loh AdrpLdrGotLdr	Lloh35, Lloh36, Lloh37
	.loh AdrpLdrGotLdr	Lloh38, Lloh39, Lloh40
	.cfi_endproc
	.section	__TEXT,__const
lJTI0_0:
	.byte	(LBB0_3-LBB0_2)>>2
	.byte	(LBB0_5-LBB0_2)>>2
	.byte	(LBB0_2-LBB0_2)>>2
	.byte	(LBB0_3-LBB0_2)>>2
	.byte	(LBB0_2-LBB0_2)>>2
	.byte	(LBB0_6-LBB0_2)>>2
	.byte	(LBB0_2-LBB0_2)>>2
	.byte	(LBB0_7-LBB0_2)>>2
	.byte	(LBB0_9-LBB0_2)>>2
                                        ; -- End function
	.comm	_SEL_16BIT,4,2                  ; @SEL_16BIT
	.comm	_SNAND_E,4,2                    ; @SNAND_E
	.comm	_DOCMD1_E,4,2                   ; @DOCMD1_E
	.comm	_DOADR_E,4,2                    ; @DOADR_E
	.comm	_DOCMD2_E,4,2                   ; @DOCMD2_E
	.comm	_CDSRC_E,4,2                    ; @CDSRC_E
	.comm	_NAND_BUSWIDTH_16,4,2           ; @NAND_BUSWIDTH_16
	.comm	_SELRW,4,2                      ; @SELRW
	.comm	_ADRCNT_1,4,2                   ; @ADRCNT_1
	.comm	_DOSR_E,4,2                     ; @DOSR_E
	.no_dead_strip	_set_cmd_regs
.subsections_via_symbols
