[openib-general] [PATCH] mthca: fix clr_int calculation
Michael S. Tsirkin
mst at mellanox.co.il
Mon Sep 26 07:43:29 PDT 2005
----- Forwarded message from Leonid Keller <leonid at mellanox.co.il> -----
Subject: a bug ?
Date: Wed, 21 Sep 2005 21:22:05 +0300
From: "Leonid Keller" <leonid at mellanox.co.il>
in mthca_init_eq_table() there is code:
dev->eq_table.clr_int = dev->clr_base + (dev->eq_table.inta_pin < 31 ? 4 : 0);
In VAPI i saw:
dev->eq_table.clr_int = dev->clr_base + (dev->eq_table.inta_pin < 32 ? 4 : 0);
It's a bug or i'm wrong somewhere ?
----- End forwarded message -----
Roland, the following makes more sense, does it not?
---
Fix clr_int calculation.
Signed-off-by: Michael S. Tsirkin <mst at mellanox.co.il>
Index: linux-kernel/drivers/infiniband/hw/mthca/mthca_eq.c
===================================================================
--- linux-kernel.orig/drivers/infiniband/hw/mthca/mthca_eq.c 2005-09-26 17:17:01.000000000 +0300
+++ linux-kernel/drivers/infiniband/hw/mthca/mthca_eq.c 2005-09-26 17:17:08.000000000 +0300
@@ -838,7 +838,7 @@ int __devinit mthca_init_eq_table(struct
dev->eq_table.clr_mask =
swab32(1 << (dev->eq_table.inta_pin & 31));
dev->eq_table.clr_int = dev->clr_base +
- (dev->eq_table.inta_pin < 31 ? 4 : 0);
+ (dev->eq_table.inta_pin < 32 ? 4 : 0);
}
dev->eq_table.arm_mask = 0;
--
MST
More information about the general
mailing list