lkml.org 
[lkml]   [2003]   [Mar]   [19]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Subject[patch] trivisl sg.c compile warning fix
From
Date
[ Sending this to the usual SCSI suspects ... ]

Trivial fix for a trivial problem in sg.c :: sg_device_kdev_read().

The sprintf() argument is a 'unsigned long' not an 'unsigned int'.

Patch is against 2.5.65. Danke,

Robert Love


drivers/scsi/sg.c | 6 ++++--
1 files changed, 4 insertions(+), 2 deletions(-)


diff -urN linux-2.5.65/drivers/scsi/sg.c linux/drivers/scsi/sg.c
--- linux-2.5.65/drivers/scsi/sg.c 2003-03-17 16:44:05.000000000 -0500
+++ linux/drivers/scsi/sg.c 2003-03-19 11:35:50.706607408 -0500
@@ -1331,9 +1331,11 @@
sg_device_kdev_read(struct device *driverfs_dev, char *page)
{
Sg_device *sdp = list_entry(driverfs_dev, Sg_device, sg_driverfs_dev);
- return sprintf(page, "%x\n", MKDEV(sdp->disk->major,
- sdp->disk->first_minor));
+
+ return sprintf(page, "%lx\n", MKDEV(sdp->disk->major,
+ sdp->disk->first_minor));
}
+
static DEVICE_ATTR(kdev,S_IRUGO,sg_device_kdev_read,NULL);

static ssize_t


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

\
 
 \ /
  Last update: 2005-03-22 13:34    [W:0.032 / U:0.056 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site