	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function bnx2x_prev_unload_close_mac
_bnx2x_prev_unload_close_mac:           ## @bnx2x_prev_unload_close_mac
	.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
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %r14
	movq	%rdi, %r13
	callq	_BP_PORT
	movl	%eax, %r12d
	xorl	%r15d, %r15d
	movq	%r14, %rdi
	xorl	%esi, %esi
	movl	$40, %edx
	callq	_memset
	movq	_MISC_REG_RESET_REG_2@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r13, %rdi
	callq	_REG_RD
	movq	%rax, %rbx
	movq	%r13, %rdi
	callq	_CHIP_IS_E3
	testl	%eax, %eax
	je	LBB0_1
## %bb.12:
	movq	_MISC_REGISTERS_RESET_REG_2_XMAC@GOTPCREL(%rip), %rax
	testl	%ebx, (%rax)
	je	LBB0_17
## %bb.13:
	leaq	L_.str.2(%rip), %rdi
	callq	_BNX2X_DEV_INFO
	movq	%r13, %rdi
	callq	_BP_PORT
	testl	%eax, %eax
	movq	%rbx, -48(%rbp)                 ## 8-byte Spill
	jne	LBB0_14
## %bb.15:
	movq	_GRCBASE_XMAC0@GOTPCREL(%rip), %rax
	jmp	LBB0_16
LBB0_1:
	movq	_NIG_REG_BMAC0_REGS_OUT_EN@GOTPCREL(%rip), %rax
	movl	%r12d, %esi
	shll	$2, %esi
	addl	(%rax), %esi
	movq	%r13, %rdi
	callq	_REG_RD
	movq	_MISC_REGISTERS_RESET_REG_2_RST_BMAC0@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edx
	movl	%r12d, %ecx
	shll	%cl, %edx
	testl	%ebx, %edx
	je	LBB0_10
## %bb.2:
	testl	%eax, %eax
	je	LBB0_10
## %bb.3:
	leaq	L_.str(%rip), %rdi
	callq	_BNX2X_DEV_INFO
	movq	%r13, %rdi
	callq	_BP_PORT
	testl	%eax, %eax
	jne	LBB0_4
## %bb.5:
	movq	_NIG_REG_INGRESS_BMAC0_MEM@GOTPCREL(%rip), %rax
	jmp	LBB0_6
LBB0_14:
	movq	_GRCBASE_XMAC1@GOTPCREL(%rip), %rax
LBB0_16:
	movl	(%rax), %ebx
	movq	_XMAC_REG_PFC_CTRL_HI@GOTPCREL(%rip), %r15
	movl	(%r15), %esi
	addl	%ebx, %esi
	movq	%r13, %rdi
	callq	_REG_RD
	movq	%rax, %r12
	movl	(%r15), %esi
	addl	%ebx, %esi
	movl	%r12d, %edx
	andl	$-3, %edx
	movq	%r13, %rdi
	callq	_REG_WR
	movl	(%r15), %esi
	addl	%ebx, %esi
	orl	$2, %r12d
	movq	%r13, %rdi
	movl	%r12d, %edx
	callq	_REG_WR
	movq	_XMAC_REG_CTRL@GOTPCREL(%rip), %rax
	addl	(%rax), %ebx
	movl	%ebx, 20(%r14)
	movq	%r13, %rdi
	movl	%ebx, %esi
	callq	_REG_RD
	movq	%rax, 24(%r14)
	movl	20(%r14), %esi
	movq	%r13, %rdi
	xorl	%edx, %edx
	callq	_REG_WR
	movl	$1, %r15d
	movq	-48(%rbp), %rbx                 ## 8-byte Reload
