Skip to content

Commit

Permalink
irqchip/crossbar: Fix incorrect type of local variables
Browse files Browse the repository at this point in the history
The max and entry variables are unsigned according to the dt-bindings.
Fix following 3 sparse issues (-Wtypesign):

  drivers/irqchip/irq-crossbar.c:222:52: warning: incorrect type in argument 3 (different signedness)
  drivers/irqchip/irq-crossbar.c:222:52:    expected unsigned int [usertype] *out_value
  drivers/irqchip/irq-crossbar.c:222:52:    got int *<noident>

  drivers/irqchip/irq-crossbar.c:245:56: warning: incorrect type in argument 4 (different signedness)
  drivers/irqchip/irq-crossbar.c:245:56:    expected unsigned int [usertype] *out_value
  drivers/irqchip/irq-crossbar.c:245:56:    got int *<noident>

  drivers/irqchip/irq-crossbar.c:263:56: warning: incorrect type in argument 4 (different signedness)
  drivers/irqchip/irq-crossbar.c:263:56:    expected unsigned int [usertype] *out_value
  drivers/irqchip/irq-crossbar.c:263:56:    got int *<noident>

Signed-off-by: Franck Demathieu <fdemathieu@gmail.com>
Signed-off-by: Marc Zyngier <marc.zyngier@arm.com>
  • Loading branch information
Franck Demathieu authored and Marc Zyngier committed Mar 6, 2017
1 parent c1ae3cf commit 077dbae
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion drivers/irqchip/irq-crossbar.c
Original file line number Diff line number Diff line change
Expand Up @@ -198,7 +198,8 @@ static const struct irq_domain_ops crossbar_domain_ops = {

static int __init crossbar_of_init(struct device_node *node)
{
int i, size, max = 0, reserved = 0, entry;
int i, size, reserved = 0;
u32 max = 0, entry;
const __be32 *irqsr;
int ret = -ENOMEM;

Expand Down

0 comments on commit 077dbae

Please sign in to comment.