提交 2b7c4a19 编写于 作者: P Prabhakar Kushwaha 提交者: York Sun

drivers: fsl-mc: Return error for major version mismatch

Management complex major version should match to the firmware present in flash.

Return error during mismatch of major version.
Signed-off-by: NPrabhakar Kushwaha <prabhakar@freescale.com>
Acked-by: NJoe Hershberger <joe.hershberger@ni.com>
Reviewed-by: NYork Sun <yorksun@freescale.com>
上级 cd8aefc0
......@@ -518,9 +518,14 @@ int mc_init(void)
goto out;
}
if (MC_VER_MAJOR != mc_ver_info.major)
if (MC_VER_MAJOR != mc_ver_info.major) {
printf("fsl-mc: ERROR: Firmware major version mismatch (found: %d, expected: %d)\n",
mc_ver_info.major, MC_VER_MAJOR);
printf("fsl-mc: Update the Management Complex firmware\n");
error = -ENODEV;
goto out;
}
if (MC_VER_MINOR != mc_ver_info.minor)
printf("fsl-mc: WARNING: Firmware minor version mismatch (found: %d, expected: %d)\n",
......@@ -541,7 +546,7 @@ int mc_init(void)
out:
if (error != 0)
mc_boot_status = -error;
mc_boot_status = error;
else
mc_boot_status = 0;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册