aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/scsi/aacraid/comminit.c
diff options
context:
space:
mode:
authorSalyzyn, Mark <mark_salyzyn@adaptec.com>2007-03-27 15:07:28 -0400
committerJames Bottomley <jejb@mulgrave.il.steeleye.com>2007-04-01 10:25:21 -0500
commit4dfb7cbef856689caebd0f498dbd140d1b79954f (patch)
treece9ee4971a82f8b15e9e4c03b0beef4138c1deb2 /drivers/scsi/aacraid/comminit.c
parent10c9a017f1bd84a7aedaea7029cd5224863197db (diff)
downloadkernel_samsung_tuna-4dfb7cbef856689caebd0f498dbd140d1b79954f.zip
kernel_samsung_tuna-4dfb7cbef856689caebd0f498dbd140d1b79954f.tar.gz
kernel_samsung_tuna-4dfb7cbef856689caebd0f498dbd140d1b79954f.tar.bz2
[SCSI] aacraid: resolve compiler warnings using ptrdiff_t
Unsigned long is not always the same size as a pointer, namely on 32 bit systems with 64 bit address space. Ptrdiff_t is the same size as a pointer in all configurations. By using ptrdiff_t we can mitigate the warning messages on these configurations. There should be no side effects of this patch. Signed-off-by: Mark Salyzyn <aacraid@adaptec.com> Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
Diffstat (limited to 'drivers/scsi/aacraid/comminit.c')
-rw-r--r--drivers/scsi/aacraid/comminit.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/scsi/aacraid/comminit.c b/drivers/scsi/aacraid/comminit.c
index ae34768..33682ce 100644
--- a/drivers/scsi/aacraid/comminit.c
+++ b/drivers/scsi/aacraid/comminit.c
@@ -5,7 +5,7 @@
* based on the old aacraid driver that is..
* Adaptec aacraid device driver for Linux.
*
- * Copyright (c) 2000 Adaptec, Inc. (aacraid@adaptec.com)
+ * Copyright (c) 2000-2007 Adaptec, Inc. (aacraid@adaptec.com)
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
@@ -110,7 +110,7 @@ static int aac_alloc_comm(struct aac_dev *dev, void **commaddr, unsigned long co
/*
* Align the beginning of Headers to commalign
*/
- align = (commalign - ((unsigned long)(base) & (commalign - 1)));
+ align = (commalign - ((ptrdiff_t)(base) & (commalign - 1)));
base = base + align;
phys = phys + align;
/*