	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function niu_alloc_rx_ring_info
_niu_alloc_rx_ring_info:                ## @niu_alloc_rx_ring_info
	.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, %rbx
	movq	%rdi, %r14
	movl	$1, %edi
	callq	_BUILD_BUG_ON
	movq	_MAX_RBR_RING_SIZE@GOTPCREL(%rip), %r15
	movl	(%r15), %edi
	movq	_GFP_KERNEL@GOTPCREL(%rip), %r12
	movl	(%r12), %edx
	movl	$8, %esi
	callq	_kcalloc
	movl	%eax, 76(%rbx)
	testl	%eax, %eax
	je	LBB0_1
## %bb.3:
	movq	8(%r14), %rax
	movl	4(%r14), %edi
	leaq	72(%rbx), %rdx
	movl	(%r12), %ecx
	movl	$4, %esi
	callq	*(%rax)
	movq	%rax, 64(%rbx)
	testq	%rax, %rax
	je	LBB0_1
## %bb.4:
	testb	$63, %al
	je	LBB0_7
## %bb.5:
	movl	(%r14), %edi
	leaq	L_.str(%rip), %rsi
LBB0_6:
	movq	%rax, %rdx
	callq	_netdev_err
	movq	_EINVAL@GOTPCREL(%rip), %rcx
	jmp	LBB0_2
LBB0_7:
	movq	8(%r14), %rax
	movl	4(%r14), %edi
	movq	_MAX_RCR_RING_SIZE@GOTPCREL(%rip), %r13
	movl	(%r13), %esi
	shll	$2, %esi
	leaq	56(%rbx), %rdx
	movl	(%r12), %ecx
	callq	*(%rax)
	movq	%rax, 48(%rbx)
	testq	%rax, %rax
	je	LBB0_1
## %bb.8:
	testb	$63, %al
	je	LBB0_10
## %bb.9:
	movl	(%r14), %edi
	leaq	L_.str.1(%rip), %rsi
	jmp	LBB0_6
LBB0_10:
	movl	(%r13), %eax
	movl	%eax, (%rbx)
	movq	$0, 40(%rbx)
	movq	8(%r14), %rax
	movl	4(%r14), %edi
	movl	(%r15), %esi
	shll	$2, %esi
	leaq	32(%rbx), %rdx
	movl	(%r12), %ecx
	callq	*(%rax)
	movq	%rax, 24(%rbx)
	testq	%rax, %rax
	je	LBB0_1
## %bb.11:
	testb	$63, %al
	je	LBB0_13
## %bb.12:
	movl	(%r14), %edi
	leaq	L_.str.2(%rip), %rsi
	jmp	LBB0_6
LBB0_1:
	movq	_ENOMEM@GOTPCREL(%rip), %rcx
LBB0_2:
	xorl	%eax, %eax
	subl	(%rcx), %eax
LBB0_14:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_13:
	movl	(%r15), %eax
	movl	%eax, 4(%rbx)
	xorps	%xmm0, %xmm0
	movups	%xmm0, 8(%rbx)
	xorl	%eax, %eax
	jmp	LBB0_14
	.cfi_endproc
                                        ## -- End function
	.comm	_MAX_RBR_RING_SIZE,4,2          ## @MAX_RBR_RING_SIZE
	.comm	_GFP_KERNEL,4,2                 ## @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Coherent alloc gives misaligned RXDMA mailbox %p\n"

	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_MAX_RCR_RING_SIZE,4,2          ## @MAX_RCR_RING_SIZE
L_.str.1:                               ## @.str.1
	.asciz	"Coherent alloc gives misaligned RXDMA RCR table %p\n"

L_.str.2:                               ## @.str.2
	.asciz	"Coherent alloc gives misaligned RXDMA RBR table %p\n"

	.no_dead_strip	_niu_alloc_rx_ring_info
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function niu_alloc_rx_ring_info
_niu_alloc_rx_ring_info:                ; @niu_alloc_rx_ring_info
	.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	x20, x1
	mov	x19, x0
	mov	w0, #1
	bl	_BUILD_BUG_ON
Lloh0:
	adrp	x21, _MAX_RBR_RING_SIZE@GOTPAGE
