	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function qlcnic_83xx_clear_function_resources
_qlcnic_83xx_clear_function_resources:  ## @qlcnic_83xx_clear_function_resources
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r14
	pushq	%rbx
	subq	$16, %rsp
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movq	%rdi, %rbx
	movl	8(%rdi), %edi
	movq	_QLC_83XX_IDC_DRV_PRESENCE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_QLCRDX
	movl	%eax, %r14d
	movl	8(%rbx), %edi
	movq	_QLC_83XX_IDC_DRV_AUDIT@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_QLCRDX
	movq	%rbx, %rdi
	movl	%r14d, %esi
	movl	%eax, %edx
	callq	_IS_QLC_83XX_USED
	testq	%rax, %rax
	je	LBB0_4
## %bb.1:
	movq	_QLCNIC_CMD_STOP_NIC_FUNC@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	leaq	-24(%rbp), %r14
	movq	%r14, %rdi
	movq	%rbx, %rsi
	callq	_qlcnic_alloc_mbx_args
	movq	_BIT_31@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movq	-24(%rbp), %rcx
	movl	%eax, 4(%rcx)
	movq	%rbx, %rdi
	movq	%r14, %rsi
	callq	_qlcnic_issue_cmd
	testl	%eax, %eax
	je	LBB0_3
## %bb.2:
	movq	(%rbx), %rdi
	leaq	L_.str(%rip), %rsi
	callq	_dev_err
LBB0_3:
	leaq	-24(%rbp), %rdi
	callq	_qlcnic_free_mbx_args
LBB0_4:
	addq	$16, %rsp
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_QLC_83XX_IDC_DRV_PRESENCE,4,2  ## @QLC_83XX_IDC_DRV_PRESENCE
	.comm	_QLC_83XX_IDC_DRV_AUDIT,4,2     ## @QLC_83XX_IDC_DRV_AUDIT
	.comm	_QLCNIC_CMD_STOP_NIC_FUNC,4,2   ## @QLCNIC_CMD_STOP_NIC_FUNC
	.comm	_BIT_31,4,2                     ## @BIT_31
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Failed to clean up the function resources\n"

	.no_dead_strip	_qlcnic_83xx_clear_function_resources
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function qlcnic_83xx_clear_function_resources
_qlcnic_83xx_clear_function_resources:  ; @qlcnic_83xx_clear_function_resources
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #48
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	mov	x19, x0
	ldr	w0, [x0, #8]
Lloh0:
	adrp	x8, _QLC_83XX_IDC_DRV_PRESENCE@GOTPAGE
Lloh1:
	ldr	x8, [x8, _QLC_83XX_IDC_DRV_PRESENCE@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	bl	_QLCRDX
	mov	x20, x0
	ldr	w0, [x19, #8]
Lloh3:
	adrp	x8, _QLC_83XX_IDC_DRV_AUDIT@GOTPAGE
Lloh4:
	ldr	x8, [x8, _QLC_83XX_IDC_DRV_AUDIT@GOTPAGEOFF]
Lloh5:
	ldr	w1, [x8]
	bl	_QLCRDX
	mov	x2, x0
	mov	x0, x19
	mov	x1, x20
	bl	_IS_QLC_83XX_USED
	cbz	x0, LBB0_4
; %bb.1:
Lloh6:
	adrp	x8, _QLCNIC_CMD_STOP_NIC_FUNC@GOTPAGE
Lloh7:
	ldr	x8, [x8, _QLCNIC_CMD_STOP_NIC_FUNC@GOTPAGEOFF]
Lloh8:
	ldr	w2, [x8]
	add	x0, sp, #8
	mov	x1, x19
	bl	_qlcnic_alloc_mbx_args
Lloh9:
	adrp	x8, _BIT_31@GOTPAGE
Lloh10:
	ldr	x8, [x8, _BIT_31@GOTPAGEOFF]
Lloh11:
	ldr	w8, [x8]
	ldr	x9, [sp, #8]
	str	w8, [x9, #4]
	add	x1, sp, #8
	mov	x0, x19
	bl	_qlcnic_issue_cmd
	cbz	w0, LBB0_3
; %bb.2:
	ldr	x0, [x19]
Lloh12:
	adrp	x1, l_.str@PAGE
Lloh13:
	add	x1, x1, l_.str@PAGEOFF
	bl	_dev_err
LBB0_3:
	add	x0, sp, #8
	bl	_qlcnic_free_mbx_args
LBB0_4:
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #48
	ret
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpAdd	Lloh12, Lloh13
	.cfi_endproc
                                        ; -- End function
	.comm	_QLC_83XX_IDC_DRV_PRESENCE,4,2  ; @QLC_83XX_IDC_DRV_PRESENCE
	.comm	_QLC_83XX_IDC_DRV_AUDIT,4,2     ; @QLC_83XX_IDC_DRV_AUDIT
	.comm	_QLCNIC_CMD_STOP_NIC_FUNC,4,2   ; @QLCNIC_CMD_STOP_NIC_FUNC
	.comm	_BIT_31,4,2                     ; @BIT_31
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Failed to clean up the function resources\n"

	.no_dead_strip	_qlcnic_83xx_clear_function_resources
.subsections_via_symbols
