Message ID | 20221104123913.50610-1-bagasdotme@gmail.com |
---|---|
State | New |
Headers |
Return-Path: <linux-kernel-owner@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:6687:0:0:0:0:0 with SMTP id l7csp377967wru; Fri, 4 Nov 2022 05:46:55 -0700 (PDT) X-Google-Smtp-Source: AMsMyM7ET8B/6OQDyGDz3pS6xoxXKxo3Fz+WSk6lFwn0FjbGTlKrPZwkijiL7tF6OQCfjfkn35+l X-Received: by 2002:a17:907:3f98:b0:7ad:8bc6:4cee with SMTP id hr24-20020a1709073f9800b007ad8bc64ceemr35040888ejc.328.1667566015040; Fri, 04 Nov 2022 05:46:55 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1667566015; cv=none; d=google.com; s=arc-20160816; b=u3Qq2REQk6ZaCNAfvLPx2VibcDP6spPGJ+GXBCL8W8hXqXKmnHC7oYKcLWpUx44dQh CP1CaYObASEd+IDOHASKoaKHIRX9aB1CUG8QGC7uA/v+NN2Zr5AEVZSa7DsUkdypwQHh y07dko5S5RblI44ga89+46eMkmyySRAqy65F9nlXjGcOCmOPLgZXxCi93i7SxX55Dt/s 2TD6POVfGXKzNTETYV2wk9tJ0dhHiajgv8UKcH1SvOPrsdPAfb5qwxC4BNtSGs427ODi TEYiDb78qcIEzcRtYZGq6e8YDqpWQOBGVzIh9NKiFC85UJOclpm+o9GYpbQeXFF5U960 ba7w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from:dkim-signature; bh=/TTs+SQ3730sftInldiJIc3c0U0T3PiqOZZn4XJKbTc=; b=WVcjcnkxfHc4jemys/O0Yd7VHOwHk0PeHIbmClEjrqCck3XW5Kl+mPv2w1smIYkqVq ctfJpJfYMYIB2usTKXq7cIcpWW6VvOqFt5OkS1yb3LclOllnhejqdOgjzu/2tsZw7hWk N+bOeisT/O6a2HBYP1mZtlYyKKBQOLVNAzcfak7RnSjlq6VgSX7Oo6AgRpSMsG1urBgP TMwg2IVvW9UYT43bqJXX0l5aSKIZ4H4ed8a6C0dBnINCM6kL1mHEtMpxMA09KSqV0aGc 808jTK9jJ1omC6gpDHNjbC2WBdeBRmMEP8FnluGpPowcOjW1OFM79hEu5v3m4m12l5ZV dL7w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=pMDidnAt; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id hb13-20020a170907160d00b00782f3e3bb71si5510620ejc.912.2022.11.04.05.46.31; Fri, 04 Nov 2022 05:46:55 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=pMDidnAt; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231728AbiKDMkI (ORCPT <rfc822;jimliu8233@gmail.com> + 99 others); Fri, 4 Nov 2022 08:40:08 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:56400 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231848AbiKDMjr (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Fri, 4 Nov 2022 08:39:47 -0400 Received: from mail-pf1-x429.google.com (mail-pf1-x429.google.com [IPv6:2607:f8b0:4864:20::429]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 8ADB5A1BC; Fri, 4 Nov 2022 05:39:45 -0700 (PDT) Received: by mail-pf1-x429.google.com with SMTP id k15so4430405pfg.2; Fri, 04 Nov 2022 05:39:45 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=/TTs+SQ3730sftInldiJIc3c0U0T3PiqOZZn4XJKbTc=; b=pMDidnAt8xhkHG6jwMe8yC27eQxhm11xGQeS5bipl/LYmQFfMD+TYXs8rsleS076oe 7iQ5oQPvzqllPSIJuoe4ZYRLrh/49FetUiUqmkfvintVSYAjiy7pNahD93uTHmVxyULz SKXj4p0LtikpNZiGqcpoNCVYxLYMibaO56eiyv+Z0y2TxnXg6Rk5NeQ5TfuTfThjgAtq TjDaK83G/YQYhadkwjg/uxo5FvEWC4/iqPd940lUMIxX+VWGciiXTMKiuPQrFtgfxqxP dEoFTx6APSO5cnuXrQO/rfsTHHns3a9rDb+x3EfBSyU9cYdkLvrgh4LDxf3Y8JemacKE fbJQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=/TTs+SQ3730sftInldiJIc3c0U0T3PiqOZZn4XJKbTc=; b=y6SGJNsqQdEYN2JZFdq3WZm6WUP8k0q/j33uTb8Srz8j3lohjRyo34XNRok+9/bf34 gWJh0RB1NJT91EZfL7vpcpNED8IhXL6hYi9R8g/lR4rft1xtVKEbZliohpcWEAkU79Pu J2PmJ0AHQzrtD1FIgw8FUMgZjdyHp7RGBmZUpFvzbJWXvmFhAEdk/6jJB947jCCKKmRt +Wfr5GHXUns0oI2Lh08uZEFhxJO1XOEqsbXpSMveVlL9sVpmAfxKyReufCMSjyw+Vk9t mgKTWCf1konN/4vL9EvP2wadOi6Vvx5XN2r+K6PiY85OGlDKRNm8JicZhlcE7nbxGkOa Uy1g== X-Gm-Message-State: ACrzQf3UJd8KBeBvePdOFhU8WQmWJFRBEeGpcQ4RbK3iNznpuWpu13CU PP8HwHhG4CrjX0bLQrhQIrvKBsJLr+MRjmbJ X-Received: by 2002:a65:49c9:0:b0:462:9ce1:3f58 with SMTP id t9-20020a6549c9000000b004629ce13f58mr30209189pgs.200.1667565584901; Fri, 04 Nov 2022 05:39:44 -0700 (PDT) Received: from debian.. (subs02-180-214-232-17.three.co.id. [180.214.232.17]) by smtp.gmail.com with ESMTPSA id w14-20020a627b0e000000b0056bd4ec964csm2603180pfc.194.2022.11.04.05.39.39 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 04 Nov 2022 05:39:44 -0700 (PDT) From: Bagas Sanjaya <bagasdotme@gmail.com> To: bpf@vger.kernel.org, linux-doc@vger.kernel.org, linux-kernel@vger.kernel.org Cc: Alexei Starovoitov <ast@kernel.org>, Daniel Borkmann <daniel@iogearbox.net>, Andrii Nakryiko <andrii@kernel.org>, Martin KaFai Lau <martin.lau@linux.dev>, Song Liu <song@kernel.org>, Yonghong Song <yhs@fb.com>, John Fastabend <john.fastabend@gmail.com>, KP Singh <kpsingh@kernel.org>, Stanislav Fomichev <sdf@google.com>, Hao Luo <haoluo@google.com>, Jiri Olsa <jolsa@kernel.org>, Jonathan Corbet <corbet@lwn.net>, David Vernet <void@manifault.com>, Kumar Kartikeya Dwivedi <memxor@gmail.com>, Bagas Sanjaya <bagasdotme@gmail.com> Subject: [PATCH bpf-next] Documentation: bpf: escape underscore in BPF type name prefix Date: Fri, 4 Nov 2022 19:39:14 +0700 Message-Id: <20221104123913.50610-1-bagasdotme@gmail.com> X-Mailer: git-send-email 2.38.1 MIME-Version: 1.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=1956; i=bagasdotme@gmail.com; h=from:subject; bh=RWnD3wD39wBwhPhnOTT0S+Ljuw5X7oF+YsnsA+fSFlU=; b=owGbwMvMwCH2bWenZ2ig32LG02pJDMmp7K+XeAbM1mn5tLAjt+Wgmqn3Uzf910snXncP/+4utdLm oc20jlIWBjEOBlkxRZZJiXxNp3cZiVxoX+sIM4eVCWQIAxenAEzkTgEjw8vIv5uPXWubEHi81+DiPf f7+meXm8xdu85hxfWoTwvNvt1iZJjZynj/zzv3/WUp5cFV726nhd6/y1xwqeTA9Rs3l3gv38oLAA== X-Developer-Key: i=bagasdotme@gmail.com; a=openpgp; fpr=701B806FDCA5D3A58FFB8F7D7C276C64A5E44A1D Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-0.6 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM, RCVD_IN_DNSWL_NONE,RCVD_IN_SORBS_WEB,SPF_HELO_NONE,SPF_PASS autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: <linux-kernel.vger.kernel.org> X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1748569702025712893?= X-GMAIL-MSGID: =?utf-8?q?1748569702025712893?= |
Series |
[bpf-next] Documentation: bpf: escape underscore in BPF type name prefix
|
|
Commit Message
Bagas Sanjaya
Nov. 4, 2022, 12:39 p.m. UTC
Sphinx reported unknown target warning:
Documentation/bpf/bpf_design_QA.rst:329: WARNING: Unknown target name: "bpf".
The warning is caused by BPF type name prefix ("bpf_") which is written
without escaping the trailing underscore.
Escape the underscore to fix the warning. While at it, wrap the
containing paragraph in less than 80 characters.
Fixes: 9805af8d8a5b17 ("bpf: Document UAPI details for special BPF types")
Signed-off-by: Bagas Sanjaya <bagasdotme@gmail.com>
---
Documentation/bpf/bpf_design_QA.rst | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
base-commit: f71b2f64177a199d5b1d2047e155d45fd98f564a
Comments
On Fri, Nov 4, 2022 at 1:39 PM Bagas Sanjaya <bagasdotme@gmail.com> wrote: > > Sphinx reported unknown target warning: > > Documentation/bpf/bpf_design_QA.rst:329: WARNING: Unknown target name: "bpf". > > The warning is caused by BPF type name prefix ("bpf_") which is written > without escaping the trailing underscore. > > Escape the underscore to fix the warning. While at it, wrap the > containing paragraph in less than 80 characters. > > Fixes: 9805af8d8a5b17 ("bpf: Document UAPI details for special BPF types") > Signed-off-by: Bagas Sanjaya <bagasdotme@gmail.com> Acked-by: KP Singh <kpsingh@kernel.org>
On Fri, Nov 04, 2022 at 07:39:14PM +0700, Bagas Sanjaya wrote: > Sphinx reported unknown target warning: > > Documentation/bpf/bpf_design_QA.rst:329: WARNING: Unknown target name: "bpf". > > The warning is caused by BPF type name prefix ("bpf_") which is written > without escaping the trailing underscore. > > Escape the underscore to fix the warning. While at it, wrap the > containing paragraph in less than 80 characters. > > Fixes: 9805af8d8a5b17 ("bpf: Document UAPI details for special BPF types") > Signed-off-by: Bagas Sanjaya <bagasdotme@gmail.com> Acked-by: David Vernet <void@manifault.com>
On Fri, Nov 4, 2022 at 5:39 AM Bagas Sanjaya <bagasdotme@gmail.com> wrote: > > Sphinx reported unknown target warning: > > Documentation/bpf/bpf_design_QA.rst:329: WARNING: Unknown target name: "bpf". > > The warning is caused by BPF type name prefix ("bpf_") which is written > without escaping the trailing underscore. > > Escape the underscore to fix the warning. While at it, wrap the > containing paragraph in less than 80 characters. > > Fixes: 9805af8d8a5b17 ("bpf: Document UAPI details for special BPF types") > Signed-off-by: Bagas Sanjaya <bagasdotme@gmail.com> > --- > Documentation/bpf/bpf_design_QA.rst | 8 ++++---- > 1 file changed, 4 insertions(+), 4 deletions(-) > Applied, thanks. But would the other similar case be problematic? $ rg 'bpf_\b' bpf_design_QA.rst 329:NOTE: BPF subsystem specially reserves the 'bpf_' prefix for type names, in 331:avoid defining types with 'bpf_' prefix to not be broken in future releases. In 333:with 'bpf_' prefix. libbpf/libbpf_naming_convention.rst 12:following prefixes: ``bpf_``, ``btf_``, ``libbpf_``, ``btf_dump_``, 59:described above should have ``libbpf_`` prefix, e.g. > diff --git a/Documentation/bpf/bpf_design_QA.rst b/Documentation/bpf/bpf_design_QA.rst > index 4e4af398607b58..17e774d96c5e4b 100644 > --- a/Documentation/bpf/bpf_design_QA.rst > +++ b/Documentation/bpf/bpf_design_QA.rst > @@ -326,11 +326,11 @@ size, type, and alignment, or any other user visible API or ABI detail across > kernel releases. The users must adapt their BPF programs to the new changes and > update them to make sure their programs continue to work correctly. > > -NOTE: BPF subsystem specially reserves the 'bpf_' prefix for type names, in > +NOTE: BPF subsystem specially reserves the 'bpf\_' prefix for type names, in > order to introduce more special fields in the future. Hence, user programs must > -avoid defining types with 'bpf_' prefix to not be broken in future releases. In > -other words, no backwards compatibility is guaranteed if one using a type in BTF > -with 'bpf_' prefix. > +avoid defining types with 'bpf\_' prefix to not be broken in future releases. > +In other words, no backwards compatibility is guaranteed if one using a type > +in BTF with 'bpf\_' prefix. > > Q: What is the compatibility story for special BPF types in local kptrs? > ------------------------------------------------------------------------ > > base-commit: f71b2f64177a199d5b1d2047e155d45fd98f564a > -- > An old man doll... just what I always wanted! - Clara >
Hello: This patch was applied to bpf/bpf-next.git (master) by Andrii Nakryiko <andrii@kernel.org>: On Fri, 4 Nov 2022 19:39:14 +0700 you wrote: > Sphinx reported unknown target warning: > > Documentation/bpf/bpf_design_QA.rst:329: WARNING: Unknown target name: "bpf". > > The warning is caused by BPF type name prefix ("bpf_") which is written > without escaping the trailing underscore. > > [...] Here is the summary with links: - [bpf-next] Documentation: bpf: escape underscore in BPF type name prefix https://git.kernel.org/bpf/bpf-next/c/25906092edb4 You are awesome, thank you!
Hi, On Fri, 4 Nov 2022 16:11:10 -0700, Andrii Nakryiko wrote: [...] > Applied, thanks. But would the other similar case be problematic? > > $ rg 'bpf_\b' > bpf_design_QA.rst > 329:NOTE: BPF subsystem specially reserves the 'bpf_' prefix for type names, in > 331:avoid defining types with 'bpf_' prefix to not be broken in future > releases. In > 333:with 'bpf_' prefix. > > libbpf/libbpf_naming_convention.rst > 12:following prefixes: ``bpf_``, ``btf_``, ``libbpf_``, ``btf_dump_``, > 59:described above should have ``libbpf_`` prefix, e.g. Those other cases are all inside double back quotes and construct "inline literal" strings. So they are fine. Which means Bagas could have used the "inline literal" approach instead. Regards, Akira
On 11/5/22 07:05, Akira Yokosawa wrote: > Hi, > > On Fri, 4 Nov 2022 16:11:10 -0700, Andrii Nakryiko wrote: > [...] >> Applied, thanks. But would the other similar case be problematic? >> >> $ rg 'bpf_\b' >> bpf_design_QA.rst >> 329:NOTE: BPF subsystem specially reserves the 'bpf_' prefix for type names, in >> 331:avoid defining types with 'bpf_' prefix to not be broken in future >> releases. In >> 333:with 'bpf_' prefix. >> >> libbpf/libbpf_naming_convention.rst >> 12:following prefixes: ``bpf_``, ``btf_``, ``libbpf_``, ``btf_dump_``, >> 59:described above should have ``libbpf_`` prefix, e.g. > > Those other cases are all inside double back quotes and > construct "inline literal" strings. So they are fine. > > Which means Bagas could have used the "inline literal" approach > instead. > Ah! I was oversighted (not seeing these other cases). Should I convert fixed 'bpf_' to inline literals?
diff --git a/Documentation/bpf/bpf_design_QA.rst b/Documentation/bpf/bpf_design_QA.rst index 4e4af398607b58..17e774d96c5e4b 100644 --- a/Documentation/bpf/bpf_design_QA.rst +++ b/Documentation/bpf/bpf_design_QA.rst @@ -326,11 +326,11 @@ size, type, and alignment, or any other user visible API or ABI detail across kernel releases. The users must adapt their BPF programs to the new changes and update them to make sure their programs continue to work correctly. -NOTE: BPF subsystem specially reserves the 'bpf_' prefix for type names, in +NOTE: BPF subsystem specially reserves the 'bpf\_' prefix for type names, in order to introduce more special fields in the future. Hence, user programs must -avoid defining types with 'bpf_' prefix to not be broken in future releases. In -other words, no backwards compatibility is guaranteed if one using a type in BTF -with 'bpf_' prefix. +avoid defining types with 'bpf\_' prefix to not be broken in future releases. +In other words, no backwards compatibility is guaranteed if one using a type +in BTF with 'bpf\_' prefix. Q: What is the compatibility story for special BPF types in local kptrs? ------------------------------------------------------------------------