mirror of
https://github.com/Telecominfraproject/OpenCellular.git
synced 2026-01-12 10:55:21 +00:00
Tegra: platform: support Tegra186 chip id
This patch adds support to read the chip id and identify if the current platform is Tegra186. Signed-off-by: Varun Wadekar <vwadekar@nvidia.com>
This commit is contained in:
@@ -69,6 +69,7 @@ typedef enum tegra_platform {
|
||||
typedef enum tegra_chipid {
|
||||
TEGRA_CHIPID_TEGRA13 = 0x13,
|
||||
TEGRA_CHIPID_TEGRA21 = 0x21,
|
||||
TEGRA_CHIPID_TEGRA18 = 0x18,
|
||||
} tegra_chipid_t;
|
||||
|
||||
/*
|
||||
@@ -109,6 +110,13 @@ uint8_t tegra_chipid_is_t210(void)
|
||||
return (chip_id == TEGRA_CHIPID_TEGRA21);
|
||||
}
|
||||
|
||||
uint8_t tegra_chipid_is_t186(void)
|
||||
{
|
||||
uint32_t chip_id = (tegra_get_chipid() >> CHIP_ID_SHIFT) & CHIP_ID_MASK;
|
||||
|
||||
return (chip_id == TEGRA_CHIPID_TEGRA18);
|
||||
}
|
||||
|
||||
/*
|
||||
* Read the chip ID value and derive the platform
|
||||
*/
|
||||
|
||||
@@ -42,8 +42,10 @@ uint32_t tegra_get_chipid_minor(void);
|
||||
/*
|
||||
* Tegra chip identifiers
|
||||
*/
|
||||
uint8_t tegra_is_t132(void);
|
||||
uint8_t tegra_is_t210(void);
|
||||
uint8_t tegra_chipid_is_t132(void);
|
||||
uint8_t tegra_chipid_is_t210(void);
|
||||
uint8_t tegra_chipid_is_t186(void);
|
||||
|
||||
|
||||
/*
|
||||
* Tegra platform identifiers
|
||||
|
||||
Reference in New Issue
Block a user