	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function vlv_update_plane
_vlv_update_plane:                      ## @vlv_update_plane
	.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	$56, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdx, %r14
	movq	%rsi, -48(%rbp)                 ## 8-byte Spill
	movq	%rdi, %rbx
	movl	8(%rdi), %edi
	callq	_to_i915
	movq	%rax, -56(%rbp)                 ## 8-byte Spill
	movl	(%rbx), %eax
	movl	%eax, -60(%rbp)                 ## 4-byte Spill
	movl	4(%rbx), %eax
	movl	%eax, -64(%rbp)                 ## 4-byte Spill
	movq	8(%r14), %rax
	movl	(%rax), %eax
	movl	%eax, -88(%rbp)                 ## 4-byte Spill
	leaq	16(%r14), %rbx
	movl	20(%r14), %eax
	shll	$16, %eax
	orl	16(%r14), %eax
	movl	%eax, -68(%rbp)                 ## 4-byte Spill
	movq	%rbx, %rdi
	callq	_drm_rect_width
	movl	%eax, %r13d
	movq	%rbx, %rdi
	callq	_drm_rect_height
	movl	%eax, %r15d
	movq	8(%r14), %rax
	movl	4(%rax), %r12d
	movl	8(%rax), %ebx
	movl	(%r14), %eax
	movl	%eax, -76(%rbp)                 ## 4-byte Spill
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
	callq	_vlv_sprite_ctl_crtc
	movl	%eax, -48(%rbp)                 ## 4-byte Spill
	decl	%r13d
	movl	%r12d, -80(%rbp)                ## 4-byte Spill
	movl	%r12d, %edi
	movl	-60(%rbp), %r12d                ## 4-byte Reload
	movl	%ebx, -84(%rbp)                 ## 4-byte Spill
	movl	%ebx, %esi
	movq	%r14, %rdx
	xorl	%ecx, %ecx
	callq	_intel_fb_xy_to_linear
	movl	%eax, -72(%rbp)                 ## 4-byte Spill
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	callq	_spin_lock_irqsave
	movl	%r12d, %edi
	movl	-64(%rbp), %ebx                 ## 4-byte Reload
	movl	%ebx, %esi
	callq	_SPSTRIDE
	movq	8(%r14), %rcx
	movl	12(%rcx), %esi
	movl	%eax, %edi
	callq	_I915_WRITE_FW
	movl	%r12d, %edi
	movl	%ebx, %esi
	callq	_SPPOS
	movl	%eax, %edi
	movl	-68(%rbp), %esi                 ## 4-byte Reload
	callq	_I915_WRITE_FW
	movl	%r12d, %edi
	movl	%ebx, %esi
	callq	_SPSIZE
	shll	$16, %r15d
	addl	$-65536, %r15d                  ## imm = 0xFFFF0000
	orl	%r13d, %r15d
	movl	%eax, %edi
	movl	%r15d, %esi
	movl	%ebx, %r15d
	callq	_I915_WRITE_FW
	movl	%r12d, %edi
	movl	%ebx, %esi
	callq	_SPCONSTALPHA
	movl	%eax, %edi
	xorl	%esi, %esi
	callq	_I915_WRITE_FW
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	callq	_IS_CHERRYVIEW
	testq	%rax, %rax
	je	LBB0_3
## %bb.1:
	movq	_PIPE_B@GOTPCREL(%rip), %rax
	cmpl	(%rax), %r12d
	jne	LBB0_3
## %bb.2:
	movq	%r14, %rdi
	callq	_chv_update_csc
LBB0_3:
	cmpq	$0, 40(%r14)
	je	LBB0_5
## %bb.4:
	movl	%r12d, %edi
	movl	%r15d, %esi
	callq	_SPKEYMINVAL
	movl	24(%r14), %esi
	movl	%eax, %edi
	callq	_I915_WRITE_FW
	movl	%r12d, %edi
	movl	%r15d, %esi
	callq	_SPKEYMSK
	movl	28(%r14), %esi
	movl	%eax, %edi
	callq	_I915_WRITE_FW
	movl	%r12d, %edi
	movl	%r15d, %esi
	callq	_SPKEYMAXVAL
	movl	32(%r14), %esi
	movl	%eax, %edi
	callq	_I915_WRITE_FW
