hwmon/coretemp: Handle large core ID value
The coretemp driver supports up to a hard-coded limit of 128 cores. Today, the driver can not support a core with an ID above that limit. Yet, the encoding of core ID's is arbitrary (BIOS APIC-ID) and so they may be sparse and they may be large. Update the driver to map arbitrary core ID numbers into appropriate array indexes so that 128 cores can be supported, no matter the encoding of core ID's. Signed-off-by: NZhang Rui <rui.zhang@intel.com> Signed-off-by: NDave Hansen <dave.hansen@linux.intel.com> Acked-by: NLen Brown <len.brown@intel.com> Acked-by: NGuenter Roeck <linux@roeck-us.net> Cc: stable@vger.kernel.org Link: https://lkml.kernel.org/r/20221014090147.1836-3-rui.zhang@intel.com
Showing
想要评论请 注册 或 登录