From c80c6333ff2912e31da5b8bcf803d2f4c2b912c5 Mon Sep 17 00:00:00 2001 From: Joonyoung Shim Date: Mon, 23 May 2016 14:37:02 +0900 Subject: [PATCH] gpu: arm: midgard: r12p0_04rel0: add exynos5422 platform files This is based on exynos5433 platform files. Signed-off-by: Joonyoung Shim --- .../r12p0_04rel0/platform/exynos5422/Kbuild | 1 + .../r12p0_04rel0/platform/exynos5422/exynos5422.c | 22 +++++++++ .../exynos5422/mali_kbase_config_platform.h | 52 ++++++++++++++++++++++ 3 files changed, 75 insertions(+) create mode 100644 drivers/gpu/arm/midgard/r12p0_04rel0/platform/exynos5422/Kbuild create mode 100644 drivers/gpu/arm/midgard/r12p0_04rel0/platform/exynos5422/exynos5422.c create mode 100644 drivers/gpu/arm/midgard/r12p0_04rel0/platform/exynos5422/mali_kbase_config_platform.h diff --git a/drivers/gpu/arm/midgard/r12p0_04rel0/platform/exynos5422/Kbuild b/drivers/gpu/arm/midgard/r12p0_04rel0/platform/exynos5422/Kbuild new file mode 100644 index 0000000..6fefc99 --- /dev/null +++ b/drivers/gpu/arm/midgard/r12p0_04rel0/platform/exynos5422/Kbuild @@ -0,0 +1 @@ +obj-y += exynos5422.o diff --git a/drivers/gpu/arm/midgard/r12p0_04rel0/platform/exynos5422/exynos5422.c b/drivers/gpu/arm/midgard/r12p0_04rel0/platform/exynos5422/exynos5422.c new file mode 100644 index 0000000..59e4147 --- /dev/null +++ b/drivers/gpu/arm/midgard/r12p0_04rel0/platform/exynos5422/exynos5422.c @@ -0,0 +1,22 @@ +/* + * Copyright (C) 2016 Samsung Electronics Co.Ltd + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License version 2 as + * published by the Free Software Foundation. + */ + +#include + +int kbase_platform_early_init(void) +{ + /* Nothing needed at this stage */ + return 0; +} + +static struct kbase_platform_config dummy_platform_config; + +struct kbase_platform_config *kbase_get_platform_config(void) +{ + return &dummy_platform_config; +} diff --git a/drivers/gpu/arm/midgard/r12p0_04rel0/platform/exynos5422/mali_kbase_config_platform.h b/drivers/gpu/arm/midgard/r12p0_04rel0/platform/exynos5422/mali_kbase_config_platform.h new file mode 100644 index 0000000..4e79d65 --- /dev/null +++ b/drivers/gpu/arm/midgard/r12p0_04rel0/platform/exynos5422/mali_kbase_config_platform.h @@ -0,0 +1,52 @@ +/* + * Copyright (C) 2016 Samsung Electronics Co.Ltd + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License version 2 as + * published by the Free Software Foundation. + */ + +/** + * Maximum frequency GPU will be clocked at. Given in kHz. + * This must be specified as there is no default value. + * + * Attached value: number in kHz + * Default value: NA + */ +#define GPU_FREQ_KHZ_MAX 533000 + +/** + * Minimum frequency GPU will be clocked at. Given in kHz. + * This must be specified as there is no default value. + * + * Attached value: number in kHz + * Default value: NA + */ +#define GPU_FREQ_KHZ_MIN 100000 + +/** + * GPU_SPEED_FUNC - A pointer to a function that calculates the GPU clock + * + * GPU clock speed of the platform in MHz - see kbase_gpu_clk_speed_func + * for the function prototype. + * + * Attached value: A kbase_gpu_clk_speed_func. + * Default Value: NA + */ +#define GPU_SPEED_FUNC (NULL) + +/** + * Power management configuration + * + * Attached value: pointer to @ref kbase_pm_callback_conf + * Default value: See @ref kbase_pm_callback_conf + */ +#define POWER_MANAGEMENT_CALLBACKS (NULL) + +/** + * Platform specific configuration functions + * + * Attached value: pointer to @ref kbase_platform_funcs_conf + * Default value: See @ref kbase_platform_funcs_conf + */ +#define PLATFORM_FUNCS (NULL) -- 2.7.4