The KD_FONT_OP_SET/GET operations hardcode vpitch to be 32 pixels, which only dates from the old VGA hardware which as asserting this. Drivers such as fbcon however do not have such limitation, so this introduces KD_FONT_OP_SET/GET_TALL operations, which userland can try to use to avoid this limitation, thus opening the patch to >32 pixels font height.
Showing the changes to include/uapi (1 of 2 files). Show all
Unified · Split
| @@ -161,19 +161,25 @@ struct console_font_op { · 160 unmodified lines | ||
| 161 | 161 | unsigned int flags; /* KD_FONT_FLAG_* */ |
| 162 | 162 | unsigned int width, height; /* font size */ |
| 163 | 163 | unsigned int charcount; |
| 164 | − unsigned char __user *data; /* font data with height fixed to 32 */ | |
| 164 | + unsigned char __user *data; /* font data with vpitch fixed to 32 for | |
| 165 | + * KD_FONT_OP_SET/GET | |
| 166 | + */ | |
| 165 | 167 | }; |
| 166 | 168 | |
| 167 | 169 | struct console_font { |
| 168 | 170 | unsigned int width, height; /* font size */ |
| 169 | 171 | unsigned int charcount; |
| 170 | − unsigned char *data; /* font data with height fixed to 32 */ | |
| 172 | + unsigned char *data; /* font data with vpitch fixed to 32 for | |
| 173 | + * KD_FONT_OP_SET/GET | |
| 174 | + */ | |
| 171 | 175 | }; |
| 172 | 176 | |
| 173 | 177 | #define KD_FONT_OP_SET 0 /* Set font */ |
| 174 | 178 | #define KD_FONT_OP_GET 1 /* Get font */ |
| 175 | 179 | #define KD_FONT_OP_SET_DEFAULT 2 /* Set font to default, data points to name / NULL */ |
| 176 | 180 | #define KD_FONT_OP_COPY 3 /* Obsolete, do not use */ |
| 181 | +#define KD_FONT_OP_SET_TALL 4 /* Set font with vpitch = height */ | |
| 182 | +#define KD_FONT_OP_GET_TALL 5 /* Get font with vpitch = height */ | |
| 177 | 183 | |
| 178 | 184 | #define KD_FONT_FLAG_DONT_RECALC 1 /* Don't recalculate hw charcell size [compat] */ |
| 179 | 185 | |