<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux/drivers/rtc/rtc-proc.c, branch v3.14-rc4</title>
<subtitle>Linux kernel source tree</subtitle>
<id>https://git.amat.us/linux/atom/drivers/rtc/rtc-proc.c?h=v3.14-rc4</id>
<link rel='self' href='https://git.amat.us/linux/atom/drivers/rtc/rtc-proc.c?h=v3.14-rc4'/>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/'/>
<updated>2013-04-09T18:13:32Z</updated>
<entry>
<title>procfs: new helper - PDE_DATA(inode)</title>
<updated>2013-04-09T18:13:32Z</updated>
<author>
<name>Al Viro</name>
<email>viro@zeniv.linux.org.uk</email>
</author>
<published>2013-03-31T22:16:14Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=d9dda78bad879595d8c4220a067fc029d6484a16'/>
<id>urn:sha1:d9dda78bad879595d8c4220a067fc029d6484a16</id>
<content type='text'>
The only part of proc_dir_entry the code outside of fs/proc
really cares about is PDE(inode)-&gt;data.  Provide a helper
for that; static inline for now, eventually will be moved
to fs/proc, along with the knowledge of struct proc_dir_entry
layout.

Signed-off-by: Al Viro &lt;viro@zeniv.linux.org.uk&gt;
</content>
</entry>
<entry>
<title>rtc-proc: permit the /proc/driver/rtc device to use other devices</title>
<updated>2012-10-05T18:05:01Z</updated>
<author>
<name>Kim, Milo</name>
<email>Milo.Kim@ti.com</email>
</author>
<published>2012-10-05T00:13:45Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=92589c986b3360ce15d239fd5113a856412a0b3f'/>
<id>urn:sha1:92589c986b3360ce15d239fd5113a856412a0b3f</id>
<content type='text'>
To get time information via /proc/driver/rtc, only the first device (rtc0)
is used.  If the rtcN (eg.  rtc1 or rtc2) is used for the system clock,
there is no way to get information of rtcN via /proc/driver/rtc.  With
this patch, the time data can be retrieved from the system clock RTC.

If the RTC_HCTOSYS_DEVICE is not defined, then rtc0 is used by default.

Signed-off-by: Milo(Woogyom) Kim &lt;milo.kim@ti.com&gt;
Cc: Alessandro Zummo &lt;a.zummo@towertech.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>RTC: Include information about UIE and PIE in RTC driver proc.</title>
<updated>2011-03-09T19:25:04Z</updated>
<author>
<name>Marcelo Roberto Jimenez</name>
<email>mroberto@cpti.cetuc.puc-rio.br</email>
</author>
<published>2011-02-11T13:50:24Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=bca8521c551afcd926bdc8f814ebaefcb8215c57'/>
<id>urn:sha1:bca8521c551afcd926bdc8f814ebaefcb8215c57</id>
<content type='text'>
Generic RTC code is always able to provide the necessary information
about update and periodic interrupts. This patch add such information to
the proc interface.

CC: Thomas Gleixner &lt;tglx@linutronix.de&gt;
CC: Alessandro Zummo &lt;a.zummo@towertech.it&gt;
CC: Marcelo Roberto Jimenez &lt;mroberto@cpti.cetuc.puc-rio.br&gt;
CC: rtc-linux@googlegroups.com
Signed-off-by: Marcelo Roberto Jimenez &lt;mroberto@cpti.cetuc.puc-rio.br&gt;
Signed-off-by: John Stultz &lt;john.stultz@linaro.org&gt;
</content>
</entry>
<entry>
<title>drivers/rtc/rtc-proc.c: add module_put on error path in rtc_proc_open()</title>
<updated>2011-02-12T00:12:20Z</updated>
<author>
<name>Alexander Strakh</name>
<email>cromlehg@gmail.com</email>
</author>
<published>2011-02-10T23:01:25Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=24a6f5b8589d2abfbf523c59ab1258726edc164f'/>
<id>urn:sha1:24a6f5b8589d2abfbf523c59ab1258726edc164f</id>
<content type='text'>
In file drivers/rtc/rtc-proc.c seq_open() can return -ENOMEM.

 86        if (!try_module_get(THIS_MODULE))
 87                return -ENODEV;
 88
 89        return single_open(file, rtc_proc_show, rtc);

In this case before exiting (line 89) from rtc_proc_open the
module_put(THIS_MODULE) must be called.

Found by Linux Device Drivers Verification Project

Signed-off-by: Alexander Strakh &lt;strakh@ispras.ru&gt;
Cc: Alessandro Zummo &lt;a.zummo@towertech.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>proc 2/2: remove struct proc_dir_entry::owner</title>
<updated>2009-03-30T21:14:44Z</updated>
<author>
<name>Alexey Dobriyan</name>
<email>adobriyan@gmail.com</email>
</author>
<published>2009-03-25T19:48:06Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=99b76233803beab302123d243eea9e41149804f3'/>
<id>urn:sha1:99b76233803beab302123d243eea9e41149804f3</id>
<content type='text'>
Setting -&gt;owner as done currently (pde-&gt;owner = THIS_MODULE) is racy
as correctly noted at bug #12454. Someone can lookup entry with NULL
-&gt;owner, thus not pinning enything, and release it later resulting
in module refcount underflow.

We can keep -&gt;owner and supply it at registration time like -&gt;proc_fops
and -&gt;data.

