Re: skb allocation from interrupt handler?

2017-08-09 Thread Stephen Hemminger
On Thu, 10 Aug 2017 00:29:19 +0200 Francois Romieu wrote: > Murali Karicheri : > [...] > > The internal memory or FIFO can store only up to 3 MTU sized packets. So > > that has to > > be processed before PRU gets another packets to send to CPU. So per above, > > it is not ideal to run NAPI for

Re: skb allocation from interrupt handler?

2017-08-09 Thread Francois Romieu
Murali Karicheri : [...] > The internal memory or FIFO can store only up to 3 MTU sized packets. So that > has to > be processed before PRU gets another packets to send to CPU. So per above, > it is not ideal to run NAPI for this scenario, right? Also for NetCP we use > about 128 descriptors wit

Re: skb allocation from interrupt handler?

2017-08-09 Thread Murali Karicheri
Hi David, On 08/08/2017 07:00 PM, David Miller wrote: > From: Murali Karicheri > Date: Tue, 8 Aug 2017 18:17:52 -0400 > >> Is there an skb_alloc function that can be used from interrupt handler? >> Looks like netdev_alloc_skb() >> can't be used since I see following trace with kernel hack debug

Re: skb allocation from interrupt handler?

2017-08-09 Thread Murali Karicheri
On 08/08/2017 06:29 PM, Matteo Croce wrote: > netdev_alloc_skb() passes GFP_ATOMIC to alloc_skb() so it should work > in an interrupt handler too. I will provide more background on my work as response to your next response. This is running RT Linux kernel. I have CONFIG_IRQ_FORCED_THREADING enabl

Re: skb allocation from interrupt handler?

2017-08-08 Thread David Miller
From: Murali Karicheri Date: Tue, 8 Aug 2017 18:17:52 -0400 > Is there an skb_alloc function that can be used from interrupt handler? Looks > like netdev_alloc_skb() > can't be used since I see following trace with kernel hack debug options > enabled. > > [ 652.481713] [] (unwind_backtrace) f

Re: skb allocation from interrupt handler?

2017-08-08 Thread Matteo Croce
Il giorno mar, 08/08/2017 alle 18.17 -0400, Murali Karicheri ha scritto: > Is there an skb_alloc function that can be used from interrupt > handler? Looks like netdev_alloc_skb() > can't be used since I see following trace with kernel hack debug > options enabled. > > [ 652.481713] [] (unwind_bac

skb allocation from interrupt handler?

2017-08-08 Thread Murali Karicheri
Is there an skb_alloc function that can be used from interrupt handler? Looks like netdev_alloc_skb() can't be used since I see following trace with kernel hack debug options enabled. [ 652.481713] [] (unwind_backtrace) from [] (show_stack+0x10/0x14) [ 652.481725] [] (show_stack) from [] (du