public inbox for linux-mtd@lists.infradead.org
 help / color / mirror / Atom feed
From: Martin Walch <walch.martin@web.de>
To: dedekind1@gmail.com
Cc: Scott Wood <scottwood@freescale.com>,
	Wolfram Sang <wolfram@the-dreams.de>,
	linux-mtd@lists.infradead.org
Subject: Re: [PATCH] mtd: nand: Kconfig: drop utf8 characters
Date: Mon, 17 Dec 2012 04:27:20 +0100	[thread overview]
Message-ID: <1568980.QkbR4hXzWB@tacticalops> (raw)
In-Reply-To: <1354541353.11583.12.camel@sauron.fi.intel.com>

[-- Attachment #1: Type: text/plain, Size: 2307 bytes --]

Am Montag, 3. Dezember 2012, 15:29:13 schrieb Artem Bityutskiy:
> On Mon, 2012-11-26 at 17:18 -0600, Scott Wood wrote:
> > On 11/26/2012 05:07:25 PM, Wolfram Sang wrote:
> > > The Linux Kernel Configuration system (lkc) expects 8 bit characters
> > > only (declared in scripts/kconfig/zconf.l: %option 8bit).
> > 
> > That option contrasts with being limited to 7-bit characters, not with
> > accepting UTF-8.  It may be that kconfig has problems with UTF-8, but I
> > don't think this is why.
> 
> Whatever has problems with UTF-8 - it is better to fix that instead of
> hiding the problem by removing UTF-8 characters.

The kernel configuration system does not support multibyte characters. I have 
not found any hint that support for multibyte characters has been specified or 
taken into account. In many places throughout the configuration system, only 
single byte characters are assumed. In bug #43067

> https://bugzilla.kernel.org/show_bug.cgi?id=43067

I have attached screenshots showing a problem with utf-8 characters in the 
interactive nconfig menu.

More usage of utf-8 characters could even lead to worse problems: the flex 
scanner only allows the characters [A-Za-z0-9_] in symbol names. Other input 
will make the scanner ignore a character or refuse the input at all ("syntax 
error").

The handling of multibyte characters in string values depends on the 
configuration menu in use. menuconfig will not allow any multibyte input. When 
editing a predefined string with multibyte characters in it, things will break. 
nconfig is even worse. xconfig substitutes characters with '?'.

Character counts do not work correctly. When using many multibyte characters 
funny things happen like text lines being cut off.

To make a long story short: multibyte characters in Kconfig files lead to 
undefined behaviour. This is no implementation bug. The configuration system 
just has not been designed for processing them. So utf-8 support can not be 
achieved with an easy fix, but will need comprehensive changes.

I do not know if anyone is willing to actually make all the necessary work to 
properly support utf-8 in the configuration system. However, I suppose this 
will not happen any time soon. Therefore I suggest removing the multibyte 
characters for now. 

Regards
Martin Walch
-- 

[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 198 bytes --]

  parent reply	other threads:[~2012-12-17  3:27 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-11-26 23:07 [PATCH] mtd: nand: Kconfig: drop utf8 characters Wolfram Sang
2012-11-26 23:18 ` Scott Wood
2012-12-03 13:29   ` Artem Bityutskiy
2012-12-03 13:29     ` Wolfram Sang
2012-12-17  3:27     ` Martin Walch [this message]
2013-01-15 10:40       ` Artem Bityutskiy
2013-01-15 11:00         ` Artem Bityutskiy
2012-12-03 13:28 ` Artem Bityutskiy

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1568980.QkbR4hXzWB@tacticalops \
    --to=walch.martin@web.de \
    --cc=dedekind1@gmail.com \
    --cc=linux-mtd@lists.infradead.org \
    --cc=scottwood@freescale.com \
    --cc=wolfram@the-dreams.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox