All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] drm/amd/display: Don't load DMCU for Raven 1 (v2)
@ 2019-05-24 15:34 Alex Deucher
  2019-05-24 16:09 ` Mike Lothian
  0 siblings, 1 reply; 7+ messages in thread
From: Alex Deucher @ 2019-05-24 15:34 UTC (permalink / raw)
  To: amd-gfx; +Cc: Harry Wentland, Nicholas Kazlauskas, Alex Deucher, stable

From: Harry Wentland <harry.wentland@amd.com>

[WHY]
Some early Raven boards had a bad SBIOS that doesn't play nicely with
the DMCU FW. We thought the issues were fixed by ignoring errors on DMCU
load but that doesn't seem to be the case. We've still seen reports of
users unable to boot their systems at all.

[HOW]
Disable DMCU load on Raven 1. Only load it for Raven 2 and Picasso.

v2: Fix ifdef (Alex)

Signed-off-by: Harry Wentland <harry.wentland@amd.com>
Reviewed-by: Nicholas Kazlauskas <nicholas.kazlauskas@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Cc: stable@vger.kernel.org
---
 drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 12 ++++++++++--
 1 file changed, 10 insertions(+), 2 deletions(-)

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 995f9df66142..bcb1a93c0b4c 100644
--- a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c
+++ b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c
@@ -29,6 +29,7 @@
 #include "dm_services_types.h"
 #include "dc.h"
 #include "dc/inc/core_types.h"
+#include "dal_asic_id.h"
 
 #include "vid.h"
 #include "amdgpu.h"
@@ -640,7 +641,7 @@ static void amdgpu_dm_fini(struct amdgpu_device *adev)
 
 static int load_dmcu_fw(struct amdgpu_device *adev)
 {
-	const char *fw_name_dmcu;
+	const char *fw_name_dmcu = NULL;
 	int r;
 	const struct dmcu_firmware_header_v1_0 *hdr;
 
@@ -663,7 +664,14 @@ static int load_dmcu_fw(struct amdgpu_device *adev)
 	case CHIP_VEGA20:
 		return 0;
 	case CHIP_RAVEN:
-		fw_name_dmcu = FIRMWARE_RAVEN_DMCU;
+#if defined(CONFIG_DRM_AMD_DC_DCN1_01)
+		if (ASICREV_IS_PICASSO(adev->external_rev_id))
+			fw_name_dmcu = FIRMWARE_RAVEN_DMCU;
+		else if (ASICREV_IS_RAVEN2(adev->external_rev_id))
+			fw_name_dmcu = FIRMWARE_RAVEN_DMCU;
+		else
+#endif
+			return 0;
 		break;
 	default:
 		DRM_ERROR("Unsupported ASIC type: 0x%X\n", adev->asic_type);
-- 
2.20.1


^ permalink raw reply related	[flat|nested] 7+ messages in thread

* Re: [PATCH] drm/amd/display: Don't load DMCU for Raven 1 (v2)
  2019-05-24 15:34 [PATCH] drm/amd/display: Don't load DMCU for Raven 1 (v2) Alex Deucher
@ 2019-05-24 16:09 ` Mike Lothian
  2019-05-24 16:20   ` Alex Deucher
  0 siblings, 1 reply; 7+ messages in thread
From: Mike Lothian @ 2019-05-24 16:09 UTC (permalink / raw)
  To: Alex Deucher
  Cc: amd-gfx list, Alex Deucher, Harry Wentland, Nicholas Kazlauskas, stable

Hi

Curious to know what this means for folk that have newer Raven1 boards
that didn't have issues loading the firmware

Cheers

Mike

On Fri, 24 May 2019 at 16:34, Alex Deucher <alexdeucher@gmail.com> wrote:
>
> From: Harry Wentland <harry.wentland@amd.com>
>
> [WHY]
> Some early Raven boards had a bad SBIOS that doesn't play nicely with
> the DMCU FW. We thought the issues were fixed by ignoring errors on DMCU
> load but that doesn't seem to be the case. We've still seen reports of
> users unable to boot their systems at all.
>
> [HOW]
> Disable DMCU load on Raven 1. Only load it for Raven 2 and Picasso.
>
> v2: Fix ifdef (Alex)
>
> Signed-off-by: Harry Wentland <harry.wentland@amd.com>
> Reviewed-by: Nicholas Kazlauskas <nicholas.kazlauskas@amd.com>
> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
> Cc: stable@vger.kernel.org
> ---
>  drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 12 ++++++++++--
>  1 file changed, 10 insertions(+), 2 deletions(-)
>
> 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 995f9df66142..bcb1a93c0b4c 100644
> --- a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c
> +++ b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c
> @@ -29,6 +29,7 @@
>  #include "dm_services_types.h"
>  #include "dc.h"
>  #include "dc/inc/core_types.h"
> +#include "dal_asic_id.h"
>
>  #include "vid.h"
>  #include "amdgpu.h"
> @@ -640,7 +641,7 @@ static void amdgpu_dm_fini(struct amdgpu_device *adev)
>
>  static int load_dmcu_fw(struct amdgpu_device *adev)
>  {
> -       const char *fw_name_dmcu;
> +       const char *fw_name_dmcu = NULL;
>         int r;
>         const struct dmcu_firmware_header_v1_0 *hdr;
>
> @@ -663,7 +664,14 @@ static int load_dmcu_fw(struct amdgpu_device *adev)
>         case CHIP_VEGA20:
>                 return 0;
>         case CHIP_RAVEN:
> -               fw_name_dmcu = FIRMWARE_RAVEN_DMCU;
> +#if defined(CONFIG_DRM_AMD_DC_DCN1_01)
> +               if (ASICREV_IS_PICASSO(adev->external_rev_id))
> +                       fw_name_dmcu = FIRMWARE_RAVEN_DMCU;
> +               else if (ASICREV_IS_RAVEN2(adev->external_rev_id))
> +                       fw_name_dmcu = FIRMWARE_RAVEN_DMCU;
> +               else
> +#endif
> +                       return 0;
>                 break;
>         default:
>                 DRM_ERROR("Unsupported ASIC type: 0x%X\n", adev->asic_type);
> --
> 2.20.1
>
> _______________________________________________
> amd-gfx mailing list
> amd-gfx@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/amd-gfx

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [PATCH] drm/amd/display: Don't load DMCU for Raven 1 (v2)
  2019-05-24 16:09 ` Mike Lothian
