All of lore.kernel.org
 help / color / mirror / Atom feed
* wandboard-rt & kernel-module-imx-gpu-viv error
@ 2016-01-12  6:47 Julio Cruz Barroso
  2016-01-12 11:12 ` Otavio Salvador
  0 siblings, 1 reply; 9+ messages in thread
From: Julio Cruz Barroso @ 2016-01-12  6:47 UTC (permalink / raw)
  To: meta-freescale; +Cc: dominic.sacre

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

Hi,

I'm trying to build a core-image-minimal for "wandboard-rt", but an error show-up compiling the module "kernel-module-imx-gpu-viv". 

I found two ways to solve this issue:

1. Apply a similar patch proposed by Dominic some months ago ([meta-freescale] [meta-fsl-arm-extra][PATCH] linux-wandboard-rt: Add initial recipe), but this time, for the external module
2. Disable the kernel module and use the built-in. For this, it suggest to use the option defined by Otavio 5 month ago (patch-v2-0-5-dynamically-choose-between-built-in-or-external-vivante-gpu-kernel-driver#post8). MACHINE_USES_VIVANTE_KERNEL_DRIVER_MODULE = "0" in the local.conf file.

Currently, both sources (module and built-in) have difference and I'm not sure if the applied patch will be enough. Dominic, do you have any comments?

Thanks for any suggestion,

Julio

[-- Attachment #2: 0001-fix-build-in-kernel-module.patch --]
[-- Type: application/octet-stream, Size: 2132 bytes --]

From e2a50627a1fc33ebda63c4a510ce5d9e2abb9df4 Mon Sep 17 00:00:00 2001
From: Julio Cruz <jcsistemas2001@gmail.com>
Date: Tue, 12 Jan 2016 14:26:17 +0800
Subject: [PATCH] fix build in kernel module

---
 .../hal/os/linux/kernel/gc_hal_kernel_os.c               | 16 +++++++---------
 1 file changed, 7 insertions(+), 9 deletions(-)

diff --git a/kernel-module-imx-gpu-viv-src/hal/os/linux/kernel/gc_hal_kernel_os.c b/kernel-module-imx-gpu-viv-src/hal/os/linux/kernel/gc_hal_kernel_os.c
index 49c9745..af3300d 100644
--- a/kernel-module-imx-gpu-viv-src/hal/os/linux/kernel/gc_hal_kernel_os.c
+++ b/kernel-module-imx-gpu-viv-src/hal/os/linux/kernel/gc_hal_kernel_os.c
@@ -7362,7 +7362,7 @@ gckOS_WaitSignal(
 
     might_sleep();
 
-    spin_lock_irq(&signal->obj.wait.lock);
+    raw_spin_lock_irq(&signal->obj.wait.lock);
 
     if (signal->obj.done)
     {
@@ -7384,9 +7384,8 @@ gckOS_WaitSignal(
             ? MAX_SCHEDULE_TIMEOUT
             : Wait * HZ / 1000;
 
-        DECLARE_WAITQUEUE(wait, current);
-        wait.flags |= WQ_FLAG_EXCLUSIVE;
-        __add_wait_queue_tail(&signal->obj.wait, &wait);
+	DEFINE_SWAITER(wait);
+	swait_prepare_locked(&signal->obj.wait, &wait);
 
         while (gcvTRUE)
         {
@@ -7398,9 +7397,9 @@ gckOS_WaitSignal(
             }
 
             __set_current_state(TASK_INTERRUPTIBLE);
-            spin_unlock_irq(&signal->obj.wait.lock);
+            raw_spin_unlock_irq(&signal->obj.wait.lock);
             timeout = schedule_timeout(timeout);
-            spin_lock_irq(&signal->obj.wait.lock);
+            raw_spin_lock_irq(&signal->obj.wait.lock);
 
             if (signal->obj.done)
             {
@@ -7421,10 +7420,10 @@ gckOS_WaitSignal(
             }
         }
 
-        __remove_wait_queue(&signal->obj.wait, &wait);
+        swait_finish_locked(&signal->obj.wait, &wait);
     }
 
-    spin_unlock_irq(&signal->obj.wait.lock);
+    raw_spin_unlock_irq(&signal->obj.wait.lock);
 
 OnError:
     /* Return status. */
@@ -8954,4 +8953,3 @@ OnError:
     gcmkFOOTER();
     return status;
 }
-
-- 
2.1.0

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

* Re: wandboard-rt & kernel-module-imx-gpu-viv error
  2016-01-12  6:47 wandboard-rt & kernel-module-imx-gpu-viv error Julio Cruz Barroso
@ 2016-01-12 11:12 ` Otavio Salvador
  2016-01-20 11:58   ` Julio Cruz Barroso
  0 siblings, 1 reply; 9+ messages in thread
From: Otavio Salvador @ 2016-01-12 11:12 UTC (permalink / raw)
  To: Julio Cruz Barroso, Prabhu Sundararaj; +Cc: meta-freescale, dominic.sacre

Hello Julio,

On Tue, Jan 12, 2016 at 4:47 AM, Julio Cruz Barroso
<julio.cruz@smartmatic.com> wrote:
> I'm trying to build a core-image-minimal for "wandboard-rt", but an error show-up compiling the module "kernel-module-imx-gpu-viv".
>
> I found two ways to solve this issue:
>
> 1. Apply a similar patch proposed by Dominic some months ago ([meta-freescale] [meta-fsl-arm-extra][PATCH] linux-wandboard-rt: Add initial recipe), but this time, for the external module
> 2. Disable the kernel module and use the built-in. For this, it suggest to use the option defined by Otavio 5 month ago (patch-v2-0-5-dynamically-choose-between-built-in-or-external-vivante-gpu-kernel-driver#post8). MACHINE_USES_VIVANTE_KERNEL_DRIVER_MODULE = "0" in the local.conf file.
>
> Currently, both sources (module and built-in) have difference and I'm not sure if the applied patch will be enough. Dominic, do you have any comments?

Ideally we ought to fix the kernel module source. Prabhu, is it
possible for you to review the patch proposed by Julio? It seems good
from my point of view and harmless for normal kernel as well.

-- 
Otavio Salvador                             O.S. Systems
http://www.ossystems.com.br        http://code.ossystems.com.br
Mobile: +55 (53) 9981-7854            Mobile: +1 (347) 903-9750


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

* Re: wandboard-rt & kernel-module-imx-gpu-viv error
  2016-01-12 11:12 ` Otavio Salvador
