linux-tegra.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v1 0/3] Activate Tegra114 SoC support by Tegra DRM driver
@ 2021-01-12 18:14 Dmitry Osipenko
  2021-01-12 18:14 ` [PATCH v1 1/3] drm/tegra: dc: Enable display controller driver for Tegra114 Dmitry Osipenko
                   ` (2 more replies)
  0 siblings, 3 replies; 7+ messages in thread
From: Dmitry Osipenko @ 2021-01-12 18:14 UTC (permalink / raw)
  To: Thierry Reding, Jonathan Hunter, Mikko Perttunen, Anton Bambura
  Cc: dri-devel, linux-tegra

This series enables Tegra DRM driver for Tegra114 SoC and corrects GR2D
compatible entries, which is a minor correction, but it conflicts with
the Tegra114 enablement if applied separately, so I included it all in
a single small series.

Patches are tested by Anton Bambura on his ASUS TF701T tablet device,
which is powered by Tegra114 SoC. Display panel now works on Tegra114.

Dmitry Osipenko (3):
  drm/tegra: dc: Enable display controller driver for Tegra114
  drm/tegra: gr2d: Correct swapped device-tree compatibles
  drm/tegra: gr2d: Add compatible for Tegra114

 drivers/gpu/drm/tegra/drm.c  | 2 ++
 drivers/gpu/drm/tegra/gr2d.c | 9 +++++++--
 2 files changed, 9 insertions(+), 2 deletions(-)

-- 
2.29.2


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

* [PATCH v1 1/3] drm/tegra: dc: Enable display controller driver for Tegra114
  2021-01-12 18:14 [PATCH v1 0/3] Activate Tegra114 SoC support by Tegra DRM driver Dmitry Osipenko
@ 2021-01-12 18:14 ` Dmitry Osipenko
  2021-01-15 16:18   ` Thierry Reding
  2021-01-12 18:14 ` [PATCH v1 2/3] drm/tegra: gr2d: Correct swapped device-tree compatibles Dmitry Osipenko
  2021-01-12 18:14 ` [PATCH v1 3/3] drm/tegra: gr2d: Add compatible for Tegra114 Dmitry Osipenko
  2 siblings, 1 reply; 7+ messages in thread
From: Dmitry Osipenko @ 2021-01-12 18:14 UTC (permalink / raw)
  To: Thierry Reding, Jonathan Hunter, Mikko Perttunen, Anton Bambura
  Cc: dri-devel, linux-tegra

Display controller driver isn't listed as a DRM sub-device for Tegra114,
thus display driver isn't loaded on Tegra114. Enable display controller
driver for Tegra114 SoC.

Tested-by: Anton Bambura <jenneron@protonmail.com>
Signed-off-by: Dmitry Osipenko <digetx@gmail.com>
---
 drivers/gpu/drm/tegra/drm.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/gpu/drm/tegra/drm.c b/drivers/gpu/drm/tegra/drm.c
