From 5bfc0aacb32e6991555497ba1683aeedcf9beb01 Mon Sep 17 00:00:00 2001 From: Arto Merilainen Date: Thu, 10 Sep 2015 15:46:29 -0700 Subject: platform: tegra: Add kfuse support This patch adds kfuse support for T186. As a new feature it introduces a reference counted in-kernel API for enabling and disabling kfuse sensing Bug 200117545 Change-Id: I03c6e360c70a9243f1284dc98ccc4122fb993f59 Signed-off-by: Arto Merilainen Reviewed-on: http://git-master/r/797418 (cherry picked from commit d67bf71ef1e6f9e3c9acb6b366f6e8a7a2ff4acf) Reviewed-on: http://git-master/r/804437 Reviewed-by: Automatic_Commit_Validation_User GVS: Gerrit_Virtual_Submit Reviewed-by: Stefan Kristiansson Reviewed-by: Konsta Holtta --- include/linux/platform/tegra/tegra18_kfuse.h | 37 ++++++++++++++++++++++++++++ 1 file changed, 37 insertions(+) create mode 100644 include/linux/platform/tegra/tegra18_kfuse.h (limited to 'include/linux/platform') diff --git a/include/linux/platform/tegra/tegra18_kfuse.h b/include/linux/platform/tegra/tegra18_kfuse.h new file mode 100644 index 000000000..2ceb706f1 --- /dev/null +++ b/include/linux/platform/tegra/tegra18_kfuse.h @@ -0,0 +1,37 @@ +/* + * Copyright (c) 2015, NVIDIA CORPORATION. All rights reserved. + * + * This program is free software; you can redistribute it and/or modify it + * under the terms and conditions of the GNU General Public License, + * version 2, as published by the Free Software Foundation. + * + * This program is distributed in the hope 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. + */ + +#ifndef TEGRA18_KFUSE_H +#define TEGRA18_KFUSE_H + +#include + +struct kfuse; + +#ifdef CONFIG_TEGRA_KFUSE +void tegra_kfuse_disable_sensing(void); +int tegra_kfuse_enable_sensing(void); +#else + +static inline void tegra_kfuse_disable_sensing(void) +{ +} + +static inline int tegra_kfuse_enable_sensing(void) +{ + return -ENOSYS; +} + +#endif + +#endif -- cgit v1.2.2