intel_telemetry_debugfs.c 29 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055
  1. /*
  2. * Intel SOC Telemetry debugfs Driver: Currently supports APL
  3. * Copyright (c) 2015, Intel Corporation.
  4. * All Rights Reserved.
  5. *
  6. * This program is free software; you can redistribute it and/or modify it
  7. * under the terms and conditions of the GNU General Public License,
  8. * version 2, as published by the Free Software Foundation.
  9. *
  10. * This program is distributed in the hope it will be useful, but WITHOUT
  11. * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
  12. * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
  13. * more details.
  14. *
  15. * This file provides the debugfs interfaces for telemetry.
  16. * /sys/kernel/debug/telemetry/pss_info: Shows Primary Control Sub-Sys Counters
  17. * /sys/kernel/debug/telemetry/ioss_info: Shows IO Sub-System Counters
  18. * /sys/kernel/debug/telemetry/soc_states: Shows SoC State
  19. * /sys/kernel/debug/telemetry/pss_trace_verbosity: Read and Change Tracing
  20. * Verbosity via firmware
  21. * /sys/kernel/debug/telemetry/ioss_race_verbosity: Write and Change Tracing
  22. * Verbosity via firmware
  23. */
  24. #include <linux/module.h>
  25. #include <linux/init.h>
  26. #include <linux/device.h>
  27. #include <linux/debugfs.h>
  28. #include <linux/seq_file.h>
  29. #include <linux/io.h>
  30. #include <linux/uaccess.h>
  31. #include <linux/pci.h>
  32. #include <linux/suspend.h>
  33. #include <asm/cpu_device_id.h>
  34. #include <asm/intel-family.h>
  35. #include <asm/intel_pmc_ipc.h>
  36. #include <asm/intel_punit_ipc.h>
  37. #include <asm/intel_telemetry.h>
  38. #define DRIVER_NAME "telemetry_soc_debugfs"
  39. #define DRIVER_VERSION "1.0.0"
  40. /* ApolloLake SoC Event-IDs */
  41. #define TELEM_APL_PSS_PSTATES_ID 0x2802
  42. #define TELEM_APL_PSS_IDLE_ID 0x2806
  43. #define TELEM_APL_PCS_IDLE_BLOCKED_ID 0x2C00
  44. #define TELEM_APL_PCS_S0IX_BLOCKED_ID 0x2C01
  45. #define TELEM_APL_PSS_WAKEUP_ID 0x2C02
  46. #define TELEM_APL_PSS_LTR_BLOCKING_ID 0x2C03
  47. #define TELEM_APL_S0IX_TOTAL_OCC_ID 0x4000
  48. #define TELEM_APL_S0IX_SHLW_OCC_ID 0x4001
  49. #define TELEM_APL_S0IX_DEEP_OCC_ID 0x4002
  50. #define TELEM_APL_S0IX_TOTAL_RES_ID 0x4800
  51. #define TELEM_APL_S0IX_SHLW_RES_ID 0x4801
  52. #define TELEM_APL_S0IX_DEEP_RES_ID 0x4802
  53. #define TELEM_APL_D0IX_ID 0x581A
  54. #define TELEM_APL_D3_ID 0x5819
  55. #define TELEM_APL_PG_ID 0x5818
  56. #define TELEM_INFO_SRAMEVTS_MASK 0xFF00
  57. #define TELEM_INFO_SRAMEVTS_SHIFT 0x8
  58. #define TELEM_SSRAM_READ_TIMEOUT 10
  59. #define TELEM_MASK_BIT 1
  60. #define TELEM_MASK_BYTE 0xFF
  61. #define BYTES_PER_LONG 8
  62. #define TELEM_APL_MASK_PCS_STATE 0xF
  63. /* Max events in bitmap to check for */
  64. #define TELEM_PSS_IDLE_EVTS 25
  65. #define TELEM_PSS_IDLE_BLOCKED_EVTS 20
  66. #define TELEM_PSS_S0IX_BLOCKED_EVTS 20
  67. #define TELEM_PSS_S0IX_WAKEUP_EVTS 20
  68. #define TELEM_PSS_LTR_BLOCKING_EVTS 20
  69. #define TELEM_IOSS_DX_D0IX_EVTS 25
  70. #define TELEM_IOSS_PG_EVTS 30
  71. #define TELEM_DEBUGFS_CPU(model, data) \
  72. { X86_VENDOR_INTEL, 6, model, X86_FEATURE_ANY, (unsigned long)&data}
  73. #define TELEM_CHECK_AND_PARSE_EVTS(EVTID, EVTNUM, BUF, EVTLOG, EVTDAT, MASK) { \
  74. if (evtlog[index].telem_evtid == (EVTID)) { \
  75. for (idx = 0; idx < (EVTNUM); idx++) \
  76. (BUF)[idx] = ((EVTLOG) >> (EVTDAT)[idx].bit_pos) & \
  77. (MASK); \
  78. continue; \
  79. } \
  80. }
  81. #define TELEM_CHECK_AND_PARSE_CTRS(EVTID, CTR) { \
  82. if (evtlog[index].telem_evtid == (EVTID)) { \
  83. (CTR) = evtlog[index].telem_evtlog; \
  84. continue; \
  85. } \
  86. }
  87. static u8 suspend_prep_ok;
  88. static u32 suspend_shlw_ctr_temp, suspend_deep_ctr_temp;
  89. static u64 suspend_shlw_res_temp, suspend_deep_res_temp;
  90. struct telemetry_susp_stats {
  91. u32 shlw_swake_ctr;
  92. u32 deep_swake_ctr;
  93. u64 shlw_swake_res;
  94. u64 deep_swake_res;
  95. u32 shlw_ctr;
  96. u32 deep_ctr;
  97. u64 shlw_res;
  98. u64 deep_res;
  99. };
  100. /* Bitmap definitions for default counters in APL */
  101. struct telem_pss_idle_stateinfo {
  102. const char *name;
  103. u32 bit_pos;
  104. };
  105. static struct telem_pss_idle_stateinfo telem_apl_pss_idle_data[] = {
  106. {"IA_CORE0_C1E", 0},
  107. {"IA_CORE1_C1E", 1},
  108. {"IA_CORE2_C1E", 2},
  109. {"IA_CORE3_C1E", 3},
  110. {"IA_CORE0_C6", 16},
  111. {"IA_CORE1_C6", 17},
  112. {"IA_CORE2_C6", 18},
  113. {"IA_CORE3_C6", 19},
  114. {"IA_MODULE0_C7", 32},
  115. {"IA_MODULE1_C7", 33},
  116. {"GT_RC6", 40},
  117. {"IUNIT_PROCESSING_IDLE", 41},
  118. {"FAR_MEM_IDLE", 43},
  119. {"DISPLAY_IDLE", 44},
  120. {"IUNIT_INPUT_SYSTEM_IDLE", 45},
  121. {"PCS_STATUS", 60},
  122. };
  123. struct telem_pcs_blkd_info {
  124. const char *name;
  125. u32 bit_pos;
  126. };
  127. static struct telem_pcs_blkd_info telem_apl_pcs_idle_blkd_data[] = {
  128. {"COMPUTE", 0},
  129. {"MISC", 8},
  130. {"MODULE_ACTIONS_PENDING", 16},
  131. {"LTR", 24},
  132. {"DISPLAY_WAKE", 32},
  133. {"ISP_WAKE", 40},
  134. {"PSF0_ACTIVE", 48},
  135. };
  136. static struct telem_pcs_blkd_info telem_apl_pcs_s0ix_blkd_data[] = {
  137. {"LTR", 0},
  138. {"IRTL", 8},
  139. {"WAKE_DEADLINE_PENDING", 16},
  140. {"DISPLAY", 24},
  141. {"ISP", 32},
  142. {"CORE", 40},
  143. {"PMC", 48},
  144. {"MISC", 56},
  145. };
  146. struct telem_pss_ltr_info {
  147. const char *name;
  148. u32 bit_pos;
  149. };
  150. static struct telem_pss_ltr_info telem_apl_pss_ltr_data[] = {
  151. {"CORE_ACTIVE", 0},
  152. {"MEM_UP", 8},
  153. {"DFX", 16},
  154. {"DFX_FORCE_LTR", 24},
  155. {"DISPLAY", 32},
  156. {"ISP", 40},
  157. {"SOUTH", 48},
  158. };
  159. struct telem_pss_wakeup_info {
  160. const char *name;
  161. u32 bit_pos;
  162. };
  163. static struct telem_pss_wakeup_info telem_apl_pss_wakeup[] = {
  164. {"IP_IDLE", 0},
  165. {"DISPLAY_WAKE", 8},
  166. {"VOLTAGE_REG_INT", 16},
  167. {"DROWSY_TIMER (HOTPLUG)", 24},
  168. {"CORE_WAKE", 32},
  169. {"MISC_S0IX", 40},
  170. {"MISC_ABORT", 56},
  171. };
  172. struct telem_ioss_d0ix_stateinfo {
  173. const char *name;
  174. u32 bit_pos;
  175. };
  176. static struct telem_ioss_d0ix_stateinfo telem_apl_ioss_d0ix_data[] = {
  177. {"CSE", 0},
  178. {"SCC2", 1},
  179. {"GMM", 2},
  180. {"XDCI", 3},
  181. {"XHCI", 4},
  182. {"ISH", 5},
  183. {"AVS", 6},
  184. {"PCIE0P1", 7},
  185. {"PECI0P0", 8},
  186. {"LPSS", 9},
  187. {"SCC", 10},
  188. {"PWM", 11},
  189. {"PCIE1_P3", 12},
  190. {"PCIE1_P2", 13},
  191. {"PCIE1_P1", 14},
  192. {"PCIE1_P0", 15},
  193. {"CNV", 16},
  194. {"SATA", 17},
  195. {"PRTC", 18},
  196. };
  197. struct telem_ioss_pg_info {
  198. const char *name;
  199. u32 bit_pos;
  200. };
  201. static struct telem_ioss_pg_info telem_apl_ioss_pg_data[] = {
  202. {"LPSS", 0},
  203. {"SCC", 1},
  204. {"P2SB", 2},
  205. {"SCC2", 3},
  206. {"GMM", 4},
  207. {"PCIE0", 5},
  208. {"XDCI", 6},
  209. {"xHCI", 7},
  210. {"CSE", 8},
  211. {"SPI", 9},
  212. {"AVSPGD4", 10},
  213. {"AVSPGD3", 11},
  214. {"AVSPGD2", 12},
  215. {"AVSPGD1", 13},
  216. {"ISH", 14},
  217. {"EXI", 15},
  218. {"NPKVRC", 16},
  219. {"NPKVNN", 17},
  220. {"CUNIT", 18},
  221. {"FUSE_CTRL", 19},
  222. {"PCIE1", 20},
  223. {"CNV", 21},
  224. {"LPC", 22},
  225. {"SATA", 23},
  226. {"SMB", 24},
  227. {"PRTC", 25},
  228. };
  229. struct telemetry_debugfs_conf {
  230. struct telemetry_susp_stats suspend_stats;
  231. struct dentry *telemetry_dbg_dir;
  232. /* Bitmap Data */
  233. struct telem_ioss_d0ix_stateinfo *ioss_d0ix_data;
  234. struct telem_pss_idle_stateinfo *pss_idle_data;
  235. struct telem_pcs_blkd_info *pcs_idle_blkd_data;
  236. struct telem_pcs_blkd_info *pcs_s0ix_blkd_data;
  237. struct telem_pss_wakeup_info *pss_wakeup;
  238. struct telem_pss_ltr_info *pss_ltr_data;
  239. struct telem_ioss_pg_info *ioss_pg_data;
  240. u8 pcs_idle_blkd_evts;
  241. u8 pcs_s0ix_blkd_evts;
  242. u8 pss_wakeup_evts;
  243. u8 pss_idle_evts;
  244. u8 pss_ltr_evts;
  245. u8 ioss_d0ix_evts;
  246. u8 ioss_pg_evts;
  247. /* IDs */
  248. u16 pss_ltr_blocking_id;
  249. u16 pcs_idle_blkd_id;
  250. u16 pcs_s0ix_blkd_id;
  251. u16 s0ix_total_occ_id;
  252. u16 s0ix_shlw_occ_id;
  253. u16 s0ix_deep_occ_id;
  254. u16 s0ix_total_res_id;
  255. u16 s0ix_shlw_res_id;
  256. u16 s0ix_deep_res_id;
  257. u16 pss_wakeup_id;
  258. u16 ioss_d0ix_id;
  259. u16 pstates_id;
  260. u16 pss_idle_id;
  261. u16 ioss_d3_id;
  262. u16 ioss_pg_id;
  263. };
  264. static struct telemetry_debugfs_conf *debugfs_conf;
  265. static struct telemetry_debugfs_conf telem_apl_debugfs_conf = {
  266. .pss_idle_data = telem_apl_pss_idle_data,
  267. .pcs_idle_blkd_data = telem_apl_pcs_idle_blkd_data,
  268. .pcs_s0ix_blkd_data = telem_apl_pcs_s0ix_blkd_data,
  269. .pss_ltr_data = telem_apl_pss_ltr_data,
  270. .pss_wakeup = telem_apl_pss_wakeup,
  271. .ioss_d0ix_data = telem_apl_ioss_d0ix_data,
  272. .ioss_pg_data = telem_apl_ioss_pg_data,
  273. .pss_idle_evts = ARRAY_SIZE(telem_apl_pss_idle_data),
  274. .pcs_idle_blkd_evts = ARRAY_SIZE(telem_apl_pcs_idle_blkd_data),
  275. .pcs_s0ix_blkd_evts = ARRAY_SIZE(telem_apl_pcs_s0ix_blkd_data),
  276. .pss_ltr_evts = ARRAY_SIZE(telem_apl_pss_ltr_data),
  277. .pss_wakeup_evts = ARRAY_SIZE(telem_apl_pss_wakeup),
  278. .ioss_d0ix_evts = ARRAY_SIZE(telem_apl_ioss_d0ix_data),
  279. .ioss_pg_evts = ARRAY_SIZE(telem_apl_ioss_pg_data),
  280. .pstates_id = TELEM_APL_PSS_PSTATES_ID,
  281. .pss_idle_id = TELEM_APL_PSS_IDLE_ID,
  282. .pcs_idle_blkd_id = TELEM_APL_PCS_IDLE_BLOCKED_ID,
  283. .pcs_s0ix_blkd_id = TELEM_APL_PCS_S0IX_BLOCKED_ID,
  284. .pss_wakeup_id = TELEM_APL_PSS_WAKEUP_ID,
  285. .pss_ltr_blocking_id = TELEM_APL_PSS_LTR_BLOCKING_ID,
  286. .s0ix_total_occ_id = TELEM_APL_S0IX_TOTAL_OCC_ID,
  287. .s0ix_shlw_occ_id = TELEM_APL_S0IX_SHLW_OCC_ID,
  288. .s0ix_deep_occ_id = TELEM_APL_S0IX_DEEP_OCC_ID,
  289. .s0ix_total_res_id = TELEM_APL_S0IX_TOTAL_RES_ID,
  290. .s0ix_shlw_res_id = TELEM_APL_S0IX_SHLW_RES_ID,
  291. .s0ix_deep_res_id = TELEM_APL_S0IX_DEEP_RES_ID,
  292. .ioss_d0ix_id = TELEM_APL_D0IX_ID,
  293. .ioss_d3_id = TELEM_APL_D3_ID,
  294. .ioss_pg_id = TELEM_APL_PG_ID,
  295. };
  296. static const struct x86_cpu_id telemetry_debugfs_cpu_ids[] = {
  297. TELEM_DEBUGFS_CPU(INTEL_FAM6_ATOM_GOLDMONT, telem_apl_debugfs_conf),
  298. TELEM_DEBUGFS_CPU(INTEL_FAM6_ATOM_GEMINI_LAKE, telem_apl_debugfs_conf),
  299. {}
  300. };
  301. MODULE_DEVICE_TABLE(x86cpu, telemetry_debugfs_cpu_ids);
  302. static int telemetry_debugfs_check_evts(void)
  303. {
  304. if ((debugfs_conf->pss_idle_evts > TELEM_PSS_IDLE_EVTS) ||
  305. (debugfs_conf->pcs_idle_blkd_evts > TELEM_PSS_IDLE_BLOCKED_EVTS) ||
  306. (debugfs_conf->pcs_s0ix_blkd_evts > TELEM_PSS_S0IX_BLOCKED_EVTS) ||
  307. (debugfs_conf->pss_ltr_evts > TELEM_PSS_LTR_BLOCKING_EVTS) ||
  308. (debugfs_conf->pss_wakeup_evts > TELEM_PSS_S0IX_WAKEUP_EVTS) ||
  309. (debugfs_conf->ioss_d0ix_evts > TELEM_IOSS_DX_D0IX_EVTS) ||
  310. (debugfs_conf->ioss_pg_evts > TELEM_IOSS_PG_EVTS))
  311. return -EINVAL;
  312. return 0;
  313. }
  314. static int telem_pss_states_show(struct seq_file *s, void *unused)
  315. {
  316. struct telemetry_evtlog evtlog[TELEM_MAX_OS_ALLOCATED_EVENTS];
  317. struct telemetry_debugfs_conf *conf = debugfs_conf;
  318. const char *name[TELEM_MAX_OS_ALLOCATED_EVENTS];
  319. u32 pcs_idle_blkd[TELEM_PSS_IDLE_BLOCKED_EVTS],
  320. pcs_s0ix_blkd[TELEM_PSS_S0IX_BLOCKED_EVTS],
  321. pss_s0ix_wakeup[TELEM_PSS_S0IX_WAKEUP_EVTS],
  322. pss_ltr_blkd[TELEM_PSS_LTR_BLOCKING_EVTS],
  323. pss_idle[TELEM_PSS_IDLE_EVTS];
  324. int index, idx, ret, err = 0;
  325. u64 pstates = 0;
  326. ret = telemetry_read_eventlog(TELEM_PSS, evtlog,
  327. TELEM_MAX_OS_ALLOCATED_EVENTS);
  328. if (ret < 0)
  329. return ret;
  330. err = telemetry_get_evtname(TELEM_PSS, name,
  331. TELEM_MAX_OS_ALLOCATED_EVENTS);
  332. if (err < 0)
  333. return err;
  334. seq_puts(s, "\n----------------------------------------------------\n");
  335. seq_puts(s, "\tPSS TELEM EVENTLOG (Residency = field/19.2 us\n");
  336. seq_puts(s, "----------------------------------------------------\n");
  337. for (index = 0; index < ret; index++) {
  338. seq_printf(s, "%-32s %llu\n",
  339. name[index], evtlog[index].telem_evtlog);
  340. /* Fetch PSS IDLE State */
  341. if (evtlog[index].telem_evtid == conf->pss_idle_id) {
  342. pss_idle[conf->pss_idle_evts - 1] =
  343. (evtlog[index].telem_evtlog >>
  344. conf->pss_idle_data[conf->pss_idle_evts - 1].bit_pos) &
  345. TELEM_APL_MASK_PCS_STATE;
  346. }
  347. TELEM_CHECK_AND_PARSE_EVTS(conf->pss_idle_id,
  348. conf->pss_idle_evts - 1,
  349. pss_idle, evtlog[index].telem_evtlog,
  350. conf->pss_idle_data, TELEM_MASK_BIT);
  351. TELEM_CHECK_AND_PARSE_EVTS(conf->pcs_idle_blkd_id,
  352. conf->pcs_idle_blkd_evts,
  353. pcs_idle_blkd,
  354. evtlog[index].telem_evtlog,
  355. conf->pcs_idle_blkd_data,
  356. TELEM_MASK_BYTE);
  357. TELEM_CHECK_AND_PARSE_EVTS(conf->pcs_s0ix_blkd_id,
  358. conf->pcs_s0ix_blkd_evts,
  359. pcs_s0ix_blkd,
  360. evtlog[index].telem_evtlog,
  361. conf->pcs_s0ix_blkd_data,
  362. TELEM_MASK_BYTE);
  363. TELEM_CHECK_AND_PARSE_EVTS(conf->pss_wakeup_id,
  364. conf->pss_wakeup_evts,
  365. pss_s0ix_wakeup,
  366. evtlog[index].telem_evtlog,
  367. conf->pss_wakeup, TELEM_MASK_BYTE);
  368. TELEM_CHECK_AND_PARSE_EVTS(conf->pss_ltr_blocking_id,
  369. conf->pss_ltr_evts, pss_ltr_blkd,
  370. evtlog[index].telem_evtlog,
  371. conf->pss_ltr_data, TELEM_MASK_BYTE);
  372. if (evtlog[index].telem_evtid == debugfs_conf->pstates_id)
  373. pstates = evtlog[index].telem_evtlog;
  374. }
  375. seq_puts(s, "\n--------------------------------------\n");
  376. seq_puts(s, "PStates\n");
  377. seq_puts(s, "--------------------------------------\n");
  378. seq_puts(s, "Domain\t\t\t\tFreq(Mhz)\n");
  379. seq_printf(s, " IA\t\t\t\t %llu\n GT\t\t\t\t %llu\n",
  380. (pstates & TELEM_MASK_BYTE)*100,
  381. ((pstates >> 8) & TELEM_MASK_BYTE)*50/3);
  382. seq_printf(s, " IUNIT\t\t\t\t %llu\n SA\t\t\t\t %llu\n",
  383. ((pstates >> 16) & TELEM_MASK_BYTE)*25,
  384. ((pstates >> 24) & TELEM_MASK_BYTE)*50/3);
  385. seq_puts(s, "\n--------------------------------------\n");
  386. seq_puts(s, "PSS IDLE Status\n");
  387. seq_puts(s, "--------------------------------------\n");
  388. seq_puts(s, "Device\t\t\t\t\tIDLE\n");
  389. for (index = 0; index < debugfs_conf->pss_idle_evts; index++) {
  390. seq_printf(s, "%-32s\t%u\n",
  391. debugfs_conf->pss_idle_data[index].name,
  392. pss_idle[index]);
  393. }
  394. seq_puts(s, "\n--------------------------------------\n");
  395. seq_puts(s, "PSS Idle blkd Status (~1ms saturating bucket)\n");
  396. seq_puts(s, "--------------------------------------\n");
  397. seq_puts(s, "Blocker\t\t\t\t\tCount\n");
  398. for (index = 0; index < debugfs_conf->pcs_idle_blkd_evts; index++) {
  399. seq_printf(s, "%-32s\t%u\n",
  400. debugfs_conf->pcs_idle_blkd_data[index].name,
  401. pcs_idle_blkd[index]);
  402. }
  403. seq_puts(s, "\n--------------------------------------\n");
  404. seq_puts(s, "PSS S0ix blkd Status (~1ms saturating bucket)\n");
  405. seq_puts(s, "--------------------------------------\n");
  406. seq_puts(s, "Blocker\t\t\t\t\tCount\n");
  407. for (index = 0; index < debugfs_conf->pcs_s0ix_blkd_evts; index++) {
  408. seq_printf(s, "%-32s\t%u\n",
  409. debugfs_conf->pcs_s0ix_blkd_data[index].name,
  410. pcs_s0ix_blkd[index]);
  411. }
  412. seq_puts(s, "\n--------------------------------------\n");
  413. seq_puts(s, "LTR Blocking Status (~1ms saturating bucket)\n");
  414. seq_puts(s, "--------------------------------------\n");
  415. seq_puts(s, "Blocker\t\t\t\t\tCount\n");
  416. for (index = 0; index < debugfs_conf->pss_ltr_evts; index++) {
  417. seq_printf(s, "%-32s\t%u\n",
  418. debugfs_conf->pss_ltr_data[index].name,
  419. pss_s0ix_wakeup[index]);
  420. }
  421. seq_puts(s, "\n--------------------------------------\n");
  422. seq_puts(s, "Wakes Status (~1ms saturating bucket)\n");
  423. seq_puts(s, "--------------------------------------\n");
  424. seq_puts(s, "Wakes\t\t\t\t\tCount\n");
  425. for (index = 0; index < debugfs_conf->pss_wakeup_evts; index++) {
  426. seq_printf(s, "%-32s\t%u\n",
  427. debugfs_conf->pss_wakeup[index].name,
  428. pss_ltr_blkd[index]);
  429. }
  430. return 0;
  431. }
  432. static int telem_pss_state_open(struct inode *inode, struct file *file)
  433. {
  434. return single_open(file, telem_pss_states_show, inode->i_private);
  435. }
  436. static const struct file_operations telem_pss_ops = {
  437. .open = telem_pss_state_open,
  438. .read = seq_read,
  439. .llseek = seq_lseek,
  440. .release = single_release,
  441. };
  442. static int telem_ioss_states_show(struct seq_file *s, void *unused)
  443. {
  444. struct telemetry_evtlog evtlog[TELEM_MAX_OS_ALLOCATED_EVENTS];
  445. const char *name[TELEM_MAX_OS_ALLOCATED_EVENTS];
  446. int index, ret, err;
  447. ret = telemetry_read_eventlog(TELEM_IOSS, evtlog,
  448. TELEM_MAX_OS_ALLOCATED_EVENTS);
  449. if (ret < 0)
  450. return ret;
  451. err = telemetry_get_evtname(TELEM_IOSS, name,
  452. TELEM_MAX_OS_ALLOCATED_EVENTS);
  453. if (err < 0)
  454. return err;
  455. seq_puts(s, "--------------------------------------\n");
  456. seq_puts(s, "\tI0SS TELEMETRY EVENTLOG\n");
  457. seq_puts(s, "--------------------------------------\n");
  458. for (index = 0; index < ret; index++) {
  459. seq_printf(s, "%-32s 0x%llx\n",
  460. name[index], evtlog[index].telem_evtlog);
  461. }
  462. return 0;
  463. }
  464. static int telem_ioss_state_open(struct inode *inode, struct file *file)
  465. {
  466. return single_open(file, telem_ioss_states_show, inode->i_private);
  467. }
  468. static const struct file_operations telem_ioss_ops = {
  469. .open = telem_ioss_state_open,
  470. .read = seq_read,
  471. .llseek = seq_lseek,
  472. .release = single_release,
  473. };
  474. static int telem_soc_states_show(struct seq_file *s, void *unused)
  475. {
  476. u32 d3_sts[TELEM_IOSS_DX_D0IX_EVTS], d0ix_sts[TELEM_IOSS_DX_D0IX_EVTS];
  477. u32 pg_sts[TELEM_IOSS_PG_EVTS], pss_idle[TELEM_PSS_IDLE_EVTS];
  478. struct telemetry_evtlog evtlog[TELEM_MAX_OS_ALLOCATED_EVENTS];
  479. u32 s0ix_total_ctr = 0, s0ix_shlw_ctr = 0, s0ix_deep_ctr = 0;
  480. u64 s0ix_total_res = 0, s0ix_shlw_res = 0, s0ix_deep_res = 0;
  481. struct telemetry_debugfs_conf *conf = debugfs_conf;
  482. struct pci_dev *dev = NULL;
  483. int index, idx, ret;
  484. u32 d3_state;
  485. u16 pmcsr;
  486. ret = telemetry_read_eventlog(TELEM_IOSS, evtlog,
  487. TELEM_MAX_OS_ALLOCATED_EVENTS);
  488. if (ret < 0)
  489. return ret;
  490. for (index = 0; index < ret; index++) {
  491. TELEM_CHECK_AND_PARSE_EVTS(conf->ioss_d3_id,
  492. conf->ioss_d0ix_evts,
  493. d3_sts, evtlog[index].telem_evtlog,
  494. conf->ioss_d0ix_data,
  495. TELEM_MASK_BIT);
  496. TELEM_CHECK_AND_PARSE_EVTS(conf->ioss_pg_id, conf->ioss_pg_evts,
  497. pg_sts, evtlog[index].telem_evtlog,
  498. conf->ioss_pg_data, TELEM_MASK_BIT);
  499. TELEM_CHECK_AND_PARSE_EVTS(conf->ioss_d0ix_id,
  500. conf->ioss_d0ix_evts,
  501. d0ix_sts, evtlog[index].telem_evtlog,
  502. conf->ioss_d0ix_data,
  503. TELEM_MASK_BIT);
  504. TELEM_CHECK_AND_PARSE_CTRS(conf->s0ix_total_occ_id,
  505. s0ix_total_ctr);
  506. TELEM_CHECK_AND_PARSE_CTRS(conf->s0ix_shlw_occ_id,
  507. s0ix_shlw_ctr);
  508. TELEM_CHECK_AND_PARSE_CTRS(conf->s0ix_deep_occ_id,
  509. s0ix_deep_ctr);
  510. TELEM_CHECK_AND_PARSE_CTRS(conf->s0ix_total_res_id,
  511. s0ix_total_res);
  512. TELEM_CHECK_AND_PARSE_CTRS(conf->s0ix_shlw_res_id,
  513. s0ix_shlw_res);
  514. TELEM_CHECK_AND_PARSE_CTRS(conf->s0ix_deep_res_id,
  515. s0ix_deep_res);
  516. }
  517. seq_puts(s, "\n---------------------------------------------------\n");
  518. seq_puts(s, "S0IX Type\t\t\t Occurrence\t\t Residency(us)\n");
  519. seq_puts(s, "---------------------------------------------------\n");
  520. seq_printf(s, "S0IX Shallow\t\t\t %10u\t %10llu\n",
  521. s0ix_shlw_ctr -
  522. conf->suspend_stats.shlw_ctr -
  523. conf->suspend_stats.shlw_swake_ctr,
  524. (u64)((s0ix_shlw_res -
  525. conf->suspend_stats.shlw_res -
  526. conf->suspend_stats.shlw_swake_res)*10/192));
  527. seq_printf(s, "S0IX Deep\t\t\t %10u\t %10llu\n",
  528. s0ix_deep_ctr -
  529. conf->suspend_stats.deep_ctr -
  530. conf->suspend_stats.deep_swake_ctr,
  531. (u64)((s0ix_deep_res -
  532. conf->suspend_stats.deep_res -
  533. conf->suspend_stats.deep_swake_res)*10/192));
  534. seq_printf(s, "Suspend(With S0ixShallow)\t %10u\t %10llu\n",
  535. conf->suspend_stats.shlw_ctr,
  536. (u64)(conf->suspend_stats.shlw_res*10)/192);
  537. seq_printf(s, "Suspend(With S0ixDeep)\t\t %10u\t %10llu\n",
  538. conf->suspend_stats.deep_ctr,
  539. (u64)(conf->suspend_stats.deep_res*10)/192);
  540. seq_printf(s, "Suspend(With Shallow-Wakes)\t %10u\t %10llu\n",
  541. conf->suspend_stats.shlw_swake_ctr +
  542. conf->suspend_stats.deep_swake_ctr,
  543. (u64)((conf->suspend_stats.shlw_swake_res +
  544. conf->suspend_stats.deep_swake_res)*10/192));
  545. seq_printf(s, "S0IX+Suspend Total\t\t %10u\t %10llu\n", s0ix_total_ctr,
  546. (u64)(s0ix_total_res*10/192));
  547. seq_puts(s, "\n-------------------------------------------------\n");
  548. seq_puts(s, "\t\tDEVICE STATES\n");
  549. seq_puts(s, "-------------------------------------------------\n");
  550. for_each_pci_dev(dev) {
  551. pci_read_config_word(dev, dev->pm_cap + PCI_PM_CTRL, &pmcsr);
  552. d3_state = ((pmcsr & PCI_PM_CTRL_STATE_MASK) ==
  553. (__force int)PCI_D3hot) ? 1 : 0;
  554. seq_printf(s, "pci %04x %04X %s %20.20s: ",
  555. dev->vendor, dev->device, dev_name(&dev->dev),
  556. dev_driver_string(&dev->dev));
  557. seq_printf(s, " d3:%x\n", d3_state);
  558. }
  559. seq_puts(s, "\n--------------------------------------\n");
  560. seq_puts(s, "D3/D0i3 Status\n");
  561. seq_puts(s, "--------------------------------------\n");
  562. seq_puts(s, "Block\t\t D3\t D0i3\n");
  563. for (index = 0; index < conf->ioss_d0ix_evts; index++) {
  564. seq_printf(s, "%-10s\t %u\t %u\n",
  565. conf->ioss_d0ix_data[index].name,
  566. d3_sts[index], d0ix_sts[index]);
  567. }
  568. seq_puts(s, "\n--------------------------------------\n");
  569. seq_puts(s, "South Complex PowerGate Status\n");
  570. seq_puts(s, "--------------------------------------\n");
  571. seq_puts(s, "Device\t\t PG\n");
  572. for (index = 0; index < conf->ioss_pg_evts; index++) {
  573. seq_printf(s, "%-10s\t %u\n",
  574. conf->ioss_pg_data[index].name,
  575. pg_sts[index]);
  576. }
  577. evtlog->telem_evtid = conf->pss_idle_id;
  578. ret = telemetry_read_events(TELEM_PSS, evtlog, 1);
  579. if (ret < 0)
  580. return ret;
  581. seq_puts(s, "\n-----------------------------------------\n");
  582. seq_puts(s, "North Idle Status\n");
  583. seq_puts(s, "-----------------------------------------\n");
  584. for (idx = 0; idx < conf->pss_idle_evts - 1; idx++) {
  585. pss_idle[idx] = (evtlog->telem_evtlog >>
  586. conf->pss_idle_data[idx].bit_pos) &
  587. TELEM_MASK_BIT;
  588. }
  589. pss_idle[idx] = (evtlog->telem_evtlog >>
  590. conf->pss_idle_data[idx].bit_pos) &
  591. TELEM_APL_MASK_PCS_STATE;
  592. for (index = 0; index < conf->pss_idle_evts; index++) {
  593. seq_printf(s, "%-30s %u\n",
  594. conf->pss_idle_data[index].name,
  595. pss_idle[index]);
  596. }
  597. seq_puts(s, "\nPCS_STATUS Code\n");
  598. seq_puts(s, "0:C0 1:C1 2:C1_DN_WT_DEV 3:C2 4:C2_WT_DE_MEM_UP\n");
  599. seq_puts(s, "5:C2_WT_DE_MEM_DOWN 6:C2_UP_WT_DEV 7:C2_DN 8:C2_VOA\n");
  600. seq_puts(s, "9:C2_VOA_UP 10:S0IX_PRE 11:S0IX\n");
  601. return 0;
  602. }
  603. static int telem_soc_state_open(struct inode *inode, struct file *file)
  604. {
  605. return single_open(file, telem_soc_states_show, inode->i_private);
  606. }
  607. static const struct file_operations telem_socstate_ops = {
  608. .open = telem_soc_state_open,
  609. .read = seq_read,
  610. .llseek = seq_lseek,
  611. .release = single_release,
  612. };
  613. static int telem_s0ix_res_get(void *data, u64 *val)
  614. {
  615. u64 s0ix_total_res;
  616. int ret;
  617. ret = intel_pmc_s0ix_counter_read(&s0ix_total_res);
  618. if (ret) {
  619. pr_err("Failed to read S0ix residency");
  620. return ret;
  621. }
  622. *val = s0ix_total_res;
  623. return 0;
  624. }
  625. DEFINE_DEBUGFS_ATTRIBUTE(telem_s0ix_fops, telem_s0ix_res_get, NULL, "%llu\n");
  626. static int telem_pss_trc_verb_show(struct seq_file *s, void *unused)
  627. {
  628. u32 verbosity;
  629. int err;
  630. err = telemetry_get_trace_verbosity(TELEM_PSS, &verbosity);
  631. if (err) {
  632. pr_err("Get PSS Trace Verbosity Failed with Error %d\n", err);
  633. return -EFAULT;
  634. }
  635. seq_printf(s, "PSS Trace Verbosity %u\n", verbosity);
  636. return 0;
  637. }
  638. static ssize_t telem_pss_trc_verb_write(struct file *file,
  639. const char __user *userbuf,
  640. size_t count, loff_t *ppos)
  641. {
  642. u32 verbosity;
  643. int err;
  644. if (kstrtou32_from_user(userbuf, count, 0, &verbosity))
  645. return -EFAULT;
  646. err = telemetry_set_trace_verbosity(TELEM_PSS, verbosity);
  647. if (err) {
  648. pr_err("Changing PSS Trace Verbosity Failed. Error %d\n", err);
  649. count = err;
  650. }
  651. return count;
  652. }
  653. static int telem_pss_trc_verb_open(struct inode *inode, struct file *file)
  654. {
  655. return single_open(file, telem_pss_trc_verb_show, inode->i_private);
  656. }
  657. static const struct file_operations telem_pss_trc_verb_ops = {
  658. .open = telem_pss_trc_verb_open,
  659. .read = seq_read,
  660. .write = telem_pss_trc_verb_write,
  661. .llseek = seq_lseek,
  662. .release = single_release,
  663. };
  664. static int telem_ioss_trc_verb_show(struct seq_file *s, void *unused)
  665. {
  666. u32 verbosity;
  667. int err;
  668. err = telemetry_get_trace_verbosity(TELEM_IOSS, &verbosity);
  669. if (err) {
  670. pr_err("Get IOSS Trace Verbosity Failed with Error %d\n", err);
  671. return -EFAULT;
  672. }
  673. seq_printf(s, "IOSS Trace Verbosity %u\n", verbosity);
  674. return 0;
  675. }
  676. static ssize_t telem_ioss_trc_verb_write(struct file *file,
  677. const char __user *userbuf,
  678. size_t count, loff_t *ppos)
  679. {
  680. u32 verbosity;
  681. int err;
  682. if (kstrtou32_from_user(userbuf, count, 0, &verbosity))
  683. return -EFAULT;
  684. err = telemetry_set_trace_verbosity(TELEM_IOSS, verbosity);
  685. if (err) {
  686. pr_err("Changing IOSS Trace Verbosity Failed. Error %d\n", err);
  687. count = err;
  688. }
  689. return count;
  690. }
  691. static int telem_ioss_trc_verb_open(struct inode *inode, struct file *file)
  692. {
  693. return single_open(file, telem_ioss_trc_verb_show, inode->i_private);
  694. }
  695. static const struct file_operations telem_ioss_trc_verb_ops = {
  696. .open = telem_ioss_trc_verb_open,
  697. .read = seq_read,
  698. .write = telem_ioss_trc_verb_write,
  699. .llseek = seq_lseek,
  700. .release = single_release,
  701. };
  702. static int pm_suspend_prep_cb(void)
  703. {
  704. struct telemetry_evtlog evtlog[TELEM_MAX_OS_ALLOCATED_EVENTS];
  705. struct telemetry_debugfs_conf *conf = debugfs_conf;
  706. int ret, index;
  707. ret = telemetry_raw_read_eventlog(TELEM_IOSS, evtlog,
  708. TELEM_MAX_OS_ALLOCATED_EVENTS);
  709. if (ret < 0) {
  710. suspend_prep_ok = 0;
  711. goto out;
  712. }
  713. for (index = 0; index < ret; index++) {
  714. TELEM_CHECK_AND_PARSE_CTRS(conf->s0ix_shlw_occ_id,
  715. suspend_shlw_ctr_temp);
  716. TELEM_CHECK_AND_PARSE_CTRS(conf->s0ix_deep_occ_id,
  717. suspend_deep_ctr_temp);
  718. TELEM_CHECK_AND_PARSE_CTRS(conf->s0ix_shlw_res_id,
  719. suspend_shlw_res_temp);
  720. TELEM_CHECK_AND_PARSE_CTRS(conf->s0ix_deep_res_id,
  721. suspend_deep_res_temp);
  722. }
  723. suspend_prep_ok = 1;
  724. out:
  725. return NOTIFY_OK;
  726. }
  727. static int pm_suspend_exit_cb(void)
  728. {
  729. struct telemetry_evtlog evtlog[TELEM_MAX_OS_ALLOCATED_EVENTS];
  730. static u32 suspend_shlw_ctr_exit, suspend_deep_ctr_exit;
  731. static u64 suspend_shlw_res_exit, suspend_deep_res_exit;
  732. struct telemetry_debugfs_conf *conf = debugfs_conf;
  733. int ret, index;
  734. if (!suspend_prep_ok)
  735. goto out;
  736. ret = telemetry_raw_read_eventlog(TELEM_IOSS, evtlog,
  737. TELEM_MAX_OS_ALLOCATED_EVENTS);
  738. if (ret < 0)
  739. goto out;
  740. for (index = 0; index < ret; index++) {
  741. TELEM_CHECK_AND_PARSE_CTRS(conf->s0ix_shlw_occ_id,
  742. suspend_shlw_ctr_exit);
  743. TELEM_CHECK_AND_PARSE_CTRS(conf->s0ix_deep_occ_id,
  744. suspend_deep_ctr_exit);
  745. TELEM_CHECK_AND_PARSE_CTRS(conf->s0ix_shlw_res_id,
  746. suspend_shlw_res_exit);
  747. TELEM_CHECK_AND_PARSE_CTRS(conf->s0ix_deep_res_id,
  748. suspend_deep_res_exit);
  749. }
  750. if ((suspend_shlw_ctr_exit < suspend_shlw_ctr_temp) ||
  751. (suspend_deep_ctr_exit < suspend_deep_ctr_temp) ||
  752. (suspend_shlw_res_exit < suspend_shlw_res_temp) ||
  753. (suspend_deep_res_exit < suspend_deep_res_temp)) {
  754. pr_err("Wrong s0ix counters detected\n");
  755. goto out;
  756. }
  757. suspend_shlw_ctr_exit -= suspend_shlw_ctr_temp;
  758. suspend_deep_ctr_exit -= suspend_deep_ctr_temp;
  759. suspend_shlw_res_exit -= suspend_shlw_res_temp;
  760. suspend_deep_res_exit -= suspend_deep_res_temp;
  761. if (suspend_shlw_ctr_exit == 1) {
  762. conf->suspend_stats.shlw_ctr +=
  763. suspend_shlw_ctr_exit;
  764. conf->suspend_stats.shlw_res +=
  765. suspend_shlw_res_exit;
  766. }
  767. /* Shallow Wakes Case */
  768. else if (suspend_shlw_ctr_exit > 1) {
  769. conf->suspend_stats.shlw_swake_ctr +=
  770. suspend_shlw_ctr_exit;
  771. conf->suspend_stats.shlw_swake_res +=
  772. suspend_shlw_res_exit;
  773. }
  774. if (suspend_deep_ctr_exit == 1) {
  775. conf->suspend_stats.deep_ctr +=
  776. suspend_deep_ctr_exit;
  777. conf->suspend_stats.deep_res +=
  778. suspend_deep_res_exit;
  779. }
  780. /* Shallow Wakes Case */
  781. else if (suspend_deep_ctr_exit > 1) {
  782. conf->suspend_stats.deep_swake_ctr +=
  783. suspend_deep_ctr_exit;
  784. conf->suspend_stats.deep_swake_res +=
  785. suspend_deep_res_exit;
  786. }
  787. out:
  788. suspend_prep_ok = 0;
  789. return NOTIFY_OK;
  790. }
  791. static int pm_notification(struct notifier_block *this,
  792. unsigned long event, void *ptr)
  793. {
  794. switch (event) {
  795. case PM_SUSPEND_PREPARE:
  796. return pm_suspend_prep_cb();
  797. case PM_POST_SUSPEND:
  798. return pm_suspend_exit_cb();
  799. }
  800. return NOTIFY_DONE;
  801. }
  802. static struct notifier_block pm_notifier = {
  803. .notifier_call = pm_notification,
  804. };
  805. static int __init telemetry_debugfs_init(void)
  806. {
  807. const struct x86_cpu_id *id;
  808. int err;
  809. struct dentry *f;
  810. /* Only APL supported for now */
  811. id = x86_match_cpu(telemetry_debugfs_cpu_ids);
  812. if (!id)
  813. return -ENODEV;
  814. debugfs_conf = (struct telemetry_debugfs_conf *)id->driver_data;
  815. err = telemetry_pltconfig_valid();
  816. if (err < 0)
  817. return -ENODEV;
  818. err = telemetry_debugfs_check_evts();
  819. if (err < 0)
  820. return -EINVAL;
  821. register_pm_notifier(&pm_notifier);
  822. err = -ENOMEM;
  823. debugfs_conf->telemetry_dbg_dir = debugfs_create_dir("telemetry", NULL);
  824. if (!debugfs_conf->telemetry_dbg_dir)
  825. goto out_pm;
  826. f = debugfs_create_file("pss_info", S_IFREG | S_IRUGO,
  827. debugfs_conf->telemetry_dbg_dir, NULL,
  828. &telem_pss_ops);
  829. if (!f) {
  830. pr_err("pss_sample_info debugfs register failed\n");
  831. goto out;
  832. }
  833. f = debugfs_create_file("ioss_info", S_IFREG | S_IRUGO,
  834. debugfs_conf->telemetry_dbg_dir, NULL,
  835. &telem_ioss_ops);
  836. if (!f) {
  837. pr_err("ioss_sample_info debugfs register failed\n");
  838. goto out;
  839. }
  840. f = debugfs_create_file("soc_states", S_IFREG | S_IRUGO,
  841. debugfs_conf->telemetry_dbg_dir,
  842. NULL, &telem_socstate_ops);
  843. if (!f) {
  844. pr_err("ioss_sample_info debugfs register failed\n");
  845. goto out;
  846. }
  847. f = debugfs_create_file("s0ix_residency_usec", S_IFREG | S_IRUGO,
  848. debugfs_conf->telemetry_dbg_dir,
  849. NULL, &telem_s0ix_fops);
  850. if (!f) {
  851. pr_err("s0ix_residency_usec debugfs register failed\n");
  852. goto out;
  853. }
  854. f = debugfs_create_file("pss_trace_verbosity", S_IFREG | S_IRUGO,
  855. debugfs_conf->telemetry_dbg_dir, NULL,
  856. &telem_pss_trc_verb_ops);
  857. if (!f) {
  858. pr_err("pss_trace_verbosity debugfs register failed\n");
  859. goto out;
  860. }
  861. f = debugfs_create_file("ioss_trace_verbosity", S_IFREG | S_IRUGO,
  862. debugfs_conf->telemetry_dbg_dir, NULL,
  863. &telem_ioss_trc_verb_ops);
  864. if (!f) {
  865. pr_err("ioss_trace_verbosity debugfs register failed\n");
  866. goto out;
  867. }
  868. return 0;
  869. out:
  870. debugfs_remove_recursive(debugfs_conf->telemetry_dbg_dir);
  871. debugfs_conf->telemetry_dbg_dir = NULL;
  872. out_pm:
  873. unregister_pm_notifier(&pm_notifier);
  874. return err;
  875. }
  876. static void __exit telemetry_debugfs_exit(void)
  877. {
  878. debugfs_remove_recursive(debugfs_conf->telemetry_dbg_dir);
  879. debugfs_conf->telemetry_dbg_dir = NULL;
  880. unregister_pm_notifier(&pm_notifier);
  881. }
  882. late_initcall(telemetry_debugfs_init);
  883. module_exit(telemetry_debugfs_exit);
  884. MODULE_AUTHOR("Souvik Kumar Chakravarty <souvik.k.chakravarty@intel.com>");
  885. MODULE_DESCRIPTION("Intel SoC Telemetry debugfs Interface");
  886. MODULE_VERSION(DRIVER_VERSION);
  887. MODULE_LICENSE("GPL");