	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function hns_nic_init_irq
_hns_nic_init_irq:                      ## @hns_nic_init_irq
	.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	$40, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	16(%rdi), %rbx
	cmpl	$0, (%rbx)
	jle	LBB0_8
## %bb.1:
	movq	%rdi, %rcx
	movq	_RCB_IRQ_INITED@GOTPCREL(%rip), %rdx
	xorl	%r15d, %r15d
	xorl	%r14d, %r14d
	movq	%rdi, -56(%rbp)                 ## 8-byte Spill
	movq	%rbx, -48(%rbp)                 ## 8-byte Spill
	jmp	LBB0_2
	.p2align	4, 0x90
LBB0_7:                                 ##   in Loop: Header=BB0_2 Depth=1
	movq	_RCB_IRQ_INITED@GOTPCREL(%rip), %rdx
	movq	(%rdx), %rax
	movq	(%r12,%r15), %rcx
	movq	%rax, (%rcx)
	incq	%r14
	movslq	(%rbx), %rax
	addq	%rax, %rax
	addq	$16, %r15
	cmpq	%rax, %r14
	movq	-56(%rbp), %rcx                 ## 8-byte Reload
	jge	LBB0_8
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	movq	8(%rcx), %r12
	movq	(%r12,%r15), %rdi
	movq	(%rdi), %rax
	cmpq	(%rdx), %rax
	je	LBB0_8
## %bb.3:                               ##   in Loop: Header=BB0_2 Depth=1
	leaq	(%r12,%r15), %rax
	movq	%rax, -72(%rbp)                 ## 8-byte Spill
	movq	8(%rdi), %rbx
	movq	_RCB_RING_NAME_LEN@GOTPCREL(%rip), %rax
	movl	(%rax), %r13d
	movq	(%rcx), %rax
	movq	(%rax), %rax
	movq	%rax, -64(%rbp)                 ## 8-byte Spill
	callq	_is_tx_ring
	testq	%rax, %rax
	leaq	L_.str.1(%rip), %r8
	leaq	L_.str.2(%rip), %rax
	cmoveq	%rax, %r8
	movl	12(%r12,%r15), %r9d
	movq	%rbx, %rdi
	movl	%r13d, %esi
	leaq	L_.str(%rip), %rdx
	movq	-64(%rbp), %rcx                 ## 8-byte Reload
	callq	_snprintf
	movq	(%r12,%r15), %rax
	movq	8(%rax), %rax
	movq	_RCB_RING_NAME_LEN@GOTPCREL(%rip), %rcx
	movslq	(%rcx), %rcx
	movb	$0, -1(%rcx,%rax)
	movq	(%r12,%r15), %rax
	movl	16(%rax), %edi
	movq	_hns_irq_handle@GOTPCREL(%rip), %rcx
	movl	(%rcx), %esi
	movq	8(%rax), %rcx
	xorl	%edx, %edx
	movq	-72(%rbp), %r8                  ## 8-byte Reload
	callq	_request_irq
	testl	%eax, %eax
	jne	LBB0_4
## %bb.5:                               ##   in Loop: Header=BB0_2 Depth=1
	movq	(%r12,%r15), %rax
	movl	16(%rax), %edi
	callq	_disable_irq
	movq	-48(%rbp), %rbx                 ## 8-byte Reload
	movl	(%rbx), %edi
	movq	(%r12,%r15), %rdx
	leaq	(%r12,%r15), %r13
	addq	$8, %r13
	movl	%r14d, %esi
	movq	%r13, %rcx
	callq	_hns_nic_init_affinity_mask
	movl	%eax, %edi
	callq	_cpu_online
	testq	%rax, %rax
	je	LBB0_7
## %bb.6:                               ##   in Loop: Header=BB0_2 Depth=1
	movq	(%r12,%r15), %rax
	movl	16(%rax), %edi
	movq	%r13, %rsi
	callq	_irq_set_affinity_hint
	jmp	LBB0_7
LBB0_8:
	xorl	%eax, %eax
	jmp	LBB0_9
LBB0_4:
	movl	%eax, %ebx
	movq	-56(%rbp), %r14                 ## 8-byte Reload
	movq	(%r14), %rdi
	movq	(%r12,%r15), %rax
	movl	16(%rax), %edx
	leaq	L_.str.3(%rip), %rsi
	callq	_netdev_err
	movq	-48(%rbp), %rax                 ## 8-byte Reload
	movl	(%rax), %edi
	movq	%r14, %rsi
	callq	_hns_nic_free_irq
	movl	%ebx, %eax
LBB0_9:
                                        ## kill: def $eax killed $eax killed $rax
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_RCB_IRQ_INITED,8,3             ## @RCB_IRQ_INITED
	.comm	_RCB_RING_NAME_LEN,4,2          ## @RCB_RING_NAME_LEN
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"%s-%s%d"

L_.str.1:                               ## @.str.1
	.asciz	"tx"

L_.str.2:                               ## @.str.2
	.asciz	"rx"

	.comm	_hns_irq_handle,4,2             ## @hns_irq_handle
L_.str.3:                               ## @.str.3
	.asciz	"request irq(%d) fail\n"

	.no_dead_strip	_hns_nic_init_irq
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function hns_nic_init_irq
_hns_nic_init_irq:                      ; @hns_nic_init_irq
	.cfi_startproc
