	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function at25_probe
_at25_probe:                            ## @at25_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
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r14
	movq	8(%rdi), %r12
	testq	%r12, %r12
	je	LBB0_1
## %bb.2:
	movl	(%r12), %eax
	movq	_EE_ADDR1@GOTPCREL(%rip), %rcx
	movl	$1, %ebx
	testl	%eax, (%rcx)
	jne	LBB0_6
## %bb.3:
	movq	_EE_ADDR2@GOTPCREL(%rip), %rcx
	movl	$2, %ebx
	testl	%eax, (%rcx)
	jne	LBB0_6
## %bb.4:
	movq	_EE_ADDR3@GOTPCREL(%rip), %rcx
	movl	$3, %ebx
	testl	%eax, (%rcx)
	je	LBB0_5
LBB0_6:
	movq	_AT25_RDSR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r14, %rdi
	callq	_spi_w8r8
	testl	%eax, %eax
	js	LBB0_8
## %bb.7:
	movq	_AT25_SR_nRDY@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	je	LBB0_9
LBB0_8:
	leaq	L_.str.2(%rip), %rsi
	xorl	%r15d, %r15d
	movq	%r14, %rdi
	movl	%eax, %edx
	movl	%eax, %ecx
	xorl	%eax, %eax
	callq	_dev_dbg
	movq	_ENXIO@GOTPCREL(%rip), %rax
	jmp	LBB0_11
LBB0_1:
	leaq	L_.str(%rip), %rsi
	xorl	%r15d, %r15d
	movq	%r14, %rdi
	xorl	%eax, %eax
	callq	_dev_dbg
	movq	_ENODEV@GOTPCREL(%rip), %rax
LBB0_11:
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
LBB0_16:
	leaq	L_.str.9(%rip), %rsi
	movq	%r14, %rdi
	movl	%ebx, %edx
	xorl	%eax, %eax
	callq	_dev_dbg
	movq	%r15, %rdi
	callq	_kfree
LBB0_20:
	movl	%ebx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_9:
	movq	_GFP_KERNEL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	$88, %edi
	callq	_kzalloc
	testq	%rax, %rax
	je	LBB0_10
## %bb.12:
	movq	%rax, %r15
	leaq	84(%rax), %rdi
	callq	_mutex_init
	movups	(%r12), %xmm0
	movups	16(%r12), %xmm1
	movups	%xmm0, 8(%r15)
	movups	%xmm1, 24(%r15)
	movq	%r14, %rdi
	callq	_spi_dev_get
	movl	%eax, 80(%r15)
	movq	%r14, %rdi
	movq	%r15, %rsi
	callq	_dev_set_drvdata
	movl	%ebx, (%r15)
	leaq	40(%r15), %rsi
	leaq	L_.str.3(%rip), %rax
	movq	%rax, 48(%r15)
	movq	_S_IRUSR@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 56(%r15)
	movq	_at25_bin_read@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	movl	%ecx, 68(%r15)
	movq	_at25_mem_read@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	movl	%ecx, 76(%r15)
	movl	12(%r15), %ecx
	movl	%ecx, 40(%r15)
	movq	_EE_READONLY@GOTPCREL(%rip), %r13
	movl	(%r13), %ecx
	testl	%ecx, (%r12)
	jne	LBB0_14
## %bb.13:
	movq	_at25_bin_write@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	movl	%ecx, 64(%r15)
	movq	_S_IWUSR@GOTPCREL(%rip), %rcx
	orl	(%rcx), %eax
	movl	%eax, 56(%r15)
	movq	_at25_mem_write@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 72(%r15)
LBB0_14:
	movq	%r14, %rdi
	callq	_sysfs_create_bin_file
	testl	%eax, %eax
	je	LBB0_17
## %bb.15:
	movl	%eax, %ebx
	jmp	LBB0_16
LBB0_10:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	xorl	%r15d, %r15d
	jmp	LBB0_11
LBB0_5:
	leaq	L_.str.1(%rip), %rsi
	xorl	%r15d, %r15d
	movq	%r14, %rdi
	xorl	%eax, %eax
	callq	_dev_dbg
	movq	_EINVAL@GOTPCREL(%rip), %rax
	jmp	LBB0_11
LBB0_17:
	movq	24(%r12), %rax
	testq	%rax, %rax
	je	LBB0_19
## %bb.18:
	movq	%r15, %rdi
	addq	$72, %rdi
	movl	16(%r12), %esi
	callq	*%rax
