summaryrefslogtreecommitdiff
path: root/src/soc/ucb/riscv/cbmem.c
diff options
context:
space:
mode:
authorRyan Salsamendi <rsalsamendi@hotmail.com>2017-06-09 19:47:57 -0700
committerPatrick Georgi <pgeorgi@google.com>2017-06-14 19:51:38 +0200
commitfce582fa1c928051a3847d35cc334d040159aafb (patch)
treed24e33460ba7967c39bcc4bc7c1cf2c0ad139e1e /src/soc/ucb/riscv/cbmem.c
parentf0b071202377e3e4c5550ddaa28a727556745fa7 (diff)
cbmem_console: Fix undefined behavior
Fixes report found by undefined behavior sanitizer. Left shifting an int where the right operand is >= width of type is undefined. Add ul suffix since it's safe for unsigned types. Change-Id: I4b2365428e421085285006bc1ea8aea75890ff65 Signed-off-by: Ryan Salsamendi <rsalsamendi@hotmail.com> Reviewed-on: https://review.coreboot.org/20144 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Paul Menzel <paulepanter@users.sourceforge.net> Reviewed-by: Philippe Mathieu-Daudé <philippe.mathieu.daude@gmail.com> Reviewed-by: Martin Roth <martinroth@google.com> Reviewed-by: Youness Alaoui <snifikino@gmail.com>
Diffstat (limited to 'src/soc/ucb/riscv/cbmem.c')
0 files changed, 0 insertions, 0 deletions