Received: by 10.223.185.116 with SMTP id b49csp1034035wrg; Fri, 16 Feb 2018 11:11:18 -0800 (PST) X-Google-Smtp-Source: AH8x226X2qU33RdIX5iuHI1f4gZk6O27s5pSEybrccDY+eWkMeLFRAfs6QUlLRTMIbpv2a2Ghm7S X-Received: by 10.99.107.200 with SMTP id g191mr5856351pgc.165.1518808278293; Fri, 16 Feb 2018 11:11:18 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1518808278; cv=none; d=google.com; s=arc-20160816; b=rfEpbWXUZgVf8oduU2w8L7Dl/oHclsBSDNCTnzBFUtKepdZsQdji7BPBGGyQdC0B+W LdGzDG2eBs8a5WzQ4mvhFApNHFKecl2OeHpaprV6DHY/rFyGPTWq+Co1xWEu03/4qlpz kr8LgtpxnxmL+UHWYjSdH9gNT+9s8pjR8rxpBxEWZ7qLamzjWnXff89E0z7nJvfkH+7Y VddES0KORNaSA9kDEHwIZCCvwoReB28W9oeg0wNOxuJr6Q9zifvN549KhXgKjtzjF1sx HYoqt+lDtZVwSwsPJjgIr7JOgiWPr9zKMBLJxX8/2ep0G2GR+IJXqM1hguJnqySr293B FqQg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:references :in-reply-to:message-id:date:subject:cc:to:from :arc-authentication-results; bh=7c2xZNofFoB67HSQ+02vgvObdVHuzYHP72CqaOmR/uw=; b=gMAkOIJsaImaN31E385DXY9ihA/lZ0RDfQHEuqOJVPHZmHHfQ/adldcDIqFHj1PlVi Xs4xaHnTEFRt87RRe3sU6U2U3Je3yByw41WMFK0G9bbuGmUfE8Mk9hTRPhAbB9wcWzsI OeSHNhowMH4J55/Y3wlknIg4OiZrRqx8jm9hp3ISsBuX+ISIvz6ChbrVsLAf0ivvDyfc n6r3bkmCkbANtbpbJgEAeKXyFVFJg6IaxGMtX3HQU2ozES8wGOA6Au/YNh4hH29DACha +blj2UybFnsi1wQP8+62eJRicn7SsN6PKsHH0QdqnSt5iutfzKm5Cjp49IuHFNAuVttK hSVA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id m4si6127260pgd.450.2018.02.16.11.11.03; Fri, 16 Feb 2018 11:11:18 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1032561AbeBPNsh (ORCPT + 99 others); Fri, 16 Feb 2018 08:48:37 -0500 Received: from osg.samsung.com ([64.30.133.232]:59041 "EHLO osg.samsung.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1032341AbeBPNsa (ORCPT ); Fri, 16 Feb 2018 08:48:30 -0500 Received: from localhost (localhost [127.0.0.1]) by osg.samsung.com (Postfix) with ESMTP id 94DBE3465C; Fri, 16 Feb 2018 05:48:30 -0800 (PST) X-Virus-Scanned: Debian amavisd-new at dev.s-opensource.com X-Amavis-Alert: BAD HEADER SECTION, Duplicate header field: "References" Received: from osg.samsung.com ([127.0.0.1]) by localhost (localhost [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id t-Tl9mq1bqdA; Fri, 16 Feb 2018 05:48:29 -0800 (PST) Received: from smtp.s-opensource.com (177.17.248.146.dynamic.adsl.gvt.net.br [177.17.248.146]) by osg.samsung.com (Postfix) with ESMTPSA id 6AC303462B; Fri, 16 Feb 2018 05:48:27 -0800 (PST) Received: from mchehab by smtp.s-opensource.com with local (Exim 4.89) (envelope-from ) id 1emgNE-0002xX-UM; Fri, 16 Feb 2018 11:48:24 -0200 From: Mauro Carvalho Chehab To: Linux Doc Mailing List Cc: Mauro Carvalho Chehab , Mauro Carvalho Chehab , linux-kernel@vger.kernel.org, Jonathan Corbet , Jani Nikula , Matthew Wilcox , Tom Saeger Subject: [PATCH 3/6] doc-guide: kernel-doc: move in-line section to be after nested struct Date: Fri, 16 Feb 2018 11:48:17 -0200 Message-Id: X-Mailer: git-send-email 2.14.3 In-Reply-To: References: In-Reply-To: References: Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org We want to give some examples about how to do in-line comments for nested structs. So, move it to be after nested structs/unions chapter. The section content was not changed on this patch. Signed-off-by: Mauro Carvalho Chehab --- Documentation/doc-guide/kernel-doc.rst | 56 +++++++++++++++++----------------- 1 file changed, 28 insertions(+), 28 deletions(-) diff --git a/Documentation/doc-guide/kernel-doc.rst b/Documentation/doc-guide/kernel-doc.rst index 3c00ce0c84e5..1ddfe35c0e78 100644 --- a/Documentation/doc-guide/kernel-doc.rst +++ b/Documentation/doc-guide/kernel-doc.rst @@ -211,34 +211,6 @@ Example:: int d; }; -In-line member documentation comments -~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - -The structure members may also be documented in-line within the definition. -There are two styles, single-line comments where both the opening ``/**`` and -closing ``*/`` are on the same line, and multi-line comments where they are each -on a line of their own, like all other kernel-doc comments:: - - /** - * struct foo - Brief description. - * @foo: The Foo member. - */ - struct foo { - int foo; - /** - * @bar: The Bar member. - */ - int bar; - /** - * @baz: The Baz member. - * - * Here, the member description may contain several paragraphs. - */ - int baz; - /** @foobar: Single line description. */ - int foobar; - }; - Nested structs/unions ~~~~~~~~~~~~~~~~~~~~~ @@ -290,6 +262,34 @@ It is possible to document nested structs and unions, like:: #) When the nested struct/union is anonymous, the member ``bar`` in it should be documented as ``@bar:`` +In-line member documentation comments +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +The structure members may also be documented in-line within the definition. +There are two styles, single-line comments where both the opening ``/**`` and +closing ``*/`` are on the same line, and multi-line comments where they are each +on a line of their own, like all other kernel-doc comments:: + + /** + * struct foo - Brief description. + * @foo: The Foo member. + */ + struct foo { + int foo; + /** + * @bar: The Bar member. + */ + int bar; + /** + * @baz: The Baz member. + * + * Here, the member description may contain several paragraphs. + */ + int baz; + /** @foobar: Single line description. */ + int foobar; + }; + Typedef documentation --------------------- -- 2.14.3