<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux/drivers/pps/pps.c, branch v3.12.10</title>
<subtitle>Linux kernel source tree</subtitle>
<id>https://git.amat.us/linux/atom/drivers/pps/pps.c?h=v3.12.10</id>
<link rel='self' href='https://git.amat.us/linux/atom/drivers/pps/pps.c?h=v3.12.10'/>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/'/>
<updated>2013-08-20T04:22:34Z</updated>
<entry>
<title>PPS: convert class code to use dev_groups</title>
<updated>2013-08-20T04:22:34Z</updated>
<author>
<name>Greg Kroah-Hartman</name>
<email>gregkh@linuxfoundation.org</email>
</author>
<published>2013-07-24T22:05:19Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=bd0eae4e1cd5c4ff7c2a9ebcb3e78ea4631251ef'/>
<id>urn:sha1:bd0eae4e1cd5c4ff7c2a9ebcb3e78ea4631251ef</id>
<content type='text'>
The dev_attrs field of struct class is going away soon, dev_groups
should be used instead.  This converts the pps class code to use the
correct field.

Cc: Rodolfo Giometti &lt;giometti@enneenne.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>pps: convert to idr_alloc()</title>
<updated>2013-02-28T03:10:18Z</updated>
<author>
<name>Tejun Heo</name>
<email>tj@kernel.org</email>
</author>
<published>2013-02-28T01:04:38Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=19dd2da3b4f643b65964a7f340000e27b5556f93'/>
<id>urn:sha1:19dd2da3b4f643b65964a7f340000e27b5556f93</id>
<content type='text'>
Convert to the much saner new idr interface.

Signed-off-by: Tejun Heo &lt;tj@kernel.org&gt;
Cc: Rodolfo Giometti &lt;giometti@enneenne.com&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>pps: Fix a use-after free bug when unregistering a source.</title>
<updated>2013-02-13T17:40:35Z</updated>
<author>
<name>George Spelvin</name>
<email>linux@horizon.com</email>
</author>
<published>2013-02-12T07:27:20Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=d953e0e837e65ecc1ddaa4f9560f7925878a0de6'/>
<id>urn:sha1:d953e0e837e65ecc1ddaa4f9560f7925878a0de6</id>
<content type='text'>
Remove the cdev from the system (with cdev_del) *before* deallocating it
(in pps_device_destruct, called via kobject_put from device_destroy).

Also prevent deallocating a device with open file handles.

A better long-term fix is probably to remove the cdev from the pps_device
entirely, and instead have all devices reference one global cdev.  Then
the deallocation ordering becomes simpler.

But that's more complex and invasive change, so we leave that
for later.

Signed-off-by: George Spelvin &lt;linux@horizon.com&gt;
Cc: stable &lt;stable@vger.kernel.org&gt;
Acked-by: Rodolfo Giometti &lt;giometti@enneenne.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>pps: Add pps_lookup_dev() function</title>
<updated>2013-02-13T17:40:35Z</updated>
<author>
<name>George Spelvin</name>
<email>linux@horizon.com</email>
</author>
<published>2013-02-10T09:08:32Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=513b032c98b4b9414aa4e9b4a315cb1bf0380101'/>
<id>urn:sha1:513b032c98b4b9414aa4e9b4a315cb1bf0380101</id>
<content type='text'>
The PPS serial line discipline wants to attach a PPS device to a tty
without changing the tty code to add a struct pps_device * pointer.

