Commit 45ad1e29 authored by Greg Kroah-Hartman's avatar Greg Kroah-Hartman

USB: fix endian warnings as found by sparse in the rio500.c driver

Signed-off-by: default avatarGreg Kroah-Hartman <greg@kroah.com>
parent d5e50611
...@@ -170,13 +170,11 @@ ioctl_rio(struct inode *inode, struct file *file, unsigned int cmd, ...@@ -170,13 +170,11 @@ ioctl_rio(struct inode *inode, struct file *file, unsigned int cmd,
if (result == -ETIMEDOUT) if (result == -ETIMEDOUT)
retries--; retries--;
else if (result < 0) { else if (result < 0) {
err("Error executing ioctrl. code = %d", err("Error executing ioctrl. code = %d", result);
le32_to_cpu(result));
retries = 0; retries = 0;
} else { } else {
dbg("Executed ioctl. Result = %d (data=%04x)", dbg("Executed ioctl. Result = %d (data=%02x)",
le32_to_cpu(result), result, buffer[0]);
le32_to_cpu(*((long *) buffer)));
if (copy_to_user(rio_cmd.buffer, buffer, if (copy_to_user(rio_cmd.buffer, buffer,
rio_cmd.length)) { rio_cmd.length)) {
free_page((unsigned long) buffer); free_page((unsigned long) buffer);
...@@ -239,12 +237,10 @@ ioctl_rio(struct inode *inode, struct file *file, unsigned int cmd, ...@@ -239,12 +237,10 @@ ioctl_rio(struct inode *inode, struct file *file, unsigned int cmd,
if (result == -ETIMEDOUT) if (result == -ETIMEDOUT)
retries--; retries--;
else if (result < 0) { else if (result < 0) {
err("Error executing ioctrl. code = %d", err("Error executing ioctrl. code = %d", result);
le32_to_cpu(result));
retries = 0; retries = 0;
} else { } else {
dbg("Executed ioctl. Result = %d", dbg("Executed ioctl. Result = %d", result);
le32_to_cpu(result));
retries = 0; retries = 0;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment