<feed xmlns='http://www.w3.org/2005/Atom'>
<title>wireguard-linux/drivers/char/ip2, branch stable</title>
<subtitle>WireGuard for the Linux kernel</subtitle>
<id>https://git.zx2c4.com/wireguard-linux/atom/drivers/char/ip2?h=stable</id>
<link rel='self' href='https://git.zx2c4.com/wireguard-linux/atom/drivers/char/ip2?h=stable'/>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/wireguard-linux/'/>
<updated>2011-02-23T00:57:21Z</updated>
<entry>
<title>tty: move obsolete and broken tty drivers to drivers/staging/tty/</title>
<updated>2011-02-23T00:57:21Z</updated>
<author>
<name>Greg Kroah-Hartman</name>
<email>gregkh@suse.de</email>
</author>
<published>2011-02-23T00:57:21Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/wireguard-linux/commit/?id=4a6514e6d096716fb7bedf238efaaca877e2a7e8'/>
<id>urn:sha1:4a6514e6d096716fb7bedf238efaaca877e2a7e8</id>
<content type='text'>
As planned by Arnd Bergmann, this moves the following drivers to the
drivers/staging/tty/ directory where they will be removed after 2.6.41
if no one steps up to claim them.
	epca
	epca
	ip2
	istallion
	riscom8
	serial167
	specialix
	stallion

Cc: Arnd Bergmann &lt;arnd@arndb.de&gt;
Cc: Alan Cox &lt;alan@lxorguk.ukuu.org.uk&gt;
Cc: Jiri Slaby &lt;jslaby@suse.cz&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;
</content>
</entry>
<entry>
<title>tty: now phase out the ioctl file pointer for good</title>
<updated>2011-02-17T19:59:56Z</updated>
<author>
<name>Alan Cox</name>
<email>alan@linux.intel.com</email>
</author>
<published>2011-02-14T16:27:22Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/wireguard-linux/commit/?id=6caa76b7786891b42b66a0e61e2c2fff2c884620'/>
<id>urn:sha1:6caa76b7786891b42b66a0e61e2c2fff2c884620</id>
<content type='text'>
Only oddities here are a couple of drivers that bogusly called the ldisc
helpers instead of returning -ENOIOCTLCMD. Fix the bug and the rest goes
away.

Signed-off-by: Alan Cox &lt;alan@linux.intel.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;
</content>
</entry>
<entry>
<title>tiocmset: kill the file pointer argument</title>
<updated>2011-02-17T19:52:43Z</updated>
<author>
<name>Alan Cox</name>
<email>alan@linux.intel.com</email>
</author>
<published>2011-02-14T16:26:50Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/wireguard-linux/commit/?id=20b9d17715017ae4dd4ec87fabc36d33b9de708e'/>
<id>urn:sha1:20b9d17715017ae4dd4ec87fabc36d33b9de708e</id>
<content type='text'>
Doing tiocmget was such fun we should do tiocmset as well for the same
reasons

Signed-off-by: Alan Cox &lt;alan@linux.intel.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;
</content>
</entry>
<entry>
<title>tiocmget: kill off the passing of the struct file</title>
<updated>2011-02-17T19:47:33Z</updated>
<author>
<name>Alan Cox</name>
<email>alan@linux.intel.com</email>
</author>
<published>2011-02-14T16:26:14Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/wireguard-linux/commit/?id=60b33c133ca0b7c0b6072c87234b63fee6e80558'/>
<id>urn:sha1:60b33c133ca0b7c0b6072c87234b63fee6e80558</id>
<content type='text'>
We don't actually need this and it causes problems for internal use of
this functionality. Currently there is a single use of the FILE * pointer.
That is the serial core which uses it to check tty_hung_up_p. However if
that is true then IO_ERROR is also already set so the check may be removed.

Signed-off-by: Alan Cox &lt;alan@linux.intel.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;
</content>
</entry>
<entry>
<title>ip2: fix compiler warning on ip2main_pci_tbl</title>
<updated>2010-12-10T23:20:15Z</updated>
<author>
<name>Namhyung Kim</name>
<email>namhyung@gmail.com</email>
</author>
<published>2010-12-07T14:27:43Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/wireguard-linux/commit/?id=53139e36cdd7bbc5efcbdc5e70fbff66e2da3c09'/>
<id>urn:sha1:53139e36cdd7bbc5efcbdc5e70fbff66e2da3c09</id>
<content type='text'>
Annotate ip2main_pci_tbl as '__used' to fix following warning:

  CC      drivers/char/ip2/ip2main.o
