	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function uvc_scan_chain
_uvc_scan_chain:                        ## @uvc_scan_chain
	.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	%r12
	pushq	%rbx
	subq	$16, %rsp
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %rbx
	movq	%rdi, %r15
	movq	_UVC_TRACE_PROBE@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str(%rip), %rsi
	xorl	%r14d, %r14d
	xorl	%eax, %eax
	callq	_uvc_trace
	movq	%rbx, -40(%rbp)
	testq	%rbx, %rbx
	je	LBB0_12
## %bb.1:
	xorl	%r12d, %r12d
	leaq	-40(%rbp), %r14
	.p2align	4, 0x90
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	cmpq	$0, 16(%rbx)
	jne	LBB0_4
## %bb.3:                               ##   in Loop: Header=BB0_2 Depth=1
	cmpq	$0, 8(%rbx)
	jne	LBB0_4
## %bb.7:                               ##   in Loop: Header=BB0_2 Depth=1
	movq	%r15, %rdi
	movq	%rbx, %rsi
	callq	_uvc_scan_chain_entity
	testq	%rax, %rax
	js	LBB0_10
## %bb.8:                               ##   in Loop: Header=BB0_2 Depth=1
	movq	-40(%rbp), %rsi
	movq	%r15, %rdi
	movq	%r12, %rdx
	callq	_uvc_scan_chain_forward
	testq	%rax, %rax
	js	LBB0_10
## %bb.9:                               ##   in Loop: Header=BB0_2 Depth=1
	movq	-40(%rbp), %r12
	movq	%r15, %rdi
	movq	%r14, %rsi
	callq	_uvc_scan_chain_backward
	testq	%rax, %rax
	js	LBB0_10
## %bb.5:                               ##   in Loop: Header=BB0_2 Depth=1
	movq	-40(%rbp), %rbx
	testq	%rbx, %rbx
	jne	LBB0_2
## %bb.6:
	xorl	%r14d, %r14d
	jmp	LBB0_12
LBB0_10:
	movq	_EINVAL@GOTPCREL(%rip), %rax
	xorl	%r14d, %r14d
	jmp	LBB0_11
LBB0_4:
	movq	_UVC_TRACE_DESCR@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	(%rbx), %edx
	leaq	L_.str.1(%rip), %rsi
	xorl	%r14d, %r14d
	xorl	%eax, %eax
	callq	_uvc_trace
	movq	_EINVAL@GOTPCREL(%rip), %rax
LBB0_11:
	subl	(%rax), %r14d
LBB0_12:
	movl	%r14d, %eax
	addq	$16, %rsp
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_UVC_TRACE_PROBE,4,2            ## @UVC_TRACE_PROBE
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Scanning UVC chain:"

	.comm	_UVC_TRACE_DESCR,4,2            ## @UVC_TRACE_DESCR
L_.str.1:                               ## @.str.1
	.asciz	"Found reference to entity %d already in chain.\n"

	.comm	_EINVAL,4,2                     ## @EINVAL
	.no_dead_strip	_uvc_scan_chain
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function uvc_scan_chain
_uvc_scan_chain:                        ; @uvc_scan_chain
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.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
	mov	x21, x1
	mov	x19, x0
Lloh0:
	adrp	x8, _UVC_TRACE_PROBE@GOTPAGE
Lloh1:
	ldr	x8, [x8, _UVC_TRACE_PROBE@GOTPAGEOFF]
Lloh2:
	ldr	w0, [x8]
Lloh3:
	adrp	x1, l_.str@PAGE
Lloh4:
	add	x1, x1, l_.str@PAGEOFF
	bl	_uvc_trace
	str	x21, [sp, #8]
	cbz	x21, LBB0_8
; %bb.1:
	mov	x20, #0
LBB0_2:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x8, [x21, #16]
	cbnz	x8, LBB0_9
; %bb.3:                                ;   in Loop: Header=BB0_2 Depth=1
	ldr	x8, [x21, #8]
	cbnz	x8, LBB0_9
; %bb.4:                                ;   in Loop: Header=BB0_2 Depth=1
	mov	x0, x19
	mov	x1, x21
	bl	_uvc_scan_chain_entity
	tbnz	x0, #63, LBB0_10
; %bb.5:                                ;   in Loop: Header=BB0_2 Depth=1
	ldr	x1, [sp, #8]
	mov	x0, x19
	mov	x2, x20
	bl	_uvc_scan_chain_forward
	tbnz	x0, #63, LBB0_10
; %bb.6:                                ;   in Loop: Header=BB0_2 Depth=1
	ldr	x20, [sp, #8]
	add	x1, sp, #8
	mov	x0, x19
	bl	_uvc_scan_chain_backward
	tbnz	x0, #63, LBB0_10
; %bb.7:                                ;   in Loop: Header=BB0_2 Depth=1
	ldr	x21, [sp, #8]
	cbnz	x21, LBB0_2
LBB0_8:
	mov	w0, #0
	b	LBB0_11
LBB0_9:
Lloh5:
	adrp	x8, _UVC_TRACE_DESCR@GOTPAGE
Lloh6:
	ldr	x8, [x8, _UVC_TRACE_DESCR@GOTPAGEOFF]
Lloh7:
	ldr	w0, [x8]
	ldr	w8, [x21]
	str	x8, [sp]
Lloh8:
	adrp	x1, l_.str.1@PAGE
Lloh9:
	add	x1, x1, l_.str.1@PAGEOFF
	bl	_uvc_trace
LBB0_10:
Lloh10:
	adrp	x8, _EINVAL@GOTPAGE
Lloh11:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh12:
	ldr	w8, [x8]
	neg	w0, w8
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
	add	sp, sp, #64
	ret
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.cfi_endproc
                                        ; -- End function
	.comm	_UVC_TRACE_PROBE,4,2            ; @UVC_TRACE_PROBE
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Scanning UVC chain:"

	.comm	_UVC_TRACE_DESCR,4,2            ; @UVC_TRACE_DESCR
l_.str.1:                               ; @.str.1
	.asciz	"Found reference to entity %d already in chain.\n"

	.comm	_EINVAL,4,2                     ; @EINVAL
	.no_dead_strip	_uvc_scan_chain
.subsections_via_symbols
