	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ixgbe_check_cs4227
_ixgbe_check_cs4227:                    ## @ixgbe_check_cs4227
	.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, %r13
	movl	24(%rdi), %r14d
	movq	_IXGBE_CS4227_RETRIES@GOTPCREL(%rip), %r15
	movq	(%r15), %rax
	xorl	%ebx, %ebx
	testq	%rax, %rax
	jle	LBB0_10
## %bb.1:
	movq	_IXGBE_CS4227_CHECK_DELAY@GOTPCREL(%rip), %r12
	jmp	LBB0_2
	.p2align	4, 0x90
LBB0_3:                                 ##   in Loop: Header=BB0_2 Depth=1
	movq	%r13, %rdi
	leaq	L_.str(%rip), %rsi
	movq	%rax, %rdx
	callq	_hw_err
LBB0_8:                                 ##   in Loop: Header=BB0_2 Depth=1
	movl	(%r12), %edi
	callq	_msleep
	incq	%rbx
	cmpq	(%r15), %rbx
	jge	LBB0_9
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	movq	%r13, %rdi
	movl	%r14d, %esi
	callq	*16(%r13)
	testq	%rax, %rax
	jne	LBB0_3
## %bb.4:                               ##   in Loop: Header=BB0_2 Depth=1
	movq	_IXGBE_CS4227_SCRATCH@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r13, %rdi
	leaq	-48(%rbp), %rdx
	callq	_ixgbe_read_cs4227
	testq	%rax, %rax
	jne	LBB0_9
## %bb.5:                               ##   in Loop: Header=BB0_2 Depth=1
	movq	-48(%rbp), %rax
	movq	_IXGBE_CS4227_RESET_COMPLETE@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	je	LBB0_19
## %bb.6:                               ##   in Loop: Header=BB0_2 Depth=1
	movq	_IXGBE_CS4227_RESET_PENDING@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_9
## %bb.7:                               ##   in Loop: Header=BB0_2 Depth=1
	movq	%r13, %rdi
	movl	%r14d, %esi
	callq	*8(%r13)
	jmp	LBB0_8
LBB0_9:
	movq	(%r15), %rax
LBB0_10:
	cmpq	%rax, %rbx
	jne	LBB0_14
## %bb.11:
	movq	%r13, %rdi
	movl	%r14d, %esi
	callq	*16(%r13)
	testq	%rax, %rax
	je	LBB0_14
## %bb.12:
	leaq	L_.str(%rip), %rsi
	jmp	LBB0_13
LBB0_14:
	movq	%r13, %rdi
	callq	_ixgbe_reset_cs4227
	testq	%rax, %rax
	je	LBB0_16
## %bb.15:
	leaq	L_.str.1(%rip), %rsi
	movq	%r13, %rdi
	movq	%rax, %rdx
	callq	_hw_err
LBB0_19:
	movq	%r13, %rdi
	movl	%r14d, %esi
	callq	*8(%r13)
	movl	(%r13), %edi
	callq	_msleep
	jmp	LBB0_20
LBB0_16:
	movq	_IXGBE_CS4227_SCRATCH@GOTPCREL(%rip), %rbx
	movl	(%rbx), %esi
	movq	_IXGBE_CS4227_RESET_PENDING@GOTPCREL(%rip), %rax
	movq	(%rax), %rdx
	movq	%r13, %rdi
	callq	_ixgbe_write_cs4227
	movq	%r13, %rdi
	movl	%r14d, %esi
	callq	*8(%r13)
	movl	$10000, %edi                    ## imm = 0x2710
	movl	$12000, %esi                    ## imm = 0x2EE0
	callq	_usleep_range
	movq	%r13, %rdi
	movl	%r14d, %esi
	callq	*16(%r13)
	testq	%rax, %rax
	je	LBB0_18
## %bb.17:
	leaq	L_.str.2(%rip), %rsi
LBB0_13:
	movq	%r13, %rdi
	movq	%rax, %rdx
	callq	_hw_err
