OSDN Git Service

hw/intc: sifive_plic: Cleanup remaining functions
authorAlistair Francis <alistair.francis@wdc.com>
Wed, 5 Jan 2022 21:39:33 +0000 (07:39 +1000)
committerAlistair Francis <alistair.francis@wdc.com>
Sat, 8 Jan 2022 05:46:09 +0000 (15:46 +1000)
commit41bcc44a2517b5775a94c5c9b2a1014be8b19235
tree54f4afb641bd6dcf35718d24c5315c0861c36ca3
parentb79e1c76c02dd01a203028c4482d975480b97f16
hw/intc: sifive_plic: Cleanup remaining functions

We can remove the original sifive_plic_irqs_pending() function and
instead just use the sifive_plic_claim() function (renamed to
sifive_plic_claimed()) to determine if any interrupts are pending.

This requires move the side effects outside of sifive_plic_claimed(),
but as they are only invoked once that isn't a problem.

We have also removed all of the old #ifdef debugging logs, so let's
cleanup the last remaining debug function while we are here.

Signed-off-by: Alistair Francis <alistair.francis@wdc.com>
Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
Message-Id: <20220105213937.1113508-5-alistair.francis@opensource.wdc.com>
hw/intc/sifive_plic.c