	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function e1000_diag_test
_e1000_diag_test:                       ## @e1000_diag_test
	.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	$40, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdx, %r15
	movq	%rsi, %r14
	movq	%rdi, %rbx
	callq	_netdev_priv
	movq	%rax, %r13
	movq	%rbx, %rdi
	callq	_netif_running
	movl	%eax, %r12d
	movq	%rbx, -56(%rbp)                 ## 8-byte Spill
	movl	(%rbx), %edi
	callq	_pm_runtime_get_sync
	movq	___E1000_TESTING@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	%r13, %rbx
	addq	$4, %rbx
	movq	%rbx, %rsi
	callq	_set_bit
	movl	%r12d, -44(%rbp)                ## 4-byte Spill
	testl	%r12d, %r12d
	jne	LBB0_4
## %bb.1:
	movq	_FLAG_HAS_AMT@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	testl	%eax, (%r13)
	je	LBB0_3
## %bb.2:
	movq	%r13, %rdi
	callq	_e1000e_get_hw_control
LBB0_3:
	movq	%r13, %rdi
	callq	_e1000e_power_up_phy
	movl	$1, 24(%r13)
	movq	%r13, %rdi
	callq	_e1000e_reset
	movl	$0, 24(%r13)
LBB0_4:
	movl	(%r14), %eax
	movq	_ETH_TEST_FL_OFFLINE@GOTPCREL(%rip), %rcx
	cmpl	(%rcx), %eax
	movq	-56(%rbp), %r12                 ## 8-byte Reload
	jne	LBB0_19
## %bb.5:
	movl	28(%r13), %eax
	movl	%eax, -48(%rbp)                 ## 4-byte Spill
	movups	8(%r13), %xmm0
	movaps	%xmm0, -80(%rbp)                ## 16-byte Spill
	leaq	L_.str(%rip), %rdi
	callq	_e_info
	cmpl	$0, -44(%rbp)                   ## 4-byte Folded Reload
	je	LBB0_7
## %bb.6:
	movq	%r12, %rdi
	callq	_e1000e_close
LBB0_7:
	movq	%r13, %rdi
	movq	%r15, %rsi
	callq	_e1000_reg_test
	testq	%rax, %rax
	je	LBB0_9
## %bb.8:
	movq	_ETH_TEST_FL_FAILED@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	orl	%eax, (%r14)
LBB0_9:
	movq	%r13, %rdi
	callq	_e1000e_reset
	leaq	4(%r15), %rsi
	movq	%r13, %rdi
	callq	_e1000_eeprom_test
	testq	%rax, %rax
	je	LBB0_11
## %bb.10:
	movq	_ETH_TEST_FL_FAILED@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	orl	%eax, (%r14)
LBB0_11:
	movq	%r13, %rdi
	callq	_e1000e_reset
	leaq	8(%r15), %rsi
	movq	%r13, %rdi
	callq	_e1000_intr_test
	testq	%rax, %rax
	je	LBB0_13
## %bb.12:
	movq	_ETH_TEST_FL_FAILED@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	orl	%eax, (%r14)
LBB0_13:
	movq	%r13, %rdi
	callq	_e1000e_reset
	leaq	12(%r15), %rsi
	movq	%r13, %rdi
	callq	_e1000_loopback_test
	testq	%rax, %rax
	je	LBB0_15
## %bb.14:
	movq	_ETH_TEST_FL_FAILED@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	orl	%eax, (%r14)
LBB0_15:
	movl	$1, 24(%r13)
	movq	%r13, %rdi
	callq	_e1000e_reset
	movl	$0, 24(%r13)
	addq	$16, %r15
	movq	%r13, %rdi
	movq	%r15, %rsi
	callq	_e1000_link_test
	testq	%rax, %rax
	je	LBB0_17
## %bb.16:
	movq	_ETH_TEST_FL_FAILED@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	orl	%eax, (%r14)
LBB0_17:
	movl	-48(%rbp), %eax                 ## 4-byte Reload
	movl	%eax, 28(%r13)
	movaps	-80(%rbp), %xmm0                ## 16-byte Reload
	movups	%xmm0, 8(%r13)
	movq	%r13, %rdi
	callq	_e1000e_reset
	movq	___E1000_TESTING@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	%rbx, %rsi
	callq	_clear_bit
	cmpl	$0, -44(%rbp)                   ## 4-byte Folded Reload
	je	LBB0_22
## %bb.18:
	movq	%r12, %rdi
	callq	_e1000e_open
	jmp	LBB0_24
LBB0_19:
	leaq	L_.str.1(%rip), %rdi
	callq	_e_info
	xorps	%xmm0, %xmm0
	movups	%xmm0, (%r15)
	addq	$16, %r15
	movq	%r13, %rdi
	movq	%r15, %rsi
	callq	_e1000_link_test
	testq	%rax, %rax
	je	LBB0_21
