<feed xmlns='http://www.w3.org/2005/Atom'>
<title>BMC/Intel-BMC/linux.git/drivers/media/rc/lirc_dev.c, branch dev-4.10</title>
<subtitle>Intel OpenBMC Linux kernel source tree (mirror)</subtitle>
<id>https://git.radix-linux.su/BMC/Intel-BMC/linux.git/atom?h=dev-4.10</id>
<link rel='self' href='https://git.radix-linux.su/BMC/Intel-BMC/linux.git/atom?h=dev-4.10'/>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/BMC/Intel-BMC/linux.git/'/>
<updated>2017-03-12T05:44:07+00:00</updated>
<entry>
<title>lirc_dev: LIRC_{G,S}ET_REC_MODE do not work</title>
<updated>2017-03-12T05:44:07+00:00</updated>
<author>
<name>Sean Young</name>
<email>sean@mess.org</email>
</author>
<published>2016-12-02T17:16:08+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/BMC/Intel-BMC/linux.git/commit/?id=81d5066323a8b422b9a3bb6cd336523e806c1885'/>
<id>urn:sha1:81d5066323a8b422b9a3bb6cd336523e806c1885</id>
<content type='text'>
commit bd291208d7f5d6b2d6a033fee449a429230b06df upstream.

Since "273b902 [media] lirc_dev: use LIRC_CAN_REC() define" these
ioctls no longer work.

Signed-off-by: Sean Young &lt;sean@mess.org&gt;
Reviewed-by: Andi Shyti &lt;andi.shyti@samsung.com&gt;
Signed-off-by: Mauro Carvalho Chehab &lt;mchehab@s-opensource.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
</entry>
<entry>
<title>[media] lirc: fix error paths in lirc_cdev_add()</title>
<updated>2016-12-01T14:46:00+00:00</updated>
<author>
<name>Sean Young</name>
<email>sean@mess.org</email>
</author>
<published>2016-11-26T21:31:24+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/BMC/Intel-BMC/linux.git/commit/?id=b40769ee2ed09ed6c6da33b0cbdf423ff94f685b'/>
<id>urn:sha1:b40769ee2ed09ed6c6da33b0cbdf423ff94f685b</id>
<content type='text'>
"c77d17c0 [media] lirc: use-after free" introduces two problems:
cdev_del() can be called with a NULL argument, and the kobject_put()
path will cause a double free.

Reported-by: Dan Carpenter &lt;dan.carpenter@oracle.com&gt;
Signed-off-by: Sean Young &lt;sean@mess.org&gt;
Signed-off-by: Mauro Carvalho Chehab &lt;mchehab@s-opensource.com&gt;
</content>
</entry>
<entry>
<title>[media] lirc: use-after free while reading from device and unplugging</title>
<updated>2016-11-21T15:28:11+00:00</updated>
<author>
<name>Sean Young</name>
<email>sean@mess.org</email>
</author>
<published>2016-10-31T17:52:27+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/BMC/Intel-BMC/linux.git/commit/?id=c77d17c0985a70fa3cd2ecde1e4f4be0dd5e9e12'/>
<id>urn:sha1:c77d17c0985a70fa3cd2ecde1e4f4be0dd5e9e12</id>
<content type='text'>
Many lirc drivers have their own receive buffers which are freed on
unplug (e.g. ir_lirc_unregister). This means that ir-&gt;buf-&gt;wait_poll
will be freed directly after unplug so do not remove yourself from the
wait queue.

Signed-off-by: Sean Young &lt;sean@mess.org&gt;
Signed-off-by: Mauro Carvalho Chehab &lt;mchehab@s-opensource.com&gt;
</content>
</entry>
<entry>
<title>[media] lirc: prevent use-after free</title>
<updated>2016-11-21T15:19:56+00:00</updated>
<author>
<name>Sean Young</name>
<email>sean@mess.org</email>
</author>
<published>2016-10-31T17:52:26+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/BMC/Intel-BMC/linux.git/commit/?id=afbb110172b93e44a3fd1b5afb3a71f7f9da4406'/>
<id>urn:sha1:afbb110172b93e44a3fd1b5afb3a71f7f9da4406</id>
<content type='text'>
If you unplug an lirc device while reading from it, you will get an
use after free as the cdev is freed while still in use.

Signed-off-by: Sean Young &lt;sean@mess.org&gt;
Signed-off-by: Mauro Carvalho Chehab &lt;mchehab@s-opensource.com&gt;
</content>
</entry>
<entry>
<title>[media] lirc: might sleep error in lirc_dev_fop_read</title>
<updated>2016-11-21T15:19:08+00:00</updated>
<author>
<name>Sean Young</name>
<email>sean@mess.org</email>
</author>
<published>2016-10-31T17:52:25+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/BMC/Intel-BMC/linux.git/commit/?id=12accdcb92ca997ffc3bf1e76887fb991d5ac773'/>
<id>urn:sha1:12accdcb92ca997ffc3bf1e76887fb991d5ac773</id>
<content type='text'>
[  101.457944] ------------[ cut here ]------------
[  101.457954] WARNING: CPU: 3 PID: 1819 at kernel/sched/core.c:7708 __might_sleep+0x7e/0x80
[  101.457960] do not call blocking ops when !TASK_RUNNING; state=1 set at [&lt;ffffffffc0364bc2&gt;] lirc_dev_fop_read+0x292/0x4e0 [lirc_dev]

