	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function cxusb_medion_try_s_fmt_vid_cap
_cxusb_medion_try_s_fmt_vid_cap:        ## @cxusb_medion_try_s_fmt_vid_cap
	.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	$40, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%edx, %r14d
	movq	%rsi, %r15
	callq	_video_drvdata
	movq	(%rax), %rbx
	testl	%r14d, %r14d
	je	LBB0_3
## %bb.1:
	leaq	24(%rbx), %rdi
	callq	_vb2_is_busy
	testq	%rax, %rax
	je	LBB0_3
## %bb.2:
	movq	_EBUSY@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
	jmp	LBB0_12
LBB0_3:
	leaq	24(%rbx), %rdi
	callq	_vb2_start_streaming_called
	testq	%rax, %rax
	je	LBB0_5
## %bb.4:
	movq	16(%rbx), %r12
	jmp	LBB0_6
LBB0_5:
	movq	%rbx, %rdi
	callq	_cxusb_medion_field_order
	movq	%rax, %r12
LBB0_6:
	leaq	-80(%rbp), %r13
	movq	%r13, %rdi
	xorl	%esi, %esi
	movl	$40, %edx
	callq	_memset
	testl	%r14d, %r14d
	jne	LBB0_7
## %bb.8:
	movq	_V4L2_SUBDEV_FORMAT_TRY@GOTPCREL(%rip), %rax
	jmp	LBB0_9
LBB0_7:
	movq	_V4L2_SUBDEV_FORMAT_ACTIVE@GOTPCREL(%rip), %rax
LBB0_9:
	movl	(%rax), %eax
	movl	%eax, -48(%rbp)
	movl	(%r15), %eax
	andl	$-2, %eax
	movl	%eax, -80(%rbp)
	movl	4(%r15), %eax
	andl	$-2, %eax
	movl	%eax, -76(%rbp)
	movq	_MEDIA_BUS_FMT_FIXED@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -56(%rbp)
	movq	%r12, -64(%rbp)
	movq	_V4L2_COLORSPACE_SMPTE170M@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -72(%rbp)
	movl	8(%rbx), %edi
	movq	_pad@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_set_fmt@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	xorl	%ecx, %ecx
	movq	%r13, %r8
	callq	_v4l2_subdev_call
	testl	%eax, %eax
	jne	LBB0_12
## %bb.10:
	movl	-80(%rbp), %ecx
	movl	%ecx, (%r15)
	movl	-76(%rbp), %edx
	leal	(%rcx,%rcx), %esi
	movl	%edx, %edi
	imull	%esi, %edi
	movl	%edx, 4(%r15)
	movq	_V4L2_PIX_FMT_UYVY@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 32(%r15)
	xorl	%eax, %eax
	movq	%r12, 24(%r15)
	movl	%esi, 8(%r15)
	movl	%edi, 12(%r15)
	movq	_V4L2_COLORSPACE_SMPTE170M@GOTPCREL(%rip), %rsi
	movq	(%rsi), %rsi
	movq	%rsi, 16(%r15)
	testl	%r14d, %r14d
	je	LBB0_12
## %bb.11:
	movl	%ecx, (%rbx)
	movl	%edx, 4(%rbx)
LBB0_12:
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_EBUSY,4,2                      ## @EBUSY
	.comm	_V4L2_SUBDEV_FORMAT_ACTIVE,4,2  ## @V4L2_SUBDEV_FORMAT_ACTIVE
	.comm	_V4L2_SUBDEV_FORMAT_TRY,4,2     ## @V4L2_SUBDEV_FORMAT_TRY
	.comm	_MEDIA_BUS_FMT_FIXED,4,2        ## @MEDIA_BUS_FMT_FIXED
	.comm	_V4L2_COLORSPACE_SMPTE170M,8,3  ## @V4L2_COLORSPACE_SMPTE170M
	.comm	_pad,4,2                        ## @pad
	.comm	_set_fmt,4,2                    ## @set_fmt
	.comm	_V4L2_PIX_FMT_UYVY,4,2          ## @V4L2_PIX_FMT_UYVY
	.no_dead_strip	_cxusb_medion_try_s_fmt_vid_cap
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function cxusb_medion_try_s_fmt_vid_cap
_cxusb_medion_try_s_fmt_vid_cap:        ; @cxusb_medion_try_s_fmt_vid_cap
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	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
	mov	x19, x2
	mov	x20, x1
	bl	_video_drvdata
	ldr	x21, [x0]
	cbz	w19, LBB0_3
; %bb.1:
	add	x0, x21, #24
	bl	_vb2_is_busy
	cbz	x0, LBB0_3
