Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion uefi/src/boot.rs
Original file line number Diff line number Diff line change
Expand Up @@ -310,7 +310,7 @@ pub(crate) fn memory_map_size() -> MemoryMapMeta {
/// the right allocation size for the memory map to prevent
/// [`Status::BUFFER_TOO_SMALL`].
///
/// # Parameters
/// # Arguments
///
/// - `mt`: The memory type for the backing memory on the UEFI heap.
/// Usually, this is [`MemoryType::LOADER_DATA`]. You can also use a
Expand Down
2 changes: 1 addition & 1 deletion uefi/src/mem/memory_map/impl_.rs
Original file line number Diff line number Diff line change
Expand Up @@ -275,7 +275,7 @@ pub(crate) struct MemoryMapBackingMemory(NonNull<[u8]>);
impl MemoryMapBackingMemory {
/// Constructs a new [`MemoryMapBackingMemory`].
///
/// # Parameters
/// # Arguments
/// - `memory_type`: The memory type for the memory map allocation.
/// Typically, [`MemoryType::LOADER_DATA`] for regular UEFI applications.
pub(crate) fn new(memory_type: MemoryType) -> crate::Result<Self> {
Expand Down
14 changes: 7 additions & 7 deletions uefi/src/proto/ata/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ pub struct AtaRequestBuilder<'a> {
impl<'a> AtaRequestBuilder<'a> {
/// Creates a new [`AtaRequestBuilder`] with the specified alignment, command, and protocol.
///
/// # Parameters
/// # Arguments
/// - `io_align`: The I/O buffer alignment required for the ATA controller.
/// - `command`: The ATA command byte specifying the operation to execute.
/// - `protocol`: The protocol type for the command (e.g., DMA, UDMA, etc.).
Expand Down Expand Up @@ -89,7 +89,7 @@ impl<'a> AtaRequestBuilder<'a> {

/// Creates a builder for a UDMA read operation.
///
/// # Parameters
/// # Arguments
/// - `io_align`: The I/O buffer alignment required for the ATA controller.
/// - `command`: The ATA command byte specifying the read operation.
///
Expand All @@ -104,7 +104,7 @@ impl<'a> AtaRequestBuilder<'a> {

/// Creates a builder for a UDMA write operation.
///
/// # Parameters
/// # Arguments
/// - `io_align`: The I/O buffer alignment required for the ATA controller.
/// - `command`: The ATA command byte specifying the write operation.
///
Expand Down Expand Up @@ -196,7 +196,7 @@ impl<'a> AtaRequestBuilder<'a> {

/// Uses a user-supplied buffer for reading data from the device.
///
/// # Parameters
/// # Arguments
/// - `bfr`: A mutable reference to an [`AlignedBuffer`] that will be used to store data read from the device.
///
/// # Returns
Expand All @@ -216,7 +216,7 @@ impl<'a> AtaRequestBuilder<'a> {

/// Adds a newly allocated read buffer to the built ATA request.
///
/// # Parameters
/// # Arguments
/// - `len`: The size of the buffer (in bytes) to allocate for receiving data.
///
/// # Returns
Expand All @@ -234,7 +234,7 @@ impl<'a> AtaRequestBuilder<'a> {

/// Uses a user-supplied buffer for writing data to the device.
///
/// # Parameters
/// # Arguments
/// - `bfr`: A mutable reference to an [`AlignedBuffer`] containing the data to be written to the device.
///
/// # Returns
Expand All @@ -255,7 +255,7 @@ impl<'a> AtaRequestBuilder<'a> {
/// Adds a newly allocated write buffer to the built ATA request that is filled from the
/// given data buffer. (Done for memory alignment and lifetime purposes)
///
/// # Parameters
/// # Arguments
/// - `data`: A slice of bytes representing the data to be written.
///
/// # Returns
Expand Down
4 changes: 2 additions & 2 deletions uefi/src/proto/ata/pass_thru.rs
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ impl AtaPassThru {
/// The `ata` api will validate that your buffers have the correct alignment and error
/// if they don't.
///
/// # Parameters
/// # Arguments
/// - `len`: The size (in bytes) of the buffer to allocate.
///
/// # Returns
Expand Down Expand Up @@ -162,7 +162,7 @@ impl AtaDevice<'_> {

/// Executes a command on the device.
///
/// # Parameters
/// # Arguments
/// - `req`: The request structure containing details about the command to execute.
///
/// # Returns
Expand Down
8 changes: 4 additions & 4 deletions uefi/src/proto/device_path/util.rs
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ impl DevicePathUtilities {
/// Retrieves the size of the specified device path in bytes, including the
/// end-of-device-path node.
///
/// # Parameters
/// # Arguments
/// - `device_path`: A reference to the [`DevicePath`] whose size is to be determined.
///
/// # Returns
Expand All @@ -31,7 +31,7 @@ impl DevicePathUtilities {

/// Creates a new device path by appending the second device path to the first.
///
/// # Parameters
/// # Arguments
/// - `path0`: A reference to the base device path.
/// - `path1`: A reference to the device path to append.
///
Expand All @@ -54,7 +54,7 @@ impl DevicePathUtilities {

/// Creates a new device path by appending a device node to the base device path.
///
/// # Parameters
/// # Arguments
/// - `basepath`: A reference to the base device path.
/// - `node`: A reference to the device node to append.
///
Expand All @@ -77,7 +77,7 @@ impl DevicePathUtilities {

/// Creates a new device path by appending the specified device path instance to the base path.
///
/// # Parameters
/// # Arguments
/// - `basepath`: A reference to the base device path.
/// - `instance`: A reference to the device path instance to append.
///
Expand Down
6 changes: 3 additions & 3 deletions uefi/src/proto/media/disk_info.rs
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ impl DiskInfo {

/// Performs an inquiry command on the disk device.
///
/// # Parameters
/// # Arguments
/// - `bfr`: A mutable byte buffer to store the inquiry data.
///
/// # Returns
Expand All @@ -116,7 +116,7 @@ impl DiskInfo {

/// Performs an identify command on the disk device.
///
/// # Parameters
/// # Arguments
/// - `bfr`: A mutable byte buffer to store the identification data.
///
/// # Returns
Expand All @@ -137,7 +137,7 @@ impl DiskInfo {

/// Retrieves sense data from the disk device.
///
/// # Parameters
/// # Arguments
/// - `bfr`: A mutable byte buffer to store the sense data.
///
/// # Returns
Expand Down
4 changes: 2 additions & 2 deletions uefi/src/proto/media/load_file.rs
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ pub struct LoadFile(LoadFileProtocol);
impl LoadFile {
/// Causes the driver to load a specified file.
///
/// # Parameters
/// # Arguments
/// - `file_path` The device specific path of the file to load.
/// - `boot_policy` The [`BootPolicy`] to use.
///
Expand Down Expand Up @@ -121,7 +121,7 @@ pub struct LoadFile2(LoadFile2Protocol);
impl LoadFile2 {
/// Causes the driver to load a specified file.
///
/// # Parameters
/// # Arguments
/// - `file_path` The device specific path of the file to load.
///
/// # Errors
Expand Down
10 changes: 5 additions & 5 deletions uefi/src/proto/nvme/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ pub struct NvmeRequestBuilder<'buffers> {
impl<'buffers> NvmeRequestBuilder<'buffers> {
/// Creates a new builder for configuring an NVMe request.
///
/// # Parameters
/// # Arguments
/// - `io_align`: Memory alignment requirements for buffers.
/// - `opcode`: The opcode for the NVMe command.
/// - `queue_type`: Specifies the type of queue the command should be placed into.
Expand Down Expand Up @@ -142,7 +142,7 @@ impl<'buffers> NvmeRequestBuilder<'buffers> {

/// Uses a user-supplied buffer for reading data from the device.
///
/// # Parameters
/// # Arguments
/// - `bfr`: A mutable reference to an [`AlignedBuffer`] that will be used to store data read from the device.
///
/// # Returns
Expand All @@ -165,7 +165,7 @@ impl<'buffers> NvmeRequestBuilder<'buffers> {

/// Adds a newly allocated transfer buffer to the built NVMe request.
///
/// # Parameters
/// # Arguments
/// - `len`: The size of the buffer (in bytes) to allocate for receiving data.
///
/// # Returns
Expand All @@ -183,7 +183,7 @@ impl<'buffers> NvmeRequestBuilder<'buffers> {

/// Uses a user-supplied metadata buffer.
///
/// # Parameters
/// # Arguments
/// - `bfr`: A mutable reference to an [`AlignedBuffer`] that will be used to store metadata.
///
/// # Returns
Expand All @@ -206,7 +206,7 @@ impl<'buffers> NvmeRequestBuilder<'buffers> {

/// Adds a newly allocated metadata buffer to the built NVMe request.
///
/// # Parameters
/// # Arguments
/// - `len`: The size of the buffer (in bytes) to allocate for storing metadata.
///
/// # Returns
Expand Down
4 changes: 2 additions & 2 deletions uefi/src/proto/nvme/pass_thru.rs
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ impl NvmePassThru {
/// The `nvme` api will validate that your buffers have the correct alignment and error
/// if they don't.
///
/// # Parameters
/// # Arguments
/// - `len`: The size (in bytes) of the buffer to allocate.
///
/// # Returns
Expand Down Expand Up @@ -148,7 +148,7 @@ impl NvmeNamespace<'_> {

/// Sends an NVM Express command to this namespace (Namespace ID ≥ 1).
///
/// # Parameters
/// # Arguments
/// - `req`: The [`NvmeRequest`] containing the command and associated data to send to the namespace.
///
/// # Returns
Expand Down
24 changes: 12 additions & 12 deletions uefi/src/proto/scsi/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ pub struct ScsiRequestBuilder<'a> {
impl ScsiRequestBuilder<'_> {
/// Creates a new instance with the specified data direction and alignment.
///
/// # Parameters
/// # Arguments
/// - `direction`: Specifies the direction of data transfer (READ, WRITE, or BIDIRECTIONAL).
/// - `io_align`: Specifies the required alignment for data buffers. (SCSI Controller specific!)
#[must_use]
Expand Down Expand Up @@ -84,7 +84,7 @@ impl ScsiRequestBuilder<'_> {
/// - READ
/// - MODE_SENSE
///
/// # Parameters
/// # Arguments
/// - `io_align`: Specifies the required alignment for data buffers.
#[must_use]
pub fn read(io_align: u32) -> Self {
Expand All @@ -97,7 +97,7 @@ impl ScsiRequestBuilder<'_> {
/// - WRITE
/// - MODE_SELECT
///
/// # Parameters
/// # Arguments
/// - `io_align`: Specifies the required alignment for data buffers.
#[must_use]
pub fn write(io_align: u32) -> Self {
Expand All @@ -109,7 +109,7 @@ impl ScsiRequestBuilder<'_> {
/// Some examples of SCSI bidirectional commands are:
/// - SEND DIAGNOSTIC
///
/// # Parameters
/// # Arguments
/// - `io_align`: Specifies the required alignment for data buffers.
#[must_use]
pub fn bidirectional(io_align: u32) -> Self {
Expand All @@ -120,7 +120,7 @@ impl ScsiRequestBuilder<'_> {
impl<'a> ScsiRequestBuilder<'a> {
/// Sets a timeout for the SCSI request.
///
/// # Parameters
/// # Arguments
/// - `timeout`: A [`Duration`] representing the maximum time allowed for the request.
/// The value is converted to 100-nanosecond units.
///
Expand All @@ -139,7 +139,7 @@ impl<'a> ScsiRequestBuilder<'a> {

/// Uses a user-supplied buffer for reading data from the device.
///
/// # Parameters
/// # Arguments
/// - `bfr`: A mutable reference to an [`AlignedBuffer`] that will be used to store data read from the device.
///
/// # Returns
Expand All @@ -159,7 +159,7 @@ impl<'a> ScsiRequestBuilder<'a> {

/// Adds a newly allocated read buffer to the built SCSI request.
///
/// # Parameters
/// # Arguments
/// - `len`: The size of the buffer (in bytes) to allocate for receiving data.
///
/// # Returns
Expand All @@ -177,7 +177,7 @@ impl<'a> ScsiRequestBuilder<'a> {

/// Adds a newly allocated sense buffer to the built SCSI request.
///
/// # Parameters
/// # Arguments
/// - `len`: The size of the buffer (in bytes) to allocate for receiving sense data.
///
/// # Returns
Expand All @@ -195,7 +195,7 @@ impl<'a> ScsiRequestBuilder<'a> {

/// Uses a user-supplied buffer for writing data to the device.
///
/// # Parameters
/// # Arguments
/// - `bfr`: A mutable reference to an [`AlignedBuffer`] containing the data to be written to the device.
///
/// # Returns
Expand All @@ -216,7 +216,7 @@ impl<'a> ScsiRequestBuilder<'a> {
/// Adds a newly allocated write buffer to the built SCSI request that is filled from the
/// given data buffer. (Done for memory alignment and lifetime purposes)
///
/// # Parameters
/// # Arguments
/// - `data`: A slice of bytes representing the data to be written.
///
/// # Returns
Expand All @@ -235,7 +235,7 @@ impl<'a> ScsiRequestBuilder<'a> {

/// Uses a user-supplied Command Data Block (CDB) buffer.
///
/// # Parameters
/// # Arguments
/// - `data`: A mutable reference to an [`AlignedBuffer`] containing the CDB to be sent to the device.
///
/// # Returns
Expand All @@ -259,7 +259,7 @@ impl<'a> ScsiRequestBuilder<'a> {
/// Adds a newly allocated Command Data Block (CDB) buffer to the built SCSI request that is filled from the
/// given data buffer. (Done for memory alignment and lifetime purposes)
///
/// # Parameters
/// # Arguments
/// - `data`: A slice of bytes representing the command to be sent.
///
/// # Returns
Expand Down
4 changes: 2 additions & 2 deletions uefi/src/proto/scsi/pass_thru.rs
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ impl ExtScsiPassThru {
/// The Scsi api will validate that your buffers have the correct alignment and crash
/// if they don't.
///
/// # Parameters
/// # Arguments
/// - `len`: The size (in bytes) of the buffer to allocate.
///
/// # Returns
Expand Down Expand Up @@ -196,7 +196,7 @@ impl ScsiDevice<'_> {
/// It supports both blocking and nonblocking I/O. Blocking I/O is mandatory, while
/// nonblocking I/O is optional and dependent on the driver's implementation.
///
/// # Parameters
/// # Arguments
/// - `scsi_req`: The [`ScsiRequest`] containing the command and data to send to the device.
///
/// # Returns
Expand Down
2 changes: 1 addition & 1 deletion xtask/src/cargo.rs
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ impl Feature {
}

/// Set of features that enables more code in the root uefi crate.
/// # Parameters
/// # Arguments
/// - `include_unstable` - add all functionality behind the `unstable` feature
/// - `runtime_features` - add all functionality that effect the runtime of Rust
pub fn more_code(include_unstable: bool, runtime_features: bool) -> Vec<Self> {
Expand Down
Loading