<feed xmlns='http://www.w3.org/2005/Atom'>
<title>opensbi.git/platform/generic, branch v1.0</title>
<subtitle>Unnamed repository; edit this file 'description' to name the repository.</subtitle>
<id>http://cgit.235523.xyz/opensbi.git/atom/platform/generic?h=v1.0</id>
<link rel='self' href='http://cgit.235523.xyz/opensbi.git/atom/platform/generic?h=v1.0'/>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/opensbi.git/'/>
<updated>2021-12-02T03:20:36Z</updated>
<entry>
<title>lib: sbi: Improve fatal error handling</title>
<updated>2021-12-02T03:20:36Z</updated>
<author>
<name>Jessica Clarke</name>
<email>jrtc27@jrtc27.com</email>
</author>
<published>2021-11-21T17:30:22Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/opensbi.git/commit/?id=14faee6916bc973b9fdb816c5f4a45096e3f645a'/>
<id>urn:sha1:14faee6916bc973b9fdb816c5f4a45096e3f645a</id>
<content type='text'>
BUG and BUG_ON are not informative and are rather lazy interfaces, only
telling the user that something went wrong in a given function, but not
what, requiring the user to find the sources corresponding to their
firmware (which may not be available) and figure out how that BUG(_ON)
was hit. Even SBI_ASSERT in its current form, which does include the
condition that triggered it in the output, isn't necessarily very
informative. In some cases, the error may be fixable by the user, but
they need to know the problem in order to have any hope of fixing it.
It's also a nuisance for developers, whose development trees may have
changed significantly since the release in question being used, and so
line numbers can make it harder for them to understand which error case
a user has hit.

This patch introduces a new sbi_panic function which is printf-like,
allowing detailed error messages to be printed to the console. BUG and
BUG_ON are removed, since the former is just a worse form of sbi_panic
and the latter is a worse version of SBI_ASSERT. Finally, SBI_ASSERT is
augmented to take a set of arguments to pass to sbi_panic on failure,
used like so (sbi_boot_print_hart's current error case, which currently
manually calls sbi_printf and sbi_hart_hang):

  SBI_ASSERT(xlen &gt;= 1, ("Error %d getting MISA XLEN\n", xlen));

The existing users of BUG are replaced with calls to sbi_panic along
with informative error messages. BUG_ON and SBI_ASSERT were unused (and,
in the case of SBI_ASSERT, remain unused).

Many existing users of sbi_hart_hang should be converted to use either
sbi_panic or SBI_ASSERT after this commit.

Signed-off-by: Jessica Clarke &lt;jrtc27@jrtc27.com&gt;
Reviewed-by: Anup Patel &lt;anup.patel@wdc.com&gt;
Reviewed-by: Xiang W &lt;wxjstz@126.com&gt;
Reviewed-by: Atish Patra &lt;atishp@rivosinc.com&gt;
</content>
</entry>
<entry>
<title>platform: sifive_fu740: add platform reset driver</title>
<updated>2021-11-12T04:59:20Z</updated>
<author>
<name>Nikita Shubin</name>
<email>n.shubin@yadro.com</email>
</author>
<published>2021-11-10T09:42:30Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/opensbi.git/commit/?id=f3744967c6b595c0caba164468b4b32b9c027dfd'/>
<id>urn:sha1:f3744967c6b595c0caba164468b4b32b9c027dfd</id>
<content type='text'>
da9063 PMIC can be used to reset/shutdown the
Sifive Unmatched board.

shutdown is done simply by writing SHUTDOWN bit to
DA9063_REG_CONTROL_F register.

reset via setting WAKEUP bit in DA9063_REG_CONTROL_F
register followed by masking POWER and POWER1 domains
and setting STANDBY bit in DA9063_REG_CONTROL_A,
originally discovered by Alexandre Ghiti on linux-riscv
maillists.

Tested-by: Heinrich Schuchardt &lt;heinrich.schuchardt@canonical.com&gt;
Reviewed-by: Alexandre Ghiti &lt;alexandre.ghiti@canonical.com&gt;
Tested-by: Alexandre Ghiti &lt;alexandre.ghiti@canonical.com&gt;
Signed-off-by: Nikita Shubin &lt;n.shubin@yadro.com&gt;
</content>
</entry>
<entry>
<title>platform: generic: move fdt_reset_init to final_init</title>
<updated>2021-11-08T05:12:05Z</updated>
<author>
<name>Heinrich Schuchardt</name>
<email>heinrich.schuchardt@canonical.com</email>
</author>
<published>2021-11-06T09:54:50Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/opensbi.git/commit/?id=57f094e67e0642a16889e9bce64266a4e378683b'/>
<id>urn:sha1:57f094e67e0642a16889e9bce64266a4e378683b</id>
<content type='text'>
Move the fdt_reset_init() invocation from generic_early_init() to
generic_final_init(). This allows to print error messages.

Ignore the return value of fdt_reset_init() as we should not stop booting
due to failure to initialize reset drivers.

Signed-off-by: Heinrich Schuchardt &lt;heinrich.schuchardt@canonical.com&gt;
Reviewed-by: Dong Du &lt;Dd_nirvana@sjtu.edu.cn&gt;
Reviewed-by: Anup Patel &lt;anup.patel@wdc.com&gt;
</content>
</entry>
<entry>
<title>include: sbi_utils: Introduce an helper to get fdt base address</title>
<updated>2021-11-02T05:53:16Z</updated>
<author>
<name>Alexandre Ghiti</name>
<email>alexandre.ghiti@canonical.com</email>
</author>
<published>2021-10-27T07:43:36Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/opensbi.git/commit/?id=c891acca172dfc60719419e19338508a83d97931'/>
<id>urn:sha1:c891acca172dfc60719419e19338508a83d97931</id>
<content type='text'>
This simply adds an helper to get fdt address which is more explicit than
sbi_scratch_thishart_arg1_ptr.

