	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_fjes_hw_unregister_buff_addr   ## -- Begin function fjes_hw_unregister_buff_addr
	.p2align	4, 0x90
_fjes_hw_unregister_buff_addr:          ## @fjes_hw_unregister_buff_addr
	.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
	cmpl	$0, 48(%rdi)
	je	LBB0_20
## %bb.1:
	movq	%rdi, %r13
	movq	40(%rdi), %rbx
	testq	%rbx, %rbx
	je	LBB0_20
## %bb.2:
	movq	32(%r13), %r12
	testq	%r12, %r12
	je	LBB0_20
## %bb.3:
	cmpq	$0, 24(%r13)
	je	LBB0_20
## %bb.4:
	movl	%esi, %r15d
	leaq	8(%r13), %r14
	movl	%esi, %edi
	movq	%r14, %rsi
	callq	_test_bit
	testl	%eax, %eax
	je	LBB0_16
## %bb.5:
	movq	%r14, -56(%rbp)                 ## 8-byte Spill
	movl	16(%r13), %edx
	movq	%rbx, %rdi
	xorl	%esi, %esi
	callq	_memset
	movl	12(%r13), %edx
	movq	%r12, %rdi
	xorl	%esi, %esi
	callq	_memset
	movq	_FJES_DEV_COMMAND_UNSHARE_BUFFER_REQ_LEN@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, (%rbx)
	movl	%r15d, -44(%rbp)                ## 4-byte Spill
	movl	%r15d, 8(%rbx)
	movq	$0, (%r12)
	movl	$0, 12(%r12)
	movq	%rbx, %rdi
	callq	_trace_fjes_hw_unregister_buff_addr_req
	movq	_FJES_CMD_REQ_UNSHARE_BUFFER@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r13, %rdi
	callq	_fjes_hw_issue_request_command
	movq	_FJES_COMMAND_REQ_BUFF_TIMEOUT@GOTPCREL(%rip), %rcx
	imull	$1000, (%rcx), %ebx             ## imm = 0x3E8
	movl	%eax, %r14d
	movq	_FJES_CMD_STATUS_NORMAL@GOTPCREL(%rip), %rax
	cmpl	(%rax), %r14d
	jne	LBB0_11
## %bb.6:
	movq	(%r12), %rax
	movq	_FJES_DEV_COMMAND_UNSHARE_BUFFER_RES_LEN@GOTPCREL(%rip), %r15
	cmpq	(%r15), %rax
	jne	LBB0_11
	.p2align	4, 0x90
LBB0_7:                                 ## =>This Inner Loop Header: Depth=1
	cmpl	$133, 12(%r12)
	jne	LBB0_11
## %bb.8:                               ##   in Loop: Header=BB0_7 Depth=1
	testl	%ebx, %ebx
	jle	LBB0_11
## %bb.9:                               ##   in Loop: Header=BB0_7 Depth=1
	movl	(%r13), %eax
	leal	(%rax,%rax,4), %eax
	leal	200(,%rax,4), %edi
	callq	_msleep
	movl	(%r13), %eax
	shll	$2, %eax
	leal	(%rax,%rax,4), %eax
	subl	%eax, %ebx
	addl	$-200, %ebx
	movq	$0, (%r12)
	movl	$0, 12(%r12)
	movq	_FJES_CMD_REQ_UNSHARE_BUFFER@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r13, %rdi
	callq	_fjes_hw_issue_request_command
	movl	%eax, %r14d
	movq	_FJES_CMD_STATUS_NORMAL@GOTPCREL(%rip), %rax
	cmpl	(%rax), %r14d
	jne	LBB0_11
## %bb.10:                              ##   in Loop: Header=BB0_7 Depth=1
	movq	(%r12), %rax
	cmpq	(%r15), %rax
	je	LBB0_7
