	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ice_force_phys_link_state
_ice_force_phys_link_state:             ## @ice_force_phys_link_state
	.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
	subq	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	testq	%rdi, %rdi
	je	LBB0_3
## %bb.1:
	movq	%rdi, %rbx
	movq	24(%rdi), %r13
	testq	%r13, %r13
	je	LBB0_3
## %bb.2:
	movq	16(%rbx), %rax
	testq	%rax, %rax
	je	LBB0_3
## %bb.5:
	movq	(%rbx), %rcx
	movq	_ICE_VSI_PF@GOTPCREL(%rip), %rdx
	xorl	%r14d, %r14d
	cmpq	(%rdx), %rcx
	jne	LBB0_18
## %bb.6:
	movl	%esi, %r12d
	movq	8(%rax), %r14
	movq	_GFP_KERNEL@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r14, %rdi
	movl	$32, %esi
	callq	_devm_kzalloc
	testq	%rax, %rax
	je	LBB0_7
## %bb.8:
	movq	%rax, %r15
	movq	%r14, -48(%rbp)                 ## 8-byte Spill
	movq	_ICE_AQC_REPORT_SW_CFG@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	xorl	%r14d, %r14d
	movq	%r13, %rdi
	xorl	%esi, %esi
	movq	%r15, %rcx
	xorl	%r8d, %r8d
	callq	_ice_aq_get_phy_caps
	testl	%eax, %eax
	movq	%r15, -56(%rbp)                 ## 8-byte Spill
	je	LBB0_10
## %bb.9:
	movl	8(%rbx), %edx
	leaq	L_.str(%rip), %rsi
	movq	-48(%rbp), %r15                 ## 8-byte Reload
	movq	%r15, %rdi
	movl	%eax, %ecx
	callq	_dev_err
	movq	_EIO@GOTPCREL(%rip), %rax
	subl	(%rax), %r14d
	jmp	LBB0_17
LBB0_3:
	movq	_EINVAL@GOTPCREL(%rip), %rax
LBB0_4:
	xorl	%r14d, %r14d
	subl	(%rax), %r14d
LBB0_18:
	movl	%r14d, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_7:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	jmp	LBB0_4
LBB0_10:
	movq	_ICE_AQC_PHY_EN_LINK@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	xorl	%ecx, %ecx
	testl	%eax, (%r15)
	setne	%cl
	cmpl	%r12d, %ecx
	movq	-48(%rbp), %r15                 ## 8-byte Reload
	jne	LBB0_12
## %bb.11:
	movq	_ICE_AQ_LINK_UP@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	xorl	%ecx, %ecx
	testl	%eax, 4(%r13)
	setne	%cl
	xorl	%r14d, %r14d
	cmpl	%r12d, %ecx
	je	LBB0_17
LBB0_12:
	movq	_GFP_KERNEL@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r15, %rdi
	movl	$32, %esi
	callq	_devm_kzalloc
	testq	%rax, %rax
	je	LBB0_13
## %bb.14:
	movq	-56(%rbp), %rcx                 ## 8-byte Reload
	movl	28(%rcx), %edx
	movl	%edx, 28(%rax)
	movq	_ICE_AQ_PHY_ENA_AUTO_LINK_UPDT@GOTPCREL(%rip), %rdx
	movl	(%rdx), %esi
	orl	(%rcx), %esi
	movl	%esi, (%rax)
	movups	12(%rcx), %xmm0
	movups	%xmm0, 12(%rax)
	movl	4(%rcx), %ecx
	movl	%ecx, 8(%rax)
	movq	_ICE_AQ_PHY_ENA_LINK@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	movl	%ecx, %edx
	notl	%edx
	andl	%esi, %edx
	orl	%ecx, %esi
	testl	%r12d, %r12d
	cmovel	%edx, %esi
	movl	%esi, (%rax)
	movq	16(%rbx), %rdi
	movl	(%r13), %esi
	xorl	%r14d, %r14d
	movq	%rax, %r12
	movq	%rax, %rdx
	xorl	%ecx, %ecx
	callq	_ice_aq_set_phy_cfg
	testl	%eax, %eax
	movq	-48(%rbp), %r15                 ## 8-byte Reload
	je	LBB0_16
## %bb.15:
	movl	8(%rbx), %edx
	leaq	L_.str.1(%rip), %rsi
	movq	%r15, %rdi
	movl	%eax, %ecx
	callq	_dev_err
	movq	_EIO@GOTPCREL(%rip), %rax
	xorl	%r14d, %r14d
	subl	(%rax), %r14d
LBB0_16:
	movq	%r15, %rdi
	movq	%r12, %rsi
	callq	_devm_kfree
	jmp	LBB0_17
