	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function niu_init_ipp
_niu_init_ipp:                          ## @niu_init_ipp
	.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
	subq	$72, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r14
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	movq	8(%rdi), %rax
	movq	(%rax), %rax
	movq	_PLAT_TYPE_NIU@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_2
## %bb.1:
	movq	_NIU_DFIFO_ENTRIES@GOTPCREL(%rip), %rax
	jmp	LBB0_5
LBB0_2:
	cmpl	$2, (%r14)
	jae	LBB0_3
## %bb.4:
	movq	_ATLAS_P0_P1_DFIFO_ENTRIES@GOTPCREL(%rip), %rax
	jmp	LBB0_5
LBB0_3:
	movq	_ATLAS_P2_P3_DFIFO_ENTRIES@GOTPCREL(%rip), %rax
LBB0_5:
	movl	(%rax), %r13d
	xorps	%xmm0, %xmm0
	movaps	%xmm0, -80(%rbp)
	movl	$0, -64(%rbp)
	testl	%r13d, %r13d
	jle	LBB0_8
## %bb.6:
	xorl	%ebx, %ebx
	leaq	-80(%rbp), %r15
	leaq	-112(%rbp), %r12
	.p2align	4, 0x90
LBB0_7:                                 ## =>This Inner Loop Header: Depth=1
	movq	%r14, %rdi
	movl	%ebx, %esi
	movq	%r15, %rdx
	callq	_niu_ipp_write
	movq	%r14, %rdi
	movl	%ebx, %esi
	movq	%r12, %rdx
	callq	_niu_ipp_read
	incl	%ebx
	cmpl	%ebx, %r13d
	jne	LBB0_7
LBB0_8:
	movq	_IPP_INT_STAT@GOTPCREL(%rip), %r15
	movl	(%r15), %edi
	callq	_nr64_ipp
	movl	(%r15), %edi
	callq	_nr64_ipp
	movq	%r14, %rdi
	callq	_niu_ipp_reset
	movl	%eax, %ebx
	testl	%eax, %eax
	jne	LBB0_10
## %bb.9:
	movq	_IPP_PKT_DIS@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_nr64_ipp
	movq	_IPP_BAD_CS_CNT@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_nr64_ipp
	movq	_IPP_ECC@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_nr64_ipp
	movl	(%r15), %edi
	callq	_nr64_ipp
	movq	_IPP_MSK@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	_IPP_MSK_ALL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	notl	%esi
	callq	_nw64_ipp
	movq	_IPP_CFIG@GOTPCREL(%rip), %r14
	movl	(%r14), %edi
	callq	_nr64_ipp
	movq	_IPP_CFIG_IP_MAX_PKT@GOTPCREL(%rip), %rcx
	movl	(%rcx), %esi
	notl	%esi
	andl	%eax, %esi
	movq	_IPP_CFIG_IPP_ENABLE@GOTPCREL(%rip), %rax
	movq	_IPP_CFIG_DFIFO_ECC_EN@GOTPCREL(%rip), %r8
	movq	_IPP_CFIG_IP_MAX_PKT_SHIFT@GOTPCREL(%rip), %rcx
	movb	(%rcx), %cl
	movl	$131071, %edi                   ## imm = 0x1FFFF
	shll	%cl, %edi
	movq	_IPP_CFIG_DROP_BAD_CRC@GOTPCREL(%rip), %rcx
	movq	_IPP_CFIG_CKSUM_EN@GOTPCREL(%rip), %rdx
	orl	(%rax), %esi
	orl	(%r8), %esi
	orl	(%rcx), %esi
	orl	(%rdx), %esi
	orl	%edi, %esi
	movl	(%r14), %edi
	callq	_nw64_ipp
