This can leak kernel stack data otherwise.
Details
Details
Diff Detail
Diff Detail
- Repository
- rG FreeBSD src repository
- Lint
Lint Not Applicable - Unit
Tests Not Applicable
Event Timeline
Comment Actions
So it's fine as is, but a pad might be better...
sys/arm/arm/exec_machdep.c | ||
---|---|---|
113 | Or we could add a a 'mcv_pad' int32_t field and just set that... It's the only bytes that need to be set and setting the other 32*8+4 (260 bytes).... |
sys/arm/arm/exec_machdep.c | ||
---|---|---|
113 | We should put a pad field in as the compiler could still leak kernel stack data via the padding. |
sys/arm/arm/exec_machdep.c | ||
---|---|---|
113 | Modern compilers are smart enough given that memcpy and memset are builtins to only memset the bits that aren't overwritten by the memcpy. I'm not sure of the value of making the padding field explicit? |