lwip-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[lwip-devel] [bug #26273] etharp.c : fix alignment issue in etharp_raw


From: Guillaume du PONTAVICE
Subject: [lwip-devel] [bug #26273] etharp.c : fix alignment issue in etharp_raw
Date: Tue, 21 Apr 2009 21:45:29 +0000
User-agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; fr; rv:1.9.0.8) Gecko/2009032609 Firefox/3.0.8

Follow-up Comment #2, bug #26273 (project lwip):

well, in my case
the beginning of the ARP packet is word aligned & hdr->sipaddr & hdr->dipaddr
are two bytes aligned (not 4 bytes aligned), as their offset in an ARP packet
is only two bytes aligned.

when writing on a non aligned address on ST20 chipset, no exception occurs,
but this may result in corruption of adjacent memory.

I guess the ST compiler try to optimize the cast & then generate a load word
/ store word instruction instead of two load short / store short
instructions.
I will have a look at the assembly dump tomorrow to confirm this.

    _______________________________________________________

Reply to this item at:

  <http://savannah.nongnu.org/bugs/?26273>

_______________________________________________
  Message posté via/par Savannah
  http://savannah.nongnu.org/





reply via email to

[Prev in Thread] Current Thread [Next in Thread]