index 1472042da2a7..e24e05a47197 100644
--- a/drivers/gpu/drm/tegra/drm.c
+++ b/drivers/gpu/drm/tegra/drm.c
@@ -1315,6 +1315,7 @@ static const struct of_device_id host1x_drm_subdevs[] = {
 	{ .compatible = "nvidia,tegra30-hdmi", },
 	{ .compatible = "nvidia,tegra30-gr2d", },
 	{ .compatible = "nvidia,tegra30-gr3d", },
+	{ .compatible = "nvidia,tegra114-dc", },
 	{ .compatible = "nvidia,tegra114-dsi", },
 	{ .compatible = "nvidia,tegra114-hdmi", },
 	{ .compatible = "nvidia,tegra114-gr3d", },
-- 
2.29.2


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

* [PATCH v1 2/3] drm/tegra: gr2d: Correct swapped device-tree compatibles
  2021-01-12 18:14 [PATCH v1 0/3] Activate Tegra114 SoC support by Tegra DRM driver Dmitry Osipenko
  2021-01-12 18:14 ` [PATCH v1 1/3] drm/tegra: dc: Enable display controller driver for Tegra114 Dmitry Osipenko
@ 2021-01-12 18:14 ` Dmitry Osipenko
  2021-01-15 16:19   ` Thierry Reding
  2021-01-12 18:14 ` [PATCH v1 3/3] drm/tegra: gr2d: Add compatible for Tegra114 Dmitry Osipenko
  2 siblings, 1 reply; 7+ messages in thread
From: Dmitry Osipenko @ 2021-01-12 18:14 UTC (permalink / raw)
  To: Thierry Reding, Jonathan Hunter, Mikko Perttunen, Anton Bambura
  Cc: dri-devel, linux-tegra

The device-tree compatibles are swapped in the code, correct them.

Tested-by: Peter Geis <pgwipeout@gmail.com>
Tested-by: Nicolas Chauvet <kwizart@gmail.com>
Tested-by: Matt Merhar <mattmerhar@protonmail.com>
Signed-off-by: Dmitry Osipenko <digetx@gmail.com>
---
 drivers/gpu/drm/tegra/gr2d.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/gpu/drm/tegra/gr2d.c b/drivers/gpu/drm/tegra/gr2d.c
index 1a0d3ba6e525..f30aa86e4c9f 100644
--- a/drivers/gpu/drm/tegra/gr2d.c
+++ b/drivers/gpu/drm/tegra/gr2d.c
@@ -162,8 +162,8 @@ static const struct gr2d_soc tegra30_gr2d_soc = {
 };
 
 static const struct of_device_id gr2d_match[] = {
-	{ .compatible = "nvidia,tegra30-gr2d", .data = &tegra20_gr2d_soc },
-	{ .compatible = "nvidia,tegra20-gr2d", .data = &tegra30_gr2d_soc },
+	{ .compatible = "nvidia,tegra30-gr2d", .data = &tegra30_gr2d_soc },
+	{ .compatible = "nvidia,tegra20-gr2d", .data = &tegra20_gr2d_soc },
 	{ },
 };
 MODULE_DEVICE_TABLE(of, gr2d_match);
-- 
2.29.2


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

* [PATCH v1 3/3] drm/tegra: gr2d: Add compatible for Tegra114
  2021-01-12 18:14 [PATCH v1 0/3] Activate Tegra114 SoC support by Tegra DRM driver Dmitry Osipenko
  2021-01-12 18:14 ` [PATCH v1 1/3] drm/tegra: dc: Enable display controller driver for Tegra114 Dmitry Osipenko
  2021-01-12 18:14 ` [PATCH v1 2/3] drm/tegra: gr2d: Correct swapped device-tree compatibles Dmitry Osipenko
@ 2021-01-12 18:14 ` Dmitry Osipenko
  2021-01-15 16:19   ` Thierry Reding
  2 siblings, 1 reply; 7+ messages in thread
From: Dmitry Osipenko @ 2021-01-12 18:14 UTC (permalink / raw)
  To: Thierry Reding, Jonathan Hunter, Mikko Perttunen, Anton Bambura
  Cc: dri-devel, linux-tegra

Tegra114 has GR2D hardware block, support it by the 2D driver.

Tested-by: Anton Bambura <jenneron@protonmail.com>
Signed-off-by: Dmitry Osipenko <digetx@gmail.com>
---
 drivers/gpu/drm/tegra/drm.c  | 1 +
 drivers/gpu/drm/tegra/gr2d.c | 5 +++++
 2 files changed, 6 insertions(+)

diff --git a/drivers/gpu/drm/tegra/drm.c b/drivers/gpu/drm/tegra/drm.c
index e24e05a47197..47e7945dbc3b 100644
--- a/drivers/gpu/drm/tegra/drm.c
+++ b/drivers/gpu/drm/tegra/drm.c
@@ -1318,6 +1318,7 @@ static const struct of_device_id host1x_drm_subdevs[] = {
 	{ .compatible = "nvidia,tegra114-dc", },
 	{ .compatible = "nvidia,tegra114-dsi", },
 	{ .compatible = "nvidia,tegra114-hdmi", },
+	{ .compatible = "nvidia,tegra114-gr2d", },
 	{ .compatible = "nvidia,tegra114-gr3d", },
 	{ .compatible = "nvidia,tegra124-dc", },
 	{ .compatible = "nvidia,tegra124-sor", },
diff --git a/drivers/gpu/drm/tegra/gr2d.c b/drivers/gpu/drm/tegra/gr2d.c
index f30aa86e4c9f..adbe2ddcda19 100644
--- a/drivers/gpu/drm/tegra/gr2d.c
+++ b/drivers/gpu/drm/tegra/gr2d.c
@@ -161,7 +161,12 @@ static const struct gr2d_soc tegra30_gr2d_soc = {
 	.version = 0x30,
 };
 
+static const struct gr2d_soc tegra114_gr2d_soc = {
+	.version = 0x35,
+};
+
 static const struct of_device_id gr2d_match[] = {
+	{ .compatible = "nvidia,tegra114-gr2d", .data = &tegra114_gr2d_soc },
 	{ .compatible = "nvidia,tegra30-gr2d", .data = &tegra30_gr2d_soc },
 	{ .compatible = "nvidia,tegra20-gr2d", .data = &tegra20_gr2d_soc },
 	{ },
-- 
2.29.2


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

* Re: [PATCH v1 1/3] drm/tegra: dc: Enable display controller driver for Tegra114
  2021-01-12 18:14 ` [PATCH v1 1/3] drm/tegra: dc: Enable display controller driver for Tegra114 Dmitry Osipenko
@ 2021-01-15 16:18   ` Thierry Reding
  0 siblings, 0 replies; 7+ messages in thread
From: Thierry Reding @ 2021-01-15 16:18 UTC (permalink / raw)
  To: Dmitry Osipenko
  Cc: Jonathan Hunter, Mikko Perttunen, Anton Bambura, dri-devel, linux-tegra

[-- Attachment #1: Type: text/plain, Size: 590 bytes --]

On Tue, Jan 12, 2021 at 09:14:19PM +0300, Dmitry Osipenko wrote:
> Display controller driver isn't listed as a DRM sub-device for Tegra114,
> thus display driver isn't loaded on Tegra114. Enable display controller
> driver for Tegra114 SoC.
> 
> Tested-by: Anton Bambura <jenneron@protonmail.com>
> Signed-off-by: Dmitry Osipenko <digetx@gmail.com>
> ---
>  drivers/gpu/drm/tegra/drm.c | 1 +
>  1 file changed, 1 insertion(+)

Good catch! This used to be covered by an "nvidia,tegra20-dc" fallback
in the DTS, but that was removed at some point.

Applied, thanks.

Thierry

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

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

* Re: [PATCH v1 2/3] drm/tegra: gr2d: Correct swapped device-tree compatibles
  2021-01-12 18:14 ` [PATCH v1 2/3] drm/tegra: gr2d: Correct swapped device-tree compatibles Dmitry Osipenko
@ 2021-01-15 16:19   ` Thierry Reding
  0 siblings, 0 replies; 7+ messages in thread
From: Thierry Reding @ 2021-01-15 16:19 UTC (permalink / raw)
  To: Dmitry Osipenko
  Cc: Jonathan Hunter, Mikko Perttunen, Anton Bambura, dri-devel, linux-tegra

[-- Attachment #1: Type: text/plain, Size: 476 bytes --]

On Tue, Jan 12, 2021 at 09:14:20PM +0300, Dmitry Osipenko wrote:
> The device-tree compatibles are swapped in the code, correct them.
> 
> Tested-by: Peter Geis <pgwipeout@gmail.com>
> Tested-by: Nicolas Chauvet <kwizart@gmail.com>
> Tested-by: Matt Merhar <mattmerhar@protonmail.com>
> Signed-off-by: Dmitry Osipenko <digetx@gmail.com>
> ---
>  drivers/gpu/drm/tegra/gr2d.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)

Applied, thanks.

Thierry

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

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

* Re: [PATCH v1 3/3] drm/tegra: gr2d: Add compatible for Tegra114
  2021-01-12 18:14 ` [PATCH v1 3/3] drm/tegra: gr2d: Add compatible for Tegra114 Dmitry Osipenko
@ 2021-01-15 16:19   ` Thierry Reding
  0 siblings, 0 replies; 7+ messages in thread
From: Thierry Reding @ 2021-01-15 16:19 UTC (permalink / raw)
  To: Dmitry Osipenko
  Cc: Jonathan Hunter, Mikko Perttunen, Anton Bambura, dri-devel, linux-tegra

[-- Attachment #1: Type: text/plain, Size: 400 bytes --]

On Tue, Jan 12, 2021 at 09:14:21PM +0300, Dmitry Osipenko wrote:
> Tegra114 has GR2D hardware block, support it by the 2D driver.
> 
> Tested-by: Anton Bambura <jenneron@protonmail.com>
> Signed-off-by: Dmitry Osipenko <digetx@gmail.com>
> ---
>  drivers/gpu/drm/tegra/drm.c  | 1 +
>  drivers/gpu/drm/tegra/gr2d.c | 5 +++++
>  2 files changed, 6 insertions(+)

Applied, thanks.

Thierry

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

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

end of thread, other threads:[~2021-01-15 16:20 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-01-12 18:14 [PATCH v1 0/3] Activate Tegra114 SoC support by Tegra DRM driver Dmitry Osipenko
2021-01-12 18:14 ` [PATCH v1 1/3] drm/tegra: dc: Enable display controller driver for Tegra114 Dmitry Osipenko
2021-01-15 16:18   ` Thierry Reding
2021-01-12 18:14 ` [PATCH v1 2/3] drm/tegra: gr2d: Correct swapped device-tree compatibles Dmitry Osipenko
2021-01-15 16:19   ` Thierry Reding
2021-01-12 18:14 ` [PATCH v1 3/3] drm/tegra: gr2d: Add compatible for Tegra114 Dmitry Osipenko
2021-01-15 16:19   ` Thierry Reding

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).