diff options
author | Ioana Radulescu <ruxandra.radulescu@nxp.com> | 2016-06-23 00:40:52 +0300 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2016-06-27 03:14:03 +0300 |
commit | 9989b59961a8ad55d92df4588b556f0c6c838ec7 (patch) | |
tree | a12fadd0caa275487bd87fcde3b8786fc01c3f48 /crypto/gf128mul.c | |
parent | adf72b5ba372ca9006f8cdcf9c0b902579f7da9f (diff) | |
download | linux-9989b59961a8ad55d92df4588b556f0c6c838ec7.tar.xz |
staging: fsl-mc: convert mc command build/parse to use C structs
The layer abstracting the building of commands and extracting
responses is currently based on macros that shift and mask the command
fields and requires exposing offset/size values as macro parameters
and makes the code harder to read.
For clarity and maintainability, instead use an implementation based on
mapping the MC command definitions to C structures. These structures
contain the hardware command fields (which are naturally-aligned)
and individual fields are little-endian ordering (the byte ordering
of the hardware).
As such, there is no need to perform the conversion between core and
hardware (LE) endianness in mc_send_command(), but instead each
individual field in a command will be converted separately if needed
by the function building the command or extracting the response.
This patch does not introduce functional changes, both the hardware
ABIs and the APIs exposed for the DPAA2 objects remain the same.
Signed-off-by: Ioana Radulescu <ruxandra.radulescu@nxp.com>
Signed-off-by: Stuart Yoder <stuart.yoder@nxp.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'crypto/gf128mul.c')
0 files changed, 0 insertions, 0 deletions