LBB0_11:
	movq	%r12, %rdi
	movl	%ebx, %esi
	callq	_trace_fjes_hw_unregister_buff_addr
	movq	(%r12), %rax
	movq	_FJES_DEV_COMMAND_UNSHARE_BUFFER_RES_LEN@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_17
## %bb.12:
	movq	_FJES_CMD_STATUS_NORMAL@GOTPCREL(%rip), %rax
	cmpl	(%rax), %r14d
	jne	LBB0_18
## %bb.13:
	movl	12(%r12), %eax
	cmpl	$133, %eax
	je	LBB0_23
## %bb.14:
	cmpl	$132, %eax
	jne	LBB0_20
## %bb.15:
	movl	-44(%rbp), %edi                 ## 4-byte Reload
	movq	-56(%rbp), %rsi                 ## 8-byte Reload
	callq	_clear_bit
LBB0_16:
	xorl	%eax, %eax
	jmp	LBB0_22
LBB0_17:
	leaq	L_.str(%rip), %rdi
	callq	_trace_fjes_hw_unregister_buff_addr_err
	movq	_ENOMSG@GOTPCREL(%rip), %rcx
	jmp	LBB0_21
LBB0_18:
	cmpl	$129, %r14d
	je	LBB0_24
## %bb.19:
	cmpl	$128, %r14d
LBB0_20:
	movq	_EPERM@GOTPCREL(%rip), %rcx
LBB0_21:
	xorl	%eax, %eax
	subl	(%rcx), %eax
LBB0_22:
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_23:
	leaq	L_.str.1(%rip), %rdi
	jmp	LBB0_25
LBB0_24:
	leaq	L_.str.2(%rip), %rdi
LBB0_25:
	callq	_trace_fjes_hw_unregister_buff_addr_err
	movq	_EBUSY@GOTPCREL(%rip), %rcx
	jmp	LBB0_21
	.cfi_endproc
                                        ## -- End function
	.comm	_EPERM,4,2                      ## @EPERM
	.comm	_FJES_DEV_COMMAND_UNSHARE_BUFFER_REQ_LEN,8,3 ## @FJES_DEV_COMMAND_UNSHARE_BUFFER_REQ_LEN
	.comm	_FJES_CMD_REQ_UNSHARE_BUFFER,4,2 ## @FJES_CMD_REQ_UNSHARE_BUFFER
	.comm	_FJES_COMMAND_REQ_BUFF_TIMEOUT,4,2 ## @FJES_COMMAND_REQ_BUFF_TIMEOUT
	.comm	_FJES_CMD_STATUS_NORMAL,4,2     ## @FJES_CMD_STATUS_NORMAL
	.comm	_FJES_DEV_COMMAND_UNSHARE_BUFFER_RES_LEN,8,3 ## @FJES_DEV_COMMAND_UNSHARE_BUFFER_RES_LEN
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Invalid res_buf"

	.comm	_ENOMSG,4,2                     ## @ENOMSG
L_.str.1:                               ## @.str.1
	.asciz	"Busy Timeout"

	.comm	_EBUSY,4,2                      ## @EBUSY
L_.str.2:                               ## @.str.2
	.asciz	"Timeout"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_fjes_hw_unregister_buff_addr   ; -- Begin function fjes_hw_unregister_buff_addr
	.p2align	2