## %bb.20:
	movq	_ETH_TEST_FL_FAILED@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	orl	%eax, (%r14)
LBB0_21:
	movq	___E1000_TESTING@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	%rbx, %rsi
	callq	_clear_bit
	cmpl	$0, -44(%rbp)                   ## 4-byte Folded Reload
	jne	LBB0_24
LBB0_22:
	movq	%r13, %rdi
	callq	_e1000e_reset
	movq	_FLAG_HAS_AMT@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	testl	%eax, (%r13)
	je	LBB0_24
## %bb.23:
	movq	%r13, %rdi
	callq	_e1000e_release_hw_control
LBB0_24:
	movl	$4000, %edi                     ## imm = 0xFA0
	callq	_msleep_interruptible
	movl	(%r12), %edi
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_pm_runtime_put_sync            ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	___E1000_TESTING,4,2            ## @__E1000_TESTING
	.comm	_FLAG_HAS_AMT,4,2               ## @FLAG_HAS_AMT
	.comm	_ETH_TEST_FL_OFFLINE,4,2        ## @ETH_TEST_FL_OFFLINE
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"offline testing starting\n"

	.comm	_ETH_TEST_FL_FAILED,4,2         ## @ETH_TEST_FL_FAILED
L_.str.1:                               ## @.str.1
	.asciz	"online testing starting\n"

	.no_dead_strip	_e1000_diag_test
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function e1000_diag_test
_e1000_diag_test:                       ; @e1000_diag_test
	.cfi_startproc
