mirror of
https://github.com/torvalds/linux.git
synced 2026-05-12 16:18:45 +02:00
cputemp_is_visible() validates the channel index against
CPUTEMP_CHANNEL_NUMS, but currently uses '>' instead of '>='.
As a result, channel == CPUTEMP_CHANNEL_NUMS is not rejected even though
valid indices are 0 .. CPUTEMP_CHANNEL_NUMS - 1.
Fix the bounds check by using '>=' so invalid channel indices are
rejected before indexing the core bitmap.
Fixes:
|
||
|---|---|---|
| .. | ||
| common.h | ||
| cputemp.c | ||
| dimmtemp.c | ||
| Kconfig | ||
| Makefile | ||