	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function octeon_destroy_resources
_octeon_destroy_resources:              ## @octeon_destroy_resources
	.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	136(%rdi), %rbx
	leaq	128(%rdi), %r14
	movq	%r14, %rdi
	callq	_atomic_read
                                        ## kill: def $eax killed $eax def $rax
	addl	$-128, %eax
	cmpl	$15, %eax
	ja	LBB0_57
## %bb.1:
	movq	%rbx, -48(%rbp)                 ## 8-byte Spill
	leaq	LJTI0_0(%rip), %rcx
	movslq	(%rcx,%rax,4), %rax
	addq	%rcx, %rax
	jmpq	*%rax
LBB0_2:
	movq	%r14, %rdi
	movl	$136, %esi
	callq	_atomic_set
	movq	_CVM_DRV_INVALID_APP@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 132(%r15)
	movq	16(%r15), %r12
	addq	$4, %r12
	movq	%r14, %rdi
	callq	_lio_get_state_string
	leaq	L_.str(%rip), %rsi
	movq	%r12, %rdi
	movl	%eax, %edx
	callq	_dev_dbg
	movq	_HZ@GOTPCREL(%rip), %rax
	movslq	(%rax), %rax
	imulq	$1717986919, %rax, %rdi         ## imm = 0x66666667
	movq	%rdi, %rax
	shrq	$63, %rax
	sarq	$34, %rdi
	addl	%eax, %edi
                                        ## kill: def $edi killed $edi killed $rdi
	callq	_schedule_timeout_uninterruptible
LBB0_3:
	movq	%r15, %rdi
	callq	_octeon_remove_consoles
LBB0_4:
	movq	%r15, %rdi
	callq	_lio_wait_for_instr_fetch
	testl	%eax, %eax
	je	LBB0_6
## %bb.5:
	movq	16(%r15), %rdi
	addq	$4, %rdi
	leaq	L_.str.1(%rip), %rsi
	callq	_dev_err
LBB0_6:
	movq	%r15, %rdi
	callq	_wait_for_pending_requests
	testl	%eax, %eax
	je	LBB0_8
## %bb.7:
	movq	16(%r15), %rdi
	addq	$4, %rdi
	leaq	L_.str.2(%rip), %rsi
	callq	_dev_err
LBB0_8:
	movq	%r15, %rdi
	callq	*48(%r15)
	movq	%r15, %rdi
	callq	_lio_wait_for_oq_pkts
	testl	%eax, %eax
	je	LBB0_10
## %bb.9:
	movq	16(%r15), %rdi
	addq	$4, %rdi
	leaq	L_.str.3(%rip), %rsi
	callq	_dev_err
LBB0_10:
	movq	%r15, %rdi
	callq	_MAX_OCTEON_INSTR_QUEUES
	testl	%eax, %eax
	jle	LBB0_16
## %bb.11:
	xorl	%ebx, %ebx
	jmp	LBB0_12
	.p2align	4, 0x90
LBB0_15:                                ##   in Loop: Header=BB0_12 Depth=1
	incq	%rbx
	movq	%r15, %rdi
	callq	_MAX_OCTEON_INSTR_QUEUES
	cltq
	cmpq	%rax, %rbx
	jge	LBB0_16
LBB0_12:                                ## =>This Inner Loop Header: Depth=1
	movl	72(%r15), %r14d
	movl	%ebx, %edi
	callq	_BIT_ULL
	testl	%r14d, %eax
	je	LBB0_15
## %bb.13:                              ##   in Loop: Header=BB0_12 Depth=1
	movq	120(%r15), %rax
	movq	(%rax,%rbx,8), %r12
	leaq	4(%r12), %r13
	movq	%r13, %rdi
	callq	_atomic_read
	testl	%eax, %eax
	je	LBB0_15
