	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function be_pci_sriov_configure
_be_pci_sriov_configure:                ## @be_pci_sriov_configure
	.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	%rbx
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%esi, %ebx
	movq	%rdi, %r14
	callq	_pci_get_drvdata
	movq	%rax, %r15
	movl	$0, -32(%rbp)
	testl	%ebx, %ebx
	je	LBB0_9
## %bb.1:
	movl	%ebx, (%r15)
LBB0_2:
	movq	%r15, %rdi
	callq	_skyhawk_chip
	testq	%rax, %rax
	je	LBB0_6
## %bb.3:
	movq	%r14, %rdi
	callq	_pci_num_vf
	testl	%eax, %eax
	jne	LBB0_6
## %bb.4:
	movl	(%r15), %esi
	leaq	-32(%rbp), %rbx
	movq	%r15, %rdi
	movq	%rbx, %rdx
	callq	_be_calculate_vf_res
	movl	(%r15), %edx
	movl	4(%r15), %esi
	movq	%r15, %rdi
	movq	%rbx, %rcx
	callq	_be_cmd_set_sriov_config
	testl	%eax, %eax
	je	LBB0_6
## %bb.5:
	leaq	L_.str.1(%rip), %rsi
	movq	%r14, %rdi
	callq	_dev_err
LBB0_6:
	movq	%r15, %rdi
	callq	_be_get_resources
	testl	%eax, %eax
	je	LBB0_11
## %bb.7:
	movl	%eax, %edi
	jmp	LBB0_8
LBB0_9:
	movq	%r15, %rdi
	callq	_be_vf_clear
	movl	$0, (%r15)
	movq	%r14, %rdi
	callq	_pci_vfs_assigned
	testq	%rax, %rax
	je	LBB0_2
## %bb.10:
	leaq	L_.str(%rip), %rsi
	movq	%r14, %rdi
	callq	_dev_warn
	movq	_EBUSY@GOTPCREL(%rip), %rax
	xorl	%r14d, %r14d
	subl	(%rax), %r14d
	jmp	LBB0_16
LBB0_11:
	xorl	%r14d, %r14d
	xorl	%eax, %eax
	callq	_rtnl_lock
	movq	%r15, %rdi
	callq	_be_update_queues
	movl	%eax, %ebx
	xorl	%eax, %eax
	callq	_rtnl_unlock
	testl	%ebx, %ebx
	je	LBB0_13
## %bb.12:
	movl	%ebx, %edi
LBB0_8:
	callq	_be_cmd_status
	movl	%eax, %r14d
LBB0_16:
	movl	%r14d, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_13:
	cmpl	$0, (%r15)
	je	LBB0_16
## %bb.14:
	movq	%r15, %rdi
	callq	_be_vf_setup
	testl	%eax, %eax
	jne	LBB0_16
## %bb.15:
	movl	(%r15), %r14d
	jmp	LBB0_16
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Cannot disable VFs while they are assigned\n"

	.comm	_EBUSY,4,2                      ## @EBUSY
L_.str.1:                               ## @.str.1
	.asciz	"Failed to optimize SR-IOV resources\n"

	.no_dead_strip	_be_pci_sriov_configure
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function be_pci_sriov_configure
_be_pci_sriov_configure:                ; @be_pci_sriov_configure
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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
	mov	x21, x1
	mov	x20, x0
	bl	_pci_get_drvdata
	mov	x19, x0
	str	wzr, [sp, #8]
	cbz	w21, LBB0_10
; %bb.1:
	str	w21, [x19]
LBB0_2:
	mov	x0, x19
	bl	_skyhawk_chip
	cbz	x0, LBB0_6
; %bb.3:
	mov	x0, x20
	bl	_pci_num_vf
	cbnz	w0, LBB0_6
; %bb.4:
	ldr	w1, [x19]
	add	x2, sp, #8
	mov	x0, x19
	bl	_be_calculate_vf_res
	ldp	w2, w1, [x19]
	add	x3, sp, #8
	mov	x0, x19
	bl	_be_cmd_set_sriov_config
	cbz	w0, LBB0_6
; %bb.5:
Lloh0:
	adrp	x1, l_.str.1@PAGE
Lloh1:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x0, x20
	bl	_dev_err
LBB0_6:
	mov	x0, x19
	bl	_be_get_resources
	cbnz	w0, LBB0_9
; %bb.7:
	bl	_rtnl_lock
	mov	x0, x19
	bl	_be_update_queues
	mov	x20, x0
	bl	_rtnl_unlock
	cbz	w20, LBB0_12
; %bb.8:
	mov	x0, x20
LBB0_9:
	bl	_be_cmd_status
	b	LBB0_16
LBB0_10:
	mov	x0, x19
	bl	_be_vf_clear
	str	wzr, [x19]
	mov	x0, x20
	bl	_pci_vfs_assigned
	cbz	x0, LBB0_2
; %bb.11:
Lloh2:
	adrp	x1, l_.str@PAGE
Lloh3:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x20
	bl	_dev_warn
Lloh4:
	adrp	x8, _EBUSY@GOTPAGE
Lloh5:
	ldr	x8, [x8, _EBUSY@GOTPAGEOFF]
Lloh6:
	ldr	w8, [x8]
	neg	w0, w8
	b	LBB0_16
LBB0_12:
	ldr	w8, [x19]
	cbz	w8, LBB0_14
; %bb.13:
	mov	x0, x19
	bl	_be_vf_setup
	cbz	w0, LBB0_15
LBB0_14:
	mov	w0, #0
	b	LBB0_16
LBB0_15:
	ldr	w0, [x19]
LBB0_16:
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #64
	ret
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh4, Lloh5, Lloh6
	.loh AdrpAdd	Lloh2, Lloh3
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Cannot disable VFs while they are assigned\n"

	.comm	_EBUSY,4,2                      ; @EBUSY
l_.str.1:                               ; @.str.1
	.asciz	"Failed to optimize SR-IOV resources\n"

	.no_dead_strip	_be_pci_sriov_configure
.subsections_via_symbols
