MLK-15046-1 can: flexcan: re-structure to decouple the dependency on fifo mode
Current driver is highly dependent on the struct flexcan_regs layout
which may vary once the Message Buffer is changed in the new flexcan
version supporting CAN FD protocol.
This patch tends to decouple the dependency on both register layout
and underlying transfer mechanism (FIFO mode or Message buffer).
The Message Buffer mode is still not supported which will be added
later.
To achieve this, struct flexcan_regs is removed and changed to use
reg offset instead and flexcan_{read|write} is then re-prototyped.
Besides that, two new designed API flexcan_mb_read/write are introduced
for raw message buffer read/write which is independent on underlying
transfer mechanism.
This patch has no function change but a preparation for the later
CAN FD support.
Signed-off-by: Dong Aisheng <aisheng.dong@nxp.com>