[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[lwip-devel] [bug #57452] CHECKSUM_ON_COPY leads to random bit error in
From: |
Victor Brzeski |
Subject: |
[lwip-devel] [bug #57452] CHECKSUM_ON_COPY leads to random bit error in TCP checksum |
Date: |
Thu, 19 Dec 2019 16:42:27 -0500 (EST) |
User-agent: |
Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/79.0.3945.79 Safari/537.36 |
URL:
<https://savannah.nongnu.org/bugs/?57452>
Summary: CHECKSUM_ON_COPY leads to random bit error in TCP
checksum
Project: lwIP - A Lightweight TCP/IP stack
Submitted by: vbrzeski
Submitted on: Thu 19 Dec 2019 09:42:25 PM UTC
Category: None
Severity: 3 - Normal
Item Group: Faulty Behaviour
Status: None
Privacy: Public
Assigned to: None
Open/Closed: Open
Discussion Lock: Any
Planned Release: None
lwIP version: git head
_______________________________________________________
Details:
Hello,
I am having problems after developing a LWIP_CHKSUM_COPY() assembly routine.
Implementations of a superior MEMCPY to the standard library, as well as a
faster LWIP_CHKSUM by utilizing ADDC instructions were both successful.
Unfortunately this improvement has caused me much frustration.
Naturally I assumed my assembly code was erroneous so I spent time I disabled
all of these macros and found the error to still exist. Considering the bug
was consistent (checksum off by 1 in MSB of checksum) I attempted to squish
it. Unfortunately after a few days I was unsuccessful.
I have done:
- Sanity checks of my MEMCPY(), LWIP_CHKSUM_COPY() and LWIP_CHKSUM() - data
copied correctly and checksum correct
- Turned off these features
- Turned off my asm byteswapping functions
- Turned off compiler optimizations (only constant folding)
Chasing the bug it seems random, and I cannot define the behavior that
reproduces it, however, it is very common. I have attached logs of debug
messages as well as a netcap with the sanity check override disabled
(commenting line 1595 in tcp_out.c).
Target: Infineon XC22xxM with ASIX Ax88796b netif
Thanks & regards,
-Victor
_______________________________________________________
File Attachments:
-------------------------------------------------------
Date: Thu 19 Dec 2019 09:42:25 PM UTC Name: csum_copy_capture.pcapng Size:
69KiB By: vbrzeski
examples of checksum issues
<http://savannah.nongnu.org/bugs/download.php?file_id=48092>
-------------------------------------------------------
Date: Thu 19 Dec 2019 09:42:25 PM UTC Name: teraterm.log Size: 597KiB By:
vbrzeski
examples of checksum issues
<http://savannah.nongnu.org/bugs/download.php?file_id=48093>
_______________________________________________________
Reply to this item at:
<https://savannah.nongnu.org/bugs/?57452>
_______________________________________________
Message sent via Savannah
https://savannah.nongnu.org/
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [lwip-devel] [bug #57452] CHECKSUM_ON_COPY leads to random bit error in TCP checksum,
Victor Brzeski <=