summaryrefslogtreecommitdiffstats
path: root/drivers/platform
diff options
context:
space:
mode:
authorDan Carpenter <dan.carpenter@oracle.com>2016-04-15 16:45:58 +0200
committerDarren Hart <dvhart@linux.intel.com>2016-04-15 17:26:41 +0200
commitd0192dca2d6b64c043db5babb40076d13a6e955b (patch)
tree6f6b2ac630bae4425d73fc8c288562c3dfe77639 /drivers/platform
parenthp_accel: Silence an uninitialized variable warning (diff)
downloadlinux-d0192dca2d6b64c043db5babb40076d13a6e955b.tar.xz
linux-d0192dca2d6b64c043db5babb40076d13a6e955b.zip
intel_telemetry_pltdrv: Silence an uninitialized variable warning
Presumably "pss_period" and "ioss_period" can't both be zero, but this function is never called so we can't infer that using static analysis alone. Silence the warning by setting "ret" to zero. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Darren Hart <dvhart@linux.intel.com>
Diffstat (limited to 'drivers/platform')
-rw-r--r--drivers/platform/x86/intel_telemetry_pltdrv.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/platform/x86/intel_telemetry_pltdrv.c b/drivers/platform/x86/intel_telemetry_pltdrv.c
index 397119f83e82..781bd10ca7ac 100644
--- a/drivers/platform/x86/intel_telemetry_pltdrv.c
+++ b/drivers/platform/x86/intel_telemetry_pltdrv.c
@@ -659,7 +659,7 @@ static int telemetry_plt_update_events(struct telemetry_evtconfig pss_evtconfig,
static int telemetry_plt_set_sampling_period(u8 pss_period, u8 ioss_period)
{
u32 telem_ctrl = 0;
- int ret;
+ int ret = 0;
mutex_lock(&(telm_conf->telem_lock));
if (ioss_period) {