@ 2016-01-20 11:58   ` Julio Cruz Barroso
  2016-01-20 14:17     ` Otavio Salvador
  2016-01-20 15:15     ` Prabhu Sundararaj
  0 siblings, 2 replies; 9+ messages in thread
From: Julio Cruz Barroso @ 2016-01-20 11:58 UTC (permalink / raw)
  To: Otavio Salvador, Prabhu Sundararaj; +Cc: meta-freescale, dominic.sacre

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

Hi Otavio, Prabhu,

The previous patch help to build the imx-gpu-viv module for the Linux-wandboard-rt. After testing, there is the following issue:

 [    3.692132] galcore: Unknown symbol swait_prepare_locked (err -22)
 [    3.701981] galcore: Unknown symbol swait_finish_locked (err -22)

These symbols are part of the linux-rt patch. To solve it, the EXPORT_SYMBOL directive was used at /kernel/sched/wait-simple.c. The board is able to show QT application using eglfs (no xorg). Attached the additional patch.

Julio

-----Original Message-----
From: Otavio Salvador [mailto:otavio.salvador@ossystems.com.br] 
Sent: Tuesday, January 12, 2016 7:13 PM
To: Julio Cruz Barroso <julio.cruz@smartmatic.com>; Prabhu Sundararaj <prabhu.sundararaj@nxp.com>
Cc: meta-freescale@yoctoproject.org; dominic.sacre@gmx.de
Subject: Re: [meta-freescale] wandboard-rt & kernel-module-imx-gpu-viv error

Hello Julio,

On Tue, Jan 12, 2016 at 4:47 AM, Julio Cruz Barroso <julio.cruz@smartmatic.com> wrote:
> I'm trying to build a core-image-minimal for "wandboard-rt", but an error show-up compiling the module "kernel-module-imx-gpu-viv".
>
> I found two ways to solve this issue:
>
> 1. Apply a similar patch proposed by Dominic some months ago 
> ([meta-freescale] [meta-fsl-arm-extra][PATCH] linux-wandboard-rt: Add initial recipe), but this time, for the external module 2. Disable the kernel module and use the built-in. For this, it suggest to use the option defined by Otavio 5 month ago (patch-v2-0-5-dynamically-choose-between-built-in-or-external-vivante-gpu-kernel-driver#post8). MACHINE_USES_VIVANTE_KERNEL_DRIVER_MODULE = "0" in the local.conf file.
>
> Currently, both sources (module and built-in) have difference and I'm not sure if the applied patch will be enough. Dominic, do you have any comments?

Ideally we ought to fix the kernel module source. Prabhu, is it possible for you to review the patch proposed by Julio? It seems good from my point of view and harmless for normal kernel as well.

-- 
Otavio Salvador                             O.S. Systems
http://www.ossystems.com.br        http://code.ossystems.com.br
Mobile: +55 (53) 9981-7854            Mobile: +1 (347) 903-9750

[-- Attachment #2: 0001-Export-symbols-for-iMX-GPU-VIV-module.patch --]
[-- Type: application/octet-stream, Size: 987 bytes --]

From 2460dd985b0cf477f74396de92d1bc5df496abdc Mon Sep 17 00:00:00 2001
From: Julio Cruz <jcsistemas2001@gmail.com>
Date: Wed, 20 Jan 2016 19:26:44 +0800
Subject: [PATCH] Export symbols for iMX-GPU-VIV module

---
 kernel/sched/wait-simple.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/kernel/sched/wait-simple.c b/kernel/sched/wait-simple.c
index 7dfa86d..a3776ee 100644
--- a/kernel/sched/wait-simple.c
+++ b/kernel/sched/wait-simple.c
@@ -40,6 +40,7 @@ void swait_prepare_locked(struct swait_head *head, struct swaiter *w)
 	if (list_empty(&w->node))
 		__swait_enqueue(head, w);
 }
+EXPORT_SYMBOL(swait_prepare_locked);
 
 void swait_prepare(struct swait_head *head, struct swaiter *w, int state)
 {
@@ -58,6 +59,7 @@ void swait_finish_locked(struct swait_head *head, struct swaiter *w)
 	if (w->task)
 		__swait_dequeue(w);
 }
+EXPORT_SYMBOL(swait_finish_locked);
 
 void swait_finish(struct swait_head *head, struct swaiter *w)
 {
-- 
2.1.0

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

* Re: wandboard-rt & kernel-module-imx-gpu-viv error
  2016-01-20 11:58   ` Julio Cruz Barroso
