From: Quentin Monnet <quentin@isovalent.com>
To: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Cc: Linux Doc Mailing List <linux-doc@vger.kernel.org>,
Jonathan Corbet <corbet@lwn.net>,
"David S. Miller" <davem@davemloft.net>,
Alexei Starovoitov <ast@kernel.org>,
Andrii Nakryiko <andrii@kernel.org>,
Daniel Borkmann <daniel@iogearbox.net>,
David Beckett <david.beckett@netronome.com>,
Jakub Kicinski <kuba@kernel.org>,
John Fastabend <john.fastabend@gmail.com>,
KP Singh <kpsingh@kernel.org>, Martin KaFai Lau <kafai@fb.com>,
Shuah Khan <shuah@kernel.org>, Song Liu <songliubraving@fb.com>,
Yonghong Song <yhs@fb.com>,
bpf@vger.kernel.org, linux-kernel@vger.kernel.org,
linux-kselftest@vger.kernel.org, netdev@vger.kernel.org
Subject: Re: [PATCH 08/24] tools: bpftool: update bpftool-prog.rst reference
Date: Thu, 16 Sep 2021 11:57:51 +0100 [thread overview]
Message-ID: <33d66a49-2fc0-57a1-c1e5-34e932bcc237@isovalent.com> (raw)
In-Reply-To: <20210916124930.7ae3b722@coco.lan>
2021-09-16 12:49 UTC+0200 ~ Mauro Carvalho Chehab
<mchehab+huawei@kernel.org>
> Hi Quentin,
>
> Em Thu, 16 Sep 2021 10:43:45 +0100
> Quentin Monnet <quentin@isovalent.com> escreveu:
>
>> 2021-09-16 11:14 UTC+0200 ~ Mauro Carvalho Chehab
>> <mchehab+huawei@kernel.org>
>>> The file name: Documentation/bpftool-prog.rst
>>> should be, instead: tools/bpf/bpftool/Documentation/bpftool-prog.rst.
>>>
>>> Update its cross-reference accordingly.
>>>
>>> Fixes: a2b5944fb4e0 ("selftests/bpf: Check consistency between bpftool source, doc, completion")
>>> Fixes: ff69c21a85a4 ("tools: bpftool: add documentation")
>>
>> Hi,
>> How is this a fix for the commit that added the documentation in bpftool?
>>
>>> Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
>>> ---
>>> tools/testing/selftests/bpf/test_bpftool_synctypes.py | 2 +-
>>> 1 file changed, 1 insertion(+), 1 deletion(-)
>>>
>>> diff --git a/tools/testing/selftests/bpf/test_bpftool_synctypes.py b/tools/testing/selftests/bpf/test_bpftool_synctypes.py
>>> index be54b7335a76..27a2c369a798 100755
>>> --- a/tools/testing/selftests/bpf/test_bpftool_synctypes.py
>>> +++ b/tools/testing/selftests/bpf/test_bpftool_synctypes.py
>>> @@ -374,7 +374,7 @@ class ManProgExtractor(ManPageExtractor):
>>> """
>>> An extractor for bpftool-prog.rst.
>>> """
>>> - filename = os.path.join(BPFTOOL_DIR, 'Documentation/bpftool-prog.rst')
>>> + filename = os.path.join(BPFTOOL_DIR, 'tools/bpf/bpftool/Documentation/bpftool-prog.rst')
>>>
>>> def get_attach_types(self):
>>> return self.get_rst_list('ATTACH_TYPE')
>>>
>>
>> No I don't believe it should. BPFTOOL_DIR already contains
>> 'tools/bpf/bpftool' and the os.path.join() concatenates the two path
>> fragments.
>>
>> Where is this suggestion coming from? Did you face an issue with the script?
>
> No, I didn't face any issues with this script.
>
> The suggestion cames from the script at:
>
> ./scripts/documentation-file-ref-check
>
> which is meant to discover broken doc references.
>
> Such script has already a rule to handle stuff under tools/:
>
> # Accept relative Documentation patches for tools/
> if ($f =~ m/tools/) {
> my $path = $f;
> $path =~ s,(.*)/.*,$1,;
> next if (grep -e, glob("$path/$ref $path/../$ref $path/$fulref"));
> }
>
> but it seems it needs a fixup in order for it to stop reporting issues
> at test_bpftool_synctypes.py:
>
> $ ./scripts/documentation-file-ref-check
> ...
> tools/testing/selftests/bpf/test_bpftool_synctypes.py: Documentation/bpftool-prog.rst
> tools/testing/selftests/bpf/test_bpftool_synctypes.py: Documentation/bpftool-map.rst
> tools/testing/selftests/bpf/test_bpftool_synctypes.py: Documentation/bpftool-cgroup.rst
Oh, I see, thanks for explaining. I didn't know this script would catch
the paths in bpftool's test file.
>
> I'll drop the patches touching it for a next version, probably
> adding a fix for such script.
>
> Thanks,
> Mauro
>
Sounds good to me, thanks a lot!
Quentin
next prev parent reply other threads:[~2021-09-16 10:58 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-09-16 9:13 [PATCH 00/24] Fix some issues at documentation Mauro Carvalho Chehab
2021-09-16 9:13 ` [PATCH 02/24] dt-bindings: net: dsa: sja1105: update nxp,sja1105.yaml reference Mauro Carvalho Chehab
2021-09-16 9:13 ` [PATCH 06/24] libbpf: update index.rst reference Mauro Carvalho Chehab
2021-09-16 9:14 ` [PATCH 08/24] tools: bpftool: update bpftool-prog.rst reference Mauro Carvalho Chehab
2021-09-16 9:43 ` Quentin Monnet
2021-09-16 10:49 ` Mauro Carvalho Chehab
2021-09-16 10:57 ` Quentin Monnet [this message]
2021-09-16 11:30 ` Mauro Carvalho Chehab
2021-09-16 12:12 ` Quentin Monnet
2021-09-16 9:14 ` [PATCH 09/24] tools: bpftool: update bpftool-map.rst reference Mauro Carvalho Chehab
2021-09-16 9:14 ` [PATCH 10/24] bpftool: update bpftool-cgroup.rst reference Mauro Carvalho Chehab
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=33d66a49-2fc0-57a1-c1e5-34e932bcc237@isovalent.com \
--to=quentin@isovalent.com \
--cc=andrii@kernel.org \
--cc=ast@kernel.org \
--cc=bpf@vger.kernel.org \
--cc=corbet@lwn.net \
--cc=daniel@iogearbox.net \
--cc=davem@davemloft.net \
--cc=david.beckett@netronome.com \
--cc=john.fastabend@gmail.com \
--cc=kafai@fb.com \
--cc=kpsingh@kernel.org \
--cc=kuba@kernel.org \
--cc=linux-doc@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-kselftest@vger.kernel.org \
--cc=mchehab+huawei@kernel.org \
--cc=netdev@vger.kernel.org \
--cc=shuah@kernel.org \
--cc=songliubraving@fb.com \
--cc=yhs@fb.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).