	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function bnx2x_leader_reset
_bnx2x_leader_reset:                    ## @bnx2x_leader_reset
	.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
	movq	%rdi, %rbx
	callq	_bnx2x_reset_is_global
	movl	%eax, %r15d
	testl	%eax, %eax
	jne	LBB0_10
## %bb.1:
	movq	%rbx, %rdi
	callq	_BP_NOMCP
	testl	%eax, %eax
	je	LBB0_2
LBB0_10:
	movq	%rbx, %rdi
	movl	%r15d, %esi
	callq	_bnx2x_process_kill
	movq	%rbx, %rdi
	testq	%rax, %rax
	je	LBB0_11
## %bb.14:
	callq	_BP_PATH
	leaq	L_.str.2(%rip), %rdi
	xorl	%r14d, %r14d
	movl	%eax, %esi
	xorl	%eax, %eax
	callq	_BNX2X_ERR
	movq	_EAGAIN@GOTPCREL(%rip), %rax
	subl	(%rax), %r14d
	testl	%r15d, %r15d
	jne	LBB0_17
	jmp	LBB0_15
LBB0_11:
	callq	_bnx2x_set_reset_done
	testl	%r15d, %r15d
	je	LBB0_12
## %bb.13:
	movq	%rbx, %rdi
	callq	_bnx2x_clear_reset_global
	xorl	%r14d, %r14d
	jmp	LBB0_17
LBB0_2:
	movq	_DRV_MSG_CODE_LOAD_REQ@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_DRV_MSG_CODE_LOAD_REQ_WITH_LFA@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%rbx, %rdi
	callq	_bnx2x_fw_command
	testq	%rax, %rax
	je	LBB0_3
## %bb.4:
	movq	_FW_MSG_CODE_DRV_LOAD_COMMON_CHIP@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	je	LBB0_8
## %bb.5:
	movq	_FW_MSG_CODE_DRV_LOAD_COMMON@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	je	LBB0_8
## %bb.6:
	leaq	L_.str.1(%rip), %rdi
	jmp	LBB0_7
LBB0_12:
	xorl	%r14d, %r14d
	jmp	LBB0_15
LBB0_3:
	leaq	L_.str(%rip), %rdi
	xorl	%r14d, %r14d
	xorl	%eax, %eax
	callq	_BNX2X_ERR
	movq	_EAGAIN@GOTPCREL(%rip), %rax
	subl	(%rax), %r14d
	jmp	LBB0_17
LBB0_8:
	movq	_DRV_MSG_CODE_LOAD_DONE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdi
	xorl	%edx, %edx
	callq	_bnx2x_fw_command
	testq	%rax, %rax
	jne	LBB0_10
## %bb.9:
	leaq	L_.str(%rip), %rdi
LBB0_7:
	xorl	%r14d, %r14d
	xorl	%eax, %eax
	callq	_BNX2X_ERR
	movq	_EAGAIN@GOTPCREL(%rip), %rax
	subl	(%rax), %r14d
LBB0_15:
	movq	%rbx, %rdi
	callq	_BP_NOMCP
	testl	%eax, %eax
	jne	LBB0_17
## %bb.16:
	movq	_DRV_MSG_CODE_UNLOAD_REQ_WOL_MCP@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdi
	xorl	%edx, %edx
	callq	_bnx2x_fw_command
	movq	_DRV_MSG_CODE_UNLOAD_DONE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdi
	xorl	%edx, %edx
	callq	_bnx2x_fw_command
LBB0_17:
	movq	$0, (%rbx)
	movq	%rbx, %rdi
	callq	_bnx2x_release_leader_lock
	xorl	%eax, %eax
	callq	_smp_mb
	movl	%r14d, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_DRV_MSG_CODE_LOAD_REQ,4,2      ## @DRV_MSG_CODE_LOAD_REQ
	.comm	_DRV_MSG_CODE_LOAD_REQ_WITH_LFA,4,2 ## @DRV_MSG_CODE_LOAD_REQ_WITH_LFA
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"MCP response failure, aborting\n"

	.comm	_EAGAIN,4,2                     ## @EAGAIN
	.comm	_FW_MSG_CODE_DRV_LOAD_COMMON_CHIP,8,3 ## @FW_MSG_CODE_DRV_LOAD_COMMON_CHIP
	.comm	_FW_MSG_CODE_DRV_LOAD_COMMON,8,3 ## @FW_MSG_CODE_DRV_LOAD_COMMON
