[ovs-dev] [PATCH 4/4] ovs: Implement 802.1ag Connectivity Fault Management

Ben Pfaff blp at nicira.com
Mon Nov 29 22:37:00 UTC 2010

On Mon, Nov 29, 2010 at 02:30:09PM -0800, Ethan Jackson wrote:
> > By itself that's not good enough because working with packed structures
> > is slow on RISC systems, because it forces them to work with misaligned
> > data.
> I don't quite get that.  If the RISC system does anything to properly
> align the data won't it be incorrect on the wire when it's sent out?
> Any padding is going to mess up the packet isn't it?

"packed" has a cost: it makes accessing structure members more expensive
on RISC machines.  If, without "packed", the structure is the right
size, then you don't want to add "packed" for that reason.  If "packed"
is necessary, though, you have to use it.

In this case, you said that "packed" actually changed the structure's
size.  So we have to use it.  That's fine.

More information about the dev mailing list