10.0-RC1, armv6: "pfctl -s state" crashes on BeagleBone Black due to unaligned access
Guy Yur
guyyur at gmail.com
Sat Jan 4 19:52:12 UTC 2014
On Sat, Jan 4, 2014 at 6:50 PM, Warner Losh <imp at bsdimp.com> wrote:
> I think this was changed in later RC versions.
>
> Warner
>
Do you mean r259308 in 10-STABLE?
I compiled a new kernel with the change applied and still get SIGBUS
on unaligned access.
>From my reading of the ARM manual for Cortex-A it looks like setting
CPU_CONTROL_AFLT_ENABLE to 1 means you want to get a trap on
unaligned access.
"1 = Strict alignment fault checking enabled."
I see that dab_align delivers a SIGBUS on user-mode alignment fault.
> On Jan 4, 2014, at 6:06 AM, Guy Yur wrote:
>
>> Hi,
>>
>> I am running 10.0-RC1 arm.armv6 on the BeagleBone Black.
>> The "pfctl -s state" command is crashing when trying to print the
>> second entry.
>>
>> struct pfsync_state has a size that is not divisiable by 4 or 8 leading to the
>> second entry in the returned state array not being aligned and pfctl
>> core dumps on Bus error when trying to access a uint32_t field.
>>
Regards,
Guy
More information about the freebsd-net
mailing list