	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_octeon_send_soft_command       ## -- Begin function octeon_send_soft_command
	.p2align	4, 0x90
_octeon_send_soft_command:              ## @octeon_send_soft_command
	.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	$16, %rsp
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %rbx
	movq	%rdi, %r14
	movq	8(%rdi), %rax
	movq	(%rsi), %rdx
	movq	(%rax,%rdx,8), %rax
	cmpl	$0, (%rax)
	je	LBB0_1
## %bb.3:
	movq	%r14, %rdi
	callq	_OCTEON_CN23XX_PF
	testq	%rax, %rax
	jne	LBB0_5
## %bb.4:
	movq	%r14, %rdi
	callq	_OCTEON_CN23XX_VF
	testq	%rax, %rax
	je	LBB0_9
LBB0_5:
	cmpq	$0, 64(%rbx)
	je	LBB0_7
## %bb.6:
	xorl	%edi, %edi
	cmpq	$0, 96(%rbx)
	sete	%dil
	callq	_WARN_ON
	movq	96(%rbx), %rax
	movq	%rax, 56(%rbx)
LBB0_7:
	leaq	64(%rbx), %r15
	cmpq	$0, 48(%rbx)
	je	LBB0_13
## %bb.8:
	xorl	%edi, %edi
	cmpq	$0, 80(%rbx)
	sete	%dil
	callq	_WARN_ON
	xorl	%edi, %edi
	cmpq	$0, 88(%rbx)
	sete	%dil
	callq	_WARN_ON
	movq	_COMPLETION_WORD_INIT@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	88(%rbx), %rcx
	movq	%rax, (%rcx)
	movq	80(%rbx), %rax
	movq	%rax, 40(%rbx)
LBB0_13:
	movq	(%r15), %r15
	movq	_jiffies@GOTPCREL(%rip), %rax
	movq	(%rax), %r12
	movq	_LIO_SC_MAX_TMO_MS@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_msecs_to_jiffies
	addq	%r12, %rax
	movq	%rax, 72(%rbx)
	movq	(%rbx), %rsi
	leaq	8(%rbx), %rcx
	movq	_REQTYPE_SOFT_COMMAND@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, (%rsp)
	movq	%r14, %rdi
	movl	$1, %edx
	movq	%rbx, %r8
	movq	%r15, %r9
	callq	_octeon_send_command
	jmp	LBB0_2
LBB0_1:
	movq	(%r14), %rdi
	leaq	L_.str(%rip), %rsi
	callq	_dev_err
	movq	(%rbx), %rsi
	movq	_instr_dropped@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r14, %rdi
	movl	$1, %ecx
	callq	_INCR_INSTRQUEUE_PKT_COUNT
	movq	_IQ_SEND_FAILED@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
LBB0_2:
	addq	$16, %rsp
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_9:
	cmpq	$0, 32(%rbx)
	je	LBB0_11
## %bb.10:
	xorl	%edi, %edi
	cmpq	$0, 96(%rbx)
	sete	%dil
	callq	_WARN_ON
	movq	96(%rbx), %rax
	movq	%rax, 24(%rbx)
LBB0_11:
	leaq	32(%rbx), %r15
	cmpq	$0, 16(%rbx)
	je	LBB0_13
## %bb.12:
	xorl	%edi, %edi
	cmpq	$0, 80(%rbx)
	sete	%dil
	callq	_WARN_ON
	xorl	%edi, %edi
	cmpq	$0, 88(%rbx)
	sete	%dil
	callq	_WARN_ON
	movq	_COMPLETION_WORD_INIT@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	88(%rbx), %rcx
	movq	%rax, (%rcx)
	movq	80(%rbx), %rax
	movq	%rax, 8(%rbx)
	jmp	LBB0_13
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Soft commands are not allowed on Queue %d\n"

	.comm	_instr_dropped,4,2              ## @instr_dropped
	.comm	_IQ_SEND_FAILED,4,2             ## @IQ_SEND_FAILED
	.comm	_COMPLETION_WORD_INIT,8,3       ## @COMPLETION_WORD_INIT
	.comm	_jiffies,8,3                    ## @jiffies
	.comm	_LIO_SC_MAX_TMO_MS,4,2          ## @LIO_SC_MAX_TMO_MS
	.comm	_REQTYPE_SOFT_COMMAND,4,2       ## @REQTYPE_SOFT_COMMAND
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_octeon_send_soft_command       ; -- Begin function octeon_send_soft_command
	.p2align	2
_octeon_send_soft_command:              ; @octeon_send_soft_command
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.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	x20, x1
	mov	x19, x0
	ldr	x8, [x0, #8]
	ldr	x2, [x1]
	ldr	x8, [x8, x2, lsl #3]
	ldr	w8, [x8]
	cbz	w8, LBB0_8
; %bb.1:
	mov	x0, x19
	bl	_OCTEON_CN23XX_PF
	cbnz	x0, LBB0_3
; %bb.2:
	mov	x0, x19
	bl	_OCTEON_CN23XX_VF
	cbz	x0, LBB0_9
LBB0_3:
	mov	x21, x20
	ldr	x8, [x21, #64]!
	cbz	x8, LBB0_5
; %bb.4:
	ldr	x8, [x20, #96]
	cmp	x8, #0
	cset	w0, eq
	bl	_WARN_ON
	ldr	x8, [x20, #96]
	str	x8, [x20, #56]
LBB0_5:
	ldr	x8, [x20, #48]
	cbz	x8, LBB0_7
; %bb.6:
	ldr	x8, [x20, #80]
	cmp	x8, #0
	cset	w0, eq
	bl	_WARN_ON
	ldr	x8, [x20, #88]
	cmp	x8, #0
	cset	w0, eq
	bl	_WARN_ON
Lloh0:
	adrp	x8, _COMPLETION_WORD_INIT@GOTPAGE
Lloh1:
	ldr	x8, [x8, _COMPLETION_WORD_INIT@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	ldp	x10, x9, [x20, #80]
	str	x8, [x9]
	str	x10, [x20, #40]
LBB0_7:
	ldr	x21, [x21]
Lloh3:
	adrp	x8, _jiffies@GOTPAGE
Lloh4:
	ldr	x8, [x8, _jiffies@GOTPAGEOFF]
Lloh5:
	ldr	x22, [x8]
Lloh6:
	adrp	x8, _LIO_SC_MAX_TMO_MS@GOTPAGE
Lloh7:
	ldr	x8, [x8, _LIO_SC_MAX_TMO_MS@GOTPAGEOFF]
Lloh8:
	ldr	w0, [x8]
	bl	_msecs_to_jiffies
	add	x8, x0, x22
	str	x8, [x20, #72]
	ldr	x1, [x20]
	add	x3, x20, #8
Lloh9:
	adrp	x8, _REQTYPE_SOFT_COMMAND@GOTPAGE
Lloh10:
	ldr	x8, [x8, _REQTYPE_SOFT_COMMAND@GOTPAGEOFF]
Lloh11:
	ldr	w6, [x8]
	mov	x0, x19
	mov	w2, #1
	mov	x4, x20
	mov	x5, x21
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	b	_octeon_send_command
LBB0_8:
	ldr	x0, [x19]
Lloh12:
	adrp	x1, l_.str@PAGE
Lloh13:
	add	x1, x1, l_.str@PAGEOFF
	bl	_dev_err
	ldr	x1, [x20]
Lloh14:
	adrp	x8, _instr_dropped@GOTPAGE
Lloh15:
	ldr	x8, [x8, _instr_dropped@GOTPAGEOFF]
Lloh16:
	ldr	w2, [x8]
	mov	x0, x19
	mov	w3, #1
	bl	_INCR_INSTRQUEUE_PKT_COUNT
Lloh17:
	adrp	x8, _IQ_SEND_FAILED@GOTPAGE
Lloh18:
	ldr	x8, [x8, _IQ_SEND_FAILED@GOTPAGEOFF]
Lloh19:
	ldr	w0, [x8]
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	ret
LBB0_9:
	mov	x21, x20
	ldr	x8, [x21, #32]!
	cbz	x8, LBB0_11
; %bb.10:
	ldr	x8, [x20, #96]
	cmp	x8, #0
	cset	w0, eq
	bl	_WARN_ON
	ldr	x8, [x20, #96]
	str	x8, [x20, #24]
LBB0_11:
	ldr	x8, [x20, #16]
	cbz	x8, LBB0_7
; %bb.12:
	ldr	x8, [x20, #80]
	cmp	x8, #0
	cset	w0, eq
	bl	_WARN_ON
	ldr	x8, [x20, #88]
	cmp	x8, #0
	cset	w0, eq
	bl	_WARN_ON
Lloh20:
	adrp	x8, _COMPLETION_WORD_INIT@GOTPAGE
Lloh21:
	ldr	x8, [x8, _COMPLETION_WORD_INIT@GOTPAGEOFF]
Lloh22:
	ldr	x8, [x8]
	ldp	x10, x9, [x20, #80]
	str	x8, [x9]
	str	x10, [x20, #8]
	b	LBB0_7
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Soft commands are not allowed on Queue %d\n"

	.comm	_instr_dropped,4,2              ; @instr_dropped
	.comm	_IQ_SEND_FAILED,4,2             ; @IQ_SEND_FAILED
	.comm	_COMPLETION_WORD_INIT,8,3       ; @COMPLETION_WORD_INIT
	.comm	_jiffies,8,3                    ; @jiffies
	.comm	_LIO_SC_MAX_TMO_MS,4,2          ; @LIO_SC_MAX_TMO_MS
	.comm	_REQTYPE_SOFT_COMMAND,4,2       ; @REQTYPE_SOFT_COMMAND
.subsections_via_symbols
