Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 61325
b: refs/heads/master
c: 3b2ae0b
h: refs/heads/master
i:
  61323: 50dfd91
v: v3
  • Loading branch information
Luca Risolia authored and Mauro Carvalho Chehab committed Jul 18, 2007
1 parent 7d5c1e5 commit 1c33e56
Show file tree
Hide file tree
Showing 6 changed files with 121 additions and 105 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: 3770be34199ace8c497ce454cebd7d63347dc4c3
refs/heads/master: 3b2ae0be9e246974db65a5bf4ccd2de328f3dede
2 changes: 1 addition & 1 deletion trunk/drivers/media/video/et61x251/Kconfig
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
config USB_ET61X251
tristate "USB ET61X[12]51 PC Camera Controller support"
depends on VIDEO_V4L1
depends on VIDEO_V4L2
---help---
Say Y here if you want support for cameras based on Etoms ET61X151
or ET61X251 PC Camera Controllers.
Expand Down
23 changes: 13 additions & 10 deletions trunk/drivers/media/video/et61x251/et61x251.h
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@
#include <linux/mutex.h>
#include <linux/stddef.h>
#include <linux/string.h>
#include <linux/kref.h>

#include "et61x251_sensor.h"

Expand Down Expand Up @@ -134,7 +135,7 @@ struct et61x251_module_param {
};

static DEFINE_MUTEX(et61x251_sysfs_lock);
static DECLARE_RWSEM(et61x251_disconnect);
static DECLARE_RWSEM(et61x251_dev_lock);

struct et61x251_device {
struct video_device* v4ldev;
Expand All @@ -158,12 +159,14 @@ struct et61x251_device {
struct et61x251_sysfs_attr sysfs;
struct et61x251_module_param module_param;

struct kref kref;
enum et61x251_dev_state state;
u8 users;

struct mutex dev_mutex, fileop_mutex;
struct completion probe;
struct mutex open_mutex, fileop_mutex;
spinlock_t queue_lock;
wait_queue_head_t open, wait_frame, wait_stream;
wait_queue_head_t wait_open, wait_frame, wait_stream;
};

/*****************************************************************************/
Expand All @@ -177,7 +180,7 @@ et61x251_match_id(struct et61x251_device* cam, const struct usb_device_id *id)

void
et61x251_attach_sensor(struct et61x251_device* cam,
struct et61x251_sensor* sensor)
const struct et61x251_sensor* sensor)
{
memcpy(&cam->sensor, sensor, sizeof(struct et61x251_sensor));
}
Expand All @@ -195,8 +198,8 @@ do { \
else if ((level) == 2) \
dev_info(&cam->usbdev->dev, fmt "\n", ## args); \
else if ((level) >= 3) \
dev_info(&cam->usbdev->dev, "[%s:%d] " fmt "\n", \
__FUNCTION__, __LINE__ , ## args); \
dev_info(&cam->usbdev->dev, "[%s:%s:%d] " fmt "\n", \
__FILE__, __FUNCTION__, __LINE__ , ## args); \
} \
} while (0)
# define KDBG(level, fmt, args...) \
Expand All @@ -205,8 +208,8 @@ do { \
if ((level) == 1 || (level) == 2) \
pr_info("et61x251: " fmt "\n", ## args); \
else if ((level) == 3) \
pr_debug("et61x251: [%s:%d] " fmt "\n", __FUNCTION__, \
__LINE__ , ## args); \
pr_debug("sn9c102: [%s:%s:%d] " fmt "\n", __FILE__, \
__FUNCTION__, __LINE__ , ## args); \
} \
} while (0)
# define V4LDBG(level, name, cmd) \
Expand All @@ -222,8 +225,8 @@ do { \

#undef PDBG
#define PDBG(fmt, args...) \
dev_info(&cam->usbdev->dev, "[%s:%d] " fmt "\n", \
__FUNCTION__, __LINE__ , ## args)
dev_info(&cam->usbdev->dev, "[%s:%s:%d] " fmt "\n", __FILE__, __FUNCTION__, \
__LINE__ , ## args)

#undef PDBGG
#define PDBGG(fmt, args...) do {;} while(0) /* placeholder */
Expand Down
Loading

0 comments on commit 1c33e56

Please sign in to comment.