summaryrefslogtreecommitdiffstats
path: root/drivers/infiniband/hw/ipath/ipath_iba7220.c
diff options
context:
space:
mode:
authorRobert P. J. Day <rpjday@crashcourse.ca>2008-07-15 08:48:44 +0200
committerRoland Dreier <rolandd@cisco.com>2008-07-15 08:48:44 +0200
commitfd91b1bf1bb6fb443cb8c7600c7314f093b31f40 (patch)
tree80f9efa76189711965243f13fee1fb01d5ec3930 /drivers/infiniband/hw/ipath/ipath_iba7220.c
parentIB/mlx4: Optimize QP stamping (diff)
downloadlinux-fd91b1bf1bb6fb443cb8c7600c7314f093b31f40.tar.xz
linux-fd91b1bf1bb6fb443cb8c7600c7314f093b31f40.zip
IB/ipath: Simplify code using ARRAY_SIZE() macro
Signed-off-by: Robert P. J. Day <rpjday@crashcourse.ca> Signed-off-by: Roland Dreier <rolandd@cisco.com>
Diffstat (limited to 'drivers/infiniband/hw/ipath/ipath_iba7220.c')
-rw-r--r--drivers/infiniband/hw/ipath/ipath_iba7220.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/infiniband/hw/ipath/ipath_iba7220.c b/drivers/infiniband/hw/ipath/ipath_iba7220.c
index 8eee7830f042..fb70712ac85c 100644
--- a/drivers/infiniband/hw/ipath/ipath_iba7220.c
+++ b/drivers/infiniband/hw/ipath/ipath_iba7220.c
@@ -2228,8 +2228,8 @@ static void ipath_autoneg_send(struct ipath_devdata *dd, int which)
0xffffffff, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0,
0x40000001, 0x1388, 0x15e, /* rest 0's */
};
- dcnt = sizeof(madpayload_start)/sizeof(madpayload_start[0]);
- hcnt = sizeof(hdr)/sizeof(hdr[0]);
+ dcnt = ARRAY_SIZE(madpayload_start);
+ hcnt = ARRAY_SIZE(hdr);
if (!swapped) {
/* for maintainability, do it at runtime */
for (i = 0; i < hcnt; i++) {