## %bb.14:                              ##   in Loop: Header=BB0_12 Depth=1
	movq	%r12, %rdi
	callq	_spin_lock_bh
	movl	$0, 20(%r12)
	movl	12(%r12), %eax
	movl	%eax, 16(%r12)
	movq	%r13, %rdi
	callq	_atomic_read
	addl	%eax, 8(%r12)
	movq	%r15, %rdi
	movq	%r12, %rsi
	xorl	%edx, %edx
	callq	_lio_process_iq_request_list
	movq	%r12, %rdi
	callq	_spin_unlock_bh
	jmp	LBB0_15
LBB0_16:
	movq	%r15, %rdi
	movl	$1, %esi
	callq	_lio_process_ordered_list
	movq	%r15, %rdi
	callq	_octeon_free_sc_done_list
	movq	%r15, %rdi
	callq	_octeon_free_sc_zombie_list
LBB0_17:
	movq	_OCTEON_ALL_INTR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r15, %rdi
	callq	*40(%r15)
	cmpl	$0, 116(%r15)
	je	LBB0_25
## %bb.18:
	movq	88(%r15), %r12
	movl	112(%r15), %eax
	cmpl	$2, %eax
	jl	LBB0_19
## %bb.20:
	movq	104(%r15), %rcx
	xorl	%ebx, %ebx
	xorl	%r13d, %r13d
	jmp	LBB0_21
	.p2align	4, 0x90
LBB0_23:                                ##   in Loop: Header=BB0_21 Depth=1
	incq	%r13
	leal	-1(%rax), %edx
	movslq	%edx, %rdx
	addq	$144, %rbx
	cmpq	%rdx, %r13
	jge	LBB0_24
LBB0_21:                                ## =>This Inner Loop Header: Depth=1
	cmpl	$0, 96(%rcx,%rbx)
	je	LBB0_23
## %bb.22:                              ##   in Loop: Header=BB0_21 Depth=1
	movl	(%r12,%r13,4), %edi
	xorl	%esi, %esi
	callq	_irq_set_affinity_hint
	movl	(%r12,%r13,4), %edi
	movq	104(%r15), %rsi
	addq	%rbx, %rsi
	callq	_free_irq
	movq	104(%r15), %rcx
	movl	$0, 96(%rcx,%rbx)
	movl	112(%r15), %eax
	jmp	LBB0_23
LBB0_25:
	movq	16(%r15), %rax
	movl	(%rax), %edi
	movq	%r15, %rsi
	callq	_free_irq
	movq	_LIO_FLAG_MSI_ENABLED@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	testl	%eax, (%r15)
	je	LBB0_27
## %bb.26:
	movq	16(%r15), %rdi
	callq	_pci_disable_msi
	jmp	LBB0_27
LBB0_19:
	xorl	%r13d, %r13d
LBB0_24:
	movl	(%r12,%r13,4), %edi
	movq	%r15, %rsi
	callq	_free_irq
	movq	16(%r15), %rdi
	callq	_pci_disable_msix
	movq	88(%r15), %rdi
	callq	_kfree
	movq	$0, 88(%r15)
LBB0_27:
	movq	80(%r15), %rdi
	callq	_kfree
	movq	$0, 80(%r15)
LBB0_28:
	movq	%r15, %rdi
	callq	_OCTEON_CN23XX_PF
	testl	%eax, %eax
	je	LBB0_30
## %bb.29:
	movq	%r15, %rdi
	callq	_octeon_free_ioq_vector
LBB0_30:
	movq	%r15, %rdi
	callq	_OCTEON_CN23XX_PF
	testl	%eax, %eax
	je	LBB0_32
## %bb.31:
	movq	%r15, %rdi
	callq	*32(%r15)
LBB0_32:
	movl	$100, %edi
	callq	_mdelay
	movq	%r15, %rdi
	callq	_MAX_OCTEON_OUTPUT_QUEUES
	testl	%eax, %eax
	jle	LBB0_37
## %bb.33:
	xorl	%ebx, %ebx
	jmp	LBB0_34
	.p2align	4, 0x90
