2019-05-28 17:10:04 +00:00
|
|
|
/* SPDX-License-Identifier: GPL-2.0-only */
|
2013-01-11 07:46:19 +00:00
|
|
|
/*
|
|
|
|
* Copyright (c) 2012, NVIDIA CORPORATION. All rights reserved.
|
|
|
|
*/
|
|
|
|
|
2014-07-17 11:17:24 +00:00
|
|
|
#ifndef __SOC_TEGRA_FUSE_H__
|
|
|
|
#define __SOC_TEGRA_FUSE_H__
|
2013-01-11 07:46:19 +00:00
|
|
|
|
2014-07-11 07:52:41 +00:00
|
|
|
#define TEGRA20 0x20
|
|
|
|
#define TEGRA30 0x30
|
|
|
|
#define TEGRA114 0x35
|
|
|
|
#define TEGRA124 0x40
|
2015-01-08 07:24:45 +00:00
|
|
|
#define TEGRA132 0x13
|
2015-04-29 14:55:57 +00:00
|
|
|
#define TEGRA210 0x21
|
2014-07-11 07:52:41 +00:00
|
|
|
|
2014-06-12 15:36:37 +00:00
|
|
|
#define TEGRA_FUSE_SKU_CALIB_0 0xf0
|
|
|
|
#define TEGRA30_FUSE_SATA_CALIB 0x124
|
2015-11-11 17:25:02 +00:00
|
|
|
#define TEGRA_FUSE_USB_CALIB_EXT_0 0x250
|
2014-06-12 15:36:37 +00:00
|
|
|
|
2014-07-11 07:52:41 +00:00
|
|
|
#ifndef __ASSEMBLY__
|
|
|
|
|
2013-01-11 07:46:19 +00:00
|
|
|
u32 tegra_read_chipid(void);
|
2014-07-11 07:52:41 +00:00
|
|
|
u8 tegra_get_chip_id(void);
|
|
|
|
|
2014-06-12 15:36:36 +00:00
|
|
|
enum tegra_revision {
|
|
|
|
TEGRA_REVISION_UNKNOWN = 0,
|
|
|
|
TEGRA_REVISION_A01,
|
|
|
|
TEGRA_REVISION_A02,
|
|
|
|
TEGRA_REVISION_A03,
|
|
|
|
TEGRA_REVISION_A03p,
|
|
|
|
TEGRA_REVISION_A04,
|
|
|
|
TEGRA_REVISION_MAX,
|
|
|
|
};
|
|
|
|
|
2014-06-12 15:36:37 +00:00
|
|
|
struct tegra_sku_info {
|
|
|
|
int sku_id;
|
|
|
|
int cpu_process_id;
|
|
|
|
int cpu_speedo_id;
|
|
|
|
int cpu_speedo_value;
|
|
|
|
int cpu_iddq_value;
|
2015-03-23 13:44:08 +00:00
|
|
|
int soc_process_id;
|
2014-06-12 15:36:37 +00:00
|
|
|
int soc_speedo_id;
|
2015-04-29 14:55:57 +00:00
|
|
|
int soc_speedo_value;
|
2014-06-12 15:36:37 +00:00
|
|
|
int gpu_process_id;
|
2015-04-29 14:55:57 +00:00
|
|
|
int gpu_speedo_id;
|
2014-06-12 15:36:37 +00:00
|
|
|
int gpu_speedo_value;
|
|
|
|
enum tegra_revision revision;
|
|
|
|
};
|
|
|
|
|
2014-06-12 15:36:36 +00:00
|
|
|
u32 tegra_read_straps(void);
|
2015-03-12 14:47:55 +00:00
|
|
|
u32 tegra_read_ram_code(void);
|
2014-06-12 15:36:37 +00:00
|
|
|
int tegra_fuse_readl(unsigned long offset, u32 *value);
|
2014-06-12 15:36:36 +00:00
|
|
|
|
2014-06-12 15:36:37 +00:00
|
|
|
extern struct tegra_sku_info tegra_sku_info;
|
2014-06-12 15:36:36 +00:00
|
|
|
|
2017-08-17 14:42:17 +00:00
|
|
|
struct device *tegra_soc_device_register(void);
|
|
|
|
|
2014-07-11 07:52:41 +00:00
|
|
|
#endif /* __ASSEMBLY__ */
|
2013-01-11 07:46:19 +00:00
|
|
|
|
2014-07-17 11:17:24 +00:00
|
|
|
#endif /* __SOC_TEGRA_FUSE_H__ */
|