	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function r8153_hw_phy_cfg
_r8153_hw_phy_cfg:                      ## @r8153_hw_phy_cfg
	.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	%rbx
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %rbx
	xorl	%esi, %esi
	callq	_r8153_aldps_en
	movq	%rbx, %rdi
	xorl	%esi, %esi
	callq	_rtl_eee_enable
	cmpl	$131, (%rbx)
	jne	LBB0_2
## %bb.1:
	movq	_OCP_EEE_CFG@GOTPCREL(%rip), %r14
	movl	(%r14), %esi
	movq	%rbx, %rdi
	callq	_ocp_reg_read
	movq	_CTAP_SHORT_EN@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edx
	notl	%edx
	andl	%eax, %edx
	movl	(%r14), %esi
	movq	%rbx, %rdi
	callq	_ocp_reg_write
LBB0_2:
	movq	_OCP_POWER_CFG@GOTPCREL(%rip), %r14
	movl	(%r14), %esi
	movq	%rbx, %rdi
	callq	_ocp_reg_read
	movq	_EEE_CLKDIV_EN@GOTPCREL(%rip), %rcx
	orl	(%rcx), %eax
	movl	(%r14), %esi
	movq	%rbx, %rdi
	movl	%eax, %edx
	callq	_ocp_reg_write
	movq	_OCP_DOWN_SPEED@GOTPCREL(%rip), %r15
	movl	(%r15), %esi
	movq	%rbx, %rdi
	callq	_ocp_reg_read
	movq	_EN_10M_BGOFF@GOTPCREL(%rip), %rcx
	orl	(%rcx), %eax
	movl	(%r15), %esi
	movq	%rbx, %rdi
	movl	%eax, %edx
	callq	_ocp_reg_write
	movl	(%r14), %esi
	movq	%rbx, %rdi
	callq	_ocp_reg_read
	movq	_EN_10M_PLLOFF@GOTPCREL(%rip), %rcx
	orl	(%rcx), %eax
	movl	(%r14), %esi
	movq	%rbx, %rdi
	movl	%eax, %edx
	callq	_ocp_reg_write
	movq	_SRAM_IMPEDANCE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdi
	movl	$2835, %edx                     ## imm = 0xB13
	callq	_sram_write
	movq	_MCU_TYPE_PLA@GOTPCREL(%rip), %r14
	movl	(%r14), %esi
	movq	_PLA_PHY_PWR@GOTPCREL(%rip), %r15
	movl	(%r15), %edx
	movq	%rbx, %rdi
	callq	_ocp_read_word
	movq	_PFM_PWM_SWITCH@GOTPCREL(%rip), %rcx
	orl	(%rcx), %eax
	movl	(%r14), %esi
	movl	(%r15), %edx
	movq	%rbx, %rdi
	movl	%eax, %ecx
	callq	_ocp_write_word
	movq	_SRAM_LPF_CFG@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdi
	movl	$63247, %edx                    ## imm = 0xF70F
	callq	_sram_write
	movq	_SRAM_10M_AMP1@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdi
	movl	$175, %edx
	callq	_sram_write
	movq	_SRAM_10M_AMP2@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdi
	movl	$520, %edx                      ## imm = 0x208
	callq	_sram_write
	cmpq	$0, 8(%rbx)
	je	LBB0_4
## %bb.3:
	movq	%rbx, %rdi
	movl	$1, %esi
	callq	_rtl_eee_enable
LBB0_4:
	movq	%rbx, %rdi
	movl	$1, %esi
	callq	_r8153_aldps_en
	movq	%rbx, %rdi
	callq	_r8152b_enable_fc
	movl	(%rbx), %eax
	andl	$-2, %eax
	cmpl	$130, %eax
	je	LBB0_6
## %bb.5:
	movq	%rbx, %rdi
	movl	$1, %esi
	callq	_r8153_u2p3en
