lkml.org 
[lkml]   [2000]   [Sep]   [3]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Subject[patch] pesky printf format warnings
Date
From
Confusion between `int' and `long int'...

p.

Index: drivers/block/linear.c
===================================================================
RCS file: /cvsroot/pub/kernel/armlinux/drivers/block/linear.c,v
retrieving revision 1.7
diff -u -p -u -r1.7 linear.c
--- drivers/block/linear.c 2000/08/02 18:34:38 1.7
+++ drivers/block/linear.c 2000/09/03 21:52:36
@@ -144,7 +144,7 @@ static int linear_make_request (mddev_t

if (block >= (tmp_dev->size + tmp_dev->offset)
|| block < tmp_dev->offset) {
- printk ("linear_make_request: Block %ld out of bounds on dev %s size %d offset %d\n", block, kdevname(tmp_dev->dev), tmp_dev->size, tmp_dev->offset);
+ printk ("linear_make_request: Block %ld out of bounds on dev %s size %ld offset %ld\n", block, kdevname(tmp_dev->dev), tmp_dev->size, tmp_dev->offset);
return -1;
}
bh->b_rdev = tmp_dev->dev;
Index: drivers/block/raid0.c
===================================================================
RCS file: /cvsroot/pub/kernel/armlinux/drivers/block/raid0.c,v
retrieving revision 1.8
diff -u -p -u -r1.8 raid0.c
--- drivers/block/raid0.c 2000/08/27 19:24:57 1.8
+++ drivers/block/raid0.c 2000/09/03 21:52:39
@@ -103,7 +103,7 @@ static int create_strip_zones (mddev_t *

zone->nb_dev = c;
zone->size = (smallest->size - current_offset) * c;
- printk(" zone->nb_dev: %d, size: %d\n",zone->nb_dev,zone->size);
+ printk(" zone->nb_dev: %d, size: %ld\n",zone->nb_dev,zone->size);

if (!conf->smallest || (zone->size < conf->smallest->size))
conf->smallest = zone;
@@ -112,7 +112,7 @@ static int create_strip_zones (mddev_t *
curr_zone_offset += zone->size;

current_offset = smallest->size;
- printk("current zone offset: %d\n", current_offset);
+ printk("current zone offset: %ld\n", current_offset);
}
printk("done.\n");
return 0;
@@ -139,7 +139,7 @@ static int raid0_run (mddev_t *mddev)
goto out_free_conf;

printk("raid0 : md_size is %d blocks.\n", md_size[mdidx(mddev)]);
- printk("raid0 : conf->smallest->size is %d blocks.\n", conf->smallest->size);
+ printk("raid0 : conf->smallest->size is %ld blocks.\n", conf->smallest->size);
nb_zone = md_size[mdidx(mddev)]/conf->smallest->size +
(md_size[mdidx(mddev)] % conf->smallest->size ? 1 : 0);
printk("raid0 : nb_zone is %ld.\n", nb_zone);

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 12:38    [W:0.025 / U:0.104 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site