[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[lwip-devel] [bug #34534] Error in sending fragmented IP if MEM_ALIGNMEN
From: |
Andriy Korud |
Subject: |
[lwip-devel] [bug #34534] Error in sending fragmented IP if MEM_ALIGNMENT > 1 |
Date: |
Wed, 12 Oct 2011 05:49:21 +0000 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:7.0.1) Gecko/20100101 Firefox/7.0.1 |
URL:
<http://savannah.nongnu.org/bugs/?34534>
Summary: Error in sending fragmented IP if MEM_ALIGNMENT > 1
Project: lwIP - A Lightweight TCP/IP stack
Submitted by: akorud
Submitted on: Wed 12 Oct 2011 05:49:20 AM GMT
Category: IPv4
Severity: 3 - Normal
Item Group: Faulty Behaviour
Status: None
Privacy: Public
Assigned to: None
Open/Closed: Open
Discussion Lock: Any
Planned Release:
lwIP version: 1.4.0
_______________________________________________________
Details:
Hi, I've discovered that this change "Fixed bug #29361 (ip_frag has problems
with zero-copy DMA MACs) by adding custom pbufs and implementing custom pbufs
that reference other (original) pbufs." has introduced new problem.
In line 379 in pbuf.c new custom pbuf is referenced with alignment, resulting
wrong data to be sent. In ip_frag() too chained pbuf's are created for each
fragment: for header and payload. Header takes 20 bytes and payload instead to
be referenced to position +20, points to byte at +32 (MEM_ALIGNMENT 32). This
cause bytes in range 20..31 are not sent at all.
How to reproduce: set MEM_ALIGNMENT to 32 and try to ping with packets > MTU.
Ping replies will return corrupted.
Temporary solution (works for me) - rollback mentioned change. Probably
removing p->pbuf.payload = LWIP_MEM_ALIGN((void *)((u8_t *)payload_mem +
offset)); will also work, I'm not sure of side effects.
_______________________________________________________
Reply to this item at:
<http://savannah.nongnu.org/bugs/?34534>
_______________________________________________
Message sent via/by Savannah
http://savannah.nongnu.org/
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [lwip-devel] [bug #34534] Error in sending fragmented IP if MEM_ALIGNMENT > 1,
Andriy Korud <=