very preliminary power savings working

This commit is contained in:
bunnie 2021-05-31 05:20:54 +08:00
parent 7c55925926
commit d9e56fd321
5 changed files with 19 additions and 19 deletions

View file

@ -3,7 +3,7 @@
<device schemaVersion="1.1" xmlns:xs="http://www.w3.org/2001/XMLSchema-instance" xs:noNamespaceSchemaLocation="CMSIS-SVD.xsd" > <device schemaVersion="1.1" xmlns:xs="http://www.w3.org/2001/XMLSchema-instance" xs:noNamespaceSchemaLocation="CMSIS-SVD.xsd" >
<vendor>litex</vendor> <vendor>litex</vendor>
<name>SOC</name> <name>SOC</name>
<description><![CDATA[Litex SoC 2021-05-30 22:41:49]]></description> <description><![CDATA[Litex SoC 2021-05-31 04:52:07]]></description>
<addressUnitBits>8</addressUnitBits> <addressUnitBits>8</addressUnitBits>
<width>32</width> <width>32</width>
@ -1185,10 +1185,10 @@ register to disable individual events.]]></description>
<register> <register>
<name>GIT_GITREV</name> <name>GIT_GITREV</name>
<description><![CDATA[First 32-bits of the git revision. This documentation was built from git rev <description><![CDATA[First 32-bits of the git revision. This documentation was built from git rev
``7393e50d``, so this value is 1939072269, which should be enough to check out ``ed015a96``, so this value is 3976288918, which should be enough to check out
the exact git version used to build this firmware.]]></description> the exact git version used to build this firmware.]]></description>
<addressOffset>0x0014</addressOffset> <addressOffset>0x0014</addressOffset>
<resetValue>0x7393e50d</resetValue> <resetValue>0xed015a96</resetValue>
<size>32</size> <size>32</size>
<fields> <fields>
<field> <field>
@ -1205,7 +1205,7 @@ the exact git version used to build this firmware.]]></description>
is ``1``, then the repository this was built from has one additional commit is ``1``, then the repository this was built from has one additional commit
beyond the tag indicated in `MAJOR`, `MINOR`, and `REVISION`.]]></description> beyond the tag indicated in `MAJOR`, `MINOR`, and `REVISION`.]]></description>
<addressOffset>0x0018</addressOffset> <addressOffset>0x0018</addressOffset>
<resetValue>0x18</resetValue> <resetValue>0x19</resetValue>
<size>32</size> <size>32</size>
<fields> <fields>
<field> <field>
@ -3284,7 +3284,7 @@ inject too fast.]]></description>
<name>SEED1</name> <name>SEED1</name>
<description><![CDATA[Bits 32-63 of `SEED_SEED`. Seed used for the build]]></description> <description><![CDATA[Bits 32-63 of `SEED_SEED`. Seed used for the build]]></description>
<addressOffset>0x0000</addressOffset> <addressOffset>0x0000</addressOffset>
<resetValue>0x4588f3a0</resetValue> <resetValue>0x1980d59a</resetValue>
<size>32</size> <size>32</size>
<fields> <fields>
<field> <field>
@ -3299,7 +3299,7 @@ inject too fast.]]></description>
<name>SEED0</name> <name>SEED0</name>
<description><![CDATA[Bits 0-31 of `SEED_SEED`.]]></description> <description><![CDATA[Bits 0-31 of `SEED_SEED`.]]></description>
<addressOffset>0x0004</addressOffset> <addressOffset>0x0004</addressOffset>
<resetValue>0x5eea589</resetValue> <resetValue>0x3d397cb2</resetValue>
<size>32</size> <size>32</size>
<fields> <fields>
<field> <field>

View file

