To modify Ixia port numbers and IP in pod.yaml
[kvmfornfv.git] / kernel / drivers / tty / n_gsm.c
index 2c34c32..9aff371 100644 (file)
@@ -161,7 +161,7 @@ struct gsm_dlci {
        struct net_device *net; /* network interface, if created */
 };
 
-/* DLCI 0, 62/63 are special or reseved see gsmtty_open */
+/* DLCI 0, 62/63 are special or reserved see gsmtty_open */
 
 #define NUM_DLCI               64
 
@@ -2045,7 +2045,9 @@ static void gsm_cleanup_mux(struct gsm_mux *gsm)
                }
        }
        spin_unlock(&gsm_mux_lock);
-       WARN_ON(i == MAX_MUX);
+       /* open failed before registering => nothing to do */
+       if (i == MAX_MUX)
+               return;
 
        /* In theory disconnecting DLCI 0 is sufficient but for some
           modems this is apparently not the case. */
@@ -2274,7 +2276,6 @@ static void gsmld_receive_buf(struct tty_struct *tty, const unsigned char *cp,
        const unsigned char *dp;
        char *f;
        int i;
-       char buf[64];
        char flags = TTY_NORMAL;
 
        if (debug & 4)
@@ -2296,7 +2297,7 @@ static void gsmld_receive_buf(struct tty_struct *tty, const unsigned char *cp,
                        break;
                default:
                        WARN_ONCE(1, "%s: unknown flag %d\n",
-                              tty_name(tty, buf), flags);
+                              tty_name(tty), flags);
                        break;
                }
        }
@@ -2713,7 +2714,7 @@ static void gsm_mux_rx_netchar(struct gsm_dlci *dlci,
        memcpy(skb_put(skb, size), in_buf, size);
 
        skb->dev = net;
-       skb->protocol = __constant_htons(ETH_P_IP);
+       skb->protocol = htons(ETH_P_IP);
 
        /* Ship it off to the kernel */
        netif_rx(skb);