	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function meson8b_dwmac_probe
_meson8b_dwmac_probe:                   ## @meson8b_dwmac_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	%r12
	pushq	%rbx
	subq	$16, %rsp
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r12
	leaq	-40(%rbp), %rsi
	callq	_stmmac_get_platform_resources
	movl	%eax, %ebx
	testl	%eax, %eax
	jne	LBB0_21
## %bb.1:
	leaq	-40(%rbp), %rsi
	movq	%r12, %rdi
	callq	_stmmac_probe_config_dt
	movq	%rax, %r14
	movq	%rax, %rdi
	callq	_IS_ERR
	testq	%rax, %rax
	je	LBB0_3
## %bb.2:
	movq	%r14, %rdi
	callq	_PTR_ERR
	movl	%eax, %ebx
	jmp	LBB0_21
LBB0_3:
	movq	_GFP_KERNEL@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r12, %rdi
	movl	$40, %esi
	callq	_devm_kzalloc
	testq	%rax, %rax
	je	LBB0_7
## %bb.4:
	movq	%rax, %r15
	movq	%r12, %rdi
	callq	_of_device_get_match_data
	movq	%rax, 8(%r15)
	testq	%rax, %rax
	je	LBB0_18
## %bb.5:
	movq	%r12, %rdi
	movl	$1, %esi
	callq	_devm_platform_ioremap_resource
	movq	%rax, 32(%r15)
	movq	%rax, %rdi
	callq	_IS_ERR
	testq	%rax, %rax
	je	LBB0_9
## %bb.6:
	movq	32(%r15), %rdi
	callq	_PTR_ERR
	movl	%eax, %ebx
	jmp	LBB0_20
LBB0_7:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	jmp	LBB0_19
LBB0_9:
	movq	%r12, 24(%r15)
	movl	(%r12), %edi
	callq	_of_get_phy_mode
	movq	%rax, 16(%r15)
	testl	$-2147483648, %eax              ## imm = 0x80000000
	jne	LBB0_17
## %bb.10:
	movl	(%r12), %edi
	leaq	L_.str.1(%rip), %rsi
	movq	%r15, %rdx
	callq	_of_property_read_u32
	testq	%rax, %rax
	je	LBB0_12
## %bb.11:
	movl	$2, (%r15)
LBB0_12:
	movq	%r15, %rdi
	callq	_meson8b_init_rgmii_tx_clk
	movl	%eax, %ebx
	testl	%eax, %eax
	jne	LBB0_20
## %bb.13:
	movq	8(%r15), %rax
	movq	%r15, %rdi
	callq	*(%rax)
	movl	%eax, %ebx
	testl	%eax, %eax
	jne	LBB0_20
## %bb.14:
	movq	%r15, %rdi
	callq	_meson8b_init_prg_eth
	movl	%eax, %ebx
	testl	%eax, %eax
	jne	LBB0_20
## %bb.15:
	movq	%r15, (%r14)
	leaq	-40(%rbp), %rdx
	movq	%r12, %rdi
	movq	%r14, %rsi
	callq	_stmmac_dvr_probe
	movl	%eax, %ebx
	testl	%eax, %eax
	jne	LBB0_20
## %bb.16:
	xorl	%ebx, %ebx
	jmp	LBB0_21
LBB0_17:
	leaq	L_.str(%rip), %rsi
	movq	%r12, %rdi
	callq	_dev_err
LBB0_18:
	movq	_EINVAL@GOTPCREL(%rip), %rax
LBB0_19:
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
LBB0_20:
	movq	%r12, %rdi
	movq	%r14, %rsi
	callq	_stmmac_remove_config_dt
LBB0_21:
	movl	%ebx, %eax
	addq	$16, %rsp
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_GFP_KERNEL,4,2                 ## @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.comm	_EINVAL,4,2                     ## @EINVAL
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"missing phy-mode property\n"

