1
0
mirror of https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git synced 2026-01-12 01:20:14 +00:00
Ben Horgan c2803bd580 arm_mpam: Stop using uninitialized variables in __ris_msmon_read()
Dan has reported two uses of uninitialized variables in __ris_msmon_read().
If an unknown monitor type is encountered then the local variable, now, is
used uninitialized. Fix this by returning early on error. If a non-mbwu
monitor is being read then the local variable, overflow, is not initialized
but still read. Initialize it to false as overflow is not relevant for csu
monitors.

Fixes: 823e7c3712c5 ("arm_mpam: Add mpam_msmon_read() to read monitor value")
Fixes: 9e5afb7c3283 ("arm_mpam: Use long MBWU counters if supported")
Reported-by: kernel test robot <lkp@intel.com>
Reported-by: Dan Carpenter <dan.carpenter@linaro.org>
Closes: https://lore.kernel.org/r/202512091519.RBwiJcSq-lkp@intel.com/
Closes: https://lore.kernel.org/r/202512100547.N7QPYgfb-lkp@intel.com/
Signed-off-by: Ben Horgan <ben.horgan@arm.com>
Reviewed-by: Jonathan Cameron <jonathan.cameron@huawei.com>
Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
2026-01-08 19:03:15 +00:00
..
2025-12-10 06:38:17 +09:00
2025-12-05 17:29:04 -08:00
2025-12-05 20:41:20 -08:00
2025-12-05 17:29:04 -08:00
2025-12-05 21:29:02 -08:00
2025-12-05 17:29:04 -08:00
2025-12-06 10:15:41 -08:00
2025-12-05 17:47:59 -08:00
2025-11-27 18:11:43 -08:00
2025-12-09 06:35:53 +09:00
2025-12-04 18:42:48 -08:00
2025-12-06 09:01:27 -08:00
2025-12-04 12:26:36 -08:00
2025-12-13 05:44:03 +12:00
2025-12-13 16:36:57 +12:00
2025-12-13 17:39:28 +12:00
2025-12-10 06:38:17 +09:00
2025-12-09 06:10:17 +09:00
2025-12-09 08:46:10 +09:00
2025-12-10 07:48:05 +09:00
2025-12-10 16:44:18 +09:00
2025-12-06 10:15:41 -08:00
2025-12-14 06:07:09 +12:00
2025-12-05 17:29:04 -08:00
2025-12-05 17:29:04 -08:00
2025-12-14 15:35:35 +12:00
2025-12-06 08:27:07 -08:00
2025-12-05 17:29:04 -08:00
2025-12-04 15:18:33 -08:00
2025-12-04 14:10:16 -08:00
2025-12-08 11:25:14 +09:00
2025-12-06 09:32:25 -08:00
2025-12-09 08:53:24 +09:00
2025-12-13 16:26:55 +12:00
2025-12-13 16:29:22 +12:00
2025-12-02 17:03:55 -08:00
2025-12-10 06:38:17 +09:00
2025-12-04 13:50:39 -08:00
2025-12-05 17:29:04 -08:00
2025-12-04 15:50:37 -08:00
2025-12-03 12:42:36 -08:00
2025-12-03 17:24:33 -08:00
2025-12-04 17:10:08 -08:00
2025-12-11 09:54:59 +09:00
2025-12-13 17:09:06 +12:00
2025-12-14 15:35:35 +12:00
2025-12-03 17:24:33 -08:00
2025-12-06 09:01:27 -08:00
2025-12-11 09:57:08 +09:00
2025-12-14 15:35:35 +12:00
2025-12-05 17:29:04 -08:00
2025-12-06 18:38:19 -08:00
2025-12-06 18:42:12 -08:00
2025-12-04 19:42:53 -08:00
2025-12-04 18:59:21 -08:00
2025-12-06 10:00:49 -08:00
2025-12-06 10:49:19 -08:00
2025-12-06 18:52:00 -08:00
2025-12-06 18:52:00 -08:00