LBB0_13:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	xorl	%r14d, %r14d
	subl	(%rax), %r14d
	movq	-48(%rbp), %r15                 ## 8-byte Reload
LBB0_17:
	movq	%r15, %rdi
	movq	-56(%rbp), %rsi                 ## 8-byte Reload
	callq	_devm_kfree
	jmp	LBB0_18
	.cfi_endproc
                                        ## -- End function
	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_ICE_VSI_PF,8,3                 ## @ICE_VSI_PF
	.comm	_GFP_KERNEL,4,2                 ## @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.comm	_ICE_AQC_REPORT_SW_CFG,4,2      ## @ICE_AQC_REPORT_SW_CFG
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Failed to get phy capabilities, VSI %d error %d\n"

	.comm	_EIO,4,2                        ## @EIO
	.comm	_ICE_AQC_PHY_EN_LINK,4,2        ## @ICE_AQC_PHY_EN_LINK
	.comm	_ICE_AQ_LINK_UP,4,2             ## @ICE_AQ_LINK_UP
	.comm	_ICE_AQ_PHY_ENA_AUTO_LINK_UPDT,4,2 ## @ICE_AQ_PHY_ENA_AUTO_LINK_UPDT
	.comm	_ICE_AQ_PHY_ENA_LINK,4,2        ## @ICE_AQ_PHY_ENA_LINK
L_.str.1:                               ## @.str.1
	.asciz	"Failed to set phy config, VSI %d error %d\n"

	.no_dead_strip	_ice_force_phys_link_state
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ice_force_phys_link_state
_ice_force_phys_link_state:             ; @ice_force_phys_link_state
	.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
	cbz	x0, LBB0_9
