	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function intel_cursor_plane_create
_intel_cursor_plane_create:             ## @intel_cursor_plane_create
	.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	%esi, %r12d
	movq	%rdi, %r15
	xorl	%eax, %eax
	callq	_intel_plane_alloc
	movq	%rax, %r14
	movq	%rax, %rbx
	movq	%rax, %rdi
	callq	_IS_ERR
	testq	%rax, %rax
	je	LBB0_1
LBB0_12:
	movq	%rbx, %rax
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_1:
	movl	%r12d, (%rbx)
	movl	%r12d, 4(%rbx)
	movq	_PLANE_CURSOR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	%esi, 44(%rbx)
	movl	%r12d, %edi
	callq	_INTEL_FRONTBUFFER
	movl	%eax, 48(%rbx)
	movq	%r15, %rdi
	callq	_IS_I845G
	movq	_i845_check_cursor@GOTPCREL(%rip), %rcx
	movq	_i845_cursor_get_hw_state@GOTPCREL(%rip), %rdx
	movq	_i845_disable_cursor@GOTPCREL(%rip), %rsi
	movq	_i845_update_cursor@GOTPCREL(%rip), %r13
	movq	%r15, %rdi
	movq	_i845_cursor_max_stride@GOTPCREL(%rip), %r15
	testq	%rax, %rax
	movq	%rdi, -56(%rbp)                 ## 8-byte Spill
	jne	LBB0_4
## %bb.2:
	callq	_IS_I865G
	movq	_i845_disable_cursor@GOTPCREL(%rip), %rsi
	movq	_i845_cursor_get_hw_state@GOTPCREL(%rip), %rdx
	movq	_i845_check_cursor@GOTPCREL(%rip), %rcx
	testq	%rax, %rax
	jne	LBB0_4
## %bb.3:
	movq	_i9xx_check_cursor@GOTPCREL(%rip), %rcx
	movq	_i9xx_cursor_get_hw_state@GOTPCREL(%rip), %rdx
	movq	_i9xx_disable_cursor@GOTPCREL(%rip), %rsi
	movq	_i9xx_update_cursor@GOTPCREL(%rip), %r13
	movq	_i9xx_cursor_max_stride@GOTPCREL(%rip), %r15
LBB0_4:
	movl	(%r15), %eax
	movl	%eax, 40(%rbx)
	movl	(%r13), %eax
	movl	%eax, 36(%rbx)
	movl	(%rsi), %eax
	movl	%eax, 32(%rbx)
	movl	(%rdx), %eax
	movl	%eax, 28(%rbx)
	movl	(%rcx), %eax
	movl	%eax, 24(%rbx)
	movq	$-1, 16(%rbx)
	movq	-56(%rbp), %r15                 ## 8-byte Reload
	movq	%r15, %rdi
	callq	_IS_I845G
	testq	%rax, %rax
	jne	LBB0_7
## %bb.5:
	movq	%r15, %rdi
	callq	_IS_I865G
	testq	%rax, %rax
	jne	LBB0_7
## %bb.6:
	movq	%r15, %rdi
	callq	_HAS_CUR_FBC
	testq	%rax, %rax
	je	LBB0_8
LBB0_7:
	movl	$-1, 12(%rbx)
LBB0_8:
	movl	%r12d, %edi
	callq	_BIT
	movl	%eax, -48(%rbp)                 ## 4-byte Spill
	addq	$8, %r14
	movq	_intel_cursor_formats@GOTPCREL(%rip), %rax
	movl	(%rax), %r13d
	movl	%r13d, %edi
	callq	_ARRAY_SIZE
	movl	%eax, -44(%rbp)                 ## 4-byte Spill
	movq	_cursor_format_modifiers@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movq	%rax, -72(%rbp)                 ## 8-byte Spill
	movq	_DRM_PLANE_TYPE_CURSOR@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movq	%rax, -64(%rbp)                 ## 8-byte Spill
	movl	%r12d, %edi
	callq	_pipe_name
                                        ## kill: def $eax killed $eax def $rax
	leaq	L_.str(%rip), %r10
	movq	_intel_cursor_plane_funcs@GOTPCREL(%rip), %rcx
	movq	%r15, %rdi
	movq	%r14, %rsi
	movl	-48(%rbp), %edx                 ## 4-byte Reload
	movl	%r13d, %r8d
	movl	-44(%rbp), %r9d                 ## 4-byte Reload
	pushq	%rax
	pushq	%r10
	pushq	-64(%rbp)                       ## 8-byte Folded Reload
	pushq	-72(%rbp)                       ## 8-byte Folded Reload
	callq	_drm_universal_plane_init
	addq	$32, %rsp
	testl	%eax, %eax
	je	LBB0_9