Lloh1:
	ldr	x21, [x21, _MAX_RBR_RING_SIZE@GOTPAGEOFF]
	ldr	w0, [x21]
Lloh2:
	adrp	x22, _GFP_KERNEL@GOTPAGE
Lloh3:
	ldr	x22, [x22, _GFP_KERNEL@GOTPAGEOFF]
	ldr	w2, [x22]
	mov	w1, #8
	bl	_kcalloc
	str	w0, [x20, #76]
	cbz	w0, LBB0_11
; %bb.1:
	ldr	x8, [x19, #8]
	ldr	x8, [x8]
	ldr	w0, [x19, #4]
	add	x2, x20, #72
	ldr	w3, [x22]
	mov	w1, #4
	blr	x8
	str	x0, [x20, #64]
	cbz	x0, LBB0_11
; %bb.2:
	mov	x2, x0
	tst	x0, #0x3f
	b.eq	LBB0_5
; %bb.3:
	ldr	w0, [x19]
Lloh4:
	adrp	x1, l_.str@PAGE
Lloh5:
	add	x1, x1, l_.str@PAGEOFF
LBB0_4:
	bl	_netdev_err
Lloh6:
	adrp	x8, _EINVAL@GOTPAGE
Lloh7:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
	b	LBB0_12
LBB0_5:
	ldr	x8, [x19, #8]
	ldr	x8, [x8]
	ldr	w0, [x19, #4]
Lloh8:
	adrp	x23, _MAX_RCR_RING_SIZE@GOTPAGE
Lloh9:
	ldr	x23, [x23, _MAX_RCR_RING_SIZE@GOTPAGEOFF]
	ldr	w9, [x23]
	lsl	w1, w9, #2
	add	x2, x20, #56
	ldr	w3, [x22]
	blr	x8
	str	x0, [x20, #48]
	cbz	x0, LBB0_11
; %bb.6:
	mov	x2, x0
	tst	x0, #0x3f
	b.eq	LBB0_8
; %bb.7:
	ldr	w0, [x19]
Lloh10:
	adrp	x1, l_.str.1@PAGE
Lloh11:
	add	x1, x1, l_.str.1@PAGEOFF
	b	LBB0_4
LBB0_8:
	ldr	w8, [x23]
	str	w8, [x20]
	str	xzr, [x20, #40]
	ldr	x8, [x19, #8]
	ldr	x8, [x8]
	ldr	w0, [x19, #4]
	ldr	w9, [x21]
	lsl	w1, w9, #2
	add	x2, x20, #32
	ldr	w3, [x22]
	blr	x8
	str	x0, [x20, #24]
	cbz	x0, LBB0_11
; %bb.9:
	mov	x2, x0
	tst	x0, #0x3f
	b.eq	LBB0_14
; %bb.10:
	ldr	w0, [x19]
Lloh12:
	adrp	x1, l_.str.2@PAGE
Lloh13:
	add	x1, x1, l_.str.2@PAGEOFF
	b	LBB0_4
LBB0_11:
Lloh14:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh15:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
LBB0_12:
	ldr	w8, [x8]
	neg	w0, w8
LBB0_13:
	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
LBB0_14:
	mov	w0, #0
	ldr	w8, [x21]
	str	w8, [x20, #4]
	stp	xzr, xzr, [x20, #8]
	b	LBB0_13
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpAdd	Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpAdd	Lloh10, Lloh11
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpLdrGot	Lloh14, Lloh15
	.cfi_endproc
                                        ; -- End function
	.comm	_MAX_RBR_RING_SIZE,4,2          ; @MAX_RBR_RING_SIZE
	.comm	_GFP_KERNEL,4,2                 ; @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Coherent alloc gives misaligned RXDMA mailbox %p\n"

	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_MAX_RCR_RING_SIZE,4,2          ; @MAX_RCR_RING_SIZE
l_.str.1:                               ; @.str.1
	.asciz	"Coherent alloc gives misaligned RXDMA RCR table %p\n"

l_.str.2:                               ; @.str.2
	.asciz	"Coherent alloc gives misaligned RXDMA RBR table %p\n"

	.no_dead_strip	_niu_alloc_rx_ring_info
.subsections_via_symbols
