nrf/qpsi: make config non_exhaustive
This commit is contained in:
@ -36,6 +36,7 @@ pub struct DeepPowerDownConfig {
|
||||
pub exit_time: u16,
|
||||
}
|
||||
|
||||
#[non_exhaustive]
|
||||
pub struct Config {
|
||||
pub xip_offset: u32,
|
||||
pub read_opcode: ReadOpcode,
|
||||
@ -44,6 +45,18 @@ pub struct Config {
|
||||
pub deep_power_down: Option<DeepPowerDownConfig>,
|
||||
}
|
||||
|
||||
impl Default for Config {
|
||||
fn default() -> Self {
|
||||
Self {
|
||||
read_opcode: ReadOpcode::READ4IO,
|
||||
write_opcode: WriteOpcode::PP4IO,
|
||||
xip_offset: 0,
|
||||
write_page_size: WritePageSize::_256BYTES,
|
||||
deep_power_down: None,
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
pub struct Qspi<'d, T: Instance> {
|
||||
peri: T,
|
||||
irq: T::Interrupt,
|
||||
|
Reference in New Issue
Block a user