diff options
Diffstat (limited to 'lib/include/nvif/os.h')
-rw-r--r-- | lib/include/nvif/os.h | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/lib/include/nvif/os.h b/lib/include/nvif/os.h index 4cd65e3cf..c265ab446 100644 --- a/lib/include/nvif/os.h +++ b/lib/include/nvif/os.h @@ -136,6 +136,12 @@ typedef dma_addr_t resource_size_t; #define IS_ENABLED_CONFIG_IOMMU_API 0 #endif +#if defined(CONFIG_ARCH_TEGRA) +#define IS_ENABLED_CONFIG_ARCH_TEGRA 1 +#else +#define IS_ENABLED_CONFIG_ARCH_TEGRA 0 +#endif + #define IS_ENABLED(x) IS_ENABLED_##x static inline bool @@ -229,6 +235,7 @@ hweight32(u32 v) { return i; } +#define BITS_PER_BYTE 8 #define BITS_PER_LONG (sizeof(unsigned long) * 8) #define BITS_TO_LONGS(b) DIV_ROUND_UP((b), BITS_PER_LONG) #define DECLARE_BITMAP(n,b) unsigned long n[BITS_TO_LONGS(b)] @@ -1553,6 +1560,13 @@ tegra_powergate_remove_clamping(int id) return -ENOSYS; } +static inline int +tegra_fuse_readl(unsigned long offset, u32 *value) +{ + *value = 0; + return -ENOSYS; +} + /****************************************************************************** * endianness (cont'd) *****************************************************************************/ |