Commit Graph

19 Commits

Author SHA1 Message Date
Suyono 358c1104dc compatibility: updated module declaration 2023-04-09 23:37:43 +10:00
Miguel Ojeda c8ed25d081 README: update with website
Signed-off-by: Miguel Ojeda <ojeda@kernel.org>
2023-03-08 15:45:04 +01:00
Miguel Ojeda 885d229c0d README: use docs.kernel.org link
Signed-off-by: Miguel Ojeda <ojeda@kernel.org>
2023-03-08 15:45:04 +01:00
Miguel Ojeda a7f73938f8 Be consistent in `$PWD` use
Signed-off-by: Miguel Ojeda <ojeda@kernel.org>
2023-02-05 02:16:11 +01:00
Miguel Ojeda 2f962a6247 Temporarily clarify that a patch is still required
Signed-off-by: Miguel Ojeda <ojeda@kernel.org>
2023-02-05 02:15:07 +01:00
Miguel Ojeda 490d67b427
Merge pull request #4 from thepacketgeek/generate-rust-project
Adding section about rust-analyzer in README
2023-01-24 20:59:12 +01:00
Mat Wood 5081c8d082 Adding section about rust-analyzer in README
- Including an example of how to create a rust-analyzer `rust-project.json` config
- Adding `rust-project.json` to `.gitignore`

Signed-off-by: Matthew Wood <mat@thepacketgeek.com>
2023-01-24 11:29:56 -08:00
Miguel Ojeda f44f83f3de
Merge pull request #5 from rnestler/fix-build-for-linux-6.2
Update for Linux 6.2
2023-01-24 19:24:19 +01:00
Raphael Nestler e36fc14c01 Update for Linux 6.2
Signed-off-by: Raphael Nestler <raphael.nestler@gmail.com>
2023-01-24 15:22:41 +01:00
Miguel Ojeda a5de4e66ae
Merge pull request #3 from rnestler/fix-build-for-linux-6.1
Fix build for Linux 6.1
2023-01-21 13:02:19 +01:00
Raphael Nestler 2fcc7219e4 Fix build for Linux 6.1 2022-12-18 20:47:44 +01:00
Miguel Ojeda 427f696b5d README: show how the kernel log looks like after loading/unloading
Signed-off-by: Miguel Ojeda <ojeda@kernel.org>
2022-08-06 14:19:39 +02:00
Miguel Ojeda 48c6c6477a rust_out_of_tree: change example data to a `Vec`
This follows the contents of `samples/rust/rust_minimal.rs` in v9, which
is the trimmed down version of v8 where `String` is not in `alloc` anymore.

Now, the log looks like:

    [    1.076945] rust_out_of_tree: Rust out-of-tree sample (init)
    [    1.084944] rust_out_of_tree: My numbers are [72, 108, 200]
    [    1.085944] rust_out_of_tree: Rust out-of-tree sample (exit)

Link: https://lore.kernel.org/lkml/20220805154231.31257-27-ojeda@kernel.org/
Signed-off-by: Miguel Ojeda <ojeda@kernel.org>
2022-08-06 14:19:29 +02:00
Miguel Ojeda b1da1b5ff9 rust_out_of_tree: use string literals in `module!` macro
See commit 593e65924b2e ("rust: take str literal instead bstr literal
in `module!` macro") in the main repository:

    For simplicity (avoid parsing), escape sequences and raw string literals
    are not yet handled.

    Module names, aliases and license strings are restricted to ASCII only.

    Signed-off-by: Gary Guo <gary@garyguo.net>

Link: https://github.com/Rust-for-Linux/linux/issues/252
Link: https://lore.kernel.org/lkml/YukvvPOOu8uZl7+n@yadro.com/
Link: 593e65924b
Signed-off-by: Miguel Ojeda <ojeda@kernel.org>
2022-08-06 14:19:06 +02:00
Miguel Ojeda e22f8fe803 rust_out_of_tree: use `GPL` as the license string instead of `GPL v2`
See commit dda49a0a5bb6 ("treewide: use `GPL` as the license string
instead of `GPL v2`") in the main repository:

    Since commit bf7fbeeae6db ("module: Cure the MODULE_LICENSE "GPL" vs.
    "GPL v2" bogosity"), Documentation/process/license-rules.rst explains
    that `MODULE_LICENSE` arguments can simply use `GPL` instead of `GPL v2`,
    because it is not meant to replace the proper licensing information.

    Since the `license:` field of the `module!` macro is the same as
    `MODULE_LICENSE`, use the simpler form in Rust too.

Link: dda49a0a5b
Signed-off-by: Miguel Ojeda <ojeda@kernel.org>
2022-08-06 14:18:46 +02:00
Miguel Ojeda 6919bb798d
Merge pull request #1 from seannash/main
rename KernelModule to kernel::Module
2022-05-05 00:13:27 +02:00
Sean Nash 44c8594a77 Rename KernelModule to kernel::Module
Signed-off-by: Sean Nash <sean.c.nash@gmail.com>
2022-05-01 09:54:12 -04:00
Miguel Ojeda c53324dd9a Remove `no_std` and `feature(...)` crate attributes
Since PR https://github.com/Rust-for-Linux/linux/pull/635 ("rust:
avoid the need of crate attributes in kernel modules") in the main
repository, these attributes are handled by the build system, thus
there is no need (and it is an error) to specify them.

Signed-off-by: Miguel Ojeda <ojeda@kernel.org>
2022-02-09 00:43:23 +01:00
Miguel Ojeda 6f1b54e2dc Initial commit
Signed-off-by: Miguel Ojeda <ojeda@kernel.org>
2021-12-22 21:46:30 +01:00