Searched hist:"7 b3bb0e7" (Results 1 – 1 of 1) sorted by relevance
/openbmc/linux/drivers/hwtracing/stm/ |
H A D | core.c | 7b3bb0e7 Tue Dec 22 09:25:20 CST 2015 Chunyan Zhang <zhang.chunyan@linaro.org> stm class: Fix an off-by-one in master array allocation
Since both sw_start and sw_end are master indices, the size of array that holds them is sw_end - sw_start + 1, which the current code gets wrong, allocating one item less than required.
This patch corrects the allocation size, avoiding potential slab corruption.
Signed-off-by: Chunyan Zhang <zhang.chunyan@linaro.org> [alexander.shishkin@linux.intel.com: re-wrote the commit message] Signed-off-by: Alexander Shishkin <alexander.shishkin@linux.intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> 7b3bb0e7 Tue Dec 22 09:25:20 CST 2015 Chunyan Zhang <zhang.chunyan@linaro.org> stm class: Fix an off-by-one in master array allocation Since both sw_start and sw_end are master indices, the size of array that holds them is sw_end - sw_start + 1, which the current code gets wrong, allocating one item less than required. This patch corrects the allocation size, avoiding potential slab corruption. Signed-off-by: Chunyan Zhang <zhang.chunyan@linaro.org> [alexander.shishkin@linux.intel.com: re-wrote the commit message] Signed-off-by: Alexander Shishkin <alexander.shishkin@linux.intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
|