aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAntti Seppälä <a.seppala@gmail.com>2014-02-16 05:16:02 -0500
committerMauro Carvalho Chehab <m.chehab@samsung.com>2014-03-11 11:22:50 -0400
commitc3c2077d9579472b07581ecdaf6cc5a60b1700bc (patch)
tree76a8773ba796b24c5a97650e1f3f3f5063f7a024
parent7a1dd50b89d4569baea71a80ad1a9def2353ad7d (diff)
[media] nuvoton-cir: Activate PNP device when probing
On certain motherboards (mainly Intel NUC series) bios keeps the Nuvoton CIR device disabled at boot. This patch adds a call to kernel PNP layer to activate the device if it is not already activated. This will improve the chances of the PNP probe actually succeeding on Intel NUC platforms. Signed-off-by: Antti Seppälä <a.seppala@gmail.com> Cc: Jarod Wilson <jarod@redhat.com> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
-rw-r--r--drivers/media/rc/nuvoton-cir.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/drivers/media/rc/nuvoton-cir.c b/drivers/media/rc/nuvoton-cir.c
index b41e52e3471a..b81325d7948f 100644
--- a/drivers/media/rc/nuvoton-cir.c
+++ b/drivers/media/rc/nuvoton-cir.c
@@ -985,6 +985,12 @@ static int nvt_probe(struct pnp_dev *pdev, const struct pnp_device_id *dev_id)
985 goto exit_free_dev_rdev; 985 goto exit_free_dev_rdev;
986 986
987 ret = -ENODEV; 987 ret = -ENODEV;
988 /* activate pnp device */
989 if (pnp_activate_dev(pdev) < 0) {
990 dev_err(&pdev->dev, "Could not activate PNP device!\n");
991 goto exit_free_dev_rdev;
992 }
993
988 /* validate pnp resources */ 994 /* validate pnp resources */
989 if (!pnp_port_valid(pdev, 0) || 995 if (!pnp_port_valid(pdev, 0) ||
990 pnp_port_len(pdev, 0) < CIR_IOREG_LENGTH) { 996 pnp_port_len(pdev, 0) < CIR_IOREG_LENGTH) {