	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ata_scsi_rbuf_get
_ata_scsi_rbuf_get:                     ## @ata_scsi_rbuf_get
	.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
	movl	%esi, %ebx
	movq	%rdi, %r14
	movq	(%rdx), %rsi
	movq	_ata_scsi_rbuf_lock@GOTPCREL(%rip), %rdi
	callq	_spin_lock_irqsave
	movq	_ata_scsi_rbuf@GOTPCREL(%rip), %r15
	movq	(%r15), %rdi
	movq	_ATA_SCSI_RBUF_SIZE@GOTPCREL(%rip), %r12
	movl	(%r12), %edx
	xorl	%esi, %esi
	callq	_memset
	testl	%ebx, %ebx
	je	LBB0_2
## %bb.1:
	movq	%r14, %rdi
	callq	_scsi_sglist
	movl	%eax, %ebx
	movq	%r14, %rdi
	callq	_scsi_sg_count
	movq	(%r15), %rdx
	movl	(%r12), %ecx
	movl	%ebx, %edi
	movl	%eax, %esi
	callq	_sg_copy_to_buffer
LBB0_2:
	movq	(%r15), %rax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_ata_scsi_rbuf_lock,4,2         ## @ata_scsi_rbuf_lock
	.comm	_ata_scsi_rbuf,8,3              ## @ata_scsi_rbuf
	.comm	_ATA_SCSI_RBUF_SIZE,4,2         ## @ATA_SCSI_RBUF_SIZE
	.no_dead_strip	_ata_scsi_rbuf_get
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ata_scsi_rbuf_get
_ata_scsi_rbuf_get:                     ; @ata_scsi_rbuf_get
	.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	x1, [x2]
Lloh0:
	adrp	x0, _ata_scsi_rbuf_lock@GOTPAGE
Lloh1:
	ldr	x0, [x0, _ata_scsi_rbuf_lock@GOTPAGEOFF]
	bl	_spin_lock_irqsave
Lloh2:
	adrp	x21, _ata_scsi_rbuf@GOTPAGE
Lloh3:
	ldr	x21, [x21, _ata_scsi_rbuf@GOTPAGEOFF]
	ldr	x0, [x21]
Lloh4:
	adrp	x22, _ATA_SCSI_RBUF_SIZE@GOTPAGE
Lloh5:
	ldr	x22, [x22, _ATA_SCSI_RBUF_SIZE@GOTPAGEOFF]
	ldr	w2, [x22]
	mov	w1, #0
	bl	_memset
	cbz	w20, LBB0_2
; %bb.1:
	mov	x0, x19
	bl	_scsi_sglist
	mov	x20, x0
	mov	x0, x19
	bl	_scsi_sg_count
	mov	x1, x0
	ldr	x2, [x21]
	ldr	w3, [x22]
	mov	x0, x20
	bl	_sg_copy_to_buffer
LBB0_2:
	ldr	x0, [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
	ret
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.cfi_endproc
                                        ; -- End function
	.comm	_ata_scsi_rbuf_lock,4,2         ; @ata_scsi_rbuf_lock
	.comm	_ata_scsi_rbuf,8,3              ; @ata_scsi_rbuf
	.comm	_ATA_SCSI_RBUF_SIZE,4,2         ; @ATA_SCSI_RBUF_SIZE
	.no_dead_strip	_ata_scsi_rbuf_get
.subsections_via_symbols