LBB0_17:
	movq	%r13, %rdi
	xorl	%esi, %esi
	movl	%ebx, %edx
	movq	%r14, %rcx
	callq	_bnx2x_prev_unload_close_umac
	movq	%rbx, %rdx
	movl	%eax, %ebx
	orl	%r15d, %ebx
	movq	%r13, %rdi
	movl	$1, %esi
                                        ## kill: def $edx killed $edx killed $rdx
	movq	%r14, %rcx
	callq	_bnx2x_prev_unload_close_umac
	orl	%ebx, %eax
	jne	LBB0_11
## %bb.18:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_4:
	movq	_NIG_REG_INGRESS_BMAC1_MEM@GOTPCREL(%rip), %rax
LBB0_6:
	movl	(%rax), %ebx
	movq	%r13, %rdi
	callq	_CHIP_IS_E2
	testq	%rax, %rax
	jne	LBB0_7
## %bb.8:
	movq	_BIGMAC_REGISTER_BMAC_CONTROL@GOTPCREL(%rip), %rax
	jmp	LBB0_9
LBB0_7:
	movq	_BIGMAC2_REGISTER_BMAC_CONTROL@GOTPCREL(%rip), %rax
LBB0_9:
	movl	(%rax), %r12d
	leal	(%r12,%rbx), %r15d
	movq	%r13, %rdi
	movl	%r15d, %esi
	callq	_REG_RD
	movq	%rax, -48(%rbp)                 ## 8-byte Spill
	leal	(%r12,%rbx), %esi
	addl	$4, %esi
	movq	%r13, %rdi
	callq	_REG_RD
	movq	%rax, %r12
	movl	%r15d, (%r14)
	movq	8(%r14), %rax
	movq	-48(%rbp), %rcx                 ## 8-byte Reload
	movl	%ecx, (%rax)
	movl	%r12d, 4(%rax)
	movq	_BMAC_CONTROL_RX_ENABLE@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	notl	%edx
	andl	%ecx, %edx
	movl	(%r14), %esi
	movq	%r13, %rdi
	callq	_REG_WR
	movl	(%r14), %esi
	addl	$4, %esi
	movq	%r13, %rdi
	movl	%r12d, %edx
	callq	_REG_WR
LBB0_10:
	leaq	L_.str.1(%rip), %rdi
	callq	_BNX2X_DEV_INFO
	movq	_NIG_REG_NIG_EMAC0_EN@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	movq	%r13, %rdi
	callq	_BP_PORT
                                        ## kill: def $eax killed $eax def $rax
	leal	(%rbx,%rax,4), %esi
	movl	%esi, 16(%r14)
	movq	%r13, %rdi
	callq	_REG_RD
	movq	%rax, 32(%r14)
	movl	16(%r14), %esi
	movq	%r13, %rdi
	xorl	%edx, %edx
	callq	_REG_WR
LBB0_11:
	movl	$20, %edi
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_msleep                         ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_MISC_REG_RESET_REG_2,4,2       ## @MISC_REG_RESET_REG_2
	.comm	_NIG_REG_BMAC0_REGS_OUT_EN,4,2  ## @NIG_REG_BMAC0_REGS_OUT_EN
	.comm	_MISC_REGISTERS_RESET_REG_2_RST_BMAC0,4,2 ## @MISC_REGISTERS_RESET_REG_2_RST_BMAC0
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Disable bmac Rx\n"

	.comm	_NIG_REG_INGRESS_BMAC1_MEM,4,2  ## @NIG_REG_INGRESS_BMAC1_MEM
	.comm	_NIG_REG_INGRESS_BMAC0_MEM,4,2  ## @NIG_REG_INGRESS_BMAC0_MEM
	.comm	_BIGMAC2_REGISTER_BMAC_CONTROL,4,2 ## @BIGMAC2_REGISTER_BMAC_CONTROL
	.comm	_BIGMAC_REGISTER_BMAC_CONTROL,4,2 ## @BIGMAC_REGISTER_BMAC_CONTROL
	.comm	_BMAC_CONTROL_RX_ENABLE,4,2     ## @BMAC_CONTROL_RX_ENABLE
