	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_qlcnic_clr_all_drv_state       ## -- Begin function qlcnic_clr_all_drv_state
	.p2align	4, 0x90
_qlcnic_clr_all_drv_state:              ## @qlcnic_clr_all_drv_state
	.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	%r12
	pushq	%rbx
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %r14
	movq	%rdi, %rbx
	callq	_qlcnic_api_lock
	testq	%rax, %rax
	jne	LBB0_6
## %bb.1:
	movq	_QLCNIC_CRB_DRV_ACTIVE@GOTPCREL(%rip), %r12
	movl	(%r12), %esi
	movq	%rbx, %rdi
	callq	_QLC_SHARED_REG_RD32
	movl	%eax, %r15d
	movl	16(%rbx), %esi
	movl	%eax, %edi
	callq	_QLC_DEV_CLR_REF_CNT
	movl	(%r12), %esi
	movq	%rbx, %rdi
	movl	%r15d, %edx
	callq	_QLC_SHARED_REG_WR32
	testq	%r14, %r14
	je	LBB0_3
## %bb.2:
	movq	_QLCNIC_CRB_DEV_STATE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_QLCNIC_DEV_FAILED@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%rbx, %rdi
	callq	_QLC_SHARED_REG_WR32
	movq	24(%rbx), %rdi
	leaq	L_.str(%rip), %rsi
	callq	_dev_info
	jmp	LBB0_5
LBB0_3:
	testl	$286331153, %r15d               ## imm = 0x11111111
	jne	LBB0_5
## %bb.4:
	movq	_QLCNIC_CRB_DEV_STATE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_QLCNIC_DEV_COLD@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%rbx, %rdi
	callq	_QLC_SHARED_REG_WR32
LBB0_5:
	movq	_QLCNIC_CRB_DRV_STATE@GOTPCREL(%rip), %r15
	movl	(%r15), %esi
	movq	%rbx, %rdi
	callq	_QLC_SHARED_REG_RD32
	movl	%eax, %r14d
	movl	16(%rbx), %esi
	movl	%eax, %edi
	callq	_QLC_DEV_CLR_RST_QSCNT
	movl	(%r15), %esi
	movq	%rbx, %rdi
	movl	%r14d, %edx
	callq	_QLC_SHARED_REG_WR32
	movq	%rbx, %rdi
	callq	_qlcnic_api_unlock
LBB0_6:
	movq	$0, 8(%rbx)
	movq	_QLCNIC_FW_HANG@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	notl	%eax
	andl	%eax, 4(%rbx)
	movq	___QLCNIC_START_FW@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	%rbx, %rsi
	callq	_clear_bit
	movq	___QLCNIC_RESETTING@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	%rbx, %rsi
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_clear_bit                      ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_QLCNIC_CRB_DRV_ACTIVE,4,2      ## @QLCNIC_CRB_DRV_ACTIVE
	.comm	_QLCNIC_CRB_DEV_STATE,4,2       ## @QLCNIC_CRB_DEV_STATE
	.comm	_QLCNIC_DEV_FAILED,4,2          ## @QLCNIC_DEV_FAILED
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Device state set to Failed. Please Reboot\n"

	.comm	_QLCNIC_DEV_COLD,4,2            ## @QLCNIC_DEV_COLD
	.comm	_QLCNIC_CRB_DRV_STATE,4,2       ## @QLCNIC_CRB_DRV_STATE
	.comm	_QLCNIC_FW_HANG,4,2             ## @QLCNIC_FW_HANG
	.comm	___QLCNIC_START_FW,4,2          ## @__QLCNIC_START_FW
	.comm	___QLCNIC_RESETTING,4,2         ## @__QLCNIC_RESETTING
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_qlcnic_clr_all_drv_state       ; -- Begin function qlcnic_clr_all_drv_state
	.p2align	2
_qlcnic_clr_all_drv_state:              ; @qlcnic_clr_all_drv_state
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.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
	.cfi_offset w21, -40
	.cfi_offset w22, -48
	mov	x20, x1
	mov	x19, x0
	bl	_qlcnic_api_lock
	cbnz	x0, LBB0_6
; %bb.1:
Lloh0:
	adrp	x22, _QLCNIC_CRB_DRV_ACTIVE@GOTPAGE
