	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function mvsw61xx_get_port_link
_mvsw61xx_get_port_link:                ## @mvsw61xx_get_port_link
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r14
	pushq	%rbx
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movq	%rdx, %r14
	movq	%rdi, %rbx
	movq	_STATUS@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_MV_PORTREG
	movq	%rbx, %rdi
	movl	%eax, %esi
	callq	_sr16
	movq	_MV_PORT_STATUS_LINK@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	andl	%eax, %ecx
	movl	%ecx, (%r14)
	je	LBB0_3
## %bb.1:
	movq	_MV_PORT_STATUS_FDX@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	andl	%eax, %ecx
	movl	%ecx, 4(%r14)
	movq	_MV_PORT_STATUS_SPEED_MASK@GOTPCREL(%rip), %rcx
	andl	(%rcx), %eax
	movq	_MV_PORT_STATUS_SPEED_SHIFT@GOTPCREL(%rip), %rcx
	movb	(%rcx), %cl
	sarl	%cl, %eax
	addl	$-128, %eax
	cmpl	$2, %eax
	ja	LBB0_3
## %bb.2:
	cltq
	leaq	l_switch.table.mvsw61xx_get_port_link(%rip), %rcx
	movq	(%rcx,%rax,8), %rax
	movl	(%rax), %eax
	movl	%eax, 8(%r14)
LBB0_3:
	xorl	%eax, %eax
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_STATUS,4,2                     ## @STATUS
	.comm	_MV_PORT_STATUS_LINK,4,2        ## @MV_PORT_STATUS_LINK
	.comm	_MV_PORT_STATUS_FDX,4,2         ## @MV_PORT_STATUS_FDX
	.comm	_MV_PORT_STATUS_SPEED_MASK,4,2  ## @MV_PORT_STATUS_SPEED_MASK
	.comm	_MV_PORT_STATUS_SPEED_SHIFT,4,2 ## @MV_PORT_STATUS_SPEED_SHIFT
	.comm	_SWITCH_PORT_SPEED_10,4,2       ## @SWITCH_PORT_SPEED_10
	.comm	_SWITCH_PORT_SPEED_100,4,2      ## @SWITCH_PORT_SPEED_100
	.comm	_SWITCH_PORT_SPEED_1000,4,2     ## @SWITCH_PORT_SPEED_1000
	.no_dead_strip	_mvsw61xx_get_port_link
	.section	__DATA,__const
	.p2align	3                               ## @switch.table.mvsw61xx_get_port_link
l_switch.table.mvsw61xx_get_port_link:
	.quad	_SWITCH_PORT_SPEED_1000
	.quad	_SWITCH_PORT_SPEED_100
	.quad	_SWITCH_PORT_SPEED_10

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function mvsw61xx_get_port_link
_mvsw61xx_get_port_link:                ; @mvsw61xx_get_port_link
	.cfi_startproc
; %bb.0:
	stp	x20, x19, [sp, #-32]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 32
	stp	x29, x30, [sp, #16]             ; 16-byte Folded Spill
	add	x29, sp, #16
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	mov	x19, x2
	mov	x20, x0
Lloh0:
	adrp	x8, _STATUS@GOTPAGE
Lloh1:
	ldr	x8, [x8, _STATUS@GOTPAGEOFF]
Lloh2:
	ldr	w0, [x8]
	bl	_MV_PORTREG
	mov	x1, x0
	mov	x0, x20
	bl	_sr16
Lloh3:
	adrp	x8, _MV_PORT_STATUS_LINK@GOTPAGE
Lloh4:
	ldr	x8, [x8, _MV_PORT_STATUS_LINK@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	ands	w8, w8, w0
	str	w8, [x19]
	b.eq	LBB0_3
; %bb.1:
Lloh6:
	adrp	x8, _MV_PORT_STATUS_FDX@GOTPAGE
Lloh7:
	ldr	x8, [x8, _MV_PORT_STATUS_FDX@GOTPAGEOFF]
Lloh8:
	ldr	w8, [x8]
	and	w8, w8, w0
	str	w8, [x19, #4]
Lloh9:
	adrp	x8, _MV_PORT_STATUS_SPEED_MASK@GOTPAGE
Lloh10:
	ldr	x8, [x8, _MV_PORT_STATUS_SPEED_MASK@GOTPAGEOFF]
Lloh11:
	ldr	w8, [x8]
	and	w8, w8, w0
Lloh12:
	adrp	x9, _MV_PORT_STATUS_SPEED_SHIFT@GOTPAGE
Lloh13:
	ldr	x9, [x9, _MV_PORT_STATUS_SPEED_SHIFT@GOTPAGEOFF]
Lloh14:
	ldr	w9, [x9]
	asr	w8, w8, w9
	sub	w8, w8, #128
	cmp	w8, #2
	b.hi	LBB0_3
; %bb.2:
Lloh15:
	adrp	x9, l_switch.table.mvsw61xx_get_port_link@PAGE
Lloh16:
	add	x9, x9, l_switch.table.mvsw61xx_get_port_link@PAGEOFF
	ldr	x8, [x9, w8, sxtw #3]
	ldr	w8, [x8]
	str	w8, [x19, #8]
LBB0_3:
	mov	w0, #0
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpAdd	Lloh15, Lloh16
	.cfi_endproc
                                        ; -- End function
	.comm	_STATUS,4,2                     ; @STATUS
	.comm	_MV_PORT_STATUS_LINK,4,2        ; @MV_PORT_STATUS_LINK
	.comm	_MV_PORT_STATUS_FDX,4,2         ; @MV_PORT_STATUS_FDX
	.comm	_MV_PORT_STATUS_SPEED_MASK,4,2  ; @MV_PORT_STATUS_SPEED_MASK
	.comm	_MV_PORT_STATUS_SPEED_SHIFT,4,2 ; @MV_PORT_STATUS_SPEED_SHIFT
	.comm	_SWITCH_PORT_SPEED_10,4,2       ; @SWITCH_PORT_SPEED_10
	.comm	_SWITCH_PORT_SPEED_100,4,2      ; @SWITCH_PORT_SPEED_100
	.comm	_SWITCH_PORT_SPEED_1000,4,2     ; @SWITCH_PORT_SPEED_1000
	.no_dead_strip	_mvsw61xx_get_port_link
	.section	__DATA,__const
	.p2align	3                               ; @switch.table.mvsw61xx_get_port_link
l_switch.table.mvsw61xx_get_port_link:
	.quad	_SWITCH_PORT_SPEED_1000
	.quad	_SWITCH_PORT_SPEED_100
	.quad	_SWITCH_PORT_SPEED_10

.subsections_via_symbols
