Re: [PATCH] s390: Warn if kernel command line contains non-printable EBCDIC characters

Ilya Leoshkevich <[email protected]>
Newsgroups org.kernel.vger.linux-s390,org.kernel.vger.linux-kernel
Message-ID <[email protected]>

On 8/26/26 15:51, David Laight wrote:
> On Tue, 25 Aug 2026 17:08:08 +0200
> Ilya Leoshkevich <[email protected]> wrote:
> 
>> Users may accidentally add multi-byte UTF-8 characters to zipl.conf
>> parmline, for example, by copying snippets containing non-breaking
>> spaces (\xC2\xA0) from web pages.
>>
>> The kernel will then interpret the entire command line as EBCDIC,
>> making it unusable. Distinguish this situation from the legitimate
>> EBCDIC conversion by looking for non-printable characters and issue
>> a warning.
> 
> Would it be better to check for the entire line being printable ebcdic?
> All of EBCDIC a-zA-Z0-9 have the 0x80 bit set and most of 0x20..0x7f
> are invalid or control characters (or punctuation).
> 
> David

I actually started with that, but this required introducing a new
_ctype-like table (unfortunately it's not as simple as checking a
couple ranges), so I decided against that and took a shortcut via
ASCII.

[...]
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.