L_.str.1:                               ## @.str.1
	.asciz	"MCP unexpected resp, aborting\n"

	.comm	_DRV_MSG_CODE_LOAD_DONE,4,2     ## @DRV_MSG_CODE_LOAD_DONE
L_.str.2:                               ## @.str.2
	.asciz	"Something bad had happen on engine %d! Aii!\n"

	.comm	_DRV_MSG_CODE_UNLOAD_REQ_WOL_MCP,4,2 ## @DRV_MSG_CODE_UNLOAD_REQ_WOL_MCP
	.comm	_DRV_MSG_CODE_UNLOAD_DONE,4,2   ## @DRV_MSG_CODE_UNLOAD_DONE
	.no_dead_strip	_bnx2x_leader_reset
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function bnx2x_leader_reset
_bnx2x_leader_reset:                    ; @bnx2x_leader_reset
	.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	x19, x0
	bl	_bnx2x_reset_is_global
	mov	x20, x0
	cbnz	w0, LBB0_2
; %bb.1:
	mov	x0, x19
	bl	_BP_NOMCP
	cbz	w0, LBB0_6
LBB0_2:
	mov	x0, x19
	mov	x1, x20
	bl	_bnx2x_process_kill
	cbz	x0, LBB0_4
; %bb.3:
	mov	x0, x19
	bl	_BP_PATH
                                        ; kill: def $w0 killed $w0 def $x0
	str	x0, [sp]
Lloh0:
	adrp	x0, l_.str.2@PAGE
Lloh1:
	add	x0, x0, l_.str.2@PAGEOFF
	bl	_BNX2X_ERR
Lloh2:
	adrp	x8, _EAGAIN@GOTPAGE
Lloh3:
	ldr	x8, [x8, _EAGAIN@GOTPAGEOFF]
Lloh4:
	ldr	w8, [x8]
	neg	w21, w8
	cbnz	w20, LBB0_16
	b	LBB0_14
LBB0_4:
	mov	x0, x19
	bl	_bnx2x_set_reset_done
	cbz	w20, LBB0_10
; %bb.5:
	mov	x0, x19
	bl	_bnx2x_clear_reset_global
	mov	w21, #0
	b	LBB0_16
LBB0_6:
Lloh5:
	adrp	x8, _DRV_MSG_CODE_LOAD_REQ@GOTPAGE
Lloh6:
	ldr	x8, [x8, _DRV_MSG_CODE_LOAD_REQ@GOTPAGEOFF]
Lloh7:
	ldr	w1, [x8]
Lloh8:
	adrp	x8, _DRV_MSG_CODE_LOAD_REQ_WITH_LFA@GOTPAGE
Lloh9:
	ldr	x8, [x8, _DRV_MSG_CODE_LOAD_REQ_WITH_LFA@GOTPAGEOFF]
Lloh10:
	ldr	w2, [x8]
	mov	x0, x19
	bl	_bnx2x_fw_command
	cbz	x0, LBB0_11
; %bb.7:
Lloh11:
	adrp	x8, _FW_MSG_CODE_DRV_LOAD_COMMON_CHIP@GOTPAGE
Lloh12:
	ldr	x8, [x8, _FW_MSG_CODE_DRV_LOAD_COMMON_CHIP@GOTPAGEOFF]
Lloh13:
	ldr	x8, [x8]
Lloh14:
	adrp	x9, _FW_MSG_CODE_DRV_LOAD_COMMON@GOTPAGE
Lloh15:
	ldr	x9, [x9, _FW_MSG_CODE_DRV_LOAD_COMMON@GOTPAGEOFF]
Lloh16:
	ldr	x9, [x9]
	cmp	x0, x8
	ccmp	x0, x9, #4, ne
	b.ne	LBB0_12
; %bb.8:
Lloh17:
	adrp	x8, _DRV_MSG_CODE_LOAD_DONE@GOTPAGE
Lloh18:
	ldr	x8, [x8, _DRV_MSG_CODE_LOAD_DONE@GOTPAGEOFF]
Lloh19:
	ldr	w1, [x8]
	mov	x0, x19
	mov	w2, #0
	bl	_bnx2x_fw_command
	cbnz	x0, LBB0_2
; %bb.9:
Lloh20:
	adrp	x0, l_.str@PAGE
Lloh21:
	add	x0, x0, l_.str@PAGEOFF
	b	LBB0_13
LBB0_10:
	mov	w21, #0
	b	LBB0_14
LBB0_11:
Lloh22:
	adrp	x0, l_.str@PAGE
Lloh23:
	add	x0, x0, l_.str@PAGEOFF
	bl	_BNX2X_ERR
Lloh24:
	adrp	x8, _EAGAIN@GOTPAGE
Lloh25:
	ldr	x8, [x8, _EAGAIN@GOTPAGEOFF]
Lloh26:
	ldr	w8, [x8]
	neg	w21, w8
	b	LBB0_16
LBB0_12:
Lloh27:
	adrp	x0, l_.str.1@PAGE
Lloh28:
	add	x0, x0, l_.str.1@PAGEOFF
LBB0_13:
	bl	_BNX2X_ERR
Lloh29:
	adrp	x8, _EAGAIN@GOTPAGE
Lloh30:
	ldr	x8, [x8, _EAGAIN@GOTPAGEOFF]
Lloh31:
	ldr	w8, [x8]
	neg	w21, w8
LBB0_14:
	mov	x0, x19
	bl	_BP_NOMCP
	cbnz	w0, LBB0_16
; %bb.15:
Lloh32:
	adrp	x8, _DRV_MSG_CODE_UNLOAD_REQ_WOL_MCP@GOTPAGE
Lloh33:
	ldr	x8, [x8, _DRV_MSG_CODE_UNLOAD_REQ_WOL_MCP@GOTPAGEOFF]
Lloh34:
	ldr	w1, [x8]
	mov	x0, x19
	mov	w2, #0
	bl	_bnx2x_fw_command
Lloh35:
	adrp	x8, _DRV_MSG_CODE_UNLOAD_DONE@GOTPAGE
Lloh36:
	ldr	x8, [x8, _DRV_MSG_CODE_UNLOAD_DONE@GOTPAGEOFF]
Lloh37:
	ldr	w1, [x8]
	mov	x0, x19
	mov	w2, #0
	bl	_bnx2x_fw_command
LBB0_16:
	str	xzr, [x19]
	mov	x0, x19
	bl	_bnx2x_release_leader_lock
	bl	_smp_mb
	mov	x0, x21
	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 AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpAdd	Lloh20, Lloh21
	.loh AdrpLdrGotLdr	Lloh24, Lloh25, Lloh26
	.loh AdrpAdd	Lloh22, Lloh23
	.loh AdrpAdd	Lloh27, Lloh28
	.loh AdrpLdrGotLdr	Lloh29, Lloh30, Lloh31
	.loh AdrpLdrGotLdr	Lloh35, Lloh36, Lloh37
	.loh AdrpLdrGotLdr	Lloh32, Lloh33, Lloh34
	.cfi_endproc
                                        ; -- End function
	.comm	_DRV_MSG_CODE_LOAD_REQ,4,2      ; @DRV_MSG_CODE_LOAD_REQ
	.comm	_DRV_MSG_CODE_LOAD_REQ_WITH_LFA,4,2 ; @DRV_MSG_CODE_LOAD_REQ_WITH_LFA
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"MCP response failure, aborting\n"

	.comm	_EAGAIN,4,2                     ; @EAGAIN
	.comm	_FW_MSG_CODE_DRV_LOAD_COMMON_CHIP,8,3 ; @FW_MSG_CODE_DRV_LOAD_COMMON_CHIP
	.comm	_FW_MSG_CODE_DRV_LOAD_COMMON,8,3 ; @FW_MSG_CODE_DRV_LOAD_COMMON
l_.str.1:                               ; @.str.1
	.asciz	"MCP unexpected resp, aborting\n"

	.comm	_DRV_MSG_CODE_LOAD_DONE,4,2     ; @DRV_MSG_CODE_LOAD_DONE
l_.str.2:                               ; @.str.2
	.asciz	"Something bad had happen on engine %d! Aii!\n"

	.comm	_DRV_MSG_CODE_UNLOAD_REQ_WOL_MCP,4,2 ; @DRV_MSG_CODE_UNLOAD_REQ_WOL_MCP
	.comm	_DRV_MSG_CODE_UNLOAD_DONE,4,2   ; @DRV_MSG_CODE_UNLOAD_DONE
	.no_dead_strip	_bnx2x_leader_reset
.subsections_via_symbols
