	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_i40e_reset_all_vfs             ## -- Begin function i40e_reset_all_vfs
	.p2align	4, 0x90
_i40e_reset_all_vfs:                    ## @i40e_reset_all_vfs
	.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	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	xorl	%r14d, %r14d
	cmpl	$0, (%rdi)
	je	LBB0_32
## %bb.1:
	movl	%esi, %r15d
	movq	%rdi, %r13
	movq	___I40E_VF_DISABLE@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	4(%r13), %esi
	callq	_test_and_set_bit
	testq	%rax, %rax
	jne	LBB0_32
## %bb.2:
	movl	(%r13), %eax
	testl	%eax, %eax
	jle	LBB0_5
## %bb.3:
	xorl	%r14d, %r14d
	xorl	%ebx, %ebx
	.p2align	4, 0x90
LBB0_4:                                 ## =>This Inner Loop Header: Depth=1
	movq	8(%r13), %rdi
	addq	%r14, %rdi
	movl	%r15d, %esi
	callq	_i40e_trigger_vf_reset
	incq	%rbx
	movslq	(%r13), %rax
	addq	$16, %r14
	cmpq	%rax, %rbx
	jl	LBB0_4
LBB0_5:
	leaq	32(%r13), %rcx
	movq	%rcx, -56(%rbp)                 ## 8-byte Spill
	testl	%eax, %eax
	movl	%r15d, -44(%rbp)                ## 4-byte Spill
	jle	LBB0_6
## %bb.7:
	xorl	%r12d, %r12d
	movq	_I40E_VPGEN_VFRSTAT_VFRD_MASK@GOTPCREL(%rip), %r15
	xorl	%r14d, %r14d
	.p2align	4, 0x90
LBB0_8:                                 ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_10 Depth 2
	movl	$10000, %edi                    ## imm = 0x2710
	movl	$20000, %esi                    ## imm = 0x4E20
	callq	_usleep_range
	cmpl	(%r13), %r14d
	jge	LBB0_12
## %bb.9:                               ##   in Loop: Header=BB0_8 Depth=1
	movslq	%r14d, %r14
	movq	%r14, %rbx
	shlq	$4, %rbx
	orq	$8, %rbx
	.p2align	4, 0x90
LBB0_10:                                ##   Parent Loop BB0_8 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	movq	8(%r13), %rax
	movl	(%rax,%rbx), %edi
	callq	_I40E_VPGEN_VFRSTAT
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	movl	%eax, %esi
	callq	_rd32
	testl	%eax, (%r15)
	je	LBB0_12
## %bb.11:                              ##   in Loop: Header=BB0_10 Depth=2
	incq	%r14
	movslq	(%r13), %rax
	addq	$16, %rbx
	cmpq	%rax, %r14
	jl	LBB0_10
LBB0_12:                                ##   in Loop: Header=BB0_8 Depth=1
	incl	%r12d
	cmpl	$10, %r12d
	je	LBB0_14
## %bb.13:                              ##   in Loop: Header=BB0_8 Depth=1
	cmpl	(%r13), %r14d
	jl	LBB0_8
	jmp	LBB0_14
LBB0_6:
	xorl	%r14d, %r14d
LBB0_14:
	cmpl	$0, -44(%rbp)                   ## 4-byte Folded Reload
	je	LBB0_16
## %bb.15:
	movl	$10000, %edi                    ## imm = 0x2710
	movl	$20000, %esi                    ## imm = 0x4E20
	callq	_usleep_range
LBB0_16:
	cmpl	(%r13), %r14d
	movq	___I40E_VF_DISABLE@GOTPCREL(%rip), %r15
	jge	LBB0_18
## %bb.17:
	movq	8(%r13), %rax
	movq	24(%r13), %rdi
	movslq	%r14d, %rcx
	shlq	$4, %rcx
	movl	8(%rax,%rcx), %edx
	leaq	L_.str(%rip), %rsi
	callq	_dev_err
LBB0_18:
	movl	$10000, %edi                    ## imm = 0x2710
	movl	$20000, %esi                    ## imm = 0x4E20
	callq	_usleep_range
	movl	(%r13), %eax
	testl	%eax, %eax
	jle	LBB0_28
## %bb.19:
	xorl	%r14d, %r14d
	xorl	%ebx, %ebx
	jmp	LBB0_20
	.p2align	4, 0x90
LBB0_22:                                ##   in Loop: Header=BB0_20 Depth=1
	incq	%rbx
	movslq	%eax, %rcx
	addq	$16, %r14
	cmpq	%rcx, %rbx
	jge	LBB0_23
LBB0_20:                                ## =>This Inner Loop Header: Depth=1
	movq	8(%r13), %rcx
	movq	(%rcx,%r14), %rcx
	testq	%rcx, %rcx
	je	LBB0_22