; %bb.1:
	mov	x21, x0
	ldr	x23, [x0, #24]
	cbz	x23, LBB0_9
; %bb.2:
	ldr	x8, [x21, #16]
	cbz	x8, LBB0_9
; %bb.3:
	ldr	x9, [x21]
Lloh0:
	adrp	x10, _ICE_VSI_PF@GOTPAGE
Lloh1:
	ldr	x10, [x10, _ICE_VSI_PF@GOTPAGEOFF]
Lloh2:
	ldr	x10, [x10]
	cmp	x9, x10
	b.ne	LBB0_12
; %bb.4:
	mov	x22, x1
	ldr	x19, [x8, #8]
Lloh3:
	adrp	x24, _GFP_KERNEL@GOTPAGE
Lloh4:
	ldr	x24, [x24, _GFP_KERNEL@GOTPAGEOFF]
	ldr	w2, [x24]
	mov	x0, x19
	mov	w1, #32
	bl	_devm_kzalloc
	cbz	x0, LBB0_13
; %bb.5:
	mov	x20, x0
Lloh5:
	adrp	x8, _ICE_AQC_REPORT_SW_CFG@GOTPAGE
Lloh6:
	ldr	x8, [x8, _ICE_AQC_REPORT_SW_CFG@GOTPAGEOFF]
Lloh7:
	ldr	w2, [x8]
	mov	x0, x23
	mov	w1, #0
	mov	x3, x20
	mov	x4, #0
	bl	_ice_aq_get_phy_caps
	cbz	w0, LBB0_14
; %bb.6:
	mov	x3, x0
	ldr	w2, [x21, #8]
Lloh8:
	adrp	x1, l_.str@PAGE
Lloh9:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x19
	bl	_dev_err
Lloh10:
	adrp	x8, _EIO@GOTPAGE
Lloh11:
	ldr	x8, [x8, _EIO@GOTPAGEOFF]
LBB0_7:
	ldr	w8, [x8]
	neg	w21, w8
LBB0_8:
	mov	x0, x19
	mov	x1, x20
	bl	_devm_kfree
	b	LBB0_11
LBB0_9:
Lloh12:
	adrp	x8, _EINVAL@GOTPAGE
Lloh13:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
LBB0_10:
	ldr	w8, [x8]
	neg	w21, w8
LBB0_11:
	mov	x0, x21
	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_12:
	mov	w21, #0
	b	LBB0_11
LBB0_13:
Lloh14:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh15:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
	b	LBB0_10
LBB0_14:
	ldr	w8, [x20]
Lloh16:
	adrp	x9, _ICE_AQC_PHY_EN_LINK@GOTPAGE
Lloh17:
	ldr	x9, [x9, _ICE_AQC_PHY_EN_LINK@GOTPAGEOFF]
Lloh18:
	ldr	w9, [x9]
	tst	w9, w8
	cset	w8, ne
	cmp	w8, w22
	b.ne	LBB0_17
; %bb.15:
	ldr	w8, [x23, #4]
Lloh19:
	adrp	x9, _ICE_AQ_LINK_UP@GOTPAGE
Lloh20:
	ldr	x9, [x9, _ICE_AQ_LINK_UP@GOTPAGEOFF]
Lloh21:
	ldr	w9, [x9]
	tst	w9, w8
	cset	w8, ne
	cmp	w8, w22
	b.ne	LBB0_17
; %bb.16:
	mov	w21, #0
	b	LBB0_8
LBB0_17:
	ldr	w2, [x24]
	mov	x0, x19
	mov	w1, #32
	bl	_devm_kzalloc
	cbz	x0, LBB0_20
; %bb.18:
	mov	x24, x0
	ldr	w8, [x20, #28]
	str	w8, [x0, #28]
Lloh22:
	adrp	x8, _ICE_AQ_PHY_ENA_AUTO_LINK_UPDT@GOTPAGE
Lloh23:
	ldr	x8, [x8, _ICE_AQ_PHY_ENA_AUTO_LINK_UPDT@GOTPAGEOFF]
	ldr	w9, [x20]
Lloh24:
	ldr	w8, [x8]
	orr	w8, w8, w9
	str	w8, [x0]
	ldur	q0, [x20, #12]
	stur	q0, [x0, #12]
	ldr	w9, [x20, #4]
	str	w9, [x0, #8]
Lloh25:
	adrp	x9, _ICE_AQ_PHY_ENA_LINK@GOTPAGE
Lloh26:
	ldr	x9, [x9, _ICE_AQ_PHY_ENA_LINK@GOTPAGEOFF]
Lloh27:
	ldr	w9, [x9]
	bic	w10, w8, w9
	orr	w8, w9, w8
	cmp	w22, #0
	csel	w8, w10, w8, eq
	str	w8, [x0]
	ldr	x0, [x21, #16]
	ldr	w1, [x23]
	mov	x2, x24
	mov	x3, #0
	bl	_ice_aq_set_phy_cfg
	cbz	w0, LBB0_21
; %bb.19:
	mov	x3, x0
	ldr	w2, [x21, #8]
Lloh28:
	adrp	x1, l_.str.1@PAGE
Lloh29:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x0, x19
	bl	_dev_err
Lloh30:
	adrp	x8, _EIO@GOTPAGE
Lloh31:
	ldr	x8, [x8, _EIO@GOTPAGEOFF]
Lloh32:
	ldr	w8, [x8]
	neg	w21, w8
	b	LBB0_22
LBB0_20:
Lloh33:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh34:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
	b	LBB0_7
LBB0_21:
	mov	w21, #0
LBB0_22:
	mov	x0, x19
	mov	x1, x24
	bl	_devm_kfree
	b	LBB0_8
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh10, Lloh11
	.loh AdrpAdd	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh12, Lloh13
	.loh AdrpLdrGot	Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh16, Lloh17, Lloh18
	.loh AdrpLdrGotLdr	Lloh19, Lloh20, Lloh21
	.loh AdrpLdrGotLdr	Lloh25, Lloh26, Lloh27
	.loh AdrpLdrGotLdr	Lloh22, Lloh23, Lloh24
	.loh AdrpLdrGotLdr	Lloh30, Lloh31, Lloh32
	.loh AdrpAdd	Lloh28, Lloh29
	.loh AdrpLdrGot	Lloh33, Lloh34
	.cfi_endproc
                                        ; -- End function
	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_ICE_VSI_PF,8,3                 ; @ICE_VSI_PF
	.comm	_GFP_KERNEL,4,2                 ; @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.comm	_ICE_AQC_REPORT_SW_CFG,4,2      ; @ICE_AQC_REPORT_SW_CFG
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Failed to get phy capabilities, VSI %d error %d\n"

	.comm	_EIO,4,2                        ; @EIO
	.comm	_ICE_AQC_PHY_EN_LINK,4,2        ; @ICE_AQC_PHY_EN_LINK
	.comm	_ICE_AQ_LINK_UP,4,2             ; @ICE_AQ_LINK_UP
	.comm	_ICE_AQ_PHY_ENA_AUTO_LINK_UPDT,4,2 ; @ICE_AQ_PHY_ENA_AUTO_LINK_UPDT
	.comm	_ICE_AQ_PHY_ENA_LINK,4,2        ; @ICE_AQ_PHY_ENA_LINK
l_.str.1:                               ; @.str.1
	.asciz	"Failed to set phy config, VSI %d error %d\n"

	.no_dead_strip	_ice_force_phys_link_state
.subsections_via_symbols
