From patchwork Thu Mar 5 05:21:21 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: NeilBrown X-Patchwork-Id: 5943531 Return-Path: X-Original-To: patchwork-linux-fsdevel@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 75E0FBF440 for ; Thu, 5 Mar 2015 05:24:21 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id BC15B202BE for ; Thu, 5 Mar 2015 05:24:20 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id F0DEB202B8 for ; Thu, 5 Mar 2015 05:24:19 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753446AbbCEFXK (ORCPT ); Thu, 5 Mar 2015 00:23:10 -0500 Received: from cantor2.suse.de ([195.135.220.15]:42176 "EHLO mx2.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752696AbbCEFXI (ORCPT ); Thu, 5 Mar 2015 00:23:08 -0500 X-Virus-Scanned: by amavisd-new at test-mx.suse.de Received: from relay1.suse.de (charybdis-ext.suse.de [195.135.220.254]) by mx2.suse.de (Postfix) with ESMTP id E0847AC77; Thu, 5 Mar 2015 05:23:06 +0000 (UTC) From: NeilBrown To: Alexander Viro Date: Thu, 05 Mar 2015 16:21:21 +1100 Subject: [PATCH 6/9] VFS/namei: enable RCU-walk when following symlinks. Cc: linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org Message-ID: <20150305052121.23906.85793.stgit@notabene.brown> In-Reply-To: <20150305051530.23906.65097.stgit@notabene.brown> References: <20150305051530.23906.65097.stgit@notabene.brown> User-Agent: StGit/0.17.1-dirty MIME-Version: 1.0 Sender: linux-fsdevel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-fsdevel@vger.kernel.org X-Spam-Status: No, score=-6.9 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, T_RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Now that follow_link handles LOOKUP_RCU, we do not need to 'unlazy_walk' when a symlink is found. Signed-off-by: NeilBrown --- fs/namei.c | 12 ------------ 1 file changed, 12 deletions(-) -- To unsubscribe from this list: send the line "unsubscribe linux-fsdevel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html diff --git a/fs/namei.c b/fs/namei.c index 4ddbc1ef5726..11e6b2068c96 100644 --- a/fs/namei.c +++ b/fs/namei.c @@ -1608,12 +1608,6 @@ static inline int walk_component(struct nameidata *nd, struct path *path, goto out_path_put; if (should_follow_link(path->dentry, follow)) { - if (nd->flags & LOOKUP_RCU) { - if (unlikely(unlazy_walk(nd, path->dentry))) { - err = -ECHILD; - goto out_err; - } - } BUG_ON(inode != path->dentry->d_inode); return 1; } @@ -3066,12 +3060,6 @@ finish_lookup: } if (should_follow_link(path->dentry, !symlink_ok)) { - if (nd->flags & LOOKUP_RCU) { - if (unlikely(unlazy_walk(nd, path->dentry))) { - error = -ECHILD; - goto out; - } - } BUG_ON(inode != path->dentry->d_inode); return 1; }