[linux-dvb] Patch: usbvision: Convert the usbvision->lock semaphore to the mutex API

Dwaine Garden dwainegarden at rogers.com
Wed Mar 18 22:44:05 CET 2009


Looking at this patch.  I have a couple of stupid questions.

- up(&usbvision->lock);

+ mutex_unlock(&usbvision->lock);

 

+#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15)

+#include <linux/mutex.h>

+#endif

#include <media/v4l2-common.h>

#include <media/tuner.h>

#include <linux/videodev2.h>

@@ -397,7 +400,11 @@ struct usb_usbvision {

unsigned char iface; /* Video interface number */

unsigned char ifaceAlt; /* Alt settings */

unsigned char Vin_Reg2_Preset;

- struct semaphore lock;

+#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,15)

+ struct mutex               lock;

+#else

+ struct semaphore           lock;

+#endif

Do we really need to check the kernel version?   We just removed all the old susbvision->lock semaphores to the mutex API
 
Dwaine
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.linuxtv.org/pipermail/linux-dvb/attachments/20090318/e78255e7/attachment.html 


More information about the linux-dvb mailing list