提交 70c30b1e 编写于 作者: M Michał Winiarski 提交者: Mauro Carvalho Chehab

media: rc: nuvoton: Tweak the interrupt enabling dance

It appears that we need to enable CIR device before attempting to touch
some of the registers. Previously, this was not a big issue, since we
were rarely seeing nvt_close() getting called.

Unfortunately, since commit cb84343f ("media: lirc: do not call close()
or open() on unregistered devices") the initial open() during probe from
rc_setup_rx_device() is no longer successful, which means that userspace
clients will actually end up calling nvt_open()/nvt_close(). Since
nvt_open() is broken, the device doesn't seem to work as expected.

Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=199597Signed-off-by: NMichał Winiarski <michal.winiarski@intel.com>
Cc: Jarod Wilson <jarod@redhat.com>
Signed-off-by: NSean Young <sean@mess.org>
Signed-off-by: NMauro Carvalho Chehab <mchehab+samsung@kernel.org>
上级 f620d1d7
......@@ -922,6 +922,9 @@ static int nvt_open(struct rc_dev *dev)
struct nvt_dev *nvt = dev->priv;
unsigned long flags;
/* enable the CIR logical device */
nvt_enable_logical_dev(nvt, LOGICAL_DEV_CIR);
spin_lock_irqsave(&nvt->lock, flags);
/* set function enable flags */
......@@ -937,9 +940,6 @@ static int nvt_open(struct rc_dev *dev)
spin_unlock_irqrestore(&nvt->lock, flags);
/* enable the CIR logical device */
nvt_enable_logical_dev(nvt, LOGICAL_DEV_CIR);
return 0;
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册