# SPDX-License-Identifier: GPL-2.0

menu "G2D Drivers"
	depends on AW_BSP

config AW_G2D
	tristate "G2D Support for Allwinner SoCs"
	default n
	help
	  Enable sunxi platform 2D Graphics engine
choice
	prompt "G2D driver version"
	depends on AW_G2D

config G2D_LEGACY
	bool "legacy version"

config G2D_RCQ
	bool "RCQ version"

config G2D_MIXER
	depends on G2D_RCQ
	bool "sunxi g2d mixer module"
	default y
	help
	  Choose Y to enable mixer module of g2d

config G2D_ROTATE
	depends on G2D_RCQ
	bool "sunxi g2d rotate module"
	default y
	help
	  Choose Y to enable rotate module of g2d


endchoice

config G2D_SYNCFENCE
	depends on AW_G2D
	select SYNC_FILE
	bool "sunxi sync fence implement for rotate jobs synchronous"
	default n
	help
	  Choose Y to enable sync fence implement for sunxi G2D

config G2D_USE_HWSPINLOCK
	depends on AW_G2D && AW_RPROC_FAST_BOOT
	bool "sunxi g2d use hwspinlock"
	default n
	help
	  Choose Y to use hwspinlock by sunxi G2D

endmenu
