	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function nvme_tcp_setup_cmd_pdu
_nvme_tcp_setup_cmd_pdu:                ## @nvme_tcp_setup_cmd_pdu
	.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
	subq	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %r15
	movq	%rdi, %rbx
	movq	%rsi, %rdi
	callq	_blk_mq_rq_to_pdu
	movq	%rax, %r13
	movq	56(%rax), %r12
	movq	64(%rax), %r14
	movq	%r12, %rdi
	callq	_nvme_tcp_hdgst_len
	movq	%rax, -56(%rbp)                 ## 8-byte Spill
	leaq	32(%r14), %rdx
	movq	%rbx, %rdi
	movq	%r15, %rsi
	callq	_nvme_setup_cmd
	movq	%rax, %rbx
	testq	%rax, %rax
	jne	LBB0_16
## %bb.1:
	movq	%r14, -48(%rbp)                 ## 8-byte Spill
	movq	%r12, %rbx
	movq	-56(%rbp), %r14                 ## 8-byte Reload
	movq	_NVME_TCP_SEND_CMD_PDU@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 48(%r13)
	movq	$0, (%r13)
	xorps	%xmm0, %xmm0
	movups	%xmm0, 24(%r13)
	movq	$0, 40(%r13)
	movq	%r15, %rdi
	callq	_blk_rq_payload_bytes
	movq	%rax, 8(%r13)
	movq	(%r15), %rax
	movq	%rax, 16(%r13)
	movq	%r15, %rdi
	callq	_rq_data_dir
	movq	_WRITE@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_3
## %bb.2:
	movq	%r15, %r12
	movq	8(%r13), %r15
	movq	%rbx, %rdi
	callq	_nvme_tcp_inline_data_size
	cmpq	%rax, %r15
	movq	%r12, %r15
	jle	LBB0_5
LBB0_3:
	cmpq	$0, 16(%r13)
	movq	%r14, %r12
	movq	%rbx, %r14
	movq	-48(%rbp), %rbx                 ## 8-byte Reload
	je	LBB0_6
## %bb.4:
	movq	_READ@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r13, %rdi
	callq	_nvme_tcp_init_iter
	jmp	LBB0_6
LBB0_5:
	movq	8(%r13), %rax
	movq	%rax, (%r13)
	movq	%r14, %r12
	movq	%rbx, %r14
	movq	-48(%rbp), %rbx                 ## 8-byte Reload
LBB0_6:
	movq	_nvme_tcp_cmd@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 24(%rbx)
	movl	$0, 20(%rbx)
	cmpq	$0, 16(%r14)
	je	LBB0_10
## %bb.7:
	movq	_NVME_TCP_F_HDGST@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 20(%rbx)
	cmpq	$0, 8(%r14)
	jne	LBB0_8
	jmp	LBB0_12
LBB0_10:
	xorl	%eax, %eax
	cmpq	$0, 8(%r14)
	je	LBB0_12
LBB0_8:
	cmpq	$0, (%r13)
	je	LBB0_12
## %bb.9:
	movq	_NVME_TCP_F_DDGST@GOTPCREL(%rip), %rcx
	orl	(%rcx), %eax
	movl	%eax, 20(%rbx)
	movq	%r14, %rdi
	callq	_nvme_tcp_ddgst_len
	jmp	LBB0_13
LBB0_12:
	xorl	%eax, %eax
LBB0_13:
	movl	$40, (%rbx)
	movq	(%r13), %rcx
	leaq	40(%r12), %rdx
	testq	%rcx, %rcx
	cmoveq	%rcx, %rdx
	movq	%rdx, 8(%rbx)
	leaq	(%rax,%r12), %rdi
	addq	$40, %rdi
	addq	%rcx, %rdi
	callq	_cpu_to_le32
	movl	%eax, 16(%rbx)
	movq	%r14, %rdi
	movq	%r15, %rsi
	callq	_nvme_tcp_map_data
	movq	%rax, %rbx
	movq	%rax, %rdi
	callq	_unlikely
	testq	%rax, %rax
	je	LBB0_15
## %bb.14:
	movq	%r15, %rdi
	callq	_nvme_cleanup_cmd
	movq	(%r14), %rax
	movl	(%rax), %edi
	leaq	L_.str(%rip), %rsi
	movq	%rbx, %rdx
	callq	_dev_err
	jmp	LBB0_16
LBB0_15:
	xorl	%ebx, %ebx
