diff options
author | Pankaj Bansal <pankaj.bansal@nxp.com> | 2017-11-24 18:52:08 +0530 |
---|---|---|
committer | Marc Kleine-Budde <mkl@pengutronix.de> | 2017-12-01 09:14:23 +0100 |
commit | 88462d2a7830b23edb31f467e8fcd06e56d4cb98 (patch) | |
tree | d491a2ca0a76815d33b1b24565a583f09637e0c3 /lib/nlattr.c | |
parent | a4efd5d8a46e2ff3f04ba22b1f3b9ab52eca7154 (diff) |
can: flexcan: Remodel FlexCAN register r/w APIs for big endian FlexCAN controllers.
The FlexCAN driver assumed that FlexCAN controller is big endian for
powerpc architecture and little endian for other architectures.
But this may not be the case. FlexCAN controller can be little or big
endian on any architecture. For e.g. NXP LS1021A ARM based SOC has big
endian FlexCAN controller.
Therefore, the driver has been modified to add a provision for both
types of controllers using an additional device tree property. On a
"fsl,p1010-flexcan" device BE is default, on all other devices LE is.
Big Endian controllers should have "big-endian" set in the device tree.
check "Documentation/devicetree/bindings/net/can/fsl-flexcan.txt" for
usage.
This is the standard practice followed in linux. for more info check:
Documentation/devicetree/bindings/common-properties.txt
Signed-off-by: Pankaj Bansal <pankaj.bansal@nxp.com>
Signed-off-by: Bhupesh Sharma <bhupesh.sharma@freescale.com>
Signed-off-by: Sakar Arora <Sakar.Arora@freescale.com>
Reviewed-by: Zhengxiong Jin <Jason.Jin@freescale.com>
Reviewed-by: Poonam Aggrwal <poonam.aggrwal@nxp.com>
Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
Diffstat (limited to 'lib/nlattr.c')
0 files changed, 0 insertions, 0 deletions