Skip to content

Commit

Permalink
microblaze: intc: Refactor DT sanity check
Browse files Browse the repository at this point in the history
Avoid funky casts and arithmetic.

Signed-off-by: Soren Brinkmann <soren.brinkmann@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
  • Loading branch information
Soren Brinkmann authored and Michal Simek committed Jan 8, 2015
1 parent 2c80a07 commit d50466c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion arch/microblaze/kernel/intc.c
Original file line number Diff line number Diff line change
Expand Up @@ -157,7 +157,7 @@ static int __init xilinx_intc_of_init(struct device_node *intc,
return ret;
}

if (intr_mask > (u32)((1ULL << nr_irq) - 1))
if (intr_mask >> nr_irq)
pr_info(" ERROR: Mismatch in kind-of-intr param\n");

pr_info("%s: num_irq=%d, edge=0x%x\n",
Expand Down

0 comments on commit d50466c

Please sign in to comment.