	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function hns3_get_ring_config
_hns3_get_ring_config:                  ## @hns3_get_ring_config
	.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	%rdi, %r15
	movq	16(%rdi), %r12
	movq	16(%r12), %r14
	movl	(%r12), %edi
	movl	$8, %esi
	movl	$2, %edx
	callq	_array3_size
	movq	_GFP_KERNEL@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edx
	movq	%r14, %rdi
	movl	%eax, %esi
	callq	_devm_kzalloc
	movq	%rax, (%r15)
	testq	%rax, %rax
	je	LBB0_11
## %bb.1:
	cmpl	$0, (%r12)
	jle	LBB0_9
## %bb.2:
	xorl	%ebx, %ebx
	.p2align	4, 0x90
LBB0_3:                                 ## =>This Inner Loop Header: Depth=1
	movq	8(%r12), %rax
	movl	(%rax,%rbx,4), %edi
	movq	%r15, %rsi
	callq	_hns3_queue_to_ring
	testl	%eax, %eax
	jne	LBB0_4
## %bb.8:                               ##   in Loop: Header=BB0_3 Depth=1
	incq	%rbx
	movslq	(%r12), %rax
	cmpq	%rax, %rbx
	jl	LBB0_3
LBB0_9:
	xorl	%r13d, %r13d
	jmp	LBB0_10
LBB0_11:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	xorl	%r13d, %r13d
	subl	(%rax), %r13d
	jmp	LBB0_10
LBB0_4:
	movl	%eax, %r13d
	testl	%ebx, %ebx
	je	LBB0_7
## %bb.5:
	decq	%rbx
	.p2align	4, 0x90
LBB0_6:                                 ## =>This Inner Loop Header: Depth=1
	movq	(%r15), %rax
	movq	8(%r15), %rdi
	movq	(%rax,%rbx,8), %rsi
	callq	_devm_kfree
	movq	(%r15), %rax
	movq	8(%r15), %rdi
	movslq	(%r12), %rcx
	addq	%rbx, %rcx
	movq	(%rax,%rcx,8), %rsi
	callq	_devm_kfree
	addq	$-1, %rbx
	jb	LBB0_6
LBB0_7:
	movq	(%r15), %rsi
	movq	%r14, %rdi
	callq	_devm_kfree
	movq	$0, (%r15)
LBB0_10:
	movl	%r13d, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_GFP_KERNEL,4,2                 ## @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.no_dead_strip	_hns3_get_ring_config
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function hns3_get_ring_config
_hns3_get_ring_config:                  ; @hns3_get_ring_config
	.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, x0
	ldr	x22, [x0, #16]
	ldr	x20, [x22, #16]
	ldr	w0, [x22]
	mov	w1, #8
	mov	w2, #2
	bl	_array3_size
	mov	x1, x0
Lloh0:
	adrp	x8, _GFP_KERNEL@GOTPAGE
Lloh1:
	ldr	x8, [x8, _GFP_KERNEL@GOTPAGEOFF]
Lloh2:
	ldr	w2, [x8]
	mov	x0, x20
	bl	_devm_kzalloc
	str	x0, [x19]
	cbz	x0, LBB0_6
; %bb.1:
	ldr	w8, [x22]
	cmp	w8, #1
	b.lt	LBB0_5
; %bb.2:
	mov	x23, #0
LBB0_3:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x8, [x22, #8]
	ldr	w0, [x8, x23, lsl #2]
	mov	x1, x19
	bl	_hns3_queue_to_ring
	cbnz	w0, LBB0_7
; %bb.4:                                ;   in Loop: Header=BB0_3 Depth=1
	add	x23, x23, #1
	ldrsw	x8, [x22]
	cmp	x23, x8
	b.lt	LBB0_3
LBB0_5:
	mov	w21, #0
	b	LBB0_11
LBB0_6:
Lloh3:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh4:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	neg	w21, w8
	b	LBB0_11
LBB0_7:
	mov	x21, x0
	cbz	w23, LBB0_10
; %bb.8:
	sub	x23, x23, #1
LBB0_9:                                 ; =>This Inner Loop Header: Depth=1
	ldp	x8, x0, [x19]
	ldr	x1, [x8, x23, lsl #3]
	bl	_devm_kfree
	ldp	x8, x0, [x19]
	ldrsw	x9, [x22]
	add	x9, x23, x9
	ldr	x1, [x8, x9, lsl #3]
	bl	_devm_kfree
	sub	x23, x23, #1
	cmn	x23, #1
	b.ne	LBB0_9
LBB0_10:
	ldr	x1, [x19]
	mov	x0, x20
	bl	_devm_kfree
	str	xzr, [x19]
LBB0_11:
	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
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.cfi_endproc
                                        ; -- End function
	.comm	_GFP_KERNEL,4,2                 ; @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.no_dead_strip	_hns3_get_ring_config
.subsections_via_symbols
