	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function get_flash_id
_get_flash_id:                          ## @get_flash_id
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%rbx
	pushq	%rax
	.cfi_offset %rbx, -24
	xorl	%eax, %eax
	callq	_kick_open
	movl	$128, %edi
	callq	_inb
	movl	%eax, -12(%rbp)
	movq	_FLASH_BASE@GOTPCREL(%rip), %rbx
	movq	(%rbx), %rax
	movb	$-112, 32768(%rax)
	movl	$15, %edi
	callq	_udelay
	movq	(%rbx), %rax
	movzbl	(%rax), %eax
	movl	%eax, -16(%rbp)
	movl	$128, %edi
	callq	_inb
	movl	%eax, -12(%rbp)
	movl	-16(%rbp), %ecx
	movq	(%rbx), %rax
	cmpl	$176, %ecx
	jne	LBB0_2
## %bb.1:
	movzbl	2(%rax), %ecx
	jmp	LBB0_3
LBB0_2:
	movzbl	1(%rax), %ecx
LBB0_3:
	movl	%ecx, -12(%rbp)
	movl	-16(%rbp), %ecx
	shll	$8, %ecx
	addl	%ecx, -12(%rbp)
	movb	$-1, 32768(%rax)
	movl	-12(%rbp), %eax
	movq	_KFLASH_ID4@GOTPCREL(%rip), %rcx
	cmpl	(%rcx), %eax
	jne	LBB0_5
## %bb.4:
	movq	_KFLASH_SIZE4@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movq	_gbFlashSize@GOTPCREL(%rip), %rcx
	movl	%eax, (%rcx)
LBB0_5:
	movl	-12(%rbp), %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_FLASH_BASE,8,3                 ## @FLASH_BASE
	.comm	_KFLASH_ID4,4,2                 ## @KFLASH_ID4
	.comm	_KFLASH_SIZE4,4,2               ## @KFLASH_SIZE4
	.comm	_gbFlashSize,4,2                ## @gbFlashSize
	.no_dead_strip	_get_flash_id
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function get_flash_id
_get_flash_id:                          ; @get_flash_id
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #48
	.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
	bl	_kick_open
	mov	w0, #128
	bl	_inb
Lloh0:
	adrp	x19, _FLASH_BASE@GOTPAGE
Lloh1:
	ldr	x19, [x19, _FLASH_BASE@GOTPAGEOFF]
	str	w0, [sp, #8]
	ldr	x8, [x19]
	mov	w9, #32768
	mov	w10, #144
	strb	w10, [x8, x9]
	mov	w0, #15
	bl	_udelay
	ldr	x8, [x19]
	ldrb	w8, [x8]
	str	w8, [sp, #12]
	mov	w0, #128
	bl	_inb
	str	w0, [sp, #8]
	ldr	w9, [sp, #12]
	ldr	x8, [x19]
	cmp	w9, #176
	b.ne	LBB0_2
; %bb.1:
	ldrb	w9, [x8, #2]
	b	LBB0_3
LBB0_2:
	ldrb	w9, [x8, #1]
LBB0_3:
	str	w9, [sp, #8]
	ldr	w9, [sp, #12]
	ldr	w10, [sp, #8]
	add	w9, w10, w9, lsl #8
	str	w9, [sp, #8]
	mov	w9, #32768
	mov	w10, #255
	strb	w10, [x8, x9]
	ldr	w8, [sp, #8]
Lloh2:
	adrp	x9, _KFLASH_ID4@GOTPAGE
Lloh3:
	ldr	x9, [x9, _KFLASH_ID4@GOTPAGEOFF]
Lloh4:
	ldr	w9, [x9]
	cmp	w8, w9
	b.ne	LBB0_5
; %bb.4:
Lloh5:
	adrp	x8, _KFLASH_SIZE4@GOTPAGE
Lloh6:
	ldr	x8, [x8, _KFLASH_SIZE4@GOTPAGEOFF]
Lloh7:
	ldr	w8, [x8]
Lloh8:
	adrp	x9, _gbFlashSize@GOTPAGE
Lloh9:
	ldr	x9, [x9, _gbFlashSize@GOTPAGEOFF]
Lloh10:
	str	w8, [x9]
LBB0_5:
	ldr	w0, [sp, #8]
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #48
	ret
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGotStr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.cfi_endproc
                                        ; -- End function
	.comm	_FLASH_BASE,8,3                 ; @FLASH_BASE
	.comm	_KFLASH_ID4,4,2                 ; @KFLASH_ID4
	.comm	_KFLASH_SIZE4,4,2               ; @KFLASH_SIZE4
	.comm	_gbFlashSize,4,2                ; @gbFlashSize
	.no_dead_strip	_get_flash_id
.subsections_via_symbols
