[openib-general] Re: ia64: kernel unaligned access in ipoib

Roland Dreier rdreier at cisco.com
Mon May 29 09:12:02 PDT 2006


    Michael> It seems Jack has found it (see below). Since you cast
    Michael> the pointer to struct ib_gid type, and then pass a struct
    Michael> pointer to memcpy, it assumes the address is naturally
    Michael> aligned and replaces memcpy with inline st8/ld8
    Michael> instructions which can't operate on misaligned addresses.

Hmm, that's strange behavior (I would expect memcpy to work regardless
of alignment), but I guess it's technically a valid optimization.

I'll post a patch tomorrow when I'm back at work (today is Memorial
Day in the US).

 - R.



More information about the general mailing list