Re: [B.A.T.M.A.N.] [PATCH maint] batman-adv: fix packet checksum in receive path

2018-01-23 Thread Maximilian Wilhelm
Anno domini 2018 Matthias Schiffer scripsit: Hi, > On 01/22/2018 10:18 PM, Matthias Schiffer wrote: > > On 01/22/2018 09:52 PM, Sven Eckelmann wrote: > >> On Montag, 22. Januar 2018 20:24:50 CET Matthias Schiffer wrote: > >>> skb_postpull_rcsum() is necessary after eth_type_trans() to adjust the

Re: [B.A.T.M.A.N.] [PATCH maint] batman-adv: fix packet checksum in receive path

2018-01-23 Thread Maximilian Wilhelm
Anno domini 2018 Sven Eckelmann scripsit: > On Montag, 22. Januar 2018 20:24:50 CET Matthias Schiffer wrote: [...] > > I don't know what the exact circumstances are that trigger the log spam, > > but it seems this was broken forever (I could also reproduce the issue with > > our compat-14 legacy

Re: [B.A.T.M.A.N.] limit of if per batman

2018-01-23 Thread Sven Eckelmann
On Dienstag, 26. Dezember 2017 15:19:41 CET Sven Eckelmann wrote: > On Mittwoch, 25. Januar 2017 08:15:52 CET Sven Eckelmann wrote: > [...] > > > this made me curious , and i modified your script a bit - turns out > > > after the 127. IF you add to batman-adv you get an Error - > > > all 510

Re: [B.A.T.M.A.N.] [PATCH maint v2 1/2] batman-adv: fix packet checksum in receive path

2018-01-23 Thread Sven Eckelmann
On Dienstag, 23. Januar 2018 10:59:49 CET Matthias Schiffer wrote: > eth_type_trans() internally calls skb_pull(), which does not adjust the > skb checksum; skb_postpull_rcsum() is necessary to avoid log spam of the > form "bat0: hw csum failure" when packets with CHECKSUM_COMPLETE are > received.

Re: [B.A.T.M.A.N.] [PATCH maint v2 1/2] batman-adv: fix packet checksum in receive path

2018-01-23 Thread Linus Lüssing
On Tue, Jan 23, 2018 at 10:59:49AM +0100, Matthias Schiffer wrote: > eth_type_trans() internally calls skb_pull(), which does not adjust the > skb checksum; skb_postpull_rcsum() is necessary to avoid log spam of the > form "bat0: hw csum failure" when packets with CHECKSUM_COMPLETE are > received.

[B.A.T.M.A.N.] [PATCH maint v2 2/2] batman-adv: invalidate checksum on fragment reassembly

2018-01-23 Thread Matthias Schiffer
A more sophisticated implementation could try to combine fragment checksums when all fragments have CHECKSUM_COMPLETE and are split at even offsets. For now, we just set ip_summed to CHECKSUM_NONE to avoid "hw csum failure" warnings in the kernel log when fragmented frames are received. In

[B.A.T.M.A.N.] [PATCH maint v2 1/2] batman-adv: fix packet checksum in receive path

2018-01-23 Thread Matthias Schiffer
eth_type_trans() internally calls skb_pull(), which does not adjust the skb checksum; skb_postpull_rcsum() is necessary to avoid log spam of the form "bat0: hw csum failure" when packets with CHECKSUM_COMPLETE are received. Note that in usual setups, packets don't reach batman-adv with

Re: [B.A.T.M.A.N.] [PATCH maint] batman-adv: fix packet checksum in receive path

2018-01-23 Thread Matthias Schiffer
On 01/22/2018 10:18 PM, Matthias Schiffer wrote: > On 01/22/2018 09:52 PM, Sven Eckelmann wrote: >> On Montag, 22. Januar 2018 20:24:50 CET Matthias Schiffer wrote: >>> skb_postpull_rcsum() is necessary after eth_type_trans() to adjust the >>> skb checksum, otherwise log spam of the form "bat0: hw