Searched hist:f57af6df (Results 1 – 1 of 1) sorted by relevance
/openbmc/linux/drivers/hwtracing/stm/ |
H A D | policy.c | f57af6df Mon Mar 28 02:55:42 CDT 2016 Chunyan Zhang <zhang.chunyan@linaro.org> stm class: Fix integer boundary checks for master range
Master IDs are of unsigned int type, yet in the configfs policy code we're validating user's input against INT_MAX. This is both pointless and misleading as the real limits are imposed by the stm device's [sw_start..sw_end] (which are also limited by the spec to be no larger than 2^16-1).
Clean this up by getting rid of the redundant comparisons.
Signed-off-by: Chunyan Zhang <zhang.chunyan@linaro.org> Signed-off-by: Alexander Shishkin <alexander.shishkin@linux.intel.com> Reviewed-by: Laurent Fert <laurent.fert@intel.com> f57af6df Mon Mar 28 02:55:42 CDT 2016 Chunyan Zhang <zhang.chunyan@linaro.org> stm class: Fix integer boundary checks for master range Master IDs are of unsigned int type, yet in the configfs policy code we're validating user's input against INT_MAX. This is both pointless and misleading as the real limits are imposed by the stm device's [sw_start..sw_end] (which are also limited by the spec to be no larger than 2^16-1). Clean this up by getting rid of the redundant comparisons. Signed-off-by: Chunyan Zhang <zhang.chunyan@linaro.org> Signed-off-by: Alexander Shishkin <alexander.shishkin@linux.intel.com> Reviewed-by: Laurent Fert <laurent.fert@intel.com>
|