Commit Graph

2 Commits

Author SHA1 Message Date
nagendra modadugu
28827163c5 Move include/byteorder.h -> builtin/endian.h
Move endian routines to builtin/ so that portable third_party
code may build without glibc.

BRANCH=none
BUG=chrome-os-partner:43025,chrome-os-partner:47524
TEST=none

Change-Id: Icb900d1e9c56dc68ec1ef4b536ebc9dcf6ebcd69
Signed-off-by: nagendra modadugu <ngm@google.com>
Reviewed-on: https://chromium-review.googlesource.com/340432
Commit-Ready: Nagendra Modadugu <ngm@google.com>
Tested-by: Nagendra Modadugu <ngm@google.com>
Reviewed-by: Vadim Bendebury <vbendeb@chromium.org>
2016-04-22 20:40:03 -07:00
Vadim Bendebury
684d25b41a common: byte order conversion functions
Support for various communications protocols requires the ability to
convert between big and little endian representation of integers. This
patch moves integer converting functions into the common scope and
uses the built in functions available in ARM architecture.

Since all today's ec platforms are running in little endian mode, the
functions being added assume that the host is little endian.

BRANCH=none
BUG=chrome-os-partner:43025
TEST=none yet

Change-Id: I55ad0c5c3fe9f30cb4ed8ae807b1f5e4a54b8b35
Signed-off-by: Vadim Bendebury <vbendeb@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/312584
Reviewed-by: Vincent Palatin <vpalatin@chromium.org>
2015-11-15 11:23:22 -08:00