	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function s5p_make_sg_cpy
_s5p_make_sg_cpy:                       ## @s5p_make_sg_cpy
	.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
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdx, %r13
	movq	%rsi, %rbx
	movq	%rdi, %r15
	movq	_GFP_ATOMIC@GOTPCREL(%rip), %r14
	movl	(%r14), %esi
	movl	$4, %edi
	callq	_kmalloc
	movq	%rax, (%r13)
	testq	%rax, %rax
	je	LBB0_1
## %bb.2:
	movq	%rbx, -48(%rbp)                 ## 8-byte Spill
	movq	(%r15), %rax
	movl	(%rax), %edi
	movq	_AES_BLOCK_SIZE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_ALIGN
	movl	%eax, %r12d
	movl	(%r14), %ebx
	movl	%eax, %edi
	callq	_get_order
	movl	%ebx, %edi
	movl	%eax, %esi
	callq	___get_free_pages
	testq	%rax, %rax
	je	LBB0_3
## %bb.4:
	movq	%rax, %r14
	movq	(%r15), %rax
	movl	(%rax), %edx
	xorl	%ebx, %ebx
	movq	%r14, %rdi
	movq	-48(%rbp), %rsi                 ## 8-byte Reload
	xorl	%ecx, %ecx
	callq	_s5p_sg_copy_buf
	movq	(%r13), %rdi
	movl	$1, %esi
	callq	_sg_init_table
	movq	(%r13), %rdi
	movq	%r14, %rsi
	movl	%r12d, %edx
	callq	_sg_set_buf
	jmp	LBB0_5
LBB0_3:
	movq	(%r13), %rdi
	callq	_kfree
	movq	$0, (%r13)
LBB0_1:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
LBB0_5:
	movl	%ebx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_GFP_ATOMIC,4,2                 ## @GFP_ATOMIC
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.comm	_AES_BLOCK_SIZE,4,2             ## @AES_BLOCK_SIZE
	.no_dead_strip	_s5p_make_sg_cpy
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function s5p_make_sg_cpy
_s5p_make_sg_cpy:                       ; @s5p_make_sg_cpy
	.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, x2
	mov	x20, x1
	mov	x21, x0
Lloh0:
	adrp	x23, _GFP_ATOMIC@GOTPAGE
Lloh1:
	ldr	x23, [x23, _GFP_ATOMIC@GOTPAGEOFF]
	ldr	w1, [x23]
	mov	w0, #4
	bl	_kmalloc
	str	x0, [x19]
	cbz	x0, LBB0_4
; %bb.1:
	ldr	x8, [x21]
	ldr	w0, [x8]
Lloh2:
	adrp	x8, _AES_BLOCK_SIZE@GOTPAGE
Lloh3:
	ldr	x8, [x8, _AES_BLOCK_SIZE@GOTPAGEOFF]
Lloh4:
	ldr	w1, [x8]
	bl	_ALIGN
	mov	x22, x0
	ldr	w23, [x23]
	bl	_get_order
	mov	x1, x0
	mov	x0, x23
	bl	___get_free_pages
	cbz	x0, LBB0_3
; %bb.2:
	mov	x23, x0
	ldr	x8, [x21]
	ldr	w2, [x8]
	mov	x1, x20
	mov	w3, #0
	bl	_s5p_sg_copy_buf
	ldr	x0, [x19]
	mov	w1, #1
	bl	_sg_init_table
	ldr	x0, [x19]
	mov	x1, x23
	mov	x2, x22
	bl	_sg_set_buf
	mov	w0, #0
	b	LBB0_5
LBB0_3:
	ldr	x0, [x19]
	bl	_kfree
	str	xzr, [x19]
LBB0_4:
Lloh5:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh6:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh7:
	ldr	w8, [x8]
	neg	w0, w8
LBB0_5:
	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 AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.cfi_endproc
                                        ; -- End function
	.comm	_GFP_ATOMIC,4,2                 ; @GFP_ATOMIC
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.comm	_AES_BLOCK_SIZE,4,2             ; @AES_BLOCK_SIZE
	.no_dead_strip	_s5p_make_sg_cpy
.subsections_via_symbols
