]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
NET: slip, fix ldisc->open retval
authorMatvejchikov Ilya <matvejchikov@gmail.com>
Fri, 6 May 2011 06:23:09 +0000 (06:23 +0000)
committerGreg Kroah-Hartman <gregkh@suse.de>
Mon, 23 May 2011 18:20:16 +0000 (11:20 -0700)
commit 057bef938896e6266ae24ec4266d24792d27c29a upstream.

TTY layer expects 0 if the ldisc->open operation succeeded.

Signed-off-by : Matvejchikov Ilya <matvejchikov@gmail.com>
Acked-by: Oliver Hartkopp <socketcan@hartkopp.net>
Acked-by: Alan Cox <alan@linux.intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/net/slip.c

index fe3cebb984deb028b8a2e6ac1b1a2e2ac25717a5..9a3088faa47b37579f68ea9849d37994e0bac0f5 100644 (file)
@@ -850,7 +850,9 @@ static int slip_open(struct tty_struct *tty)
        /* Done.  We have linked the TTY line to a channel. */
        rtnl_unlock();
        tty->receive_room = 65536;      /* We don't flow control */
-       return sl->dev->base_addr;
+
+       /* TTY layer expects 0 on success */
+       return 0;
 
 err_free_bufs:
        sl_free_bufs(sl);