The passed parameter to sysrq handlers is a key (a character). So change the type from 'int' to 'u8'. Let it specifically be 'u8' for two reasons: * unsigned: unsigned values come from the upper layers (devices) and the tty layer assumes unsigned on most places, and * 8-bit: as that what's supposed to be one day in all the layers built on the top of tty. (Currently, we use mostly 'unsigned char' and somewhere still only 'char'. (But that also translates to the former thanks to -funsigned-char.))
Showing the changes to kernel/debug (1 of 11 files). Show all
Unified · Split
| @@ -968,7 +968,7 @@ static int __init opt_kgdb_con(char *str) · 967 unmodified lines | ||
| 968 | 968 | early_param("kgdbcon", opt_kgdb_con); |
| 969 | 969 | |
| 970 | 970 | #ifdef CONFIG_MAGIC_SYSRQ |
| 971 | −static void sysrq_handle_dbg(int key) | |
| 971 | +static void sysrq_handle_dbg(u8 key) | |
| 972 | 972 | { |
| 973 | 973 | if (!dbg_io_ops) { |
| 974 | 974 | pr_crit("ERROR: No KGDB I/O module available\n"); |