	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function cam_mode
_cam_mode:                              ## @cam_mode
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r14
	pushq	%rbx
	subq	$16, %rsp
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	cmpl	%esi, (%rdi)
	je	LBB0_8
## %bb.1:
	movl	%esi, %r14d
	movq	%rdi, %rbx
	cmpl	$1, %esi
	je	LBB0_4
## %bb.2:
	testl	%r14d, %r14d
	jne	LBB0_7
## %bb.3:
	movq	%rbx, %rdi
	movl	$32, %esi
	jmp	LBB0_6
LBB0_4:
	cmpl	$0, 20(%rbx)
	je	LBB0_8
## %bb.5:
	movl	$0, 16(%rbx)
	movq	8(%rbx), %rdi
	leaq	L_.str(%rip), %rsi
	callq	_dev_info
	movq	%rbx, %rdi
	movl	$13, %esi
	xorl	%edx, %edx
	callq	_write_reg
	movq	%rbx, %rdi
	movl	$14, %esi
	movl	$1, %edx
	callq	_write_reg
	movq	%rbx, %rdi
	movl	$8, %esi
	movl	$64, %edx
	movl	$64, %ecx
	callq	_write_regm
	leaq	-20(%rbp), %rdx
	movq	%rbx, %rdi
	movl	$18, %esi
	callq	_read_reg
	movq	%rbx, %rdi
	movl	$8, %esi
LBB0_6:
	movl	$128, %edx
	movl	$128, %ecx
	callq	_write_regm
LBB0_7:
	movl	%r14d, (%rbx)
LBB0_8:
	addq	$16, %rsp
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"enable cam buffer mode\n"

	.no_dead_strip	_cam_mode
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function cam_mode
_cam_mode:                              ; @cam_mode
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #48
	.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
	ldr	w8, [x0]
	cmp	w8, w1
	b.eq	LBB0_8
; %bb.1:
	mov	x19, x1
	mov	x20, x0
	cmp	w1, #1
	b.eq	LBB0_4
; %bb.2:
	cbnz	w19, LBB0_7
; %bb.3:
	mov	x0, x20
	mov	w1, #32
	b	LBB0_6
LBB0_4:
	ldr	w8, [x20, #20]
	cbz	w8, LBB0_8
; %bb.5:
	str	wzr, [x20, #16]
	ldr	x0, [x20, #8]
Lloh0:
	adrp	x1, l_.str@PAGE
Lloh1:
	add	x1, x1, l_.str@PAGEOFF
	bl	_dev_info
	mov	x0, x20
	mov	w1, #13
	mov	w2, #0
	bl	_write_reg
	mov	x0, x20
	mov	w1, #14
	mov	w2, #1
	bl	_write_reg
	mov	x0, x20
	mov	w1, #8
	mov	w2, #64
	mov	w3, #64
	bl	_write_regm
	add	x2, sp, #12
	mov	x0, x20
	mov	w1, #18
	bl	_read_reg
	mov	x0, x20
	mov	w1, #8
LBB0_6:
	mov	w2, #128
	mov	w3, #128
	bl	_write_regm
LBB0_7:
	str	w19, [x20]
LBB0_8:
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #48
	ret
	.loh AdrpAdd	Lloh0, Lloh1
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"enable cam buffer mode\n"

	.no_dead_strip	_cam_mode
.subsections_via_symbols