L_.str.1:                               ## @.str.1
	.asciz	"Disable emac Rx\n"

	.comm	_NIG_REG_NIG_EMAC0_EN,4,2       ## @NIG_REG_NIG_EMAC0_EN
	.comm	_MISC_REGISTERS_RESET_REG_2_XMAC,4,2 ## @MISC_REGISTERS_RESET_REG_2_XMAC
L_.str.2:                               ## @.str.2
	.asciz	"Disable xmac Rx\n"

	.comm	_GRCBASE_XMAC1,4,2              ## @GRCBASE_XMAC1
	.comm	_GRCBASE_XMAC0,4,2              ## @GRCBASE_XMAC0
	.comm	_XMAC_REG_PFC_CTRL_HI,4,2       ## @XMAC_REG_PFC_CTRL_HI
	.comm	_XMAC_REG_CTRL,4,2              ## @XMAC_REG_CTRL
	.no_dead_strip	_bnx2x_prev_unload_close_mac
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function bnx2x_prev_unload_close_mac
_bnx2x_prev_unload_close_mac:           ; @bnx2x_prev_unload_close_mac
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.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
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	mov	x19, x1
	mov	x20, x0
	bl	_BP_PORT
	mov	x22, x0
	mov	x0, x19
	mov	w1, #0
	mov	w2, #40
	bl	_memset
Lloh0:
	adrp	x8, _MISC_REG_RESET_REG_2@GOTPAGE
