diff options
author | Tudor Ambarus <[email protected]> | 2024-02-07 12:04:19 +0000 |
---|---|---|
committer | Mark Brown <[email protected]> | 2024-02-08 16:33:29 +0000 |
commit | a336d41bbea51e11e3e4f56bd3877a535c077129 (patch) | |
tree | 61ae9810d82613dd7c0e24cc213714cf49e26d4d /tools/testing/selftests/bpf/progs/recvmsg_unix_prog.c | |
parent | 7256d6bdd4fe0eac6d4bcd138c3d87f95f79c750 (diff) |
spi: s3c64xx: avoid possible negative array index
The platform id is used as an index into the fifo_lvl_mask array.
Platforms can come with a negative device ID, PLATFORM_DEVID_NONE (-1),
thus we risked a negative array index. Catch such cases and fail to
probe.
Reviewed-by: Sam Protsenko <[email protected]>
Reviewed-by: Peter Griffin <[email protected]>
Signed-off-by: Tudor Ambarus <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Mark Brown <[email protected]>
Diffstat (limited to 'tools/testing/selftests/bpf/progs/recvmsg_unix_prog.c')
0 files changed, 0 insertions, 0 deletions