Thread (20 messages) flat view 20 messages, 5 authors, 2012-05-24

Re: [RFC] net/hsr: Add support for IEC 62439-3 High-availability Seamless Redundancy

From: Ben Hutchings <hidden>
Date: 2012-04-05 19:21:12

On Wed, 2012-04-04 at 20:17 -0400, David Miller wrote:
From: Arvid Brodin <redacted>
Date: Thu, 5 Apr 2012 01:09:48 +0200
quoted
-		icmp_param.data.icmph	   = *icmp_hdr(skb);
+		memcpy(&icmp_param.data.icmph, icmp_hdr(skb),
+						sizeof(icmp_param.data.icmph));
GCC can and will optimize this into an inline assignment, and thus
have the same unaligned access problems, because it determines
alignment based upon the types involved.
So presumably icmp_hdr() should be changed to skb_transport_header().

Ben.

-- 
Ben Hutchings, Staff Engineer, Solarflare
Not speaking for my employer; that's the marketing department's job.
They asked us to note that Solarflare product names are trademarked.
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help