aboutsummaryrefslogtreecommitdiff
path: root/drivers/media/common
diff options
context:
space:
mode:
authorWim Van Sebroeck <wim@iguana.be>2007-05-01 06:53:01 +0000
committerWim Van Sebroeck <wim@iguana.be>2007-05-01 06:53:01 +0000
commit48a7afe314bfc4d7f50e1608632f503dbba7e013 (patch)
tree4a80e6b96321a71affd1bacea817de93be08894b /drivers/media/common
parentfb8f7ba077b5c665432082ab205bcd2cb01f6a3c (diff)
parentdc87c3985e9b442c60994308a96f887579addc39 (diff)
Merge /pub/scm/linux/kernel/git/torvalds/linux-2.6
Diffstat (limited to 'drivers/media/common')
-rw-r--r--drivers/media/common/ir-functions.c6
-rw-r--r--drivers/media/common/ir-keymaps.c18
-rw-r--r--drivers/media/common/saa7146_video.c6
3 files changed, 22 insertions, 8 deletions
diff --git a/drivers/media/common/ir-functions.c b/drivers/media/common/ir-functions.c
index cbf7c056488..fcb19413562 100644
--- a/drivers/media/common/ir-functions.c
+++ b/drivers/media/common/ir-functions.c
@@ -310,13 +310,15 @@ void ir_rc5_timer_end(unsigned long data)
tv.tv_usec - ir->base_time.tv_usec;
}
- /* Allow some timmer jitter (RC5 is ~24ms anyway so this is ok) */
+ /* signal we're ready to start a new code */
+ ir->active = 0;
+
+ /* Allow some timer jitter (RC5 is ~24ms anyway so this is ok) */
if (gap < 28000) {
dprintk(1, "ir-common: spurious timer_end\n");
return;
}
- ir->active = 0;
if (ir->last_bit < 20) {
/* ignore spurious codes (caused by light/other remotes) */
dprintk(1, "ir-common: short code: %x\n", ir->code);
diff --git a/drivers/media/common/ir-keymaps.c b/drivers/media/common/ir-keymaps.c
index 03b47a262f2..cbd1184b521 100644
--- a/drivers/media/common/ir-keymaps.c
+++ b/drivers/media/common/ir-keymaps.c
@@ -667,7 +667,7 @@ IR_KEYTAB_TYPE ir_codes_pinnacle_grey[IR_KEYTAB_SIZE] = {
[ 0x1f ] = KEY_L,
[ 0x2b ] = KEY_I,
- [ 0x2d ] = KEY_ZOOM,
+ [ 0x2d ] = KEY_SCREEN,
[ 0x1e ] = KEY_ZOOM,
[ 0x1b ] = KEY_VOLUMEUP,
[ 0x0f ] = KEY_VOLUMEDOWN,
@@ -682,12 +682,12 @@ IR_KEYTAB_TYPE ir_codes_pinnacle_grey[IR_KEYTAB_SIZE] = {
[ 0x3f ] = KEY_UP,
[ 0x3e ] = KEY_DOWN,
- [ 0x1a ] = KEY_PAUSE,
+ [ 0x1a ] = KEY_ENTER,
[ 0x1d ] = KEY_MENU,
- [ 0x19 ] = KEY_PLAY,
- [ 0x16 ] = KEY_REWIND,
- [ 0x13 ] = KEY_FORWARD,
+ [ 0x19 ] = KEY_AGAIN,
+ [ 0x16 ] = KEY_PREVIOUSSONG,
+ [ 0x13 ] = KEY_NEXTSONG,
[ 0x15 ] = KEY_PAUSE,
[ 0x0e ] = KEY_REWIND,
[ 0x0d ] = KEY_PLAY,
@@ -1739,7 +1739,7 @@ IR_KEYTAB_TYPE ir_codes_encore_enltv[IR_KEYTAB_SIZE] = {
EXPORT_SYMBOL_GPL(ir_codes_encore_enltv);
-/* for the Technotrend 1500 bundled remote: */
+/* for the Technotrend 1500 bundled remotes (grey and black): */
IR_KEYTAB_TYPE ir_codes_tt_1500[IR_KEYTAB_SIZE] = {
[ 0x01 ] = KEY_POWER,
[ 0x02 ] = KEY_SHUFFLE, /* ? double-arrow key */
@@ -1774,6 +1774,12 @@ IR_KEYTAB_TYPE ir_codes_tt_1500[IR_KEYTAB_SIZE] = {
[ 0x25 ] = KEY_VOLUMEUP,
[ 0x26 ] = KEY_VOLUMEDOWN,
[ 0x27 ] = KEY_SETUP,
+ [ 0x3a ] = KEY_RECORD, /* these keys are only in the black remote */
+ [ 0x3b ] = KEY_PLAY,
+ [ 0x3c ] = KEY_STOP,
+ [ 0x3d ] = KEY_REWIND,
+ [ 0x3e ] = KEY_PAUSE,
+ [ 0x3f ] = KEY_FORWARD,
};
EXPORT_SYMBOL_GPL(ir_codes_tt_1500);
diff --git a/drivers/media/common/saa7146_video.c b/drivers/media/common/saa7146_video.c
index 7e0cedc557d..e3d04a4cef4 100644
--- a/drivers/media/common/saa7146_video.c
+++ b/drivers/media/common/saa7146_video.c
@@ -1428,6 +1428,7 @@ static void video_close(struct saa7146_dev *dev, struct file *file)
{
struct saa7146_fh *fh = (struct saa7146_fh *)file->private_data;
struct saa7146_vv *vv = dev->vv_data;
+ struct videobuf_queue *q = &fh->video_q;
int err;
if (IS_CAPTURE_ACTIVE(fh) != 0) {
@@ -1436,6 +1437,11 @@ static void video_close(struct saa7146_dev *dev, struct file *file)
err = saa7146_stop_preview(fh);
}
+ // release all capture buffers
+ mutex_lock(&q->lock);
+ videobuf_read_stop(q);
+ mutex_unlock(&q->lock);
+
/* hmm, why is this function declared void? */
/* return err */
}