m68k: Improved switch stack handling
Get series with b4
b4 am [email protected]Versions newest first · linked by author and title
- v4 Latest3 patches 25 repliesIn review
- v33 patches 2 repliesSuperseded
- v21 patch 11 repliesSuperseded
Patches in v4 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/3 | m68k: save extra registers on more syscall entry pointsarch/ arch/ arch/ | +65 | 0 replies | |
| 2/3 | m68k: correctly handle IO worker stack frame set-uparch/ arch/ | +24 | 0 replies | |
| 3/3 | m68k: track syscalls being traced with shallow user context stackarch/ arch/ arch/ +2 more | +104 | 4 replies |
Reviews trailers per patch
None of the 3 patches has a Reviewed-by or Acked-by of their own; the series has one for all of them.
| Patch | Geert Uytterhoeven |
|---|---|
| Series | A-b |
| 1/3 | |
| 2/3 | |
| 3/3 |
Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.
Cover letter [PATCH v4 0/3] m68k: Improved switch stack handling
m68k version of Eric's patch series 'alpha/ptrace: Improved switch_stack handling'.
Registers d6, d7, a3-a6 are not saved on the stack by default on every syscall entry by the m68k kernel. A separate switch stack frame is pushed to save those registers as needed. This leaves the majority of syscalls with only a subset of registers on the stack, and access to unsaved registers in those would expose or modify random stack addresses.
Patch 1 and 2 add a switch stack for all syscalls that were found to need one to allow ptrace access to all registers outside of syscall entry/exit tracing, as well as kernel worker threads. This ought to protect against accidents.
Patch 3 adds safety checks and debug output to m68k get_reg() and put_reg() functions. Any unsafe register access during process tracing will be prevented and reported.
Suggestions for optimizations or improvements welcome!
Cheers,
Michael