# SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note OR MIT
#
# (C) COPYRIGHT 2021 ARM Limited. All rights reserved.
#
# This program is free software and is provided to you under the terms of the
# GNU General Public License version 2 as published by the Free Software
# Foundation, and any use by you of this program is subject to the terms
# of such GNU license.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, you can access it online at
# http://www.gnu.org/licenses/gpl-2.0.html.
#
#

config MALI_PARTITION_MANAGER
	bool "Enable compilation of partition manager modules"
	depends on MALI_MIDGARD
	default n
	default y if GPU_TBAX
	help
	  This option enables the compilation of the partition manager
	  modules used to configure the Mali-G78AE GPU.

config BUILD_PTM_MODULES
	bool "Enable compilation of partition manager modules"
	depends on BUILD_KERNEL_MODULES
	default n
	default y if MALI_PARTITION_MANAGER
	help
	  Build a daisy chain reference arbiter useful
	  to manage Mali to different Virtual Machines

	  If unsure, say N.

config BUILD_GPU_RESOURCE_GROUP_MODULE
	bool
	depends on BUILD_ARBITER_MODULES && BUILD_PTM_MODULES
	default y

config BUILD_PTM_KERNEL_TESTS
	bool "Kernel has PTM module unit tests enabled"
	depends on BUILD_KERNEL_MODULES
	default n
	default y if UNIT_TEST_KERNEL_MODULES && BUILD_PTM_MODULES

config BUILD_PTM_TESTS
	bool "Userspace PTM unit tests enabled"
	depends on MALI_PARTITION_MANAGER
	default n
	default y if UNIT_TEST_CODE

config BUILD_GPU_RESOURCE_GROUP_TESTS
	bool "Kernel has Resource Group module unit tests enabled"
	depends on BUILD_ARBITER_KERNEL_TESTS && BUILD_PTM_KERNEL_TESTS
	default y

config BUILD_PTM_ARBITER_KERNEL_TESTS
	bool "Kernel has PTM arbiter module unit tests enabled"
	depends on BUILD_ARBITER_KERNEL_TESTS && BUILD_PTM_KERNEL_TESTS
	default y
