Current mc-utils driver is specific to T234 without any support for
extending it to future SOCs. Add such support so that it can be easily
extended for future chips.
- Create a struct of function pointers of all present operations
- Set these function pointers as per SOCs
Bug 4090660
Change-Id: I93e9da987bce1e563eb03aeeb0ac8bcb9da48023
Signed-off-by: Ketan Patil <ketanp@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/2911894
Reviewed-by: Jonathan Hunter <jonathanh@nvidia.com>
Reviewed-by: Sachin Nikam <snikam@nvidia.com>
GVS: Gerrit_Virtual_Submit <buildbot_gerritrpt@nvidia.com>
EMC registers are currently accessed to get DRAM parameters.
As these are platform specific and static, DRAM parameters are added in
device-tree. In case of hypervisor environment, read DRAM properties
from device-tree instead of accessing EMC registers.
Also, MC and EMC register access by kernel is going to be blocked from
hypervisor. So, remove access to these registers.
Bug 3938091
Change-Id: I8a85bef7c34a919a48b3f0999f631f264540585a
Signed-off-by: Ashish Mhetre <amhetre@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/2848653
Reviewed-by: svcacv <svcacv@nvidia.com>
Reviewed-by: Sachin Nikam <snikam@nvidia.com>
GVS: Gerrit_Virtual_Submit <buildbot_gerritrpt@nvidia.com>
The mc-utils driver shares a Makefile with several others drivers in the
drivers/platform/tegra directory and this means that we cannot compile
the mc-utils driver independently of these other drivers and package the
mc-utils driver without all of the other drivers. Therefore, move the
mc-utils driver into its own sub-directory and add its own Makefile so
that we can build and package this driver independently.
Bug 3841177
Signed-off-by: Jon Hunter <jonathanh@nvidia.com>
Change-Id: If8962fc1ede9fb4318341a7961106f799156cdad
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/2827672
(cherry picked from commit a18d0a5a739144dc00a7200ec53397966fc543ba)
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/2829120
Reviewed-by: Ketan Patil <ketanp@nvidia.com>
Reviewed-by: Bibek Basu <bbasu@nvidia.com>
Reviewed-by: Thierry Reding <treding@nvidia.com>
GVS: Gerrit_Virtual_Submit <buildbot_gerritrpt@nvidia.com>