riscv32: Use medany C model for modules
authorKhem Raj <raj.khem@gmail.com>
Sun, 6 Jun 2021 22:09:40 +0000 (15:09 -0700)
committerPalmer Dabbelt <palmerdabbelt@google.com>
Sun, 13 Jun 2021 00:20:49 +0000 (17:20 -0700)
commit5d2388dbf84adebeb6d9742164be8d32728e4269
treee3410ea87a1c0c08eccdb169bbbdefa7e63958c6
parent0ddd7eaffa644baa78e247bbd220ab7195b1eed6
riscv32: Use medany C model for modules

When CONFIG_CMODEL_MEDLOW is used it ends up generating riscv_hi20_rela
relocations in modules which are not resolved during runtime and
following errors would be seen

[    4.802714] virtio_input: target 00000000c1539090 can not be addressed by the 32-bit offset from PC = 39148b7b
[    4.854800] virtio_input: target 00000000c1539090 can not be addressed by the 32-bit offset from PC = 9774456d

Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Palmer Dabbelt <palmerdabbelt@google.com>
arch/riscv/Makefile