Lloh1:
	ldr	x22, [x22, _QLCNIC_CRB_DRV_ACTIVE@GOTPAGEOFF]
	ldr	w1, [x22]
	mov	x0, x19
	bl	_QLC_SHARED_REG_RD32
	mov	x21, x0
	ldr	w1, [x19, #16]
	bl	_QLC_DEV_CLR_REF_CNT
	ldr	w1, [x22]
	mov	x0, x19
	mov	x2, x21
	bl	_QLC_SHARED_REG_WR32
	cbz	x20, LBB0_3
; %bb.2:
Lloh2:
	adrp	x8, _QLCNIC_CRB_DEV_STATE@GOTPAGE
Lloh3:
	ldr	x8, [x8, _QLCNIC_CRB_DEV_STATE@GOTPAGEOFF]
Lloh4:
	ldr	w1, [x8]
Lloh5:
	adrp	x8, _QLCNIC_DEV_FAILED@GOTPAGE
Lloh6:
	ldr	x8, [x8, _QLCNIC_DEV_FAILED@GOTPAGEOFF]
Lloh7:
	ldr	w2, [x8]
	mov	x0, x19
	bl	_QLC_SHARED_REG_WR32
	ldr	x0, [x19, #24]
Lloh8:
	adrp	x1, l_.str@PAGE
Lloh9:
	add	x1, x1, l_.str@PAGEOFF
	bl	_dev_info
	b	LBB0_5
LBB0_3:
	tst	w21, #0x11111111
	b.ne	LBB0_5
; %bb.4:
Lloh10:
	adrp	x8, _QLCNIC_CRB_DEV_STATE@GOTPAGE
Lloh11:
	ldr	x8, [x8, _QLCNIC_CRB_DEV_STATE@GOTPAGEOFF]
Lloh12:
	ldr	w1, [x8]
Lloh13:
	adrp	x8, _QLCNIC_DEV_COLD@GOTPAGE
Lloh14:
	ldr	x8, [x8, _QLCNIC_DEV_COLD@GOTPAGEOFF]
Lloh15:
	ldr	w2, [x8]
	mov	x0, x19
	bl	_QLC_SHARED_REG_WR32
LBB0_5:
Lloh16:
	adrp	x21, _QLCNIC_CRB_DRV_STATE@GOTPAGE
Lloh17:
	ldr	x21, [x21, _QLCNIC_CRB_DRV_STATE@GOTPAGEOFF]
	ldr	w1, [x21]
	mov	x0, x19
	bl	_QLC_SHARED_REG_RD32
	mov	x20, x0
	ldr	w1, [x19, #16]
	bl	_QLC_DEV_CLR_RST_QSCNT
	ldr	w1, [x21]
	mov	x0, x19
	mov	x2, x20
	bl	_QLC_SHARED_REG_WR32
	mov	x0, x19
	bl	_qlcnic_api_unlock
LBB0_6:
	str	xzr, [x19, #8]
Lloh18:
	adrp	x8, _QLCNIC_FW_HANG@GOTPAGE
Lloh19:
	ldr	x8, [x8, _QLCNIC_FW_HANG@GOTPAGEOFF]
Lloh20:
	ldr	w8, [x8]
	ldr	w9, [x19, #4]
	bic	w8, w9, w8
	str	w8, [x19, #4]
Lloh21:
	adrp	x8, ___QLCNIC_START_FW@GOTPAGE
Lloh22:
	ldr	x8, [x8, ___QLCNIC_START_FW@GOTPAGEOFF]
Lloh23:
	ldr	w0, [x8]
	mov	x1, x19
	bl	_clear_bit
Lloh24:
	adrp	x8, ___QLCNIC_RESETTING@GOTPAGE
Lloh25:
	ldr	x8, [x8, ___QLCNIC_RESETTING@GOTPAGEOFF]
Lloh26:
	ldr	w0, [x8]
	mov	x1, x19
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	b	_clear_bit
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpAdd	Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpLdrGot	Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh24, Lloh25, Lloh26
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.cfi_endproc
                                        ; -- End function
	.comm	_QLCNIC_CRB_DRV_ACTIVE,4,2      ; @QLCNIC_CRB_DRV_ACTIVE
	.comm	_QLCNIC_CRB_DEV_STATE,4,2       ; @QLCNIC_CRB_DEV_STATE
	.comm	_QLCNIC_DEV_FAILED,4,2          ; @QLCNIC_DEV_FAILED
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Device state set to Failed. Please Reboot\n"

	.comm	_QLCNIC_DEV_COLD,4,2            ; @QLCNIC_DEV_COLD
	.comm	_QLCNIC_CRB_DRV_STATE,4,2       ; @QLCNIC_CRB_DRV_STATE
	.comm	_QLCNIC_FW_HANG,4,2             ; @QLCNIC_FW_HANG
	.comm	___QLCNIC_START_FW,4,2          ; @__QLCNIC_START_FW
	.comm	___QLCNIC_RESETTING,4,2         ; @__QLCNIC_RESETTING
.subsections_via_symbols