LBB0_19:
	movl	40(%r15), %eax
	leal	1023(%rax), %edx
	testl	%eax, %eax
	cmovnsl	%eax, %edx
	sarl	$10, %edx
	cmpl	$1024, %eax                     ## imm = 0x400
	cmovll	%eax, %edx
	leaq	L_.str.5(%rip), %rax
	leaq	L_.str.6(%rip), %rcx
	cmovlq	%rax, %rcx
	movl	16(%r15), %eax
	movl	20(%r15), %r8d
	movl	(%r13), %esi
	andl	(%r12), %esi
	leaq	L_.str.8(%rip), %rsi
	leaq	L_.str.7(%rip), %r9
	cmoveq	%rsi, %r9
	movl	%eax, (%rsp)
	leaq	L_.str.4(%rip), %rsi
	movq	%r14, %rdi
	callq	_dev_info
	xorl	%ebx, %ebx
	jmp	LBB0_20
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"no chip description\n"

	.comm	_ENODEV,4,2                     ## @ENODEV
	.comm	_EE_ADDR1,4,2                   ## @EE_ADDR1
	.comm	_EE_ADDR2,4,2                   ## @EE_ADDR2
	.comm	_EE_ADDR3,4,2                   ## @EE_ADDR3
L_.str.1:                               ## @.str.1
	.asciz	"unsupported address type\n"

	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_AT25_RDSR,4,2                  ## @AT25_RDSR
	.comm	_AT25_SR_nRDY,4,2               ## @AT25_SR_nRDY
L_.str.2:                               ## @.str.2
	.asciz	"rdsr --> %d (%02x)\n"

	.comm	_ENXIO,4,2                      ## @ENXIO
	.comm	_GFP_KERNEL,4,2                 ## @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ## @ENOMEM
L_.str.3:                               ## @.str.3
	.asciz	"eeprom"

	.comm	_S_IRUSR,4,2                    ## @S_IRUSR
	.comm	_at25_bin_read,4,2              ## @at25_bin_read
	.comm	_at25_mem_read,4,2              ## @at25_mem_read
	.comm	_EE_READONLY,4,2                ## @EE_READONLY
	.comm	_at25_bin_write,4,2             ## @at25_bin_write
	.comm	_S_IWUSR,4,2                    ## @S_IWUSR
	.comm	_at25_mem_write,4,2             ## @at25_mem_write
L_.str.4:                               ## @.str.4
	.asciz	"%Zd %s %s eeprom%s, pagesize %u\n"

L_.str.5:                               ## @.str.5
	.asciz	"Byte"

L_.str.6:                               ## @.str.6
	.asciz	"KByte"

L_.str.7:                               ## @.str.7
	.asciz	" (readonly)"

L_.str.8:                               ## @.str.8
	.space	1

