Rust-for-linux archive mirror
 help / color / mirror / Atom feed
From: Aswin Unnikrishnan <aswinunni01@gmail.com>
To: Miguel Ojeda <ojeda@kernel.org>,
	Alex Gaynor <alex.gaynor@gmail.com>,
	Wedson Almeida Filho <wedsonaf@gmail.com>
Cc: "Boqun Feng" <boqun.feng@gmail.com>,
	"Gary Guo" <gary@garyguo.net>,
	"Björn Roy Baron" <bjorn3_gh@protonmail.com>,
	"Benno Lossin" <benno.lossin@proton.me>,
	"Andreas Hindborg" <a.hindborg@samsung.com>,
	"Alice Ryhl" <aliceryhl@google.com>,
	rust-for-linux@vger.kernel.org,
	"Aswin Unnikrishnan" <aswinunni01@gmail.com>
Subject: [PATCH v2 1/2] rust: add example for `alias` argument in `module` macro documentation
Date: Sun, 12 May 2024 11:23:20 +0000	[thread overview]
Message-ID: <20240512112324.8514-1-aswinunni01@gmail.com> (raw)

Add example for `alias` argument supported by `module` macro.
`alias` accepts an array of alternate names for the module as string.

Reviewed-by: Alice Ryhl <aliceryhl@google.com>
Signed-off-by: Aswin Unnikrishnan <aswinunni01@gmail.com>
---

Changes in v2:
- Add Reviewed-by tag
- Link to v1: https://lore.kernel.org/rust-for-linux/20240419215015.157258-2-aswinunni01@gmail.com/

 rust/macros/lib.rs | 1 +
 1 file changed, 1 insertion(+)

diff --git a/rust/macros/lib.rs b/rust/macros/lib.rs
index 520eae5fd792..aa89b41fa10e 100644
--- a/rust/macros/lib.rs
+++ b/rust/macros/lib.rs
@@ -35,6 +35,7 @@
 ///     author: "Rust for Linux Contributors",
 ///     description: "My very own kernel module!",
 ///     license: "GPL",
+///     alias: ["alternate_module_name"],
 /// }
 ///
 /// struct MyModule;
-- 
2.43.0


             reply	other threads:[~2024-05-12 11:23 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-05-12 11:23 Aswin Unnikrishnan [this message]
2024-05-12 11:23 ` [PATCH v2 2/2] rust: fix datatype in docs for `module` macro arguments Aswin Unnikrishnan
2024-05-27 19:31   ` Benno Lossin
2024-05-27 19:31 ` [PATCH v2 1/2] rust: add example for `alias` argument in `module` macro documentation Benno Lossin

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=20240512112324.8514-1-aswinunni01@gmail.com \
    --to=aswinunni01@gmail.com \
    --cc=a.hindborg@samsung.com \
    --cc=alex.gaynor@gmail.com \
    --cc=aliceryhl@google.com \
    --cc=benno.lossin@proton.me \
    --cc=bjorn3_gh@protonmail.com \
    --cc=boqun.feng@gmail.com \
    --cc=gary@garyguo.net \
    --cc=ojeda@kernel.org \
    --cc=rust-for-linux@vger.kernel.org \
    --cc=wedsonaf@gmail.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 read-only IMAP folder(s) and NNTP newsgroup(s).