- 09 Apr, 2012 13 commits
-
-
Jiri Slaby authored
Add there .carrier_raised. It is taken from current block_til_ready. We will need tty_port->ops->carrier_raised for tty_port_block_til_ready helper. Signed-off-by:
Jiri Slaby <jslaby@suse.cz> Cc: Karsten Keil <isdn@linux-pingi.de> Signed-off-by:
Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-
Jiri Slaby authored
The code does almost the same, so there we can leverage the helper's code. The only difference is locking. The helper protects counts by a spinlock. This never hurts and should be added to other code parts too. Signed-off-by:
Jiri Slaby <jslaby@suse.cz> Cc: Karsten Keil <isdn@linux-pingi.de> Signed-off-by:
Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-
Jiri Slaby authored
In some functions we use tty_port much. So let us have a local pointer to that variable instead of having info->port all over the code. Signed-off-by:
Jiri Slaby <jslaby@suse.cz> Cc: Karsten Keil <isdn@linux-pingi.de> Signed-off-by:
Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-
Jiri Slaby authored
Signed-off-by:
Jiri Slaby <jslaby@suse.cz> Cc: Karsten Keil <isdn@linux-pingi.de> Signed-off-by:
Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-
Jiri Slaby authored
No recounting this time, just a plain switch. Signed-off-by:
Jiri Slaby <jslaby@suse.cz> Cc: Karsten Keil <isdn@linux-pingi.de> Signed-off-by:
Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-
Jiri Slaby authored
blocked_open and count this time. Signed-off-by:
Jiri Slaby <jslaby@suse.cz> Cc: Karsten Keil <isdn@linux-pingi.de> Signed-off-by:
Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-
Jiri Slaby authored
Hmm, the isdn ones were initialized twice. Signed-off-by:
Jiri Slaby <jslaby@suse.cz> Cc: Karsten Keil <isdn@linux-pingi.de> Signed-off-by:
Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-
Jiri Slaby authored
And use tty_port->flags now. Other members will follow. Signed-off-by:
Jiri Slaby <jslaby@suse.cz> Cc: Karsten Keil <isdn@linux-pingi.de> Signed-off-by:
Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-
Jiri Slaby authored
Huh, this was a mess. * Remove the 5 indent levels by just returning from isdn_tty_try_read when the conditions there are not satisfied. * Use 'continue' in loop in isdn_tty_readmodem to save 2 levels. * Chain 'if's in isdn_tty_modem_escape. * Use 'continue' in loop in isdn_tty_carrier_timeout to save 1 level. Better to look at this patch with -w -b. Signed-off-by:
Jiri Slaby <jslaby@suse.cz> Cc: Karsten Keil <isdn@linux-pingi.de> Signed-off-by:
Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-
Jiri Slaby authored
The module which called allocate_tty_driver is already refcounted by the TTY layer automatically. And since THIS_MODULE is isdn_tty and it allocated the tty_driver, there is no need to do the counts in isdn's tty->ops->open/close. Signed-off-by:
Jiri Slaby <jslaby@suse.cz> Cc: Karsten Keil <isdn@linux-pingi.de> Signed-off-by:
Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-
Jiri Slaby authored
They are the same as TTY ones. So there is no need to redefine them. Remove ISDN_ASYNC_* and use only ASYNC_*. Except the MAGIC number, of course. While we are there, remove also the SERIAL_TYPE flags which are unused. Perhaps we should move the ASYNC flags from serial.h to tty.h given they are used by the tty layer and tty drivers, not only serial? Signed-off-by:
Jiri Slaby <jslaby@suse.cz> Cc: Karsten Keil <isdn@linux-pingi.de> Signed-off-by:
Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-
Jiri Slaby authored
I wonder how this survived there during the whole 2.6 series until now :D. Callouts are not used for a decade, so let us remove it also from isdn. This means removal of ISDN_ASYNC_CALLOUT_ACTIVE which is never raised in info->flags and callout_termios which are never used. This will help us to get rid of ISDN_ASYNC_* flags and use ASYNC ones from serial.h. And then we will switch to tty_port. Signed-off-by:
Jiri Slaby <jslaby@suse.cz> Cc: Karsten Keil <isdn@linux-pingi.de> Signed-off-by:
Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-
Jiri Slaby authored
CVS $Id$ is unused and makes no sense in our tree. Get rid of that. Signed-off-by:
Jiri Slaby <jslaby@suse.cz> Cc: Karsten Keil <isdn@linux-pingi.de> Signed-off-by:
Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-
- 28 Mar, 2012 1 commit
-
-
David Howells authored
Remove all #inclusions of asm/system.h preparatory to splitting and killing it. Performed with the following command: perl -p -i -e 's!^#\s*include\s*<asm/system[.]h>.*\n!!' `grep -Irl '^#\s*include\s*<asm/system[.]h>' *` Signed-off-by:
David Howells <dhowells@redhat.com>
-
- 27 Mar, 2012 1 commit
-
-
Dan Carpenter authored
There are two channels here. User space starts counting channels at one but in the kernel we start at zero. If the user passes in a zero channel that's invalid and could lead to memory corruption. Signed-off-by:
Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by:
David S. Miller <davem@davemloft.net>
-
- 08 Mar, 2012 4 commits
-
-
Jiri Slaby authored
Let us port the code to use tty_port. We now use open_count and tty from there. This allows us also to use tty_port_tty_set with tty refcounting instead of hand-written locking and logic. Note that tty and open_count are no longer protected by cs->lock. It is protected by tty_port->lock. But since all the places where they were used are now switched to the helpers, we are fine. Signed-off-by:
Jiri Slaby <jslaby@suse.cz> Cc: Hansjoerg Lipp <hjlipp@web.de> Acked-by:
Tilman Schmidt <tilman@imap.cc> Cc: <gigaset307x-common@lists.sourceforge.net> Signed-off-by:
Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-
Jiri Slaby authored
Close the window in open where driver_data is reset to NULL on each open. It could cause other processes to get invalid retval from the tty->ops operations because of the checks all over the code. With this change we may do other cleanups. Now, the only valid check for tty->driver_data != NULL is in close. This can happen only if open fails at gigaset_get_cs_by_tty or try_module_get. The rest of checks in various tty->ops->* are invalid as driver_data cannot be NULL there. The same holds for cs->open_count. So remove them. Signed-off-by:
Jiri Slaby <jslaby@suse.cz> Cc: Hansjoerg Lipp <hjlipp@web.de> Cc: Tilman Schmidt <tilman@imap.cc> Cc: gigaset307x-common@lists.sourceforge.net Signed-off-by:
Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-
Jiri Slaby authored
Checking if tty->index is in bounds is not needed. The tty has the index set in the initial open. This is done in get_tty_driver. And it can be only in interval <0,driver->num). So remove the tests which check exactly this interval. Some are left untouched as they check against the current backing device count. (Leaving apart that the check is racy in most of the cases.) Signed-off-by:
Jiri Slaby <jslaby@suse.cz> Signed-off-by:
Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-
Jiri Slaby authored
All num, magic and owner are set by alloc_tty_driver. No need to re-set them on each allocation site. pti driver sets something different to what it passes to alloc_tty_driver. It is not a bug, since we don't use the lines parameter in any way. Anyway this is fixed, and now we do the right thing. Signed-off-by:
Jiri Slaby <jslaby@suse.cz> Acked-by:
Tilman Schmidt <tilman@imap.cc> Signed-off-by:
Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-
- 04 Mar, 2012 1 commit
-
-
Paul Mackerras authored
Since all that include/linux/if_ppp.h does is #include <linux/ppp-ioctl.h>, this replaces the occurrences of #include <linux/if_ppp.h> with #include <linux/ppp-ioctl.h>. It also corrects an error in Documentation/networking/l2tp.txt, where it referenced include/linux/if_ppp.h as the source of some definitions that are actually now defined in include/linux/if_pppol2tp.h. Signed-off-by:
Paul Mackerras <paulus@samba.org> Signed-off-by:
David S. Miller <davem@davemloft.net>
-
- 27 Feb, 2012 1 commit
-
-
Joe Perches authored
Commas are not generally used at locations where statement termination semicolons are used. Realign each field set at appropriate indentation. Signed-off-by:
Joe Perches <joe@perches.com> Signed-off-by:
David S. Miller <davem@davemloft.net>
-
- 21 Feb, 2012 1 commit
-
-
Joe Perches authored
isdn source code uses a not-current coding style. Update the coding style used on a per-line basis so that git diff -w shows only elided blank lines at EOF. Done with emacs and some scripts and some typing. Built x86 allyesconfig. No detected change in objdump -d or size. Signed-off-by:
Joe Perches <joe@perches.com>
-
- 12 Feb, 2012 4 commits
-
-
Masanari Iida authored
Correct spelling "modul" to "module" in drivers/isdn/mISDN/dsp_core.c Signed-off-by:
Masanari Iida <standby24x7@gmail.com> Signed-off-by:
David S. Miller <davem@davemloft.net>
-
Masanari Iida authored
Correct spelling "reseting" to "resetting" in drivers/isdn/i4l/isdn_ppp.c Signed-off-by:
Masanari Iida <standby24x7@gmail.com> Signed-off-by:
David S. Miller <davem@davemloft.net>
-
Danny Kukawka authored
Removed unused variable hfcsusb_rev (-Wunused-variable) and copied Revision info to file comment block above to keep the info. Signed-off-by:
Danny Kukawka <danny.kukawka@bisect.de> Signed-off-by:
David S. Miller <davem@davemloft.net>
-
Masanari Iida authored
Correct spelling "ioclt" to "ioctl" in drivers/isdn/hisax/callc.c Correct spelling "asigned" to "assigned" in drivers/isdn/hisax/tei.c Signed-off-by:
Masanari Iida <standby24x7@gmail.com> Signed-off-by:
David S. Miller <davem@davemloft.net>
-
- 09 Feb, 2012 1 commit
-
-
Dan Carpenter authored
We use len to store the return value from eth_header(). eth_header() can return -ETH_HLEN (-14). We want to pass this back instead of truncating it to 65522 and returning that. Signed-off-by:
Dan Carpenter <dan.carpenter@oracle.com> Acked-by:
Neil Horman <nhorman@tuxdriver.com> Signed-off-by:
David S. Miller <davem@davemloft.net>
-
- 02 Feb, 2012 2 commits
-
-
Jiri Slaby authored
Use the helper in the rest of the tty drivers. This is a simple replacement. Signed-off-by:
Jiri Slaby <jslaby@suse.cz> Acked-by:
Alan Cox <alan@linux.intel.com> Signed-off-by:
Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-
Danny Kukawka authored
Fix for a -Warray-bounds warning. mixer_notify_update() tries to write to ((CAPI_MSG *) msg)->info.facility_req.structs[3] while structs is defined as byte structs[1]. Set all 'structs' which are part of the typdefs in the info union to 'byte structs[0]'. v2: set all info.*.structs to byte structs[0] Signed-off-by:
Danny Kukawka <danny.kukawka@bisect.de> Signed-off-by:
David S. Miller <davem@davemloft.net>
-
- 01 Feb, 2012 1 commit
-
-
Akinobu Mita authored
Use memchr_inv to check if the data contains all same bytes. It is faster than looping for each byte. Signed-off-by:
Akinobu Mita <akinobu.mita@gmail.com> Cc: Karsten Keil <isdn@linux-pingi.de> Cc: netdev@vger.kernel.org Signed-off-by:
David S. Miller <davem@davemloft.net>
-
- 12 Jan, 2012 1 commit
-
-
Rusty Russell authored
module_param(bool) used to counter-intuitively take an int. In fddd5201 (mid-2009) we allowed bool or int/unsigned int using a messy trick. It's time to remove the int/unsigned int option. For this version it'll simply give a warning, but it'll break next kernel version. Acked-by:
Mauro Carvalho Chehab <mchehab@redhat.com> Signed-off-by:
Rusty Russell <rusty@rustcorp.com.au>
-
- 10 Jan, 2012 1 commit
-
-
Fabio Estevam authored
Fix the following build warning: warning: (ISDN_PPP) selects SLHC which has unmet direct dependencies (NETDEVICES) Signed-off-by:
Fabio Estevam <fabio.estevam@freescale.com> Signed-off-by:
David S. Miller <davem@davemloft.net>
-
- 02 Jan, 2012 1 commit
-
-
Al Viro authored
Signed-off-by:
Al Viro <viro@zeniv.linux.org.uk> Signed-off-by:
Jiri Kosina <jkosina@suse.cz>
-
- 29 Nov, 2011 2 commits
-
-
Dan Carpenter authored
"cfg->drvid" comes from the user so there is a possibility they didn't NUL terminate it properly. Signed-off-by:
Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by:
David S. Miller <davem@davemloft.net>
-
Dan Carpenter authored
These strings come from the user. We strcpy() them inside cf_command() so we should check that they are NULL terminated and return an error if not. Signed-off-by:
Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by:
David S. Miller <davem@davemloft.net>
-
- 27 Nov, 2011 1 commit
-
-
Tilman Schmidt authored
Move the "ISDN4Linux interface" message from device registration, where it is emitted for each device, to driver registration, where it is emitted only once, for consistency with the CAPI variant. Signed-off-by:
Tilman Schmidt <tilman@imap.cc> Signed-off-by:
David S. Miller <davem@davemloft.net>
-
- 18 Nov, 2011 1 commit
-
-
Greg Kroah-Hartman authored
This converts the remaining USB drivers in the kernel to use the module_usb_driver() macro which makes the code smaller and a bit simpler. Added bonus is that it removes some unneeded kernel log messages about drivers loading and/or unloading. Cc: Guenter Roeck <guenter.roeck@ericsson.com> Cc: Jean Delvare <khali@linux-fr.org> Cc: Ben Dooks <ben-linux@fluff.org> Cc: Till Harbaum <till@harbaum.org> Cc: Karsten Keil <isdn@linux-pingi.de> Cc: Chris Ball <cjb@laptop.org> Cc: David Woodhouse <dwmw2@infradead.org> Cc: Lauro Ramos Venancio <lauro.venancio@openbossa.org> Cc: Aloisio Almeida Jr <aloisio.almeida@openbossa.org> Cc: Samuel Ortiz <sameo@linux.intel.com> Cc: Steve Glendinning <steve.glendinning@smsc.com> Cc: Florian Tobias Schandinat <FlorianSchandinat@gmx.de> Cc: Evgeniy Polyakov <zbr@ioremap.net> Cc: Wim Van Sebroeck <wim@iguana.be> Cc: "David S. Miller" <davem@davemloft.net> Cc: Jesper Juhl <jj@chaosbits.net> Cc: Artem Bityutskiy <Artem.Bityutskiy@nokia.com> Cc: Jamie Iles <jamie@jamieiles.com> Cc: Andrew Morton <akpm@linux-foundation.org> Signed-off-by:
Greg Kroah-Hartman <gregkh@suse.de>
-
- 02 Nov, 2011 1 commit
-
-
Al Viro authored
Signed-off-by:
Al Viro <viro@zeniv.linux.org.uk> Signed-off-by:
Richard Weinberger <richard@nod.at>
-
- 01 Nov, 2011 2 commits
-
-
Paul Bolle authored
That should probably be 'CONFIG_DE_AOC'. Signed-off-by:
Paul Bolle <pebolle@tiscali.nl> Signed-off-by:
David S. Miller <davem@davemloft.net>
-
Paul Bolle authored
That should be 'CONFIG_DE_AOC'. Signed-off-by:
Paul Bolle <pebolle@tiscali.nl> Signed-off-by:
Jiri Kosina <jkosina@suse.cz>
-