![]() |
TT-System-Firmware APIs 19.10.99
Tenstorrent Firmware
|
#include "axi.h"#include "jtag_profile_functions.h"#include "tenstorrent/bitrev.h"#include "jtag_priv.h"#include <stdint.h>#include <zephyr/device.h>#include <zephyr/drivers/gpio.h>#include <zephyr/drivers/gpio/gpio_emul.h>#include <zephyr/drivers/jtag.h>#include <zephyr/kernel.h>#include <zephyr/logging/log.h>#include <zephyr/sys/byteorder.h>#include <zephyr/sys/util.h>
Data Structures | |
| struct | jtag_instr_t |
| union | jtag_instr_u |
Macros | |
| #define | DT_DRV_COMPAT zephyr_jtag_gpio |
| #define | MST_TAP_OP_ISCAN_SEL (2) |
| #define | MST_TAP_OP_DEVID_SEL (6) |
| #define | TENSIX_SM_RTAP (0x19e) |
| #define | TENSIX_SM_SIBLEN (4) |
| #define | TENSIX_SM_TDRLEN (32) |
| #define | TENSIX_SIBLEN_PLUS_1_OR_0 ((TENSIX_SM_SIBLEN > 0) ? (TENSIX_SM_SIBLEN + 1) : 0) |
| #define | TENSIX_TDRLEN_SIBLEN_PLUS_1 (1 + TENSIX_SM_TDRLEN + TENSIX_SM_SIBLEN) |
| #define | SIBSHIFT(x) |
| #define | SIBSHIFTUP(x) |
| #define | INSTR_REG_BISTEN_SEL_END_0 (9) |
| #define | INSTR_REG_BISTEN_SEL_START_0 (7) |
| #define | INSTR_REG_BISTEN_SEL_MASK_0 (7) |
| #define | INSTR_REG_BISTEN_SEL_MASK_1 (0x3f) |
| #define | IF_TDI(config, stmt) |
| #define | JTAG_BB_GPIOS_GET_REG(n, gpios) |
| #define | JTAG_BB_DEVICE_DEFINE(n) |
Functions | |
| LOG_MODULE_REGISTER (jtag_bitbang, CONFIG_JTAG_LOG_LEVEL) | |
| static void | SET_TCK (const struct jtag_config *config) |
| static void | CLR_TCK (const struct jtag_config *config) |
| static void | SET_TDI (const struct jtag_config *config) |
| static void | CLR_TDI (const struct jtag_config *config) |
| static bool | GET_TDO (const struct jtag_config *config) |
| static void | SET_TMS (const struct jtag_config *config) |
| static void | CLR_TMS (const struct jtag_config *config) |
| static ALWAYS_INLINE void | jtag_bitbang_tick (const struct device *dev, uint32_t count) |
| int | jtag_bitbang_reset (const struct device *dev) |
| static ALWAYS_INLINE void | jtag_bitbang_update_ir (const struct device *dev, uint32_t count, uint64_t data) |
| static ALWAYS_INLINE uint64_t | jtag_bitbang_xfer_dr (const struct device *dev, uint32_t count, uint64_t data_in, bool idle, bool capture) |
| static ALWAYS_INLINE uint64_t | jtag_bitbang_capture_dr_idle (const struct device *dev, uint32_t count, uint64_t data_in) |
| static ALWAYS_INLINE uint64_t | jtag_bitbang_capture_dr (const struct device *dev, uint32_t count, uint64_t data_in) |
| static ALWAYS_INLINE void | jtag_bitbang_update_dr_idle (const struct device *dev, uint32_t count, uint64_t data_in) |
| static ALWAYS_INLINE void | jtag_bitbang_update_dr (const struct device *dev, uint32_t count, uint64_t data_in) |
| int | jtag_bitbang_read_id (const struct device *dev, uint32_t *id) |
| int | jtag_bitbang_setup (const struct device *dev) |
| static int | jtag_bitbang_teardown (const struct device *dev) |
| static ALWAYS_INLINE void | jtag_setup_access (const struct device *dev, uint32_t rtap_addr) |
| static ALWAYS_INLINE uint32_t | jtag_access_rtap_tdr_idle (const struct device *dev, uint32_t rtap_addr, uint32_t tdr_addr, uint32_t wrdata) |
| static ALWAYS_INLINE uint32_t | jtag_access_rtap_tdr (const struct device *dev, uint32_t rtap_addr, uint32_t tdr_addr, uint32_t wrdata) |
| static ALWAYS_INLINE void | jtag_wr_tensix_sm_rtap_tdr_idle (const struct device *dev, uint32_t tdr_addr, uint32_t wrvalue) |
| static ALWAYS_INLINE void | jtag_wr_tensix_sm_rtap_tdr (const struct device *dev, uint32_t tdr_addr, uint32_t wrvalue) |
| static ALWAYS_INLINE uint32_t | jtag_rd_tensix_sm_rtap_tdr_idle (const struct device *dev, uint32_t tdr_addr) |
| static ALWAYS_INLINE uint32_t | jtag_rd_tensix_sm_rtap_tdr (const struct device *dev, uint32_t tdr_addr) |
| void | jtag_req_clear (const struct device *dev) |
| int | jtag_axiread (const struct device *dev, uint32_t addr, uint32_t *result) |
| int | jtag_axiwrite (const struct device *dev, uint32_t addr, uint32_t value) |
| int | jtag_axi_blockwrite (const struct device *dev, uint32_t addr, const uint32_t *value, uint32_t len) |
| static int | jtag_bitbang_init (const struct device *dev) |
Variables | |
| static struct jtag_api | jtag_bitbang_api |
| #define DT_DRV_COMPAT zephyr_jtag_gpio |
| #define IF_TDI | ( | config, | |
| stmt ) |
| #define INSTR_REG_BISTEN_SEL_END_0 (9) |
| #define INSTR_REG_BISTEN_SEL_MASK_0 (7) |
| #define INSTR_REG_BISTEN_SEL_MASK_1 (0x3f) |
| #define INSTR_REG_BISTEN_SEL_START_0 (7) |
| #define JTAG_BB_DEVICE_DEFINE | ( | n | ) |
| #define JTAG_BB_GPIOS_GET_REG | ( | n, | |
| gpios ) |
| #define MST_TAP_OP_DEVID_SEL (6) |
| #define MST_TAP_OP_ISCAN_SEL (2) |
| #define SIBSHIFT | ( | x | ) |
| #define SIBSHIFTUP | ( | x | ) |
| #define TENSIX_SIBLEN_PLUS_1_OR_0 ((TENSIX_SM_SIBLEN > 0) ? (TENSIX_SM_SIBLEN + 1) : 0) |
| #define TENSIX_SM_RTAP (0x19e) |
| #define TENSIX_SM_SIBLEN (4) |
| #define TENSIX_SM_TDRLEN (32) |
| #define TENSIX_TDRLEN_SIBLEN_PLUS_1 (1 + TENSIX_SM_TDRLEN + TENSIX_SM_SIBLEN) |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
| int jtag_axi_blockwrite | ( | const struct device * | dev, |
| uint32_t | addr, | ||
| const uint32_t * | value, | ||
| uint32_t | len ) |
|
static |
|
static |
|
static |
| int jtag_bitbang_reset | ( | const struct device * | dev | ) |
| int jtag_bitbang_setup | ( | const struct device * | dev | ) |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
| void jtag_req_clear | ( | const struct device * | dev | ) |
|
static |
|
static |
|
static |
| LOG_MODULE_REGISTER | ( | jtag_bitbang | , |
| CONFIG_JTAG_LOG_LEVEL | ) |
|
static |
|
static |
|
static |
|
static |