drivers/char/ip2/ip2main.c:3227: warning: ‘ip2main_pci_tbl’ defined but not used

Signed-off-by: Namhyung Kim &lt;namhyung@gmail.com&gt;
Cc: "Michael H. Warfield" &lt;mhw@wittsend.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;
</content>
</entry>
<entry>
<title>drivers/char/ip2/Makefile: replace the use of &lt;module&gt;-objs with &lt;module&gt;-y</title>
<updated>2010-10-28T01:03:14Z</updated>
<author>
<name>Tracey Dent</name>
<email>tdent48227@gmail.com</email>
</author>
<published>2010-10-27T22:34:23Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/wireguard-linux/commit/?id=44cd4dffe28b18139fe76e2a7b39cd1fdb459619'/>
<id>urn:sha1:44cd4dffe28b18139fe76e2a7b39cd1fdb459619</id>
<content type='text'>
Changed &lt;module&gt;-objs to &lt;module&gt;-y in Makefile.

Signed-off-by: Tracey Dent &lt;tdent48227@gmail.com&gt;
Cc: Jiri Slaby &lt;jirislaby@gmail.com&gt;
Cc: Michal Marek &lt;mmarek@suse.cz&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>Merge git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/tty-2.6</title>
<updated>2010-10-23T02:59:04Z</updated>
<author>
<name>Linus Torvalds</name>
<email>torvalds@linux-foundation.org</email>
</author>
<published>2010-10-23T02:59:04Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/wireguard-linux/commit/?id=73ecf3a6e3f0206bf56a0fefe3b3eda042fb7034'/>
<id>urn:sha1:73ecf3a6e3f0206bf56a0fefe3b3eda042fb7034</id>
<content type='text'>
* git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/tty-2.6: (49 commits)
  serial8250: ratelimit "too much work" error
  serial: bfin_sport_uart: speed up sport RX sample rate to be 3% faster
  serial: abstraction for 8250 legacy ports
  serial/imx: check that the buffer is non-empty before sending it out
  serial: mfd: add more baud rates support
  jsm: Remove the uart port on errors
  Alchemy: Add UART PM methods.
  8250: allow platforms to override PM hook.
  altera_uart: Don't use plain integer as NULL pointer
  altera_uart: Fix missing prototype for registering an early console
  altera_uart: Fixup type usage of port flags
  altera_uart: Make it possible to use Altera UART and 8250 ports together
  altera_uart: Add support for different address strides
  altera_uart: Add support for getting mapbase and IRQ from resources
  altera_uart: Add support for polling mode (IRQ-less)
  serial: Factor out uart_poll_timeout() from 8250 driver
  serial: mark the 8250 driver as maintained
  serial: 8250: Don't delay after transmitter is ready.
  tty: MAINTAINERS: add drivers/serial/jsm/ as maintained driver
  vcs: invoke the vt update callback when /dev/vcs* is written to
  ...
</content>
</entry>
<entry>
<title>Merge branch 'llseek' of git://git.kernel.org/pub/scm/linux/kernel/git/arnd/bkl</title>
<updated>2010-10-22T17:52:56Z</updated>
<author>
<name>Linus Torvalds</name>
<email>torvalds@linux-foundation.org</email>
</author>
<published>2010-10-22T17:52:56Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/wireguard-linux/commit/?id=092e0e7e520a1fca03e13c9f2d157432a8657ff2'/>
<id>urn:sha1:092e0e7e520a1fca03e13c9f2d157432a8657ff2</id>
<content type='text'>
* 'llseek' of git://git.kernel.org/pub/scm/linux/kernel/git/arnd/bkl:
  vfs: make no_llseek the default
  vfs: don't use BKL in default_llseek
  llseek: automatically add .llseek fop
  libfs: use generic_file_llseek for simple_attr
  mac80211: disallow seeks in minstrel debug code
  lirc: make chardev nonseekable
  viotape: use noop_llseek
  raw: use explicit llseek file operations
  ibmasmfs: use generic_file_llseek
  spufs: use llseek in all file operations
  arm/omap: use generic_file_llseek in iommu_debug
  lkdtm: use generic_file_llseek in debugfs
  net/wireless: use generic_file_llseek in debugfs
  drm: use noop_llseek
</content>
</entry>
<entry>
<title>tty: icount changeover for other main devices</title>
<updated>2010-10-22T17:20:05Z</updated>
<author>
<name>Alan Cox</name>
<email>alan@linux.intel.com</email>
</author>
<published>2010-09-16T17:21:52Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/wireguard-linux/commit/?id=0587102cf9f427c185bfdeb2cef41e13ee0264b1'/>
<id>urn:sha1:0587102cf9f427c185bfdeb2cef41e13ee0264b1</id>
<content type='text'>
Again basically cut and paste

