On 14-Apr-21 11:00 AM, Burakov, Anatoly wrote:
On 14-Apr-21 10:24 AM, Pattan, Reshma wrote:
-Original Message-
From: Burakov, Anatoly
base_max_ratio =
strtoul(buf_base, NULL,
POWER_CONVERT_TO_DECIMAL)
/ BUS_FREQ;
+/* not needed any more */
+fclose(f_base_max);
+f_base_max = NUL
On 14-Apr-21 10:24 AM, Pattan, Reshma wrote:
-Original Message-
From: Burakov, Anatoly
base_max_ratio =
strtoul(buf_base, NULL,
POWER_CONVERT_TO_DECIMAL)
/ BUS_FREQ;
+/* not needed any more */
+fclose(f_base_max);
+f_base_max = NULL;
Should this be moved before FOPS_OR_NULL_GO
> -Original Message-
> From: Burakov, Anatoly
> base_max_ratio =
> strtoul(buf_base, NULL,
> POWER_CONVERT_TO_DECIMAL)
> / BUS_FREQ;
> + /* not needed any more */
> + fclose(f_base_max);
> +
Currently, we open the system base frequency file, but never close it,
which results in a memory leak.
Coverity issue: 369693
Fixes: 8a5febaac4f7 ("power: fix P-state base frequency handling")
Cc: david.h...@intel.com
Cc: reshma.pat...@intel.com
Signed-off-by: Anatoly Burakov
---
Notes:
Id
4 matches
Mail list logo