Searched hist:a4cccb4f6cbbb35d12bd5f8779f3c6d8d762619c (Results 1 – 1 of 1) sorted by relevance
| /rk3399_ARM-atf/common/ |
| H A D | feat_detect.c | a4cccb4f6cbbb35d12bd5f8779f3c6d8d762619c Wed Feb 01 11:46:31 UTC 2023 Andre Przywara <andre.przywara@arm.com> feat(cpufeat): extend check_feature() to deal with min/max
So far the check_feature() function compares the subfield of a CPU ID register against 0, to learn if a feature is enabled or not. This is problematic for checks that require a certain revision of a feature, so we should check against a minimum version number instead. On top of that we might need to add code to support newer versions of a feature, so we should be alerted if new hardware introduces a higher number.
Extend the check_feature() function to take two extra arguments: the minimum version, and the greatest currently known number. Then make sure that the CPU ID field is in this range.
Change-Id: I425b68535a2ba9eafd31854e74d142183b521cd5 Signed-off-by: Andre Przywara <andre.przywara@arm.com>
|