Signed-off-by: Sean Young &lt;sean@mess.org&gt;
Signed-off-by: Mauro Carvalho Chehab &lt;mchehab@s-opensource.com&gt;
</content>
</entry>
<entry>
<title>[media] lirc_dev: remove compat_ioctl assignment</title>
<updated>2016-11-18T16:16:09+00:00</updated>
<author>
<name>Andi Shyti</name>
<email>andi.shyti@samsung.com</email>
</author>
<published>2016-07-06T09:01:22+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/BMC/Intel-BMC/linux.git/commit/?id=5911f629266d577c7697dd3e9797b2d1e947a40b'/>
<id>urn:sha1:5911f629266d577c7697dd3e9797b2d1e947a40b</id>
<content type='text'>
There is no need to check for CONFIG_COMPAT and consequently
assign the compat_ioctl.

Signed-off-by: Andi Shyti &lt;andi.shyti@samsung.com&gt;
Signed-off-by: Mauro Carvalho Chehab &lt;mchehab@s-opensource.com&gt;
</content>
</entry>
<entry>
<title>[media] lirc_dev: use LIRC_CAN_REC() define to check if the device can receive</title>
<updated>2016-07-13T18:29:03+00:00</updated>
<author>
<name>Andi Shyti</name>
<email>andi.shyti@samsung.com</email>
</author>
<published>2016-07-06T09:01:27+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/BMC/Intel-BMC/linux.git/commit/?id=273b902a5b1bfd6977a73c4de3eb96db3cb103cb'/>
<id>urn:sha1:273b902a5b1bfd6977a73c4de3eb96db3cb103cb</id>
<content type='text'>
The LIRC_CAN_REC() returns a boolean "flag &amp; LIRC_CAN_REC_MASK"
to check whether the device can receive data.

Signed-off-by: Andi Shyti &lt;andi.shyti@samsung.com&gt;
Signed-off-by: Mauro Carvalho Chehab &lt;mchehab@s-opensource.com&gt;
</content>
</entry>
<entry>
<title>[media] lirc_dev: fix potential segfault</title>
<updated>2016-07-13T18:28:25+00:00</updated>
<author>
<name>Andi Shyti</name>
<email>andi.shyti@samsung.com</email>
</author>
<published>2016-07-06T09:01:26+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/BMC/Intel-BMC/linux.git/commit/?id=8e5fa4c67d6387d40e2ae350e96fca939ba5e681'/>
<id>urn:sha1:8e5fa4c67d6387d40e2ae350e96fca939ba5e681</id>
<content type='text'>
When opening or closing a lirc character device, the framework
provides to the user the possibility to keep track of opening or
closing of the device by calling two functions:

 - set_use_inc() when opening the device
 - set_use_dec() when closing the device

if those are not set by the lirc user, the system segfaults.
Check the pointer value before calling the above functions.

Signed-off-by: Andi Shyti &lt;andi.shyti@samsung.com&gt;
Signed-off-by: Mauro Carvalho Chehab &lt;mchehab@s-opensource.com&gt;
</content>
</entry>
<entry>
<title>[media] lirc_dev: extremely trivial comment style fix</title>
<updated>2016-07-13T18:27:16+00:00</updated>
<author>
<name>Andi Shyti</name>
<email>andi.shyti@samsung.com</email>
</author>
<published>2016-07-06T09:01:25+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/BMC/Intel-BMC/linux.git/commit/?id=62e92682c08885e91113ba742573e736c85db0e4'/>
<id>urn:sha1:62e92682c08885e91113ba742573e736c85db0e4</id>
<content type='text'>
Signed-off-by: Andi Shyti &lt;andi.shyti@samsung.com&gt;
Signed-off-by: Mauro Carvalho Chehab &lt;mchehab@s-opensource.com&gt;
</content>
</entry>
<entry>
<title>[media] lirc_dev: fix error return value</title>
<updated>2016-07-13T18:26:52+00:00</updated>
<author>
<name>Andi Shyti</name>
<email>andi.shyti@samsung.com</email>
</author>
<published>2016-07-06T09:01:24+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/BMC/Intel-BMC/linux.git/commit/?id=b408809487e0b80fdd7869f92b5ca3be55923e9d'/>
<id>urn:sha1:b408809487e0b80fdd7869f92b5ca3be55923e9d</id>
<content type='text'>
If ioctl is called, it cannot be a case of invalid system call
number (ENOSYS), that is a ENOTTY case which means that the
device doesn't support that specific ioctl command.

So, replace ENOSYS with ENOTTY.

Signed-off-by: Andi Shyti &lt;andi.shyti@samsung.com&gt;
Signed-off-by: Mauro Carvalho Chehab &lt;mchehab@s-opensource.com&gt;
</content>
</entry>
</feed>
