	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function preview_set_selection
_preview_set_selection:                 ## @preview_set_selection
	.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
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdx, %rbx
	movq	%rsi, %r14
	callq	_v4l2_get_subdevdata
	movq	%rax, %r15
	movq	(%rbx), %rax
	movq	_V4L2_SEL_TGT_CROP@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_2
## %bb.1:
	movq	8(%rbx), %rdx
	movq	_PREV_PAD_SINK@GOTPCREL(%rip), %rax
	cmpq	(%rax), %rdx
	jne	LBB0_2
## %bb.4:
	movq	(%r15), %rax
	movq	_ISP_PIPELINE_STREAM_STOPPED@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_5
## %bb.6:
	movq	_V4L2_SEL_FLAG_KEEP_CONFIG@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	20(%rbx), %ecx
	testl	%eax, 16(%rbx)
	je	LBB0_8
## %bb.7:
	movq	%r15, %rdi
	movq	%r14, %rsi
	movl	%ecx, %edx
	callq	___preview_get_crop
	movl	(%rax), %eax
	movl	%eax, 24(%rbx)
	jmp	LBB0_9
LBB0_2:
	movq	_EINVAL@GOTPCREL(%rip), %rcx
LBB0_3:
	xorl	%eax, %eax
	subl	(%rcx), %eax
LBB0_10:
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_5:
	movq	_EBUSY@GOTPCREL(%rip), %rcx
	jmp	LBB0_3
LBB0_8:
	movq	%r15, %rdi
	movq	%r14, %rsi
	callq	___preview_get_format
	leaq	24(%rbx), %rdx
	movq	%r15, %rdi
	movq	%rax, %rsi
	callq	_preview_try_crop
	movl	20(%rbx), %edx
	movl	24(%rbx), %r12d
	movq	%r15, %rdi
	movq	%r14, %rsi
	callq	___preview_get_crop
	movl	%r12d, (%rax)
	movq	_PREV_PAD_SOURCE@GOTPCREL(%rip), %r12
	movq	(%r12), %rdx
	movl	20(%rbx), %ecx
	movq	%r15, %rdi
	movq	%r14, %rsi
	callq	___preview_get_format
	movq	(%r12), %rdx
	movl	20(%rbx), %r8d
	movq	%r15, %rdi
	movq	%r14, %rsi
	movq	%rax, %rcx
	callq	_preview_try_format
LBB0_9:
	xorl	%eax, %eax
	jmp	LBB0_10
	.cfi_endproc
                                        ## -- End function
	.comm	_V4L2_SEL_TGT_CROP,8,3          ## @V4L2_SEL_TGT_CROP
	.comm	_PREV_PAD_SINK,8,3              ## @PREV_PAD_SINK
	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_ISP_PIPELINE_STREAM_STOPPED,8,3 ## @ISP_PIPELINE_STREAM_STOPPED
	.comm	_EBUSY,4,2                      ## @EBUSY
	.comm	_V4L2_SEL_FLAG_KEEP_CONFIG,4,2  ## @V4L2_SEL_FLAG_KEEP_CONFIG
	.comm	_PREV_PAD_SOURCE,8,3            ## @PREV_PAD_SOURCE
	.no_dead_strip	_preview_set_selection
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function preview_set_selection
_preview_set_selection:                 ; @preview_set_selection
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.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	x19, x2
	mov	x20, x1
	bl	_v4l2_get_subdevdata
	ldr	x8, [x19]
Lloh0:
	adrp	x9, _V4L2_SEL_TGT_CROP@GOTPAGE
Lloh1:
	ldr	x9, [x9, _V4L2_SEL_TGT_CROP@GOTPAGEOFF]
Lloh2:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_5
; %bb.1:
	ldr	x2, [x19, #8]
Lloh3:
	adrp	x8, _PREV_PAD_SINK@GOTPAGE
Lloh4:
	ldr	x8, [x8, _PREV_PAD_SINK@GOTPAGEOFF]
Lloh5:
	ldr	x8, [x8]
	cmp	x2, x8
	b.ne	LBB0_5
; %bb.2:
	mov	x21, x0
	ldr	x8, [x0]
Lloh6:
	adrp	x9, _ISP_PIPELINE_STREAM_STOPPED@GOTPAGE
Lloh7:
	ldr	x9, [x9, _ISP_PIPELINE_STREAM_STOPPED@GOTPAGEOFF]
Lloh8:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_8
; %bb.3:
Lloh9:
	adrp	x8, _V4L2_SEL_FLAG_KEEP_CONFIG@GOTPAGE
Lloh10:
	ldr	x8, [x8, _V4L2_SEL_FLAG_KEEP_CONFIG@GOTPAGEOFF]
Lloh11:
	ldr	w8, [x8]
	ldp	w9, w3, [x19, #16]
	tst	w8, w9
	b.eq	LBB0_9
; %bb.4:
	mov	x0, x21
	mov	x1, x20
	mov	x2, x3
	bl	___preview_get_crop
	mov	x8, x0
	mov	w0, #0
	ldr	w8, [x8]
	str	w8, [x19, #24]
	b	LBB0_7
LBB0_5:
Lloh12:
	adrp	x8, _EINVAL@GOTPAGE
Lloh13:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
LBB0_6:
	ldr	w8, [x8]
	neg	w0, w8
LBB0_7:
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	ret
LBB0_8:
Lloh14:
	adrp	x8, _EBUSY@GOTPAGE
Lloh15:
	ldr	x8, [x8, _EBUSY@GOTPAGEOFF]
	b	LBB0_6
LBB0_9:
	mov	x0, x21
	mov	x1, x20
	bl	___preview_get_format
	mov	x1, x0
	add	x2, x19, #24
	mov	x0, x21
	bl	_preview_try_crop
	ldp	w2, w22, [x19, #20]
	mov	x0, x21
	mov	x1, x20
	bl	___preview_get_crop
	str	w22, [x0]
Lloh16:
	adrp	x22, _PREV_PAD_SOURCE@GOTPAGE
Lloh17:
	ldr	x22, [x22, _PREV_PAD_SOURCE@GOTPAGEOFF]
	ldr	x2, [x22]
	ldr	w3, [x19, #20]
	mov	x0, x21
	mov	x1, x20
	bl	___preview_get_format
	mov	x3, x0
	ldr	x2, [x22]
	ldr	w4, [x19, #20]
	mov	x0, x21
	mov	x1, x20
	bl	_preview_try_format
	mov	w0, #0
	b	LBB0_7
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGot	Lloh12, Lloh13
	.loh AdrpLdrGot	Lloh14, Lloh15
	.loh AdrpLdrGot	Lloh16, Lloh17
	.cfi_endproc
                                        ; -- End function
	.comm	_V4L2_SEL_TGT_CROP,8,3          ; @V4L2_SEL_TGT_CROP
	.comm	_PREV_PAD_SINK,8,3              ; @PREV_PAD_SINK
	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_ISP_PIPELINE_STREAM_STOPPED,8,3 ; @ISP_PIPELINE_STREAM_STOPPED
	.comm	_EBUSY,4,2                      ; @EBUSY
	.comm	_V4L2_SEL_FLAG_KEEP_CONFIG,4,2  ; @V4L2_SEL_FLAG_KEEP_CONFIG
	.comm	_PREV_PAD_SOURCE,8,3            ; @PREV_PAD_SOURCE
	.no_dead_strip	_preview_set_selection
.subsections_via_symbols
