mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-07-30 13:53:54 -06:00

This commit adds a re-implementation of hw/char/pl011.c in Rust. How to build: 1. Configure a QEMU build with: --enable-system --target-list=aarch64-softmmu --enable-rust 2. Launching a VM with qemu-system-aarch64 should use the Rust version of the pl011 device Co-authored-by: Junjie Mao <junjie.mao@intel.com> Co-authored-by: Paolo Bonzini <pbonzini@redhat.com> Signed-off-by: Junjie Mao <junjie.mao@intel.com> Signed-off-by: Manos Pitsidianakis <manos.pitsidianakis@linaro.org> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> Link: https://lore.kernel.org/r/20241024-rust-round-2-v1-2-051e7a25b978@linaro.org
31 lines
737 B
Markdown
31 lines
737 B
Markdown
# PL011 QEMU Device Model
|
|
|
|
This library implements a device model for the PrimeCell® UART (PL011)
|
|
device in QEMU.
|
|
|
|
## Build static lib
|
|
|
|
Host build target must be explicitly specified:
|
|
|
|
```sh
|
|
cargo build --target x86_64-unknown-linux-gnu
|
|
```
|
|
|
|
Replace host target triplet if necessary.
|
|
|
|
## Generate Rust documentation
|
|
|
|
To generate docs for this crate, including private items:
|
|
|
|
```sh
|
|
cargo doc --no-deps --document-private-items --target x86_64-unknown-linux-gnu
|
|
```
|
|
|
|
To include direct dependencies like `bilge` (bitmaps for register types):
|
|
|
|
```sh
|
|
cargo tree --depth 1 -e normal --prefix none \
|
|
| cut -d' ' -f1 \
|
|
| xargs printf -- '-p %s\n' \
|
|
| xargs cargo doc --no-deps --document-private-items --target x86_64-unknown-linux-gnu
|
|
```
|