qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Manos Pitsidianakis <manos.pitsidianakis@linaro.org>
To: qemu-devel@nongnu.org
Cc: "Stefan Hajnoczi" <stefanha@redhat.com>,
	"Mads Ynddal" <mads@ynddal.dk>,
	"Peter Maydell" <peter.maydell@linaro.org>,
	"Alex Bennée" <alex.bennee@linaro.org>,
	"Daniel P. Berrangé" <berrange@redhat.com>,
	"Marc-André Lureau" <marcandre.lureau@redhat.com>,
	"Thomas Huth" <thuth@redhat.com>,
	"Markus Armbruster" <armbru@redhat.com>,
	"Philippe Mathieu-Daudé" <philmd@linaro.org>,
	"Zhao Liu" <zhao1.liu@intel.com>,
	"Gustavo Romero" <gustavo.romero@linaro.org>,
	"Pierrick Bouvier" <pierrick.bouvier@linaro.org>,
	rowan.hart@intel.com,
	"Richard Henderson" <richard.henderson@linaro.org>
Subject: [RFC PATCH v4 0/7] Add Rust support, implement ARM PL011
Date: Thu,  4 Jul 2024 15:15:36 +0300	[thread overview]
Message-ID: <rust-pl011-rfc-v4.git.manos.pitsidianakis@linaro.org> (raw)

Changes from v3->v4:
- Add rust-specific files to .gitattributes
- Added help text to scripts/cargo_wrapper.py arguments (thanks Stephan)
- Split bindings separate crate
- Add declarative macros for symbols exported to QEMU to said crate
- Lowered MSRV to 1.77.2
- Removed auto-download and install of bindgen-cli
- Fixed re-compilation of Rust objects in case they are missing from 
  filesystem
- Fixed optimized builds by adding #[used] (thanks Pierrick for the help 
  debugging this)

Also, Pierrick helped confirming it works on Windows with some 
windows-specific changes. I confirmed it works on macos by allowing 
bindgen to detect system paths for clang, which is a workaround and not 
a solution. However this series doesn't have the windows changes 
integrated.

Changes from v2->v3:
- Addressed minor mistakes (thanks Stefan)
- Setup supported version checks for cargo, rustc and bindgen (thanks 
  everyone who pointed it out / suggested it)
- Fixed problem with bindgen failing if certain system headers where 
  needed by defining an allowlist for headers instead of a blocklist for 
  what we don't want (thanks Alex Bennée for reporting it)
- Cleaned up bindgen target/dependendy definition in meson.build by 
  removing unnecessary bits

Changes from v1->v2:
- Create bindgen target first, then add commit for device (thanks 
  Pierrick)
- Create a special named generated.rs for each target as compilation 
  would fail if more than one targets were defined. The generated.rs 
  target names would clash.
- Add more descriptive commit messages
- Update MAINTAINERS
- Cleanup patch order for better review, hopefully


Manos Pitsidianakis (7):
  build-sys: Add rust feature option
  rust: add bindgen step as a meson dependency
  rust: add crate to expose bindings and interfaces
  rust: add PL011 device model
  .gitattributes: add Rust diff and merge attributes
  DO NOT MERGE: add rustdoc build for gitlab pages
  DO NOT MERGE: replace TYPE_PL011 with x-pl011-rust in arm virt machine

 .gitattributes                    |   3 +
 .gitlab-ci.d/buildtest.yml        |  64 +++-
 MAINTAINERS                       |  20 ++
 configure                         |  11 +
 hw/arm/virt.c                     |   4 +
 meson.build                       |  72 ++++
 meson_options.txt                 |   5 +
 rust/.cargo/config.toml           |   2 +
 rust/.gitignore                   |   3 +
 rust/meson.build                  | 114 ++++++
 rust/pl011/.gitignore             |   2 +
 rust/pl011/Cargo.lock             | 125 +++++++
 rust/pl011/Cargo.toml             |  67 ++++
 rust/pl011/README.md              |  31 ++
 rust/pl011/deny.toml              |  57 +++
 rust/pl011/meson.build            |   7 +
 rust/pl011/rustfmt.toml           |   1 +
 rust/pl011/src/definitions.rs     |  39 +++
 rust/pl011/src/device.rs          | 509 +++++++++++++++++++++++++++
 rust/pl011/src/device_class.rs    |  48 +++
 rust/pl011/src/lib.rs             | 556 ++++++++++++++++++++++++++++++
 rust/pl011/src/memory_ops.rs      |  45 +++
 rust/qemu-api/.gitignore          |   2 +
 rust/qemu-api/Cargo.lock          |   7 +
 rust/qemu-api/Cargo.toml          |  59 ++++
 rust/qemu-api/README.md           |  17 +
 rust/qemu-api/build.rs            |  48 +++
 rust/qemu-api/deny.toml           |  57 +++
 rust/qemu-api/meson.build         |   0
 rust/qemu-api/rustfmt.toml        |   1 +
 rust/qemu-api/src/bindings.rs     |   8 +
 rust/qemu-api/src/definitions.rs  | 112 ++++++
 rust/qemu-api/src/device_class.rs | 131 +++++++
 rust/qemu-api/src/lib.rs          |  29 ++
 rust/qemu-api/src/tests.rs        |  48 +++
 rust/rustfmt.toml                 |   7 +
 rust/wrapper.h                    |  39 +++
 scripts/cargo_wrapper.py          | 288 ++++++++++++++++
 scripts/meson-buildoptions.sh     |   6 +
 39 files changed, 2625 insertions(+), 19 deletions(-)
 create mode 100644 rust/.cargo/config.toml
 create mode 100644 rust/.gitignore
 create mode 100644 rust/meson.build
 create mode 100644 rust/pl011/.gitignore
 create mode 100644 rust/pl011/Cargo.lock
 create mode 100644 rust/pl011/Cargo.toml
 create mode 100644 rust/pl011/README.md
 create mode 100644 rust/pl011/deny.toml
 create mode 100644 rust/pl011/meson.build
 create mode 120000 rust/pl011/rustfmt.toml
 create mode 100644 rust/pl011/src/definitions.rs
 create mode 100644 rust/pl011/src/device.rs
 create mode 100644 rust/pl011/src/device_class.rs
 create mode 100644 rust/pl011/src/lib.rs
 create mode 100644 rust/pl011/src/memory_ops.rs
 create mode 100644 rust/qemu-api/.gitignore
 create mode 100644 rust/qemu-api/Cargo.lock
 create mode 100644 rust/qemu-api/Cargo.toml
 create mode 100644 rust/qemu-api/README.md
 create mode 100644 rust/qemu-api/build.rs
 create mode 100644 rust/qemu-api/deny.toml
 create mode 100644 rust/qemu-api/meson.build
 create mode 120000 rust/qemu-api/rustfmt.toml
 create mode 100644 rust/qemu-api/src/bindings.rs
 create mode 100644 rust/qemu-api/src/definitions.rs
 create mode 100644 rust/qemu-api/src/device_class.rs
 create mode 100644 rust/qemu-api/src/lib.rs
 create mode 100644 rust/qemu-api/src/tests.rs
 create mode 100644 rust/rustfmt.toml
 create mode 100644 rust/wrapper.h
 create mode 100644 scripts/cargo_wrapper.py


