Re: [PATCH v6 4/4] net: moxa: continue loop on skb allocation failure

2014-08-25 Thread David Miller
From: Jonas Jensen Date: Mon, 25 Aug 2014 16:22:40 +0200 > If netdev_alloc_skb_ip_align() fails, subsequent code will > try to dereference an invalid pointer. > > Continue to next descriptor on error. > > While we're at it, > > 1. eliminate the chance of an endless loop, replace the main >

[PATCH v6 4/4] net: moxa: continue loop on skb allocation failure

2014-08-25 Thread Jonas Jensen
If netdev_alloc_skb_ip_align() fails, subsequent code will try to dereference an invalid pointer. Continue to next descriptor on error. While we're at it, 1. eliminate the chance of an endless loop, replace the main loop with while(rx < budget) 2. use napi_complete() and remove the explicit

[PATCH v6 4/4] net: moxa: continue loop on skb allocation failure

2014-08-25 Thread Jonas Jensen
If netdev_alloc_skb_ip_align() fails, subsequent code will try to dereference an invalid pointer. Continue to next descriptor on error. While we're at it, 1. eliminate the chance of an endless loop, replace the main loop with while(rx budget) 2. use napi_complete() and remove the explicit

Re: [PATCH v6 4/4] net: moxa: continue loop on skb allocation failure

2014-08-25 Thread David Miller
From: Jonas Jensen jonas.jen...@gmail.com Date: Mon, 25 Aug 2014 16:22:40 +0200 If netdev_alloc_skb_ip_align() fails, subsequent code will try to dereference an invalid pointer. Continue to next descriptor on error. While we're at it, 1. eliminate the chance of an endless loop, replace