LBB0_16:
	movq	%rbx, %rax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_NVME_TCP_SEND_CMD_PDU,4,2      ## @NVME_TCP_SEND_CMD_PDU
	.comm	_WRITE,8,3                      ## @WRITE
	.comm	_READ,4,2                       ## @READ
	.comm	_nvme_tcp_cmd,4,2               ## @nvme_tcp_cmd
	.comm	_NVME_TCP_F_HDGST,4,2           ## @NVME_TCP_F_HDGST
	.comm	_NVME_TCP_F_DDGST,4,2           ## @NVME_TCP_F_DDGST
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Failed to map data (%d)\n"

	.no_dead_strip	_nvme_tcp_setup_cmd_pdu
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function nvme_tcp_setup_cmd_pdu
_nvme_tcp_setup_cmd_pdu:                ; @nvme_tcp_setup_cmd_pdu
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.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
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	mov	x19, x1
	mov	x23, x0
	mov	x0, x1
	bl	_blk_mq_rq_to_pdu
	mov	x21, x0
	ldp	x20, x24, [x0, #56]
	mov	x0, x20
	bl	_nvme_tcp_hdgst_len
	mov	x22, x0
	add	x2, x24, #32
	mov	x0, x23
	mov	x1, x19
	bl	_nvme_setup_cmd
	mov	x23, x0
	cbnz	x0, LBB0_15
; %bb.1:
Lloh0:
	adrp	x8, _NVME_TCP_SEND_CMD_PDU@GOTPAGE
Lloh1:
	ldr	x8, [x8, _NVME_TCP_SEND_CMD_PDU@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	str	w8, [x21, #48]
	str	xzr, [x21]
	stp	xzr, xzr, [x21, #32]
	str	xzr, [x21, #24]
	mov	x0, x19
	bl	_blk_rq_payload_bytes
	ldr	x8, [x19]
	stp	x0, x8, [x21, #8]
	mov	x0, x19
	bl	_rq_data_dir
Lloh3:
	adrp	x8, _WRITE@GOTPAGE
Lloh4:
	ldr	x8, [x8, _WRITE@GOTPAGEOFF]
Lloh5:
	ldr	x8, [x8]
	cmp	x0, x8
	b.ne	LBB0_3
; %bb.2:
	ldr	x23, [x21, #8]
	mov	x0, x20
	bl	_nvme_tcp_inline_data_size
	cmp	x23, x0
	b.le	LBB0_5
LBB0_3:
	ldr	x8, [x21, #16]
	cbz	x8, LBB0_6
; %bb.4:
Lloh6:
	adrp	x8, _READ@GOTPAGE
Lloh7:
	ldr	x8, [x8, _READ@GOTPAGEOFF]
Lloh8:
	ldr	w1, [x8]
	mov	x0, x21
	bl	_nvme_tcp_init_iter
	b	LBB0_6
LBB0_5:
	ldr	x8, [x21, #8]
	str	x8, [x21]
LBB0_6:
Lloh9:
	adrp	x8, _nvme_tcp_cmd@GOTPAGE
Lloh10:
	ldr	x8, [x8, _nvme_tcp_cmd@GOTPAGEOFF]
Lloh11:
	ldr	w8, [x8]
	stp	wzr, w8, [x24, #20]
	ldr	x8, [x20, #16]
	cbz	x8, LBB0_8
; %bb.7:
Lloh12:
	adrp	x8, _NVME_TCP_F_HDGST@GOTPAGE
Lloh13:
	ldr	x8, [x8, _NVME_TCP_F_HDGST@GOTPAGEOFF]
Lloh14:
	ldr	w8, [x8]
	str	w8, [x24, #20]
LBB0_8:
	ldr	x9, [x20, #8]
	cbz	x9, LBB0_11
; %bb.9:
	ldr	x9, [x21]
	cbz	x9, LBB0_11
; %bb.10:
Lloh15:
	adrp	x9, _NVME_TCP_F_DDGST@GOTPAGE
Lloh16:
	ldr	x9, [x9, _NVME_TCP_F_DDGST@GOTPAGEOFF]
Lloh17:
	ldr	w9, [x9]
	orr	w8, w8, w9
	str	w8, [x24, #20]
	mov	x0, x20
	bl	_nvme_tcp_ddgst_len
	b	LBB0_12
LBB0_11:
	mov	x0, #0
LBB0_12:
	mov	w8, #40
	str	w8, [x24]
	ldr	x8, [x21]
	add	x9, x22, #40
	cmp	x8, #0
	csel	x10, xzr, x9, eq
	str	x10, [x24, #8]
	add	x9, x0, x9
	add	x0, x9, x8
	bl	_cpu_to_le32
	str	w0, [x24, #16]
	mov	x0, x20
	mov	x1, x19
	bl	_nvme_tcp_map_data
	mov	x23, x0
	bl	_unlikely
	cbz	x0, LBB0_14
; %bb.13:
	mov	x0, x19
	bl	_nvme_cleanup_cmd
	ldr	x8, [x20]
	ldr	w0, [x8]
Lloh18:
	adrp	x1, l_.str@PAGE
Lloh19:
	add	x1, x1, l_.str@PAGEOFF
	mov	x2, x23
	bl	_dev_err
	b	LBB0_15
LBB0_14:
	mov	x23, #0
LBB0_15:
	mov	x0, x23
	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
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpAdd	Lloh18, Lloh19
	.cfi_endproc
                                        ; -- End function
	.comm	_NVME_TCP_SEND_CMD_PDU,4,2      ; @NVME_TCP_SEND_CMD_PDU
	.comm	_WRITE,8,3                      ; @WRITE
	.comm	_READ,4,2                       ; @READ
	.comm	_nvme_tcp_cmd,4,2               ; @nvme_tcp_cmd
	.comm	_NVME_TCP_F_HDGST,4,2           ; @NVME_TCP_F_HDGST
	.comm	_NVME_TCP_F_DDGST,4,2           ; @NVME_TCP_F_DDGST
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Failed to map data (%d)\n"

	.no_dead_strip	_nvme_tcp_setup_cmd_pdu
.subsections_via_symbols
