Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1731472
| From | Allen Pais <allen.lkml@gmail.com> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | [PATCH v2] drivers:platform/x86:Use ARRAY_SIZE() for the size calculation of the array. |
| Date | 2017-09-13 11:00 +0200 |
| Message-ID | <upbGy-542-17@gated-at.bofh.it> (permalink) |
| Organization | linux.* mail to news gateway |
Signed-off-by: Allen Pais <allen.lkml@gmail.com>
---
drivers/platform/x86/intel_telemetry_debugfs.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/platform/x86/intel_telemetry_debugfs.c b/drivers/platform/x86/intel_telemetry_debugfs.c
index d4fc42b..6b63b3d 100644
--- a/drivers/platform/x86/intel_telemetry_debugfs.c
+++ b/drivers/platform/x86/intel_telemetry_debugfs.c
@@ -76,7 +76,7 @@
#define TELEM_IOSS_DX_D0IX_EVTS 25
#define TELEM_IOSS_PG_EVTS 30
-#define TELEM_EVT_LEN(x) (sizeof(x)/sizeof((x)[0]))
+#define TELEM_EVT_LEN(x) ARRAY_SIZE(x)
#define TELEM_DEBUGFS_CPU(model, data) \
{ X86_VENDOR_INTEL, 6, model, X86_FEATURE_ANY, (unsigned long)&data}
--
2.7.4
Back to linux.kernel | Previous | Next — Next in thread | Find similar | Unroll thread
[PATCH v2] drivers:platform/x86:Use ARRAY_SIZE() for the size calculation of the array. Allen Pais <allen.lkml@gmail.com> - 2017-09-13 11:00 +0200
Re: [PATCH v2] drivers:platform/x86:Use ARRAY_SIZE() for the size calculation of the array. Bjørn Mork <bjorn@mork.no> - 2017-09-13 12:10 +0200
RE: [PATCH v2] drivers:platform/x86:Use ARRAY_SIZE() for the size calculation of the array. "Chakravarty, Souvik K" <souvik.k.chakravarty@intel.com> - 2017-09-13 12:20 +0200
Re: [PATCH v2] drivers:platform/x86:Use ARRAY_SIZE() for the size calculation of the array. Allen <allen.lkml@gmail.com> - 2017-09-13 13:00 +0200
csiph-web