Re: [PATCH v3 6/7] riscv: Ensure gp is NULL or points to valid data

2020-09-21 Thread Rick Chen
> This ensures constructs like `if (gd & gd->...) { ... }` work when > accessing the global data pointer. Without this change, it was possible for > a very early trap to cause _exit_trap to directly or indirectly (through > printf) to read arbitrary memory. This could cause a second trap, > prevent

[PATCH v3 6/7] riscv: Ensure gp is NULL or points to valid data

2020-09-21 Thread Sean Anderson
This ensures constructs like `if (gd & gd->...) { ... }` work when accessing the global data pointer. Without this change, it was possible for a very early trap to cause _exit_trap to directly or indirectly (through printf) to read arbitrary memory. This could cause a second trap, preventing show_r