_fjes_hw_unregister_buff_addr:          ; @fjes_hw_unregister_buff_addr
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	stp	x28, x27, [sp, #16]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #32]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #48]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #64]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #80]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #96]             ; 16-byte Folded Spill
	add	x29, sp, #96
	.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
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	ldr	w8, [x0, #48]
	cbz	w8, LBB0_2
; %bb.1:
	mov	x22, x0
	ldp	x21, x23, [x0, #32]
	ldr	x8, [x0, #24]
	cmp	x23, #0
	ccmp	x21, #0, #4, ne
	ccmp	x8, #0, #4, ne
	b.ne	LBB0_5
LBB0_2:
Lloh0:
	adrp	x8, _EPERM@GOTPAGE
Lloh1:
	ldr	x8, [x8, _EPERM@GOTPAGEOFF]
LBB0_3:
	ldr	w8, [x8]
	neg	w0, w8
LBB0_4:
	ldp	x29, x30, [sp, #96]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #80]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #64]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #48]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #32]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #112
	ret
LBB0_5:
	mov	x19, x1
	add	x20, x22, #8
	mov	x0, x1
	mov	x1, x20
	bl	_test_bit
	cbz	w0, LBB0_4
; %bb.6:
	ldr	w2, [x22, #16]
	mov	x0, x23
	mov	w1, #0
	bl	_memset
	ldr	w2, [x22, #12]
	mov	x0, x21
	mov	w1, #0
	bl	_memset
Lloh2:
	adrp	x8, _FJES_DEV_COMMAND_UNSHARE_BUFFER_REQ_LEN@GOTPAGE
Lloh3:
	ldr	x8, [x8, _FJES_DEV_COMMAND_UNSHARE_BUFFER_REQ_LEN@GOTPAGEOFF]
Lloh4:
	ldr	x8, [x8]
	str	x8, [x23]
	str	w19, [x23, #8]
	str	xzr, [x21]
	str	wzr, [x21, #12]
	mov	x0, x23
	bl	_trace_fjes_hw_unregister_buff_addr_req
Lloh5:
	adrp	x27, _FJES_CMD_REQ_UNSHARE_BUFFER@GOTPAGE
Lloh6:
	ldr	x27, [x27, _FJES_CMD_REQ_UNSHARE_BUFFER@GOTPAGEOFF]
	ldr	w1, [x27]
	mov	x0, x22
	bl	_fjes_hw_issue_request_command
	mov	x23, x0
Lloh7:
	adrp	x8, _FJES_COMMAND_REQ_BUFF_TIMEOUT@GOTPAGE
Lloh8:
	ldr	x8, [x8, _FJES_COMMAND_REQ_BUFF_TIMEOUT@GOTPAGEOFF]
Lloh9:
	ldr	w8, [x8]
	mov	w9, #1000
	mul	w24, w8, w9
Lloh10:
	adrp	x25, _FJES_CMD_STATUS_NORMAL@GOTPAGE
Lloh11:
	ldr	x25, [x25, _FJES_CMD_STATUS_NORMAL@GOTPAGEOFF]
	ldr	w8, [x25]
Lloh12:
	adrp	x26, _FJES_DEV_COMMAND_UNSHARE_BUFFER_RES_LEN@GOTPAGE
Lloh13:
	ldr	x26, [x26, _FJES_DEV_COMMAND_UNSHARE_BUFFER_RES_LEN@GOTPAGEOFF]
	cmp	w0, w8
	str	x20, [sp, #8]                   ; 8-byte Folded Spill
	b.ne	LBB0_12
; %bb.7:
	ldr	x8, [x21]
	ldr	x9, [x26]
	cmp	x8, x9
	b.ne	LBB0_12
; %bb.8:
	mov	w28, #20
	mov	w20, #-20
LBB0_9:                                 ; =>This Inner Loop Header: Depth=1
	ldr	w8, [x21, #12]
	cmp	w8, #133
	ccmp	w24, #1, #8, eq
	b.lt	LBB0_12
; %bb.10:                               ;   in Loop: Header=BB0_9 Depth=1
	ldr	w8, [x22]
	mul	w8, w8, w28
	add	w0, w8, #200
	bl	_msleep
	ldr	w8, [x22]
	madd	w8, w8, w20, w24
	sub	w24, w8, #200
	str	xzr, [x21]
	str	wzr, [x21, #12]
	ldr	w1, [x27]
	mov	x0, x22
	bl	_fjes_hw_issue_request_command
	mov	x23, x0
	ldr	w8, [x25]
	cmp	w0, w8
	b.ne	LBB0_12
; %bb.11:                               ;   in Loop: Header=BB0_9 Depth=1
	ldr	x8, [x21]
	ldr	x9, [x26]
	cmp	x8, x9
	b.eq	LBB0_9
LBB0_12:
	mov	x0, x21
	mov	x1, x24
	bl	_trace_fjes_hw_unregister_buff_addr
	ldr	x8, [x21]
	ldr	x9, [x26]
	cmp	x8, x9
	b.ne	LBB0_17
; %bb.13:
	ldr	w8, [x25]
	cmp	w23, w8
	b.ne	LBB0_18
; %bb.14:
	ldr	w8, [x21, #12]
	cmp	w8, #133
	b.eq	LBB0_20
; %bb.15:
	cmp	w8, #132
	b.ne	LBB0_2
; %bb.16:
	mov	x0, x19
	ldr	x1, [sp, #8]                    ; 8-byte Folded Reload
	bl	_clear_bit
	mov	w0, #0
	b	LBB0_4
LBB0_17:
Lloh14:
	adrp	x0, l_.str@PAGE
Lloh15:
	add	x0, x0, l_.str@PAGEOFF
	bl	_trace_fjes_hw_unregister_buff_addr_err
Lloh16:
	adrp	x8, _ENOMSG@GOTPAGE
Lloh17:
	ldr	x8, [x8, _ENOMSG@GOTPAGEOFF]
	b	LBB0_3
LBB0_18:
	cmp	w23, #129
	b.eq	LBB0_21
; %bb.19:
	cmp	w23, #128
	b	LBB0_2
LBB0_20:
Lloh18:
	adrp	x0, l_.str.1@PAGE
Lloh19:
	add	x0, x0, l_.str.1@PAGEOFF
	b	LBB0_22
LBB0_21:
Lloh20:
	adrp	x0, l_.str.2@PAGE
Lloh21:
	add	x0, x0, l_.str.2@PAGEOFF
LBB0_22:
	bl	_trace_fjes_hw_unregister_buff_addr_err
Lloh22:
	adrp	x8, _EBUSY@GOTPAGE
Lloh23:
	ldr	x8, [x8, _EBUSY@GOTPAGEOFF]
	b	LBB0_3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh12, Lloh13
	.loh AdrpLdrGot	Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh16, Lloh17
	.loh AdrpAdd	Lloh14, Lloh15
	.loh AdrpAdd	Lloh18, Lloh19
	.loh AdrpAdd	Lloh20, Lloh21
	.loh AdrpLdrGot	Lloh22, Lloh23
	.cfi_endproc
                                        ; -- End function
	.comm	_EPERM,4,2                      ; @EPERM
	.comm	_FJES_DEV_COMMAND_UNSHARE_BUFFER_REQ_LEN,8,3 ; @FJES_DEV_COMMAND_UNSHARE_BUFFER_REQ_LEN
	.comm	_FJES_CMD_REQ_UNSHARE_BUFFER,4,2 ; @FJES_CMD_REQ_UNSHARE_BUFFER
	.comm	_FJES_COMMAND_REQ_BUFF_TIMEOUT,4,2 ; @FJES_COMMAND_REQ_BUFF_TIMEOUT
	.comm	_FJES_CMD_STATUS_NORMAL,4,2     ; @FJES_CMD_STATUS_NORMAL
	.comm	_FJES_DEV_COMMAND_UNSHARE_BUFFER_RES_LEN,8,3 ; @FJES_DEV_COMMAND_UNSHARE_BUFFER_RES_LEN
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Invalid res_buf"

	.comm	_ENOMSG,4,2                     ; @ENOMSG
l_.str.1:                               ; @.str.1
	.asciz	"Busy Timeout"

	.comm	_EBUSY,4,2                      ; @EBUSY
l_.str.2:                               ; @.str.2
	.asciz	"Timeout"

.subsections_via_symbols