L_.str.1:                               ## @.str.1
	.asciz	"amlogic,tx-delay-ns"

	.no_dead_strip	_meson8b_dwmac_probe
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function meson8b_dwmac_probe
_meson8b_dwmac_probe:                   ; @meson8b_dwmac_probe
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.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
	mov	x19, x0
	add	x1, sp, #8
	bl	_stmmac_get_platform_resources
	mov	x22, x0
	cbnz	w0, LBB0_19
; %bb.1:
	add	x1, sp, #8
	mov	x0, x19
	bl	_stmmac_probe_config_dt
	mov	x20, x0
	bl	_IS_ERR
	cbz	x0, LBB0_3
; %bb.2:
	mov	x0, x20
	bl	_PTR_ERR
	mov	x22, x0
	b	LBB0_19
LBB0_3:
Lloh0:
	adrp	x8, _GFP_KERNEL@GOTPAGE
Lloh1:
	ldr	x8, [x8, _GFP_KERNEL@GOTPAGEOFF]
Lloh2:
	ldr	w2, [x8]
	mov	x0, x19
	mov	w1, #40
	bl	_devm_kzalloc
	cbz	x0, LBB0_7
; %bb.4:
	mov	x21, x0
	mov	x0, x19
	bl	_of_device_get_match_data
	str	x0, [x21, #8]
	cbz	x0, LBB0_16
; %bb.5:
	mov	x0, x19
	mov	w1, #1
	bl	_devm_platform_ioremap_resource
	str	x0, [x21, #32]
	bl	_IS_ERR
	cbz	x0, LBB0_8
; %bb.6:
	ldr	x0, [x21, #32]
	bl	_PTR_ERR
	mov	x22, x0
	b	LBB0_18
LBB0_7:
Lloh3:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh4:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
	b	LBB0_17
LBB0_8:
	str	x19, [x21, #24]
	ldr	w0, [x19]
	bl	_of_get_phy_mode
	str	x0, [x21, #16]
	tbnz	w0, #31, LBB0_15
; %bb.9:
	ldr	w0, [x19]
Lloh5:
	adrp	x1, l_.str.1@PAGE
Lloh6:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x2, x21
	bl	_of_property_read_u32
	cbz	x0, LBB0_11
; %bb.10:
	mov	w8, #2
	str	w8, [x21]
LBB0_11:
	mov	x0, x21
	bl	_meson8b_init_rgmii_tx_clk
	mov	x22, x0
	cbnz	w0, LBB0_18
; %bb.12:
	ldr	x8, [x21, #8]
	ldr	x8, [x8]
	mov	x0, x21
	blr	x8
	mov	x22, x0
	cbnz	w0, LBB0_18
; %bb.13:
	mov	x0, x21
	bl	_meson8b_init_prg_eth
	mov	x22, x0
	cbnz	w0, LBB0_18
; %bb.14:
	str	x21, [x20]
	add	x2, sp, #8
	mov	x0, x19
	mov	x1, x20
	bl	_stmmac_dvr_probe
	mov	x22, x0
	cbnz	w0, LBB0_18
	b	LBB0_19
LBB0_15:
Lloh7:
	adrp	x1, l_.str@PAGE
Lloh8:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x19
	bl	_dev_err
LBB0_16:
Lloh9:
	adrp	x8, _EINVAL@GOTPAGE
Lloh10:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
LBB0_17:
	ldr	w8, [x8]
	neg	w22, w8
LBB0_18:
	mov	x0, x19
	mov	x1, x20
	bl	_stmmac_remove_config_dt
LBB0_19:
	mov	x0, x22
	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
	add	sp, sp, #64
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpAdd	Lloh5, Lloh6
	.loh AdrpAdd	Lloh7, Lloh8
	.loh AdrpLdrGot	Lloh9, Lloh10
	.cfi_endproc
                                        ; -- End function
	.comm	_GFP_KERNEL,4,2                 ; @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.comm	_EINVAL,4,2                     ; @EINVAL
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"missing phy-mode property\n"

l_.str.1:                               ; @.str.1
	.asciz	"amlogic,tx-delay-ns"

	.no_dead_strip	_meson8b_dwmac_probe
.subsections_via_symbols
