Received: by 2002:a05:6a10:17d3:0:0:0:0 with SMTP id hz19csp2094181pxb; Sun, 18 Apr 2021 18:41:55 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyrsIQPDRuertKZOsqXdlGY5ZSVkNtNe7oOoE23GZFf3TgnQtGJ05vjzaehjugfI8MRYI4x X-Received: by 2002:a17:902:8d84:b029:eb:37bd:a3f7 with SMTP id v4-20020a1709028d84b02900eb37bda3f7mr20584005plo.26.1618796515151; Sun, 18 Apr 2021 18:41:55 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1618796515; cv=none; d=google.com; s=arc-20160816; b=tIaBofV1xu2ut05Y9EDIey7JWxfc37quqHSN4kIKdFxd8Mm72ugLMKokZEbsgvHnYR dCT/YV41S9M9n1L2fagAUWSG9OIB9XxCcI+t3YmjgwBc7J0lYYiISv7q2mFpPFvzUgD4 ZEwOIE8wfQnBUdEYS7ohUxx/uy3ComyeAM9/V4iSBwNnoembCie46caA71sXFhzHOWiF pTg/DcQLHs76UYbtT6IqH2WY/ou7FtFY+WLfrNmd5cUpx/SFQkpC2HHsM3Ql8eWwWv7F hfrsVAz7T2bdvPAz0kcCT6GW3ytyCFQIfgae1vT4I8nxbXXG6g1LhXwuzhwmO+vW/7tO nkuA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:message-id:references:in-reply-to :subject:cc:date:to:from; bh=vJlWnpMYsoPhiCE6KJZ7+GINtSVGpCnQDBx/gg30RcI=; b=xqsWARGliK5tC4KdYJsCgFfr3CIRHIEFlktg8blCreO5K5TeDp4e81i9qb/kL25uAj ioBXhOW9tQkSu9i8BQ2zOLWR07R87dBf1461CUcrLGlZiBX7ulJnoA3mo9xDbf14fX6H gmr+5sqHvOeEACw7MnlEUTKJ+N+ySfjYHUWnY3np++x2p6zWhuim1f1FtkQ+n++shvYK Qzan7DOSfs9jia9Bux0MUrnrBa6adVz7Y9cspF5Qb2qogVWcui0+g977pon/IE0U5lBl 9/T0RtBKm2o11c4XvWIN3a0k566dwP0gEo23bm8BHqjfdZMQLL2nRdbfglyxcmwz9hL9 2kJg== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id y10si15026533pjy.122.2021.04.18.18.41.43; Sun, 18 Apr 2021 18:41:55 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233106AbhDSBli (ORCPT + 99 others); Sun, 18 Apr 2021 21:41:38 -0400 Received: from mx2.suse.de ([195.135.220.15]:56946 "EHLO mx2.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232013AbhDSBlg (ORCPT ); Sun, 18 Apr 2021 21:41:36 -0400 X-Virus-Scanned: by amavisd-new at test-mx.suse.de Received: from relay2.suse.de (unknown [195.135.221.27]) by mx2.suse.de (Postfix) with ESMTP id 812E8AC87; Mon, 19 Apr 2021 01:41:06 +0000 (UTC) From: NeilBrown To: Fox Chen Date: Mon, 19 Apr 2021 11:41:00 +1000 Cc: Fox Chen , corbet@lwn.net, vegard.nossum@oracle.com, viro@zeniv.linux.org.uk, rdunlap@infradead.org, grandmaster@al2klimov.de, linux-doc@vger.kernel.org, linux-kernel@vger.kernel.org, gregkh@linuxfoundation.org Subject: Re: [PATCH v2 09/12] docs: path-lookup: no get_link() In-Reply-To: <20210316054727.25655-10-foxhlchen@gmail.com> References: <20210316054727.25655-1-foxhlchen@gmail.com> <20210316054727.25655-10-foxhlchen@gmail.com> Message-ID: <87v98j126r.fsf@notabene.neil.brown.name> MIME-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha256; protocol="application/pgp-signature" Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org --=-=-= Content-Type: text/plain Content-Transfer-Encoding: quoted-printable On Tue, Mar 16 2021, Fox Chen wrote: > no get_link() anymore. we have step_into() and pick_link(). > > walk_component() will call step_into(), in turn call pick_link, > and return symlink name. > > Signed-off-by: Fox Chen > --- > Documentation/filesystems/path-lookup.rst | 10 ++++------ > 1 file changed, 4 insertions(+), 6 deletions(-) > > diff --git a/Documentation/filesystems/path-lookup.rst b/Documentation/fi= lesystems/path-lookup.rst > index 8ab95dd9046e..0d41c61f7e4f 100644 > --- a/Documentation/filesystems/path-lookup.rst > +++ b/Documentation/filesystems/path-lookup.rst > @@ -1103,12 +1103,10 @@ doesn't need to notice. Getting this ``name`` va= riable on and off the > stack is very straightforward; pushing and popping the references is > a little more complex. >=20=20 > -When a symlink is found, ``walk_component()`` returns the value ``1`` > -(``0`` is returned for any other sort of success, and a negative number > -is, as usual, an error indicator). This causes ``get_link()`` to be > -called; it then gets the link from the filesystem. Providing that > -operation is successful, the old path ``name`` is placed on the stack, > -and the new value is used as the ``name`` for a while. When the end of > +When a symlink is found, ``walk_component()`` calls ``pick_link()``, walk_component() calls pick_link() via step_into() ?? > +it then gets the link from the filesystem returning new path ``name``. "which returns the link from the filesystem." With those changes (assuming you agree with them) Reviewed-by: NeilBrown Thanks, NeilBrown > +Providing that operation is successful, the old path ``name`` is placed = on the > +stack, and the new value is used as the ``name`` for a while. When the = end of > the path is found (i.e. ``*name`` is ``'\0'``) the old ``name`` is resto= red > off the stack and path walking continues. >=20=20 > --=20 > 2.30.2 --=-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQJCBAEBCAAsFiEEG8Yp69OQ2HB7X0l6Oeye3VZigbkFAmB836wOHG5laWxiQHN1 c2UuZGUACgkQOeye3VZigbkhlQ/+KEDT1Qg5sJP/HbvSh+uqKcRG74YFfZp64srx RGr3aAOIGIxL860sROvxmUl7QvYjNVnYBN6w4tEGIU4WEr7rpRAHGup3OQ11sH6D 8PolYl8ZtdrOFz9x1KDH09xFHdBYlufOgWY8/7Mh+0v/Kw+yKDmwavXGxyUkmOmD nEQBAdfyYHeqKcm6eG0A2J2T+NYoSwcONBXycWk2+1qDSlr1A3iC+fTYPpH/lpWZ 9zb/d5kMvBFozSXSsCnUEgNX3rxpEiISaLgpDv41e4/k/pk08weFR54i/F7aE6JJ JsAiLTjFPcsw9v2Zov0YUJIsH8yJAatZXvM5mxXI0gKas/FIIRyrxqYmBjdpzGKI 8XadNQfeHwh+GmMqCuyRphd6hDsbYHgZbb+rEtIAslvn4cXGFHzOQt6tuosl52Nz UhVe64R1TQFU+nkqLK45W0eNTGn3Bd/SVHN4srmzOxb/RxAjM8UR78WFglI2AsbX YpkpRA+1V5yXVEHA7VOYXTz6rZgYhIVyO57mWoSCFIk8Oq9KGgOjUT+cNBr1Ncwa d4xSx9Rg223PEz3Jrz4pYGLa+0LQfkd6Xm/2TWgSH9bdJKLzHfk8GPHCg35L1Wg9 2fMD1zRGRv+W0y+lv/sA8VHIufPne3mw7NV6b9VN9rtijt1sHizvZKY2YT5qZso0 MRWiNRo= =qvPS -----END PGP SIGNATURE----- --=-=-=--