Since the number of PPS devices in a typical system is generally very low
(n=1 is by far the most common), it's practical to search the entire list
of allocated pps devices.  (We capture the timestamp before the lookup,
so the timing isn't affected.)

It is a bit ugly that this function, which is part of the in-kernel
PPS API, has to be in pps.c as opposed to kapi,c, but that's not
something that affects users.

Signed-off-by: George Spelvin &lt;linux@horizon.com&gt;
Acked-by: Rodolfo Giometti &lt;giometti@enneenne.com&gt;
Cc: stable &lt;stable@vger.kernel.org&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>idr: rename MAX_LEVEL to MAX_IDR_LEVEL</title>
<updated>2012-10-05T18:04:56Z</updated>
<author>
<name>Fengguang Wu</name>
<email>fengguang.wu@intel.com</email>
</author>
<published>2012-10-05T00:13:15Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=125c4c706b680c7831f0966ff873c1ad0354ec25'/>
<id>urn:sha1:125c4c706b680c7831f0966ff873c1ad0354ec25</id>
<content type='text'>
To avoid name conflicts:

  drivers/video/riva/fbdev.c:281:9: sparse: preprocessor token MAX_LEVEL redefined

While at it, also make the other names more consistent and add
parentheses.

[akpm@linux-foundation.org: repair fallout]
[sfr@canb.auug.org.au: IB/mlx4: fix for MAX_ID_MASK to MAX_IDR_MASK name change]
Signed-off-by: Fengguang Wu &lt;fengguang.wu@intel.com&gt;
Cc: Bernd Petrovitsch &lt;bernd@petrovitsch.priv.at&gt;
Cc: walter harms &lt;wharms@bfs.de&gt;
Cc: Glauber Costa &lt;glommer@parallels.com&gt;
Signed-off-by: Stephen Rothwell &lt;sfr@canb.auug.org.au&gt;
Cc: Roland Dreier &lt;roland@purestorage.com&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>pps: return PTR_ERR on error in device_create</title>
<updated>2012-07-31T00:25:21Z</updated>
<author>
<name>Emil Goode</name>
<email>emilgoode@gmail.com</email>
</author>
<published>2012-07-30T21:42:51Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=668f06b9fb846ecedb73964ca5dd95ce441707be'/>
<id>urn:sha1:668f06b9fb846ecedb73964ca5dd95ce441707be</id>
<content type='text'>
We should return PTR_ERR if the call to the device_create function fails.
Without this patch we instead return the value from a successful call to
cdev_add if the call to device_create fails.

Signed-off-by: Emil Goode &lt;emilgoode@gmail.com&gt;
Acked-by: Devendra Naga &lt;devendra.aaru@gmail.com&gt;
Cc: Alexander Gordeev &lt;lasaine@lvk.cs.msu.su&gt;
Cc: Rodolfo Giometti &lt;giometti@enneenne.com&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>pps: class_create() returns an ERR_PTR, not NULL</title>
<updated>2012-03-05T23:49:43Z</updated>
<author>
<name>Dan Carpenter</name>
<email>dan.carpenter@oracle.com</email>
</author>
<published>2012-03-05T22:59:15Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=7ad12566dc02ca76e0056af58606b5ce0181460f'/>
<id>urn:sha1:7ad12566dc02ca76e0056af58606b5ce0181460f</id>
<content type='text'>
class_create() never returns NULLs only ERR_PTRs.

Signed-off-by: Dan Carpenter &lt;dan.carpenter@oracle.com&gt;
Cc: Rodolfo Giometti &lt;giometti@enneenne.com&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>pps: add kernel consumer support</title>
<updated>2011-01-13T16:03:21Z</updated>
<author>
<name>Alexander Gordeev</name>
<email>lasaine@lvk.cs.msu.su</email>
</author>
<published>2011-01-13T01:00:58Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=717c033669ed3ceaee8df57d4562fafcc1a6267a'/>
<id>urn:sha1:717c033669ed3ceaee8df57d4562fafcc1a6267a</id>
<content type='text'>
Add an optional feature of PPSAPI, kernel consumer support, which uses the
added hardpps() function.

Signed-off-by: Alexander Gordeev &lt;lasaine@lvk.cs.msu.su&gt;
Acked-by: Rodolfo Giometti &lt;giometti@linux.it&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>pps: make idr lock a mutex and protect idr_pre_get</title>
<updated>2011-01-13T16:03:20Z</updated>
<author>
<name>Alexander Gordeev</name>
<email>lasaine@lvk.cs.msu.su</email>
</author>
<published>2011-01-13T01:00:53Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=2a5cd6e2fb1984cc83f08b3645bf394830ac7825'/>
<id>urn:sha1:2a5cd6e2fb1984cc83f08b3645bf394830ac7825</id>
<content type='text'>
Now pps_idr_lock is never used in interrupt context so we can replace
spin_lock_irq/spin_unlock_irq with plain spin_lock/spin_unlock. But
there is also a potential race condition when someone can steal an id
which was allocated by idr_pre_get before it is used. So convert spin
lock to mutex and protect the whole id generation process.

Signed-off-by: Alexander Gordeev &lt;lasaine@lvk.cs.msu.su&gt;
Cc: Rodolfo Giometti &lt;giometti@linux.it&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>pps: move idr stuff to pps.c</title>
<updated>2011-01-13T16:03:20Z</updated>
<author>
<name>Alexander Gordeev</name>
<email>lasaine@lvk.cs.msu.su</email>
</author>
<published>2011-01-13T01:00:53Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=083e58666ff5b3c5750d9a5c0560018b03cfb4b2'/>
<id>urn:sha1:083e58666ff5b3c5750d9a5c0560018b03cfb4b2</id>
<content type='text'>
Since now idr is only used to manage char device id's and not used in
kernel API anymore it should be moved to pps.c.  This also makes it
possible to release id only at actual device freeing so nobody can
register a pps device with the same id while our device is not freed yet.

Signed-off-by: Alexander Gordeev &lt;lasaine@lvk.cs.msu.su&gt;
Acked-by: Rodolfo Giometti &lt;giometti@linux.it&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
</feed>
