	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function htc_proc_trailer
_htc_proc_trailer:                      ## @htc_proc_trailer
	.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
	movl	%r9d, -48(%rbp)                 ## 4-byte Spill
	movq	%r8, -64(%rbp)                  ## 8-byte Spill
	movq	%rcx, %r15
	movl	%edx, %ebx
	movq	%rsi, %r12
	movq	%rdi, %r14
	movq	_ATH6KL_DBG_HTC@GOTPCREL(%rip), %r13
	movl	(%r13), %edi
	leaq	L_.str(%rip), %rsi
	callq	_ath6kl_dbg
	movl	(%r13), %edi
	leaq	L_.str.1(%rip), %rdx
	xorl	%r13d, %r13d
	xorl	%esi, %esi
	movq	%r12, %rcx
	movl	%ebx, %r8d
	callq	_ath6kl_dbg_dump
	testl	%ebx, %ebx
	jle	LBB0_11
## %bb.1:
	movq	%r12, -56(%rbp)                 ## 8-byte Spill
	movq	%r12, %r13
	movl	%ebx, -44(%rbp)                 ## 4-byte Spill
	movl	%ebx, %r12d
	.p2align	4, 0x90
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	cmpl	$8, %r12d
	jb	LBB0_5
## %bb.3:                               ##   in Loop: Header=BB0_2 Depth=1
	addl	$-8, %r12d
	movl	(%r13), %esi
	cmpl	%r12d, %esi
	jg	LBB0_4
## %bb.8:                               ##   in Loop: Header=BB0_2 Depth=1
	leaq	32(%r13), %rbx
	movq	%r14, %rdi
	movq	%r13, %rsi
	movq	%rbx, %rdx
	movq	%r15, %rcx
	movl	-48(%rbp), %r8d                 ## 4-byte Reload
	movq	-64(%rbp), %r9                  ## 8-byte Reload
	callq	_htc_parse_trailer
	testl	%eax, %eax
	jne	LBB0_7
## %bb.9:                               ##   in Loop: Header=BB0_2 Depth=1
	movslq	(%r13), %rax
	leaq	(%rbx,%rax,4), %r13
	subl	%eax, %r12d
	jg	LBB0_2
## %bb.10:
	xorl	%r13d, %r13d
	jmp	LBB0_11
LBB0_4:
	movl	4(%r13), %edx
	leaq	L_.str.2(%rip), %rdi
	movl	%r12d, %ecx
	callq	_ath6kl_err
LBB0_5:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	testl	%eax, %eax
	movl	$0, %r13d
	je	LBB0_11
## %bb.6:
	negl	%eax
LBB0_7:
	movl	%eax, %r13d
	movl	-44(%rbp), %r8d                 ## 4-byte Reload
	movq	-56(%rbp), %rcx                 ## 8-byte Reload
	movq	_ATH6KL_DBG_HTC@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str.3(%rip), %rsi
	leaq	L_.str.1(%rip), %rdx
	callq	_ath6kl_dbg_dump
LBB0_11:
	movl	%r13d, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_ATH6KL_DBG_HTC,4,2             ## @ATH6KL_DBG_HTC
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"htc rx trailer len %d\n"

L_.str.1:                               ## @.str.1
	.space	1

	.comm	_ENOMEM,4,2                     ## @ENOMEM
L_.str.2:                               ## @.str.2
	.asciz	"invalid record len: %d (id:%d) buf has: %d bytes left\n"

L_.str.3:                               ## @.str.3
	.asciz	"htc rx bad trailer"

	.no_dead_strip	_htc_proc_trailer
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function htc_proc_trailer
_htc_proc_trailer:                      ; @htc_proc_trailer
	.cfi_startproc