## %bb.13:
	movl	%eax, %r12d
	movq	%rbx, %rdi
	callq	_intel_plane_free
	movl	%r12d, %edi
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_ERR_PTR                        ## TAILCALL
LBB0_9:
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	callq	_INTEL_GEN
	cmpl	$4, %eax
	jl	LBB0_11
## %bb.10:
	movq	_DRM_MODE_ROTATE_0@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_DRM_MODE_ROTATE_180@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	orl	%esi, %edx
	movq	%r14, %rdi
	callq	_drm_plane_create_rotation_property
LBB0_11:
	movq	_intel_plane_helper_funcs@GOTPCREL(%rip), %rsi
	movq	%r14, %rdi
	callq	_drm_plane_helper_add
	jmp	LBB0_12
	.cfi_endproc
                                        ## -- End function
	.comm	_PLANE_CURSOR,4,2               ## @PLANE_CURSOR
	.comm	_i845_cursor_max_stride,4,2     ## @i845_cursor_max_stride
	.comm	_i845_update_cursor,4,2         ## @i845_update_cursor
	.comm	_i845_disable_cursor,4,2        ## @i845_disable_cursor
	.comm	_i845_cursor_get_hw_state,4,2   ## @i845_cursor_get_hw_state
	.comm	_i845_check_cursor,4,2          ## @i845_check_cursor
	.comm	_i9xx_cursor_max_stride,4,2     ## @i9xx_cursor_max_stride
	.comm	_i9xx_update_cursor,4,2         ## @i9xx_update_cursor
	.comm	_i9xx_disable_cursor,4,2        ## @i9xx_disable_cursor
	.comm	_i9xx_cursor_get_hw_state,4,2   ## @i9xx_cursor_get_hw_state
	.comm	_i9xx_check_cursor,4,2          ## @i9xx_check_cursor
	.comm	_intel_cursor_plane_funcs,4,2   ## @intel_cursor_plane_funcs
	.comm	_intel_cursor_formats,4,2       ## @intel_cursor_formats
	.comm	_cursor_format_modifiers,4,2    ## @cursor_format_modifiers
	.comm	_DRM_PLANE_TYPE_CURSOR,4,2      ## @DRM_PLANE_TYPE_CURSOR
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"cursor %c"

	.comm	_DRM_MODE_ROTATE_0,4,2          ## @DRM_MODE_ROTATE_0
	.comm	_DRM_MODE_ROTATE_180,4,2        ## @DRM_MODE_ROTATE_180
	.comm	_intel_plane_helper_funcs,4,2   ## @intel_plane_helper_funcs
	.no_dead_strip	_intel_cursor_plane_create
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function intel_cursor_plane_create
_intel_cursor_plane_create:             ; @intel_cursor_plane_create
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	stp	x28, x27, [sp, #16]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #32]             ; 16-byte Folded Spill
	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
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	mov	x21, x1
	mov	x20, x0
	bl	_intel_plane_alloc
	mov	x19, x0
	bl	_IS_ERR
	cbz	x0, LBB0_2
LBB0_1:
	mov	x0, x19
	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
	ldp	x26, x25, [sp, #32]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #112
	ret
LBB0_2:
	stp	w21, w21, [x19]
Lloh0:
	adrp	x8, _PLANE_CURSOR@GOTPAGE
Lloh1:
	ldr	x8, [x8, _PLANE_CURSOR@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	str	w1, [x19, #44]
	mov	x0, x21
	bl	_INTEL_FRONTBUFFER
	str	w0, [x19, #48]
	mov	x0, x20
	bl	_IS_I845G
	cbnz	x0, LBB0_4
; %bb.3:
	mov	x0, x20
	bl	_IS_I865G
	cbz	x0, LBB0_14
LBB0_4:
Lloh3:
	adrp	x8, _i845_check_cursor@GOTPAGE
Lloh4:
	ldr	x8, [x8, _i845_check_cursor@GOTPAGEOFF]
Lloh5:
	adrp	x9, _i845_cursor_get_hw_state@GOTPAGE
Lloh6:
	ldr	x9, [x9, _i845_cursor_get_hw_state@GOTPAGEOFF]
Lloh7:
	adrp	x10, _i845_disable_cursor@GOTPAGE
Lloh8:
	ldr	x10, [x10, _i845_disable_cursor@GOTPAGEOFF]
Lloh9:
	adrp	x11, _i845_update_cursor@GOTPAGE
Lloh10:
	ldr	x11, [x11, _i845_update_cursor@GOTPAGEOFF]
Lloh11:
	adrp	x12, _i845_cursor_max_stride@GOTPAGE
Lloh12:
	ldr	x12, [x12, _i845_cursor_max_stride@GOTPAGEOFF]
LBB0_5:
	ldr	w12, [x12]
	ldr	w11, [x11]
	ldr	w10, [x10]
	stp	w11, w12, [x19, #36]
	ldr	w9, [x9]
	ldr	w8, [x8]
	stp	w9, w10, [x19, #28]
	str	w8, [x19, #24]
	movi.2d	v0, #0xffffffffffffffff
	str	d0, [x19, #16]
	mov	x0, x20
	bl	_IS_I845G
	cbnz	x0, LBB0_8
; %bb.6:
	mov	x0, x20
	bl	_IS_I865G
	cbnz	x0, LBB0_8
; %bb.7:
	mov	x0, x20
	bl	_HAS_CUR_FBC
	cbz	x0, LBB0_9
LBB0_8:
	mov	w8, #-1
	str	w8, [x19, #12]
LBB0_9:
	mov	x0, x21
	bl	_BIT
	mov	x23, x0
	add	x22, x19, #8
Lloh13:
	adrp	x8, _intel_cursor_formats@GOTPAGE
Lloh14:
	ldr	x8, [x8, _intel_cursor_formats@GOTPAGEOFF]
Lloh15:
	ldr	w24, [x8]
	mov	x0, x24
	bl	_ARRAY_SIZE
	mov	x25, x0
Lloh16:
	adrp	x8, _cursor_format_modifiers@GOTPAGE
Lloh17:
	ldr	x8, [x8, _cursor_format_modifiers@GOTPAGEOFF]
Lloh18:
	ldr	w26, [x8]
Lloh19:
	adrp	x8, _DRM_PLANE_TYPE_CURSOR@GOTPAGE
Lloh20:
	ldr	x8, [x8, _DRM_PLANE_TYPE_CURSOR@GOTPAGEOFF]
Lloh21:
	ldr	w27, [x8]
	mov	x0, x21
	bl	_pipe_name
Lloh22:
	adrp	x8, l_.str@PAGE
Lloh23:
	add	x8, x8, l_.str@PAGEOFF
	str	w0, [sp, #8]
	str	x8, [sp]
Lloh24:
	adrp	x3, _intel_cursor_plane_funcs@GOTPAGE
Lloh25:
	ldr	x3, [x3, _intel_cursor_plane_funcs@GOTPAGEOFF]
	mov	x0, x20
	mov	x1, x22
	mov	x2, x23
	mov	x4, x24
	mov	x5, x25
	mov	x6, x26
	mov	x7, x27
	bl	_drm_universal_plane_init
	cbz	w0, LBB0_11
; %bb.10:
	mov	x21, x0
	mov	x0, x19
	bl	_intel_plane_free
	mov	x0, x21
	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
	ldp	x26, x25, [sp, #32]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #112
	b	_ERR_PTR
LBB0_11:
	mov	x0, x20
	bl	_INTEL_GEN
	cmp	w0, #4
	b.lt	LBB0_13
; %bb.12:
Lloh26:
	adrp	x8, _DRM_MODE_ROTATE_0@GOTPAGE
Lloh27:
	ldr	x8, [x8, _DRM_MODE_ROTATE_0@GOTPAGEOFF]
Lloh28:
	ldr	w1, [x8]
Lloh29:
	adrp	x8, _DRM_MODE_ROTATE_180@GOTPAGE
Lloh30:
	ldr	x8, [x8, _DRM_MODE_ROTATE_180@GOTPAGEOFF]
Lloh31:
	ldr	w8, [x8]
	orr	w2, w8, w1
	mov	x0, x22
	bl	_drm_plane_create_rotation_property
LBB0_13:
Lloh32:
	adrp	x1, _intel_plane_helper_funcs@GOTPAGE
Lloh33:
	ldr	x1, [x1, _intel_plane_helper_funcs@GOTPAGEOFF]
	mov	x0, x22
	bl	_drm_plane_helper_add
	b	LBB0_1
LBB0_14:
Lloh34:
	adrp	x8, _i9xx_check_cursor@GOTPAGE
Lloh35:
	ldr	x8, [x8, _i9xx_check_cursor@GOTPAGEOFF]
Lloh36:
	adrp	x9, _i9xx_cursor_get_hw_state@GOTPAGE
Lloh37:
	ldr	x9, [x9, _i9xx_cursor_get_hw_state@GOTPAGEOFF]
Lloh38:
	adrp	x10, _i9xx_disable_cursor@GOTPAGE
Lloh39:
	ldr	x10, [x10, _i9xx_disable_cursor@GOTPAGEOFF]
Lloh40:
	adrp	x11, _i9xx_update_cursor@GOTPAGE
Lloh41:
	ldr	x11, [x11, _i9xx_update_cursor@GOTPAGEOFF]
Lloh42:
	adrp	x12, _i9xx_cursor_max_stride@GOTPAGE
Lloh43:
	ldr	x12, [x12, _i9xx_cursor_max_stride@GOTPAGEOFF]
	b	LBB0_5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh11, Lloh12
	.loh AdrpLdrGot	Lloh9, Lloh10
	.loh AdrpLdrGot	Lloh7, Lloh8
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh24, Lloh25
	.loh AdrpAdd	Lloh22, Lloh23
	.loh AdrpLdrGotLdr	Lloh19, Lloh20, Lloh21
	.loh AdrpLdrGotLdr	Lloh16, Lloh17, Lloh18
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh29, Lloh30, Lloh31
	.loh AdrpLdrGotLdr	Lloh26, Lloh27, Lloh28
	.loh AdrpLdrGot	Lloh32, Lloh33
	.loh AdrpLdrGot	Lloh42, Lloh43
	.loh AdrpLdrGot	Lloh40, Lloh41
	.loh AdrpLdrGot	Lloh38, Lloh39
	.loh AdrpLdrGot	Lloh36, Lloh37
	.loh AdrpLdrGot	Lloh34, Lloh35
	.cfi_endproc
                                        ; -- End function
	.comm	_PLANE_CURSOR,4,2               ; @PLANE_CURSOR
	.comm	_i845_cursor_max_stride,4,2     ; @i845_cursor_max_stride
	.comm	_i845_update_cursor,4,2         ; @i845_update_cursor
	.comm	_i845_disable_cursor,4,2        ; @i845_disable_cursor
	.comm	_i845_cursor_get_hw_state,4,2   ; @i845_cursor_get_hw_state
	.comm	_i845_check_cursor,4,2          ; @i845_check_cursor
	.comm	_i9xx_cursor_max_stride,4,2     ; @i9xx_cursor_max_stride
	.comm	_i9xx_update_cursor,4,2         ; @i9xx_update_cursor
	.comm	_i9xx_disable_cursor,4,2        ; @i9xx_disable_cursor
	.comm	_i9xx_cursor_get_hw_state,4,2   ; @i9xx_cursor_get_hw_state
	.comm	_i9xx_check_cursor,4,2          ; @i9xx_check_cursor
	.comm	_intel_cursor_plane_funcs,4,2   ; @intel_cursor_plane_funcs
	.comm	_intel_cursor_formats,4,2       ; @intel_cursor_formats
	.comm	_cursor_format_modifiers,4,2    ; @cursor_format_modifiers
	.comm	_DRM_PLANE_TYPE_CURSOR,4,2      ; @DRM_PLANE_TYPE_CURSOR
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"cursor %c"

	.comm	_DRM_MODE_ROTATE_0,4,2          ; @DRM_MODE_ROTATE_0
	.comm	_DRM_MODE_ROTATE_180,4,2        ; @DRM_MODE_ROTATE_180
	.comm	_intel_plane_helper_funcs,4,2   ; @intel_plane_helper_funcs
	.no_dead_strip	_intel_cursor_plane_create
.subsections_via_symbols