@ -59,7 +59,7 @@ pub fn idle() -> bool {
// Issue `wfi`. This will return as soon as an external interrupt // Issue `wfi`. This will return as soon as an external interrupt
// is available. // is available.
if true { if false {
unsafe { riscv::asm::wfi() }; unsafe { riscv::asm::wfi() };
} else { } else {
wfi_kernel_csr.wfo(utra::wfi::IGNORE_LOCKED_IGNORE_LOCKED, 1); wfi_kernel_csr.wfo(utra::wfi::IGNORE_LOCKED_IGNORE_LOCKED, 1);

View file

@ -3,7 +3,7 @@
<device schemaVersion="1.1" xmlns:xs="http://www.w3.org/2001/XMLSchema-instance" xs:noNamespaceSchemaLocation="CMSIS-SVD.xsd" > <device schemaVersion="1.1" xmlns:xs="http://www.w3.org/2001/XMLSchema-instance" xs:noNamespaceSchemaLocation="CMSIS-SVD.xsd" >
<vendor>litex</vendor> <vendor>litex</vendor>
<name>SOC</name> <name>SOC</name>
<description><![CDATA[Litex SoC 2021-05-30 22:41:49]]></description> <description><![CDATA[Litex SoC 2021-05-31 04:52:07]]></description>
<addressUnitBits>8</addressUnitBits> <addressUnitBits>8</addressUnitBits>
<width>32</width> <width>32</width>
@ -1185,10 +1185,10 @@ register to disable individual events.]]></description>
<register> <register>
<name>GIT_GITREV</name> <name>GIT_GITREV</name>
<description><![CDATA[First 32-bits of the git revision. This documentation was built from git rev <description><![CDATA[First 32-bits of the git revision. This documentation was built from git rev
``7393e50d``, so this value is 1939072269, which should be enough to check out ``ed015a96``, so this value is 3976288918, which should be enough to check out
the exact git version used to build this firmware.]]></description> the exact git version used to build this firmware.]]></description>
<addressOffset>0x0014</addressOffset> <addressOffset>0x0014</addressOffset>
<resetValue>0x7393e50d</resetValue> <resetValue>0xed015a96</resetValue>
<size>32</size> <size>32</size>
<fields> <fields>
<field> <field>
@ -1205,7 +1205,7 @@ the exact git version used to build this firmware.]]></description>
is ``1``, then the repository this was built from has one additional commit is ``1``, then the repository this was built from has one additional commit
beyond the tag indicated in `MAJOR`, `MINOR`, and `REVISION`.]]></description> beyond the tag indicated in `MAJOR`, `MINOR`, and `REVISION`.]]></description>
<addressOffset>0x0018</addressOffset> <addressOffset>0x0018</addressOffset>
<resetValue>0x18</resetValue> <resetValue>0x19</resetValue>
<size>32</size> <size>32</size>
<fields> <fields>
<field> <field>
@ -3284,7 +3284,7 @@ inject too fast.]]></description>
<name>SEED1</name> <name>SEED1</name>
<description><![CDATA[Bits 32-63 of `SEED_SEED`. Seed used for the build]]></description> <description><![CDATA[Bits 32-63 of `SEED_SEED`. Seed used for the build]]></description>
<addressOffset>0x0000</addressOffset> <addressOffset>0x0000</addressOffset>
<resetValue>0x4588f3a0</resetValue> <resetValue>0x1980d59a</resetValue>
<size>32</size> <size>32</size>
<fields> <fields>
<field> <field>
@ -3299,7 +3299,7 @@ inject too fast.]]></description>
<name>SEED0</name> <name>SEED0</name>
<description><![CDATA[Bits 0-31 of `SEED_SEED`.]]></description> <description><![CDATA[Bits 0-31 of `SEED_SEED`.]]></description>
<addressOffset>0x0004</addressOffset> <addressOffset>0x0004</addressOffset>
<resetValue>0x5eea589</resetValue> <resetValue>0x3d397cb2</resetValue>
<size>32</size> <size>32</size>
<fields> <fields>
<field> <field>

Binary file not shown.

View file

@ -3,7 +3,7 @@
<device schemaVersion="1.1" xmlns:xs="http://www.w3.org/2001/XMLSchema-instance" xs:noNamespaceSchemaLocation="CMSIS-SVD.xsd" > <device schemaVersion="1.1" xmlns:xs="http://www.w3.org/2001/XMLSchema-instance" xs:noNamespaceSchemaLocation="CMSIS-SVD.xsd" >
<vendor>litex</vendor> <vendor>litex</vendor>
<name>SOC</name> <name>SOC</name>
<description><![CDATA[Litex SoC 2021-05-30 22:41:49]]></description> <description><![CDATA[Litex SoC 2021-05-31 04:52:07]]></description>
<addressUnitBits>8</addressUnitBits> <addressUnitBits>8</addressUnitBits>
<width>32</width> <width>32</width>
@ -1185,10 +1185,10 @@ register to disable individual events.]]></description>
<register> <register>
<name>GIT_GITREV</name> <name>GIT_GITREV</name>
<description><![CDATA[First 32-bits of the git revision. This documentation was built from git rev <description><![CDATA[First 32-bits of the git revision. This documentation was built from git rev
``7393e50d``, so this value is 1939072269, which should be enough to check out ``ed015a96``, so this value is 3976288918, which should be enough to check out
the exact git version used to build this firmware.]]></description> the exact git version used to build this firmware.]]></description>
<addressOffset>0x0014</addressOffset> <addressOffset>0x0014</addressOffset>
<resetValue>0x7393e50d</resetValue> <resetValue>0xed015a96</resetValue>
<size>32</size> <size>32</size>
<fields> <fields>
<field> <field>
@ -1205,7 +1205,7 @@ the exact git version used to build this firmware.]]></description>
is ``1``, then the repository this was built from has one additional commit is ``1``, then the repository this was built from has one additional commit
beyond the tag indicated in `MAJOR`, `MINOR`, and `REVISION`.]]></description> beyond the tag indicated in `MAJOR`, `MINOR`, and `REVISION`.]]></description>
<addressOffset>0x0018</addressOffset> <addressOffset>0x0018</addressOffset>
<resetValue>0x18</resetValue> <resetValue>0x19</resetValue>
<size>32</size> <size>32</size>
<fields> <fields>
<field> <field>
@ -3284,7 +3284,7 @@ inject too fast.]]></description>
<name>SEED1</name> <name>SEED1</name>
<description><![CDATA[Bits 32-63 of `SEED_SEED`. Seed used for the build]]></description> <description><![CDATA[Bits 32-63 of `SEED_SEED`. Seed used for the build]]></description>
<addressOffset>0x0000</addressOffset> <addressOffset>0x0000</addressOffset>
<resetValue>0x4588f3a0</resetValue> <resetValue>0x1980d59a</resetValue>
<size>32</size> <size>32</size>
<fields> <fields>
<field> <field>
@ -3299,7 +3299,7 @@ inject too fast.]]></description>
<name>SEED0</name> <name>SEED0</name>
<description><![CDATA[Bits 0-31 of `SEED_SEED`.]]></description> <description><![CDATA[Bits 0-31 of `SEED_SEED`.]]></description>
<addressOffset>0x0004</addressOffset> <addressOffset>0x0004</addressOffset>
<resetValue>0x5eea589</resetValue> <resetValue>0x3d397cb2</resetValue>
<size>32</size> <size>32</size>
<fields> <fields>
<field> <field>