diff options
author | Mauro Carvalho Chehab <m.chehab@samsung.com> | 2014-01-13 02:31:31 -0500 |
---|---|---|
committer | Mauro Carvalho Chehab <m.chehab@samsung.com> | 2014-01-14 11:40:10 -0500 |
commit | 4b819724984042eff2f14d889b55e906e420fbb3 (patch) | |
tree | cc25a5b78f6ee11d482149f607cf1713fefc2d06 /drivers/media | |
parent | a02b9c238b408f69fc78d528b549b85001df98b8 (diff) |
[media] drxk: remove the option to load firmware asynchronously
The option to load firmware asynchronously were added due to
a requirement with a few versions of udev. It turns that this was
a bad idea and caused regressions on drxk-based devices.
So, we end by only letting the firmware to be loaded syncronously
everywhere.
So, let's remove the bad code.
This patch partially reverts the changeset 8e30783b0b3.
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
Diffstat (limited to 'drivers/media')
-rw-r--r-- | drivers/media/dvb-frontends/drxk.h | 2 | ||||
-rw-r--r-- | drivers/media/dvb-frontends/drxk_hard.c | 24 | ||||
-rw-r--r-- | drivers/media/usb/em28xx/em28xx-dvb.c | 5 |
3 files changed, 6 insertions, 25 deletions
diff --git a/drivers/media/dvb-frontends/drxk.h b/drivers/media/dvb-frontends/drxk.h index f22eb9f13ad5..f6cb34660327 100644 --- a/drivers/media/dvb-frontends/drxk.h +++ b/drivers/media/dvb-frontends/drxk.h | |||
@@ -29,7 +29,6 @@ | |||
29 | * A value of 0 (default) or lower indicates that | 29 | * A value of 0 (default) or lower indicates that |
30 | * the correct number of parameters will be | 30 | * the correct number of parameters will be |
31 | * automatically detected. | 31 | * automatically detected. |
32 | * @load_firmware_sync: Force the firmware load to be synchronous. | ||
33 | * | 32 | * |
34 | * On the *_gpio vars, bit 0 is UIO-1, bit 1 is UIO-2 and bit 2 is | 33 | * On the *_gpio vars, bit 0 is UIO-1, bit 1 is UIO-2 and bit 2 is |
35 | * UIO-3. | 34 | * UIO-3. |
@@ -41,7 +40,6 @@ struct drxk_config { | |||
41 | bool parallel_ts; | 40 | bool parallel_ts; |
42 | bool dynamic_clk; | 41 | bool dynamic_clk; |
43 | bool enable_merr_cfg; | 42 | bool enable_merr_cfg; |
44 | bool load_firmware_sync; | ||
45 | 43 | ||
46 | bool antenna_dvbt; | 44 | bool antenna_dvbt; |
47 | u16 antenna_gpio; | 45 | u16 antenna_gpio; |
diff --git a/drivers/media/dvb-frontends/drxk_hard.c b/drivers/media/dvb-frontends/drxk_hard.c index bf29a3f0e6f0..cce94a75b2e1 100644 --- a/drivers/media/dvb-frontends/drxk_hard.c +++ b/drivers/media/dvb-frontends/drxk_hard.c | |||
@@ -6830,25 +6830,13 @@ struct dvb_frontend *drxk_attach(const struct drxk_config *config, | |||
6830 | 6830 | ||
6831 | /* Load firmware and initialize DRX-K */ | 6831 | /* Load firmware and initialize DRX-K */ |
6832 | if (state->microcode_name) { | 6832 | if (state->microcode_name) { |
6833 | if (config->load_firmware_sync) { | 6833 | const struct firmware *fw = NULL; |
6834 | const struct firmware *fw = NULL; | ||
6835 | 6834 | ||
6836 | status = request_firmware(&fw, state->microcode_name, | 6835 | status = request_firmware(&fw, state->microcode_name, |
6837 | state->i2c->dev.parent); | 6836 | state->i2c->dev.parent); |
6838 | if (status < 0) | 6837 | if (status < 0) |
6839 | fw = NULL; | 6838 | fw = NULL; |
6840 | load_firmware_cb(fw, state); | 6839 | load_firmware_cb(fw, state); |
6841 | } else { | ||
6842 | status = request_firmware_nowait(THIS_MODULE, 1, | ||
6843 | state->microcode_name, | ||
6844 | state->i2c->dev.parent, | ||
6845 | GFP_KERNEL, | ||
6846 | state, load_firmware_cb); | ||
6847 | if (status < 0) { | ||
6848 | pr_err("failed to request a firmware\n"); | ||
6849 | return NULL; | ||
6850 | } | ||
6851 | } | ||
6852 | } else if (init_drxk(state) < 0) | 6840 | } else if (init_drxk(state) < 0) |
6853 | goto error; | 6841 | goto error; |
6854 | 6842 | ||
diff --git a/drivers/media/usb/em28xx/em28xx-dvb.c b/drivers/media/usb/em28xx/em28xx-dvb.c index f4cdf9e8dc18..881a813836eb 100644 --- a/drivers/media/usb/em28xx/em28xx-dvb.c +++ b/drivers/media/usb/em28xx/em28xx-dvb.c | |||
@@ -375,7 +375,6 @@ static struct drxk_config terratec_h5_drxk = { | |||
375 | .no_i2c_bridge = 1, | 375 | .no_i2c_bridge = 1, |
376 | .microcode_name = "dvb-usb-terratec-h5-drxk.fw", | 376 | .microcode_name = "dvb-usb-terratec-h5-drxk.fw", |
377 | .qam_demod_parameter_count = 2, | 377 | .qam_demod_parameter_count = 2, |
378 | .load_firmware_sync = true, | ||
379 | }; | 378 | }; |
380 | 379 | ||
381 | static struct drxk_config hauppauge_930c_drxk = { | 380 | static struct drxk_config hauppauge_930c_drxk = { |
@@ -385,7 +384,6 @@ static struct drxk_config hauppauge_930c_drxk = { | |||
385 | .microcode_name = "dvb-usb-hauppauge-hvr930c-drxk.fw", | 384 | .microcode_name = "dvb-usb-hauppauge-hvr930c-drxk.fw", |
386 | .chunk_size = 56, | 385 | .chunk_size = 56, |
387 | .qam_demod_parameter_count = 2, | 386 | .qam_demod_parameter_count = 2, |
388 | .load_firmware_sync = true, | ||
389 | }; | 387 | }; |
390 | 388 | ||
391 | static struct drxk_config terratec_htc_stick_drxk = { | 389 | static struct drxk_config terratec_htc_stick_drxk = { |
@@ -399,7 +397,6 @@ static struct drxk_config terratec_htc_stick_drxk = { | |||
399 | .antenna_dvbt = true, | 397 | .antenna_dvbt = true, |
400 | /* The windows driver uses the same. This will disable LNA. */ | 398 | /* The windows driver uses the same. This will disable LNA. */ |
401 | .antenna_gpio = 0x6, | 399 | .antenna_gpio = 0x6, |
402 | .load_firmware_sync = true, | ||
403 | }; | 400 | }; |
404 | 401 | ||
405 | static struct drxk_config maxmedia_ub425_tc_drxk = { | 402 | static struct drxk_config maxmedia_ub425_tc_drxk = { |
@@ -408,7 +405,6 @@ static struct drxk_config maxmedia_ub425_tc_drxk = { | |||
408 | .no_i2c_bridge = 1, | 405 | .no_i2c_bridge = 1, |
409 | .microcode_name = "dvb-demod-drxk-01.fw", | 406 | .microcode_name = "dvb-demod-drxk-01.fw", |
410 | .chunk_size = 62, | 407 | .chunk_size = 62, |
411 | .load_firmware_sync = true, | ||
412 | .qam_demod_parameter_count = 2, | 408 | .qam_demod_parameter_count = 2, |
413 | }; | 409 | }; |
414 | 410 | ||
@@ -420,7 +416,6 @@ static struct drxk_config pctv_520e_drxk = { | |||
420 | .chunk_size = 58, | 416 | .chunk_size = 58, |
421 | .antenna_dvbt = true, /* disable LNA */ | 417 | .antenna_dvbt = true, /* disable LNA */ |
422 | .antenna_gpio = (1 << 2), /* disable LNA */ | 418 | .antenna_gpio = (1 << 2), /* disable LNA */ |
423 | .load_firmware_sync = true, | ||
424 | }; | 419 | }; |
425 | 420 | ||
426 | static int drxk_gate_ctrl(struct dvb_frontend *fe, int enable) | 421 | static int drxk_gate_ctrl(struct dvb_frontend *fe, int enable) |