LBB0_10:
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_12
## %bb.11:
	movl	%ebx, %eax
	addq	$72, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_12:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_PLAT_TYPE_NIU,8,3              ## @PLAT_TYPE_NIU
	.comm	_ATLAS_P0_P1_DFIFO_ENTRIES,4,2  ## @ATLAS_P0_P1_DFIFO_ENTRIES
	.comm	_ATLAS_P2_P3_DFIFO_ENTRIES,4,2  ## @ATLAS_P2_P3_DFIFO_ENTRIES
	.comm	_NIU_DFIFO_ENTRIES,4,2          ## @NIU_DFIFO_ENTRIES
	.comm	_IPP_INT_STAT,4,2               ## @IPP_INT_STAT
	.comm	_IPP_PKT_DIS,4,2                ## @IPP_PKT_DIS
	.comm	_IPP_BAD_CS_CNT,4,2             ## @IPP_BAD_CS_CNT
	.comm	_IPP_ECC,4,2                    ## @IPP_ECC
	.comm	_IPP_MSK,4,2                    ## @IPP_MSK
	.comm	_IPP_MSK_ALL,4,2                ## @IPP_MSK_ALL
	.comm	_IPP_CFIG,4,2                   ## @IPP_CFIG
	.comm	_IPP_CFIG_IP_MAX_PKT,4,2        ## @IPP_CFIG_IP_MAX_PKT
	.comm	_IPP_CFIG_IPP_ENABLE,4,2        ## @IPP_CFIG_IPP_ENABLE
	.comm	_IPP_CFIG_DFIFO_ECC_EN,4,2      ## @IPP_CFIG_DFIFO_ECC_EN
	.comm	_IPP_CFIG_DROP_BAD_CRC,4,2      ## @IPP_CFIG_DROP_BAD_CRC
	.comm	_IPP_CFIG_CKSUM_EN,4,2          ## @IPP_CFIG_CKSUM_EN
	.comm	_IPP_CFIG_IP_MAX_PKT_SHIFT,4,2  ## @IPP_CFIG_IP_MAX_PKT_SHIFT
	.no_dead_strip	_niu_init_ipp
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function niu_init_ipp
_niu_init_ipp:                          ; @niu_init_ipp
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	stp	x22, x21, [sp, #64]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #80]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #96]             ; 16-byte Folded Spill
	add	x29, sp, #96
	.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
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	stur	x8, [x29, #-40]
	ldr	x8, [x0, #8]
	ldr	x8, [x8]
Lloh3:
	adrp	x9, _PLAT_TYPE_NIU@GOTPAGE
Lloh4:
	ldr	x9, [x9, _PLAT_TYPE_NIU@GOTPAGEOFF]
Lloh5:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_2
; %bb.1:
Lloh6:
	adrp	x8, _NIU_DFIFO_ENTRIES@GOTPAGE
Lloh7:
	ldr	x8, [x8, _NIU_DFIFO_ENTRIES@GOTPAGEOFF]
	b	LBB0_3
LBB0_2:
	ldr	w8, [x19]
Lloh8:
	adrp	x9, _ATLAS_P2_P3_DFIFO_ENTRIES@GOTPAGE
Lloh9:
	ldr	x9, [x9, _ATLAS_P2_P3_DFIFO_ENTRIES@GOTPAGEOFF]
Lloh10:
	adrp	x10, _ATLAS_P0_P1_DFIFO_ENTRIES@GOTPAGE
Lloh11:
	ldr	x10, [x10, _ATLAS_P0_P1_DFIFO_ENTRIES@GOTPAGEOFF]
	cmp	w8, #2
	csel	x8, x10, x9, lo
LBB0_3:
	ldr	w21, [x8]
	stp	xzr, xzr, [sp, #32]
	str	wzr, [sp, #48]
	cmp	w21, #1
	b.lt	LBB0_6
; %bb.4:
	mov	w20, #0
LBB0_5:                                 ; =>This Inner Loop Header: Depth=1
	add	x2, sp, #32
	mov	x0, x19
	mov	x1, x20
	bl	_niu_ipp_write
	add	x2, sp, #12
	mov	x0, x19
	mov	x1, x20
	bl	_niu_ipp_read
	add	w20, w20, #1
	cmp	w21, w20
	b.ne	LBB0_5
LBB0_6:
Lloh12:
	adrp	x20, _IPP_INT_STAT@GOTPAGE
Lloh13:
	ldr	x20, [x20, _IPP_INT_STAT@GOTPAGEOFF]
	ldr	w0, [x20]
	bl	_nr64_ipp
	ldr	w0, [x20]
	bl	_nr64_ipp
	mov	x0, x19
	bl	_niu_ipp_reset
	mov	x19, x0
	cbnz	w0, LBB0_8
; %bb.7:
Lloh14:
	adrp	x8, _IPP_PKT_DIS@GOTPAGE
Lloh15:
	ldr	x8, [x8, _IPP_PKT_DIS@GOTPAGEOFF]
Lloh16:
	ldr	w0, [x8]
	bl	_nr64_ipp
Lloh17:
	adrp	x8, _IPP_BAD_CS_CNT@GOTPAGE
Lloh18:
	ldr	x8, [x8, _IPP_BAD_CS_CNT@GOTPAGEOFF]
Lloh19:
	ldr	w0, [x8]
	bl	_nr64_ipp
Lloh20:
	adrp	x8, _IPP_ECC@GOTPAGE
Lloh21:
	ldr	x8, [x8, _IPP_ECC@GOTPAGEOFF]
Lloh22:
	ldr	w0, [x8]
	bl	_nr64_ipp
	ldr	w0, [x20]
	bl	_nr64_ipp
Lloh23:
	adrp	x8, _IPP_MSK@GOTPAGE
Lloh24:
	ldr	x8, [x8, _IPP_MSK@GOTPAGEOFF]
Lloh25:
	ldr	w0, [x8]
Lloh26:
	adrp	x8, _IPP_MSK_ALL@GOTPAGE
Lloh27:
	ldr	x8, [x8, _IPP_MSK_ALL@GOTPAGEOFF]
Lloh28:
	ldr	w8, [x8]
	mvn	w1, w8
	bl	_nw64_ipp
Lloh29:
	adrp	x20, _IPP_CFIG@GOTPAGE
Lloh30:
	ldr	x20, [x20, _IPP_CFIG@GOTPAGEOFF]
	ldr	w0, [x20]
	bl	_nr64_ipp
Lloh31:
	adrp	x8, _IPP_CFIG_IP_MAX_PKT@GOTPAGE
Lloh32:
	ldr	x8, [x8, _IPP_CFIG_IP_MAX_PKT@GOTPAGEOFF]
Lloh33:
	ldr	w8, [x8]
	bic	w8, w0, w8
Lloh34:
	adrp	x9, _IPP_CFIG_IPP_ENABLE@GOTPAGE
Lloh35:
	ldr	x9, [x9, _IPP_CFIG_IPP_ENABLE@GOTPAGEOFF]
Lloh36:
	ldr	w9, [x9]
Lloh37:
	adrp	x10, _IPP_CFIG_DFIFO_ECC_EN@GOTPAGE
Lloh38:
	ldr	x10, [x10, _IPP_CFIG_DFIFO_ECC_EN@GOTPAGEOFF]
Lloh39:
	ldr	w10, [x10]
Lloh40:
	adrp	x11, _IPP_CFIG_DROP_BAD_CRC@GOTPAGE
Lloh41:
	ldr	x11, [x11, _IPP_CFIG_DROP_BAD_CRC@GOTPAGEOFF]
Lloh42:
	ldr	w11, [x11]
Lloh43:
	adrp	x12, _IPP_CFIG_CKSUM_EN@GOTPAGE
Lloh44:
	ldr	x12, [x12, _IPP_CFIG_CKSUM_EN@GOTPAGEOFF]
Lloh45:
	ldr	w12, [x12]
Lloh46:
	adrp	x13, _IPP_CFIG_IP_MAX_PKT_SHIFT@GOTPAGE
Lloh47:
	ldr	x13, [x13, _IPP_CFIG_IP_MAX_PKT_SHIFT@GOTPAGEOFF]
Lloh48:
	ldr	w13, [x13]
	mov	w14, #131071
	lsl	w13, w14, w13
	orr	w8, w8, w9
	orr	w8, w8, w10
	orr	w8, w8, w11
	orr	w8, w8, w12
	orr	w1, w8, w13
	ldr	w0, [x20]
	bl	_nw64_ipp
LBB0_8:
	ldur	x8, [x29, #-40]
Lloh49:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh50:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh51:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_10
; %bb.9:
	mov	x0, x19
	ldp	x29, x30, [sp, #96]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #80]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #64]             ; 16-byte Folded Reload
	add	sp, sp, #112
	ret
LBB0_10:
	bl	___stack_chk_fail
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh10, Lloh11
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh46, Lloh47, Lloh48
	.loh AdrpLdrGotLdr	Lloh43, Lloh44, Lloh45
	.loh AdrpLdrGotLdr	Lloh40, Lloh41, Lloh42
	.loh AdrpLdrGotLdr	Lloh37, Lloh38, Lloh39
	.loh AdrpLdrGotLdr	Lloh34, Lloh35, Lloh36
	.loh AdrpLdrGotLdr	Lloh31, Lloh32, Lloh33
	.loh AdrpLdrGot	Lloh29, Lloh30
	.loh AdrpLdrGotLdr	Lloh26, Lloh27, Lloh28
	.loh AdrpLdrGotLdr	Lloh23, Lloh24, Lloh25
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh49, Lloh50, Lloh51
	.cfi_endproc
                                        ; -- End function
	.comm	_PLAT_TYPE_NIU,8,3              ; @PLAT_TYPE_NIU
	.comm	_ATLAS_P0_P1_DFIFO_ENTRIES,4,2  ; @ATLAS_P0_P1_DFIFO_ENTRIES
	.comm	_ATLAS_P2_P3_DFIFO_ENTRIES,4,2  ; @ATLAS_P2_P3_DFIFO_ENTRIES
	.comm	_NIU_DFIFO_ENTRIES,4,2          ; @NIU_DFIFO_ENTRIES
	.comm	_IPP_INT_STAT,4,2               ; @IPP_INT_STAT
	.comm	_IPP_PKT_DIS,4,2                ; @IPP_PKT_DIS
	.comm	_IPP_BAD_CS_CNT,4,2             ; @IPP_BAD_CS_CNT
	.comm	_IPP_ECC,4,2                    ; @IPP_ECC
	.comm	_IPP_MSK,4,2                    ; @IPP_MSK
	.comm	_IPP_MSK_ALL,4,2                ; @IPP_MSK_ALL
	.comm	_IPP_CFIG,4,2                   ; @IPP_CFIG
	.comm	_IPP_CFIG_IP_MAX_PKT,4,2        ; @IPP_CFIG_IP_MAX_PKT
	.comm	_IPP_CFIG_IPP_ENABLE,4,2        ; @IPP_CFIG_IPP_ENABLE
	.comm	_IPP_CFIG_DFIFO_ECC_EN,4,2      ; @IPP_CFIG_DFIFO_ECC_EN
	.comm	_IPP_CFIG_DROP_BAD_CRC,4,2      ; @IPP_CFIG_DROP_BAD_CRC
	.comm	_IPP_CFIG_CKSUM_EN,4,2          ; @IPP_CFIG_CKSUM_EN
	.comm	_IPP_CFIG_IP_MAX_PKT_SHIFT,4,2  ; @IPP_CFIG_IP_MAX_PKT_SHIFT
	.no_dead_strip	_niu_init_ipp
.subsections_via_symbols
