	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function dpaa_ingress_cgr_init
_dpaa_ingress_cgr_init:                 ## @dpaa_ingress_cgr_init
	.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
	subq	$32, %rsp
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r15
	leaq	16(%rdi), %r14
	movq	%r14, %rdi
	callq	_qman_alloc_cgrid
	testl	%eax, %eax
	js	LBB0_1
## %bb.3:
	leaq	-64(%rbp), %r12
	movq	%r12, %rdi
	xorl	%esi, %esi
	movl	$32, %edx
	callq	_memset
	movq	_QM_CGR_WE_CS_THRES@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_cpu_to_be16
	movl	%eax, -40(%rbp)
	movq	_QM_CGR_EN@GOTPCREL(%rip), %rbx
	movq	(%rbx), %rax
	movq	%rax, -48(%rbp)
	movq	_DPAA_INGRESS_CS_THRESHOLD@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	-56(%rbp), %rdi
	movl	$1, %edx
	callq	_qm_cgr_cs_thres_set64
	movq	_QM_CGR_WE_CSTD_EN@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_cpu_to_be16
	orl	%eax, -40(%rbp)
	movq	(%rbx), %rax
	movq	%rax, -64(%rbp)
	movq	_QMAN_CGR_FLAG_USE_INIT@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r14, %rdi
	movq	%r12, %rdx
	callq	_qman_create_cgr
	movl	%eax, %ebx
	movq	%r15, %rdi
	callq	_netif_msg_drv
	testl	%ebx, %ebx
	js	LBB0_4
## %bb.7:
	testq	%rax, %rax
	je	LBB0_9
## %bb.8:
	movl	16(%r15), %esi
	movq	8(%r15), %rax
	movl	(%rax), %edx
	leaq	L_.str.2(%rip), %rdi
	callq	_pr_debug
LBB0_9:
	movl	$1, (%r15)
	jmp	LBB0_10
LBB0_1:
	movl	%eax, %ebx
	movq	%r15, %rdi
	callq	_netif_msg_drv
	testq	%rax, %rax
	je	LBB0_10
## %bb.2:
	leaq	L_.str(%rip), %rdi
	movl	%ebx, %esi
	xorl	%eax, %eax
	callq	_pr_err
	jmp	LBB0_10
LBB0_4:
	testq	%rax, %rax
	je	LBB0_6
## %bb.5:
	movl	(%r14), %edx
	leaq	L_.str.1(%rip), %rdi
	movl	%ebx, %esi
	xorl	%eax, %eax
	callq	_pr_err
LBB0_6:
	movl	(%r14), %edi
	callq	_qman_release_cgrid
LBB0_10:
	movl	%ebx, %eax
	addq	$32, %rsp
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Error %d allocating CGR ID\n"

	.comm	_QM_CGR_WE_CS_THRES,4,2         ## @QM_CGR_WE_CS_THRES
	.comm	_QM_CGR_EN,8,3                  ## @QM_CGR_EN
	.comm	_DPAA_INGRESS_CS_THRESHOLD,4,2  ## @DPAA_INGRESS_CS_THRESHOLD
	.comm	_QM_CGR_WE_CSTD_EN,4,2          ## @QM_CGR_WE_CSTD_EN
	.comm	_QMAN_CGR_FLAG_USE_INIT,4,2     ## @QMAN_CGR_FLAG_USE_INIT
L_.str.1:                               ## @.str.1
	.asciz	"Error %d creating ingress CGR with ID %d\n"