; %bb.0:
	stp	x28, x27, [sp, #-96]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 96
	stp	x26, x25, [sp, #16]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #32]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #48]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #64]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #80]             ; 16-byte Folded Spill
	add	x29, sp, #80
	.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
	mov	x21, x5
	mov	x22, x4
	mov	x23, x3
	mov	x19, x2
	mov	x20, x1
	mov	x24, x0
Lloh0:
	adrp	x25, _ATH6KL_DBG_HTC@GOTPAGE
Lloh1:
	ldr	x25, [x25, _ATH6KL_DBG_HTC@GOTPAGEOFF]
	ldr	w0, [x25]
Lloh2:
	adrp	x1, l_.str@PAGE
Lloh3:
	add	x1, x1, l_.str@PAGEOFF
	bl	_ath6kl_dbg
	ldr	w0, [x25]
Lloh4:
	adrp	x2, l_.str.1@PAGE
Lloh5:
	add	x2, x2, l_.str.1@PAGEOFF
	mov	x1, #0
	mov	x3, x20
	mov	x4, x19
	bl	_ath6kl_dbg_dump
	cmp	w19, #1
	b.lt	LBB0_9
; %bb.1:
	mov	x25, x20
	mov	x8, x19
LBB0_2:                                 ; =>This Inner Loop Header: Depth=1
	subs	w26, w8, #8
	b.lo	LBB0_7
; %bb.3:                                ;   in Loop: Header=BB0_2 Depth=1
	mov	x28, x25
	ldr	w1, [x28], #32
	cmp	w1, w26
	b.gt	LBB0_6
; %bb.4:                                ;   in Loop: Header=BB0_2 Depth=1
	mov	x0, x24
	mov	x1, x25
	mov	x2, x28
	mov	x3, x23
	mov	x4, x21
	mov	x5, x22
	bl	_htc_parse_trailer
	cbnz	w0, LBB0_10
; %bb.5:                                ;   in Loop: Header=BB0_2 Depth=1
	ldrsw	x8, [x25]
	add	x25, x28, x8, lsl #2
	sub	w8, w26, w8
	cmp	w8, #0
	b.gt	LBB0_2
	b	LBB0_9
LBB0_6:
	ldr	w2, [x25, #4]
Lloh6:
	adrp	x0, l_.str.2@PAGE
Lloh7:
	add	x0, x0, l_.str.2@PAGEOFF
	mov	x3, x26
	bl	_ath6kl_err
LBB0_7:
Lloh8:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh9:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh10:
	ldr	w8, [x8]
	cbz	w8, LBB0_9
; %bb.8:
	neg	w27, w8
	b	LBB0_11
LBB0_9:
	mov	w27, #0
	b	LBB0_12
LBB0_10:
	mov	x27, x0
LBB0_11:
Lloh11:
	adrp	x8, _ATH6KL_DBG_HTC@GOTPAGE
Lloh12:
	ldr	x8, [x8, _ATH6KL_DBG_HTC@GOTPAGEOFF]
Lloh13:
	ldr	w0, [x8]
Lloh14:
	adrp	x1, l_.str.3@PAGE
Lloh15:
	add	x1, x1, l_.str.3@PAGEOFF
Lloh16:
	adrp	x2, l_.str.1@PAGE
Lloh17:
	add	x2, x2, l_.str.1@PAGEOFF
	mov	x3, x20
	mov	x4, x19
	bl	_ath6kl_dbg_dump
LBB0_12:
	mov	x0, x27
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #16]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp], #96             ; 16-byte Folded Reload
	ret
	.loh AdrpAdd	Lloh4, Lloh5
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpAdd	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpAdd	Lloh16, Lloh17
	.loh AdrpAdd	Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.cfi_endproc
                                        ; -- End function
	.comm	_ATH6KL_DBG_HTC,4,2             ; @ATH6KL_DBG_HTC
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"htc rx trailer len %d\n"

l_.str.1:                               ; @.str.1
	.space	1

	.comm	_ENOMEM,4,2                     ; @ENOMEM
l_.str.2:                               ; @.str.2
	.asciz	"invalid record len: %d (id:%d) buf has: %d bytes left\n"

l_.str.3:                               ; @.str.3
	.asciz	"htc rx bad trailer"

	.no_dead_strip	_htc_proc_trailer
.subsections_via_symbols
