Eliminate duplicate p-states entries

Reported and tested by:	ales dot rom at kabelnet dot net
Reviewed by:	njl
Approved by:	njl, imp (mentor)
MFC after:	3 days
This commit is contained in:
Bruno Ducrot 2006-07-15 17:34:03 +00:00
parent 62fad4a13f
commit 2880646d24
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=160381

View File

@ -299,6 +299,12 @@ acpi_perf_evaluate(device_t dev)
sc->px_states[count].core_freq >= 0xffff)
continue;
/* Check for duplicate entries */
if (count > 0 &&
sc->px_states[count - 1].core_freq ==
sc->px_states[count].core_freq)
continue;
count++;
}
sc->px_count = count;