	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function sti_dwmac_set_mode
_sti_dwmac_set_mode:                    ## @sti_dwmac_set_mode
	.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
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %rbx
	movq	32(%rdi), %r14
	movslq	(%rdi), %r12
	movl	24(%rdi), %r15d
	cmpq	$0, 16(%rdi)
	je	LBB0_2
## %bb.1:
	movq	_EN_MASK@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	_EN@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movq	%r14, %rdi
	movl	%r15d, %esi
	callq	_regmap_update_bits
LBB0_2:
	movq	_MII_PHY_SEL_MASK@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	_phy_intf_sels@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movl	(%rax,%r12,4), %ecx
	movq	%r14, %rdi
	movl	%r15d, %esi
	callq	_regmap_update_bits
	movq	_PHY_INTERFACE_MODE_REVMII@GOTPCREL(%rip), %rax
	movl	$0, %ecx
	cmpl	(%rax), %r12d
	je	LBB0_4
## %bb.3:
	movq	_ENMII@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
LBB0_4:
	movq	_ENMII_MASK@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r14, %rdi
	movl	%r15d, %esi
	callq	_regmap_update_bits
	movl	4(%rbx), %esi
	movq	%rbx, %rdi
	callq	*8(%rbx)
	xorl	%eax, %eax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_EN_MASK,4,2                    ## @EN_MASK
	.comm	_EN,4,2                         ## @EN
	.comm	_MII_PHY_SEL_MASK,4,2           ## @MII_PHY_SEL_MASK
	.comm	_phy_intf_sels,8,3              ## @phy_intf_sels
	.comm	_PHY_INTERFACE_MODE_REVMII,4,2  ## @PHY_INTERFACE_MODE_REVMII
	.comm	_ENMII,4,2                      ## @ENMII
	.comm	_ENMII_MASK,4,2                 ## @ENMII_MASK
	.no_dead_strip	_sti_dwmac_set_mode
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function sti_dwmac_set_mode
_sti_dwmac_set_mode:                    ; @sti_dwmac_set_mode
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.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
	ldr	x20, [x0, #32]
	ldrsw	x22, [x0]
	ldr	w21, [x0, #24]
	ldr	x8, [x0, #16]
	cbz	x8, LBB0_2
; %bb.1:
Lloh0:
	adrp	x8, _EN_MASK@GOTPAGE
Lloh1:
	ldr	x8, [x8, _EN_MASK@GOTPAGEOFF]
Lloh2:
	ldr	w2, [x8]
Lloh3:
	adrp	x8, _EN@GOTPAGE
Lloh4:
	ldr	x8, [x8, _EN@GOTPAGEOFF]
Lloh5:
	ldr	w3, [x8]
	mov	x0, x20
	mov	x1, x21
	bl	_regmap_update_bits
LBB0_2:
Lloh6:
	adrp	x8, _MII_PHY_SEL_MASK@GOTPAGE
Lloh7:
	ldr	x8, [x8, _MII_PHY_SEL_MASK@GOTPAGEOFF]
Lloh8:
	ldr	w2, [x8]
Lloh9:
	adrp	x8, _phy_intf_sels@GOTPAGE
Lloh10:
	ldr	x8, [x8, _phy_intf_sels@GOTPAGEOFF]
Lloh11:
	ldr	x8, [x8]
	ldr	w3, [x8, x22, lsl #2]
	mov	x0, x20
	mov	x1, x21
	bl	_regmap_update_bits
Lloh12:
	adrp	x8, _PHY_INTERFACE_MODE_REVMII@GOTPAGE
Lloh13:
	ldr	x8, [x8, _PHY_INTERFACE_MODE_REVMII@GOTPAGEOFF]
Lloh14:
	ldr	w8, [x8]
Lloh15:
	adrp	x9, _ENMII@GOTPAGE
Lloh16:
	ldr	x9, [x9, _ENMII@GOTPAGEOFF]
Lloh17:
	ldr	w9, [x9]
	cmp	w22, w8
	csel	w3, wzr, w9, eq
Lloh18:
	adrp	x8, _ENMII_MASK@GOTPAGE
Lloh19:
	ldr	x8, [x8, _ENMII_MASK@GOTPAGEOFF]
Lloh20:
	ldr	w2, [x8]
	mov	x0, x20
	mov	x1, x21
	bl	_regmap_update_bits
	ldr	x8, [x19, #8]
	ldr	w1, [x19, #4]
	mov	x0, x19
	blr	x8
	mov	w0, #0
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.cfi_endproc
                                        ; -- End function
	.comm	_EN_MASK,4,2                    ; @EN_MASK
	.comm	_EN,4,2                         ; @EN
	.comm	_MII_PHY_SEL_MASK,4,2           ; @MII_PHY_SEL_MASK
	.comm	_phy_intf_sels,8,3              ; @phy_intf_sels
	.comm	_PHY_INTERFACE_MODE_REVMII,4,2  ; @PHY_INTERFACE_MODE_REVMII
	.comm	_ENMII,4,2                      ; @ENMII
	.comm	_ENMII_MASK,4,2                 ; @ENMII_MASK
	.no_dead_strip	_sti_dwmac_set_mode
.subsections_via_symbols