Convert the main driver set to use the hooks for GICOUNT

Signed-off-by: Alan Cox &lt;alan@linux.intel.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;


</content>
</entry>
<entry>
<title>llseek: automatically add .llseek fop</title>
<updated>2010-10-15T13:53:27Z</updated>
<author>
<name>Arnd Bergmann</name>
<email>arnd@arndb.de</email>
</author>
<published>2010-08-15T16:52:59Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/wireguard-linux/commit/?id=6038f373a3dc1f1c26496e60b6c40b164716f07e'/>
<id>urn:sha1:6038f373a3dc1f1c26496e60b6c40b164716f07e</id>
<content type='text'>
All file_operations should get a .llseek operation so we can make
nonseekable_open the default for future file operations without a
.llseek pointer.

The three cases that we can automatically detect are no_llseek, seq_lseek
and default_llseek. For cases where we can we can automatically prove that
the file offset is always ignored, we use noop_llseek, which maintains
the current behavior of not returning an error from a seek.

New drivers should normally not use noop_llseek but instead use no_llseek
and call nonseekable_open at open time.  Existing drivers can be converted
to do the same when the maintainer knows for certain that no user code
relies on calling seek on the device file.

The generated code is often incorrectly indented and right now contains
comments that clarify for each added line why a specific variant was
chosen. In the version that gets submitted upstream, the comments will
be gone and I will manually fix the indentation, because there does not
seem to be a way to do that using coccinelle.

Some amount of new code is currently sitting in linux-next that should get
the same modifications, which I will do at the end of the merge window.

Many thanks to Julia Lawall for helping me learn to write a semantic
patch that does all this.

===== begin semantic patch =====
// This adds an llseek= method to all file operations,
// as a preparation for making no_llseek the default.
//
// The rules are
// - use no_llseek explicitly if we do nonseekable_open
// - use seq_lseek for sequential files
// - use default_llseek if we know we access f_pos
// - use noop_llseek if we know we don't access f_pos,
//   but we still want to allow users to call lseek
//
@ open1 exists @
identifier nested_open;
@@
nested_open(...)
{
&lt;+...
nonseekable_open(...)
...+&gt;
}

@ open exists@
identifier open_f;
identifier i, f;
identifier open1.nested_open;
@@
int open_f(struct inode *i, struct file *f)
{
&lt;+...
(
nonseekable_open(...)
|
nested_open(...)
)
...+&gt;
}

@ read disable optional_qualifier exists @
identifier read_f;
identifier f, p, s, off;
type ssize_t, size_t, loff_t;
expression E;
identifier func;
@@
ssize_t read_f(struct file *f, char *p, size_t s, loff_t *off)
{
&lt;+...
(
   *off = E
|
   *off += E
|
   func(..., off, ...)
|
   E = *off
)
...+&gt;
}

@ read_no_fpos disable optional_qualifier exists @
identifier read_f;
identifier f, p, s, off;
type ssize_t, size_t, loff_t;
@@
ssize_t read_f(struct file *f, char *p, size_t s, loff_t *off)
{
... when != off
}

@ write @
identifier write_f;
identifier f, p, s, off;
type ssize_t, size_t, loff_t;
expression E;
identifier func;
@@
ssize_t write_f(struct file *f, const char *p, size_t s, loff_t *off)
{
&lt;+...
(
  *off = E
|
  *off += E
|
  func(..., off, ...)
|
  E = *off
)
...+&gt;
}

@ write_no_fpos @
identifier write_f;
identifier f, p, s, off;
type ssize_t, size_t, loff_t;
@@
ssize_t write_f(struct file *f, const char *p, size_t s, loff_t *off)
{
... when != off
}

@ fops0 @
identifier fops;
@@
struct file_operations fops = {
 ...
};

@ has_llseek depends on fops0 @
identifier fops0.fops;
identifier llseek_f;
@@
struct file_operations fops = {
...
 .llseek = llseek_f,
...
};

@ has_read depends on fops0 @
identifier fops0.fops;
identifier read_f;
@@
struct file_operations fops = {
...
 .read = read_f,
...
};

@ has_write depends on fops0 @
identifier fops0.fops;
identifier write_f;
@@
struct file_operations fops = {
...
 .write = write_f,
...
};

@ has_open depends on fops0 @
identifier fops0.fops;
identifier open_f;
@@
struct file_operations fops = {
...
 .open = open_f,
...
};

