Received: by 2002:a25:8b91:0:0:0:0:0 with SMTP id j17csp624395ybl; Tue, 7 Jan 2020 12:06:03 -0800 (PST) X-Google-Smtp-Source: APXvYqwtlhUM57fatS5vUGIy0dDa7pbekY1tlGpd96NBwRka+AKd1FVL0CTSvCwiK4ng846mqgLc X-Received: by 2002:a9d:6d10:: with SMTP id o16mr1582960otp.28.1578427563479; Tue, 07 Jan 2020 12:06:03 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1578427563; cv=none; d=google.com; s=arc-20160816; b=tzOkfyUwa5bJBCimSQm7dnP7DNp+JHemxFbZrvZMqh2wp9NCOpHBX4k8XrUM/9zN40 BKyu/boqj7tMdiffeVm83e6qkQBwsDTBiVoorphr9zngRsqWaBx+jhsrpUCmABnx2Tq6 QCnigzDQ2eeBIiEjgz+ojx+9pIkuMbQHfQoZkyF51E+ILoyB9RswJIWMsfmv8p9GeahF SNXvllHdIzquLIhd/DO3mfWBTxxhuXisVNJu6phrTbbmR+AppsrfPJjcmWegYHjSWNLW ezxdiu8tH7flPo/z5Qfx8ogL3S2c5ueRmER69y/cwrHzAHfSJR3dlpEBjjuaQUbuzfrS 6TMA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:in-reply-to:content-transfer-encoding :content-disposition:mime-version:references:message-id:subject:cc :to:from:date; bh=grZr5b4wV5NZBVwxf2jKMlLXCfNDzFgnSkenTlSGzQs=; b=EIXra0frLOPCp9hKZXoKwmxxYcjuOjVnVOCyaL0xjgw6tmJwlXktKYAhHeBFbhB8K1 gYNmVoYJYt9IoW0vRftavHgn71lEpqoIjdVLeTNn6OUEv92YlSOHEqPgCeJaflHTrCDf eBa1OnZlNfoZPeqLRZU2ciQhuXOl9gtIS+y21RqXUOUUw1bvRa3BcxJFABkktAEM5a7U ArJS3MvHtUBvA5PSiUHV8HD7IX3+xcH+RiqOxlIL1e5ZrOrvd29OeTAzjTSwtmGITov1 zWUSs4g6ducHXVDAJarWVPxWYFjNM2NM/+1nbRnuMXfxpQIAJBftRBPkd9vbIxCOYDYf b0Zg== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id y127si537204oiy.250.2020.01.07.12.05.50; Tue, 07 Jan 2020 12:06:03 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728691AbgAGUEu (ORCPT + 99 others); Tue, 7 Jan 2020 15:04:50 -0500 Received: from outgoing-auth-1.mit.edu ([18.9.28.11]:54363 "EHLO outgoing.mit.edu" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1728358AbgAGUEt (ORCPT ); Tue, 7 Jan 2020 15:04:49 -0500 Received: from callcc.thunk.org (guestnat-104-133-0-111.corp.google.com [104.133.0.111] (may be forged)) (authenticated bits=0) (User authenticated as tytso@ATHENA.MIT.EDU) by outgoing.mit.edu (8.14.7/8.12.4) with ESMTP id 007K31WJ002663 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Tue, 7 Jan 2020 15:03:02 -0500 Received: by callcc.thunk.org (Postfix, from userid 15806) id B2F684207DF; Tue, 7 Jan 2020 15:03:01 -0500 (EST) Date: Tue, 7 Jan 2020 15:03:01 -0500 From: "Theodore Y. Ts'o" To: Pali =?iso-8859-1?Q?Roh=E1r?= Cc: Jan Kara , linux-kernel@vger.kernel.org, linux-fsdevel@vger.kernel.org, linux-ntfs-dev@lists.sourceforge.net, linux-cifs@vger.kernel.org, Alexander Viro , Luis de Bethencourt , Salah Triki , Steve French , OGAWA Hirofumi , Greg Kroah-Hartman , Thomas Gleixner , David Sterba , Dave Kleikamp , Anton Altaparmakov , Jan Kara , Eric Sandeen , Namjae Jeon , Pavel Machek , Christoph Hellwig Subject: Re: Unification of filesystem encoding options Message-ID: <20200107200301.GE3619@mit.edu> References: <20200102211855.gg62r7jshp742d6i@pali> <20200107133233.GC25547@quack2.suse.cz> <20200107173842.ciskn4ahuhiklycm@pali> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <20200107173842.ciskn4ahuhiklycm@pali> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Jan 07, 2020 at 06:38:42PM +0100, Pali Roh?r wrote: > Adding support for case-insensitivity into UTF-8 NLS encoding would mean > to create completely new kernel NLS API (which would support variable > length encodings) and rewrite all NLS filesystems to use this new API. > Also all existing NLS encodings would be needed to port into this new > API. > > It is really something which have a value? Just because of UTF-8? > > For me it looks like better option would be to remove UTF-8 NLS encoding > as it is broken. Some filesystems already do not use NLS API for their > UTF-8 support (e.g. vfat, udf or newly prepared exfat). And others could > be modified/extended/fixed in similar way. You didn't mention ext4 and f2fs, which is using the Unicode code in fs/unicode for its case-folding and normalization support. Ext4 and f2fs only supports utf-8, so using the NLS API would have added no value --- and it as you pointed out, the NLS API doesn't support variable length encoding anyway. In contrast the fs/unicode functions have support for full Unicode case folding and normalization, and currently has the latest Unicode 12.1 tables (released May 2019). What I'd suggest is to create a new API, enhancing the functions in fs/unicode, to support those file systems that need to deal with UTF-16 and UTF-32 for their on-disk directory format, and that we assume that for the most part, userspace *will* be using a UTF-8 encoding for the user<->kernel interface. We can keep the existing NLS interface and mount options for legacy support, but in my opinion it's not worth the effort to try to do anything else. - Ted