csky: Support kernel non-aligned access
authorGuo Ren <ren_guo@c-sky.com>
Tue, 20 Aug 2019 12:15:44 +0000 (20:15 +0800)
committerGuo Ren <ren_guo@c-sky.com>
Tue, 20 Aug 2019 12:15:44 +0000 (20:15 +0800)
commitc7e6f0e99227b3dcdc5e62f789119e000887ff79
treebb4a79195274df2fd3903ebb41fa475af808b1a3
parentdc140045c0cace809af872e3799e8fbe1b7d7f86
csky: Support kernel non-aligned access

We prohibit non-aligned access in kernel mode, but some special NIC
driver needs to support kernel-state unaligned access. For example,
when the bus does not support unaligned access, IP header parsing
will cause non-aligned access and driver does not recopy the skb
buffer to dma for performance reasons.

Added kernel_enable & user_enable to control unaligned access and
added kernel_count  & user_count for statistical unaligned access.

Signed-off-by: Guo Ren <ren_guo@c-sky.com>
Cc: Arnd Bergmann <arnd@arndb.de>
arch/csky/abiv1/alignment.c