// use no_llseek if we call nonseekable_open
////////////////////////////////////////////
@ nonseekable1 depends on !has_llseek &amp;&amp; has_open @
identifier fops0.fops;
identifier nso ~= "nonseekable_open";
@@
struct file_operations fops = {
...  .open = nso, ...
+.llseek = no_llseek, /* nonseekable */
};

@ nonseekable2 depends on !has_llseek @
identifier fops0.fops;
identifier open.open_f;
@@
struct file_operations fops = {
...  .open = open_f, ...
+.llseek = no_llseek, /* open uses nonseekable */
};

// use seq_lseek for sequential files
/////////////////////////////////////
@ seq depends on !has_llseek @
identifier fops0.fops;
identifier sr ~= "seq_read";
@@
struct file_operations fops = {
...  .read = sr, ...
+.llseek = seq_lseek, /* we have seq_read */
};

// use default_llseek if there is a readdir
///////////////////////////////////////////
@ fops1 depends on !has_llseek &amp;&amp; !nonseekable1 &amp;&amp; !nonseekable2 &amp;&amp; !seq @
identifier fops0.fops;
identifier readdir_e;
@@
// any other fop is used that changes pos
struct file_operations fops = {
... .readdir = readdir_e, ...
+.llseek = default_llseek, /* readdir is present */
};

// use default_llseek if at least one of read/write touches f_pos
/////////////////////////////////////////////////////////////////
@ fops2 depends on !fops1 &amp;&amp; !has_llseek &amp;&amp; !nonseekable1 &amp;&amp; !nonseekable2 &amp;&amp; !seq @
identifier fops0.fops;
identifier read.read_f;
@@
// read fops use offset
struct file_operations fops = {
... .read = read_f, ...
+.llseek = default_llseek, /* read accesses f_pos */
};

@ fops3 depends on !fops1 &amp;&amp; !fops2 &amp;&amp; !has_llseek &amp;&amp; !nonseekable1 &amp;&amp; !nonseekable2 &amp;&amp; !seq @
identifier fops0.fops;
identifier write.write_f;
@@
// write fops use offset
struct file_operations fops = {
... .write = write_f, ...
+	.llseek = default_llseek, /* write accesses f_pos */
};

// Use noop_llseek if neither read nor write accesses f_pos
///////////////////////////////////////////////////////////

@ fops4 depends on !fops1 &amp;&amp; !fops2 &amp;&amp; !fops3 &amp;&amp; !has_llseek &amp;&amp; !nonseekable1 &amp;&amp; !nonseekable2 &amp;&amp; !seq @
identifier fops0.fops;
identifier read_no_fpos.read_f;
identifier write_no_fpos.write_f;
@@
// write fops use offset
struct file_operations fops = {
...
 .write = write_f,
 .read = read_f,
...
+.llseek = noop_llseek, /* read and write both use no f_pos */
};

@ depends on has_write &amp;&amp; !has_read &amp;&amp; !fops1 &amp;&amp; !fops2 &amp;&amp; !has_llseek &amp;&amp; !nonseekable1 &amp;&amp; !nonseekable2 &amp;&amp; !seq @
identifier fops0.fops;
identifier write_no_fpos.write_f;
@@
struct file_operations fops = {
... .write = write_f, ...
+.llseek = noop_llseek, /* write uses no f_pos */
};

@ depends on has_read &amp;&amp; !has_write &amp;&amp; !fops1 &amp;&amp; !fops2 &amp;&amp; !has_llseek &amp;&amp; !nonseekable1 &amp;&amp; !nonseekable2 &amp;&amp; !seq @
identifier fops0.fops;
identifier read_no_fpos.read_f;
@@
struct file_operations fops = {
... .read = read_f, ...
+.llseek = noop_llseek, /* read uses no f_pos */
};

@ depends on !has_read &amp;&amp; !has_write &amp;&amp; !fops1 &amp;&amp; !fops2 &amp;&amp; !has_llseek &amp;&amp; !nonseekable1 &amp;&amp; !nonseekable2 &amp;&amp; !seq @
identifier fops0.fops;
@@
struct file_operations fops = {
...
+.llseek = noop_llseek, /* no read or write fn */
};
===== End semantic patch =====

Signed-off-by: Arnd Bergmann &lt;arnd@arndb.de&gt;
Cc: Julia Lawall &lt;julia@diku.dk&gt;
Cc: Christoph Hellwig &lt;hch@infradead.org&gt;
</content>
</entry>
</feed>
