]> pilppa.com Git - linux-2.6-omap-h63xx.git/commit
byteorder: use generic C version for value byteswapping
authorHarvey Harrison <harvey.harrison@gmail.com>
Sun, 19 Oct 2008 03:28:36 +0000 (20:28 -0700)
committerLinus Torvalds <torvalds@linux-foundation.org>
Mon, 20 Oct 2008 15:52:40 +0000 (08:52 -0700)
commitacf0108a84edae22b99655eb2f6f6c9f7ec4d449
treebfd93125ccff25c774c2e4d71a8ba537312950ab
parentb8e465f4945bc0e9f324e3bbe15f5180a8e9a6fe
byteorder: use generic C version for value byteswapping

This makes the new implementation of the byteorder helpers match the old
in how it degraded when an arch-defined version was not available:

1) swab()
- look for arch defined
- if not, use generic c version

2) swabp()
- look for arch-defined
- if not, deref pointer and use swab()

3) swabs()
- look for arch defined
- if not, use swabp

Signed-off-by: Harvey Harrison <harvey.harrison@gmail.com>
Cc: "David S. Miller" <davem@davemloft.net>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
include/linux/swab.h