	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function adv7511_set_colormap
_adv7511_set_colormap:                  ## @adv7511_set_colormap
	.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
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%ecx, %r14d
	movq	%rdx, %r12
	movl	%esi, %r13d
	movq	%rdi, %r15
	movl	(%rdi), %ebx
	movl	$1, %edi
	callq	_ADV7511_REG_CSC_UPPER
	movq	_ADV7511_CSC_UPDATE_MODE@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	movl	%ebx, %edi
	movl	%eax, %esi
	movl	%ecx, %edx
	callq	_regmap_update_bits
	testl	%r13d, %r13d
	je	LBB0_4
## %bb.1:
	xorl	%ebx, %ebx
	.p2align	4, 0x90
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	movl	(%r15), %r13d
	movl	%ebx, %edi
	callq	_ADV7511_REG_CSC_UPPER
	movl	(%r12,%rbx,4), %ecx
	sarl	$8, %ecx
	movl	%r13d, %edi
	movl	%eax, %esi
	movl	$31, %edx
	callq	_regmap_update_bits
	movl	(%r15), %r13d
	movl	%ebx, %edi
	callq	_ADV7511_REG_CSC_LOWER
	movzbl	(%r12,%rbx,4), %edx
	movl	%r13d, %edi
	movl	%eax, %esi
	callq	_regmap_write
	incq	%rbx
	cmpq	$12, %rbx
	jne	LBB0_2
## %bb.3:
	movl	(%r15), %ebx
	xorl	%edi, %edi
	callq	_ADV7511_REG_CSC_UPPER
	orl	$4, %r14d
	shll	$5, %r14d
	movl	%ebx, %edi
	movl	%eax, %esi
	movl	$224, %edx
	movl	%r14d, %ecx
	jmp	LBB0_5
LBB0_4:
	movl	(%r15), %ebx
	xorl	%edi, %edi
	callq	_ADV7511_REG_CSC_UPPER
	movl	%ebx, %edi
	movl	%eax, %esi
	movl	$128, %edx
	xorl	%ecx, %ecx
LBB0_5:
	callq	_regmap_update_bits
	movl	(%r15), %ebx
	movl	$1, %edi
	callq	_ADV7511_REG_CSC_UPPER
	movq	_ADV7511_CSC_UPDATE_MODE@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edx
	movl	%ebx, %edi
	movl	%eax, %esi
	xorl	%ecx, %ecx
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_regmap_update_bits             ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_ADV7511_CSC_UPDATE_MODE,4,2    ## @ADV7511_CSC_UPDATE_MODE
	.no_dead_strip	_adv7511_set_colormap
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function adv7511_set_colormap
_adv7511_set_colormap:                  ; @adv7511_set_colormap
	.cfi_startproc
; %bb.0:
	stp	x26, x25, [sp, #-80]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	mov	x20, x3
	mov	x21, x2
	mov	x22, x1
	mov	x19, x0
	ldr	w23, [x0]
	mov	w0, #1
	bl	_ADV7511_REG_CSC_UPPER
	mov	x1, x0
Lloh0:
	adrp	x24, _ADV7511_CSC_UPDATE_MODE@GOTPAGE
Lloh1:
	ldr	x24, [x24, _ADV7511_CSC_UPDATE_MODE@GOTPAGEOFF]
	ldr	w2, [x24]
	mov	x0, x23
	mov	x3, x2
	bl	_regmap_update_bits
	cbz	w22, LBB0_4
; %bb.1:
	mov	x22, #0
LBB0_2:                                 ; =>This Inner Loop Header: Depth=1
	ldr	w23, [x19]
	mov	x0, x22
	bl	_ADV7511_REG_CSC_UPPER
	mov	x1, x0
	lsl	x25, x22, #2
	ldr	w8, [x21, x25]
	asr	w3, w8, #8
	mov	x0, x23
	mov	w2, #31
	bl	_regmap_update_bits
	ldr	w23, [x19]
	mov	x0, x22
	bl	_ADV7511_REG_CSC_LOWER
	mov	x1, x0
	ldrb	w2, [x21, x25]
	mov	x0, x23
	bl	_regmap_write
	add	x22, x22, #1
	cmp	x22, #12
	b.ne	LBB0_2
; %bb.3:
	ldr	w21, [x19]
	mov	w0, #0
	bl	_ADV7511_REG_CSC_UPPER
	mov	x1, x0
	lsl	w8, w20, #5
	orr	w3, w8, #0x80
	mov	x0, x21
	mov	w2, #224
	b	LBB0_5
LBB0_4:
	ldr	w20, [x19]
	mov	w0, #0
	bl	_ADV7511_REG_CSC_UPPER
	mov	x1, x0
	mov	x0, x20
	mov	w2, #128
	mov	w3, #0
LBB0_5:
	bl	_regmap_update_bits
	ldr	w19, [x19]
	mov	w0, #1
	bl	_ADV7511_REG_CSC_UPPER
	mov	x1, x0
	ldr	w2, [x24]
	mov	x0, x19
	mov	w3, #0
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp], #80             ; 16-byte Folded Reload
	b	_regmap_update_bits
	.loh AdrpLdrGot	Lloh0, Lloh1
	.cfi_endproc
                                        ; -- End function
	.comm	_ADV7511_CSC_UPDATE_MODE,4,2    ; @ADV7511_CSC_UPDATE_MODE
	.no_dead_strip	_adv7511_set_colormap
.subsections_via_symbols
