	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function omap_sham_done_task
_omap_sham_done_task:                   ## @omap_sham_done_task
	.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	%rdi, %r14
	movq	_FLAGS_BUSY@GOTPCREL(%rip), %r12
	movl	(%r12), %edi
	leaq	4(%r14), %rbx
	movq	%rbx, %rsi
	callq	_test_bit
	testq	%rax, %rax
	je	LBB0_10
## %bb.1:
	movq	_FLAGS_CPU@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	%rbx, %rsi
	callq	_test_bit
	testq	%rax, %rax
	je	LBB0_3
## %bb.2:
	movq	_FLAGS_OUTPUT_READY@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	%rbx, %rsi
	callq	_test_and_clear_bit
	xorl	%r15d, %r15d
	testq	%rax, %rax
	je	LBB0_9
LBB0_8:
	movl	12(%r14), %edi
	leaq	L_.str(%rip), %rsi
	movl	%r15d, %edx
	callq	_dev_dbg
	movl	8(%r14), %edi
	movl	%r15d, %esi
	callq	_omap_sham_finish_req
	movl	(%r12), %edi
	movq	%rbx, %rsi
	callq	_test_bit
	testq	%rax, %rax
	jne	LBB0_9
LBB0_10:
	movq	%r14, %rdi
	xorl	%esi, %esi
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_omap_sham_handle_queue         ## TAILCALL
LBB0_3:
	movq	_FLAGS_DMA_READY@GOTPCREL(%rip), %r13
	movl	(%r13), %edi
	movq	%rbx, %rsi
	callq	_test_bit
	testq	%rax, %rax
	je	LBB0_9
## %bb.4:
	movq	_FLAGS_DMA_ACTIVE@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	%rbx, %rsi
	callq	_test_and_clear_bit
	testq	%rax, %rax
	je	LBB0_6
## %bb.5:
	movq	%r14, %rdi
	callq	_omap_sham_update_dma_stop
	movl	(%r14), %r15d
	testl	%r15d, %r15d
	jne	LBB0_8
LBB0_6:
	movq	_FLAGS_OUTPUT_READY@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	%rbx, %rsi
	callq	_test_and_clear_bit
	testq	%rax, %rax
	je	LBB0_9
## %bb.7:
	movl	(%r13), %edi
	movq	%rbx, %rsi
	callq	_clear_bit
	xorl	%r15d, %r15d
	jmp	LBB0_8
LBB0_9:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_FLAGS_BUSY,4,2                 ## @FLAGS_BUSY
	.comm	_FLAGS_CPU,4,2                  ## @FLAGS_CPU
	.comm	_FLAGS_OUTPUT_READY,4,2         ## @FLAGS_OUTPUT_READY
	.comm	_FLAGS_DMA_READY,4,2            ## @FLAGS_DMA_READY
	.comm	_FLAGS_DMA_ACTIVE,4,2           ## @FLAGS_DMA_ACTIVE
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"update done: err: %d\n"

	.no_dead_strip	_omap_sham_done_task
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function omap_sham_done_task
_omap_sham_done_task:                   ; @omap_sham_done_task
	.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, x0
Lloh0:
	adrp	x22, _FLAGS_BUSY@GOTPAGE
Lloh1:
	ldr	x22, [x22, _FLAGS_BUSY@GOTPAGEOFF]
	ldr	w0, [x22]
	add	x20, x19, #4
	mov	x1, x20
	bl	_test_bit
	cbz	x0, LBB0_5
; %bb.1:
Lloh2:
	adrp	x8, _FLAGS_CPU@GOTPAGE
Lloh3:
	ldr	x8, [x8, _FLAGS_CPU@GOTPAGEOFF]
Lloh4:
	ldr	w0, [x8]
	mov	x1, x20
	bl	_test_bit
	cbz	x0, LBB0_6
; %bb.2:
Lloh5:
	adrp	x8, _FLAGS_OUTPUT_READY@GOTPAGE
Lloh6:
	ldr	x8, [x8, _FLAGS_OUTPUT_READY@GOTPAGEOFF]
Lloh7:
	ldr	w0, [x8]
	mov	x1, x20
	bl	_test_and_clear_bit
	cbz	x0, LBB0_11
LBB0_3:
	mov	w21, #0
LBB0_4:
	ldr	w0, [x19, #12]
Lloh8:
	adrp	x1, l_.str@PAGE
Lloh9:
	add	x1, x1, l_.str@PAGEOFF
	mov	x2, x21
	bl	_dev_dbg
	ldr	w0, [x19, #8]
	mov	x1, x21
	bl	_omap_sham_finish_req
	ldr	w0, [x22]
	mov	x1, x20
	bl	_test_bit
	cbnz	x0, LBB0_11
LBB0_5:
	mov	x0, x19
	mov	x1, #0
	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
	b	_omap_sham_handle_queue
LBB0_6:
Lloh10:
	adrp	x23, _FLAGS_DMA_READY@GOTPAGE
Lloh11:
	ldr	x23, [x23, _FLAGS_DMA_READY@GOTPAGEOFF]
	ldr	w0, [x23]
	mov	x1, x20
	bl	_test_bit
	cbz	x0, LBB0_11
; %bb.7:
Lloh12:
	adrp	x8, _FLAGS_DMA_ACTIVE@GOTPAGE
Lloh13:
	ldr	x8, [x8, _FLAGS_DMA_ACTIVE@GOTPAGEOFF]
Lloh14:
	ldr	w0, [x8]
	mov	x1, x20
	bl	_test_and_clear_bit
	cbz	x0, LBB0_9
; %bb.8:
	mov	x0, x19
	bl	_omap_sham_update_dma_stop
	ldr	w21, [x19]
	cbnz	w21, LBB0_4
LBB0_9:
Lloh15:
	adrp	x8, _FLAGS_OUTPUT_READY@GOTPAGE
Lloh16:
	ldr	x8, [x8, _FLAGS_OUTPUT_READY@GOTPAGEOFF]
Lloh17:
	ldr	w0, [x8]
	mov	x1, x20
	bl	_test_and_clear_bit
	cbz	x0, LBB0_11
; %bb.10:
	ldr	w0, [x23]
	mov	x1, x20
	bl	_clear_bit
	b	LBB0_3
LBB0_11:
	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
	.loh AdrpAdd	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.cfi_endproc
                                        ; -- End function
	.comm	_FLAGS_BUSY,4,2                 ; @FLAGS_BUSY
	.comm	_FLAGS_CPU,4,2                  ; @FLAGS_CPU
	.comm	_FLAGS_OUTPUT_READY,4,2         ; @FLAGS_OUTPUT_READY
	.comm	_FLAGS_DMA_READY,4,2            ; @FLAGS_DMA_READY
	.comm	_FLAGS_DMA_ACTIVE,4,2           ; @FLAGS_DMA_ACTIVE
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"update done: err: %d\n"

	.no_dead_strip	_omap_sham_done_task
.subsections_via_symbols
