Re: [PATCH] em28xx: PCTV 520e workaround for DRX-K fw loading

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Em Thu, 20 Sep 2012 19:06:04 +0300
Antti Palosaari <crope@xxxxxx> escreveu:

> This is hack to make device working again.
> Looks like we need to wait DRX-K fw loading is ready until tuner
> is attached as tuner is behind demod I2C bus.
> 
> For some reason it still crash when device is re-plugged without
> module unloading...
> 
> Signed-off-by: Antti Palosaari <crope@xxxxxx>
> ---
>  drivers/media/usb/em28xx/em28xx-dvb.c | 3 +++
>  1 file changed, 3 insertions(+)
> 
> diff --git a/drivers/media/usb/em28xx/em28xx-dvb.c b/drivers/media/usb/em28xx/em28xx-dvb.c
> index 5b7f2b3..4e46fef 100644
> --- a/drivers/media/usb/em28xx/em28xx-dvb.c
> +++ b/drivers/media/usb/em28xx/em28xx-dvb.c
> @@ -1128,6 +1128,9 @@ static int em28xx_dvb_init(struct em28xx *dev)
>  		dvb->fe[0] = dvb_attach(drxk_attach, &pctv_520e_drxk,
>  				&dev->i2c_adap);
>  
> +		/* FIXME: wait demod fw is loaded, up and running */
> +		msleep(2000);
> +

Gah! that sounds ugly! Also, there's no warranty at all that this would work,
as it will depend on udev good will.

If you need to be sure that the firmware is loaded, you'll need to use wait
queues or some other way for em28xx-dvb to check if the frontend status.

>  		if (dvb->fe[0]) {
>  			/* attach tuner */
>  			if (!dvb_attach(tda18271_attach, dvb->fe[0], 0x60,

-- 
Regards,
Mauro
--
To unsubscribe from this list: send the line "unsubscribe linux-media" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Input]     [Video for Linux]     [Gstreamer Embedded]     [Mplayer Users]     [Linux USB Devel]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]
  Powered by Linux