; %bb.0:
	stp	x28, x27, [sp, #-96]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 96
	stp	x26, x25, [sp, #16]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #32]             ; 16-byte Folded Spill
	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
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	ldr	x19, [x0, #16]
	ldr	w8, [x19]
	cmp	w8, #1
	b.lt	LBB0_7
; %bb.1:
	mov	x10, x0
	mov	x27, #0
	mov	x20, #0
Lloh0:
	adrp	x21, _RCB_IRQ_INITED@GOTPAGE
Lloh1:
	ldr	x21, [x21, _RCB_IRQ_INITED@GOTPAGEOFF]
	b	LBB0_3
LBB0_2:                                 ;   in Loop: Header=BB0_3 Depth=1
	ldr	x8, [x28, x27]
	ldr	x9, [x21]
	str	x9, [x8]
	add	x20, x20, #1
	ldrsw	x8, [x19]
	add	x27, x27, #16
	cmp	x20, x8, lsl #1
	mov	x10, x26
	b.ge	LBB0_7
LBB0_3:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x28, [x10, #8]
	add	x22, x28, x27
	ldr	x0, [x22]
	ldr	x8, [x0]
	ldr	x9, [x21]
	cmp	x8, x9
	b.eq	LBB0_7
; %bb.4:                                ;   in Loop: Header=BB0_3 Depth=1
	ldr	x23, [x0, #8]
Lloh2:
	adrp	x8, _RCB_RING_NAME_LEN@GOTPAGE
Lloh3:
	ldr	x8, [x8, _RCB_RING_NAME_LEN@GOTPAGEOFF]
Lloh4:
	ldr	w24, [x8]
	mov	x26, x10
	ldr	x8, [x10]
	ldr	x25, [x8]
	bl	_is_tx_ring
	cmp	x0, #0
Lloh5:
	adrp	x8, l_.str.1@PAGE
Lloh6:
	add	x8, x8, l_.str.1@PAGEOFF
Lloh7:
	adrp	x9, l_.str.2@PAGE
Lloh8:
	add	x9, x9, l_.str.2@PAGEOFF
	csel	x4, x9, x8, eq
	ldr	w5, [x22, #12]
	mov	x0, x23
	mov	x1, x24
Lloh9:
	adrp	x2, l_.str@PAGE
Lloh10:
	add	x2, x2, l_.str@PAGEOFF
	mov	x3, x25
	bl	_snprintf
	ldr	x8, [x22]
	ldr	x8, [x8, #8]
Lloh11:
	adrp	x9, _RCB_RING_NAME_LEN@GOTPAGE
Lloh12:
	ldr	x9, [x9, _RCB_RING_NAME_LEN@GOTPAGEOFF]
Lloh13:
	ldrsw	x9, [x9]
	add	x8, x9, x8
	sturb	wzr, [x8, #-1]
	ldr	x8, [x22]
	ldr	w0, [x8, #16]
Lloh14:
	adrp	x9, _hns_irq_handle@GOTPAGE
Lloh15:
	ldr	x9, [x9, _hns_irq_handle@GOTPAGEOFF]
Lloh16:
	ldr	w1, [x9]
	ldr	x3, [x8, #8]
	mov	w2, #0
	mov	x4, x22
	bl	_request_irq
	cbnz	w0, LBB0_8
; %bb.5:                                ;   in Loop: Header=BB0_3 Depth=1
	add	x22, x28, x27
	ldr	x8, [x22]
	ldr	w0, [x8, #16]
	bl	_disable_irq
	ldr	w0, [x19]
	ldr	x2, [x22], #8
	mov	x1, x20
	mov	x3, x22
	bl	_hns_nic_init_affinity_mask
	bl	_cpu_online
	cbz	x0, LBB0_2
; %bb.6:                                ;   in Loop: Header=BB0_3 Depth=1
	ldr	x8, [x28, x27]
	ldr	w0, [x8, #16]
	mov	x1, x22
	bl	_irq_set_affinity_hint
	b	LBB0_2
LBB0_7:
	mov	w22, #0
	b	LBB0_9
LBB0_8:
	mov	x22, x0
	ldr	x0, [x26]
	ldr	x8, [x28, x27]
	ldr	w2, [x8, #16]
Lloh17:
	adrp	x1, l_.str.3@PAGE
Lloh18:
	add	x1, x1, l_.str.3@PAGEOFF
	bl	_netdev_err
	ldr	w0, [x19]
	mov	x1, x26
	bl	_hns_nic_free_irq
LBB0_9:
	mov	x0, x22
	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
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #16]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp], #96             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpAdd	Lloh9, Lloh10
	.loh AdrpAdd	Lloh7, Lloh8
	.loh AdrpAdd	Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpAdd	Lloh17, Lloh18
	.cfi_endproc
                                        ; -- End function
	.comm	_RCB_IRQ_INITED,8,3             ; @RCB_IRQ_INITED
	.comm	_RCB_RING_NAME_LEN,4,2          ; @RCB_RING_NAME_LEN
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"%s-%s%d"

l_.str.1:                               ; @.str.1
	.asciz	"tx"

l_.str.2:                               ; @.str.2
	.asciz	"rx"

	.comm	_hns_irq_handle,4,2             ; @hns_irq_handle
l_.str.3:                               ; @.str.3
	.asciz	"request irq(%d) fail\n"

	.no_dead_strip	_hns_nic_init_irq
.subsections_via_symbols
