[Why]
Not having support for autoload isn't an error. If the DMUB firmware
doesn't support it then don't return DMUB_STATUS_INVALID.
[How]
Return DMUB_STATUS_OK when ->is_auto_load_done is NULL.
Signed-off-by: Nicholas Kazlauskas <nicholas.kazlauskas@amd.com>
Reviewed-by: Tony Cheng <Tony.Cheng@amd.com>
Acked-by: Leo Li <sunpeng.li@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
{
uint32_t i;
- if (!dmub->hw_init || !dmub->hw_funcs.is_auto_load_done)
+ if (!dmub->hw_init)
return DMUB_STATUS_INVALID;
+ if (!dmub->hw_funcs.is_auto_load_done)
+ return DMUB_STATUS_OK;
+
for (i = 0; i <= timeout_us; i += 100) {
if (dmub->hw_funcs.is_auto_load_done(dmub))
return DMUB_STATUS_OK;
{
uint32_t i = 0;
- if (!dmub->hw_init || !dmub->hw_funcs.is_phy_init)
+ if (!dmub->hw_init)
return DMUB_STATUS_INVALID;
+ if (!dmub->hw_funcs.is_phy_init)
+ return DMUB_STATUS_OK;
+
for (i = 0; i <= timeout_us; i += 10) {
if (dmub->hw_funcs.is_phy_init(dmub))
return DMUB_STATUS_OK;