[Public] > -----Original Message----- > From: Alex Deucher <alexdeucher@xxxxxxxxx> > Sent: Friday, October 29, 2021 15:24 > To: Limonciello, Mario <Mario.Limonciello@xxxxxxx> > Cc: amd-gfx list <amd-gfx@xxxxxxxxxxxxxxxxxxxxx>; Li, Roman > <Roman.Li@xxxxxxx> > Subject: Re: [PATCH] drm/amd/display: Look at firmware version to determine > using dmub on dcn21 > > On Fri, Oct 29, 2021 at 4:19 PM Alex Deucher <alexdeucher@xxxxxxxxx> wrote: > > > > On Fri, Oct 29, 2021 at 4:12 PM Mario Limonciello > > <mario.limonciello@xxxxxxx> wrote: > > > > > > commit b1c61212d8dc ("drm/amd/display: Fully switch to dmub for all dcn21 > > > asics") switched over to using dmub on Renoir to fix Gitlab 1735, but this > > > implied a new dependency on newer firmware which might not be met on > older > > > kernel versions. > > > > > > Since sw_init runs before hw_init, there is an opportunity to determine > > > whether or not the firmware version is new to adjust the behavior. > > > > > > Cc: Roman.Li@xxxxxxx > > > BugLink: > https://nam11.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgitlab.fr > eedesktop.org%2Fdrm%2Famd%2F- > %2Fissues%2F1772&data=04%7C01%7Cmario.limonciello%40amd.com%7 > C03c84193638144254d6f08d99b1a147c%7C3dd8961fe4884e608e11a82d994e1 > 83d%7C0%7C0%7C637711358602513049%7CUnknown%7CTWFpbGZsb3d8eyJ > WIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C > 1000&sdata=frHB0cKKTUHWxj0t8kFBBYTlGapT2dpqUOddJyuPeZ0%3D&am > p;reserved=0 > > > BugLink: > https://nam11.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgitlab.fr > eedesktop.org%2Fdrm%2Famd%2F- > %2Fissues%2F1735&data=04%7C01%7Cmario.limonciello%40amd.com%7 > C03c84193638144254d6f08d99b1a147c%7C3dd8961fe4884e608e11a82d994e1 > 83d%7C0%7C0%7C637711358602522996%7CUnknown%7CTWFpbGZsb3d8eyJ > WIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C > 1000&sdata=dOqYHWrdTNrJdqdTL1OFJHJVY8ntiLG%2BJzWSqGLSn5w%3D > &reserved=0 > > > Fixes: b1c61212d8dc ("drm/amd/display: Fully switch to dmub for all dcn21 > asics") > > > Signed-off-by: Mario Limonciello <mario.limonciello@xxxxxxx> > > > > Acked-by: Alex Deucher <alexander.deucher@xxxxxxx> > > Actually if there are version differences between renoir and green > sardine, maybe we need to bring back the old logic. E.g., > if (ASICREV_IS_GREEN_SARDINE(adev->external_rev_id)) > init_data.flags.disable_dmcu = true; > else > init_data.flags.disable_dmcu = adev->dm.dmcub_fw_version > 0x01000000; > Good point - I'll respin for that. > Alex > > > > > > --- > > > drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 2 +- > > > 1 file changed, 1 insertion(+), 1 deletion(-) > > > > > > diff --git a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c > b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c > > > index 6dd6262f2769..85b3de97f870 100644 > > > --- a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c > > > +++ b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c > > > @@ -1410,7 +1410,7 @@ static int amdgpu_dm_init(struct amdgpu_device > *adev) > > > switch (adev->ip_versions[DCE_HWIP][0]) { > > > case IP_VERSION(2, 1, 0): > > > init_data.flags.gpu_vm_support = true; > > > - init_data.flags.disable_dmcu = true; > > > + init_data.flags.disable_dmcu = adev->dm.dmcub_fw_version > > 0x01000000; > > > break; > > > case IP_VERSION(1, 0, 0): > > > case IP_VERSION(1, 0, 1): > > > -- > > > 2.25.1 > > >