aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/scsi/gdth.c
diff options
context:
space:
mode:
authorTobias Klauser <tklauser@nuerscht.ch>2006-06-09 01:23:48 -0400
committerJames Bottomley <jejb@mulgrave.il.steeleye.com>2006-06-10 11:45:30 -0400
commit6391a11375de5e2bb1eb8481e54619761dc65d9f (patch)
tree956aae1d278a3f731b2e6148ff40a69aa7957ea8 /drivers/scsi/gdth.c
parent9dc399de0840a478adb71278becf598d3ab3aacc (diff)
[SCSI] drivers/scsi: Use ARRAY_SIZE macro
Use ARRAY_SIZE macro instead of sizeof(x)/sizeof(x[0]) and remove duplicates of the macro. Signed-off-by: Tobias Klauser <tklauser@nuerscht.ch> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
Diffstat (limited to 'drivers/scsi/gdth.c')
-rw-r--r--drivers/scsi/gdth.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/scsi/gdth.c b/drivers/scsi/gdth.c
index e720bb017c1e..fc4d9f61cf3d 100644
--- a/drivers/scsi/gdth.c
+++ b/drivers/scsi/gdth.c
@@ -569,8 +569,8 @@ static struct timer_list gdth_timer;
569#endif 569#endif
570 570
571#define PTR2USHORT(a) (ushort)(ulong)(a) 571#define PTR2USHORT(a) (ushort)(ulong)(a)
572#define GDTOFFSOF(a,b) (size_t)&(((a*)0)->b) 572#define GDTOFFSOF(a,b) (size_t)&(((a*)0)->b)
573#define INDEX_OK(i,t) ((i)<sizeof(t)/sizeof((t)[0])) 573#define INDEX_OK(i,t) ((i)<ARRAY_SIZE(t))
574 574
575#define NUMDATA(a) ( (gdth_num_str *)((a)->hostdata)) 575#define NUMDATA(a) ( (gdth_num_str *)((a)->hostdata))
576#define HADATA(a) (&((gdth_ext_str *)((a)->hostdata))->haext) 576#define HADATA(a) (&((gdth_ext_str *)((a)->hostdata))->haext)