Questions on libertas driver
dcbw at redhat.com
Mon Jan 28 11:52:24 EST 2008
On Mon, 2008-01-28 at 17:29 +0100, Cyril HAENEL wrote:
> In fact I modified ALL le16_to_cpu() function calls to implement the
> get_unaligned((u16*), to be sure !!
> Instead of use get_unaligned, which surely eat cpu time, it cannot be
> possible to directly align data used by the driver ? In structure and
> other ?
> Or maybe it exists an option in the blackfin gcc to do this automaticaly
> at compilation ?
I don't think the driver can do anything here; it's the firmware passing
back a structure in which the fields don't align on the boundaries your
There's not too much you can do about that besides changing the firmware
or using a different architecture that doesn't have such a big problem
with unaligned reads, I guess. Maybe there's some magic that smarter
people than I know of to make the hit lighter though.
Besides, the hit will only happen when you scan, which shouldn't be that
often (maybe once a minute max).
> Vladimir Davydov a écrit :
> >>I become crazy !! :)
> >>But I continue to have kernel Oops with non aligned data.
> >>The kernel panic happen when I use iwconfig to change the essid. When I
> >>use essid "any", we can some communication between the driver and the
> >>card, but when I use essid "a3ipWifi", It hangs directly.
> >About kernel Oops with non aligned data.
> >You can try to change following lines in scan.c:
> >bytesleft = le16_to_cpu(pscan->bssdescriptsize);
> >bytesleft = le16_to_cpu(get_unaligned((u16*)&pscan->bssdescriptsize));
> >scanrespsize = le16_to_cpu(resp->size);
> >scanrespsize = le16_to_cpu(get_unaligned((u16*)&resp->size));
> >I don't known why David Woodhouse has changed those lines.
More information about the libertas-dev