drivers/ddr/fsl: Update fsl_ddr_board_options as weak function
authorPriyanka Jain <priyanka.jain@nxp.com>
Mon, 29 Oct 2018 09:37:36 +0000 (09:37 +0000)
committerPrabhakar Kushwaha <prabhakar.kushwaha@nxp.com>
Tue, 19 Feb 2019 04:56:43 +0000 (10:26 +0530)
fsl_ddr_board_options is generally defined in board
board's ddr.c, but some boards like lx2160ardb board
does not need this function.
Defining fsl_ddr_board_options as weak function to
resolve compilation errors for such boards.

Signed-off-by: Priyanka Jain <priyanka.jain@nxp.com>
[PK: Fix checkpatch warnings]
Signed-off-by: Prabhakar Kushwaha <prabhakar.kushwaha@nxp.com>
drivers/ddr/fsl/options.c

index 7639a8b3dd81c4c613d599d57e5331233f829ce6..4573ffa11517c11a5df24248cbd2903126a7559d 100644 (file)
  */
 
 /* Board-specific functions defined in each board's ddr.c */
-extern void fsl_ddr_board_options(memctl_options_t *popts,
-               dimm_params_t *pdimm,
-               unsigned int ctrl_num);
+void __weak fsl_ddr_board_options(memctl_options_t *popts,
+                                 dimm_params_t *pdimm,
+                                 unsigned int ctrl_num)
+{
+       return;
+}
 
 struct dynamic_odt {
        unsigned int odt_rd_cfg;