LBB0_6:
	movq	_PHY_RESET@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	addq	$4, %rbx
	movq	%rbx, %rsi
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_set_bit                        ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_OCP_EEE_CFG,4,2                ## @OCP_EEE_CFG
	.comm	_CTAP_SHORT_EN,4,2              ## @CTAP_SHORT_EN
	.comm	_OCP_POWER_CFG,4,2              ## @OCP_POWER_CFG
	.comm	_EEE_CLKDIV_EN,4,2              ## @EEE_CLKDIV_EN
	.comm	_OCP_DOWN_SPEED,4,2             ## @OCP_DOWN_SPEED
	.comm	_EN_10M_BGOFF,4,2               ## @EN_10M_BGOFF
	.comm	_EN_10M_PLLOFF,4,2              ## @EN_10M_PLLOFF
	.comm	_SRAM_IMPEDANCE,4,2             ## @SRAM_IMPEDANCE
	.comm	_MCU_TYPE_PLA,4,2               ## @MCU_TYPE_PLA
	.comm	_PLA_PHY_PWR,4,2                ## @PLA_PHY_PWR
	.comm	_PFM_PWM_SWITCH,4,2             ## @PFM_PWM_SWITCH
	.comm	_SRAM_LPF_CFG,4,2               ## @SRAM_LPF_CFG
	.comm	_SRAM_10M_AMP1,4,2              ## @SRAM_10M_AMP1
	.comm	_SRAM_10M_AMP2,4,2              ## @SRAM_10M_AMP2
	.comm	_PHY_RESET,4,2                  ## @PHY_RESET
	.no_dead_strip	_r8153_hw_phy_cfg
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function r8153_hw_phy_cfg
_r8153_hw_phy_cfg:                      ; @r8153_hw_phy_cfg
	.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
	mov	w1, #0
	bl	_r8153_aldps_en
	mov	x0, x19
	mov	w1, #0
	bl	_rtl_eee_enable
	ldr	w8, [x19]
	cmp	w8, #131
	b.ne	LBB0_2
; %bb.1:
Lloh0:
	adrp	x20, _OCP_EEE_CFG@GOTPAGE
Lloh1:
	ldr	x20, [x20, _OCP_EEE_CFG@GOTPAGEOFF]
	ldr	w1, [x20]
	mov	x0, x19
	bl	_ocp_reg_read
Lloh2:
	adrp	x8, _CTAP_SHORT_EN@GOTPAGE
Lloh3:
	ldr	x8, [x8, _CTAP_SHORT_EN@GOTPAGEOFF]
Lloh4:
	ldr	w8, [x8]
	bic	w2, w0, w8
	ldr	w1, [x20]
	mov	x0, x19
	bl	_ocp_reg_write
LBB0_2:
Lloh5:
	adrp	x20, _OCP_POWER_CFG@GOTPAGE
Lloh6:
	ldr	x20, [x20, _OCP_POWER_CFG@GOTPAGEOFF]
	ldr	w1, [x20]
	mov	x0, x19
	bl	_ocp_reg_read
Lloh7:
	adrp	x8, _EEE_CLKDIV_EN@GOTPAGE
Lloh8:
	ldr	x8, [x8, _EEE_CLKDIV_EN@GOTPAGEOFF]
Lloh9:
	ldr	w8, [x8]
	orr	w2, w8, w0
	ldr	w1, [x20]
	mov	x0, x19
	bl	_ocp_reg_write
Lloh10:
	adrp	x21, _OCP_DOWN_SPEED@GOTPAGE
Lloh11:
	ldr	x21, [x21, _OCP_DOWN_SPEED@GOTPAGEOFF]
	ldr	w1, [x21]
	mov	x0, x19
	bl	_ocp_reg_read
Lloh12:
	adrp	x8, _EN_10M_BGOFF@GOTPAGE
Lloh13:
	ldr	x8, [x8, _EN_10M_BGOFF@GOTPAGEOFF]
Lloh14:
	ldr	w8, [x8]
	orr	w2, w8, w0
	ldr	w1, [x21]
	mov	x0, x19
	bl	_ocp_reg_write
	ldr	w1, [x20]
	mov	x0, x19
	bl	_ocp_reg_read
Lloh15:
	adrp	x8, _EN_10M_PLLOFF@GOTPAGE
Lloh16:
	ldr	x8, [x8, _EN_10M_PLLOFF@GOTPAGEOFF]
Lloh17:
	ldr	w8, [x8]
	orr	w2, w8, w0
	ldr	w1, [x20]
	mov	x0, x19
	bl	_ocp_reg_write
Lloh18:
	adrp	x8, _SRAM_IMPEDANCE@GOTPAGE
Lloh19:
	ldr	x8, [x8, _SRAM_IMPEDANCE@GOTPAGEOFF]
Lloh20:
	ldr	w1, [x8]
	mov	x0, x19
	mov	w2, #2835
	bl	_sram_write
Lloh21:
	adrp	x20, _MCU_TYPE_PLA@GOTPAGE
Lloh22:
	ldr	x20, [x20, _MCU_TYPE_PLA@GOTPAGEOFF]
	ldr	w1, [x20]
Lloh23:
	adrp	x21, _PLA_PHY_PWR@GOTPAGE
