Received: by 2002:a25:ad19:0:0:0:0:0 with SMTP id y25csp1750269ybi; Sat, 27 Jul 2019 17:49:14 -0700 (PDT) X-Google-Smtp-Source: APXvYqxQQ2SOqzqIosHxuqkE2anb9tQDThfKP4weiaFQb24ExL2iLpUMIREFg0p3j/qD7HfLzVI3 X-Received: by 2002:aa7:858b:: with SMTP id w11mr28277556pfn.68.1564274954434; Sat, 27 Jul 2019 17:49:14 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1564274954; cv=none; d=google.com; s=arc-20160816; b=BZXW8DoOIO0SFOs7Cst0yk0n0KZnLKrO54WJ9MHUaUQTGML/tWM8nDD729ffHXclG5 iq2DpnSU/hWnmOLsSuvfj/rIKdPPiJOYbKxdxiGwINZH1b392eqCrdcu830IRvVE00Yj 43L12+0l/AyXjMkP5VwxUaXru+5BYG/zoS+9jHO0e4BTQiaomDZ7ZLQy1BfcuThMBC81 CwoEpi19O78F6svz4Wv3fRHH1XpQcKECN/eG00BPR9Nck5BEp6zmICDty9Y2qwz4gEAD aFRBkWWUApH36TSMUHd5oaNSaM5YGfBYmRK7lRCeBfdOqz7ObPy7H6RDgWSWXI5NcW0e xXVw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject:dkim-signature; bh=vHLe6Yifu5e92NfKH7mCrPjQ6Zxz64kTfMH6b8mvEqs=; b=B7Nq4sGZ5egUyoBTjZWIrhdtikP98enEZGwjwoiusJx4ge6mSu1LcFU66E1wPYNSBn CqerQTrLDmMqvdoaaC9nqnNccfNDuby0ODJ7WBTHJOucApyhAu35gQT/vOHU/oR8Y9nS Vt1nVJ/KozIxRv3fvusdPNEgzZeBJSVppiN1/yiGaUEETTgch5KcmxGzr47m3JAkNwf1 290sApepc4+W8HDi2CGnW+lwE6ahU3EI6TKvX7ZZftovawZRTjAdYqQci/LC3BHtAwpq QZMdeY6FrN++uj5jmMgP/JohPtGgtmGAPZ3b2fHaEEHoy7k6+uXI+5Ei4PcOvZAF/6f9 LDsg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=0fpJx0lh; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id v15si22657521pfm.238.2019.07.27.17.48.56; Sat, 27 Jul 2019 17:49:14 -0700 (PDT) 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; dkim=pass header.i=@kernel.org header.s=default header.b=0fpJx0lh; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729021AbfG1AqF (ORCPT + 99 others); Sat, 27 Jul 2019 20:46:05 -0400 Received: from mail.kernel.org ([198.145.29.99]:56110 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726044AbfG1AqF (ORCPT ); Sat, 27 Jul 2019 20:46:05 -0400 Received: from [192.168.0.101] (unknown [180.111.32.87]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 3B06A2086D; Sun, 28 Jul 2019 00:46:02 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1564274764; bh=hsA8mSmdQowOsHRk9e/OVmaiCpd4e8KUxVDsMnzqcmM=; h=Subject:To:Cc:References:From:Date:In-Reply-To:From; b=0fpJx0lhiOeLOAsoah0WBkaoCDA5/zd4qGBunNewqDCve1P+H+ZTiVjUYEvSWi7cH yqgyGp7/yrBQRuCVvN4YaEo5hPe1u371k1oVeh2rjQ3GDT0ha6jB6hQiRNQGPU8uIM D8oZofcCILnWY2Zn/Wcu55XjaUbnLnVPK8JyMp8w= Subject: Re: [f2fs-dev] [PATCH v4 2/3] f2fs: include charset encoding information in the superblock To: Daniel Rosenberg , Jaegeuk Kim , Chao Yu , Jonathan Corbet , linux-f2fs-devel@lists.sourceforge.net Cc: linux-doc@vger.kernel.org, linux-api@vger.kernel.org, linux-kernel@vger.kernel.org, linux-fsdevel@vger.kernel.org, kernel-team@android.com References: <20190723230529.251659-1-drosen@google.com> <20190723230529.251659-3-drosen@google.com> From: Chao Yu Message-ID: Date: Sun, 28 Jul 2019 08:45:51 +0800 User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:52.0) Gecko/20100101 Thunderbird/52.9.1 MIME-Version: 1.0 In-Reply-To: <20190723230529.251659-3-drosen@google.com> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 2019-7-24 7:05, Daniel Rosenberg via Linux-f2fs-devel wrote: > Add charset encoding to f2fs to support casefolding. It is modeled after > the same feature introduced in commit c83ad55eaa91 ("ext4: include charset > encoding information in the superblock") > > Currently this is not compatible with encryption, similar to the current > ext4 imlpementation. This will change in the future. > > From the ext4 patch: > """ > The s_encoding field stores a magic number indicating the encoding > format and version used globally by file and directory names in the > filesystem. The s_encoding_flags defines policies for using the charset > encoding, like how to handle invalid sequences. The magic number is > mapped to the exact charset table, but the mapping is specific to ext4. > Since we don't have any commitment to support old encodings, the only > encoding I am supporting right now is utf8-12.1.0. > > The current implementation prevents the user from enabling encoding and > per-directory encryption on the same filesystem at the same time. The > incompatibility between these features lies in how we do efficient > directory searches when we cannot be sure the encryption of the user > provided fname will match the actual hash stored in the disk without > decrypting every directory entry, because of normalization cases. My > quickest solution is to simply block the concurrent use of these > features for now, and enable it later, once we have a better solution. > """ > > Signed-off-by: Daniel Rosenberg Reviewed-by: Chao Yu Thanks,