	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function tw9910_s_std
_tw9910_s_std:                          ## @tw9910_s_std
	.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	%rbx
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%esi, %ebx
	callq	_v4l2_get_subdevdata
	movq	%rax, %r15
	movq	%rax, %rdi
	callq	_to_tw9910
	movq	_V4L2_STD_NTSC@GOTPCREL(%rip), %rcx
	movq	_V4L2_STD_PAL@GOTPCREL(%rip), %rdx
	movl	(%rdx), %edx
	orl	(%rcx), %edx
	testl	%ebx, %edx
	je	LBB0_1
## %bb.2:
	movl	%ebx, (%rax)
	movq	_V4L2_STD_525_60@GOTPCREL(%rip), %rax
	xorl	%ecx, %ecx
	andl	(%rax), %ebx
	setne	%cl
	movq	_VVBI@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	$288, %eax                      ## imm = 0x120
	movl	$240, %r14d
	cmovel	%eax, %r14d
	movl	$24, %eax
	movl	$18, %ebx
	cmovel	%eax, %ebx
	shll	$4, %ecx
	movq	%r15, %rdi
	movl	$16, %edx
	callq	_tw9910_mask_set
	testl	%eax, %eax
	jne	LBB0_5
## %bb.3:
	movq	_CROP_HI@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	%r14d, %edx
	shrl	$4, %edx
	andl	$-16, %edx
	orl	$2, %edx
	movq	%r15, %rdi
	callq	_i2c_smbus_write_byte_data
	testl	%eax, %eax
	jne	LBB0_5
## %bb.4:
	movq	_VDELAY_LO@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r15, %rdi
	movl	%ebx, %edx
	callq	_i2c_smbus_write_byte_data
	testl	%eax, %eax
	jne	LBB0_5
## %bb.6:
	movq	_VACTIVE_LO@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	andl	$240, %r14d
	movq	%r15, %rdi
	movl	%r14d, %edx
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_i2c_smbus_write_byte_data      ## TAILCALL
LBB0_1:
	movq	_EINVAL@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
LBB0_5:
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_V4L2_STD_NTSC,4,2              ## @V4L2_STD_NTSC
	.comm	_V4L2_STD_PAL,4,2               ## @V4L2_STD_PAL
	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_V4L2_STD_525_60,4,2            ## @V4L2_STD_525_60
	.comm	_VVBI,4,2                       ## @VVBI
	.comm	_CROP_HI,4,2                    ## @CROP_HI
	.comm	_VDELAY_LO,4,2                  ## @VDELAY_LO
	.comm	_VACTIVE_LO,4,2                 ## @VACTIVE_LO
	.no_dead_strip	_tw9910_s_std
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function tw9910_s_std
_tw9910_s_std:                          ; @tw9910_s_std
	.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	x20, x1
	bl	_v4l2_get_subdevdata
	mov	x19, x0
	bl	_to_tw9910
Lloh0:
	adrp	x8, _V4L2_STD_NTSC@GOTPAGE
Lloh1:
	ldr	x8, [x8, _V4L2_STD_NTSC@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
Lloh3:
	adrp	x9, _V4L2_STD_PAL@GOTPAGE
Lloh4:
	ldr	x9, [x9, _V4L2_STD_PAL@GOTPAGEOFF]
Lloh5:
	ldr	w9, [x9]
	orr	w8, w9, w8
	tst	w8, w20
	b.eq	LBB0_5
; %bb.1:
	str	w20, [x0]
Lloh6:
	adrp	x8, _V4L2_STD_525_60@GOTPAGE
Lloh7:
	ldr	x8, [x8, _V4L2_STD_525_60@GOTPAGEOFF]
Lloh8:
	ldr	w8, [x8]
	tst	w8, w20
	cset	w8, ne
Lloh9:
	adrp	x9, _VVBI@GOTPAGE
Lloh10:
	ldr	x9, [x9, _VVBI@GOTPAGEOFF]
Lloh11:
	ldr	w1, [x9]
	lsl	w3, w8, #4
	mov	w8, #240
	mov	w9, #288
	csel	w21, w9, w8, eq
	mov	w8, #18
	mov	w9, #24
	csel	w20, w9, w8, eq
	mov	x0, x19
	mov	w2, #16
	bl	_tw9910_mask_set
	cbnz	w0, LBB0_6
; %bb.2:
Lloh12:
	adrp	x8, _CROP_HI@GOTPAGE
Lloh13:
	ldr	x8, [x8, _CROP_HI@GOTPAGEOFF]
Lloh14:
	ldr	w1, [x8]
	lsr	w8, w21, #4
	and	w8, w8, #0x10
	orr	w2, w8, #0x2
	mov	x0, x19
	bl	_i2c_smbus_write_byte_data
	cbnz	w0, LBB0_6
; %bb.3:
Lloh15:
	adrp	x8, _VDELAY_LO@GOTPAGE
Lloh16:
	ldr	x8, [x8, _VDELAY_LO@GOTPAGEOFF]
Lloh17:
	ldr	w1, [x8]
	mov	x0, x19
	mov	x2, x20
	bl	_i2c_smbus_write_byte_data
	cbnz	w0, LBB0_6
; %bb.4:
Lloh18:
	adrp	x8, _VACTIVE_LO@GOTPAGE
Lloh19:
	ldr	x8, [x8, _VACTIVE_LO@GOTPAGEOFF]
Lloh20:
	ldr	w1, [x8]
	and	w2, w21, #0xf0
	mov	x0, x19
	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
	b	_i2c_smbus_write_byte_data
LBB0_5:
Lloh21:
	adrp	x8, _EINVAL@GOTPAGE
Lloh22:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh23:
	ldr	w8, [x8]
	neg	w0, w8
LBB0_6:
	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
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.cfi_endproc
                                        ; -- End function
	.comm	_V4L2_STD_NTSC,4,2              ; @V4L2_STD_NTSC
	.comm	_V4L2_STD_PAL,4,2               ; @V4L2_STD_PAL
	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_V4L2_STD_525_60,4,2            ; @V4L2_STD_525_60
	.comm	_VVBI,4,2                       ; @VVBI
	.comm	_CROP_HI,4,2                    ; @CROP_HI
	.comm	_VDELAY_LO,4,2                  ; @VDELAY_LO
	.comm	_VACTIVE_LO,4,2                 ; @VACTIVE_LO
	.no_dead_strip	_tw9910_s_std
.subsections_via_symbols
