	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function cas_set_link_ksettings
_cas_set_link_ksettings:                ## @cas_set_link_ksettings
	.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	%rsi, %rbx
	callq	_netdev_priv
	movq	%rax, %r14
	movq	(%rbx), %rax
	movq	8(%rbx), %rcx
	movq	_AUTONEG_ENABLE@GOTPCREL(%rip), %rsi
	movq	_AUTONEG_DISABLE@GOTPCREL(%rip), %rdx
	movq	(%rdx), %rdx
	cmpq	(%rsi), %rcx
	je	LBB0_3
## %bb.1:
	cmpq	%rdx, %rcx
	je	LBB0_3
LBB0_2:
	movq	_EINVAL@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
	jmp	LBB0_10
LBB0_3:
	cmpq	%rdx, %rcx
	jne	LBB0_9
## %bb.4:
	movq	_SPEED_1000@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	je	LBB0_7
## %bb.5:
	movq	_SPEED_100@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	je	LBB0_7
## %bb.6:
	movq	_SPEED_10@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_2
LBB0_7:
	movq	16(%rbx), %rax
	movq	_DUPLEX_HALF@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	je	LBB0_9
## %bb.8:
	movq	_DUPLEX_FULL@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_2
LBB0_9:
	movq	%r14, %rdi
	callq	_spin_lock_irqsave
	movq	%r14, %rdi
	movq	%rbx, %rsi
	callq	_cas_begin_auto_negotiation
	movq	%r14, %rdi
	callq	_spin_unlock_irqrestore
	xorl	%eax, %eax
LBB0_10:
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_AUTONEG_ENABLE,8,3             ## @AUTONEG_ENABLE
	.comm	_AUTONEG_DISABLE,8,3            ## @AUTONEG_DISABLE
	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_SPEED_1000,8,3                 ## @SPEED_1000
	.comm	_SPEED_100,8,3                  ## @SPEED_100
	.comm	_SPEED_10,8,3                   ## @SPEED_10
	.comm	_DUPLEX_HALF,8,3                ## @DUPLEX_HALF
	.comm	_DUPLEX_FULL,8,3                ## @DUPLEX_FULL
	.no_dead_strip	_cas_set_link_ksettings
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function cas_set_link_ksettings
_cas_set_link_ksettings:                ; @cas_set_link_ksettings
	.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, x1
	bl	_netdev_priv
	ldr	x8, [x19, #8]
Lloh0:
	adrp	x9, _AUTONEG_ENABLE@GOTPAGE
Lloh1:
	ldr	x9, [x9, _AUTONEG_ENABLE@GOTPAGEOFF]
Lloh2:
	ldr	x10, [x9]
Lloh3:
	adrp	x9, _AUTONEG_DISABLE@GOTPAGE
Lloh4:
	ldr	x9, [x9, _AUTONEG_DISABLE@GOTPAGEOFF]
Lloh5:
	ldr	x9, [x9]
	cmp	x8, x10
	ccmp	x8, x9, #4, ne
	b.ne	LBB0_5
; %bb.1:
	mov	x20, x0
	cmp	x8, x9
	b.ne	LBB0_4
; %bb.2:
	ldr	x8, [x19]
Lloh6:
	adrp	x9, _SPEED_1000@GOTPAGE
Lloh7:
	ldr	x9, [x9, _SPEED_1000@GOTPAGEOFF]
Lloh8:
	ldr	x9, [x9]
Lloh9:
	adrp	x10, _SPEED_100@GOTPAGE
Lloh10:
	ldr	x10, [x10, _SPEED_100@GOTPAGEOFF]
Lloh11:
	ldr	x10, [x10]
Lloh12:
	adrp	x11, _SPEED_10@GOTPAGE
Lloh13:
	ldr	x11, [x11, _SPEED_10@GOTPAGEOFF]
Lloh14:
	ldr	x11, [x11]
	cmp	x8, x9
	ccmp	x8, x10, #4, ne
	ccmp	x8, x11, #4, ne
	b.ne	LBB0_5
; %bb.3:
	ldr	x8, [x19, #16]
Lloh15:
	adrp	x9, _DUPLEX_HALF@GOTPAGE
Lloh16:
	ldr	x9, [x9, _DUPLEX_HALF@GOTPAGEOFF]
Lloh17:
	ldr	x9, [x9]
Lloh18:
	adrp	x10, _DUPLEX_FULL@GOTPAGE
Lloh19:
	ldr	x10, [x10, _DUPLEX_FULL@GOTPAGEOFF]
Lloh20:
	ldr	x10, [x10]
	cmp	x8, x9
	ccmp	x8, x10, #4, ne
	b.ne	LBB0_5
LBB0_4:
	mov	x0, x20
	bl	_spin_lock_irqsave
	mov	x0, x20
	mov	x1, x19
	bl	_cas_begin_auto_negotiation
	mov	x0, x20
	bl	_spin_unlock_irqrestore
	mov	w0, #0
	b	LBB0_6
LBB0_5:
Lloh21:
	adrp	x8, _EINVAL@GOTPAGE
Lloh22:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh23:
	ldr	w8, [x8]
	neg	w0, w8
LBB0_6:
	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 AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.cfi_endproc
                                        ; -- End function
	.comm	_AUTONEG_ENABLE,8,3             ; @AUTONEG_ENABLE
	.comm	_AUTONEG_DISABLE,8,3            ; @AUTONEG_DISABLE
	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_SPEED_1000,8,3                 ; @SPEED_1000
	.comm	_SPEED_100,8,3                  ; @SPEED_100
	.comm	_SPEED_10,8,3                   ; @SPEED_10
	.comm	_DUPLEX_HALF,8,3                ; @DUPLEX_HALF
	.comm	_DUPLEX_FULL,8,3                ; @DUPLEX_FULL
	.no_dead_strip	_cas_set_link_ksettings
.subsections_via_symbols