LBB0_20:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_18:
	movl	(%rbx), %esi
	movq	_IXGBE_CS4227_RESET_COMPLETE@GOTPCREL(%rip), %rax
	movq	(%rax), %rdx
	movq	%r13, %rdi
	callq	_ixgbe_write_cs4227
	jmp	LBB0_19
	.cfi_endproc
                                        ## -- End function
	.comm	_IXGBE_CS4227_RETRIES,8,3       ## @IXGBE_CS4227_RETRIES
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"semaphore failed with %d\n"

	.comm	_IXGBE_CS4227_CHECK_DELAY,4,2   ## @IXGBE_CS4227_CHECK_DELAY
	.comm	_IXGBE_CS4227_SCRATCH,4,2       ## @IXGBE_CS4227_SCRATCH
	.comm	_IXGBE_CS4227_RESET_COMPLETE,8,3 ## @IXGBE_CS4227_RESET_COMPLETE
	.comm	_IXGBE_CS4227_RESET_PENDING,8,3 ## @IXGBE_CS4227_RESET_PENDING
L_.str.1:                               ## @.str.1
	.asciz	"CS4227 reset failed: %d"

L_.str.2:                               ## @.str.2
	.asciz	"semaphore failed with %d"

	.no_dead_strip	_ixgbe_check_cs4227
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ixgbe_check_cs4227
_ixgbe_check_cs4227:                    ; @ixgbe_check_cs4227
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	stp	x28, x27, [sp, #16]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #32]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #48]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #64]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #80]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #96]             ; 16-byte Folded Spill
	add	x29, sp, #96
	.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	x19, x0
	ldr	w20, [x0, #24]
Lloh0:
	adrp	x23, _IXGBE_CS4227_RETRIES@GOTPAGE
Lloh1:
	ldr	x23, [x23, _IXGBE_CS4227_RETRIES@GOTPAGEOFF]
	ldr	x8, [x23]
	cmp	x8, #1
	b.lt	LBB0_10
; %bb.1:
	mov	x22, #0
Lloh2:
	adrp	x24, _IXGBE_CS4227_SCRATCH@GOTPAGE
Lloh3:
	ldr	x24, [x24, _IXGBE_CS4227_SCRATCH@GOTPAGEOFF]
Lloh4:
	adrp	x25, _IXGBE_CS4227_RESET_COMPLETE@GOTPAGE
Lloh5:
	ldr	x25, [x25, _IXGBE_CS4227_RESET_COMPLETE@GOTPAGEOFF]
Lloh6:
	adrp	x26, _IXGBE_CS4227_RESET_PENDING@GOTPAGE
Lloh7:
	ldr	x26, [x26, _IXGBE_CS4227_RESET_PENDING@GOTPAGEOFF]
Lloh8:
	adrp	x21, l_.str@PAGE
Lloh9:
	add	x21, x21, l_.str@PAGEOFF
Lloh10:
	adrp	x27, _IXGBE_CS4227_CHECK_DELAY@GOTPAGE
Lloh11:
	ldr	x27, [x27, _IXGBE_CS4227_CHECK_DELAY@GOTPAGEOFF]
	b	LBB0_4
LBB0_2:                                 ;   in Loop: Header=BB0_4 Depth=1
	mov	x2, x0
	mov	x0, x19
	mov	x1, x21
	bl	_hw_err
LBB0_3:                                 ;   in Loop: Header=BB0_4 Depth=1
	ldr	w0, [x27]
	bl	_msleep
	add	x22, x22, #1
	ldr	x8, [x23]
	cmp	x22, x8
	b.ge	LBB0_9
LBB0_4:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x8, [x19, #16]
	mov	x0, x19
	mov	x1, x20
	blr	x8
	cbnz	x0, LBB0_2
; %bb.5:                                ;   in Loop: Header=BB0_4 Depth=1
	ldr	w1, [x24]
	add	x2, sp, #8
	mov	x0, x19
	bl	_ixgbe_read_cs4227
	cbnz	x0, LBB0_9
; %bb.6:                                ;   in Loop: Header=BB0_4 Depth=1
	ldr	x8, [sp, #8]
	ldr	x9, [x25]
	cmp	x8, x9
	b.eq	LBB0_15
; %bb.7:                                ;   in Loop: Header=BB0_4 Depth=1
	ldr	x9, [x26]
	cmp	x8, x9
	b.ne	LBB0_9
; %bb.8:                                ;   in Loop: Header=BB0_4 Depth=1
	ldr	x8, [x19, #8]
	mov	x0, x19
	mov	x1, x20
	blr	x8
	b	LBB0_3
LBB0_9:
	ldr	x8, [x23]
	cmp	x22, x8
	b.eq	LBB0_11
	b	LBB0_13
LBB0_10:
	mov	x22, #0
	cmp	x22, x8
	b.ne	LBB0_13
LBB0_11:
	ldr	x8, [x19, #16]
	mov	x0, x19
	mov	x1, x20
	blr	x8
	cbz	x0, LBB0_13
; %bb.12:
	mov	x2, x0
Lloh12:
	adrp	x1, l_.str@PAGE
Lloh13:
	add	x1, x1, l_.str@PAGEOFF
	b	LBB0_18
LBB0_13:
	mov	x0, x19
	bl	_ixgbe_reset_cs4227
	cbz	x0, LBB0_16
; %bb.14:
	mov	x2, x0
Lloh14:
	adrp	x1, l_.str.1@PAGE
Lloh15:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x0, x19
	bl	_hw_err
LBB0_15:
	ldr	x8, [x19, #8]
	mov	x0, x19
	mov	x1, x20
	blr	x8
	ldr	w0, [x19]
	bl	_msleep
	b	LBB0_19
LBB0_16:
Lloh16:
	adrp	x21, _IXGBE_CS4227_SCRATCH@GOTPAGE
Lloh17:
	ldr	x21, [x21, _IXGBE_CS4227_SCRATCH@GOTPAGEOFF]
	ldr	w1, [x21]
Lloh18:
	adrp	x8, _IXGBE_CS4227_RESET_PENDING@GOTPAGE
Lloh19:
	ldr	x8, [x8, _IXGBE_CS4227_RESET_PENDING@GOTPAGEOFF]
Lloh20:
	ldr	x2, [x8]
	mov	x0, x19
	bl	_ixgbe_write_cs4227
	ldr	x8, [x19, #8]
	mov	x0, x19
	mov	x1, x20
	blr	x8
	mov	w0, #10000
	mov	w1, #12000
	bl	_usleep_range
	ldr	x8, [x19, #16]
	mov	x0, x19
	mov	x1, x20
	blr	x8
	cbz	x0, LBB0_20
; %bb.17:
	mov	x2, x0
Lloh21:
	adrp	x1, l_.str.2@PAGE
Lloh22:
	add	x1, x1, l_.str.2@PAGEOFF
LBB0_18:
	mov	x0, x19
	bl	_hw_err
LBB0_19:
	ldp	x29, x30, [sp, #96]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #80]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #64]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #48]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #32]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #112
	ret
LBB0_20:
	ldr	w1, [x21]
Lloh23:
	adrp	x8, _IXGBE_CS4227_RESET_COMPLETE@GOTPAGE
Lloh24:
	ldr	x8, [x8, _IXGBE_CS4227_RESET_COMPLETE@GOTPAGEOFF]
Lloh25:
	ldr	x2, [x8]
	mov	x0, x19
	bl	_ixgbe_write_cs4227
	b	LBB0_15
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh10, Lloh11
	.loh AdrpAdd	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpAdd	Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGot	Lloh16, Lloh17
	.loh AdrpAdd	Lloh21, Lloh22
	.loh AdrpLdrGotLdr	Lloh23, Lloh24, Lloh25
	.cfi_endproc
                                        ; -- End function
	.comm	_IXGBE_CS4227_RETRIES,8,3       ; @IXGBE_CS4227_RETRIES
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"semaphore failed with %d\n"

	.comm	_IXGBE_CS4227_CHECK_DELAY,4,2   ; @IXGBE_CS4227_CHECK_DELAY
	.comm	_IXGBE_CS4227_SCRATCH,4,2       ; @IXGBE_CS4227_SCRATCH
	.comm	_IXGBE_CS4227_RESET_COMPLETE,8,3 ; @IXGBE_CS4227_RESET_COMPLETE
	.comm	_IXGBE_CS4227_RESET_PENDING,8,3 ; @IXGBE_CS4227_RESET_PENDING
l_.str.1:                               ; @.str.1
	.asciz	"CS4227 reset failed: %d"

l_.str.2:                               ; @.str.2
	.asciz	"semaphore failed with %d"

	.no_dead_strip	_ixgbe_check_cs4227
.subsections_via_symbols