; %bb.2:
Lloh0:
	adrp	x8, _EBUSY@GOTPAGE
Lloh1:
	ldr	x8, [x8, _EBUSY@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	neg	w0, w8
	b	LBB0_9
LBB0_3:
	add	x0, x21, #24
	bl	_vb2_start_streaming_called
	cbz	x0, LBB0_5
; %bb.4:
	ldr	x22, [x21, #16]
	b	LBB0_6
LBB0_5:
	mov	x0, x21
	bl	_cxusb_medion_field_order
	mov	x22, x0
LBB0_6:
	add	x0, sp, #8
	mov	w1, #0
	mov	w2, #40
	bl	_memset
Lloh3:
	adrp	x8, _V4L2_SUBDEV_FORMAT_ACTIVE@GOTPAGE
Lloh4:
	ldr	x8, [x8, _V4L2_SUBDEV_FORMAT_ACTIVE@GOTPAGEOFF]
Lloh5:
	adrp	x9, _V4L2_SUBDEV_FORMAT_TRY@GOTPAGE
Lloh6:
	ldr	x9, [x9, _V4L2_SUBDEV_FORMAT_TRY@GOTPAGEOFF]
	cmp	w19, #0
	csel	x8, x9, x8, eq
	ldr	w8, [x8]
	ldr	d0, [x20]
	bic.2s	v0, #1
	str	d0, [sp, #8]
Lloh7:
	adrp	x9, _MEDIA_BUS_FMT_FIXED@GOTPAGE
Lloh8:
	ldr	x9, [x9, _MEDIA_BUS_FMT_FIXED@GOTPAGEOFF]
Lloh9:
	ldr	w9, [x9]
	str	w8, [sp, #40]
	str	w9, [sp, #32]
Lloh10:
	adrp	x23, _V4L2_COLORSPACE_SMPTE170M@GOTPAGE
Lloh11:
	ldr	x23, [x23, _V4L2_COLORSPACE_SMPTE170M@GOTPAGEOFF]
	ldr	x8, [x23]
	stp	x8, x22, [sp, #16]
	ldr	w0, [x21, #8]
Lloh12:
	adrp	x8, _pad@GOTPAGE
Lloh13:
	ldr	x8, [x8, _pad@GOTPAGEOFF]
Lloh14:
	ldr	w1, [x8]
Lloh15:
	adrp	x8, _set_fmt@GOTPAGE
Lloh16:
	ldr	x8, [x8, _set_fmt@GOTPAGEOFF]
Lloh17:
	ldr	w2, [x8]
	add	x4, sp, #8
	mov	x3, #0
	bl	_v4l2_subdev_call
	cbnz	w0, LBB0_9
; %bb.7:
	ldp	w8, w9, [sp, #8]
	stp	w8, w9, [x20]
Lloh18:
	adrp	x10, _V4L2_PIX_FMT_UYVY@GOTPAGE
Lloh19:
	ldr	x10, [x10, _V4L2_PIX_FMT_UYVY@GOTPAGEOFF]
Lloh20:
	ldr	w10, [x10]
	str	w10, [x20, #32]
	lsl	w10, w8, #1
	mul	w11, w9, w10
	stp	w10, w11, [x20, #8]
	ldr	x10, [x23]
	stp	x10, x22, [x20, #16]
	mov	w0, #0
	cbz	w19, LBB0_9
; %bb.8:
	stp	w8, w9, [x21]
LBB0_9:
	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
	add	sp, sp, #112
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGot	Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.cfi_endproc
                                        ; -- End function
	.comm	_EBUSY,4,2                      ; @EBUSY
	.comm	_V4L2_SUBDEV_FORMAT_ACTIVE,4,2  ; @V4L2_SUBDEV_FORMAT_ACTIVE
	.comm	_V4L2_SUBDEV_FORMAT_TRY,4,2     ; @V4L2_SUBDEV_FORMAT_TRY
	.comm	_MEDIA_BUS_FMT_FIXED,4,2        ; @MEDIA_BUS_FMT_FIXED
	.comm	_V4L2_COLORSPACE_SMPTE170M,8,3  ; @V4L2_COLORSPACE_SMPTE170M
	.comm	_pad,4,2                        ; @pad
	.comm	_set_fmt,4,2                    ; @set_fmt
	.comm	_V4L2_PIX_FMT_UYVY,4,2          ; @V4L2_PIX_FMT_UYVY
	.no_dead_strip	_cxusb_medion_try_s_fmt_vid_cap
.subsections_via_symbols
