	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function generic_onenand_probe
_generic_onenand_probe:                 ## @generic_onenand_probe
	.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	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %rbx
	callq	_dev_get_platdata
	movq	%rax, -64(%rbp)                 ## 8-byte Spill
	movq	8(%rbx), %r12
	movq	%r12, %rdi
	callq	_resource_size
	movq	%rax, %r13
	movq	_GFP_KERNEL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	$32, %edi
	callq	_kzalloc
	testq	%rax, %rax
	je	LBB0_1
## %bb.2:
	movq	%rax, %r15
	movq	%rbx, %rdi
	movq	%rax, %r14
	movq	%r13, %rbx
	movl	(%r12), %r13d
	movq	%rdi, -48(%rbp)                 ## 8-byte Spill
	callq	_dev_name
	movl	%r13d, %edi
	movq	%rbx, %r13
	movq	%rbx, %rsi
	movl	%eax, %edx
	callq	_request_mem_region
	testl	%eax, %eax
	je	LBB0_3
## %bb.4:
	movq	%r12, -56(%rbp)                 ## 8-byte Spill
	movl	(%r12), %edi
	movq	%r13, %rsi
	callq	_ioremap
	movl	%eax, (%r14)
	testl	%eax, %eax
	movq	%r14, %rbx
	je	LBB0_5
## %bb.6:
	movq	-64(%rbp), %r12                 ## 8-byte Reload
	testq	%r12, %r12
	je	LBB0_7
## %bb.8:
	movq	16(%r12), %rax
	jmp	LBB0_9
LBB0_1:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
	jmp	LBB0_17
LBB0_3:
	movq	_EBUSY@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	jmp	LBB0_12
LBB0_5:
	movq	%rbx, %r14
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	jmp	LBB0_11
LBB0_7:
	xorl	%eax, %eax
LBB0_9:
	movq	-48(%rbp), %r14                 ## 8-byte Reload
	movq	%rax, 8(%rbx)
	movq	%r14, %rdi
	xorl	%esi, %esi
	callq	_platform_get_irq
	movl	%eax, 4(%rbx)
	addq	$16, %r15
	movq	%r14, 24(%rbx)
	movq	%rbx, 16(%rbx)
	movq	%r15, %rdi
	movl	$1, %esi
	callq	_onenand_scan
	testq	%rax, %rax
	je	LBB0_13
## %bb.10:
	movq	_ENXIO@GOTPCREL(%rip), %rax
	movq	%rbx, %rcx
	movl	(%rax), %ebx
	movq	%rcx, %r14
	movl	(%rcx), %edi
	callq	_iounmap
LBB0_11:
	movq	-56(%rbp), %rax                 ## 8-byte Reload
	movl	(%rax), %edi
	movq	%r13, %rsi
	callq	_release_mem_region
LBB0_12:
	negl	%ebx
	movq	%r14, %rdi
	callq	_kfree
LBB0_17:
	movl	%ebx, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_13:
	testq	%r12, %r12
	je	LBB0_14
## %bb.15:
	movq	8(%r12), %rsi
	movl	(%r12), %edx
	jmp	LBB0_16
LBB0_14:
	xorl	%esi, %esi
	xorl	%edx, %edx
LBB0_16:
	movq	%r15, %rdi
                                        ## kill: def $edx killed $edx killed $rdx
	callq	_mtd_device_register
	movq	%r14, %rdi
	movq	%rbx, %rsi
	callq	_platform_set_drvdata
	xorl	%ebx, %ebx
	jmp	LBB0_17
	.cfi_endproc
                                        ## -- End function
	.comm	_GFP_KERNEL,4,2                 ## @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.comm	_EBUSY,4,2                      ## @EBUSY
	.comm	_ENXIO,4,2                      ## @ENXIO
	.no_dead_strip	_generic_onenand_probe
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function generic_onenand_probe
_generic_onenand_probe:                 ; @generic_onenand_probe
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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
	mov	x20, x0
	bl	_dev_get_platdata
	mov	x23, x0
	ldr	x21, [x20, #8]
	mov	x0, x21
	bl	_resource_size
	mov	x22, x0
Lloh0:
	adrp	x8, _GFP_KERNEL@GOTPAGE
Lloh1:
	ldr	x8, [x8, _GFP_KERNEL@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	mov	w0, #32
	bl	_kzalloc
	cbz	x0, LBB0_5
; %bb.1:
	mov	x19, x0
	ldr	w24, [x21]
	mov	x0, x20
	bl	_dev_name
	mov	x2, x0
	mov	x0, x24
	mov	x1, x22
	bl	_request_mem_region
	cbz	w0, LBB0_6
; %bb.2:
	ldr	w0, [x21]
	mov	x1, x22
	bl	_ioremap
	str	w0, [x19]
	cbz	w0, LBB0_7
; %bb.3:
	cbz	x23, LBB0_8
; %bb.4:
	ldr	x8, [x23, #16]
	b	LBB0_9
LBB0_5:
Lloh3:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh4:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	neg	w20, w8
	b	LBB0_13
LBB0_6:
Lloh6:
	adrp	x8, _EBUSY@GOTPAGE
Lloh7:
	ldr	x8, [x8, _EBUSY@GOTPAGEOFF]
Lloh8:
	ldr	w20, [x8]
	b	LBB0_12
LBB0_7:
Lloh9:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh10:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh11:
	ldr	w20, [x8]
	b	LBB0_11
LBB0_8:
	mov	x8, #0
LBB0_9:
	str	x8, [x19, #8]
	mov	x0, x20
	mov	w1, #0
	bl	_platform_get_irq
	str	w0, [x19, #4]
	add	x24, x19, #16
	stp	x19, x20, [x19, #16]
	mov	x0, x24
	mov	w1, #1
	bl	_onenand_scan
	cbz	x0, LBB0_14
; %bb.10:
Lloh12:
	adrp	x8, _ENXIO@GOTPAGE
Lloh13:
	ldr	x8, [x8, _ENXIO@GOTPAGEOFF]
Lloh14:
	ldr	w20, [x8]
	ldr	w0, [x19]
	bl	_iounmap
LBB0_11:
	ldr	w0, [x21]
	mov	x1, x22
	bl	_release_mem_region
LBB0_12:
	neg	w20, w20
	mov	x0, x19
	bl	_kfree
LBB0_13:
	mov	x0, x20
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	ret
LBB0_14:
	cbz	x23, LBB0_16
; %bb.15:
	ldr	x1, [x23, #8]
	ldr	w2, [x23]
	b	LBB0_17
LBB0_16:
	mov	x1, #0
	mov	w2, #0
LBB0_17:
	mov	x0, x24
	bl	_mtd_device_register
	mov	x0, x20
	mov	x1, x19
	bl	_platform_set_drvdata
	mov	w20, #0
	b	LBB0_13
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.cfi_endproc
                                        ; -- End function
	.comm	_GFP_KERNEL,4,2                 ; @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.comm	_EBUSY,4,2                      ; @EBUSY
	.comm	_ENXIO,4,2                      ; @ENXIO
	.no_dead_strip	_generic_onenand_probe
.subsections_via_symbols