; %bb.0:
	stp	x28, x27, [sp, #-96]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 96
	stp	x26, x25, [sp, #16]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #32]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #48]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #64]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #80]             ; 16-byte Folded Spill
	add	x29, sp, #80
	.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
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	mov	x24, x2
	mov	x22, x1
	mov	x19, x0
	bl	_netdev_priv
	mov	x20, x0
	mov	x0, x19
	bl	_netif_running
	mov	x21, x0
	ldr	w0, [x19]
	bl	_pm_runtime_get_sync
Lloh0:
	adrp	x25, ___E1000_TESTING@GOTPAGE
Lloh1:
	ldr	x25, [x25, ___E1000_TESTING@GOTPAGEOFF]
	ldr	w0, [x25]
	add	x23, x20, #4
	mov	x1, x23
	bl	_set_bit
	cbnz	w21, LBB0_4
; %bb.1:
	ldr	w8, [x20]
Lloh2:
	adrp	x9, _FLAG_HAS_AMT@GOTPAGE
Lloh3:
	ldr	x9, [x9, _FLAG_HAS_AMT@GOTPAGEOFF]
Lloh4:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_3
; %bb.2:
	mov	x0, x20
	bl	_e1000e_get_hw_control
LBB0_3:
	mov	x0, x20
	bl	_e1000e_power_up_phy
	mov	w8, #1
	str	w8, [x20, #24]
	mov	x0, x20
	bl	_e1000e_reset
	str	wzr, [x20, #24]
LBB0_4:
	ldr	w8, [x22]
Lloh5:
	adrp	x9, _ETH_TEST_FL_OFFLINE@GOTPAGE
Lloh6:
	ldr	x9, [x9, _ETH_TEST_FL_OFFLINE@GOTPAGEOFF]
Lloh7:
	ldr	w9, [x9]
	cmp	w8, w9
	b.ne	LBB0_19
; %bb.5:
	ldr	w26, [x20, #28]
	ldp	x28, x27, [x20, #8]
Lloh8:
	adrp	x0, l_.str@PAGE
Lloh9:
	add	x0, x0, l_.str@PAGEOFF
	bl	_e_info
	cbz	w21, LBB0_7
; %bb.6:
	mov	x0, x19
	bl	_e1000e_close
LBB0_7:
	mov	x0, x20
	mov	x1, x24
	bl	_e1000_reg_test
	cbz	x0, LBB0_9
; %bb.8:
Lloh10:
	adrp	x8, _ETH_TEST_FL_FAILED@GOTPAGE
Lloh11:
	ldr	x8, [x8, _ETH_TEST_FL_FAILED@GOTPAGEOFF]
Lloh12:
	ldr	w8, [x8]
	ldr	w9, [x22]
	orr	w8, w9, w8
	str	w8, [x22]
LBB0_9:
	mov	x0, x20
	bl	_e1000e_reset
	add	x1, x24, #4
	mov	x0, x20
	bl	_e1000_eeprom_test
	cbz	x0, LBB0_11
; %bb.10:
Lloh13:
	adrp	x8, _ETH_TEST_FL_FAILED@GOTPAGE
Lloh14:
	ldr	x8, [x8, _ETH_TEST_FL_FAILED@GOTPAGEOFF]
Lloh15:
	ldr	w8, [x8]
	ldr	w9, [x22]
	orr	w8, w9, w8
	str	w8, [x22]
LBB0_11:
	mov	x0, x20
	bl	_e1000e_reset
	add	x1, x24, #8
	mov	x0, x20
	bl	_e1000_intr_test
	cbz	x0, LBB0_13
; %bb.12:
Lloh16:
	adrp	x8, _ETH_TEST_FL_FAILED@GOTPAGE
Lloh17:
	ldr	x8, [x8, _ETH_TEST_FL_FAILED@GOTPAGEOFF]
Lloh18:
	ldr	w8, [x8]
	ldr	w9, [x22]
	orr	w8, w9, w8
	str	w8, [x22]
LBB0_13:
	mov	x0, x20
	bl	_e1000e_reset
	add	x1, x24, #12
	mov	x0, x20
	bl	_e1000_loopback_test
	cbz	x0, LBB0_15
; %bb.14:
Lloh19:
	adrp	x8, _ETH_TEST_FL_FAILED@GOTPAGE
Lloh20:
	ldr	x8, [x8, _ETH_TEST_FL_FAILED@GOTPAGEOFF]
Lloh21:
	ldr	w8, [x8]
	ldr	w9, [x22]
	orr	w8, w9, w8
	str	w8, [x22]
LBB0_15:
	mov	w8, #1
	str	w8, [x20, #24]
	mov	x0, x20
	bl	_e1000e_reset
	str	wzr, [x20, #24]
	add	x1, x24, #16
	mov	x0, x20
	bl	_e1000_link_test
	cbz	x0, LBB0_17
; %bb.16:
Lloh22:
	adrp	x8, _ETH_TEST_FL_FAILED@GOTPAGE
Lloh23:
	ldr	x8, [x8, _ETH_TEST_FL_FAILED@GOTPAGEOFF]
Lloh24:
	ldr	w8, [x8]
	ldr	w9, [x22]
	orr	w8, w9, w8
	str	w8, [x22]
LBB0_17:
	str	w26, [x20, #28]
	stp	x28, x27, [x20, #8]
	mov	x0, x20
	bl	_e1000e_reset
	ldr	w0, [x25]
	mov	x1, x23
	bl	_clear_bit
	cbz	w21, LBB0_22
; %bb.18:
	mov	x0, x19
	bl	_e1000e_open
	b	LBB0_24
LBB0_19:
Lloh25:
	adrp	x0, l_.str.1@PAGE
Lloh26:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	_e_info
	add	x1, x24, #16
	stp	xzr, xzr, [x24]
	mov	x0, x20
	bl	_e1000_link_test
	cbz	x0, LBB0_21
; %bb.20:
Lloh27:
	adrp	x8, _ETH_TEST_FL_FAILED@GOTPAGE
Lloh28:
	ldr	x8, [x8, _ETH_TEST_FL_FAILED@GOTPAGEOFF]
Lloh29:
	ldr	w8, [x8]
	ldr	w9, [x22]
	orr	w8, w9, w8
	str	w8, [x22]
LBB0_21:
	ldr	w0, [x25]
	mov	x1, x23
	bl	_clear_bit
	cbnz	w21, LBB0_24
LBB0_22:
	mov	x0, x20
	bl	_e1000e_reset
	ldr	w8, [x20]
Lloh30:
	adrp	x9, _FLAG_HAS_AMT@GOTPAGE
Lloh31:
	ldr	x9, [x9, _FLAG_HAS_AMT@GOTPAGEOFF]
Lloh32:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_24
; %bb.23:
	mov	x0, x20
	bl	_e1000e_release_hw_control
LBB0_24:
	mov	w0, #4000
	bl	_msleep_interruptible
	ldr	w0, [x19]
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #16]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp], #96             ; 16-byte Folded Reload
	b	_pm_runtime_put_sync
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpAdd	Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh16, Lloh17, Lloh18
	.loh AdrpLdrGotLdr	Lloh19, Lloh20, Lloh21
	.loh AdrpLdrGotLdr	Lloh22, Lloh23, Lloh24
	.loh AdrpAdd	Lloh25, Lloh26
	.loh AdrpLdrGotLdr	Lloh27, Lloh28, Lloh29
	.loh AdrpLdrGotLdr	Lloh30, Lloh31, Lloh32
	.cfi_endproc
                                        ; -- End function
	.comm	___E1000_TESTING,4,2            ; @__E1000_TESTING
	.comm	_FLAG_HAS_AMT,4,2               ; @FLAG_HAS_AMT
	.comm	_ETH_TEST_FL_OFFLINE,4,2        ; @ETH_TEST_FL_OFFLINE
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"offline testing starting\n"

	.comm	_ETH_TEST_FL_FAILED,4,2         ; @ETH_TEST_FL_FAILED
l_.str.1:                               ; @.str.1
	.asciz	"online testing starting\n"

	.no_dead_strip	_e1000_diag_test
.subsections_via_symbols