@ 2019-05-24 16:20   ` Alex Deucher
  2019-05-24 16:32     ` Mike Lothian
  0 siblings, 1 reply; 7+ messages in thread
From: Alex Deucher @ 2019-05-24 16:20 UTC (permalink / raw)
  To: Mike Lothian
  Cc: amd-gfx list, Alex Deucher, Harry Wentland, Nicholas Kazlauskas, for 3.8

On Fri, May 24, 2019 at 12:09 PM Mike Lothian <mike@fireburn.co.uk> wrote:
>
> Hi
>
> Curious to know what this means for folk that have newer Raven1 boards
> that didn't have issues loading the firmware

You won't get ABM I think.  ABM is the automatic backlight management.

Alex

>
> Cheers
>
> Mike
>
> On Fri, 24 May 2019 at 16:34, Alex Deucher <alexdeucher@gmail.com> wrote:
> >
> > From: Harry Wentland <harry.wentland@amd.com>
> >
> > [WHY]
> > Some early Raven boards had a bad SBIOS that doesn't play nicely with
> > the DMCU FW. We thought the issues were fixed by ignoring errors on DMCU
> > load but that doesn't seem to be the case. We've still seen reports of
> > users unable to boot their systems at all.
> >
> > [HOW]
> > Disable DMCU load on Raven 1. Only load it for Raven 2 and Picasso.
> >
> > v2: Fix ifdef (Alex)
> >
> > Signed-off-by: Harry Wentland <harry.wentland@amd.com>
> > Reviewed-by: Nicholas Kazlauskas <nicholas.kazlauskas@amd.com>
> > Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
> > Cc: stable@vger.kernel.org
> > ---
> >  drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 12 ++++++++++--
> >  1 file changed, 10 insertions(+), 2 deletions(-)
> >
> > 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 995f9df66142..bcb1a93c0b4c 100644
> > --- a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c
> > +++ b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c
> > @@ -29,6 +29,7 @@
> >  #include "dm_services_types.h"
> >  #include "dc.h"
> >  #include "dc/inc/core_types.h"
> > +#include "dal_asic_id.h"
> >
> >  #include "vid.h"
> >  #include "amdgpu.h"
> > @@ -640,7 +641,7 @@ static void amdgpu_dm_fini(struct amdgpu_device *adev)
> >
> >  static int load_dmcu_fw(struct amdgpu_device *adev)
> >  {
> > -       const char *fw_name_dmcu;
> > +       const char *fw_name_dmcu = NULL;
> >         int r;
> >         const struct dmcu_firmware_header_v1_0 *hdr;
> >
> > @@ -663,7 +664,14 @@ static int load_dmcu_fw(struct amdgpu_device *adev)
> >         case CHIP_VEGA20:
> >                 return 0;
> >         case CHIP_RAVEN:
> > -               fw_name_dmcu = FIRMWARE_RAVEN_DMCU;
> > +#if defined(CONFIG_DRM_AMD_DC_DCN1_01)
> > +               if (ASICREV_IS_PICASSO(adev->external_rev_id))
> > +                       fw_name_dmcu = FIRMWARE_RAVEN_DMCU;
> > +               else if (ASICREV_IS_RAVEN2(adev->external_rev_id))
> > +                       fw_name_dmcu = FIRMWARE_RAVEN_DMCU;
> > +               else
> > +#endif
> > +                       return 0;
> >                 break;
> >         default:
> >                 DRM_ERROR("Unsupported ASIC type: 0x%X\n", adev->asic_type);
> > --
> > 2.20.1
> >
> > _______________________________________________
> > amd-gfx mailing list
> > amd-gfx@lists.freedesktop.org
> > https://lists.freedesktop.org/mailman/listinfo/amd-gfx

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [PATCH] drm/amd/display: Don't load DMCU for Raven 1 (v2)
  2019-05-24 16:20   ` Alex Deucher
@ 2019-05-24 16:32     ` Mike Lothian
  2019-05-24 16:49       ` Alex Deucher
  0 siblings, 1 reply; 7+ messages in thread
From: Mike Lothian @ 2019-05-24 16:32 UTC (permalink / raw)
  To: Alex Deucher
  Cc: amd-gfx list, Alex Deucher, Harry Wentland, Nicholas Kazlauskas, for 3.8

I realise you don't want to enable this as it's breaking some people's
systems, but could we add a new boot parameter to force it for working
systems? Or check against a black list maybe?

On Fri, 24 May 2019 at 17:20, Alex Deucher <alexdeucher@gmail.com> wrote:
>
> On Fri, May 24, 2019 at 12:09 PM Mike Lothian <mike@fireburn.co.uk> wrote:
> >
> > Hi
> >
> > Curious to know what this means for folk that have newer Raven1 boards
> > that didn't have issues loading the firmware
>
> You won't get ABM I think.  ABM is the automatic backlight management.
>
> Alex
>
> >
> > Cheers
> >
> > Mike
> >
> > On Fri, 24 May 2019 at 16:34, Alex Deucher <alexdeucher@gmail.com> wrote:
> > >
> > > From: Harry Wentland <harry.wentland@amd.com>
> > >
> > > [WHY]
> > > Some early Raven boards had a bad SBIOS that doesn't play nicely with
> > > the DMCU FW. We thought the issues were fixed by ignoring errors on DMCU
> > > load but that doesn't seem to be the case. We've still seen reports of
> > > users unable to boot their systems at all.
> > >
> > > [HOW]
> > > Disable DMCU load on Raven 1. Only load it for Raven 2 and Picasso.
> > >
> > > v2: Fix ifdef (Alex)
> > >
> > > Signed-off-by: Harry Wentland <harry.wentland@amd.com>
> > > Reviewed-by: Nicholas Kazlauskas <nicholas.kazlauskas@amd.com>
> > > Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
> > > Cc: stable@vger.kernel.org
> > > ---
> > >  drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 12 ++++++++++--
> > >  1 file changed, 10 insertions(+), 2 deletions(-)
> > >
> > > 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 995f9df66142..bcb1a93c0b4c 100644
> > > --- a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c
> > > +++ b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c
> > > @@ -29,6 +29,7 @@
> > >  #include "dm_services_types.h"
> > >  #include "dc.h"
> > >  #include "dc/inc/core_types.h"
> > > +#include "dal_asic_id.h"
> > >
> > >  #include "vid.h"
> > >  #include "amdgpu.h"
> > > @@ -640,7 +641,7 @@ static void amdgpu_dm_fini(struct amdgpu_device *adev)
> > >
> > >  static int load_dmcu_fw(struct amdgpu_device *adev)
> > >  {
> > > -       const char *fw_name_dmcu;
> > > +       const char *fw_name_dmcu = NULL;
> > >         int r;
> > >         const struct dmcu_firmware_header_v1_0 *hdr;
> > >
> > > @@ -663,7 +664,14 @@ static int load_dmcu_fw(struct amdgpu_device *adev)
> > >         case CHIP_VEGA20:
> > >                 return 0;
> > >         case CHIP_RAVEN:
> > > -               fw_name_dmcu = FIRMWARE_RAVEN_DMCU;
> > > +#if defined(CONFIG_DRM_AMD_DC_DCN1_01)
> > > +               if (ASICREV_IS_PICASSO(adev->external_rev_id))
> > > +                       fw_name_dmcu = FIRMWARE_RAVEN_DMCU;
> > > +               else if (ASICREV_IS_RAVEN2(adev->external_rev_id))
> > > +                       fw_name_dmcu = FIRMWARE_RAVEN_DMCU;
> > > +               else
> > > +#endif
> > > +                       return 0;
> > >                 break;
> > >         default:
> > >                 DRM_ERROR("Unsupported ASIC type: 0x%X\n", adev->asic_type);
> > > --
> > > 2.20.1
> > >
> > > _______________________________________________
> > > amd-gfx mailing list
> > > amd-gfx@lists.freedesktop.org
> > > https://lists.freedesktop.org/mailman/listinfo/amd-gfx

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [PATCH] drm/amd/display: Don't load DMCU for Raven 1 (v2)
  2019-05-24 16:32     ` Mike Lothian
@ 2019-05-24 16:49       ` Alex Deucher
       [not found]         ` <CADnq5_N48x5Zas_HWTN1JdEgUUmFadsSiu5_1uZmRgaDw+qraw-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
  0 siblings, 1 reply; 7+ messages in thread
From: Alex Deucher @ 2019-05-24 16:49 UTC (permalink / raw)
  To: Mike Lothian
  Cc: amd-gfx list, Alex Deucher, Harry Wentland, Nicholas Kazlauskas, for 3.8

On Fri, May 24, 2019 at 12:32 PM Mike Lothian <mike@fireburn.co.uk> wrote:
>
> I realise you don't want to enable this as it's breaking some people's
> systems, but could we add a new boot parameter to force it for working
> systems? Or check against a black list maybe?

We could probably add a whitelist.  I'm not sure what the best way to
id the working systems are though.

Alex

>
> On Fri, 24 May 2019 at 17:20, Alex Deucher <alexdeucher@gmail.com> wrote:
> >
> > On Fri, May 24, 2019 at 12:09 PM Mike Lothian <mike@fireburn.co.uk> wrote:
> > >
> > > Hi
> > >
> > > Curious to know what this means for folk that have newer Raven1 boards
> > > that didn't have issues loading the firmware
> >
> > You won't get ABM I think.  ABM is the automatic backlight management.
> >
> > Alex
> >
> > >
> > > Cheers
> > >
> > > Mike
> > >
> > > On Fri, 24 May 2019 at 16:34, Alex Deucher <alexdeucher@gmail.com> wrote:
> > > >
> > > > From: Harry Wentland <harry.wentland@amd.com>
> > > >
> > > > [WHY]
> > > > Some early Raven boards had a bad SBIOS that doesn't play nicely with
> > > > the DMCU FW. We thought the issues were fixed by ignoring errors on DMCU
> > > > load but that doesn't seem to be the case. We've still seen reports of
> > > > users unable to boot their systems at all.
> > > >
> > > > [HOW]
> > > > Disable DMCU load on Raven 1. Only load it for Raven 2 and Picasso.
> > > >
> > > > v2: Fix ifdef (Alex)
> > > >
> > > > Signed-off-by: Harry Wentland <harry.wentland@amd.com>
> > > > Reviewed-by: Nicholas Kazlauskas <nicholas.kazlauskas@amd.com>
> > > > Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
> > > > Cc: stable@vger.kernel.org
> > > > ---
> > > >  drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 12 ++++++++++--
> > > >  1 file changed, 10 insertions(+), 2 deletions(-)
> > > >
> > > > 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 995f9df66142..bcb1a93c0b4c 100644
> > > > --- a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c
> > > > +++ b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c
> > > > @@ -29,6 +29,7 @@
> > > >  #include "dm_services_types.h"
> > > >  #include "dc.h"
> > > >  #include "dc/inc/core_types.h"
> > > > +#include "dal_asic_id.h"
> > > >
> > > >  #include "vid.h"
> > > >  #include "amdgpu.h"
> > > > @@ -640,7 +641,7 @@ static void amdgpu_dm_fini(struct amdgpu_device *adev)
> > > >
> > > >  static int load_dmcu_fw(struct amdgpu_device *adev)
> > > >  {
> > > > -       const char *fw_name_dmcu;
> > > > +       const char *fw_name_dmcu = NULL;
> > > >         int r;
> > > >         const struct dmcu_firmware_header_v1_0 *hdr;
> > > >
> > > > @@ -663,7 +664,14 @@ static int load_dmcu_fw(struct amdgpu_device *adev)
> > > >         case CHIP_VEGA20:
> > > >                 return 0;
> > > >         case CHIP_RAVEN:
> > > > -               fw_name_dmcu = FIRMWARE_RAVEN_DMCU;
> > > > +#if defined(CONFIG_DRM_AMD_DC_DCN1_01)
> > > > +               if (ASICREV_IS_PICASSO(adev->external_rev_id))
> > > > +                       fw_name_dmcu = FIRMWARE_RAVEN_DMCU;
> > > > +               else if (ASICREV_IS_RAVEN2(adev->external_rev_id))
> > > > +                       fw_name_dmcu = FIRMWARE_RAVEN_DMCU;
> > > > +               else
> > > > +#endif
> > > > +                       return 0;
> > > >                 break;
> > > >         default:
> > > >                 DRM_ERROR("Unsupported ASIC type: 0x%X\n", adev->asic_type);
> > > > --
> > > > 2.20.1
> > > >
> > > > _______________________________________________
> > > > amd-gfx mailing list
> > > > amd-gfx@lists.freedesktop.org
> > > > https://lists.freedesktop.org/mailman/listinfo/amd-gfx

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [PATCH] drm/amd/display: Don't load DMCU for Raven 1 (v2)
       [not found]         ` <CADnq5_N48x5Zas_HWTN1JdEgUUmFadsSiu5_1uZmRgaDw+qraw-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
@ 2019-05-30 14:40           ` Samantha McVey
  2019-05-30 15:55             ` Alex Deucher
  0 siblings, 1 reply; 7+ messages in thread
From: Samantha McVey @ 2019-05-30 14:40 UTC (permalink / raw)
  To: amd-gfx-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW


[-- Attachment #1.1: Type: text/plain, Size: 4414 bytes --]

Alex,

Are any of these non-booting systems laptops? If all the laptops don't have this issue, is 
there a way we can detect we are on mobile and load the DMCU? Seeing as ABM and PSR 
are both practically only used on mobile, maybe we can check for that. This way we only 
enable it on systems that actually need the features. I am guessing the number of Raven 
Ridge laptops is much much smaller than the number of motherboards which can 
potentially support Raven Ridge.

On vrijdag 24 mei 2019 18:49:27 CEST you wrote:
> On Fri, May 24, 2019 at 12:32 PM Mike Lothian <mike at fireburn.co.uk> wrote:
> > I realise you don't want to enable this as it's breaking some people's
> > systems, but could we add a new boot parameter to force it for working
> > systems? Or check against a black list maybe?
> 
> We could probably add a whitelist.  I'm not sure what the best way to
> id the working systems are though.
> 
> Alex
> 
> > On Fri, 24 May 2019 at 17:20, Alex Deucher <alexdeucher at gmail.com> wrote:
> > > On Fri, May 24, 2019 at 12:09 PM Mike Lothian <mike at fireburn.co.uk> wrote:
> > > > Hi
> > > > 
> > > > Curious to know what this means for folk that have newer Raven1 boards
> > > > that didn't have issues loading the firmware
> > > 
> > > You won't get ABM I think.  ABM is the automatic backlight management.
> > > 
> > > Alex
> > > 
> > > > Cheers
> > > > 
> > > > Mike
> > > > 
> > > > On Fri, 24 May 2019 at 16:34, Alex Deucher <alexdeucher at gmail.com> wrote:
> > > > > From: Harry Wentland <harry.wentland at amd.com>
> > > > > 
> > > > > [WHY]
> > > > > Some early Raven boards had a bad SBIOS that doesn't play nicely
> > > > > with
> > > > > the DMCU FW. We thought the issues were fixed by ignoring errors on
> > > > > DMCU
> > > > > load but that doesn't seem to be the case. We've still seen reports
> > > > > of
> > > > > users unable to boot their systems at all.
> > > > > 
> > > > > [HOW]
> > > > > Disable DMCU load on Raven 1. Only load it for Raven 2 and Picasso.
> > > > > 
> > > > > v2: Fix ifdef (Alex)
> > > > > 
> > > > > Signed-off-by: Harry Wentland <harry.wentland at amd.com>
> > > > > Reviewed-by: Nicholas Kazlauskas <nicholas.kazlauskas at amd.com>
> > > > > Signed-off-by: Alex Deucher <alexander.deucher at amd.com>
> > > > > Cc: stable at vger.kernel.org
> > > > > ---
> > > > > 
> > > > >  drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 12 ++++++++++--
> > > > >  1 file changed, 10 insertions(+), 2 deletions(-)
> > > > > 
> > > > > 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
> > > > > 995f9df66142..bcb1a93c0b4c 100644
> > > > > --- a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c
> > > > > +++ b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c
> > > > > @@ -29,6 +29,7 @@
> > > > > 
> > > > >  #include "dm_services_types.h"
> > > > >  #include "dc.h"
> > > > >  #include "dc/inc/core_types.h"
> > > > > 
> > > > > +#include "dal_asic_id.h"
> > > > > 
> > > > >  #include "vid.h"
> > > > >  #include "amdgpu.h"
> > > > > 
> > > > > @@ -640,7 +641,7 @@ static void amdgpu_dm_fini(struct amdgpu_device
> > > > > *adev)
> > > > > 
> > > > >  static int load_dmcu_fw(struct amdgpu_device *adev)
> > > > >  {
> > > > > 
> > > > > -       const char *fw_name_dmcu;
> > > > > +       const char *fw_name_dmcu = NULL;
> > > > > 
> > > > >         int r;
> > > > >         const struct dmcu_firmware_header_v1_0 *hdr;
> > > > > 
> > > > > @@ -663,7 +664,14 @@ static int load_dmcu_fw(struct amdgpu_device
> > > > > *adev)
> > > > > 
> > > > >         case CHIP_VEGA20:
> > > > >                 return 0;
> > > > >         
> > > > >         case CHIP_RAVEN:
> > > > > -               fw_name_dmcu = FIRMWARE_RAVEN_DMCU;
> > > > > +#if defined(CONFIG_DRM_AMD_DC_DCN1_01)
> > > > > +               if (ASICREV_IS_PICASSO(adev->external_rev_id))
> > > > > +                       fw_name_dmcu = FIRMWARE_RAVEN_DMCU;
> > > > > +               else if (ASICREV_IS_RAVEN2(adev->external_rev_id))
> > > > > +                       fw_name_dmcu = FIRMWARE_RAVEN_DMCU;
> > > > > +               else
> > > > > +#endif
> > > > > +                       return 0;
> > > > > 
> > > > >                 break;
> > > > >         
> > > > >         default:
> > > > >                 DRM_ERROR("Unsupported ASIC type: 0x%X\n",
> > > > >                 adev->asic_type);
> > > > > 

[-- Attachment #1.2: Type: text/html, Size: 22650 bytes --]

[-- Attachment #2: Type: text/plain, Size: 153 bytes --]

_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [PATCH] drm/amd/display: Don't load DMCU for Raven 1 (v2)
  2019-05-30 14:40           ` Samantha McVey
@ 2019-05-30 15:55             ` Alex Deucher
  0 siblings, 0 replies; 7+ messages in thread
From: Alex Deucher @ 2019-05-30 15:55 UTC (permalink / raw)
  To: Samantha McVey; +Cc: amd-gfx list

On Thu, May 30, 2019 at 10:48 AM Samantha McVey <samantham@posteo.net> wrote:
>
> Alex,
>
>
>
> Are any of these non-booting systems laptops? If all the laptops don't have this issue, is there a way we can detect we are on mobile and load the DMCU? Seeing as ABM and PSR are both practically only used on mobile, maybe we can check for that. This way we only enable it on systems that actually need the features. I am guessing the number of Raven Ridge laptops is much much smaller than the number of motherboards which can potentially support Raven Ridge.
>
>

Mostly if not exclusively laptops.  DMCU doesn't really have much use
on desktops since there is no eDP panel in most cases.  We don't
currently support PSR so it's really only ABM.

Alex

>
> On vrijdag 24 mei 2019 18:49:27 CEST you wrote:
>
> > On Fri, May 24, 2019 at 12:32 PM Mike Lothian <mike at fireburn.co.uk> wrote:
>
> > > I realise you don't want to enable this as it's breaking some people's
>
> > > systems, but could we add a new boot parameter to force it for working
>
> > > systems? Or check against a black list maybe?
>
> >
>
> > We could probably add a whitelist. I'm not sure what the best way to
>
> > id the working systems are though.
>
> >
>
> > Alex
>
> >
>
> > > On Fri, 24 May 2019 at 17:20, Alex Deucher <alexdeucher at gmail.com> wrote:
>
> > > > On Fri, May 24, 2019 at 12:09 PM Mike Lothian <mike at fireburn.co.uk> wrote:
>
> > > > > Hi
>
> > > > >
>
> > > > > Curious to know what this means for folk that have newer Raven1 boards
>
> > > > > that didn't have issues loading the firmware
>
> > > >
>
> > > > You won't get ABM I think. ABM is the automatic backlight management.
>
> > > >
>
> > > > Alex
>
> > > >
>
> > > > > Cheers
>
> > > > >
>
> > > > > Mike
>
> > > > >
>
> > > > > On Fri, 24 May 2019 at 16:34, Alex Deucher <alexdeucher at gmail.com> wrote:
>
> > > > > > From: Harry Wentland <harry.wentland at amd.com>
>
> > > > > >
>
> > > > > > [WHY]
>
> > > > > > Some early Raven boards had a bad SBIOS that doesn't play nicely
>
> > > > > > with
>
> > > > > > the DMCU FW. We thought the issues were fixed by ignoring errors on
>
> > > > > > DMCU
>
> > > > > > load but that doesn't seem to be the case. We've still seen reports
>
> > > > > > of
>
> > > > > > users unable to boot their systems at all.
>
> > > > > >
>
> > > > > > [HOW]
>
> > > > > > Disable DMCU load on Raven 1. Only load it for Raven 2 and Picasso.
>
> > > > > >
>
> > > > > > v2: Fix ifdef (Alex)
>
> > > > > >
>
> > > > > > Signed-off-by: Harry Wentland <harry.wentland at amd.com>
>
> > > > > > Reviewed-by: Nicholas Kazlauskas <nicholas.kazlauskas at amd.com>
>
> > > > > > Signed-off-by: Alex Deucher <alexander.deucher at amd.com>
>
> > > > > > Cc: stable at vger.kernel.org
>
> > > > > > ---
>
> > > > > >
>
> > > > > > drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 12 ++++++++++--
>
> > > > > > 1 file changed, 10 insertions(+), 2 deletions(-)
>
> > > > > >
>
> > > > > > 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
>
> > > > > > 995f9df66142..bcb1a93c0b4c 100644
>
> > > > > > --- a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c
>
> > > > > > +++ b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c
>
> > > > > > @@ -29,6 +29,7 @@
>
> > > > > >
>
> > > > > > #include "dm_services_types.h"
>
> > > > > > #include "dc.h"
>
> > > > > > #include "dc/inc/core_types.h"
>
> > > > > >
>
> > > > > > +#include "dal_asic_id.h"
>
> > > > > >
>
> > > > > > #include "vid.h"
>
> > > > > > #include "amdgpu.h"
>
> > > > > >
>
> > > > > > @@ -640,7 +641,7 @@ static void amdgpu_dm_fini(struct amdgpu_device
>
> > > > > > *adev)
>
> > > > > >
>
> > > > > > static int load_dmcu_fw(struct amdgpu_device *adev)
>
> > > > > > {
>
> > > > > >
>
> > > > > > - const char *fw_name_dmcu;
>
> > > > > > + const char *fw_name_dmcu = NULL;
>
> > > > > >
>
> > > > > > int r;
>
> > > > > > const struct dmcu_firmware_header_v1_0 *hdr;
>
> > > > > >
>
> > > > > > @@ -663,7 +664,14 @@ static int load_dmcu_fw(struct amdgpu_device
>
> > > > > > *adev)
>
> > > > > >
>
> > > > > > case CHIP_VEGA20:
>
> > > > > > return 0;
>
> > > > > >
>
> > > > > > case CHIP_RAVEN:
>
> > > > > > - fw_name_dmcu = FIRMWARE_RAVEN_DMCU;
>
> > > > > > +#if defined(CONFIG_DRM_AMD_DC_DCN1_01)
>
> > > > > > + if (ASICREV_IS_PICASSO(adev->external_rev_id))
>
> > > > > > + fw_name_dmcu = FIRMWARE_RAVEN_DMCU;
>
> > > > > > + else if (ASICREV_IS_RAVEN2(adev->external_rev_id))
>
> > > > > > + fw_name_dmcu = FIRMWARE_RAVEN_DMCU;
>
> > > > > > + else
>
> > > > > > +#endif
>
> > > > > > + return 0;
>
> > > > > >
>
> > > > > > break;
>
> > > > > >
>
> > > > > > default:
>
> > > > > > DRM_ERROR("Unsupported ASIC type: 0x%X\n",
>
> > > > > > adev->asic_type);
>
> > > > > >
>
> > > > > > --
>
> > > > > > 2.20.1
>
> > > > > >
>
> > > > > > _______________________________________________
>
> > > > > > amd-gfx mailing list
>
> > > > > > amd-gfx at lists.freedesktop.org
>
> > > > > > https://lists.freedesktop.org/mailman/listinfo/amd-gfx
>
> _______________________________________________
> amd-gfx mailing list
> amd-gfx@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/amd-gfx
_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2019-05-30 15:55 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-05-24 15:34 [PATCH] drm/amd/display: Don't load DMCU for Raven 1 (v2) Alex Deucher
2019-05-24 16:09 ` Mike Lothian
2019-05-24 16:20   ` Alex Deucher
2019-05-24 16:32     ` Mike Lothian
2019-05-24 16:49       ` Alex Deucher
     [not found]         ` <CADnq5_N48x5Zas_HWTN1JdEgUUmFadsSiu5_1uZmRgaDw+qraw-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2019-05-30 14:40           ` Samantha McVey
2019-05-30 15:55             ` Alex Deucher

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.