* [PATCH 2/2] panfrost: Add compatible string for bifrost
2020-06-11 8:58 [PATCH 1/2] panfrost: Make sure GPU is powered on when reading GPU_LATEST_FLUSH_ID Tomeu Vizoso
@ 2020-06-11 8:58 ` Tomeu Vizoso
2020-06-11 9:07 ` Heiko Stuebner
2020-06-19 9:00 ` Steven Price
2020-06-11 9:05 ` [PATCH 1/2] panfrost: Make sure GPU is powered on when reading GPU_LATEST_FLUSH_ID Heiko Stuebner
` (3 subsequent siblings)
4 siblings, 2 replies; 10+ messages in thread
From: Tomeu Vizoso @ 2020-06-11 8:58 UTC (permalink / raw)
To: LKML
Cc: Tomeu Vizoso, David Airlie, dri-devel, Steven Price, Alyssa Rosenzweig
Mesa now supports some Bifrost devices, so enable it.
Signed-off-by: Tomeu Vizoso <tomeu.vizoso@collabora.com>
---
drivers/gpu/drm/panfrost/panfrost_drv.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/gpu/drm/panfrost/panfrost_drv.c b/drivers/gpu/drm/panfrost/panfrost_drv.c
index 882fecc33fdb..8ff8e140f91e 100644
--- a/drivers/gpu/drm/panfrost/panfrost_drv.c
+++ b/drivers/gpu/drm/panfrost/panfrost_drv.c
@@ -677,6 +677,7 @@ static const struct of_device_id dt_match[] = {
{ .compatible = "arm,mali-t830", .data = &default_data, },
{ .compatible = "arm,mali-t860", .data = &default_data, },
{ .compatible = "arm,mali-t880", .data = &default_data, },
+ { .compatible = "arm,mali-bifrost", .data = &default_data, },
{}
};
MODULE_DEVICE_TABLE(of, dt_match);
--
2.21.0
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel
^ permalink raw reply related [flat|nested] 10+ messages in thread
* Re: [PATCH 2/2] panfrost: Add compatible string for bifrost
2020-06-11 8:58 ` [PATCH 2/2] panfrost: Add compatible string for bifrost Tomeu Vizoso
@ 2020-06-11 9:07 ` Heiko Stuebner
2020-06-19 9:00 ` Steven Price
1 sibling, 0 replies; 10+ messages in thread
From: Heiko Stuebner @ 2020-06-11 9:07 UTC (permalink / raw)
To: dri-devel
Cc: David Airlie, Alyssa Rosenzweig, LKML, Tomeu Vizoso, Steven Price
Am Donnerstag, 11. Juni 2020, 10:58:44 CEST schrieb Tomeu Vizoso:
> Mesa now supports some Bifrost devices, so enable it.
>
> Signed-off-by: Tomeu Vizoso <tomeu.vizoso@collabora.com>
> ---
> drivers/gpu/drm/panfrost/panfrost_drv.c | 1 +
> 1 file changed, 1 insertion(+)
>
> diff --git a/drivers/gpu/drm/panfrost/panfrost_drv.c b/drivers/gpu/drm/panfrost/panfrost_drv.c
> index 882fecc33fdb..8ff8e140f91e 100644
> --- a/drivers/gpu/drm/panfrost/panfrost_drv.c
> +++ b/drivers/gpu/drm/panfrost/panfrost_drv.c
> @@ -677,6 +677,7 @@ static const struct of_device_id dt_match[] = {
> { .compatible = "arm,mali-t830", .data = &default_data, },
> { .compatible = "arm,mali-t860", .data = &default_data, },
> { .compatible = "arm,mali-t880", .data = &default_data, },
> + { .compatible = "arm,mali-bifrost", .data = &default_data, },
> {}
> };
> MODULE_DEVICE_TABLE(of, dt_match);
on a PX30-board (sibling of rk3326) with a 720x1280 panel and
glmark2 running all tests
Tested-by: Heiko Stuebner <heiko@sntech.de>
and as this is the generic compatible from the binding:
Reviewed-by: Heiko Stuebner <heiko@sntech.de>
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [PATCH 2/2] panfrost: Add compatible string for bifrost
2020-06-11 8:58 ` [PATCH 2/2] panfrost: Add compatible string for bifrost Tomeu Vizoso
2020-06-11 9:07 ` Heiko Stuebner
@ 2020-06-19 9:00 ` Steven Price
2020-10-05 6:44 ` Tomeu Vizoso
1 sibling, 1 reply; 10+ messages in thread
From: Steven Price @ 2020-06-19 9:00 UTC (permalink / raw)
To: Tomeu Vizoso, LKML; +Cc: David Airlie, dri-devel, Alyssa Rosenzweig
On 11/06/2020 09:58, Tomeu Vizoso wrote:
> Mesa now supports some Bifrost devices, so enable it.
>
> Signed-off-by: Tomeu Vizoso <tomeu.vizoso@collabora.com>
Reviewed-by: Steven Price <steven.price@arm.com>
I've also dug out my Hikey960 (from the box it's been in since lock down
started), so I'll see if I can get things running on there, at the
moment I'm seeing some DATA_INVALID_FAULT regressions running my hacked
DDK :(
Steve
> ---
> drivers/gpu/drm/panfrost/panfrost_drv.c | 1 +
> 1 file changed, 1 insertion(+)
>
> diff --git a/drivers/gpu/drm/panfrost/panfrost_drv.c b/drivers/gpu/drm/panfrost/panfrost_drv.c
> index 882fecc33fdb..8ff8e140f91e 100644
> --- a/drivers/gpu/drm/panfrost/panfrost_drv.c
> +++ b/drivers/gpu/drm/panfrost/panfrost_drv.c
> @@ -677,6 +677,7 @@ static const struct of_device_id dt_match[] = {
> { .compatible = "arm,mali-t830", .data = &default_data, },
> { .compatible = "arm,mali-t860", .data = &default_data, },
> { .compatible = "arm,mali-t880", .data = &default_data, },
> + { .compatible = "arm,mali-bifrost", .data = &default_data, },
> {}
> };
> MODULE_DEVICE_TABLE(of, dt_match);
>
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [PATCH 2/2] panfrost: Add compatible string for bifrost
2020-06-19 9:00 ` Steven Price
@ 2020-10-05 6:44 ` Tomeu Vizoso
2020-10-05 7:06 ` Tomeu Vizoso
0 siblings, 1 reply; 10+ messages in thread
From: Tomeu Vizoso @ 2020-10-05 6:44 UTC (permalink / raw)
To: Steven Price; +Cc: David Airlie, LKML, dri-devel, Alyssa Rosenzweig
On Fri, 19 Jun 2020 at 11:00, Steven Price <steven.price@arm.com> wrote:
>
> On 11/06/2020 09:58, Tomeu Vizoso wrote:
> > Mesa now supports some Bifrost devices, so enable it.
> >
> > Signed-off-by: Tomeu Vizoso <tomeu.vizoso@collabora.com>
>
> Reviewed-by: Steven Price <steven.price@arm.com>
>
> I've also dug out my Hikey960 (from the box it's been in since lock down
> started), so I'll see if I can get things running on there, at the
> moment I'm seeing some DATA_INVALID_FAULT regressions running my hacked
> DDK :(
Hi!
Has this one fallen through the cracks?
Thanks,
Tomeu
>
> Steve
>
> > ---
> > drivers/gpu/drm/panfrost/panfrost_drv.c | 1 +
> > 1 file changed, 1 insertion(+)
> >
> > diff --git a/drivers/gpu/drm/panfrost/panfrost_drv.c b/drivers/gpu/drm/panfrost/panfrost_drv.c
> > index 882fecc33fdb..8ff8e140f91e 100644
> > --- a/drivers/gpu/drm/panfrost/panfrost_drv.c
> > +++ b/drivers/gpu/drm/panfrost/panfrost_drv.c
> > @@ -677,6 +677,7 @@ static const struct of_device_id dt_match[] = {
> > { .compatible = "arm,mali-t830", .data = &default_data, },
> > { .compatible = "arm,mali-t860", .data = &default_data, },
> > { .compatible = "arm,mali-t880", .data = &default_data, },
> > + { .compatible = "arm,mali-bifrost", .data = &default_data, },
> > {}
> > };
> > MODULE_DEVICE_TABLE(of, dt_match);
> >
>
> _______________________________________________
> dri-devel mailing list
> dri-devel@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/dri-devel
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [PATCH 2/2] panfrost: Add compatible string for bifrost
2020-10-05 6:44 ` Tomeu Vizoso
@ 2020-10-05 7:06 ` Tomeu Vizoso
0 siblings, 0 replies; 10+ messages in thread
From: Tomeu Vizoso @ 2020-10-05 7:06 UTC (permalink / raw)
To: Steven Price; +Cc: David Airlie, LKML, dri-devel, Alyssa Rosenzweig
On Mon, 5 Oct 2020 at 08:44, Tomeu Vizoso <tomeu.vizoso@collabora.com> wrote:
>
> On Fri, 19 Jun 2020 at 11:00, Steven Price <steven.price@arm.com> wrote:
> >
> > On 11/06/2020 09:58, Tomeu Vizoso wrote:
> > > Mesa now supports some Bifrost devices, so enable it.
> > >
> > > Signed-off-by: Tomeu Vizoso <tomeu.vizoso@collabora.com>
> >
> > Reviewed-by: Steven Price <steven.price@arm.com>
> >
> > I've also dug out my Hikey960 (from the box it's been in since lock down
> > started), so I'll see if I can get things running on there, at the
> > moment I'm seeing some DATA_INVALID_FAULT regressions running my hacked
> > DDK :(
>
> Hi!
>
> Has this one fallen through the cracks?
Oops, sorry about the noise, I had an old checkout.
Cheers,
Tomeu
> Thanks,
>
> Tomeu
>
> >
> > Steve
> >
> > > ---
> > > drivers/gpu/drm/panfrost/panfrost_drv.c | 1 +
> > > 1 file changed, 1 insertion(+)
> > >
> > > diff --git a/drivers/gpu/drm/panfrost/panfrost_drv.c b/drivers/gpu/drm/panfrost/panfrost_drv.c
> > > index 882fecc33fdb..8ff8e140f91e 100644
> > > --- a/drivers/gpu/drm/panfrost/panfrost_drv.c
> > > +++ b/drivers/gpu/drm/panfrost/panfrost_drv.c
> > > @@ -677,6 +677,7 @@ static const struct of_device_id dt_match[] = {
> > > { .compatible = "arm,mali-t830", .data = &default_data, },
> > > { .compatible = "arm,mali-t860", .data = &default_data, },
> > > { .compatible = "arm,mali-t880", .data = &default_data, },
> > > + { .compatible = "arm,mali-bifrost", .data = &default_data, },
> > > {}
> > > };
> > > MODULE_DEVICE_TABLE(of, dt_match);
> > >
> >
> > _______________________________________________
> > dri-devel mailing list
> > dri-devel@lists.freedesktop.org
> > https://lists.freedesktop.org/mailman/listinfo/dri-devel
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [PATCH 1/2] panfrost: Make sure GPU is powered on when reading GPU_LATEST_FLUSH_ID
2020-06-11 8:58 [PATCH 1/2] panfrost: Make sure GPU is powered on when reading GPU_LATEST_FLUSH_ID Tomeu Vizoso
2020-06-11 8:58 ` [PATCH 2/2] panfrost: Add compatible string for bifrost Tomeu Vizoso
@ 2020-06-11 9:05 ` Heiko Stuebner
2020-06-11 14:11 ` Alyssa Rosenzweig
` (2 subsequent siblings)
4 siblings, 0 replies; 10+ messages in thread
From: Heiko Stuebner @ 2020-06-11 9:05 UTC (permalink / raw)
To: dri-devel
Cc: David Airlie, Alyssa Rosenzweig, LKML, Tomeu Vizoso, Steven Price
Am Donnerstag, 11. Juni 2020, 10:58:43 CEST schrieb Tomeu Vizoso:
> Bifrost devices do support the flush reduction feature, so on first job
> submit we were trying to read the register while still powered off.
>
> If the GPU is powered off, the feature doesn't bring any benefit, so
> don't try to read.
>
> Signed-off-by: Tomeu Vizoso <tomeu.vizoso@collabora.com>
on a PX30-board (sibling of rk3326) with a 720x1280 panel and
glmark2 running all tests
Tested-by: Heiko Stuebner <heiko@sntech.de>
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [PATCH 1/2] panfrost: Make sure GPU is powered on when reading GPU_LATEST_FLUSH_ID
2020-06-11 8:58 [PATCH 1/2] panfrost: Make sure GPU is powered on when reading GPU_LATEST_FLUSH_ID Tomeu Vizoso
2020-06-11 8:58 ` [PATCH 2/2] panfrost: Add compatible string for bifrost Tomeu Vizoso
2020-06-11 9:05 ` [PATCH 1/2] panfrost: Make sure GPU is powered on when reading GPU_LATEST_FLUSH_ID Heiko Stuebner
@ 2020-06-11 14:11 ` Alyssa Rosenzweig
2020-06-19 8:52 ` Steven Price
2020-08-07 19:47 ` Rob Herring
4 siblings, 0 replies; 10+ messages in thread
From: Alyssa Rosenzweig @ 2020-06-11 14:11 UTC (permalink / raw)
To: Tomeu Vizoso; +Cc: David Airlie, LKML, dri-devel, Steven Price
[-- Attachment #1.1: Type: text/plain, Size: 1740 bytes --]
Both patches are Reviewed-by: Alyssa Rosenzweig
<alyssa.rosenzweig@collabora.com>
On Thu, Jun 11, 2020 at 10:58:43AM +0200, Tomeu Vizoso wrote:
> Bifrost devices do support the flush reduction feature, so on first job
> submit we were trying to read the register while still powered off.
>
> If the GPU is powered off, the feature doesn't bring any benefit, so
> don't try to read.
>
> Signed-off-by: Tomeu Vizoso <tomeu.vizoso@collabora.com>
> ---
> drivers/gpu/drm/panfrost/panfrost_gpu.c | 14 ++++++++++++--
> 1 file changed, 12 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/gpu/drm/panfrost/panfrost_gpu.c b/drivers/gpu/drm/panfrost/panfrost_gpu.c
> index f2c1ddc41a9b..e0f190e43813 100644
> --- a/drivers/gpu/drm/panfrost/panfrost_gpu.c
> +++ b/drivers/gpu/drm/panfrost/panfrost_gpu.c
> @@ -10,6 +10,7 @@
> #include <linux/io.h>
> #include <linux/iopoll.h>
> #include <linux/platform_device.h>
> +#include <linux/pm_runtime.h>
>
> #include "panfrost_device.h"
> #include "panfrost_features.h"
> @@ -368,7 +369,16 @@ void panfrost_gpu_fini(struct panfrost_device *pfdev)
>
> u32 panfrost_gpu_get_latest_flush_id(struct panfrost_device *pfdev)
> {
> - if (panfrost_has_hw_feature(pfdev, HW_FEATURE_FLUSH_REDUCTION))
> - return gpu_read(pfdev, GPU_LATEST_FLUSH_ID);
> + u32 flush_id;
> +
> + if (panfrost_has_hw_feature(pfdev, HW_FEATURE_FLUSH_REDUCTION)) {
> + /* Flush reduction only makes sense when the GPU is kept powered on between jobs */
> + if (pm_runtime_get_if_in_use(pfdev->dev)) {
> + flush_id = gpu_read(pfdev, GPU_LATEST_FLUSH_ID);
> + pm_runtime_put(pfdev->dev);
> + return flush_id;
> + }
> + }
> +
> return 0;
> }
> --
> 2.21.0
>
[-- Attachment #1.2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]
[-- Attachment #2: Type: text/plain, Size: 160 bytes --]
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [PATCH 1/2] panfrost: Make sure GPU is powered on when reading GPU_LATEST_FLUSH_ID
2020-06-11 8:58 [PATCH 1/2] panfrost: Make sure GPU is powered on when reading GPU_LATEST_FLUSH_ID Tomeu Vizoso
` (2 preceding siblings ...)
2020-06-11 14:11 ` Alyssa Rosenzweig
@ 2020-06-19 8:52 ` Steven Price
2020-08-07 19:47 ` Rob Herring
4 siblings, 0 replies; 10+ messages in thread
From: Steven Price @ 2020-06-19 8:52 UTC (permalink / raw)
To: Tomeu Vizoso, LKML; +Cc: David Airlie, dri-devel, Alyssa Rosenzweig
On 11/06/2020 09:58, Tomeu Vizoso wrote:
> Bifrost devices do support the flush reduction feature, so on first job
> submit we were trying to read the register while still powered off.
>
> If the GPU is powered off, the feature doesn't bring any benefit, so
> don't try to read.
>
> Signed-off-by: Tomeu Vizoso <tomeu.vizoso@collabora.com>
Reviewed-by: Steven Price <steven.price@arm.com>
> ---
> drivers/gpu/drm/panfrost/panfrost_gpu.c | 14 ++++++++++++--
> 1 file changed, 12 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/gpu/drm/panfrost/panfrost_gpu.c b/drivers/gpu/drm/panfrost/panfrost_gpu.c
> index f2c1ddc41a9b..e0f190e43813 100644
> --- a/drivers/gpu/drm/panfrost/panfrost_gpu.c
> +++ b/drivers/gpu/drm/panfrost/panfrost_gpu.c
> @@ -10,6 +10,7 @@
> #include <linux/io.h>
> #include <linux/iopoll.h>
> #include <linux/platform_device.h>
> +#include <linux/pm_runtime.h>
>
> #include "panfrost_device.h"
> #include "panfrost_features.h"
> @@ -368,7 +369,16 @@ void panfrost_gpu_fini(struct panfrost_device *pfdev)
>
> u32 panfrost_gpu_get_latest_flush_id(struct panfrost_device *pfdev)
> {
> - if (panfrost_has_hw_feature(pfdev, HW_FEATURE_FLUSH_REDUCTION))
> - return gpu_read(pfdev, GPU_LATEST_FLUSH_ID);
> + u32 flush_id;
> +
> + if (panfrost_has_hw_feature(pfdev, HW_FEATURE_FLUSH_REDUCTION)) {
> + /* Flush reduction only makes sense when the GPU is kept powered on between jobs */
> + if (pm_runtime_get_if_in_use(pfdev->dev)) {
> + flush_id = gpu_read(pfdev, GPU_LATEST_FLUSH_ID);
> + pm_runtime_put(pfdev->dev);
> + return flush_id;
> + }
> + }
> +
> return 0;
> }
>
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [PATCH 1/2] panfrost: Make sure GPU is powered on when reading GPU_LATEST_FLUSH_ID
2020-06-11 8:58 [PATCH 1/2] panfrost: Make sure GPU is powered on when reading GPU_LATEST_FLUSH_ID Tomeu Vizoso
` (3 preceding siblings ...)
2020-06-19 8:52 ` Steven Price
@ 2020-08-07 19:47 ` Rob Herring
4 siblings, 0 replies; 10+ messages in thread
From: Rob Herring @ 2020-08-07 19:47 UTC (permalink / raw)
To: Tomeu Vizoso
Cc: David Airlie, LKML, dri-devel, Steven Price, Alyssa Rosenzweig
On Thu, Jun 11, 2020 at 2:59 AM Tomeu Vizoso <tomeu.vizoso@collabora.com> wrote:
>
> Bifrost devices do support the flush reduction feature, so on first job
> submit we were trying to read the register while still powered off.
>
> If the GPU is powered off, the feature doesn't bring any benefit, so
> don't try to read.
>
> Signed-off-by: Tomeu Vizoso <tomeu.vizoso@collabora.com>
> ---
> drivers/gpu/drm/panfrost/panfrost_gpu.c | 14 ++++++++++++--
> 1 file changed, 12 insertions(+), 2 deletions(-)
Both patches applied.
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel
^ permalink raw reply [flat|nested] 10+ messages in thread