[PATCH] nbd.c compile warning

Shane Shrybman (shrybman@sympatico.ca)
12 Jul 2003 10:50:12 -0400


This is a MIME-formatted message. If you see this text it means that your
E-mail software does not support MIME-formatted messages.

--=_courier-28918-1058021846-0001-2
Content-Type: text/plain; charset=iso-8859-1
Content-Transfer-Encoding: 7bit

Here is a patch to fix a compile warning from nbd.c. It has been compile
tested, ( I don't actually use nbd, yet). I have included the patch as
an attachment in case it gets mangled.

--- linux-2.5.75-mm1/drivers/block/nbd.c.orig Sat Jul 12 09:23:45 2003
+++ linux-2.5.75-mm1/drivers/block/nbd.c Sat Jul 12 09:45:06 2003
@@ -261,7 +261,7 @@
dprintk(DBG_TX, "%s: request %p: sending control
(%s@%llu,%luB)\n",
lo->disk->disk_name, req,
nbdcmd_to_ascii(nbd_cmd(req)),
- req->sector << 9, req->nr_sectors << 9);
+ (unsigned long long)req->sector << 9,
req->nr_sectors << 9);
result = sock_xmit(sock, 1, &request, sizeof(request),
(nbd_cmd(req) == NBD_CMD_WRITE)? MSG_MORE: 0);
if (result <= 0) {

Regards,

shane

--=_courier-28918-1058021846-0001-2
Content-Type: text/x-diff; name="nbd.compile.warning.diff"; charset=iso-8859-1
Content-Transfer-Encoding: 7bit
Content-Disposition: attachment; filename=nbd.compile.warning.diff

--- linux-2.5.75-mm1/drivers/block/nbd.c.orig Sat Jul 12 09:23:45 2003
+++ linux-2.5.75-mm1/drivers/block/nbd.c Sat Jul 12 09:45:06 2003
@@ -261,7 +261,7 @@
dprintk(DBG_TX, "%s: request %p: sending control (%s@%llu,%luB)\n",
lo->disk->disk_name, req,
nbdcmd_to_ascii(nbd_cmd(req)),
- req->sector << 9, req->nr_sectors << 9);
+ (unsigned long long)req->sector << 9, req->nr_sectors << 9);
result = sock_xmit(sock, 1, &request, sizeof(request),
(nbd_cmd(req) == NBD_CMD_WRITE)? MSG_MORE: 0);
if (result <= 0) {

--=_courier-28918-1058021846-0001-2--