diff options
author | Michael Krufky <mkrufky@linuxtv.org> | 2008-11-22 13:32:19 -0500 |
---|---|---|
committer | Michael Krufky <mkrufky@linuxtv.org> | 2008-11-22 13:32:19 -0500 |
commit | 7026808ec63b0f4aa67bc7d067510957924dcbb7 (patch) | |
tree | 19b172bb0840d8d00c288a12a5e1396b3c9522b5 /linux/drivers/media/dvb/siano/smsdvb.c | |
parent | 050475e9486c0de3e3720f2e4a7dfdbe6796d980 (diff) | |
download | mediapointer-dvb-s2-7026808ec63b0f4aa67bc7d067510957924dcbb7.tar.gz mediapointer-dvb-s2-7026808ec63b0f4aa67bc7d067510957924dcbb7.tar.bz2 |
sms1xxx: enable signal quality indicator LEDs on Hauppauge WinTV MiniStick
From: Michael Krufky <mkrufky@linuxtv.org>
Priority: normal
Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Diffstat (limited to 'linux/drivers/media/dvb/siano/smsdvb.c')
-rw-r--r-- | linux/drivers/media/dvb/siano/smsdvb.c | 15 |
1 files changed, 13 insertions, 2 deletions
diff --git a/linux/drivers/media/dvb/siano/smsdvb.c b/linux/drivers/media/dvb/siano/smsdvb.c index 0c48d2c3d..bbc87fe2e 100644 --- a/linux/drivers/media/dvb/siano/smsdvb.c +++ b/linux/drivers/media/dvb/siano/smsdvb.c @@ -167,8 +167,18 @@ static int smsdvb_send_statistics_request(struct smsdvb_client_t *client) struct SmsMsgHdr_ST Msg = { MSG_SMS_GET_STATISTICS_REQ, DVBT_BDA_CONTROL_MSG_ID, HIF_TASK, sizeof(struct SmsMsgHdr_ST), 0 }; - return smsdvb_sendrequest_and_wait(client, &Msg, sizeof(Msg), - &client->stat_done); + int ret = smsdvb_sendrequest_and_wait(client, &Msg, sizeof(Msg), + &client->stat_done); + if (ret < 0) + return ret; + + if (client->fe_status & FE_HAS_LOCK) + sms_board_led_feedback(client->coredev, + (client->fe_unc == 0) ? + SMS_LED_HI : SMS_LED_LO); + else + sms_board_led_feedback(client->coredev, SMS_LED_OFF); + return ret; } static int smsdvb_read_status(struct dvb_frontend *fe, fe_status_t *stat) @@ -309,6 +319,7 @@ static int smsdvb_sleep(struct dvb_frontend *fe) struct smsdvb_client_t *client = container_of(fe, struct smsdvb_client_t, frontend); + sms_board_led_feedback(client->coredev, SMS_LED_OFF); sms_board_power(client->coredev, 0); return 0; |