## %bb.21:                              ##   in Loop: Header=BB0_20 Depth=1
	movq	16(%r13), %rax
	movl	(%rax,%rcx,4), %edi
	callq	_i40e_vsi_stop_rings_no_wait
	movl	(%r13), %eax
	jmp	LBB0_22
LBB0_23:
	testl	%eax, %eax
	jle	LBB0_28
## %bb.24:
	xorl	%r14d, %r14d
	xorl	%ebx, %ebx
	jmp	LBB0_25
	.p2align	4, 0x90
LBB0_27:                                ##   in Loop: Header=BB0_25 Depth=1
	incq	%rbx
	movslq	%eax, %rcx
	addq	$16, %r14
	cmpq	%rcx, %rbx
	jge	LBB0_28
LBB0_25:                                ## =>This Inner Loop Header: Depth=1
	movq	8(%r13), %rcx
	movq	(%rcx,%r14), %rcx
	testq	%rcx, %rcx
	je	LBB0_27
## %bb.26:                              ##   in Loop: Header=BB0_25 Depth=1
	movq	16(%r13), %rax
	movl	(%rax,%rcx,4), %edi
	callq	_i40e_vsi_wait_queues_disabled
	movl	(%r13), %eax
	jmp	LBB0_27
LBB0_28:
	movl	$50, %edi
	callq	_mdelay
	cmpl	$0, (%r13)
	jle	LBB0_31
## %bb.29:
	xorl	%r14d, %r14d
	xorl	%ebx, %ebx
	.p2align	4, 0x90
LBB0_30:                                ## =>This Inner Loop Header: Depth=1
	movq	8(%r13), %rdi
	addq	%r14, %rdi
	callq	_i40e_cleanup_reset_vf
	incq	%rbx
	movslq	(%r13), %rax
	addq	$16, %r14
	cmpq	%rax, %rbx
	jl	LBB0_30
LBB0_31:
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	callq	_i40e_flush
	movl	(%r15), %edi
	movl	4(%r13), %esi
	callq	_clear_bit
	movl	$1, %r14d
LBB0_32:
	movl	%r14d, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	___I40E_VF_DISABLE,4,2          ## @__I40E_VF_DISABLE
	.comm	_I40E_VPGEN_VFRSTAT_VFRD_MASK,4,2 ## @I40E_VPGEN_VFRSTAT_VFRD_MASK
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"VF reset check timeout on VF %d\n"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_i40e_reset_all_vfs             ; -- Begin function i40e_reset_all_vfs
	.p2align	2
_i40e_reset_all_vfs:                    ; @i40e_reset_all_vfs
	.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, x0
	ldr	w8, [x20], #32
	cbz	w8, LBB0_2
; %bb.1:
	mov	x21, x1
	mov	x19, x0
Lloh0:
	adrp	x22, ___I40E_VF_DISABLE@GOTPAGE
