diff options
author | Gustavo A. R. Silva <gustavo@embeddedor.com> | 2018-03-10 07:27:35 +0100 |
---|---|---|
committer | Alexandre Belloni <alexandre.belloni@bootlin.com> | 2018-03-17 14:20:57 +0100 |
commit | 756d5282bf04db868b1c0b93f41981dabe2af57f (patch) | |
tree | 4631fc3f2adbe463c97c2ea3d3fd3b7dfaa45579 /crypto/pcrypt.c | |
parent | rtc: s5m: Move enum from rtc.h to rtc-s5m.c (diff) | |
download | linux-756d5282bf04db868b1c0b93f41981dabe2af57f.tar.xz linux-756d5282bf04db868b1c0b93f41981dabe2af57f.zip |
rtc: s5m: Remove VLA usage
In preparation to enabling -Wvla, remove VLAs and replace them
with fixed-length arrays instead.
>From a security viewpoint, the use of Variable Length Arrays can be
a vector for stack overflow attacks. Also, in general, as the code
evolves it is easy to lose track of how big a VLA can get. Thus, we
can end up having segfaults that are hard to debug.
Also, fixed as part of the directive to remove all VLAs from
the kernel: https://lkml.org/lkml/2018/3/7/621
Signed-off-by: Gustavo A. R. Silva <gustavo@embeddedor.com>
Reviewed-by: Krzysztof Kozlowski <krzk@kernel.org>
Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
Diffstat (limited to 'crypto/pcrypt.c')
0 files changed, 0 insertions, 0 deletions