mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2026-02-17 11:21:05 -05:00
cpuidle: menu: Drop a redundant local variable
Local variable min in get_typical_interval() is updated, but never accessed later, so drop it. No functional impact. Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Reviewed-by: Christian Loehle <christian.loehle@arm.com> Tested-by: Artem Bityutskiy <artem.bityutskiy@linux.intel.com> Tested-by: Christian Loehle <christian.loehle@arm.com> Tested-by: Aboorva Devarajan <aboorvad@linux.ibm.com> Link: https://patch.msgid.link/13699686.uLZWGnKmhe@rjwysocki.net
This commit is contained in:
@@ -117,7 +117,7 @@ static void menu_update(struct cpuidle_driver *drv, struct cpuidle_device *dev);
|
||||
static unsigned int get_typical_interval(struct menu_device *data)
|
||||
{
|
||||
int i, divisor;
|
||||
unsigned int min, max, thresh, avg;
|
||||
unsigned int max, thresh, avg;
|
||||
uint64_t sum, variance;
|
||||
|
||||
thresh = INT_MAX; /* Discard outliers above this value */
|
||||
@@ -125,7 +125,6 @@ static unsigned int get_typical_interval(struct menu_device *data)
|
||||
again:
|
||||
|
||||
/* First calculate the average of past intervals */
|
||||
min = UINT_MAX;
|
||||
max = 0;
|
||||
sum = 0;
|
||||
divisor = 0;
|
||||
@@ -136,9 +135,6 @@ static unsigned int get_typical_interval(struct menu_device *data)
|
||||
divisor++;
|
||||
if (value > max)
|
||||
max = value;
|
||||
|
||||
if (value < min)
|
||||
min = value;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user