lib: sbi: add priority for reset handler
authorNikita Shubin <n.shubin@yadro.com>
Fri, 1 Oct 2021 08:31:17 +0000 (11:31 +0300)
committerAnup Patel <anup@brainfault.org>
Mon, 11 Oct 2021 05:02:26 +0000 (10:32 +0530)
commit9283d503bd260a972f7e7ac2d895f7cfb152ef77
tree9ec4124ac004ed273615f6184f95e0062843eca4
parent516161c46f0d3c73bf6a57e551d6e2489912fc03
lib: sbi: add priority for reset handler

Let's make system_reset_check returning priority instead of only
true/false. In that case 0 - means not supported, and anything above
means priority that makes existing reset handlers being used in first
place, unless it is decided to lower their priority.

The handler with the most priority wins.

Signed-off-by: Nikita Shubin <n.shubin@yadro.com>
Reviewed-by: Anup Patel <anup.patel@wdc.com>
lib/sbi/sbi_system.c