]> err.no Git - linux-2.6/commitdiff
[PATCH] USB ldusb: fmt warnings fixes for 64-bit platforms
authorAlexey Dobriyan <adobriyan@gmail.com>
Sun, 14 Aug 2005 13:24:26 +0000 (17:24 +0400)
committerGreg Kroah-Hartman <gregkh@suse.de>
Thu, 8 Sep 2005 23:28:27 +0000 (16:28 -0700)
Fix

drivers/usb/misc/ldusb.c: In function `ld_usb_read':
drivers/usb/misc/ldusb.c:467: warning: int format, different type arg (arg 4)
drivers/usb/misc/ldusb.c: In function `ld_usb_write':
drivers/usb/misc/ldusb.c:531: warning: int format, different type arg (arg 4)
drivers/usb/misc/ldusb.c:532: warning: int format, different type arg (arg 5)
drivers/usb/misc/ldusb.c:532: warning: int format, different type arg (arg 6)

Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/usb/misc/ldusb.c

index ad17892aac9e829b8ad8dd509203a11f425f2a24..7e93ac96490f6176bfb143b99f7f15a9431fd00e 100644 (file)
@@ -464,7 +464,7 @@ static ssize_t ld_usb_read(struct file *file, char __user *buffer, size_t count,
        actual_buffer = (size_t*)(dev->ring_buffer + dev->ring_tail*(sizeof(size_t)+dev->interrupt_in_endpoint_size));
        bytes_to_read = min(count, *actual_buffer);
        if (bytes_to_read < *actual_buffer)
-               dev_warn(&dev->intf->dev, "Read buffer overflow, %d bytes dropped\n",
+               dev_warn(&dev->intf->dev, "Read buffer overflow, %zd bytes dropped\n",
                         *actual_buffer-bytes_to_read);
 
        /* copy one interrupt_in_buffer from ring_buffer into userspace */
@@ -528,8 +528,8 @@ static ssize_t ld_usb_write(struct file *file, const char __user *buffer,
        /* write the data into interrupt_out_buffer from userspace */
        bytes_to_write = min(count, write_buffer_size*dev->interrupt_out_endpoint_size);
        if (bytes_to_write < count)
-               dev_warn(&dev->intf->dev, "Write buffer overflow, %d bytes dropped\n",count-bytes_to_write);
-       dbg_info(&dev->intf->dev, "%s: count = %d, bytes_to_write = %d\n", __FUNCTION__, count, bytes_to_write);
+               dev_warn(&dev->intf->dev, "Write buffer overflow, %zd bytes dropped\n",count-bytes_to_write);
+       dbg_info(&dev->intf->dev, "%s: count = %zd, bytes_to_write = %zd\n", __FUNCTION__, count, bytes_to_write);
 
        if (copy_from_user(dev->interrupt_out_buffer, buffer, bytes_to_write)) {
                retval = -EFAULT;