	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function wait_phys_link_out_of_offline
_wait_phys_link_out_of_offline:         ## @wait_phys_link_out_of_offline
	.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
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r15
	movq	_jiffies@GOTPCREL(%rip), %rax
	movq	(%rax), %r13
	movl	%esi, -44(%rbp)                 ## 4-byte Spill
	movl	%esi, %edi
	callq	_msecs_to_jiffies
	movq	%rax, %r12
	movl	(%r15), %edi
	callq	_read_physical_state
	movl	%eax, %ebx
	andl	$240, %eax
	movq	_PLS_OFFLINE@GOTPCREL(%rip), %r14
	cmpl	(%r14), %eax
	jne	LBB0_4
## %bb.1:
	addq	%r13, %r12
	movq	_jiffies@GOTPCREL(%rip), %r13
	.p2align	4, 0x90
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	movq	(%r13), %rdi
	movq	%r12, %rsi
	callq	_time_after
	testq	%rax, %rax
	jne	LBB0_6
## %bb.3:                               ##   in Loop: Header=BB0_2 Depth=1
	movl	$1950, %edi                     ## imm = 0x79E
	movl	$2050, %esi                     ## imm = 0x802
	callq	_usleep_range
	movl	(%r15), %edi
	callq	_read_physical_state
	movl	%eax, %ebx
	andl	$240, %eax
	cmpl	(%r14), %eax
	je	LBB0_2
LBB0_4:
	movq	%r15, %rdi
	movl	%ebx, %esi
	callq	_log_state_transition
	jmp	LBB0_5
LBB0_6:
	movl	(%r15), %edi
	leaq	L_.str(%rip), %rsi
	movl	%ebx, %edx
	movl	-44(%rbp), %ecx                 ## 4-byte Reload
	callq	_dd_dev_err
	movq	_ETIMEDOUT@GOTPCREL(%rip), %rax
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
LBB0_5:
	movl	%ebx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_jiffies,8,3                    ## @jiffies
	.comm	_PLS_OFFLINE,4,2                ## @PLS_OFFLINE
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"timeout waiting for phy link out of offline. Read state 0x%x, %dms\n"

	.comm	_ETIMEDOUT,4,2                  ## @ETIMEDOUT
	.no_dead_strip	_wait_phys_link_out_of_offline
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function wait_phys_link_out_of_offline
_wait_phys_link_out_of_offline:         ; @wait_phys_link_out_of_offline
	.cfi_startproc
; %bb.0:
	stp	x26, x25, [sp, #-80]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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
	mov	x20, x1
	mov	x19, x0
Lloh0:
	adrp	x23, _jiffies@GOTPAGE
Lloh1:
	ldr	x23, [x23, _jiffies@GOTPAGEOFF]
	ldr	x25, [x23]
	mov	x0, x1
	bl	_msecs_to_jiffies
	mov	x22, x0
	ldr	w0, [x19]
	bl	_read_physical_state
	mov	x21, x0
	and	w8, w0, #0xf0
Lloh2:
	adrp	x24, _PLS_OFFLINE@GOTPAGE
Lloh3:
	ldr	x24, [x24, _PLS_OFFLINE@GOTPAGEOFF]
	ldr	w9, [x24]
	cmp	w8, w9
	b.ne	LBB0_4
; %bb.1:
	add	x22, x22, x25
LBB0_2:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x0, [x23]
	mov	x1, x22
	bl	_time_after
	cbnz	x0, LBB0_5
; %bb.3:                                ;   in Loop: Header=BB0_2 Depth=1
	mov	w0, #1950
	mov	w1, #2050
	bl	_usleep_range
	ldr	w0, [x19]
	bl	_read_physical_state
	mov	x21, x0
	and	w8, w0, #0xf0
	ldr	w9, [x24]
	cmp	w8, w9
	b.eq	LBB0_2
LBB0_4:
	mov	x0, x19
	mov	x1, x21
	bl	_log_state_transition
	b	LBB0_6
LBB0_5:
	ldr	w0, [x19]
Lloh4:
	adrp	x1, l_.str@PAGE
Lloh5:
	add	x1, x1, l_.str@PAGEOFF
	mov	x2, x21
	mov	x3, x20
	bl	_dd_dev_err
Lloh6:
	adrp	x8, _ETIMEDOUT@GOTPAGE
Lloh7:
	ldr	x8, [x8, _ETIMEDOUT@GOTPAGEOFF]
Lloh8:
	ldr	w8, [x8]
	neg	w21, w8
LBB0_6:
	mov	x0, x21
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp], #80             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpAdd	Lloh4, Lloh5
	.cfi_endproc
                                        ; -- End function
	.comm	_jiffies,8,3                    ; @jiffies
	.comm	_PLS_OFFLINE,4,2                ; @PLS_OFFLINE
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"timeout waiting for phy link out of offline. Read state 0x%x, %dms\n"

	.comm	_ETIMEDOUT,4,2                  ; @ETIMEDOUT
	.no_dead_strip	_wait_phys_link_out_of_offline
.subsections_via_symbols
