	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function spi_nor_ready
_spi_nor_ready:                         ## @spi_nor_ready
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r14
	pushq	%rbx
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movq	%rdi, %rbx
	movq	_SNOR_F_READY_XSR_RDY@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	testl	%eax, (%rdi)
	je	LBB0_2
## %bb.1:
	movq	%rbx, %rdi
	callq	_s3an_sr_ready
	jmp	LBB0_3
LBB0_2:
	movq	%rbx, %rdi
	callq	_spi_nor_sr_ready
LBB0_3:
	movl	%eax, %r14d
	testl	%eax, %eax
	js	LBB0_4
## %bb.5:
	movq	_SNOR_F_USE_FSR@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	testl	%eax, (%rbx)
	je	LBB0_6
## %bb.7:
	movq	%rbx, %rdi
	callq	_spi_nor_fsr_ready
	testl	%eax, %eax
	jns	LBB0_8
	jmp	LBB0_9
LBB0_4:
	movl	%r14d, %eax
	jmp	LBB0_9
LBB0_6:
	movl	$1, %eax
LBB0_8:
	testl	%r14d, %r14d
	setne	%cl
	testl	%eax, %eax
	setne	%al
	andb	%cl, %al
	movzbl	%al, %eax
LBB0_9:
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_SNOR_F_READY_XSR_RDY,4,2       ## @SNOR_F_READY_XSR_RDY
	.comm	_SNOR_F_USE_FSR,4,2             ## @SNOR_F_USE_FSR
	.no_dead_strip	_spi_nor_ready
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function spi_nor_ready
_spi_nor_ready:                         ; @spi_nor_ready
	.cfi_startproc
; %bb.0:
	stp	x20, x19, [sp, #-32]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 32
	stp	x29, x30, [sp, #16]             ; 16-byte Folded Spill
	add	x29, sp, #16
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	mov	x19, x0
	ldr	w8, [x0]
Lloh0:
	adrp	x9, _SNOR_F_READY_XSR_RDY@GOTPAGE
Lloh1:
	ldr	x9, [x9, _SNOR_F_READY_XSR_RDY@GOTPAGEOFF]
Lloh2:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_4
; %bb.1:
	bl	_s3an_sr_ready
	mov	x20, x0
	tbnz	w0, #31, LBB0_5
LBB0_2:
	ldr	w8, [x19]
Lloh3:
	adrp	x9, _SNOR_F_USE_FSR@GOTPAGE
Lloh4:
	ldr	x9, [x9, _SNOR_F_USE_FSR@GOTPAGEOFF]
Lloh5:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_6
; %bb.3:
	mov	x0, x19
	bl	_spi_nor_fsr_ready
	tbz	w0, #31, LBB0_7
	b	LBB0_8
LBB0_4:
	bl	_spi_nor_sr_ready
	mov	x20, x0
	tbz	w0, #31, LBB0_2
LBB0_5:
	mov	x0, x20
	b	LBB0_8
LBB0_6:
	mov	w0, #1
LBB0_7:
	cmp	w20, #0
	ccmp	w0, #0, #4, ne
	cset	w0, ne
LBB0_8:
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.cfi_endproc
                                        ; -- End function
	.comm	_SNOR_F_READY_XSR_RDY,4,2       ; @SNOR_F_READY_XSR_RDY
	.comm	_SNOR_F_USE_FSR,4,2             ; @SNOR_F_USE_FSR
	.no_dead_strip	_spi_nor_ready
.subsections_via_symbols