L_.str.2:                               ## @.str.2
	.asciz	"Created ingress CGR %d for netdev with hwaddr %pM\n"

	.no_dead_strip	_dpaa_ingress_cgr_init
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function dpaa_ingress_cgr_init
_dpaa_ingress_cgr_init:                 ; @dpaa_ingress_cgr_init
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #96
	.cfi_def_cfa_offset 96
	stp	x22, x21, [sp, #48]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #64]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #80]             ; 16-byte Folded Spill
	add	x29, sp, #80
	.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
	add	x20, x0, #16
	mov	x0, x20
	bl	_qman_alloc_cgrid
	tbnz	w0, #31, LBB0_5
; %bb.1:
	add	x21, sp, #16
	add	x0, sp, #16
	mov	w1, #0
	mov	w2, #32
	bl	_memset
Lloh0:
	adrp	x8, _QM_CGR_WE_CS_THRES@GOTPAGE
Lloh1:
	ldr	x8, [x8, _QM_CGR_WE_CS_THRES@GOTPAGEOFF]
Lloh2:
	ldr	w0, [x8]
	bl	_cpu_to_be16
	str	w0, [sp, #40]
Lloh3:
	adrp	x22, _QM_CGR_EN@GOTPAGE
Lloh4:
	ldr	x22, [x22, _QM_CGR_EN@GOTPAGEOFF]
	ldr	x8, [x22]
	str	x8, [sp, #32]
Lloh5:
	adrp	x8, _DPAA_INGRESS_CS_THRESHOLD@GOTPAGE
Lloh6:
	ldr	x8, [x8, _DPAA_INGRESS_CS_THRESHOLD@GOTPAGEOFF]
Lloh7:
	ldr	w1, [x8]
	add	x0, x21, #8
	mov	w2, #1
	bl	_qm_cgr_cs_thres_set64
Lloh8:
	adrp	x8, _QM_CGR_WE_CSTD_EN@GOTPAGE
Lloh9:
	ldr	x8, [x8, _QM_CGR_WE_CSTD_EN@GOTPAGEOFF]
Lloh10:
	ldr	w0, [x8]
	bl	_cpu_to_be16
	ldr	w8, [sp, #40]
	orr	w8, w8, w0
	str	w8, [sp, #40]
	ldr	x8, [x22]
	str	x8, [sp, #16]
Lloh11:
	adrp	x8, _QMAN_CGR_FLAG_USE_INIT@GOTPAGE
Lloh12:
	ldr	x8, [x8, _QMAN_CGR_FLAG_USE_INIT@GOTPAGEOFF]
Lloh13:
	ldr	w1, [x8]
	add	x2, sp, #16
	mov	x0, x20
	bl	_qman_create_cgr
	mov	x21, x0
	mov	x0, x19
	bl	_netif_msg_drv
	tbnz	w21, #31, LBB0_7
; %bb.2:
	cbz	x0, LBB0_4
; %bb.3:
	ldr	w1, [x19, #16]
	ldr	x8, [x19, #8]
	ldr	w2, [x8]
Lloh14:
	adrp	x0, l_.str.2@PAGE
Lloh15:
	add	x0, x0, l_.str.2@PAGEOFF
	bl	_pr_debug
LBB0_4:
	mov	w8, #1
	str	w8, [x19]
	b	LBB0_10
LBB0_5:
	mov	x21, x0
	mov	x0, x19
	bl	_netif_msg_drv
	cbz	x0, LBB0_10
; %bb.6:
Lloh16:
	adrp	x0, l_.str@PAGE
Lloh17:
	add	x0, x0, l_.str@PAGEOFF
	mov	x1, x21
	bl	_pr_err
	b	LBB0_10
LBB0_7:
	cbz	x0, LBB0_9
; %bb.8:
	ldr	w8, [x20]
	str	x8, [sp]
Lloh18:
	adrp	x0, l_.str.1@PAGE
Lloh19:
	add	x0, x0, l_.str.1@PAGEOFF
	mov	x1, x21
	bl	_pr_err
LBB0_9:
	ldr	w0, [x20]
	bl	_qman_release_cgrid
LBB0_10:
	mov	x0, x21
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	add	sp, sp, #96
	ret
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh14, Lloh15
	.loh AdrpAdd	Lloh16, Lloh17
	.loh AdrpAdd	Lloh18, Lloh19
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Error %d allocating CGR ID\n"

	.comm	_QM_CGR_WE_CS_THRES,4,2         ; @QM_CGR_WE_CS_THRES
	.comm	_QM_CGR_EN,8,3                  ; @QM_CGR_EN
	.comm	_DPAA_INGRESS_CS_THRESHOLD,4,2  ; @DPAA_INGRESS_CS_THRESHOLD
	.comm	_QM_CGR_WE_CSTD_EN,4,2          ; @QM_CGR_WE_CSTD_EN
	.comm	_QMAN_CGR_FLAG_USE_INIT,4,2     ; @QMAN_CGR_FLAG_USE_INIT
l_.str.1:                               ; @.str.1
	.asciz	"Error %d creating ingress CGR with ID %d\n"

l_.str.2:                               ; @.str.2
	.asciz	"Created ingress CGR %d for netdev with hwaddr %pM\n"

	.no_dead_strip	_dpaa_ingress_cgr_init
.subsections_via_symbols
