pub struct DriverConfigBuilder { /* private fields */ }Expand description
Driver configuration builder Driver配置构建器
Provides a fluent API for constructing driver configurations. 提供用于构建driver配置的流畅API。
Implementations§
Source§impl DriverConfigBuilder
impl DriverConfigBuilder
Sourcepub fn entries(self, entries: u32) -> Self
pub fn entries(self, entries: u32) -> Self
Set the queue depth (will be rounded up to next power of 2) 设置队列深度(将向上舍入到下一个2的幂)
Sourcepub const fn submit_wait(self, wait: bool) -> Self
pub const fn submit_wait(self, wait: bool) -> Self
Enable or disable submit-wait mode 启用或禁用提交等待模式
Sourcepub const fn cpu_affinity(self, core: usize) -> Self
pub const fn cpu_affinity(self, core: usize) -> Self
Set CPU affinity for the driver thread 为driver线程设置CPU亲和性
Sourcepub const fn no_affinity(self) -> Self
pub const fn no_affinity(self) -> Self
Clear CPU affinity (no affinity) 清除CPU亲和性(无亲和性)
Sourcepub const fn defer_wakeup(self, defer: bool) -> Self
pub const fn defer_wakeup(self, defer: bool) -> Self
Enable or disable deferred task wake-up 启用或禁用延迟任务唤醒
Sourcepub const fn max_ops_per_fd(self, max: u32) -> Self
pub const fn max_ops_per_fd(self, max: u32) -> Self
Set maximum operations per file descriptor 设置每个文件描述符的最大操作数
Sourcepub const fn build(self) -> DriverConfig
pub const fn build(self) -> DriverConfig
Build the configuration 构建配置
Trait Implementations§
Source§impl Clone for DriverConfigBuilder
impl Clone for DriverConfigBuilder
Source§fn clone(&self) -> DriverConfigBuilder
fn clone(&self) -> DriverConfigBuilder
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for DriverConfigBuilder
impl Debug for DriverConfigBuilder
Auto Trait Implementations§
impl Freeze for DriverConfigBuilder
impl RefUnwindSafe for DriverConfigBuilder
impl Send for DriverConfigBuilder
impl Sync for DriverConfigBuilder
impl Unpin for DriverConfigBuilder
impl UnsafeUnpin for DriverConfigBuilder
impl UnwindSafe for DriverConfigBuilder
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more