	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function hisi_femac_mdio_probe
_hisi_femac_mdio_probe:                 ## @hisi_femac_mdio_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), %r15
	movl	$8, %edi
	callq	_mdiobus_alloc_size
	testq	%rax, %rax
	je	LBB0_1
## %bb.2:
	movq	%rax, %rbx
	leaq	8(%r14), %r12
	leaq	L_.str(%rip), %rax
	movq	%rax, (%rbx)
	movq	_hisi_femac_mdio_read@GOTPCREL(%rip), %rax
	movq	%rax, 40(%rbx)
	movq	_hisi_femac_mdio_write@GOTPCREL(%rip), %rax
	movq	%rax, 32(%rbx)
	movl	24(%rbx), %edi
	movq	_MII_BUS_ID_SIZE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	(%r14), %rcx
	leaq	L_.str.1(%rip), %rdx
	callq	_snprintf
	movq	%r12, 16(%rbx)
	movq	8(%rbx), %r13
	movq	%r14, %rdi
	xorl	%esi, %esi
	callq	_devm_platform_ioremap_resource
	movl	%eax, 4(%r13)
	movl	%eax, %edi
	callq	_IS_ERR
	testq	%rax, %rax
	je	LBB0_4
## %bb.3:
	movl	4(%r13), %edi
	jmp	LBB0_5
LBB0_1:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	xorl	%r12d, %r12d
	subl	(%rax), %r12d
	jmp	LBB0_11
LBB0_4:
	movq	%r12, %rdi
	xorl	%esi, %esi
	callq	_devm_clk_get
	movl	%eax, (%r13)
	movl	%eax, %edi
	callq	_IS_ERR
	movl	(%r13), %edi
	testq	%rax, %rax
	je	LBB0_6
LBB0_5:
	callq	_PTR_ERR
	movl	%eax, %r12d
LBB0_10:
	movq	%rbx, %rdi
	callq	_mdiobus_free
LBB0_11:
	movl	%r12d, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_6:
	callq	_clk_prepare_enable
	movl	%eax, %r12d
	testl	%eax, %eax
	jne	LBB0_10
## %bb.7:
	movq	%rbx, %rdi
	movq	%r15, %rsi
	callq	_of_mdiobus_register
	testl	%eax, %eax
	je	LBB0_8
## %bb.9:
	movl	%eax, %r12d
	movl	(%r13), %edi
	callq	_clk_disable_unprepare
	jmp	LBB0_10
LBB0_8:
	movq	%r14, %rdi
	movq	%rbx, %rsi
	callq	_platform_set_drvdata
	xorl	%r12d, %r12d
	jmp	LBB0_11
	.cfi_endproc
                                        ## -- End function
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"hisi_femac_mii_bus"

	.comm	_hisi_femac_mdio_read,4,2       ## @hisi_femac_mdio_read
	.comm	_hisi_femac_mdio_write,4,2      ## @hisi_femac_mdio_write
	.comm	_MII_BUS_ID_SIZE,4,2            ## @MII_BUS_ID_SIZE
L_.str.1:                               ## @.str.1
	.asciz	"%s"

	.no_dead_strip	_hisi_femac_mdio_probe
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function hisi_femac_mdio_probe
_hisi_femac_mdio_probe:                 ; @hisi_femac_mdio_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
	mov	x22, x0
	ldr	x21, [x22, #8]!
	mov	w0, #8
	bl	_mdiobus_alloc_size
	cbz	x0, LBB0_3
; %bb.1:
	mov	x19, x0
Lloh0:
	adrp	x8, l_.str@PAGE
Lloh1:
	add	x8, x8, l_.str@PAGEOFF
	str	x8, [x0]
Lloh2:
	adrp	x8, _hisi_femac_mdio_read@GOTPAGE
Lloh3:
	ldr	x8, [x8, _hisi_femac_mdio_read@GOTPAGEOFF]
Lloh4:
	adrp	x9, _hisi_femac_mdio_write@GOTPAGE
Lloh5:
	ldr	x9, [x9, _hisi_femac_mdio_write@GOTPAGEOFF]
	stp	x9, x8, [x0, #32]
	ldr	w0, [x0, #24]
Lloh6:
	adrp	x8, _MII_BUS_ID_SIZE@GOTPAGE
Lloh7:
	ldr	x8, [x8, _MII_BUS_ID_SIZE@GOTPAGEOFF]
Lloh8:
	ldr	w1, [x8]
	ldr	x3, [x20]
Lloh9:
	adrp	x2, l_.str.1@PAGE
Lloh10:
	add	x2, x2, l_.str.1@PAGEOFF
	bl	_snprintf
	str	x22, [x19, #16]
	ldr	x23, [x19, #8]
	mov	x0, x20
	mov	w1, #0
	bl	_devm_platform_ioremap_resource
	str	w0, [x23, #4]
	bl	_IS_ERR
	cbz	x0, LBB0_4
; %bb.2:
	ldr	w0, [x23, #4]
	b	LBB0_5
LBB0_3:
Lloh11:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh12:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh13:
	ldr	w8, [x8]
	neg	w22, w8
	b	LBB0_7
LBB0_4:
	mov	x0, x22
	mov	x1, #0
	bl	_devm_clk_get
	str	w0, [x23]
	bl	_IS_ERR
	mov	x8, x0
	ldr	w0, [x23]
	cbz	x8, LBB0_8
LBB0_5:
	bl	_PTR_ERR
	mov	x22, x0
LBB0_6:
	mov	x0, x19
	bl	_mdiobus_free
LBB0_7:
	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
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	ret
LBB0_8:
	bl	_clk_prepare_enable
	mov	x22, x0
	cbnz	w0, LBB0_6
; %bb.9:
	mov	x0, x19
	mov	x1, x21
	bl	_of_mdiobus_register
	mov	x22, x0
	cbz	w0, LBB0_11
; %bb.10:
	ldr	w0, [x23]
	bl	_clk_disable_unprepare
	b	LBB0_6
LBB0_11:
	mov	x0, x20
	mov	x1, x19
	bl	_platform_set_drvdata
	b	LBB0_7
	.loh AdrpAdd	Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.cfi_endproc
                                        ; -- End function
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"hisi_femac_mii_bus"

	.comm	_hisi_femac_mdio_read,4,2       ; @hisi_femac_mdio_read
	.comm	_hisi_femac_mdio_write,4,2      ; @hisi_femac_mdio_write
	.comm	_MII_BUS_ID_SIZE,4,2            ; @MII_BUS_ID_SIZE
l_.str.1:                               ; @.str.1
	.asciz	"%s"

	.no_dead_strip	_hisi_femac_mdio_probe
.subsections_via_symbols
