Skip to content

Commit

Permalink
uefi: Replace IpFilters with PxeBaseCodeIpFilterFlags from uefi-raw
Browse files Browse the repository at this point in the history
  • Loading branch information
nicholasbishop committed Feb 17, 2025
1 parent 9d62973 commit 86cc82a
Showing 1 changed file with 3 additions and 17 deletions.
20 changes: 3 additions & 17 deletions uefi/src/proto/network/pxe.rs
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,9 @@ use crate::{CStr8, Char8, Result, Status, StatusExt};

use super::{IpAddress, MacAddress};

pub use uefi_raw::protocol::network::pxe::PxeBaseCodeUdpOpFlags as UdpOpFlags;
pub use uefi_raw::protocol::network::pxe::{
PxeBaseCodeIpFilterFlags as IpFilters, PxeBaseCodeUdpOpFlags as UdpOpFlags,
};

/// PXE Base Code protocol
#[derive(Debug)]
Expand Down Expand Up @@ -874,22 +876,6 @@ impl IpFilter {
}
}

bitflags! {
/// IP receive filters.
#[derive(Clone, Copy, Debug, Default, PartialEq, Eq, PartialOrd, Ord)]
#[repr(transparent)]
pub struct IpFilters: u8 {
/// Enable the Station IP address.
const STATION_IP = 0x01;
/// Enable IPv4 broadcast addresses.
const BROADCAST = 0x02;
/// Enable all addresses.
const PROMISCUOUS = 0x04;
/// Enable all multicast addresses.
const PROMISCUOUS_MULTICAST = 0x08;
}
}

/// A network packet.
///
/// Corresponds to the `EFI_PXE_BASE_CODE_PACKET` type in the C API.
Expand Down

0 comments on commit 86cc82a

Please sign in to comment.