[−][src]Struct dpdk_unix::android_linux::mounts::HugePageMountSettings
Settings for mounting a hugetlbfs file system.
Fields
mount_point: PathBuf
Mount point for huge pages file system.
There is no real standard; we default to /dev/hugepages
, this being the default used by the Ubuntu official deb package and similar in spirit to /dev/shm
. Other options include:-
- DPDK
dpdk-setup.sh
uses/mnt/huge
- DPDK docs variously also use
/mnt/hugepages
and/mnt/hugetlbfs
. - RHEL, Debian tutorials and examples use
/hugetlbfs
. - Ubuntu official deb package uses
/dev/hugepages
(https://gerrit.fd.io/r/gitweb?p=deb_dpdk.git;a=blob;f=debian/dpdk-init;h=86eda2cb9c4e802aa07603761a82b312f4bb7fa2;hb=HEAD). - At least one admin on a forum uses
/mnt/huge_1gb
.
user_id: uid_t
User id (uid
), eg 0
.
group_id: gid_t
Group id (gid
), eg 0
.
mode: mode_t
Permissions mode.
Debian uses 1770 for mode.
maximum_value_of_memory_in_bytes: Option<u64>
eg None
.
minimum_value_of_memory_in_bytes: Option<u64>
eg None
.
maximum_number_of_inodes: Option<u64>
eg None
.
mount_flags: MountFlags
eg MountFlags::DoNotUpdateAccessTimes | MountFlags::DoNotAllowProgramsToBeExecuted | MountFlags::DoNotHonourSetUidAndSetGidPermissions
.
Methods
impl HugePageMountSettings
[src]
pub fn mount(&self, sys_path: &SysPath) -> bool
[src]
Creates the required mount point then mounts hugetlbfs
.
Panics if mount already exists and is not a directory.
Returns true
if the mount point was created or false
if it already existed.
Trait Implementations
impl Eq for HugePageMountSettings
[src]
impl Clone for HugePageMountSettings
[src]
fn clone(&self) -> HugePageMountSettings
[src]
fn clone_from(&mut self, source: &Self)
1.0.0[src]
Performs copy-assignment from source
. Read more
impl PartialOrd<HugePageMountSettings> for HugePageMountSettings
[src]
fn partial_cmp(&self, other: &HugePageMountSettings) -> Option<Ordering>
[src]
fn lt(&self, other: &HugePageMountSettings) -> bool
[src]
fn le(&self, other: &HugePageMountSettings) -> bool
[src]
fn gt(&self, other: &HugePageMountSettings) -> bool
[src]
fn ge(&self, other: &HugePageMountSettings) -> bool
[src]
impl PartialEq<HugePageMountSettings> for HugePageMountSettings
[src]
fn eq(&self, other: &HugePageMountSettings) -> bool
[src]
fn ne(&self, other: &HugePageMountSettings) -> bool
[src]
impl Default for HugePageMountSettings
[src]
impl Ord for HugePageMountSettings
[src]
fn cmp(&self, other: &HugePageMountSettings) -> Ordering
[src]
fn max(self, other: Self) -> Self
1.21.0[src]
Compares and returns the maximum of two values. Read more
fn min(self, other: Self) -> Self
1.21.0[src]
Compares and returns the minimum of two values. Read more
impl Hash for HugePageMountSettings
[src]
fn hash<__H: Hasher>(&self, state: &mut __H)
[src]
fn hash_slice<H>(data: &[Self], state: &mut H) where
H: Hasher,
1.3.0[src]
H: Hasher,
Feeds a slice of this type into the given [Hasher
]. Read more
impl Debug for HugePageMountSettings
[src]
impl Serialize for HugePageMountSettings
[src]
fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error> where
__S: Serializer,
[src]
__S: Serializer,
impl<'de> Deserialize<'de> for HugePageMountSettings where
HugePageMountSettings: Default,
[src]
HugePageMountSettings: Default,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error> where
__D: Deserializer<'de>,
[src]
__D: Deserializer<'de>,
Auto Trait Implementations
impl Send for HugePageMountSettings
impl Sync for HugePageMountSettings
Blanket Implementations
impl<T, U> Into for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
impl<T> From for T
[src]
impl<T, U> TryFrom for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = !
try_from
)The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T> Borrow for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T, U> TryInto for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
try_from
)The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> BorrowMut for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> DeserializeOwned for T where
T: Deserialize<'de>,
[src]
T: Deserialize<'de>,