But this leaves -&gt;owner as easy-manipulative field (just one C assignment)
and somebody will forget to unpin previous/pin current module when
switching -&gt;owner. -&gt;proc_fops is declared as "const" which should give
some thoughts.

-&gt;read_proc/-&gt;write_proc were just fixed to not require -&gt;owner for
protection.

rmmod'ed directories will be empty and return "." and ".." -- no harm.
And directories with tricky enough readdir and lookup shouldn't be modular.
We definitely don't want such modular code.

Removing -&gt;owner will also make PDE smaller.

So, let's nuke it.

Kudos to Jeff Layton for reminding about this, let's say, oversight.

http://bugzilla.kernel.org/show_bug.cgi?id=12454

Signed-off-by: Alexey Dobriyan &lt;adobriyan@gmail.com&gt;
</content>
</entry>
<entry>
<title>drivers: use non-racy method for proc entries creation (2)</title>
<updated>2008-04-29T15:06:22Z</updated>
<author>
<name>Denis V. Lunev</name>
<email>den@openvz.org</email>
</author>
<published>2008-04-29T08:02:35Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=c7705f3449c7edd5c1744871097f93977227afc4'/>
<id>urn:sha1:c7705f3449c7edd5c1744871097f93977227afc4</id>
<content type='text'>
Use proc_create()/proc_create_data() to make sure that -&gt;proc_fops and -&gt;data
be setup before gluing PDE to main tree.

Signed-off-by: Denis V. Lunev &lt;den@openvz.org&gt;
Cc: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;
Cc: Alexey Dobriyan &lt;adobriyan@gmail.com&gt;
Cc: "Eric W. Biederman" &lt;ebiederm@xmission.com&gt;
Cc: Peter Osterlund &lt;petero2@telia.com&gt;
Cc: Bartlomiej Zolnierkiewicz &lt;bzolnier@gmail.com&gt;
Cc: Dmitry Torokhov &lt;dtor@mail.ru&gt;
Cc: Neil Brown &lt;neilb@suse.de&gt;
Cc: Mauro Carvalho Chehab &lt;mchehab@infradead.org&gt;
Cc: Bjorn Helgaas &lt;bjorn.helgaas@hp.com&gt;
Cc: Alessandro Zummo &lt;a.zummo@towertech.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>rtc: remove rest of class_device</title>
<updated>2007-05-08T18:15:18Z</updated>
<author>
<name>David Brownell</name>
<email>david-b@pacbell.net</email>
</author>
<published>2007-05-08T07:33:40Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=cd9662094edf4173e87f0452e57e4eacc228f8ff'/>
<id>urn:sha1:cd9662094edf4173e87f0452e57e4eacc228f8ff</id>
<content type='text'>
Finish converting the RTC framework so it no longer uses class_device.

Signed-off-by: David Brownell &lt;dbrownell@users.sourceforge.net&gt;
Acked-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;
Acked-By: Alessandro Zummo &lt;a.zummo@towertech.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>rtc: simplified /proc/driver/rtc handling</title>
<updated>2007-05-08T18:15:18Z</updated>
<author>
<name>David Brownell</name>
<email>david-b@pacbell.net</email>
</author>
<published>2007-05-08T07:33:38Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=7d9f99eccc8f94ace31030a2a7ff73cf5f8c12a0'/>
<id>urn:sha1:7d9f99eccc8f94ace31030a2a7ff73cf5f8c12a0</id>
<content type='text'>
This simplifies the RTC procfs support by removing the class_interface that
hooks it into the rtc core.  If it's configured, then sysfs support is now
part of the RTC core, and is never a separate module.

It also removes the class_interface hook, now that its last remaining user is
gone.  (That API is usable only with a "struct class_device".)

It's another step towards being able to remove "struct class_device".

Signed-off-by: David Brownell &lt;dbrownell@users.sourceforge.net&gt;
Acked-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;
Acked-By: Alessandro Zummo &lt;a.zummo@towertech.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>rtc: rtc interfaces don't use class_device</title>
<updated>2007-05-08T18:15:18Z</updated>
<author>
<name>David Brownell</name>
<email>david-b@pacbell.net</email>
</author>
<published>2007-05-08T07:33:30Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=ab6a2d70d18edc7a716ef3127b9e13382faec98c'/>
<id>urn:sha1:ab6a2d70d18edc7a716ef3127b9e13382faec98c</id>
<content type='text'>
This patch removes class_device from the programming interface that the RTC
framework exposes to the rest of the kernel.  Now an rtc_device is passed,
which is more type-safe and streamlines all the relevant code.

Signed-off-by: David Brownell &lt;dbrownell@users.sourceforge.net&gt;
Acked-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;
Acked-By: Alessandro Zummo &lt;a.zummo@towertech.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>[PATCH] mark struct file_operations const 5</title>
<updated>2007-02-12T17:48:45Z</updated>
<author>
<name>Arjan van de Ven</name>
<email>arjan@linux.intel.com</email>
</author>
<published>2007-02-12T08:55:34Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=d54b1fdb1d9f82e375a299e22bd366aad52d4c34'/>
<id>urn:sha1:d54b1fdb1d9f82e375a299e22bd366aad52d4c34</id>
<content type='text'>
Many struct file_operations in the kernel can be "const".  Marking them const
moves these to the .rodata section, which avoids false sharing with potential
dirty data.  In addition it'll catch accidental writes at compile time to
these shared resources.

Signed-off-by: Arjan van de Ven &lt;arjan@linux.intel.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>
</feed>
