Run with updated version of rustfmt
This commit is contained in:
@ -2,18 +2,12 @@ use vcell::VolatileCell;
|
||||
#[doc = r" Register block"]
|
||||
#[repr(C)]
|
||||
pub struct RegisterBlock {
|
||||
#[doc = "0x00 - SMC Version ID Register"]
|
||||
pub verid: VERID,
|
||||
#[doc = "0x04 - SMC Parameter Register"]
|
||||
pub param: PARAM,
|
||||
#[doc = "0x08 - Power Mode Protection register"]
|
||||
pub pmprot: PMPROT,
|
||||
#[doc = "0x0c - Power Mode Control register"]
|
||||
pub pmctrl: PMCTRL,
|
||||
#[doc = "0x10 - Stop Control Register"]
|
||||
pub stopctrl: STOPCTRL,
|
||||
#[doc = "0x14 - Power Mode Status register"]
|
||||
pub pmstat: PMSTAT,
|
||||
#[doc = "0x00 - SMC Version ID Register"] pub verid: VERID,
|
||||
#[doc = "0x04 - SMC Parameter Register"] pub param: PARAM,
|
||||
#[doc = "0x08 - Power Mode Protection register"] pub pmprot: PMPROT,
|
||||
#[doc = "0x0c - Power Mode Control register"] pub pmctrl: PMCTRL,
|
||||
#[doc = "0x10 - Stop Control Register"] pub stopctrl: STOPCTRL,
|
||||
#[doc = "0x14 - Power Mode Status register"] pub pmstat: PMSTAT,
|
||||
}
|
||||
#[doc = "SMC Version ID Register"]
|
||||
pub struct VERID {
|
||||
|
@ -6,16 +6,16 @@ impl super::PARAM {
|
||||
#[doc = r" Reads the contents of the register"]
|
||||
#[inline]
|
||||
pub fn read(&self) -> R {
|
||||
R { bits: self.register.get() }
|
||||
R {
|
||||
bits: self.register.get(),
|
||||
}
|
||||
}
|
||||
}
|
||||
#[doc = "Possible values of the field `EHSRUN`"]
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
pub enum EHSRUNR {
|
||||
#[doc = "The feature is not available."]
|
||||
_0,
|
||||
#[doc = "The feature is available."]
|
||||
_1,
|
||||
#[doc = "The feature is not available."] _0,
|
||||
#[doc = "The feature is available."] _1,
|
||||
}
|
||||
impl EHSRUNR {
|
||||
#[doc = r" Returns `true` if the bit is clear (0)"]
|
||||
@ -59,10 +59,8 @@ impl EHSRUNR {
|
||||
#[doc = "Possible values of the field `ELLS`"]
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
pub enum ELLSR {
|
||||
#[doc = "The feature is not available."]
|
||||
_0,
|
||||
#[doc = "The feature is available."]
|
||||
_1,
|
||||
#[doc = "The feature is not available."] _0,
|
||||
#[doc = "The feature is available."] _1,
|
||||
}
|
||||
impl ELLSR {
|
||||
#[doc = r" Returns `true` if the bit is clear (0)"]
|
||||
@ -106,10 +104,8 @@ impl ELLSR {
|
||||
#[doc = "Possible values of the field `ELLS2`"]
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
pub enum ELLS2R {
|
||||
#[doc = "The feature is not available."]
|
||||
_0,
|
||||
#[doc = "The feature is available."]
|
||||
_1,
|
||||
#[doc = "The feature is not available."] _0,
|
||||
#[doc = "The feature is available."] _1,
|
||||
}
|
||||
impl ELLS2R {
|
||||
#[doc = r" Returns `true` if the bit is clear (0)"]
|
||||
@ -153,10 +149,8 @@ impl ELLS2R {
|
||||
#[doc = "Possible values of the field `EVLLS0`"]
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
pub enum EVLLS0R {
|
||||
#[doc = "The feature is not available."]
|
||||
_0,
|
||||
#[doc = "The feature is available."]
|
||||
_1,
|
||||
#[doc = "The feature is not available."] _0,
|
||||
#[doc = "The feature is available."] _1,
|
||||
}
|
||||
impl EVLLS0R {
|
||||
#[doc = r" Returns `true` if the bit is clear (0)"]
|
||||
|
@ -22,7 +22,9 @@ impl super::PMCTRL {
|
||||
#[doc = r" Reads the contents of the register"]
|
||||
#[inline]
|
||||
pub fn read(&self) -> R {
|
||||
R { bits: self.register.get() }
|
||||
R {
|
||||
bits: self.register.get(),
|
||||
}
|
||||
}
|
||||
#[doc = r" Writes to the register"]
|
||||
#[inline]
|
||||
@ -43,14 +45,10 @@ impl super::PMCTRL {
|
||||
#[doc = "Possible values of the field `STOPM`"]
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
pub enum STOPMR {
|
||||
#[doc = "Normal Stop (STOP)"]
|
||||
_000,
|
||||
#[doc = "Very-Low-Power Stop (VLPS)"]
|
||||
_010,
|
||||
#[doc = "Reseved"]
|
||||
_110,
|
||||
#[doc = r" Reserved"]
|
||||
_Reserved(u8),
|
||||
#[doc = "Normal Stop (STOP)"] _000,
|
||||
#[doc = "Very-Low-Power Stop (VLPS)"] _010,
|
||||
#[doc = "Reseved"] _110,
|
||||
#[doc = r" Reserved"] _Reserved(u8),
|
||||
}
|
||||
impl STOPMR {
|
||||
#[doc = r" Value of the field as raw bits"]
|
||||
@ -93,10 +91,8 @@ impl STOPMR {
|
||||
#[doc = "Possible values of the field `VLPSA`"]
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
pub enum VLPSAR {
|
||||
#[doc = "The previous stop mode entry was successful."]
|
||||
_0,
|
||||
#[doc = "The previous stop mode entry was aborted."]
|
||||
_1,
|
||||
#[doc = "The previous stop mode entry was successful."] _0,
|
||||
#[doc = "The previous stop mode entry was aborted."] _1,
|
||||
}
|
||||
impl VLPSAR {
|
||||
#[doc = r" Returns `true` if the bit is clear (0)"]
|
||||
@ -140,14 +136,10 @@ impl VLPSAR {
|
||||
#[doc = "Possible values of the field `RUNM`"]
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
pub enum RUNMR {
|
||||
#[doc = "Normal Run mode (RUN)"]
|
||||
_00,
|
||||
#[doc = "Very-Low-Power Run mode (VLPR)"]
|
||||
_10,
|
||||
#[doc = "High Speed Run mode (HSRUN)"]
|
||||
_11,
|
||||
#[doc = r" Reserved"]
|
||||
_Reserved(u8),
|
||||
#[doc = "Normal Run mode (RUN)"] _00,
|
||||
#[doc = "Very-Low-Power Run mode (VLPR)"] _10,
|
||||
#[doc = "High Speed Run mode (HSRUN)"] _11,
|
||||
#[doc = r" Reserved"] _Reserved(u8),
|
||||
}
|
||||
impl RUNMR {
|
||||
#[doc = r" Value of the field as raw bits"]
|
||||
@ -189,12 +181,9 @@ impl RUNMR {
|
||||
}
|
||||
#[doc = "Values that can be written to the field `STOPM`"]
|
||||
pub enum STOPMW {
|
||||
#[doc = "Normal Stop (STOP)"]
|
||||
_000,
|
||||
#[doc = "Very-Low-Power Stop (VLPS)"]
|
||||
_010,
|
||||
#[doc = "Reseved"]
|
||||
_110,
|
||||
#[doc = "Normal Stop (STOP)"] _000,
|
||||
#[doc = "Very-Low-Power Stop (VLPS)"] _010,
|
||||
#[doc = "Reseved"] _110,
|
||||
}
|
||||
impl STOPMW {
|
||||
#[allow(missing_docs)]
|
||||
@ -245,12 +234,9 @@ impl<'a> _STOPMW<'a> {
|
||||
}
|
||||
#[doc = "Values that can be written to the field `RUNM`"]
|
||||
pub enum RUNMW {
|
||||
#[doc = "Normal Run mode (RUN)"]
|
||||
_00,
|
||||
#[doc = "Very-Low-Power Run mode (VLPR)"]
|
||||
_10,
|
||||
#[doc = "High Speed Run mode (HSRUN)"]
|
||||
_11,
|
||||
#[doc = "Normal Run mode (RUN)"] _00,
|
||||
#[doc = "Very-Low-Power Run mode (VLPR)"] _10,
|
||||
#[doc = "High Speed Run mode (HSRUN)"] _11,
|
||||
}
|
||||
impl RUNMW {
|
||||
#[allow(missing_docs)]
|
||||
|
@ -22,7 +22,9 @@ impl super::PMPROT {
|
||||
#[doc = r" Reads the contents of the register"]
|
||||
#[inline]
|
||||
pub fn read(&self) -> R {
|
||||
R { bits: self.register.get() }
|
||||
R {
|
||||
bits: self.register.get(),
|
||||
}
|
||||
}
|
||||
#[doc = r" Writes to the register"]
|
||||
#[inline]
|
||||
@ -43,10 +45,8 @@ impl super::PMPROT {
|
||||
#[doc = "Possible values of the field `AVLP`"]
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
pub enum AVLPR {
|
||||
#[doc = "VLPR and VLPS are not allowed."]
|
||||
_0,
|
||||
#[doc = "VLPR and VLPS are allowed."]
|
||||
_1,
|
||||
#[doc = "VLPR and VLPS are not allowed."] _0,
|
||||
#[doc = "VLPR and VLPS are allowed."] _1,
|
||||
}
|
||||
impl AVLPR {
|
||||
#[doc = r" Returns `true` if the bit is clear (0)"]
|
||||
@ -90,10 +90,8 @@ impl AVLPR {
|
||||
#[doc = "Possible values of the field `AHSRUN`"]
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
pub enum AHSRUNR {
|
||||
#[doc = "HSRUN is not allowed"]
|
||||
_0,
|
||||
#[doc = "HSRUN is allowed"]
|
||||
_1,
|
||||
#[doc = "HSRUN is not allowed"] _0,
|
||||
#[doc = "HSRUN is allowed"] _1,
|
||||
}
|
||||
impl AHSRUNR {
|
||||
#[doc = r" Returns `true` if the bit is clear (0)"]
|
||||
@ -136,10 +134,8 @@ impl AHSRUNR {
|
||||
}
|
||||
#[doc = "Values that can be written to the field `AVLP`"]
|
||||
pub enum AVLPW {
|
||||
#[doc = "VLPR and VLPS are not allowed."]
|
||||
_0,
|
||||
#[doc = "VLPR and VLPS are allowed."]
|
||||
_1,
|
||||
#[doc = "VLPR and VLPS are not allowed."] _0,
|
||||
#[doc = "VLPR and VLPS are allowed."] _1,
|
||||
}
|
||||
impl AVLPW {
|
||||
#[allow(missing_docs)]
|
||||
@ -194,10 +190,8 @@ impl<'a> _AVLPW<'a> {
|
||||
}
|
||||
#[doc = "Values that can be written to the field `AHSRUN`"]
|
||||
pub enum AHSRUNW {
|
||||
#[doc = "HSRUN is not allowed"]
|
||||
_0,
|
||||
#[doc = "HSRUN is allowed"]
|
||||
_1,
|
||||
#[doc = "HSRUN is not allowed"] _0,
|
||||
#[doc = "HSRUN is allowed"] _1,
|
||||
}
|
||||
impl AHSRUNW {
|
||||
#[allow(missing_docs)]
|
||||
|
@ -6,7 +6,9 @@ impl super::PMSTAT {
|
||||
#[doc = r" Reads the contents of the register"]
|
||||
#[inline]
|
||||
pub fn read(&self) -> R {
|
||||
R { bits: self.register.get() }
|
||||
R {
|
||||
bits: self.register.get(),
|
||||
}
|
||||
}
|
||||
}
|
||||
#[doc = r" Value of the field"]
|
||||
|
@ -22,7 +22,9 @@ impl super::STOPCTRL {
|
||||
#[doc = r" Reads the contents of the register"]
|
||||
#[inline]
|
||||
pub fn read(&self) -> R {
|
||||
R { bits: self.register.get() }
|
||||
R {
|
||||
bits: self.register.get(),
|
||||
}
|
||||
}
|
||||
#[doc = r" Writes to the register"]
|
||||
#[inline]
|
||||
@ -43,12 +45,9 @@ impl super::STOPCTRL {
|
||||
#[doc = "Possible values of the field `STOPO`"]
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
pub enum STOPOR {
|
||||
#[doc = "STOP1 - Stop with both system and bus clocks disabled"]
|
||||
_01,
|
||||
#[doc = "STOP2 - Stop with system clock disabled and bus clock enabled"]
|
||||
_10,
|
||||
#[doc = r" Reserved"]
|
||||
_Reserved(u8),
|
||||
#[doc = "STOP1 - Stop with both system and bus clocks disabled"] _01,
|
||||
#[doc = "STOP2 - Stop with system clock disabled and bus clock enabled"] _10,
|
||||
#[doc = r" Reserved"] _Reserved(u8),
|
||||
}
|
||||
impl STOPOR {
|
||||
#[doc = r" Value of the field as raw bits"]
|
||||
@ -83,10 +82,8 @@ impl STOPOR {
|
||||
}
|
||||
#[doc = "Values that can be written to the field `STOPO`"]
|
||||
pub enum STOPOW {
|
||||
#[doc = "STOP1 - Stop with both system and bus clocks disabled"]
|
||||
_01,
|
||||
#[doc = "STOP2 - Stop with system clock disabled and bus clock enabled"]
|
||||
_10,
|
||||
#[doc = "STOP1 - Stop with both system and bus clocks disabled"] _01,
|
||||
#[doc = "STOP2 - Stop with system clock disabled and bus clock enabled"] _10,
|
||||
}
|
||||
impl STOPOW {
|
||||
#[allow(missing_docs)]
|
||||
|
@ -6,16 +6,16 @@ impl super::VERID {
|
||||
#[doc = r" Reads the contents of the register"]
|
||||
#[inline]
|
||||
pub fn read(&self) -> R {
|
||||
R { bits: self.register.get() }
|
||||
R {
|
||||
bits: self.register.get(),
|
||||
}
|
||||
}
|
||||
}
|
||||
#[doc = "Possible values of the field `FEATURE`"]
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
pub enum FEATURER {
|
||||
#[doc = "Standard features implemented"]
|
||||
_0,
|
||||
#[doc = r" Reserved"]
|
||||
_Reserved(u16),
|
||||
#[doc = "Standard features implemented"] _0,
|
||||
#[doc = r" Reserved"] _Reserved(u16),
|
||||
}
|
||||
impl FEATURER {
|
||||
#[doc = r" Value of the field as raw bits"]
|
||||
|
Reference in New Issue
Block a user