diff options
author | Cédric Le Goater <clg@kaod.org> | 2017-11-10 15:20:08 +0000 |
---|---|---|
committer | David Gibson <david@gibson.dropbear.id.au> | 2017-12-15 09:49:23 +1100 |
commit | e0f7110acaaa222591e5f025953934c70c5ae15f (patch) | |
tree | 4324831abca9f468557376cc4745644980e32016 /hw/intc/xics_spapr.c | |
parent | c4a2e3a9709aa7c84def7bc4bfbdcaf37ccf7527 (diff) |
ppc/xics: remove useless if condition
The previous code section uses a 'first < 0' test and returns. Therefore,
there is no need to test the 'first' variable against '>= 0' afterwards.
Signed-off-by: Cédric Le Goater <clg@kaod.org>
Reviewed-by: Greg Kurz <groug@kaod.org>
Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
Diffstat (limited to 'hw/intc/xics_spapr.c')
-rw-r--r-- | hw/intc/xics_spapr.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/hw/intc/xics_spapr.c b/hw/intc/xics_spapr.c index d98ea8b130..e8c0a1b3e9 100644 --- a/hw/intc/xics_spapr.c +++ b/hw/intc/xics_spapr.c @@ -329,10 +329,8 @@ int spapr_ics_alloc_block(ICSState *ics, int num, bool lsi, return -1; } - if (first >= 0) { - for (i = first; i < first + num; ++i) { - ics_set_irq_type(ics, i, lsi); - } + for (i = first; i < first + num; ++i) { + ics_set_irq_type(ics, i, lsi); } first += ics->offset; |