LBB0_5:
	movl	-48(%rbp), %ebx                 ## 4-byte Reload
	orl	-76(%rbp), %ebx                 ## 4-byte Folded Reload
	movl	%r12d, %edi
	movl	%r15d, %esi
	callq	_SPLINOFF
	movl	%eax, %edi
	movl	-72(%rbp), %esi                 ## 4-byte Reload
	callq	_I915_WRITE_FW
	movl	%r12d, %edi
	movl	%r15d, %esi
	callq	_SPTILEOFF
	movl	-84(%rbp), %esi                 ## 4-byte Reload
	shll	$16, %esi
	orl	-80(%rbp), %esi                 ## 4-byte Folded Reload
	movl	%eax, %edi
	callq	_I915_WRITE_FW
	movl	%r12d, %edi
	movl	%r15d, %esi
	callq	_SPCNTR
	movl	%eax, %edi
	movl	%ebx, %esi
	callq	_I915_WRITE_FW
	movl	%r12d, %edi
	movl	%r15d, %esi
	callq	_SPSURF
	movl	%eax, %ebx
	movq	%r14, %rdi
	callq	_intel_plane_ggtt_offset
	movl	-88(%rbp), %esi                 ## 4-byte Reload
	addl	%eax, %esi
	movl	%ebx, %edi
	callq	_I915_WRITE_FW
	movq	%r14, %rdi
	callq	_vlv_update_clrc
	movq	%r14, %rdi
	callq	_vlv_update_gamma
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	addq	$56, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_spin_unlock_irqrestore         ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_PIPE_B,4,2                     ## @PIPE_B
	.no_dead_strip	_vlv_update_plane
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function vlv_update_plane
_vlv_update_plane:                      ; @vlv_update_plane
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #128
	.cfi_def_cfa_offset 128
	stp	x28, x27, [sp, #32]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #48]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #64]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #80]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #96]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #112]            ; 16-byte Folded Spill
	add	x29, sp, #112
	.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
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	mov	x19, x2
	mov	x25, x1
	mov	x22, x0
	ldr	w0, [x0, #8]
	bl	_to_i915
	mov	x20, x0
	ldp	w21, w22, [x22]
	ldr	x8, [x19, #8]
	ldr	w8, [x8]
	str	w8, [sp, #28]                   ; 4-byte Folded Spill
	mov	x23, x19
	ldr	w28, [x23, #16]!
	ldr	w24, [x19, #20]
	mov	x0, x23
	bl	_drm_rect_width
	mov	x26, x0
	mov	x0, x23
	bl	_drm_rect_height
	str	w0, [sp, #12]                   ; 4-byte Folded Spill
	ldr	x8, [x19, #8]
	ldp	w23, w27, [x8, #4]
	ldr	w8, [x19]
	str	w8, [sp, #20]                   ; 4-byte Folded Spill
	mov	x0, x25
	bl	_vlv_sprite_ctl_crtc
	str	w0, [sp, #16]                   ; 4-byte Folded Spill
	sub	w25, w26, #1
	str	w23, [sp, #24]                  ; 4-byte Folded Spill
	mov	x0, x23
	mov	x1, x27
	mov	x2, x19
	mov	w3, #0
	bl	_intel_fb_xy_to_linear
	mov	x26, x0
	mov	x0, x20
	bl	_spin_lock_irqsave
	mov	x0, x21
	mov	x1, x22
	bl	_SPSTRIDE
	ldr	x8, [x19, #8]
	ldr	w1, [x8, #12]
	bl	_I915_WRITE_FW
	mov	x0, x21
	mov	x1, x22
	bl	_SPPOS
	orr	w1, w28, w24, lsl #16
	bl	_I915_WRITE_FW
	mov	x0, x21
	mov	x1, x22
	bl	_SPSIZE
	ldr	w8, [sp, #12]                   ; 4-byte Folded Reload
	lsl	w8, w8, #16
	sub	w8, w8, #16, lsl #12            ; =65536
	orr	w1, w8, w25
	bl	_I915_WRITE_FW
	mov	x0, x21
	mov	x1, x22
	bl	_SPCONSTALPHA
	mov	w1, #0
	bl	_I915_WRITE_FW
	mov	x0, x20
	bl	_IS_CHERRYVIEW
	cbz	x0, LBB0_3
; %bb.1:
Lloh0:
	adrp	x8, _PIPE_B@GOTPAGE
Lloh1:
	ldr	x8, [x8, _PIPE_B@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	cmp	w21, w8
	b.ne	LBB0_3
; %bb.2:
	mov	x0, x19
	bl	_chv_update_csc
LBB0_3:
	ldr	x8, [x19, #40]
	cbz	x8, LBB0_5
; %bb.4:
	mov	x0, x21
	mov	x1, x22
	bl	_SPKEYMINVAL
	ldr	w1, [x19, #24]
	bl	_I915_WRITE_FW
	mov	x0, x21
	mov	x1, x22
	bl	_SPKEYMSK
	ldr	w1, [x19, #28]
	bl	_I915_WRITE_FW
	mov	x0, x21
	mov	x1, x22
	bl	_SPKEYMAXVAL
	ldr	w1, [x19, #32]
	bl	_I915_WRITE_FW
LBB0_5:
	ldp	w9, w8, [sp, #16]               ; 8-byte Folded Reload
	orr	w25, w9, w8
	mov	x0, x21
	mov	x1, x22
	bl	_SPLINOFF
	mov	x1, x26
	bl	_I915_WRITE_FW
	mov	x0, x21
	mov	x1, x22
	bl	_SPTILEOFF
	ldr	w8, [sp, #24]                   ; 4-byte Folded Reload
	orr	w1, w8, w27, lsl #16
	bl	_I915_WRITE_FW
	mov	x0, x21
	mov	x1, x22
	bl	_SPCNTR
	mov	x1, x25
	bl	_I915_WRITE_FW
	mov	x0, x21
	mov	x1, x22
	bl	_SPSURF
	mov	x21, x0
	mov	x0, x19
	bl	_intel_plane_ggtt_offset
	ldr	w8, [sp, #28]                   ; 4-byte Folded Reload
	add	w1, w0, w8
	mov	x0, x21
	bl	_I915_WRITE_FW
	mov	x0, x19
	bl	_vlv_update_clrc
	mov	x0, x19
	bl	_vlv_update_gamma
	mov	x0, x20
	ldp	x29, x30, [sp, #112]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #96]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #80]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #64]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #48]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #128
	b	_spin_unlock_irqrestore
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.cfi_endproc
                                        ; -- End function
	.comm	_PIPE_B,4,2                     ; @PIPE_B
	.no_dead_strip	_vlv_update_plane
.subsections_via_symbols
