All of lore.kernel.org
 help / color / mirror / Atom feed
* [KJ] [PATCH][2/26] drivers/block/* - compile warning cleanup
@ 2005-02-10 21:34 Stephen Biggs
  0 siblings, 0 replies; only message in thread
From: Stephen Biggs @ 2005-02-10 21:34 UTC (permalink / raw)
  To: kernel-janitors

[-- Attachment #1: Mail message body --]
[-- Type: text/plain, Size: 1509 bytes --]

Description: compile warning cleanups - handle error return from 
scsi_add_host, cast argument to sprintf to silence warning

Signed-off-by: Stephen Biggs <yrgrknmxpzlk@gawab.com>

diff -Nurdp -X dontdiff-osdl linux-2.6.11-rc3-mm-original/drivers/block/cciss_scsi.c linux-2.6.11-rc3-mm/drivers/block/cciss_scsi.c
--- linux-2.6.11-rc3-mm-original/drivers/block/cciss_scsi.c	2005-02-03 03:55:22.000000000 +0200
+++ linux-2.6.11-rc3-mm/drivers/block/cciss_scsi.c	2005-02-09 23:04:23.000000000 +0200
@@ -706,7 +706,8 @@ cciss_scsi_detect(int ctlr)
 	sh->hostdata[0] = (unsigned long) hba[ctlr];
 	sh->irq = hba[ctlr]->intr;
 	sh->unique_id = sh->irq;
-	scsi_add_host(sh, &hba[ctlr]->pdev->dev); /* XXX handle failure */
+	if(scsi_add_host(sh, &hba[ctlr]->pdev->dev))
+		return 0;
 	scsi_scan_host(sh);
 
 	return 1;
diff -Nurdp -X dontdiff-osdl linux-2.6.11-rc3-mm-original/drivers/block/sx8.c linux-2.6.11-rc3-mm/drivers/block/sx8.c
--- linux-2.6.11-rc3-mm-original/drivers/block/sx8.c	2005-02-03 
03:57:16.000000000 +0200
+++ linux-2.6.11-rc3-mm/drivers/block/sx8.c	2005-02-07 15:35:49.000000000 +0200
@@ -1503,7 +1503,7 @@ static int carm_init_disks(struct carm_h
 		}
 
 		port->disk = disk;
-		sprintf(disk->disk_name, DRV_NAME "/%u", (host->id * CARM_MAX_PORTS) + i);
+		sprintf(disk->disk_name, DRV_NAME "/%u", (unsigned int)((host->id * CARM_MAX_PORTS) + i));
 		sprintf(disk->devfs_name, DRV_NAME "/%u_%u", host->id, i);
 		disk->major = host->major;
 		disk->first_minor = i * CARM_MINORS_PER_MAJOR;




[-- Attachment #2: Type: text/plain, Size: 167 bytes --]

_______________________________________________
Kernel-janitors mailing list
Kernel-janitors@lists.osdl.org
http://lists.osdl.org/mailman/listinfo/kernel-janitors

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2005-02-10 21:34 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-02-10 21:34 [KJ] [PATCH][2/26] drivers/block/* - compile warning cleanup Stephen Biggs

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.