base-commit: 7914bda497f07965f15a91905cd7ed9eaf1c1092
-- 
γαῖα πυρί μιχθήτω



             reply	other threads:[~2024-07-04 12:17 UTC|newest]

Thread overview: 38+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-07-04 12:15 Manos Pitsidianakis [this message]
2024-07-04 12:15 ` [RFC PATCH v4 1/7] build-sys: Add rust feature option Manos Pitsidianakis
2024-07-08 14:49   ` Paolo Bonzini
2024-07-04 12:15 ` [RFC PATCH v4 2/7] rust: add bindgen step as a meson dependency Manos Pitsidianakis
2024-07-08 15:07   ` Paolo Bonzini
2024-07-09 10:53   ` Alex Bennée
2024-07-09 12:08     ` Peter Maydell
2024-07-09 12:28       ` Paolo Bonzini
2024-07-09 13:00         ` Daniel P. Berrangé
2024-07-11 21:23           ` Pierrick Bouvier
2024-07-12  6:14             ` Manos Pitsidianakis
2024-07-09 14:23         ` Alex Bennée
2024-07-10 15:03         ` Zhao Liu
2024-07-10 14:50           ` Paolo Bonzini
2024-07-11  8:30             ` Zhao Liu
2024-07-09 14:52     ` Alex Bennée
2024-07-10  8:55   ` Alex Bennée
2024-07-04 12:15 ` [RFC PATCH v4 3/7] rust: add crate to expose bindings and interfaces Manos Pitsidianakis
2024-07-08 15:40   ` Paolo Bonzini
2024-07-04 12:15 ` [RFC PATCH v4 4/7] rust: add PL011 device model Manos Pitsidianakis
2024-07-08 16:07   ` Paolo Bonzini
2024-07-04 12:15 ` [RFC PATCH v4 5/7] .gitattributes: add Rust diff and merge attributes Manos Pitsidianakis
2024-07-10  8:44   ` Alex Bennée
2024-07-04 12:15 ` [RFC PATCH v4 6/7] DO NOT MERGE: add rustdoc build for gitlab pages Manos Pitsidianakis
2024-07-04 12:15 ` [RFC PATCH v4 7/7] DO NOT MERGE: replace TYPE_PL011 with x-pl011-rust in arm virt machine Manos Pitsidianakis
2024-07-08 16:26 ` [RFC PATCH v4 0/7] Add Rust support, implement ARM PL011 Paolo Bonzini
2024-07-08 16:33   ` Daniel P. Berrangé
2024-07-08 16:55     ` Paolo Bonzini
2024-07-08 17:12       ` Daniel P. Berrangé
2024-07-08 18:34         ` Paolo Bonzini
2024-07-08 18:39           ` Manos Pitsidianakis
2024-07-08 18:48             ` Paolo Bonzini
2024-07-09  7:38               ` Manos Pitsidianakis
2024-07-09  7:54                 ` Paolo Bonzini
2024-07-09 12:18                   ` Daniel P. Berrangé
2024-07-09 16:51                     ` Paolo Bonzini
2024-07-09 18:02                       ` Richard Henderson
2024-07-09 10:34             ` Manos Pitsidianakis

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=rust-pl011-rfc-v4.git.manos.pitsidianakis@linaro.org \
    --to=manos.pitsidianakis@linaro.org \
    --cc=alex.bennee@linaro.org \
    --cc=armbru@redhat.com \
    --cc=berrange@redhat.com \
    --cc=gustavo.romero@linaro.org \
    --cc=mads@ynddal.dk \
    --cc=marcandre.lureau@redhat.com \
    --cc=peter.maydell@linaro.org \
    --cc=philmd@linaro.org \
    --cc=pierrick.bouvier@linaro.org \
    --cc=qemu-devel@nongnu.org \
    --cc=richard.henderson@linaro.org \
    --cc=rowan.hart@intel.com \
    --cc=stefanha@redhat.com \
    --cc=thuth@redhat.com \
    --cc=zhao1.liu@intel.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).