Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 337117
b: refs/heads/master
c: 7d82c65
h: refs/heads/master
i:
  337115: b20df3e
v: v3
  • Loading branch information
Devendra Naga authored and Greg Kroah-Hartman committed Oct 22, 2012
1 parent 4e446d8 commit 1a3096f
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 25 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 0965be39641589a66fd0ea5745d11a11ed0d3335
refs/heads/master: 7d82c65f04b00093088002a1d8c147006c98f960
24 changes: 0 additions & 24 deletions trunk/drivers/staging/ced1401/usb1401.c
Original file line number Diff line number Diff line change
Expand Up @@ -90,13 +90,11 @@ synchronous non-Urb based transfers.
#include <linux/mm.h>
#include <linux/highmem.h>
#include <linux/version.h>
#if ( LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,35) )
#include <linux/init.h>
#include <linux/slab.h>
#include <linux/module.h>
#include <linux/kref.h>
#include <linux/uaccess.h>
#endif

#include "usb1401.h"

Expand All @@ -123,19 +121,6 @@ MODULE_DEVICE_TABLE(usb, ced_table);
#define WRITES_IN_FLIGHT 8
/* arbitrarily chosen */

/*
The cause for these errors is that the driver makes use of the functions usb_buffer_alloc() and usb_buffer_free() which got renamed in kernel 2.6.35. This is stated in the Changelog: USB: rename usb_buffer_alloc() and usb_buffer_free() users
For more clearance what the functions actually do,
usb_buffer_alloc() is renamed to usb_alloc_coherent()
usb_buffer_free() is renamed to usb_free_coherent()
This is needed on Debian 2.6.32-5-amd64
*/
#if ( LINUX_VERSION_CODE < KERNEL_VERSION(2,6,35) )
#define usb_alloc_coherent usb_buffer_alloc
#define usb_free_coherent usb_buffer_free
#define noop_llseek NULL
#endif

static struct usb_driver ced_driver;

static void ced_delete(struct kref *kref)
Expand Down Expand Up @@ -1252,12 +1237,7 @@ int Allowi(DEVICE_EXTENSION * pdx, bool bInCallback)
** ulArg The argument passed in. Note that long is 64-bits in 64-bit system, i.e. it is big
** enough for a 64-bit pointer.
*****************************************************************************/
#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,36)
static long ced_ioctl(struct file *file, unsigned int cmd, unsigned long ulArg)
#else
static int ced_ioctl(struct inode *node, struct file *file, unsigned int cmd,
unsigned long ulArg)
#endif
{
int err = 0;
DEVICE_EXTENSION *pdx = file->private_data;
Expand Down Expand Up @@ -1388,11 +1368,7 @@ static const struct file_operations ced_fops = {
.release = ced_release,
.flush = ced_flush,
.llseek = noop_llseek,
#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,36)
.unlocked_ioctl = ced_ioctl,
#else
.ioctl = ced_ioctl,
#endif
};

/*
Expand Down

0 comments on commit 1a3096f

Please sign in to comment.