	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function fetch_scsi_inquiry
_fetch_scsi_inquiry:                    ## @fetch_scsi_inquiry
	.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
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %r14
	movq	%rdi, %r12
	callq	_cam_getccb
	testq	%rax, %rax
	je	LBB0_6
## %bb.1:
	movq	%rax, %rbx
	movq	%rax, %rdi
	callq	_CCB_CLEAR_ALL_EXCEPT_HDR
	movl	$1, %edi
	movl	$4, %esi
	callq	_calloc
	testq	%rax, %rax
	je	LBB0_5
## %bb.2:
	movq	%rax, %r15
	movq	_MSG_SIMPLE_Q_TAG@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movq	_SHORT_INQUIRY_LENGTH@GOTPCREL(%rip), %rax
	movl	(%rax), %r9d
	movq	_SSD_FULL_SIZE@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movq	%rbx, %rdi
	movl	$1, %esi
	xorl	%edx, %edx
	movq	%r15, %r8
	pushq	$5000                           ## imm = 0x1388
	pushq	%rax
	pushq	$0
	pushq	$0
	callq	_scsi_inquiry
	addq	$32, %rsp
	movq	_CAM_DEV_QFRZDIS@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	orl	%eax, 4(%rbx)
	movq	%r12, %rdi
	movq	%rbx, %rsi
	callq	_cam_send_ccb
	testq	%rax, %rax
	js	LBB0_7
## %bb.3:
	movq	_CAM_STATUS_MASK@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	andl	(%rbx), %eax
	movq	_CAM_REQ_CMP@GOTPCREL(%rip), %rcx
	cmpl	(%rcx), %eax
	jne	LBB0_8
## %bb.4:
	movq	%rbx, %rdi
	callq	_cam_freeccb
	movq	%r14, %rdi
	movq	%r15, %rsi
	callq	_format_scsi_inquiry
	movq	%r15, %rdi
	callq	_free
	xorl	%r14d, %r14d
	jmp	LBB0_10
LBB0_5:
	movq	%rbx, %rdi
	callq	_cam_freeccb
LBB0_6:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
LBB0_9:
	movl	(%rax), %r14d
LBB0_10:
	movl	%r14d, %eax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_7:
	movq	_errno@GOTPCREL(%rip), %rax
	movl	(%rax), %r14d
	movq	%r15, %rdi
	callq	_free
	movq	%rbx, %rdi
	callq	_cam_freeccb
	jmp	LBB0_10
LBB0_8:
	movq	%r15, %rdi
	callq	_free
	movq	%rbx, %rdi
	callq	_cam_freeccb
	movq	_EIO@GOTPCREL(%rip), %rax
	jmp	LBB0_9
	.cfi_endproc
                                        ## -- End function
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.comm	_MSG_SIMPLE_Q_TAG,4,2           ## @MSG_SIMPLE_Q_TAG
	.comm	_SHORT_INQUIRY_LENGTH,4,2       ## @SHORT_INQUIRY_LENGTH
	.comm	_SSD_FULL_SIZE,4,2              ## @SSD_FULL_SIZE
	.comm	_CAM_DEV_QFRZDIS,4,2            ## @CAM_DEV_QFRZDIS
	.comm	_errno,4,2                      ## @errno
	.comm	_CAM_STATUS_MASK,4,2            ## @CAM_STATUS_MASK
	.comm	_CAM_REQ_CMP,4,2                ## @CAM_REQ_CMP
	.comm	_EIO,4,2                        ## @EIO
	.no_dead_strip	_fetch_scsi_inquiry
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function fetch_scsi_inquiry
_fetch_scsi_inquiry:                    ; @fetch_scsi_inquiry
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.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
	mov	x20, x1
	mov	x22, x0
	bl	_cam_getccb
	cbz	x0, LBB0_6
; %bb.1:
	mov	x19, x0
	bl	_CCB_CLEAR_ALL_EXCEPT_HDR
	mov	w0, #1
	mov	w1, #4
	bl	_calloc
	cbz	x0, LBB0_5
; %bb.2:
	mov	x21, x0
Lloh0:
	adrp	x8, _MSG_SIMPLE_Q_TAG@GOTPAGE