Signed-off-by: Alexandre Ghiti &lt;alexandre.ghiti@canonical.com&gt;
Reviewed-by: Xiang W &lt;wxjstz@126.com&gt;
Reviewed-by: Anup Patel &lt;anup.patel@wdc.com&gt;
</content>
</entry>
<entry>
<title>generic: fu740: add workaround for CIP-1200 errata</title>
<updated>2021-07-27T09:59:59Z</updated>
<author>
<name>David Abdurachmanov</name>
<email>david.abdurachmanov@sifive.com</email>
</author>
<published>2021-07-20T17:02:39Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/opensbi.git/commit/?id=217d5e488033c7337b80794563b2f13e29b9f88d'/>
<id>urn:sha1:217d5e488033c7337b80794563b2f13e29b9f88d</id>
<content type='text'>
Instruction TLB can fail to respect a non-global SFENCE thus we need to
flush the TLB using SFENCE.VMA x0, x0

See full description of CIP-1200 in Errata_FU740-C000_20210205 from
https://www.sifive.com/boards/hifive-unmatched

Signed-off-by: David Abdurachmanov &lt;david.abdurachmanov@sifive.com&gt;
Signed-off-by: Heinrich Schuchardt &lt;heinrich.schuchardt@canonical.com&gt;
</content>
</entry>
<entry>
<title>platform: generic: Add PMU support</title>
<updated>2021-07-11T05:09:42Z</updated>
<author>
<name>Atish Patra</name>
<email>atish.patra@wdc.com</email>
</author>
<published>2021-07-10T16:18:16Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/opensbi.git/commit/?id=0e12aa8dee632f67dbb458aa5d3ee38f7db4e70c'/>
<id>urn:sha1:0e12aa8dee632f67dbb458aa5d3ee38f7db4e70c</id>
<content type='text'>
Add PMU support for generic platform. Generic platform solely relies on
the device tree to parse all pmu related information. If any event is
not described in device tree, generic platform will not support it.

Reviewed-by: Anup Patel &lt;anup.patel@wdc.com&gt;
Signed-off-by: Atish Patra &lt;atish.patra@wdc.com&gt;
</content>
</entry>
<entry>
<title>platform: generic: Terminate platform.name with null</title>
<updated>2021-07-06T08:51:53Z</updated>
<author>
<name>Bin Meng</name>
<email>bmeng.cn@gmail.com</email>
</author>
<published>2021-07-04T15:01:13Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/opensbi.git/commit/?id=17e23b678dac2e4579e714705cec137b351f7e9b'/>
<id>urn:sha1:17e23b678dac2e4579e714705cec137b351f7e9b</id>
<content type='text'>
fw_platform_init() fills platform.name without considering the
ending null character. Fix it.

Signed-off-by: Bin Meng &lt;bmeng.cn@gmail.com&gt;
Reviewed-by: Anup Patel &lt;anup.patel@wdc.com&gt;
</content>
</entry>
<entry>
<title>lib: sbi: Simplify system reset platform operations</title>
<updated>2021-04-28T11:55:00Z</updated>
<author>
<name>Anup Patel</name>
<email>anup.patel@wdc.com</email>
</author>
<published>2021-04-22T06:23:32Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/opensbi.git/commit/?id=043d088e3964ec64b091f739e2282f53f7d264fb'/>
<id>urn:sha1:043d088e3964ec64b091f739e2282f53f7d264fb</id>
<content type='text'>
Instead of having system_reset_check() and system_reset() callbacks
in platform operations, it will be much simpler for reset driver to
directly register these operations as a device to the sbi_system
implementation.

Signed-off-by: Anup Patel &lt;anup.patel@wdc.com&gt;
Reviewed-by: Alistair Francis &lt;alistair.francis@wdc.com&gt;
</content>
</entry>
<entry>
<title>lib: sbi: Simplify ipi platform operations</title>
<updated>2021-04-28T11:33:31Z</updated>
<author>
<name>Anup Patel</name>
<email>anup.patel@wdc.com</email>
</author>
<published>2021-04-22T04:57:15Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/opensbi.git/commit/?id=dc39c7b630a607b96c25f8ea50f0bb1af619928a'/>
<id>urn:sha1:dc39c7b630a607b96c25f8ea50f0bb1af619928a</id>
<content type='text'>
Instead of having ipi_send() and ipi_clear() callbacks in
platform operations, it will be much simpler for ipi driver
to directly register these operations as a device to sbi_ipi
implementation.

Signed-off-by: Anup Patel &lt;anup.patel@wdc.com&gt;
Reviewed-by: Alistair Francis &lt;alistair.francis@wdc.com&gt;
</content>
</entry>
<entry>
<title>lib: sbi: Simplify timer platform operations</title>
<updated>2021-04-28T11:30:49Z</updated>
<author>
<name>Anup Patel</name>
<email>anup.patel@wdc.com</email>
</author>
<published>2021-04-21T16:34:17Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/opensbi.git/commit/?id=559a8f1d3be3210d4903c0db54c2d36e2f8d6ad4'/>
<id>urn:sha1:559a8f1d3be3210d4903c0db54c2d36e2f8d6ad4</id>
<content type='text'>
Instead of having timer_value(), timer_event_start(), and
timer_event_stop() callbacks in platform operations, it will
be much simpler for timer driver to directly register these
operations as device to the sbi_timer implementation.

Signed-off-by: Anup Patel &lt;anup.patel@wdc.com&gt;
Reviewed-by: Alistair Francis &lt;alistair.francis@wdc.com&gt;
</content>
</entry>
</feed>
