OSDN Git Service

Merge tag 'v4.4.214' into 10
[sagit-ice-cold/kernel_xiaomi_msm8998.git] / drivers / net / ppp / ppp_async.c
index 9c889e0..cef40de 100644 (file)
@@ -878,15 +878,15 @@ ppp_async_input(struct asyncppp *ap, const unsigned char *buf,
                                skb = dev_alloc_skb(ap->mru + PPP_HDRLEN + 2);
                                if (!skb)
                                        goto nomem;
-                               ap->rpkt = skb;
-                       }
-                       if (skb->len == 0) {
-                               /* Try to get the payload 4-byte aligned.
-                                * This should match the
-                                * PPP_ALLSTATIONS/PPP_UI/compressed tests in
-                                * process_input_packet, but we do not have
-                                * enough chars here to test buf[1] and buf[2].
-                                */
+                               ap->rpkt = skb;
+                       }
+                       if (skb->len == 0) {
+                               /* Try to get the payload 4-byte aligned.
+                                * This should match the
+                                * PPP_ALLSTATIONS/PPP_UI/compressed tests in
+                                * process_input_packet, but we do not have
+                                * enough chars here to test buf[1] and buf[2].
+                                */
                                if (buf[0] != PPP_ALLSTATIONS)
                                        skb_reserve(skb, 2 + (buf[0] & 1));
                        }