	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_tegra_plane_state_add          ## -- Begin function tegra_plane_state_add
	.p2align	4, 0x90
_tegra_plane_state_add:                 ## @tegra_plane_state_add
	.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	%r12
	pushq	%rbx
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %rbx
	movq	%rdi, %r15
	movl	(%rsi), %esi
	movl	4(%rbx), %edi
	callq	_drm_atomic_get_crtc_state
	movq	%rax, %r12
	movq	%rax, %rdi
	callq	_IS_ERR
	testq	%rax, %rax
	je	LBB0_1
## %bb.5:
	movq	%r12, %rdi
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_PTR_ERR                        ## TAILCALL
LBB0_1:
	movq	_INT_MAX@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	xorl	%r14d, %r14d
	movq	%rbx, %rdi
	movq	%r12, %rsi
	xorl	%edx, %edx
	movl	$1, %r8d
	movl	$1, %r9d
	callq	_drm_atomic_helper_check_plane_state
	testl	%eax, %eax
	js	LBB0_2
## %bb.3:
	movq	%r12, %rdi
	callq	_to_dc_state
	movq	_WIN_A_ACT_REQ@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edx
	movb	(%r15), %cl
	shll	%cl, %edx
	orl	%edx, (%rax)
	jmp	LBB0_4
LBB0_2:
	movl	%eax, %r14d
LBB0_4:
	movl	%r14d, %eax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_INT_MAX,4,2                    ## @INT_MAX
	.comm	_WIN_A_ACT_REQ,4,2              ## @WIN_A_ACT_REQ
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_tegra_plane_state_add          ; -- Begin function tegra_plane_state_add
	.p2align	2
_tegra_plane_state_add:                 ; @tegra_plane_state_add
	.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	x21, x1
	mov	x19, x0
	ldp	w1, w0, [x1]
	bl	_drm_atomic_get_crtc_state
	mov	x20, x0
	bl	_IS_ERR
	cbz	x0, LBB0_2
; %bb.1:
	mov	x0, x20
	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	_PTR_ERR
LBB0_2:
Lloh0:
	adrp	x8, _INT_MAX@GOTPAGE
Lloh1:
	ldr	x8, [x8, _INT_MAX@GOTPAGEOFF]
Lloh2:
	ldr	w3, [x8]
	mov	x0, x21
	mov	x1, x20
	mov	w2, #0
	mov	w4, #1
	mov	w5, #1
	bl	_drm_atomic_helper_check_plane_state
	tbnz	w0, #31, LBB0_4
; %bb.3:
	mov	x0, x20
	bl	_to_dc_state
	mov	x8, x0
	mov	w0, #0
Lloh3:
	adrp	x9, _WIN_A_ACT_REQ@GOTPAGE
Lloh4:
	ldr	x9, [x9, _WIN_A_ACT_REQ@GOTPAGEOFF]
Lloh5:
	ldr	w9, [x9]
	ldr	w10, [x19]
	lsl	w9, w9, w10
	ldr	w10, [x8]
	orr	w9, w10, w9
	str	w9, [x8]
LBB0_4:
	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	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.cfi_endproc
                                        ; -- End function
	.comm	_INT_MAX,4,2                    ; @INT_MAX
	.comm	_WIN_A_ACT_REQ,4,2              ; @WIN_A_ACT_REQ
.subsections_via_symbols
