	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function mga_verify_blit
_mga_verify_blit:                       ## @mga_verify_blit
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	movl	%esi, %eax
	andl	$3, %eax
	movq	_MGA_SRCACC_PCI@GOTPCREL(%rip), %rdi
	movq	_MGA_SRCMAP_SYSMEM@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	orl	(%rdi), %ecx
	cmpl	%ecx, %eax
	je	LBB0_2
## %bb.1:
	movl	%edx, %edi
	andl	$3, %edi
	xorl	%eax, %eax
	cmpl	%ecx, %edi
	je	LBB0_2
## %bb.3:
	popq	%rbp
	retq
LBB0_2:
	leaq	L_.str(%rip), %rdi
	callq	_DRM_ERROR
	movq	_EINVAL@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_MGA_SRCACC_PCI,4,2             ## @MGA_SRCACC_PCI
	.comm	_MGA_SRCMAP_SYSMEM,4,2          ## @MGA_SRCMAP_SYSMEM
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"*** bad blit: src=0x%x dst=0x%x\n"

	.comm	_EINVAL,4,2                     ## @EINVAL
	.no_dead_strip	_mga_verify_blit
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function mga_verify_blit
_mga_verify_blit:                       ; @mga_verify_blit
	.cfi_startproc
; %bb.0:
	stp	x29, x30, [sp, #-16]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 16
	mov	x29, sp
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	and	w8, w1, #0x3
Lloh0:
	adrp	x9, _MGA_SRCACC_PCI@GOTPAGE
Lloh1:
	ldr	x9, [x9, _MGA_SRCACC_PCI@GOTPAGEOFF]
Lloh2:
	adrp	x10, _MGA_SRCMAP_SYSMEM@GOTPAGE
Lloh3:
	ldr	x10, [x10, _MGA_SRCMAP_SYSMEM@GOTPAGEOFF]
Lloh4:
	ldr	w9, [x9]
Lloh5:
	ldr	w10, [x10]
	orr	w9, w10, w9
	and	w10, w2, #0x3
	cmp	w8, w9
	ccmp	w10, w9, #4, ne
	b.ne	LBB0_2
; %bb.1:
Lloh6:
	adrp	x0, l_.str@PAGE
Lloh7:
	add	x0, x0, l_.str@PAGEOFF
	bl	_DRM_ERROR
Lloh8:
	adrp	x8, _EINVAL@GOTPAGE
Lloh9:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh10:
	ldr	w8, [x8]
	neg	w0, w8
	ldp	x29, x30, [sp], #16             ; 16-byte Folded Reload
	ret
LBB0_2:
	mov	w0, #0
	ldp	x29, x30, [sp], #16             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh4
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpAdd	Lloh6, Lloh7
	.cfi_endproc
                                        ; -- End function
	.comm	_MGA_SRCACC_PCI,4,2             ; @MGA_SRCACC_PCI
	.comm	_MGA_SRCMAP_SYSMEM,4,2          ; @MGA_SRCMAP_SYSMEM
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"*** bad blit: src=0x%x dst=0x%x\n"

	.comm	_EINVAL,4,2                     ; @EINVAL
	.no_dead_strip	_mga_verify_blit
.subsections_via_symbols
