Skip to content
Snippets Groups Projects
Commit ce26e8a1 authored by Xu Ziyuan's avatar Xu Ziyuan Committed by Simon Glass
Browse files

rockchip: use dummy byte only enable OF_PLATDATA


Add a condition to determine the rk3288_sdram_channel size.

This patch fixes read sdram_channel property failed from DT on rk3288
boards, which not enable OF_PLATDATA.

Signed-off-by: default avatarZiyuan Xu <xzy.xu@rock-chips.com>
parent bd218ab8
No related branches found
No related tags found
No related merge requests found
...@@ -24,12 +24,16 @@ struct rk3288_sdram_channel { ...@@ -24,12 +24,16 @@ struct rk3288_sdram_channel {
u8 row_3_4; u8 row_3_4;
u8 cs0_row; u8 cs0_row;
u8 cs1_row; u8 cs1_row;
#if CONFIG_IS_ENABLED(OF_PLATDATA)
/* /*
* For of-platdata, which would otherwise convert this into two * For of-platdata, which would otherwise convert this into two
* byte-swapped integers. With a size of 9 bytes, this struct will * byte-swapped integers. With a size of 9 bytes, this struct will
* appear in of-platdata as a byte array. * appear in of-platdata as a byte array.
*
* If OF_PLATDATA enabled, need to add a dummy byte in dts.(i.e 0xff)
*/ */
u8 dummy; u8 dummy;
#endif
}; };
struct rk3288_sdram_pctl_timing { struct rk3288_sdram_pctl_timing {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment