	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function sbp2scsi_abort
_sbp2scsi_abort:                        ## @sbp2scsi_abort
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r14
	pushq	%rbx
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movq	%rdi, %rbx
	movq	(%rdi), %rax
	movq	(%rax), %rax
	movq	(%rax), %rax
	movq	(%rax), %r14
	leaq	L_.str(%rip), %rdi
	callq	_SBP2_INFO
	movq	%rbx, %rdi
	callq	_scsi_print_command
	movq	%r14, %rdi
	callq	_sbp2util_node_is_available
	testq	%rax, %rax
	je	LBB0_5
## %bb.1:
	movq	%r14, %rdi
	movl	$1, %esi
	callq	_sbp2_agent_reset
	movq	%r14, %rdi
	callq	_spin_lock_irqsave
	movq	%r14, %rdi
	movq	%rbx, %rsi
	callq	_sbp2util_find_command_for_SCpnt
	testq	%rax, %rax
	je	LBB0_4
## %bb.2:
	movq	%rax, %rbx
	movq	%r14, %rdi
	movq	%rax, %rsi
	callq	_sbp2util_mark_command_completed
	movq	(%rbx), %rdi
	testq	%rdi, %rdi
	je	LBB0_4
## %bb.3:
	movq	_DID_ABORT@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	shll	$16, %eax
	movl	%eax, (%rdi)
	callq	*8(%rbx)
LBB0_4:
	movq	%r14, %rdi
	callq	_spin_unlock_irqrestore
	movq	_DID_BUS_BUSY@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r14, %rdi
	callq	_sbp2scsi_complete_all_commands
LBB0_5:
	movq	_SUCCESS@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"aborting sbp2 command"

	.comm	_DID_ABORT,4,2                  ## @DID_ABORT
	.comm	_DID_BUS_BUSY,4,2               ## @DID_BUS_BUSY
	.comm	_SUCCESS,4,2                    ## @SUCCESS
	.no_dead_strip	_sbp2scsi_abort
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function sbp2scsi_abort
_sbp2scsi_abort:                        ; @sbp2scsi_abort
	.cfi_startproc
; %bb.0:
	stp	x20, x19, [sp, #-32]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 32
	stp	x29, x30, [sp, #16]             ; 16-byte Folded Spill
	add	x29, sp, #16
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	mov	x20, x0
	ldr	x8, [x0]
	ldr	x8, [x8]
	ldr	x8, [x8]
	ldr	x19, [x8]
Lloh0:
	adrp	x0, l_.str@PAGE
Lloh1:
	add	x0, x0, l_.str@PAGEOFF
	bl	_SBP2_INFO
	mov	x0, x20
	bl	_scsi_print_command
	mov	x0, x19
	bl	_sbp2util_node_is_available
	cbz	x0, LBB0_5
; %bb.1:
	mov	x0, x19
	mov	w1, #1
	bl	_sbp2_agent_reset
	mov	x0, x19
	bl	_spin_lock_irqsave
	mov	x0, x19
	mov	x1, x20
	bl	_sbp2util_find_command_for_SCpnt
	cbz	x0, LBB0_4
; %bb.2:
	mov	x20, x0
	mov	x0, x19
	mov	x1, x20
	bl	_sbp2util_mark_command_completed
	ldr	x0, [x20]
	cbz	x0, LBB0_4
; %bb.3:
Lloh2:
	adrp	x8, _DID_ABORT@GOTPAGE
Lloh3:
	ldr	x8, [x8, _DID_ABORT@GOTPAGEOFF]
Lloh4:
	ldr	w8, [x8]
	lsl	w8, w8, #16
	str	w8, [x0]
	ldr	x8, [x20, #8]
	blr	x8
LBB0_4:
	mov	x0, x19
	bl	_spin_unlock_irqrestore
Lloh5:
	adrp	x8, _DID_BUS_BUSY@GOTPAGE
Lloh6:
	ldr	x8, [x8, _DID_BUS_BUSY@GOTPAGEOFF]
Lloh7:
	ldr	w1, [x8]
	mov	x0, x19
	bl	_sbp2scsi_complete_all_commands
LBB0_5:
Lloh8:
	adrp	x8, _SUCCESS@GOTPAGE
Lloh9:
	ldr	x8, [x8, _SUCCESS@GOTPAGEOFF]
Lloh10:
	ldr	w0, [x8]
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"aborting sbp2 command"

	.comm	_DID_ABORT,4,2                  ; @DID_ABORT
	.comm	_DID_BUS_BUSY,4,2               ; @DID_BUS_BUSY
	.comm	_SUCCESS,4,2                    ; @SUCCESS
	.no_dead_strip	_sbp2scsi_abort
.subsections_via_symbols
