summaryrefslogtreecommitdiffstats
path: root/include/linux
diff options
context:
space:
mode:
authorPotharaju Ravi Teja <pteja@nvidia.com>2019-10-24 03:25:13 -0400
committermobile promotions <svcmobile_promotions@nvidia.com>2020-01-24 02:42:16 -0500
commit17dd85a1cc1d3c97e3db3d92ccfb9db50602e410 (patch)
tree48d8d0a79927015d6067645de450ff66fa71f8b4 /include/linux
parent7544f678853edea145beff4fb0971fe343ce854e (diff)
inject-vm-err: T19x MC error handler
- Add support to handle Memory Controller errors on on t19x. - This change adds a sample handler for MC errors. It is a minimal handler that just dumps error information to the console. This can be used as a reference to implement an elaborate error handler. Bug 2580803 Change-Id: Ib86b925125650b4812fdbee5310455ae95ccd83c (cherry picked from commit 6c8395d11872f79ab5819a9900cb40b8f946852e) Signed-off-by: Potharaju Ravi Teja <pteja@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvidia/+/2279875 Tested-by: mobile promotions <svcmobile_promotions@nvidia.com> Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
Diffstat (limited to 'include/linux')
-rw-r--r--include/linux/errinfo.h19
-rw-r--r--include/linux/vm_err.h1
2 files changed, 20 insertions, 0 deletions
diff --git a/include/linux/errinfo.h b/include/linux/errinfo.h
index e75c2b308..074208918 100644
--- a/include/linux/errinfo.h
+++ b/include/linux/errinfo.h
@@ -18,6 +18,7 @@ enum err_reason {
18 REASON_ASYNC_SMMU_GLOBAL, 18 REASON_ASYNC_SMMU_GLOBAL,
19 REASON_ASYNC_BRIDGE, 19 REASON_ASYNC_BRIDGE,
20 REASON_ASYNC_MC, 20 REASON_ASYNC_MC,
21 REASON_ASYNC_MC_T19X,
21 REASON_ASYNC_CBB, 22 REASON_ASYNC_CBB,
22 REASON_SYNC_INSTR_ABORT, 23 REASON_SYNC_INSTR_ABORT,
23 REASON_SYNC_DATA_ABORT, 24 REASON_SYNC_DATA_ABORT,
@@ -105,6 +106,23 @@ struct __attribute__((__packed__)) async_mc_err_t {
105 int32_t peripheral_id; 106 int32_t peripheral_id;
106}; 107};
107 108
109struct __attribute__((__packed__)) async_mc_err_t19x_t {
110 bool vpr_violation;
111 unsigned int vpr_base[2];
112 unsigned int vpr_size;
113 unsigned int vpr_ctrl;
114 unsigned int vpr_override[4];
115 bool no_status;
116 bool two_status;
117 int client_swgid;
118 char client_name[NAME_SIZE];
119 char fault_msg[NAME_SIZE];
120 unsigned int status;
121 uint64_t address;
122 unsigned int secure;
123 unsigned int write;
124};
125
108struct __attribute__((__packed__)) sync_data_abort_t { 126struct __attribute__((__packed__)) sync_data_abort_t {
109 bool is_filled; /* metadata field per vcpu */ 127 bool is_filled; /* metadata field per vcpu */
110 bool is_write; 128 bool is_write;
@@ -127,6 +145,7 @@ struct __attribute__((__packed__)) err_data_t {
127 struct async_smmu_err_t async_smmu_err; 145 struct async_smmu_err_t async_smmu_err;
128 struct async_mc_err_t async_mc_err; 146 struct async_mc_err_t async_mc_err;
129 struct async_cbb_err_t async_cbb_err; 147 struct async_cbb_err_t async_cbb_err;
148 struct async_mc_err_t19x_t async_mc_err_t19x;
130 /* Synchronous */ 149 /* Synchronous */
131 struct sync_data_abort_t sync_data_abort; 150 struct sync_data_abort_t sync_data_abort;
132 }; 151 };
diff --git a/include/linux/vm_err.h b/include/linux/vm_err.h
index 31e3fca79..bcb3f255e 100644
--- a/include/linux/vm_err.h
+++ b/include/linux/vm_err.h
@@ -38,6 +38,7 @@ static const char * const tegra_hv_err_reason_desc[] = {
38 "SMMU Global", 38 "SMMU Global",
39 "Bridge", 39 "Bridge",
40 "Memory Controller", 40 "Memory Controller",
41 "Memory Controller T19X",
41 "Central Back Bone", 42 "Central Back Bone",
42 "Instruction Abort", 43 "Instruction Abort",
43 "Data Abort", 44 "Data Abort",