Lloh24:
	ldr	x21, [x21, _PLA_PHY_PWR@GOTPAGEOFF]
	ldr	w2, [x21]
	mov	x0, x19
	bl	_ocp_read_word
Lloh25:
	adrp	x8, _PFM_PWM_SWITCH@GOTPAGE
Lloh26:
	ldr	x8, [x8, _PFM_PWM_SWITCH@GOTPAGEOFF]
Lloh27:
	ldr	w8, [x8]
	orr	w3, w8, w0
	ldr	w1, [x20]
	ldr	w2, [x21]
	mov	x0, x19
	bl	_ocp_write_word
Lloh28:
	adrp	x8, _SRAM_LPF_CFG@GOTPAGE
Lloh29:
	ldr	x8, [x8, _SRAM_LPF_CFG@GOTPAGEOFF]
Lloh30:
	ldr	w1, [x8]
	mov	x0, x19
	mov	w2, #63247
	bl	_sram_write
Lloh31:
	adrp	x8, _SRAM_10M_AMP1@GOTPAGE
Lloh32:
	ldr	x8, [x8, _SRAM_10M_AMP1@GOTPAGEOFF]
Lloh33:
	ldr	w1, [x8]
	mov	x0, x19
	mov	w2, #175
	bl	_sram_write
Lloh34:
	adrp	x8, _SRAM_10M_AMP2@GOTPAGE
Lloh35:
	ldr	x8, [x8, _SRAM_10M_AMP2@GOTPAGEOFF]
Lloh36:
	ldr	w1, [x8]
	mov	x0, x19
	mov	w2, #520
	bl	_sram_write
	ldr	x8, [x19, #8]
	cbz	x8, LBB0_4
; %bb.3:
	mov	x0, x19
	mov	w1, #1
	bl	_rtl_eee_enable
LBB0_4:
	mov	x0, x19
	mov	w1, #1
	bl	_r8153_aldps_en
	mov	x0, x19
	bl	_r8152b_enable_fc
	ldr	w8, [x19]
	and	w8, w8, #0xfffffffe
	cmp	w8, #130
	b.eq	LBB0_6
; %bb.5:
	mov	x0, x19
	mov	w1, #1
	bl	_r8153_u2p3en
LBB0_6:
Lloh37:
	adrp	x8, _PHY_RESET@GOTPAGE
Lloh38:
	ldr	x8, [x8, _PHY_RESET@GOTPAGEOFF]
Lloh39:
	ldr	w0, [x8]
	add	x1, x19, #4
	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
	b	_set_bit
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh34, Lloh35, Lloh36
	.loh AdrpLdrGotLdr	Lloh31, Lloh32, Lloh33
	.loh AdrpLdrGotLdr	Lloh28, Lloh29, Lloh30
	.loh AdrpLdrGotLdr	Lloh25, Lloh26, Lloh27
	.loh AdrpLdrGot	Lloh23, Lloh24
	.loh AdrpLdrGot	Lloh21, Lloh22
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGot	Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh37, Lloh38, Lloh39
	.cfi_endproc
                                        ; -- End function
	.comm	_OCP_EEE_CFG,4,2                ; @OCP_EEE_CFG
	.comm	_CTAP_SHORT_EN,4,2              ; @CTAP_SHORT_EN
	.comm	_OCP_POWER_CFG,4,2              ; @OCP_POWER_CFG
	.comm	_EEE_CLKDIV_EN,4,2              ; @EEE_CLKDIV_EN
	.comm	_OCP_DOWN_SPEED,4,2             ; @OCP_DOWN_SPEED
	.comm	_EN_10M_BGOFF,4,2               ; @EN_10M_BGOFF
	.comm	_EN_10M_PLLOFF,4,2              ; @EN_10M_PLLOFF
	.comm	_SRAM_IMPEDANCE,4,2             ; @SRAM_IMPEDANCE
	.comm	_MCU_TYPE_PLA,4,2               ; @MCU_TYPE_PLA
	.comm	_PLA_PHY_PWR,4,2                ; @PLA_PHY_PWR
	.comm	_PFM_PWM_SWITCH,4,2             ; @PFM_PWM_SWITCH
	.comm	_SRAM_LPF_CFG,4,2               ; @SRAM_LPF_CFG
	.comm	_SRAM_10M_AMP1,4,2              ; @SRAM_10M_AMP1
	.comm	_SRAM_10M_AMP2,4,2              ; @SRAM_10M_AMP2
	.comm	_PHY_RESET,4,2                  ; @PHY_RESET
	.no_dead_strip	_r8153_hw_phy_cfg
.subsections_via_symbols
