	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function machxo2_spi_probe
_machxo2_spi_probe:                     ## @machxo2_spi_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	%r14
	pushq	%rbx
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movq	%rdi, %rbx
	addq	$8, %rdi
	movq	(%rbx), %rax
	movq	_MACHXO2_MAX_SPEED@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jle	LBB0_2
## %bb.1:
	leaq	L_.str(%rip), %rsi
	callq	_dev_err
	movq	_EINVAL@GOTPCREL(%rip), %rcx
	jmp	LBB0_4
LBB0_2:
	leaq	L_.str.1(%rip), %rsi
	movq	_machxo2_ops@GOTPCREL(%rip), %rdx
	movq	%rbx, %rcx
	callq	_devm_fpga_mgr_create
	testq	%rax, %rax
	je	LBB0_3
## %bb.5:
	movq	%rax, %r14
	movq	%rbx, %rdi
	movq	%rax, %rsi
	callq	_spi_set_drvdata
	movq	%r14, %rdi
	popq	%rbx
	popq	%r14
	popq	%rbp
	jmp	_fpga_mgr_register              ## TAILCALL
LBB0_3:
	movq	_ENOMEM@GOTPCREL(%rip), %rcx
LBB0_4:
	xorl	%eax, %eax
	subl	(%rcx), %eax
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_MACHXO2_MAX_SPEED,8,3          ## @MACHXO2_MAX_SPEED
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Speed is too high\n"

	.comm	_EINVAL,4,2                     ## @EINVAL
L_.str.1:                               ## @.str.1
	.asciz	"Lattice MachXO2 SPI FPGA Manager"

	.comm	_machxo2_ops,4,2                ## @machxo2_ops
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.no_dead_strip	_machxo2_spi_probe
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function machxo2_spi_probe
_machxo2_spi_probe:                     ; @machxo2_spi_probe
	.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	x8, [x0], #8
Lloh0:
	adrp	x9, _MACHXO2_MAX_SPEED@GOTPAGE
Lloh1:
	ldr	x9, [x9, _MACHXO2_MAX_SPEED@GOTPAGEOFF]
Lloh2:
	ldr	x9, [x9]
	cmp	x8, x9
	b.le	LBB0_2
; %bb.1:
Lloh3:
	adrp	x1, l_.str@PAGE
Lloh4:
	add	x1, x1, l_.str@PAGEOFF
	bl	_dev_err
Lloh5:
	adrp	x8, _EINVAL@GOTPAGE
Lloh6:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
	b	LBB0_5
LBB0_2:
Lloh7:
	adrp	x1, l_.str.1@PAGE
Lloh8:
	add	x1, x1, l_.str.1@PAGEOFF
Lloh9:
	adrp	x2, _machxo2_ops@GOTPAGE
Lloh10:
	ldr	x2, [x2, _machxo2_ops@GOTPAGEOFF]
	mov	x3, x19
	bl	_devm_fpga_mgr_create
	cbz	x0, LBB0_4
; %bb.3:
	mov	x20, x0
	mov	x0, x19
	mov	x1, x20
	bl	_spi_set_drvdata
	mov	x0, x20
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	b	_fpga_mgr_register
LBB0_4:
Lloh11:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh12:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
LBB0_5:
	ldr	w8, [x8]
	neg	w0, w8
	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 AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh9, Lloh10
	.loh AdrpAdd	Lloh7, Lloh8
	.loh AdrpLdrGot	Lloh11, Lloh12
	.cfi_endproc
                                        ; -- End function
	.comm	_MACHXO2_MAX_SPEED,8,3          ; @MACHXO2_MAX_SPEED
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Speed is too high\n"

	.comm	_EINVAL,4,2                     ; @EINVAL
l_.str.1:                               ; @.str.1
	.asciz	"Lattice MachXO2 SPI FPGA Manager"

	.comm	_machxo2_ops,4,2                ; @machxo2_ops
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.no_dead_strip	_machxo2_spi_probe
.subsections_via_symbols