LBB0_36:                                ##   in Loop: Header=BB0_34 Depth=1
	incl	%ebx
	movq	%r15, %rdi
	callq	_MAX_OCTEON_OUTPUT_QUEUES
	cmpl	%eax, %ebx
	jge	LBB0_37
LBB0_34:                                ## =>This Inner Loop Header: Depth=1
	movl	76(%r15), %r14d
	movl	%ebx, %edi
	callq	_BIT_ULL
	testl	%r14d, %eax
	je	LBB0_36
## %bb.35:                              ##   in Loop: Header=BB0_34 Depth=1
	movq	%r15, %rdi
	movl	%ebx, %esi
	callq	_octeon_delete_droq
	jmp	LBB0_36
LBB0_37:
	movq	_MAX_OCTEON_DEVICES@GOTPCREL(%rip), %r12
	movl	(%r12), %eax
	testl	%eax, %eax
	jle	LBB0_42
## %bb.38:
	movl	$16, %r13d
	xorl	%ebx, %ebx
	movq	_handshake@GOTPCREL(%rip), %r14
	jmp	LBB0_39
	.p2align	4, 0x90
LBB0_41:                                ##   in Loop: Header=BB0_39 Depth=1
	incq	%rbx
	movslq	%eax, %rcx
	addq	$20, %r13
	cmpq	%rcx, %rbx
	jge	LBB0_42
LBB0_39:                                ## =>This Inner Loop Header: Depth=1
	movq	(%r14), %rcx
	cmpl	$0, (%rcx,%r13)
	je	LBB0_41
## %bb.40:                              ##   in Loop: Header=BB0_39 Depth=1
	movq	8(%r15), %rax
	leaq	(%rax,%rax,4), %rax
	movl	$0, 12(%rcx,%rax,4)
	leaq	(%rcx,%rax,4), %rdi
	addq	$8, %rdi
	callq	_complete
	movq	(%r14), %rax
	movq	8(%r15), %rcx
	leaq	(%rcx,%rcx,4), %rcx
	leaq	(%rax,%rcx,4), %rdi
	movl	$0, 4(%rax,%rcx,4)
	callq	_complete
	movl	(%r12), %eax
	jmp	LBB0_41
LBB0_42:
	movq	%r15, %rdi
	callq	_octeon_delete_response_list
LBB0_43:
	movq	%r15, %rdi
	callq	_MAX_OCTEON_INSTR_QUEUES
	testl	%eax, %eax
	jle	LBB0_48
## %bb.44:
	xorl	%ebx, %ebx
	jmp	LBB0_45
	.p2align	4, 0x90
LBB0_47:                                ##   in Loop: Header=BB0_45 Depth=1
	incl	%ebx
	movq	%r15, %rdi
	callq	_MAX_OCTEON_INSTR_QUEUES
	cmpl	%eax, %ebx
	jge	LBB0_48
LBB0_45:                                ## =>This Inner Loop Header: Depth=1
	movl	72(%r15), %r14d
	movl	%ebx, %edi
	callq	_BIT_ULL
	testl	%r14d, %eax
	je	LBB0_47
## %bb.46:                              ##   in Loop: Header=BB0_45 Depth=1
	movq	%r15, %rdi
	movl	%ebx, %esi
	callq	_octeon_delete_instr_queue
	jmp	LBB0_47
LBB0_48:
	movq	%r15, %rdi
	callq	_octeon_free_sc_buffer_pool
LBB0_49:
	movq	%r15, %rdi
	callq	_octeon_delete_dispatch_list
	leaq	64(%r15), %rdi
	callq	_cancel_delayed_work_sync
LBB0_50:
	movq	%r15, %rdi
	callq	_octeon_deregister_device
	movl	%eax, %ebx
	movq	56(%r15), %rdi
	callq	_atomic_read
	movq	_FW_IS_PRELOADED@GOTPCREL(%rip), %rcx
	cmpl	(%rcx), %eax
	jne	LBB0_52
## %bb.51:
	movq	%r15, %rdi
	callq	_octeon_pci_flr
	jmp	LBB0_55
LBB0_52:
	movq	%r15, %rdi
	callq	_OCTEON_CN6XXX
	testl	%eax, %eax
	jne	LBB0_54
## %bb.53:
	testl	%ebx, %ebx
	jne	LBB0_55
LBB0_54:
	movq	%r15, %rdi
	callq	*24(%r15)
LBB0_55:
	movq	%r15, %rdi
	xorl	%esi, %esi
	callq	_octeon_unmap_pci_barx
	movq	%r15, %rdi
	movl	$1, %esi
	callq	_octeon_unmap_pci_barx
LBB0_56:
	movq	16(%r15), %rdi
	callq	_pci_clear_master
	movq	16(%r15), %rdi
	callq	_pci_disable_device
	movq	-48(%rbp), %rbx                 ## 8-byte Reload
LBB0_57:
	movq	%rbx, %rdi
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_tasklet_kill                   ## TAILCALL
	.cfi_endproc
	.p2align	2, 0x90
	.data_region jt32
.set L0_0_set_48, LBB0_48-LJTI0_0
.set L0_0_set_2, LBB0_2-LJTI0_0
.set L0_0_set_42, LBB0_42-LJTI0_0
.set L0_0_set_50, LBB0_50-LJTI0_0
.set L0_0_set_56, LBB0_56-LJTI0_0
.set L0_0_set_28, LBB0_28-LJTI0_0
.set L0_0_set_30, LBB0_30-LJTI0_0
.set L0_0_set_4, LBB0_4-LJTI0_0
.set L0_0_set_32, LBB0_32-LJTI0_0
.set L0_0_set_17, LBB0_17-LJTI0_0
.set L0_0_set_43, LBB0_43-LJTI0_0
.set L0_0_set_3, LBB0_3-LJTI0_0
.set L0_0_set_49, LBB0_49-LJTI0_0
LJTI0_0:
	.long	L0_0_set_48
	.long	L0_0_set_2
	.long	L0_0_set_42
	.long	L0_0_set_50
	.long	L0_0_set_56
	.long	L0_0_set_28
	.long	L0_0_set_30
	.long	L0_0_set_4
	.long	L0_0_set_32
	.long	L0_0_set_17
	.long	L0_0_set_43
	.long	L0_0_set_3
	.long	L0_0_set_32
	.long	L0_0_set_49
	.long	L0_0_set_2
	.long	L0_0_set_3
	.end_data_region
                                        ## -- End function
	.comm	_CVM_DRV_INVALID_APP,4,2        ## @CVM_DRV_INVALID_APP
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Device state is now %s\n"

	.comm	_HZ,4,2                         ## @HZ
L_.str.1:                               ## @.str.1
	.asciz	"IQ had pending instructions\n"

L_.str.2:                               ## @.str.2
	.asciz	"There were pending requests\n"

L_.str.3:                               ## @.str.3
	.asciz	"OQ had pending packets\n"

	.comm	_OCTEON_ALL_INTR,4,2            ## @OCTEON_ALL_INTR
	.comm	_LIO_FLAG_MSI_ENABLED,4,2       ## @LIO_FLAG_MSI_ENABLED
	.comm	_MAX_OCTEON_DEVICES,4,2         ## @MAX_OCTEON_DEVICES
	.comm	_handshake,8,3                  ## @handshake
	.comm	_FW_IS_PRELOADED,4,2            ## @FW_IS_PRELOADED
	.no_dead_strip	_octeon_destroy_resources
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function octeon_destroy_resources
_octeon_destroy_resources:              ; @octeon_destroy_resources
	.cfi_startproc