Lloh1:
	ldr	x22, [x22, ___I40E_VF_DISABLE@GOTPAGEOFF]
	ldr	w0, [x22]
	ldr	w1, [x19, #4]
	bl	_test_and_set_bit
	cbz	x0, LBB0_3
LBB0_2:
	mov	w0, #0
	b	LBB0_33
LBB0_3:
	ldr	w8, [x19]
	cmp	w8, #1
	b.lt	LBB0_6
; %bb.4:
	mov	x23, #0
	mov	x24, #0
LBB0_5:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x8, [x19, #8]
	add	x0, x8, x23
	mov	x1, x21
	bl	_i40e_trigger_vf_reset
	add	x24, x24, #1
	ldrsw	x8, [x19]
	add	x23, x23, #16
	cmp	x24, x8
	b.lt	LBB0_5
LBB0_6:
	cmp	w8, #1
	b.lt	LBB0_14
; %bb.7:
	mov	w24, #0
	mov	w23, #0
Lloh2:
	adrp	x25, _I40E_VPGEN_VFRSTAT_VFRD_MASK@GOTPAGE
Lloh3:
	ldr	x25, [x25, _I40E_VPGEN_VFRSTAT_VFRD_MASK@GOTPAGEOFF]
LBB0_8:                                 ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_10 Depth 2
	mov	w0, #10000
	mov	w1, #20000
	bl	_usleep_range
	ldr	w8, [x19]
	cmp	w23, w8
	b.ge	LBB0_12
; %bb.9:                                ;   in Loop: Header=BB0_8 Depth=1
                                        ; kill: def $w23 killed $w23 killed $x23 def $x23
	sxtw	x23, w23
	mov	w26, #8
	bfi	x26, x23, #4, #60
LBB0_10:                                ;   Parent Loop BB0_8 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	ldr	x8, [x19, #8]
	ldr	w0, [x8, x26]
	bl	_I40E_VPGEN_VFRSTAT
	mov	x1, x0
	mov	x0, x20
	bl	_rd32
	ldr	w8, [x25]
	tst	w8, w0
	b.eq	LBB0_12
; %bb.11:                               ;   in Loop: Header=BB0_10 Depth=2
	add	x23, x23, #1
	ldrsw	x8, [x19]
	add	x26, x26, #16
	cmp	x23, x8
	b.lt	LBB0_10
LBB0_12:                                ;   in Loop: Header=BB0_8 Depth=1
	add	w24, w24, #1
	cmp	w24, #10
	b.eq	LBB0_15
; %bb.13:                               ;   in Loop: Header=BB0_8 Depth=1
	ldr	w8, [x19]
	cmp	w23, w8
	b.lt	LBB0_8
	b	LBB0_15
LBB0_14:
	mov	w23, #0
LBB0_15:
	cbz	w21, LBB0_17
; %bb.16:
	mov	w0, #10000
	mov	w1, #20000
	bl	_usleep_range
LBB0_17:
	ldr	w8, [x19]
	cmp	w23, w8
	b.ge	LBB0_19
; %bb.18:
	ldr	x0, [x19, #24]
	ldr	x8, [x19, #8]
	add	x8, x8, w23, sxtw #4
	ldr	w2, [x8, #8]
Lloh4:
	adrp	x1, l_.str@PAGE
Lloh5:
	add	x1, x1, l_.str@PAGEOFF
	bl	_dev_err
LBB0_19:
	mov	w0, #10000
	mov	w1, #20000
	bl	_usleep_range
	ldr	w8, [x19]
	cmp	w8, #1
	b.lt	LBB0_29
; %bb.20:
	mov	x21, #0
	mov	x23, #0
	b	LBB0_22
LBB0_21:                                ;   in Loop: Header=BB0_22 Depth=1
	add	x23, x23, #1
	add	x21, x21, #16
	cmp	x23, w8, sxtw
	b.ge	LBB0_24
LBB0_22:                                ; =>This Inner Loop Header: Depth=1
	ldr	x9, [x19, #8]
	ldr	x9, [x9, x21]
	cbz	x9, LBB0_21
; %bb.23:                               ;   in Loop: Header=BB0_22 Depth=1
	ldr	x8, [x19, #16]
	ldr	w0, [x8, x9, lsl #2]
	bl	_i40e_vsi_stop_rings_no_wait
	ldr	w8, [x19]
	b	LBB0_21
LBB0_24:
	cmp	w8, #1
	b.lt	LBB0_29
; %bb.25:
	mov	x21, #0
	mov	x23, #0
	b	LBB0_27
LBB0_26:                                ;   in Loop: Header=BB0_27 Depth=1
	add	x23, x23, #1
	add	x21, x21, #16
	cmp	x23, w8, sxtw
	b.ge	LBB0_29
LBB0_27:                                ; =>This Inner Loop Header: Depth=1
	ldr	x9, [x19, #8]
	ldr	x9, [x9, x21]
	cbz	x9, LBB0_26
; %bb.28:                               ;   in Loop: Header=BB0_27 Depth=1
	ldr	x8, [x19, #16]
	ldr	w0, [x8, x9, lsl #2]
	bl	_i40e_vsi_wait_queues_disabled
	ldr	w8, [x19]
	b	LBB0_26
LBB0_29:
	mov	w0, #50
	bl	_mdelay
	ldr	w8, [x19]
	cmp	w8, #1
	b.lt	LBB0_32
; %bb.30:
	mov	x21, #0
	mov	x23, #0
LBB0_31:                                ; =>This Inner Loop Header: Depth=1
	ldr	x8, [x19, #8]
	add	x0, x8, x21
	bl	_i40e_cleanup_reset_vf
	add	x23, x23, #1
	ldrsw	x8, [x19]
	add	x21, x21, #16
	cmp	x23, x8
	b.lt	LBB0_31
LBB0_32:
	mov	x0, x20
	bl	_i40e_flush
	ldr	w0, [x22]
	ldr	w1, [x19, #4]
	bl	_clear_bit
	mov	w0, #1
LBB0_33:
	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	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpAdd	Lloh4, Lloh5
	.cfi_endproc
                                        ; -- End function
	.comm	___I40E_VF_DISABLE,4,2          ; @__I40E_VF_DISABLE
	.comm	_I40E_VPGEN_VFRSTAT_VFRD_MASK,4,2 ; @I40E_VPGEN_VFRSTAT_VFRD_MASK
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"VF reset check timeout on VF %d\n"

.subsections_via_symbols