@ 2016-01-20 14:17     ` Otavio Salvador
  2016-01-20 15:15     ` Prabhu Sundararaj
  1 sibling, 0 replies; 9+ messages in thread
From: Otavio Salvador @ 2016-01-20 14:17 UTC (permalink / raw)
  To: Julio Cruz Barroso; +Cc: meta-freescale, Prabhu Sundararaj, dominic.sacre

On Wed, Jan 20, 2016 at 9:58 AM, Julio Cruz Barroso
<julio.cruz@smartmatic.com> wrote:
> The previous patch help to build the imx-gpu-viv module for the Linux-wandboard-rt. After testing, there is the following issue:
>
>  [    3.692132] galcore: Unknown symbol swait_prepare_locked (err -22)
>  [    3.701981] galcore: Unknown symbol swait_finish_locked (err -22)
>
> These symbols are part of the linux-rt patch. To solve it, the EXPORT_SYMBOL directive was used at /kernel/sched/wait-simple.c. The board is able to show QT application using eglfs (no xorg). Attached the additional patch.

It would be great if we could rework the module to make it compatible
with both and avoid this patch. What is Linux-RT recommendation for
this lock cases?

-- 
Otavio Salvador                             O.S. Systems
http://www.ossystems.com.br        http://code.ossystems.com.br
Mobile: +55 (53) 9981-7854            Mobile: +1 (347) 903-9750


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

* Re: wandboard-rt & kernel-module-imx-gpu-viv error
  2016-01-20 11:58   ` Julio Cruz Barroso
  2016-01-20 14:17     ` Otavio Salvador
@ 2016-01-20 15:15     ` Prabhu Sundararaj
  2016-01-21  2:43       ` Julio Cruz Barroso
  1 sibling, 1 reply; 9+ messages in thread
From: Prabhu Sundararaj @ 2016-01-20 15:15 UTC (permalink / raw)
  To: Julio Cruz Barroso, Otavio Salvador; +Cc: meta-freescale, dominic.sacre

Wondering what is the kernel version you are using? The problem does not seem to occur in linux-imx with 3.14 kernel.

Best Regards,
Prabhu

-----Original Message-----
From: Julio Cruz Barroso [mailto:julio.cruz@smartmatic.com] 
Sent: Wednesday, January 20, 2016 5:59 AM
To: Otavio Salvador <otavio.salvador@ossystems.com.br>; Prabhu Sundararaj <prabhu.sundararaj@nxp.com>
Cc: meta-freescale@yoctoproject.org; dominic.sacre@gmx.de
Subject: RE: [meta-freescale] wandboard-rt & kernel-module-imx-gpu-viv error