L_.str.9:                               ## @.str.9
	.asciz	"probe err %d\n"

	.no_dead_strip	_at25_probe
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function at25_probe
_at25_probe:                            ; @at25_probe
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #80
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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	x19, x0
	ldr	x22, [x0, #8]
	cbz	x22, LBB0_3
; %bb.1:
	ldr	w8, [x22]
Lloh0:
	adrp	x9, _EE_ADDR1@GOTPAGE
Lloh1:
	ldr	x9, [x9, _EE_ADDR1@GOTPAGEOFF]
Lloh2:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_4
; %bb.2:
	mov	w21, #1
	b	LBB0_8
LBB0_3:
Lloh3:
	adrp	x1, l_.str@PAGE
Lloh4:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x19
	bl	_dev_dbg
	mov	x20, #0
Lloh5:
	adrp	x8, _ENODEV@GOTPAGE
Lloh6:
	ldr	x8, [x8, _ENODEV@GOTPAGEOFF]
	b	LBB0_11
LBB0_4:
Lloh7:
	adrp	x9, _EE_ADDR2@GOTPAGE
Lloh8:
	ldr	x9, [x9, _EE_ADDR2@GOTPAGEOFF]
Lloh9:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_6
; %bb.5:
	mov	w21, #2
	b	LBB0_8
LBB0_6:
Lloh10:
	adrp	x9, _EE_ADDR3@GOTPAGE
Lloh11:
	ldr	x9, [x9, _EE_ADDR3@GOTPAGEOFF]
Lloh12:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_20
; %bb.7:
	mov	w21, #3
LBB0_8:
Lloh13:
	adrp	x8, _AT25_RDSR@GOTPAGE
Lloh14:
	ldr	x8, [x8, _AT25_RDSR@GOTPAGEOFF]
Lloh15:
	ldr	w1, [x8]
	mov	x0, x19
	bl	_spi_w8r8
                                        ; kill: def $w0 killed $w0 def $x0
	tbnz	w0, #31, LBB0_10
; %bb.9:
Lloh16:
	adrp	x8, _AT25_SR_nRDY@GOTPAGE
Lloh17:
	ldr	x8, [x8, _AT25_SR_nRDY@GOTPAGEOFF]
Lloh18:
	ldr	w8, [x8]
	tst	w8, w0
	b.eq	LBB0_14
LBB0_10:
	stp	x0, x0, [sp]
Lloh19:
	adrp	x1, l_.str.2@PAGE
Lloh20:
	add	x1, x1, l_.str.2@PAGEOFF
	mov	x0, x19
	bl	_dev_dbg
	mov	x20, #0
Lloh21:
	adrp	x8, _ENXIO@GOTPAGE
Lloh22:
	ldr	x8, [x8, _ENXIO@GOTPAGEOFF]
LBB0_11:
	ldr	w8, [x8]
	neg	w21, w8
LBB0_12:
	str	x21, [sp]
Lloh23:
	adrp	x1, l_.str.9@PAGE
Lloh24:
	add	x1, x1, l_.str.9@PAGEOFF
	mov	x0, x19
	bl	_dev_dbg
	mov	x0, x20
	bl	_kfree
LBB0_13:
	mov	x0, x21
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #80
	ret
LBB0_14:
Lloh25:
	adrp	x8, _GFP_KERNEL@GOTPAGE
Lloh26:
	ldr	x8, [x8, _GFP_KERNEL@GOTPAGEOFF]
Lloh27:
	ldr	w1, [x8]
	mov	w0, #88
	bl	_kzalloc
	mov	x20, x0
	cbz	x0, LBB0_19
; %bb.15:
	add	x0, x20, #84
	bl	_mutex_init
	ldp	q1, q0, [x22]
	stur	q1, [x20, #8]
	stur	q0, [x20, #24]
	mov	x0, x19
	bl	_spi_dev_get
	str	w0, [x20, #80]
	mov	x0, x19
	mov	x1, x20
	bl	_dev_set_drvdata
	str	w21, [x20]
	ldr	w8, [x20, #12]
	mov	x1, x20
	str	w8, [x1, #40]!
Lloh28:
	adrp	x8, l_.str.3@PAGE
Lloh29:
	add	x8, x8, l_.str.3@PAGEOFF
	str	x8, [x20, #48]
Lloh30:
	adrp	x8, _S_IRUSR@GOTPAGE
Lloh31:
	ldr	x8, [x8, _S_IRUSR@GOTPAGEOFF]
Lloh32:
	ldr	w8, [x8]
Lloh33:
	adrp	x9, _at25_bin_read@GOTPAGE
Lloh34:
	ldr	x9, [x9, _at25_bin_read@GOTPAGEOFF]
	str	w8, [x20, #56]
Lloh35:
	ldr	w9, [x9]
	str	w9, [x20, #68]
Lloh36:
	adrp	x9, _at25_mem_read@GOTPAGE
Lloh37:
	ldr	x9, [x9, _at25_mem_read@GOTPAGEOFF]
Lloh38:
	ldr	w9, [x9]
	str	w9, [x20, #76]
	ldr	w9, [x22]
Lloh39:
	adrp	x23, _EE_READONLY@GOTPAGE
Lloh40:
	ldr	x23, [x23, _EE_READONLY@GOTPAGEOFF]
	ldr	w10, [x23]
	tst	w10, w9
	b.ne	LBB0_17
; %bb.16:
Lloh41:
	adrp	x9, _at25_bin_write@GOTPAGE
Lloh42:
	ldr	x9, [x9, _at25_bin_write@GOTPAGEOFF]
Lloh43:
	ldr	w9, [x9]
	str	w9, [x20, #64]
Lloh44:
	adrp	x9, _S_IWUSR@GOTPAGE
Lloh45:
	ldr	x9, [x9, _S_IWUSR@GOTPAGEOFF]
Lloh46:
	ldr	w9, [x9]
	orr	w8, w9, w8
	str	w8, [x20, #56]
Lloh47:
	adrp	x8, _at25_mem_write@GOTPAGE
Lloh48:
	ldr	x8, [x8, _at25_mem_write@GOTPAGEOFF]
Lloh49:
	ldr	w8, [x8]
	str	w8, [x20, #72]
LBB0_17:
	mov	x0, x19
	bl	_sysfs_create_bin_file
	cbz	w0, LBB0_21
; %bb.18:
	mov	x21, x0
	b	LBB0_12
LBB0_19:
Lloh50:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh51:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
	b	LBB0_11
LBB0_20:
Lloh52:
	adrp	x1, l_.str.1@PAGE
Lloh53:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x0, x19
	bl	_dev_dbg
	mov	x20, #0
Lloh54:
	adrp	x8, _EINVAL@GOTPAGE
Lloh55:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
	b	LBB0_11
LBB0_21:
	ldr	x8, [x22, #24]
	cbz	x8, LBB0_23
; %bb.22:
	add	x0, x20, #72
	ldr	w1, [x22, #16]
	blr	x8
LBB0_23:
	ldr	w8, [x20, #40]
	add	w9, w8, #1023
	cmp	w8, #0
	csel	w9, w9, w8, lt
	asr	w9, w9, #10
Lloh56:
	adrp	x10, l_.str.6@PAGE
Lloh57:
	add	x10, x10, l_.str.6@PAGEOFF
Lloh58:
	adrp	x11, l_.str.5@PAGE
Lloh59:
	add	x11, x11, l_.str.5@PAGEOFF
	cmp	w8, #1024
	csel	w2, w8, w9, lt
	csel	x3, x11, x10, lt
	ldr	w8, [x22]
	ldr	w9, [x23]
Lloh60:
	adrp	x10, l_.str.7@PAGE
Lloh61:
	add	x10, x10, l_.str.7@PAGEOFF
Lloh62:
	adrp	x11, l_.str.8@PAGE
Lloh63:
	add	x11, x11, l_.str.8@PAGEOFF
	tst	w9, w8
	csel	x5, x11, x10, eq
	ldp	w6, w4, [x20, #16]
Lloh64:
	adrp	x1, l_.str.4@PAGE
Lloh65:
	add	x1, x1, l_.str.4@PAGEOFF
	mov	x0, x19
	bl	_dev_info
	mov	w21, #0
	b	LBB0_13
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh16, Lloh17, Lloh18
	.loh AdrpLdrGot	Lloh21, Lloh22
	.loh AdrpAdd	Lloh19, Lloh20
	.loh AdrpAdd	Lloh23, Lloh24
	.loh AdrpLdrGotLdr	Lloh25, Lloh26, Lloh27
	.loh AdrpLdrGot	Lloh39, Lloh40
	.loh AdrpLdrGotLdr	Lloh36, Lloh37, Lloh38
	.loh AdrpLdrGotLdr	Lloh33, Lloh34, Lloh35
	.loh AdrpLdrGotLdr	Lloh30, Lloh31, Lloh32
	.loh AdrpAdd	Lloh28, Lloh29
	.loh AdrpLdrGotLdr	Lloh47, Lloh48, Lloh49
	.loh AdrpLdrGotLdr	Lloh44, Lloh45, Lloh46
	.loh AdrpLdrGotLdr	Lloh41, Lloh42, Lloh43
	.loh AdrpLdrGot	Lloh50, Lloh51
	.loh AdrpLdrGot	Lloh54, Lloh55
	.loh AdrpAdd	Lloh52, Lloh53
	.loh AdrpAdd	Lloh64, Lloh65
	.loh AdrpAdd	Lloh62, Lloh63
	.loh AdrpAdd	Lloh60, Lloh61
	.loh AdrpAdd	Lloh58, Lloh59
	.loh AdrpAdd	Lloh56, Lloh57
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"no chip description\n"

	.comm	_ENODEV,4,2                     ; @ENODEV
	.comm	_EE_ADDR1,4,2                   ; @EE_ADDR1
	.comm	_EE_ADDR2,4,2                   ; @EE_ADDR2
	.comm	_EE_ADDR3,4,2                   ; @EE_ADDR3
l_.str.1:                               ; @.str.1
	.asciz	"unsupported address type\n"

	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_AT25_RDSR,4,2                  ; @AT25_RDSR
	.comm	_AT25_SR_nRDY,4,2               ; @AT25_SR_nRDY
l_.str.2:                               ; @.str.2
	.asciz	"rdsr --> %d (%02x)\n"

	.comm	_ENXIO,4,2                      ; @ENXIO
	.comm	_GFP_KERNEL,4,2                 ; @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ; @ENOMEM
l_.str.3:                               ; @.str.3
	.asciz	"eeprom"

	.comm	_S_IRUSR,4,2                    ; @S_IRUSR
	.comm	_at25_bin_read,4,2              ; @at25_bin_read
	.comm	_at25_mem_read,4,2              ; @at25_mem_read
	.comm	_EE_READONLY,4,2                ; @EE_READONLY
	.comm	_at25_bin_write,4,2             ; @at25_bin_write
	.comm	_S_IWUSR,4,2                    ; @S_IWUSR
	.comm	_at25_mem_write,4,2             ; @at25_mem_write
l_.str.4:                               ; @.str.4
	.asciz	"%Zd %s %s eeprom%s, pagesize %u\n"

l_.str.5:                               ; @.str.5
	.asciz	"Byte"

l_.str.6:                               ; @.str.6
	.asciz	"KByte"

l_.str.7:                               ; @.str.7
	.asciz	" (readonly)"

l_.str.8:                               ; @.str.8
	.space	1

l_.str.9:                               ; @.str.9
	.asciz	"probe err %d\n"

	.no_dead_strip	_at25_probe
.subsections_via_symbols
