Received: by 2002:a05:6902:102b:0:0:0:0 with SMTP id x11csp965725ybt; Tue, 7 Jul 2020 04:46:06 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwVN021VLgdaTHXIQvnMyKJAKz9/2t6FLLZQmgkqtj4ZFCKj4XTv6tG0CvedBes6pylBcLD X-Received: by 2002:a17:907:10d4:: with SMTP id rv20mr32877957ejb.413.1594122365974; Tue, 07 Jul 2020 04:46:05 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1594122365; cv=none; d=google.com; s=arc-20160816; b=hjzwuMMNBxIxzewi9vsqmOfIa1HWFdYjam10qogH2fjLaHxCgxPB41t+fLbbgI8uMR uSTV0B9Yqa5z/CZprFoR8YvPBIxKkfKRRqWaqxg3Cz7xW/gxDmo6zJTR5gO/F1M4Nq2/ H/KZUFK9CPCWiIrRRi2cSWZ0Cv0iX+C/W7Ck648iWAKJEt7p1lmcJ25hvr6zCzumckGX e//KI8m8LVpFnYbzilU6CWZdKncSIYDw5jAWr8Fy48nY5NSWPkYnz8TR1zg+MIjRppeM fGjjhzSPTV7N605xZGnez3vfI1VBSOvXDiWRLRWGerXaZuqISgDlK6J5zczd2OdNBuwY +KLA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:from:subject:mime-version :message-id:date:dkim-signature; bh=LLQSBg64iwWxTtcpWWM6iR9wTgF8QbEH02Vy+2bg9Hg=; b=pPIn1My8ObnbTU49VTKK50FcochH1cKqPi/taHB9ZriZh6ylUh59BE/yQAAgQ4e5Xa 7ET2ccycbEIFTwtK8Y+P+GawfsFoU8p+4TBr1L36NEPywYlTZh5zoFFGjHswb2Zrw4jk 2ed4MUhexapc+k7GqFFV7x8T8szXCr6lx8gRK6CbCUk2MAPK/e40n8gNRgdokL5WUIB9 FXi+zRkXDoSCK5KSPmsdYiXvIZafzDGoVLOFpnj/9V6z1zWghJhmu7tayEndj1Ka2rBK WQg0KPQM23uII9KqsNFr5Aq0RA0fRhaYvUuAKdRWa1kY5u8TPoTXxtEbS0w2QpL1LTaY RZ6w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@google.com header.s=20161025 header.b=vaUinhNZ; spf=pass (google.com: domain of linux-ext4-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-ext4-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id of23si9502273ejb.414.2020.07.07.04.45.36; Tue, 07 Jul 2020 04:46:05 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-ext4-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@google.com header.s=20161025 header.b=vaUinhNZ; spf=pass (google.com: domain of linux-ext4-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-ext4-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728391AbgGGLpN (ORCPT + 99 others); Tue, 7 Jul 2020 07:45:13 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:55046 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726805AbgGGLpM (ORCPT ); Tue, 7 Jul 2020 07:45:12 -0400 Received: from mail-yb1-xb4a.google.com (mail-yb1-xb4a.google.com [IPv6:2607:f8b0:4864:20::b4a]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 18F1EC061755 for ; Tue, 7 Jul 2020 04:45:12 -0700 (PDT) Received: by mail-yb1-xb4a.google.com with SMTP id s7so46614108ybg.10 for ; Tue, 07 Jul 2020 04:45:12 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20161025; h=date:message-id:mime-version:subject:from:to:cc; bh=LLQSBg64iwWxTtcpWWM6iR9wTgF8QbEH02Vy+2bg9Hg=; b=vaUinhNZkQN3RAVXNuIvu2m9UALKLZu6+nRg7EiTfijttvY5uvU/HlfVTs6MFI3BjD Er2jhbF7pByOmGUAkA0Rwjx6r1yRJYYD9O+cl25wvja83NKdtmmp1zngnkV02lhR5H60 b5PjacpY1TP2NcUr9fiYcugKPCAjjR9rmlEhUHB0wiSX4QdOcSpvSGrvsQV0rT/nifCK 2ZKi0Cmb2t3TuutVgBjI50QCH9omrBcU2W/h5TS/pS3DnoIpdnsJzSM7wmedPsCcY2wS ytB1vf691KXilc3nIafaO0kmcuwa8X3LA+tSoYg6SrxvtuS6RBnGMpkCLIhuojqhRuKM 4b2g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:message-id:mime-version:subject:from:to:cc; bh=LLQSBg64iwWxTtcpWWM6iR9wTgF8QbEH02Vy+2bg9Hg=; b=Cen6p8wuik07Fn5gaVi+p0vhHDsawwG/xbFlmrxUTnUY2SODqEw3GMGrux8MFU7hvF Gz665sdvlU4w9fnst0FGWZpX0iRyWPb5ufQsthiTNA8jJAnd4PiQTmZejNeIB2XfatRQ 7HuMLWkeQEUIHR0cbU7TBMSJqpTk42/Wfo2j2irGYUXfcPdPGG+sJthg7Z4/7TB4pXw2 vbiVv3YwhAqfmEIXoR5mFmHcVT3YDF1SzjON0vxa/yKubMcHLJQQUEcEzp8XpUL8weFF 7sLucTVCaUnYlnCqot2CCQqDN0YX1fXSWq4k+df1kRSumd2h5sW5q39xK2QU5o5VWHKV X85w== X-Gm-Message-State: AOAM533t+FkBj2k1i9G7xSxPiQ795QlAWMfhvucqJIyFhx2VXFCD3A/4 l2NIVxgAJC3hSUAV4o+DxUXwv4qr03Q= X-Received: by 2002:a25:b903:: with SMTP id x3mr32504935ybj.445.1594122311275; Tue, 07 Jul 2020 04:45:11 -0700 (PDT) Date: Tue, 7 Jul 2020 04:31:19 -0700 Message-Id: <20200707113123.3429337-1-drosen@google.com> Mime-Version: 1.0 X-Mailer: git-send-email 2.27.0.212.ge8ba1cc988-goog Subject: [PATCH v10 0/4] Prepare for upcoming Casefolding/Encryption patches From: Daniel Rosenberg To: "Theodore Ts'o" , linux-ext4@vger.kernel.org, Jaegeuk Kim , Chao Yu , linux-f2fs-devel@lists.sourceforge.net, Eric Biggers , linux-fscrypt@vger.kernel.org, Alexander Viro Cc: Andreas Dilger , linux-kernel@vger.kernel.org, linux-fsdevel@vger.kernel.org, Gabriel Krisman Bertazi , kernel-team@android.com, Daniel Rosenberg Content-Type: text/plain; charset="UTF-8" Sender: linux-ext4-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-ext4@vger.kernel.org This lays the ground work for enabling casefolding and encryption at the same time for ext4 and f2fs. A future set of patches will enable that functionality. These unify the highly similar dentry_operations that ext4 and f2fs both use for casefolding. In addition, they improve d_hash by not requiring a new string allocation, and ensure we don't attempt to casefold the no-key token of an encrypted filename. Daniel Rosenberg (4): unicode: Add utf8_casefold_hash fs: Add standard casefolding support f2fs: Use generic casefolding support ext4: Use generic casefolding support fs/ext4/dir.c | 64 +-------------------------- fs/ext4/ext4.h | 12 ------ fs/ext4/hash.c | 2 +- fs/ext4/namei.c | 20 ++++----- fs/ext4/super.c | 12 +++--- fs/f2fs/dir.c | 83 ++++------------------------------- fs/f2fs/f2fs.h | 4 -- fs/f2fs/super.c | 10 ++--- fs/f2fs/sysfs.c | 10 +++-- fs/libfs.c | 96 +++++++++++++++++++++++++++++++++++++++++ fs/unicode/utf8-core.c | 23 +++++++++- include/linux/f2fs_fs.h | 3 -- include/linux/fs.h | 16 +++++++ include/linux/unicode.h | 3 ++ 14 files changed, 174 insertions(+), 184 deletions(-) -- 2.27.0.212.ge8ba1cc988-goog