Lloh1:
	ldr	x8, [x8, _MSG_SIMPLE_Q_TAG@GOTPAGEOFF]
Lloh2:
	ldr	w3, [x8]
Lloh3:
	adrp	x8, _SHORT_INQUIRY_LENGTH@GOTPAGE
Lloh4:
	ldr	x8, [x8, _SHORT_INQUIRY_LENGTH@GOTPAGEOFF]
Lloh5:
	ldr	w5, [x8]
Lloh6:
	adrp	x8, _SSD_FULL_SIZE@GOTPAGE
Lloh7:
	ldr	x8, [x8, _SSD_FULL_SIZE@GOTPAGEOFF]
Lloh8:
	ldr	w8, [x8]
	mov	w9, #5000
	stp	w8, w9, [sp]
	mov	x0, x19
	mov	w1, #1
	mov	x2, #0
	mov	x4, x21
	mov	w6, #0
	mov	w7, #0
	bl	_scsi_inquiry
Lloh9:
	adrp	x8, _CAM_DEV_QFRZDIS@GOTPAGE
Lloh10:
	ldr	x8, [x8, _CAM_DEV_QFRZDIS@GOTPAGEOFF]
Lloh11:
	ldr	w8, [x8]
	ldr	w9, [x19, #4]
	orr	w8, w9, w8
	str	w8, [x19, #4]
	mov	x0, x22
	mov	x1, x19
	bl	_cam_send_ccb
	tbnz	x0, #63, LBB0_9
; %bb.3:
	ldr	w8, [x19]
Lloh12:
	adrp	x9, _CAM_STATUS_MASK@GOTPAGE
Lloh13:
	ldr	x9, [x9, _CAM_STATUS_MASK@GOTPAGEOFF]
Lloh14:
	ldr	w9, [x9]
	and	w8, w9, w8
Lloh15:
	adrp	x9, _CAM_REQ_CMP@GOTPAGE
Lloh16:
	ldr	x9, [x9, _CAM_REQ_CMP@GOTPAGEOFF]
Lloh17:
	ldr	w9, [x9]
	cmp	w8, w9
	b.ne	LBB0_10
; %bb.4:
	mov	x0, x19
	bl	_cam_freeccb
	mov	x0, x20
	mov	x1, x21
	bl	_format_scsi_inquiry
	mov	x0, x21
	bl	_free
	mov	w20, #0
	b	LBB0_8
LBB0_5:
	mov	x0, x19
	bl	_cam_freeccb
LBB0_6:
Lloh18:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh19:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
LBB0_7:
	ldr	w20, [x8]
LBB0_8:
	mov	x0, x20
	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
	add	sp, sp, #64
	ret
LBB0_9:
Lloh20:
	adrp	x8, _errno@GOTPAGE
Lloh21:
	ldr	x8, [x8, _errno@GOTPAGEOFF]
Lloh22:
	ldr	w20, [x8]
	mov	x0, x21
	bl	_free
	mov	x0, x19
	bl	_cam_freeccb
	b	LBB0_8
LBB0_10:
	mov	x0, x21
	bl	_free
	mov	x0, x19
	bl	_cam_freeccb
Lloh23:
	adrp	x8, _EIO@GOTPAGE
Lloh24:
	ldr	x8, [x8, _EIO@GOTPAGEOFF]
	b	LBB0_7
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGot	Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.loh AdrpLdrGot	Lloh23, Lloh24
	.cfi_endproc
                                        ; -- End function
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.comm	_MSG_SIMPLE_Q_TAG,4,2           ; @MSG_SIMPLE_Q_TAG
	.comm	_SHORT_INQUIRY_LENGTH,4,2       ; @SHORT_INQUIRY_LENGTH
	.comm	_SSD_FULL_SIZE,4,2              ; @SSD_FULL_SIZE
	.comm	_CAM_DEV_QFRZDIS,4,2            ; @CAM_DEV_QFRZDIS
	.comm	_errno,4,2                      ; @errno
	.comm	_CAM_STATUS_MASK,4,2            ; @CAM_STATUS_MASK
	.comm	_CAM_REQ_CMP,4,2                ; @CAM_REQ_CMP
	.comm	_EIO,4,2                        ; @EIO
	.no_dead_strip	_fetch_scsi_inquiry
.subsections_via_symbols