Hi Otavio, Prabhu,

The previous patch help to build the imx-gpu-viv module for the Linux-wandboard-rt. After testing, there is the following issue:

 [    3.692132] galcore: Unknown symbol swait_prepare_locked (err -22)
 [    3.701981] galcore: Unknown symbol swait_finish_locked (err -22)

These symbols are part of the linux-rt patch. To solve it, the EXPORT_SYMBOL directive was used at /kernel/sched/wait-simple.c. The board is able to show QT application using eglfs (no xorg). Attached the additional patch.

Julio

-----Original Message-----
From: Otavio Salvador [mailto:otavio.salvador@ossystems.com.br]
Sent: Tuesday, January 12, 2016 7:13 PM
To: Julio Cruz Barroso <julio.cruz@smartmatic.com>; Prabhu Sundararaj <prabhu.sundararaj@nxp.com>
Cc: meta-freescale@yoctoproject.org; dominic.sacre@gmx.de
Subject: Re: [meta-freescale] wandboard-rt & kernel-module-imx-gpu-viv error

Hello Julio,

On Tue, Jan 12, 2016 at 4:47 AM, Julio Cruz Barroso <julio.cruz@smartmatic.com> wrote:
> I'm trying to build a core-image-minimal for "wandboard-rt", but an error show-up compiling the module "kernel-module-imx-gpu-viv".
>
> I found two ways to solve this issue:
>
> 1. Apply a similar patch proposed by Dominic some months ago 
> ([meta-freescale] [meta-fsl-arm-extra][PATCH] linux-wandboard-rt: Add initial recipe), but this time, for the external module 2. Disable the kernel module and use the built-in. For this, it suggest to use the option defined by Otavio 5 month ago (patch-v2-0-5-dynamically-choose-between-built-in-or-external-vivante-gpu-kernel-driver#post8). MACHINE_USES_VIVANTE_KERNEL_DRIVER_MODULE = "0" in the local.conf file.
>
> Currently, both sources (module and built-in) have difference and I'm not sure if the applied patch will be enough. Dominic, do you have any comments?

Ideally we ought to fix the kernel module source. Prabhu, is it possible for you to review the patch proposed by Julio? It seems good from my point of view and harmless for normal kernel as well.

-- 
Otavio Salvador                             O.S. Systems
http://www.ossystems.com.br        http://code.ossystems.com.br
Mobile: +55 (53) 9981-7854            Mobile: +1 (347) 903-9750

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

* Re: wandboard-rt & kernel-module-imx-gpu-viv error
  2016-01-20 15:15     ` Prabhu Sundararaj
@ 2016-01-21  2:43       ` Julio Cruz Barroso
  2016-01-21  2:53         ` Prabhu Sundararaj
  0 siblings, 1 reply; 9+ messages in thread
From: Julio Cruz Barroso @ 2016-01-21  2:43 UTC (permalink / raw)
  To: Prabhu Sundararaj; +Cc: meta-freescale, dominic.sacre, Otavio Salvador

Hi Prabhu,

I'm using the kernel version 3.14.28.

Regards

Julio

On Jan 20, 2016, at 11:16 PM, Prabhu Sundararaj <prabhu.sundararaj@nxp.com> wrote:

Wondering what is the kernel version you are using? The problem does not seem to occur in linux-imx with 3.14 kernel.

Best Regards,
Prabhu

-----Original Message-----
From: Julio Cruz Barroso [mailto:julio.cruz@smartmatic.com] 
Sent: Wednesday, January 20, 2016 5:59 AM
To: Otavio Salvador <otavio.salvador@ossystems.com.br>; Prabhu Sundararaj <prabhu.sundararaj@nxp.com>
Cc: meta-freescale@yoctoproject.org; dominic.sacre@gmx.de
Subject: RE: [meta-freescale] wandboard-rt & kernel-module-imx-gpu-viv error

Hi Otavio, Prabhu,

The previous patch help to build the imx-gpu-viv module for the Linux-wandboard-rt. After testing, there is the following issue:

[    3.692132] galcore: Unknown symbol swait_prepare_locked (err -22)
[    3.701981] galcore: Unknown symbol swait_finish_locked (err -22)

These symbols are part of the linux-rt patch. To solve it, the EXPORT_SYMBOL directive was used at /kernel/sched/wait-simple.c. The board is able to show QT application using eglfs (no xorg). Attached the additional patch.

Julio

-----Original Message-----
From: Otavio Salvador [mailto:otavio.salvador@ossystems.com.br]
Sent: Tuesday, January 12, 2016 7:13 PM
To: Julio Cruz Barroso <julio.cruz@smartmatic.com>; Prabhu Sundararaj <prabhu.sundararaj@nxp.com>
Cc: meta-freescale@yoctoproject.org; dominic.sacre@gmx.de
Subject: Re: [meta-freescale] wandboard-rt & kernel-module-imx-gpu-viv error

Hello Julio,

> On Tue, Jan 12, 2016 at 4:47 AM, Julio Cruz Barroso <julio.cruz@smartmatic.com> wrote:
> I'm trying to build a core-image-minimal for "wandboard-rt", but an error show-up compiling the module "kernel-module-imx-gpu-viv".
> 
> I found two ways to solve this issue:
> 
> 1. Apply a similar patch proposed by Dominic some months ago 
> ([meta-freescale] [meta-fsl-arm-extra][PATCH] linux-wandboard-rt: Add initial recipe), but this time, for the external module 2. Disable the kernel module and use the built-in. For this, it suggest to use the option defined by Otavio 5 month ago (patch-v2-0-5-dynamically-choose-between-built-in-or-external-vivante-gpu-kernel-driver#post8). MACHINE_USES_VIVANTE_KERNEL_DRIVER_MODULE = "0" in the local.conf file.
> 
> Currently, both sources (module and built-in) have difference and I'm not sure if the applied patch will be enough. Dominic, do you have any comments?

Ideally we ought to fix the kernel module source. Prabhu, is it possible for you to review the patch proposed by Julio? It seems good from my point of view and harmless for normal kernel as well.

-- 
Otavio Salvador                             O.S. Systems
http://www.ossystems.com.br        http://code.ossystems.com.br
Mobile: +55 (53) 9981-7854            Mobile: +1 (347) 903-9750


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

* Re: wandboard-rt & kernel-module-imx-gpu-viv error
  2016-01-21  2:43       ` Julio Cruz Barroso
@ 2016-01-21  2:53         ` Prabhu Sundararaj
  2016-01-21  3:04           ` Julio Cruz Barroso
  0 siblings, 1 reply; 9+ messages in thread
From: Prabhu Sundararaj @ 2016-01-21  2:53 UTC (permalink / raw)
  To: Julio Cruz Barroso
  Cc: meta-freescale, Xiong Xiao, dominic.sacre, Otavio Salvador

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

checked 4.6.9.p13, 5.0.11.p4/p7, and there is no place to use swait_prepare_locked or swait_finish_locked symbol.
Which gpu driver version did you use?

Best Regards,
Prabhu




On Wed, Jan 20, 2016 at 6:49 PM -0800, "Julio Cruz Barroso" <julio.cruz@smartmatic.com<mailto:julio.cruz@smartmatic.com>> wrote:

Hi Prabhu,

I'm using the kernel version 3.14.28.

Regards

Julio

On Jan 20, 2016, at 11:16 PM, Prabhu Sundararaj <prabhu.sundararaj@nxp.com> wrote:

Wondering what is the kernel version you are using? The problem does not seem to occur in linux-imx with 3.14 kernel.

Best Regards,
Prabhu

-----Original Message-----
From: Julio Cruz Barroso [mailto:julio.cruz@smartmatic.com]
Sent: Wednesday, January 20, 2016 5:59 AM
To: Otavio Salvador <otavio.salvador@ossystems.com.br>; Prabhu Sundararaj <prabhu.sundararaj@nxp.com>
Cc: meta-freescale@yoctoproject.org; dominic.sacre@gmx.de
Subject: RE: [meta-freescale] wandboard-rt & kernel-module-imx-gpu-viv error

Hi Otavio, Prabhu,

The previous patch help to build the imx-gpu-viv module for the Linux-wandboard-rt. After testing, there is the following issue:

[    3.692132] galcore: Unknown symbol swait_prepare_locked (err -22)
[    3.701981] galcore: Unknown symbol swait_finish_locked (err -22)

These symbols are part of the linux-rt patch. To solve it, the EXPORT_SYMBOL directive was used at /kernel/sched/wait-simple.c. The board is able to show QT application using eglfs (no xorg). Attached the additional patch.

Julio

-----Original Message-----
From: Otavio Salvador [mailto:otavio.salvador@ossystems.com.br]
Sent: Tuesday, January 12, 2016 7:13 PM
To: Julio Cruz Barroso <julio.cruz@smartmatic.com>; Prabhu Sundararaj <prabhu.sundararaj@nxp.com>
Cc: meta-freescale@yoctoproject.org; dominic.sacre@gmx.de
Subject: Re: [meta-freescale] wandboard-rt & kernel-module-imx-gpu-viv error

Hello Julio,

> On Tue, Jan 12, 2016 at 4:47 AM, Julio Cruz Barroso <julio.cruz@smartmatic.com> wrote:
> I'm trying to build a core-image-minimal for "wandboard-rt", but an error show-up compiling the module "kernel-module-imx-gpu-viv".
>
> I found two ways to solve this issue:
>
> 1. Apply a similar patch proposed by Dominic some months ago
> ([meta-freescale] [meta-fsl-arm-extra][PATCH] linux-wandboard-rt: Add initial recipe), but this time, for the external module 2. Disable the kernel module and use the built-in. For this, it suggest to use the option defined by Otavio 5 month ago (patch-v2-0-5-dynamically-choose-between-built-in-or-external-vivante-gpu-kernel-driver#post8). MACHINE_USES_VIVANTE_KERNEL_DRIVER_MODULE = "0" in the local.conf file.
>
> Currently, both sources (module and built-in) have difference and I'm not sure if the applied patch will be enough. Dominic, do you have any comments?

Ideally we ought to fix the kernel module source. Prabhu, is it possible for you to review the patch proposed by Julio? It seems good from my point of view and harmless for normal kernel as well.

--
Otavio Salvador                             O.S. Systems
http://www.ossystems.com.br        http://code.ossystems.com.br
Mobile: +55 (53) 9981-7854            Mobile: +1 (347) 903-9750

[-- Attachment #2: Type: text/html, Size: 4655 bytes --]

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

* Re: wandboard-rt & kernel-module-imx-gpu-viv error
  2016-01-21  2:53         ` Prabhu Sundararaj
@ 2016-01-21  3:04           ` Julio Cruz Barroso
  2016-01-21  6:11             ` Julio Cruz Barroso
  0 siblings, 1 reply; 9+ messages in thread
From: Julio Cruz Barroso @ 2016-01-21  3:04 UTC (permalink / raw)
  To: Prabhu Sundararaj
  Cc: meta-freescale, Xiong Xiao, dominic.sacre, Otavio Salvador

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

Prabhu,

I use the 5.0.11.p7.
According with log: 5.0.11.33433.

Regards
Julio

On Jan 21, 2016, at 10:54 AM, Prabhu Sundararaj <prabhu.sundararaj@nxp.com<mailto:prabhu.sundararaj@nxp.com>> wrote:

checked 4.6.9.p13, 5.0.11.p4/p7, and there is no place to use swait_prepare_locked or swait_finish_locked symbol.
Which gpu driver version did you use?

Best Regards,
Prabhu




On Wed, Jan 20, 2016 at 6:49 PM -0800, "Julio Cruz Barroso" <julio.cruz@smartmatic.com<mailto:julio.cruz@smartmatic.com>> wrote:

Hi Prabhu,

I'm using the kernel version 3.14.28.

Regards

Julio

On Jan 20, 2016, at 11:16 PM, Prabhu Sundararaj <prabhu.sundararaj@nxp.com<mailto:prabhu.sundararaj@nxp.com>> wrote:

Wondering what is the kernel version you are using? The problem does not seem to occur in linux-imx with 3.14 kernel.

Best Regards,
Prabhu

-----Original Message-----
From: Julio Cruz Barroso [mailto:julio.cruz@smartmatic.com]
Sent: Wednesday, January 20, 2016 5:59 AM
To: Otavio Salvador <otavio.salvador@ossystems.com.br<mailto:otavio.salvador@ossystems.com.br>>; Prabhu Sundararaj <prabhu.sundararaj@nxp.com<mailto:prabhu.sundararaj@nxp.com>>
Cc: meta-freescale@yoctoproject.org<mailto:meta-freescale@yoctoproject.org>; dominic.sacre@gmx.de<mailto:dominic.sacre@gmx.de>
Subject: RE: [meta-freescale] wandboard-rt & kernel-module-imx-gpu-viv error

Hi Otavio, Prabhu,

The previous patch help to build the imx-gpu-viv module for the Linux-wandboard-rt. After testing, there is the following issue:

[    3.692132] galcore: Unknown symbol swait_prepare_locked (err -22)
[    3.701981] galcore: Unknown symbol swait_finish_locked (err -22)

These symbols are part of the linux-rt patch. To solve it, the EXPORT_SYMBOL directive was used at /kernel/sched/wait-simple.c. The board is able to show QT application using eglfs (no xorg). Attached the additional patch.

Julio

-----Original Message-----
From: Otavio Salvador [mailto:otavio.salvador@ossystems.com.br]
Sent: Tuesday, January 12, 2016 7:13 PM
To: Julio Cruz Barroso <julio.cruz@smartmatic.com<mailto:julio.cruz@smartmatic.com>>; Prabhu Sundararaj <prabhu.sundararaj@nxp.com<mailto:prabhu.sundararaj@nxp.com>>
Cc: meta-freescale@yoctoproject.org<mailto:meta-freescale@yoctoproject.org>; dominic.sacre@gmx.de<mailto:dominic.sacre@gmx.de>
Subject: Re: [meta-freescale] wandboard-rt & kernel-module-imx-gpu-viv error

Hello Julio,

> On Tue, Jan 12, 2016 at 4:47 AM, Julio Cruz Barroso <julio.cruz@smartmatic.com<mailto:julio.cruz@smartmatic.com>> wrote:
> I'm trying to build a core-image-minimal for "wandboard-rt", but an error show-up compiling the module "kernel-module-imx-gpu-viv".
>
> I found two ways to solve this issue:
>
> 1. Apply a similar patch proposed by Dominic some months ago
> ([meta-freescale] [meta-fsl-arm-extra][PATCH] linux-wandboard-rt: Add initial recipe), but this time, for the external module 2. Disable the kernel module and use the built-in. For this, it suggest to use the option defined by Otavio 5 month ago (patch-v2-0-5-dynamically-choose-between-built-in-or-external-vivante-gpu-kernel-driver#post8). MACHINE_USES_VIVANTE_KERNEL_DRIVER_MODULE = "0" in the local.conf file.
>
> Currently, both sources (module and built-in) have difference and I'm not sure if the applied patch will be enough. Dominic, do you have any comments?

Ideally we ought to fix the kernel module source. Prabhu, is it possible for you to review the patch proposed by Julio? It seems good from my point of view and harmless for normal kernel as well.

--
Otavio Salvador                             O.S. Systems
http://www.ossystems.com.br        http://code.ossystems.com.br
Mobile: +55 (53) 9981-7854            Mobile: +1 (347) 903-9750

[-- Attachment #2: Type: text/html, Size: 5514 bytes --]

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

* Re: wandboard-rt & kernel-module-imx-gpu-viv error
  2016-01-21  3:04           ` Julio Cruz Barroso
@ 2016-01-21  6:11             ` Julio Cruz Barroso
  0 siblings, 0 replies; 9+ messages in thread
From: Julio Cruz Barroso @ 2016-01-21  6:11 UTC (permalink / raw)
  To: Prabhu Sundararaj
  Cc: meta-freescale, Xiong Xiao, dominic.sacre, Otavio Salvador

Hi Prabhu,

In the imx-gpu-viv there are various places with the following functions:

- spin_lock_irq(&signal->obj.wait.lock);
- spin_unlock_irq(&signal->obj.wait.lock);
- __add_wait_queue_tail(&signal->obj.wait, &wait);
-  __remove_wait_queue(&signal->obj.wait, &wait);

Those function will show error during building linux-rt. To solve the issue, the original patch change those as below (at the same order):

- raw_spin_lock_irq(&signal->obj.wait.lock);
- raw_spin_unlock_irq(&signal->obj.wait.lock);
- swait_prepare_locked(&signal->obj.wait, &wait);
- swait_finish_locked(&signal->obj.wait, &wait);

This change apply to the built-in driver. A similar patch was proposed for the external driver (basically the same). However, this still will fail at runtime (not find symbol). To solve this last issue, the latest patch was proposed (modify the kernel to export the symbols)

I could be wrong, let me know your feedback.

Regards,

Julio

From: meta-freescale-bounces@yoctoproject.org [mailto:meta-freescale-bounces@yoctoproject.org] On Behalf Of Julio Cruz Barroso
Sent: Thursday, January 21, 2016 11:05 AM
To: Prabhu Sundararaj <prabhu.sundararaj@nxp.com>
Cc: meta-freescale@yoctoproject.org; Xiong Xiao <xiong.xiao@nxp.com>; dominic.sacre@gmx.de; Otavio Salvador <otavio.salvador@ossystems.com.br>
Subject: Re: [meta-freescale] wandboard-rt & kernel-module-imx-gpu-viv error

Prabhu,

I use the 5.0.11.p7.
According with log: 5.0.11.33433.

Regards
Julio

On Jan 21, 2016, at 10:54 AM, Prabhu Sundararaj <prabhu.sundararaj@nxp.com> wrote:
checked 4.6.9.p13, 5.0.11.p4/p7, and there is no place to use swait_prepare_locked or swait_finish_locked symbol.
Which gpu driver version did you use?
Best Regards,
Prabhu



On Wed, Jan 20, 2016 at 6:49 PM -0800, "Julio Cruz Barroso" <julio.cruz@smartmatic.com> wrote:
Hi Prabhu,

I'm using the kernel version 3.14.28.

Regards

Julio

On Jan 20, 2016, at 11:16 PM, Prabhu Sundararaj <prabhu.sundararaj@nxp.com> wrote:

Wondering what is the kernel version you are using? The problem does not seem to occur in linux-imx with 3.14 kernel.

Best Regards,
Prabhu

-----Original Message-----
From: Julio Cruz Barroso [mailto:julio.cruz@smartmatic.com] 
Sent: Wednesday, January 20, 2016 5:59 AM
To: Otavio Salvador <otavio.salvador@ossystems.com.br>; Prabhu Sundararaj <prabhu.sundararaj@nxp.com>
Cc: meta-freescale@yoctoproject.org; dominic.sacre@gmx.de
Subject: RE: [meta-freescale] wandboard-rt & kernel-module-imx-gpu-viv error

Hi Otavio, Prabhu,

The previous patch help to build the imx-gpu-viv module for the Linux-wandboard-rt. After testing, there is the following issue:

[    3.692132] galcore: Unknown symbol swait_prepare_locked (err -22)
[    3.701981] galcore: Unknown symbol swait_finish_locked (err -22)

These symbols are part of the linux-rt patch. To solve it, the EXPORT_SYMBOL directive was used at /kernel/sched/wait-simple.c. The board is able to show QT application using eglfs (no xorg). Attached the additional patch.

Julio

-----Original Message-----
From: Otavio Salvador [mailto:otavio.salvador@ossystems.com.br]
Sent: Tuesday, January 12, 2016 7:13 PM
To: Julio Cruz Barroso <julio.cruz@smartmatic.com>; Prabhu Sundararaj <prabhu.sundararaj@nxp.com>
Cc: meta-freescale@yoctoproject.org; dominic.sacre@gmx.de
Subject: Re: [meta-freescale] wandboard-rt & kernel-module-imx-gpu-viv error

Hello Julio,

> On Tue, Jan 12, 2016 at 4:47 AM, Julio Cruz Barroso <julio.cruz@smartmatic.com> wrote:
> I'm trying to build a core-image-minimal for "wandboard-rt", but an error show-up compiling the module "kernel-module-imx-gpu-viv".
> 
> I found two ways to solve this issue:
> 
> 1. Apply a similar patch proposed by Dominic some months ago 
> ([meta-freescale] [meta-fsl-arm-extra][PATCH] linux-wandboard-rt: Add initial recipe), but this time, for the external module 2. Disable the kernel module and use the built-in. For this, it suggest to use the option defined by Otavio 5 month ago (patch-v2-0-5-dynamically-choose-between-built-in-or-external-vivante-gpu-kernel-driver#post8). MACHINE_USES_VIVANTE_KERNEL_DRIVER_MODULE = "0" in the local.conf file.
> 
> Currently, both sources (module and built-in) have difference and I'm not sure if the applied patch will be enough. Dominic, do you have any comments?

Ideally we ought to fix the kernel module source. Prabhu, is it possible for you to review the patch proposed by Julio? It seems good from my point of view and harmless for normal kernel as well.

-- 
Otavio Salvador                             O.S. Systems
http://www.ossystems.com.br        http://code.ossystems.com.br
Mobile: +55 (53) 9981-7854            Mobile: +1 (347) 903-9750


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

end of thread, other threads:[~2016-01-21  6:18 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-01-12  6:47 wandboard-rt & kernel-module-imx-gpu-viv error Julio Cruz Barroso
2016-01-12 11:12 ` Otavio Salvador
2016-01-20 11:58   ` Julio Cruz Barroso
2016-01-20 14:17     ` Otavio Salvador
2016-01-20 15:15     ` Prabhu Sundararaj
2016-01-21  2:43       ` Julio Cruz Barroso
2016-01-21  2:53         ` Prabhu Sundararaj
2016-01-21  3:04           ` Julio Cruz Barroso
2016-01-21  6:11             ` Julio Cruz Barroso

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.