; %bb.0:
	stp	x26, x25, [sp, #-80]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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
	mov	x20, x0
	ldr	x19, [x0, #136]
	add	x21, x0, #128
	mov	x0, x21
	bl	_atomic_read
	sub	w8, w0, #128
	cmp	w8, #15
	b.hi	LBB0_57
; %bb.1:
Lloh0:
	adrp	x9, lJTI0_0@PAGE
Lloh1:
	add	x9, x9, lJTI0_0@PAGEOFF
	adr	x10, LBB0_2
	ldrh	w11, [x9, x8, lsl #1]
	add	x10, x10, x11, lsl #2
	br	x10
LBB0_2:
	mov	x0, x21
	mov	w1, #136
	bl	_atomic_set
Lloh2:
	adrp	x8, _CVM_DRV_INVALID_APP@GOTPAGE
Lloh3:
	ldr	x8, [x8, _CVM_DRV_INVALID_APP@GOTPAGEOFF]
Lloh4:
	ldr	w8, [x8]
	str	w8, [x20, #132]
	ldr	x8, [x20, #16]
	add	x22, x8, #4
	mov	x0, x21
	bl	_lio_get_state_string
	mov	x2, x0
Lloh5:
	adrp	x1, l_.str@PAGE
Lloh6:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x22
	bl	_dev_dbg
Lloh7:
	adrp	x8, _HZ@GOTPAGE
Lloh8:
	ldr	x8, [x8, _HZ@GOTPAGEOFF]
Lloh9:
	ldrsw	x8, [x8]
	mov	w9, #26215
	movk	w9, #26214, lsl #16
	mul	x8, x8, x9
	lsr	x9, x8, #63
	asr	x8, x8, #34
	add	w0, w8, w9
	bl	_schedule_timeout_uninterruptible
LBB0_3:
	mov	x0, x20
	bl	_octeon_remove_consoles
LBB0_4:
	mov	x0, x20
	bl	_lio_wait_for_instr_fetch
	cbz	w0, LBB0_6
; %bb.5:
	ldr	x8, [x20, #16]
	add	x0, x8, #4
Lloh10:
	adrp	x1, l_.str.1@PAGE
Lloh11:
	add	x1, x1, l_.str.1@PAGEOFF
	bl	_dev_err
LBB0_6:
	mov	x0, x20
	bl	_wait_for_pending_requests
	cbz	w0, LBB0_8
; %bb.7:
	ldr	x8, [x20, #16]
	add	x0, x8, #4
Lloh12:
	adrp	x1, l_.str.2@PAGE
Lloh13:
	add	x1, x1, l_.str.2@PAGEOFF
	bl	_dev_err
LBB0_8:
	ldr	x8, [x20, #48]
	mov	x0, x20
	blr	x8
	mov	x0, x20
	bl	_lio_wait_for_oq_pkts
	cbz	w0, LBB0_10
; %bb.9:
	ldr	x8, [x20, #16]
	add	x0, x8, #4
Lloh14:
	adrp	x1, l_.str.3@PAGE
Lloh15:
	add	x1, x1, l_.str.3@PAGEOFF
	bl	_dev_err
LBB0_10:
	mov	x0, x20
	bl	_MAX_OCTEON_INSTR_QUEUES
	cmp	w0, #1
	b.lt	LBB0_16
; %bb.11:
	mov	x21, #0
	b	LBB0_13
LBB0_12:                                ;   in Loop: Header=BB0_13 Depth=1
	add	x21, x21, #1
	mov	x0, x20
	bl	_MAX_OCTEON_INSTR_QUEUES
	cmp	x21, w0, sxtw
	b.ge	LBB0_16
LBB0_13:                                ; =>This Inner Loop Header: Depth=1
	ldr	w22, [x20, #72]
	mov	x0, x21
	bl	_BIT_ULL
	tst	w0, w22
	b.eq	LBB0_12
; %bb.14:                               ;   in Loop: Header=BB0_13 Depth=1
	ldr	x8, [x20, #120]
	ldr	x22, [x8, x21, lsl #3]
	add	x23, x22, #4
	mov	x0, x23
	bl	_atomic_read
	cbz	w0, LBB0_12
; %bb.15:                               ;   in Loop: Header=BB0_13 Depth=1
	mov	x0, x22
	bl	_spin_lock_bh
	ldr	w8, [x22, #12]
	stp	w8, wzr, [x22, #16]
	mov	x0, x23
	bl	_atomic_read
	ldr	w8, [x22, #8]
	add	w8, w8, w0
	str	w8, [x22, #8]
	mov	x0, x20
	mov	x1, x22
	mov	w2, #0
	bl	_lio_process_iq_request_list
	mov	x0, x22
	bl	_spin_unlock_bh
	b	LBB0_12
LBB0_16:
	mov	x0, x20
	mov	w1, #1
	bl	_lio_process_ordered_list
	mov	x0, x20
	bl	_octeon_free_sc_done_list
	mov	x0, x20
	bl	_octeon_free_sc_zombie_list
LBB0_17:
	ldr	x8, [x20, #40]
Lloh16:
	adrp	x9, _OCTEON_ALL_INTR@GOTPAGE
Lloh17:
	ldr	x9, [x9, _OCTEON_ALL_INTR@GOTPAGEOFF]
Lloh18:
	ldr	w1, [x9]
	mov	x0, x20
	blr	x8
	ldr	w8, [x20, #116]
	cbz	w8, LBB0_23
; %bb.18:
	ldr	x21, [x20, #88]
	ldr	w8, [x20, #112]
	cmp	w8, #2
	b.lt	LBB0_25
; %bb.19:
	mov	x22, #0
	ldr	x9, [x20, #104]
	mov	w23, #96
	b	LBB0_21
LBB0_20:                                ;   in Loop: Header=BB0_21 Depth=1
	add	x22, x22, #1
	sub	w10, w8, #1
	add	x23, x23, #144
	cmp	x22, w10, sxtw
	b.ge	LBB0_26
LBB0_21:                                ; =>This Inner Loop Header: Depth=1
	ldr	w10, [x9, x23]
	cbz	w10, LBB0_20
; %bb.22:                               ;   in Loop: Header=BB0_21 Depth=1
	lsl	x24, x22, #2
	ldr	w0, [x21, x24]
	mov	x1, #0
	bl	_irq_set_affinity_hint
	ldr	w0, [x21, x24]
	ldr	x8, [x20, #104]
	add	x8, x8, x23
	sub	x1, x8, #96
	bl	_free_irq
	ldr	x9, [x20, #104]
	str	wzr, [x9, x23]
	ldr	w8, [x20, #112]
	b	LBB0_20
LBB0_23:
	ldr	x8, [x20, #16]
	ldr	w0, [x8]
	mov	x1, x20
	bl	_free_irq
	ldr	w8, [x20]
Lloh19:
	adrp	x9, _LIO_FLAG_MSI_ENABLED@GOTPAGE
Lloh20:
	ldr	x9, [x9, _LIO_FLAG_MSI_ENABLED@GOTPAGEOFF]
Lloh21:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_27
; %bb.24:
	ldr	x0, [x20, #16]
	bl	_pci_disable_msi
	b	LBB0_27
LBB0_25:
	mov	x22, #0
LBB0_26:
	ldr	w0, [x21, x22, lsl #2]
	mov	x1, x20
	bl	_free_irq
	ldr	x0, [x20, #16]
	bl	_pci_disable_msix
	ldr	x0, [x20, #88]
	bl	_kfree
	str	xzr, [x20, #88]
LBB0_27:
	ldr	x0, [x20, #80]
	bl	_kfree
	str	xzr, [x20, #80]
LBB0_28:
	mov	x0, x20
	bl	_OCTEON_CN23XX_PF
	cbz	w0, LBB0_30
; %bb.29:
	mov	x0, x20
	bl	_octeon_free_ioq_vector
LBB0_30:
	mov	x0, x20
	bl	_OCTEON_CN23XX_PF
	cbz	w0, LBB0_32
; %bb.31:
	ldr	x8, [x20, #32]
	mov	x0, x20
	blr	x8
LBB0_32:
	mov	w0, #100
	bl	_mdelay
	mov	x0, x20
	bl	_MAX_OCTEON_OUTPUT_QUEUES
	cmp	w0, #1
	b.lt	LBB0_37
; %bb.33:
	mov	w21, #0
	b	LBB0_35
LBB0_34:                                ;   in Loop: Header=BB0_35 Depth=1
	add	w21, w21, #1
	mov	x0, x20
	bl	_MAX_OCTEON_OUTPUT_QUEUES
	cmp	w21, w0
	b.ge	LBB0_37
LBB0_35:                                ; =>This Inner Loop Header: Depth=1
	ldr	w22, [x20, #76]
	mov	x0, x21
	bl	_BIT_ULL
	tst	w0, w22
	b.eq	LBB0_34
; %bb.36:                               ;   in Loop: Header=BB0_35 Depth=1
	mov	x0, x20
	mov	x1, x21
	bl	_octeon_delete_droq
	b	LBB0_34
LBB0_37:
Lloh22:
	adrp	x21, _MAX_OCTEON_DEVICES@GOTPAGE
Lloh23:
	ldr	x21, [x21, _MAX_OCTEON_DEVICES@GOTPAGEOFF]
	ldr	w8, [x21]
	cmp	w8, #1
	b.lt	LBB0_42
; %bb.38:
	mov	x22, #0
	mov	w23, #16
Lloh24:
	adrp	x24, _handshake@GOTPAGE
Lloh25:
	ldr	x24, [x24, _handshake@GOTPAGEOFF]
	mov	w25, #20
	b	LBB0_40
LBB0_39:                                ;   in Loop: Header=BB0_40 Depth=1
	add	x22, x22, #1
	add	x23, x23, #20
	cmp	x22, w8, sxtw
	b.ge	LBB0_42
LBB0_40:                                ; =>This Inner Loop Header: Depth=1
	ldr	x9, [x24]
	ldr	w10, [x9, x23]
	cbz	w10, LBB0_39
; %bb.41:                               ;   in Loop: Header=BB0_40 Depth=1
	ldr	x8, [x20, #8]
	madd	x8, x8, x25, x9
	str	wzr, [x8, #12]
	add	x0, x8, #8
	bl	_complete
	ldr	x8, [x24]
	ldr	x9, [x20, #8]
	madd	x0, x9, x25, x8
	str	wzr, [x0, #4]
	bl	_complete
	ldr	w8, [x21]
	b	LBB0_39
LBB0_42:
	mov	x0, x20
	bl	_octeon_delete_response_list
LBB0_43:
	mov	x0, x20
	bl	_MAX_OCTEON_INSTR_QUEUES
	cmp	w0, #1
	b.lt	LBB0_48
; %bb.44:
	mov	w21, #0
	b	LBB0_46
LBB0_45:                                ;   in Loop: Header=BB0_46 Depth=1
	add	w21, w21, #1
	mov	x0, x20
	bl	_MAX_OCTEON_INSTR_QUEUES
	cmp	w21, w0
	b.ge	LBB0_48
LBB0_46:                                ; =>This Inner Loop Header: Depth=1
	ldr	w22, [x20, #72]
	mov	x0, x21
	bl	_BIT_ULL
	tst	w0, w22
	b.eq	LBB0_45
; %bb.47:                               ;   in Loop: Header=BB0_46 Depth=1
	mov	x0, x20
	mov	x1, x21
	bl	_octeon_delete_instr_queue
	b	LBB0_45
LBB0_48:
	mov	x0, x20
	bl	_octeon_free_sc_buffer_pool
LBB0_49:
	mov	x0, x20
	bl	_octeon_delete_dispatch_list
	add	x0, x20, #64
	bl	_cancel_delayed_work_sync
LBB0_50:
	mov	x0, x20
	bl	_octeon_deregister_device
	mov	x21, x0
	ldr	x0, [x20, #56]
	bl	_atomic_read
Lloh26:
	adrp	x8, _FW_IS_PRELOADED@GOTPAGE
Lloh27:
	ldr	x8, [x8, _FW_IS_PRELOADED@GOTPAGEOFF]
Lloh28:
	ldr	w8, [x8]
	cmp	w0, w8
	b.ne	LBB0_52
; %bb.51:
	mov	x0, x20
	bl	_octeon_pci_flr
	b	LBB0_55
LBB0_52:
	mov	x0, x20
	bl	_OCTEON_CN6XXX
	cbnz	w0, LBB0_54
; %bb.53:
	cbnz	w21, LBB0_55
LBB0_54:
	ldr	x8, [x20, #24]
	mov	x0, x20
	blr	x8
LBB0_55:
	mov	x0, x20
	mov	w1, #0
	bl	_octeon_unmap_pci_barx
	mov	x0, x20
	mov	w1, #1
	bl	_octeon_unmap_pci_barx
LBB0_56:
	ldr	x0, [x20, #16]
	bl	_pci_clear_master
	ldr	x0, [x20, #16]
	bl	_pci_disable_device
LBB0_57:
	mov	x0, x19
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp], #80             ; 16-byte Folded Reload
	b	_tasklet_kill
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpAdd	Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpAdd	Lloh10, Lloh11
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpAdd	Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh16, Lloh17, Lloh18
	.loh AdrpLdrGotLdr	Lloh19, Lloh20, Lloh21
	.loh AdrpLdrGot	Lloh22, Lloh23
	.loh AdrpLdrGot	Lloh24, Lloh25
	.loh AdrpLdrGotLdr	Lloh26, Lloh27, Lloh28
	.cfi_endproc
	.section	__TEXT,__const
	.p2align	1
lJTI0_0:
	.short	(LBB0_48-LBB0_2)>>2
	.short	(LBB0_2-LBB0_2)>>2
	.short	(LBB0_42-LBB0_2)>>2
	.short	(LBB0_50-LBB0_2)>>2
	.short	(LBB0_56-LBB0_2)>>2
	.short	(LBB0_28-LBB0_2)>>2
	.short	(LBB0_30-LBB0_2)>>2
	.short	(LBB0_4-LBB0_2)>>2
	.short	(LBB0_32-LBB0_2)>>2
	.short	(LBB0_17-LBB0_2)>>2
	.short	(LBB0_43-LBB0_2)>>2
	.short	(LBB0_3-LBB0_2)>>2
	.short	(LBB0_32-LBB0_2)>>2
	.short	(LBB0_49-LBB0_2)>>2
	.short	(LBB0_2-LBB0_2)>>2
	.short	(LBB0_3-LBB0_2)>>2
                                        ; -- End function
	.comm	_CVM_DRV_INVALID_APP,4,2        ; @CVM_DRV_INVALID_APP
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Device state is now %s\n"

	.comm	_HZ,4,2                         ; @HZ
l_.str.1:                               ; @.str.1
	.asciz	"IQ had pending instructions\n"

l_.str.2:                               ; @.str.2
	.asciz	"There were pending requests\n"

l_.str.3:                               ; @.str.3
	.asciz	"OQ had pending packets\n"

	.comm	_OCTEON_ALL_INTR,4,2            ; @OCTEON_ALL_INTR
	.comm	_LIO_FLAG_MSI_ENABLED,4,2       ; @LIO_FLAG_MSI_ENABLED
	.comm	_MAX_OCTEON_DEVICES,4,2         ; @MAX_OCTEON_DEVICES
	.comm	_handshake,8,3                  ; @handshake
	.comm	_FW_IS_PRELOADED,4,2            ; @FW_IS_PRELOADED
	.no_dead_strip	_octeon_destroy_resources
.subsections_via_symbols
