diff options
author | Ian Armstrong <ian@iarmst.demon.co.uk> | 2010-06-12 12:41:57 -0400 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@redhat.com> | 2010-08-02 13:48:13 -0400 |
commit | 215659d14f9dbc849ccda1655c94d710f8cc6384 (patch) | |
tree | 7f1c65043106c2b14492616e48b17d76243a20f4 /drivers/media/video/ivtv/ivtv-mailbox.c | |
parent | 914610e8c508224a6fb9fb501ed4bda25b340ba6 (diff) |
V4L/DVB: ivtv: Automatic firmware reload
If the firmware has failed, this patch will automatically reload &
restart the card. The previous card state will be restored on a
successful restart. Firmware reload will only happen if neither the
encoder or decoder is active. If the card is busy then behaviour is as
before, returning -EIO on device access until the reload can occur. On
cards that support video output, coloured bars will be displayed during
the reload.
Andy Walls (ivtv maintainer and patch committer) made minor tweaks to
comments and the logged messages, but nothing substantial otherwise.
Signed-off-by: Ian Armstrong <ian@iarmst.demon.co.uk>
Signed-off-by: Andy Walls <awalls@md.metrocast.net>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media/video/ivtv/ivtv-mailbox.c')
-rw-r--r-- | drivers/media/video/ivtv/ivtv-mailbox.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/drivers/media/video/ivtv/ivtv-mailbox.c b/drivers/media/video/ivtv/ivtv-mailbox.c index 84577f6f41a2..e3ce96763785 100644 --- a/drivers/media/video/ivtv/ivtv-mailbox.c +++ b/drivers/media/video/ivtv/ivtv-mailbox.c | |||
@@ -377,3 +377,11 @@ void ivtv_api_get_data(struct ivtv_mailbox_data *mbdata, int mb, | |||
377 | for (i = 0; i < argc; i++, p++) | 377 | for (i = 0; i < argc; i++, p++) |
378 | data[i] = readl(p); | 378 | data[i] = readl(p); |
379 | } | 379 | } |
380 | |||
381 | /* Wipe api cache */ | ||
382 | void ivtv_mailbox_cache_invalidate(struct ivtv *itv) | ||
383 | { | ||
384 | int i; | ||
385 | for (i = 0; i < 256; i++) | ||
386 | itv->api_cache[i].last_jiffies = 0; | ||
387 | } | ||