Lloh1:
	ldr	x8, [x8, _MISC_REG_RESET_REG_2@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	mov	x0, x20
	bl	_REG_RD
	mov	x21, x0
	mov	x0, x20
	bl	_CHIP_IS_E3
	cbz	w0, LBB0_3
; %bb.1:
Lloh3:
	adrp	x8, _MISC_REGISTERS_RESET_REG_2_XMAC@GOTPAGE
Lloh4:
	ldr	x8, [x8, _MISC_REGISTERS_RESET_REG_2_XMAC@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	tst	w8, w21
	b.eq	LBB0_6
; %bb.2:
Lloh6:
	adrp	x0, l_.str.2@PAGE
Lloh7:
	add	x0, x0, l_.str.2@PAGEOFF
	bl	_BNX2X_DEV_INFO
	mov	x0, x20
	bl	_BP_PORT
Lloh8:
	adrp	x8, _GRCBASE_XMAC1@GOTPAGE
Lloh9:
	ldr	x8, [x8, _GRCBASE_XMAC1@GOTPAGEOFF]
Lloh10:
	adrp	x9, _GRCBASE_XMAC0@GOTPAGE
Lloh11:
	ldr	x9, [x9, _GRCBASE_XMAC0@GOTPAGEOFF]
	cmp	w0, #0
	csel	x8, x9, x8, eq
	ldr	w23, [x8]
Lloh12:
	adrp	x24, _XMAC_REG_PFC_CTRL_HI@GOTPAGE
Lloh13:
	ldr	x24, [x24, _XMAC_REG_PFC_CTRL_HI@GOTPAGEOFF]
	ldr	w8, [x24]
	add	w1, w23, w8
	mov	x0, x20
	bl	_REG_RD
	mov	x22, x0
	ldr	w8, [x24]
	add	w1, w8, w23
	and	w2, w22, #0xfffffffd
	mov	x0, x20
	bl	_REG_WR
	ldr	w8, [x24]
	add	w1, w8, w23
	orr	w2, w22, #0x2
	mov	x0, x20
	bl	_REG_WR
Lloh14:
	adrp	x8, _XMAC_REG_CTRL@GOTPAGE
Lloh15:
	ldr	x8, [x8, _XMAC_REG_CTRL@GOTPAGEOFF]
Lloh16:
	ldr	w8, [x8]
	add	w1, w8, w23
	str	w1, [x19, #20]
	mov	x0, x20
	bl	_REG_RD
	str	x0, [x19, #24]
	ldr	w1, [x19, #20]
	mov	x0, x20
	mov	w2, #0
	bl	_REG_WR
	mov	w22, #1
	b	LBB0_7
LBB0_3:
Lloh17:
	adrp	x8, _NIG_REG_BMAC0_REGS_OUT_EN@GOTPAGE
Lloh18:
	ldr	x8, [x8, _NIG_REG_BMAC0_REGS_OUT_EN@GOTPAGEOFF]
Lloh19:
	ldr	w8, [x8]
	add	w1, w8, w22, lsl #2
	mov	x0, x20
	bl	_REG_RD
Lloh20:
	adrp	x8, _MISC_REGISTERS_RESET_REG_2_RST_BMAC0@GOTPAGE
Lloh21:
	ldr	x8, [x8, _MISC_REGISTERS_RESET_REG_2_RST_BMAC0@GOTPAGEOFF]
Lloh22:
	ldr	w8, [x8]
	lsl	w8, w8, w22
	and	w8, w8, w21
	cmp	w8, #0
	ccmp	w0, #0, #4, ne
	b.eq	LBB0_5
; %bb.4:
Lloh23:
	adrp	x0, l_.str@PAGE
Lloh24:
	add	x0, x0, l_.str@PAGEOFF
	bl	_BNX2X_DEV_INFO
	mov	x0, x20
	bl	_BP_PORT
Lloh25:
	adrp	x8, _NIG_REG_INGRESS_BMAC1_MEM@GOTPAGE
Lloh26:
	ldr	x8, [x8, _NIG_REG_INGRESS_BMAC1_MEM@GOTPAGEOFF]
Lloh27:
	adrp	x9, _NIG_REG_INGRESS_BMAC0_MEM@GOTPAGE
Lloh28:
	ldr	x9, [x9, _NIG_REG_INGRESS_BMAC0_MEM@GOTPAGEOFF]
	cmp	w0, #0
	csel	x8, x9, x8, eq
	ldr	w21, [x8]
	mov	x0, x20
	bl	_CHIP_IS_E2
Lloh29:
	adrp	x8, _BIGMAC2_REGISTER_BMAC_CONTROL@GOTPAGE
Lloh30:
	ldr	x8, [x8, _BIGMAC2_REGISTER_BMAC_CONTROL@GOTPAGEOFF]
Lloh31:
	adrp	x9, _BIGMAC_REGISTER_BMAC_CONTROL@GOTPAGE
Lloh32:
	ldr	x9, [x9, _BIGMAC_REGISTER_BMAC_CONTROL@GOTPAGEOFF]
	cmp	x0, #0
	csel	x8, x9, x8, eq
	ldr	w8, [x8]
	add	w21, w8, w21
	mov	x0, x20
	mov	x1, x21
	bl	_REG_RD
	mov	x22, x0
	add	w1, w21, #4
	mov	x0, x20
	bl	_REG_RD
	mov	x23, x0
	str	w21, [x19]
	ldr	x8, [x19, #8]
	stp	w22, w23, [x8]
Lloh33:
	adrp	x8, _BMAC_CONTROL_RX_ENABLE@GOTPAGE
Lloh34:
	ldr	x8, [x8, _BMAC_CONTROL_RX_ENABLE@GOTPAGEOFF]
Lloh35:
	ldr	w8, [x8]
	bic	w2, w22, w8
	ldr	w1, [x19]
	mov	x0, x20
	bl	_REG_WR
	ldr	w8, [x19]
	add	w1, w8, #4
	mov	x0, x20
	mov	x2, x23
	bl	_REG_WR
LBB0_5:
Lloh36:
	adrp	x0, l_.str.1@PAGE
Lloh37:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	_BNX2X_DEV_INFO
Lloh38:
	adrp	x8, _NIG_REG_NIG_EMAC0_EN@GOTPAGE
Lloh39:
	ldr	x8, [x8, _NIG_REG_NIG_EMAC0_EN@GOTPAGEOFF]
Lloh40:
	ldr	w21, [x8]
	mov	x0, x20
	bl	_BP_PORT
	add	w1, w21, w0, lsl #2
	str	w1, [x19, #16]
	mov	x0, x20
	bl	_REG_RD
	str	x0, [x19, #32]
	ldr	w1, [x19, #16]
	mov	x0, x20
	mov	w2, #0
	bl	_REG_WR
	b	LBB0_8
LBB0_6:
	mov	w22, #0
LBB0_7:
	mov	x0, x20
	mov	w1, #0
	mov	x2, x21
	mov	x3, x19
	bl	_bnx2x_prev_unload_close_umac
	orr	w22, w0, w22
	mov	x0, x20
	mov	w1, #1
	mov	x2, x21
	mov	x3, x19
	bl	_bnx2x_prev_unload_close_umac
	orr	w8, w22, w0
	cbz	w8, LBB0_9
LBB0_8:
	mov	w0, #20
	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
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	b	_msleep
LBB0_9:
	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
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpLdrGot	Lloh12, Lloh13
	.loh AdrpLdrGot	Lloh10, Lloh11
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpAdd	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh33, Lloh34, Lloh35
	.loh AdrpLdrGot	Lloh31, Lloh32
	.loh AdrpLdrGot	Lloh29, Lloh30
	.loh AdrpLdrGot	Lloh27, Lloh28
	.loh AdrpLdrGot	Lloh25, Lloh26
	.loh AdrpAdd	Lloh23, Lloh24
	.loh AdrpLdrGotLdr	Lloh38, Lloh39, Lloh40
	.loh AdrpAdd	Lloh36, Lloh37
	.cfi_endproc
                                        ; -- End function
	.comm	_MISC_REG_RESET_REG_2,4,2       ; @MISC_REG_RESET_REG_2
	.comm	_NIG_REG_BMAC0_REGS_OUT_EN,4,2  ; @NIG_REG_BMAC0_REGS_OUT_EN
	.comm	_MISC_REGISTERS_RESET_REG_2_RST_BMAC0,4,2 ; @MISC_REGISTERS_RESET_REG_2_RST_BMAC0
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Disable bmac Rx\n"

	.comm	_NIG_REG_INGRESS_BMAC1_MEM,4,2  ; @NIG_REG_INGRESS_BMAC1_MEM
	.comm	_NIG_REG_INGRESS_BMAC0_MEM,4,2  ; @NIG_REG_INGRESS_BMAC0_MEM
	.comm	_BIGMAC2_REGISTER_BMAC_CONTROL,4,2 ; @BIGMAC2_REGISTER_BMAC_CONTROL
	.comm	_BIGMAC_REGISTER_BMAC_CONTROL,4,2 ; @BIGMAC_REGISTER_BMAC_CONTROL
	.comm	_BMAC_CONTROL_RX_ENABLE,4,2     ; @BMAC_CONTROL_RX_ENABLE
l_.str.1:                               ; @.str.1
	.asciz	"Disable emac Rx\n"

	.comm	_NIG_REG_NIG_EMAC0_EN,4,2       ; @NIG_REG_NIG_EMAC0_EN
	.comm	_MISC_REGISTERS_RESET_REG_2_XMAC,4,2 ; @MISC_REGISTERS_RESET_REG_2_XMAC
l_.str.2:                               ; @.str.2
	.asciz	"Disable xmac Rx\n"

	.comm	_GRCBASE_XMAC1,4,2              ; @GRCBASE_XMAC1
	.comm	_GRCBASE_XMAC0,4,2              ; @GRCBASE_XMAC0
	.comm	_XMAC_REG_PFC_CTRL_HI,4,2       ; @XMAC_REG_PFC_CTRL_HI
	.comm	_XMAC_REG_CTRL,4,2              ; @XMAC_REG_CTRL
	.no_dead_strip	_bnx2x_prev_unload_close_mac
.subsections_via_symbols
