diff options
author | Alina Friedrichsen <x-alina@gmx.net> | 2011-01-23 10:27:05 -0500 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@redhat.com> | 2011-03-21 19:31:58 -0400 |
commit | b8bc77db1e23c6e141734511db873902c66bec8c (patch) | |
tree | 9eb444e78e960ca7fe42e25e5fbd00660a87d8cb /drivers/media/common | |
parent | 2b97e2201eb76d56c4901d39e8ed276f2de0e2e9 (diff) |
[media] tuner-xc2028: More firmware loading retries
My Hauppauge WinTV HVR-1400 needs sometimes more then only one retry to load the firmware successfully.
Signed-off-by: Alina Friedrichsen <x-alina@gmx.net>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media/common')
-rw-r--r-- | drivers/media/common/tuners/tuner-xc2028.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/media/common/tuners/tuner-xc2028.c b/drivers/media/common/tuners/tuner-xc2028.c index b6ce528e1889..d95f3b256e30 100644 --- a/drivers/media/common/tuners/tuner-xc2028.c +++ b/drivers/media/common/tuners/tuner-xc2028.c | |||
@@ -685,7 +685,7 @@ static int check_firmware(struct dvb_frontend *fe, unsigned int type, | |||
685 | { | 685 | { |
686 | struct xc2028_data *priv = fe->tuner_priv; | 686 | struct xc2028_data *priv = fe->tuner_priv; |
687 | struct firmware_properties new_fw; | 687 | struct firmware_properties new_fw; |
688 | int rc = 0, is_retry = 0; | 688 | int rc = 0, retry_count = 0; |
689 | u16 version, hwmodel; | 689 | u16 version, hwmodel; |
690 | v4l2_std_id std0; | 690 | v4l2_std_id std0; |
691 | 691 | ||
@@ -855,9 +855,9 @@ read_not_reliable: | |||
855 | 855 | ||
856 | fail: | 856 | fail: |
857 | memset(&priv->cur_fw, 0, sizeof(priv->cur_fw)); | 857 | memset(&priv->cur_fw, 0, sizeof(priv->cur_fw)); |
858 | if (!is_retry) { | 858 | if (retry_count < 8) { |
859 | msleep(50); | 859 | msleep(50); |
860 | is_retry = 1; | 860 | retry_count++; |
861 | tuner_dbg("Retrying firmware load\n"); | 861 | tuner_dbg("Retrying firmware load\n"); |
862 | goto retry; | 862 | goto retry; |
863 | } | 863 | } |