From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by yocto-www.yoctoproject.org (Postfix, from userid 118) id 4F6B5E008D7; Thu, 13 Nov 2014 00:22:27 -0800 (PST) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on yocto-www.yoctoproject.org X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_NONE, SPF_HELO_PASS autolearn=ham version=3.3.1 X-Spam-HAM-Report: * -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at http://www.dnswl.org/, no * trust * [157.55.234.56 listed in list.dnswl.org] * -0.0 SPF_HELO_PASS SPF: HELO matches SPF record * -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% * [score: 0.0000] Received: from emea01-db3-obe.outbound.protection.outlook.com (mail-db3on0056.outbound.protection.outlook.com [157.55.234.56]) by yocto-www.yoctoproject.org (Postfix) with ESMTP id DC339E008C3 for ; Thu, 13 Nov 2014 00:22:19 -0800 (PST) Received: from [192.168.1.118] (93.64.190.105) by DBXPR04MB399.eurprd04.prod.outlook.com (10.141.15.149) with Microsoft SMTP Server (TLS) id 15.1.16.15; Thu, 13 Nov 2014 08:22:16 +0000 Message-ID: <54646A34.6080201@giuneco.it> Date: Thu, 13 Nov 2014 09:22:12 +0100 From: Gianluca Cinci User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.2.0 MIME-Version: 1.0 To: Daiane Angolini References: <5462A702.3040909@giuneco.it> In-Reply-To: X-Originating-IP: [93.64.190.105] X-ClientProxiedBy: DB3PR03CA0017.eurprd03.prod.outlook.com (10.255.183.17) To DBXPR04MB399.eurprd04.prod.outlook.com (10.141.15.149) X-Microsoft-Antispam: UriScan:; X-Microsoft-Antispam: BCL:0;PCL:0;RULEID:;SRVR:DBXPR04MB399; X-Exchange-Antispam-Report-Test: UriScan:; X-Exchange-Antispam-Report-CFA-Test: BCL:0;PCL:0;RULEID:;SRVR:DBXPR04MB399; X-Forefront-PRVS: 0394259C80 X-Forefront-Antispam-Report: SFV:NSPM; SFS:(10009020)(6009001)(6049001)(377454003)(479174003)(24454002)(53754006)(5423002)(51704005)(189002)(199003)(99136001)(21056001)(80316001)(19580405001)(76176999)(50986999)(106356001)(65816999)(36756003)(42186005)(4396001)(19580395003)(107046002)(33656002)(15975445006)(64706001)(65956001)(54356999)(71186001)(87266999)(20776003)(568964001)(117156001)(66066001)(62966003)(77156002)(77096003)(102836001)(87976001)(92566001)(92726001)(110136001)(40100003)(99396003)(64126003)(15202345003)(230783001)(59896002)(512874002)(95666004)(31966008)(83506001)(46102003)(105586002)(120916001)(97736003)(575784001)(84326002)(122386002)(86362001)(74482002)(101416001)(19627235001); DIR:OUT; SFP:1101; SCL:1; SRVR:DBXPR04MB399; H:[192.168.1.118]; FPR:; MLV:sfv; PTR:InfoNoRecords; MX:1; A:1; LANG:en; X-Exchange-Antispam-Report-CFA-Test: BCL:0;PCL:0;RULEID:;SRVR:DBXPR04MB399; X-OriginatorOrg: giuneco.it Cc: "meta-freescale@yoctoproject.org" Subject: Re: [meta-fsl-arm] [linux-2.6.35-r45] amd-gpu : patch proposal / discussion (imx53 + Qt 5.3 + EGLFS) X-BeenThere: meta-freescale@yoctoproject.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: Usage and development list for the meta-fsl-* layers List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 13 Nov 2014 08:22:27 -0000 X-Groupsio-MsgNum: 11401 Content-Type: multipart/mixed; boundary="------------040103090101050000090709" --------------040103090101050000090709 Content-Type: text/plain; charset="utf-8"; format=flowed Content-Transfer-Encoding: 7bit Hi Daiane, sure , the patch is attached to this mail (let me know if I must to change it) About the cinematicexperience + eglfs dependecies: With the only inclusion of cinematicexperience the "EGL..." error come out , so i must to add the "amd-gpu-bin-mx51" package to have all the necessary library on my fs. Bests Regards Gianluca On 12/11/2014 11:47, Daiane Angolini wrote: > On Tue, Nov 11, 2014 at 10:17 PM, Gianluca Cinci > wrote: >> From 768a9f37734a9c6acb02ac1a832127af9f15da1b Mon Sep 17 00:00:00 2001 >> From: Gianluca Cinci >> Date: Tue, 11 Nov 2014 22:25:17 +0100 >> Subject: [PATCH] avoid shared memory free issue on application exit > I would start the commit subject with "imx: amd-gpu: avoid shared......" > > >> --- >> drivers/mxc/amd-gpu/common/gsl_sharedmem.c | 3 +++ >> 1 file changed, 3 insertions(+) >> >> diff --git a/drivers/mxc/amd-gpu/common/gsl_sharedmem.c >> b/drivers/mxc/amd-gpu/common/gsl_sharedmem.c >> index 51e66f9..2529267 100644 >> --- a/drivers/mxc/amd-gpu/common/gsl_sharedmem.c >> +++ b/drivers/mxc/amd-gpu/common/gsl_sharedmem.c >> @@ -430,6 +430,9 @@ kgsl_sharedmem_free0(gsl_memdesc_t *memdesc, unsigned >> int pid) >> } >> else >> { >> + kgsl_hal_freephysical(memdesc->gpuaddr, NULL, NULL); // free the >> previously allocated memory if >> + >> // gpuaddress is present in gsl_linux_map_list >> + >> status = GSL_FAILURE; >> } >> >> -- >> 1.9.1 >> >> >> Hi all, >> i finally reached to run an Qt 5.3 application on imx53(loco) board (linux >> 2.6.35-r45) >> My problem come out when i try to execute a previously killed application: >> ------------------------------------------------------------------------------------------------------------------------------------ >> Unable to handle kernel paging request at virtual address 8e011800 >> pgd = cf550000 > (...) >> Finally the step to run a Qt 5.3 application on imx53 if someone has this >> problem (tested on a framebuffer system) >> >> 1) add to local.conf or wherever you want the packages: >> ---cinematicexperience >> ---amd-gpu-bin-mx51 (this is usefull because inside the recipe there >> is the PACKAGES variable that is just setted to include the all libraries >> needed. >> The package contains only some test >> binary of GPU acceleration >> NOTE :if the egl libraries were not >> included the Qt 5 application failed to start with EGL Error : Could not >> create the egl surface: error = 0x3003) >> > Does it means we have a dependency error? > > > >> 2)apply the patch to kernel > Would you, please, create a patch for the kernel recipe [1] including > your kernel patch for _mx5? > > [1] http://git.yoctoproject.org/cgit/cgit.cgi/meta-fsl-arm/tree/recipes-kernel/linux/linux-imx_2.6.35.3.bb > > This is something I would like to test. > > > Daiane >> 3) build a new image >> >> 3) run Qt5_CinematicExperience -platform eglfs >> >> During this analysys I didn't find any that conduce to think about some non >> cleaned blocks during normal execution and also the gsl_sanity_app reach the >> end with success every time. >> >> >> Best Regards >> Gianluca Cinci >> >> Notes: >> (*1) : here a kgsl_sharedmem_free (without 0) is called , inside that there >> is a subcall to kgsl_sharedmem_free0 >> >> (*2) : >> the other kernel message mentioned above: >> -------------------------------------------------------------- >> >> >> Unhandled fault: external abort on non-linefetch (0x1008) at 0xd0ac0edc >> Internal error: : 1008 [#1] PREEMPT last sysfs file: >> /sys/devices/system/cpu/online Modules linked in: >> CPU: 0 Not tainted (2.6.35.3-11.09.01+yocto+ged51f22 #1) >> PC is at kgsl_yamato_regread+0xc/0x24 >> LR is at kgsl_yamato_isr+0x18/0x80 >> pc : [<80376c2c>] lr : [<80377450>] psr: 60070193 >> sp : c81dff58 ip : ffffab5e fp : 00000000 >> r10: 00000000 r9 : c81de000 r8 : 00000000 >> r7 : 0000000c r6 : 00000000 r5 : 00000000 r4 : 806a0b28 >> r3 : d0ac0000 r2 : c81dff5c r1 : 000003b7 r0 : 806a0b28 >> Flags: nZCv IRQs off FIQs on Mode SVC_32 ISA ARM Segment user >> Control: 10c5387d Table: ba6e4019 DAC: 00000015 Process QSGRenderThread >> (pid: 1700, stack limit = 0xc81de2e8) >> Stack: (0xc81dff58 to 0xc81e0000) >> ff40: 806a0b28 >> cff48780 >> ff60: 806a0b28 80373b5c cf263f40 803792dc 803792d0 800e9e50 00000000 >> 80641e3c >> ff80: 0000000c cf263f40 00000001 800eb8b4 0000000c 00000000 00000001 >> 80090068 >> ffa0: 20070010 ffffffff d0800000 80090bc8 32681000 01aae330 00003910 >> 00000000 >> ffc0: 01aac450 4c298b80 002f0498 01aac450 00001850 002f8420 00000000 >> 00000000 >> ffe0: 32682ec0 3216d934 4bef37e4 4bc6a0b0 20070010 ffffffff 8e38d48b >> 59ebdc88 >> [<80376c2c>] (kgsl_yamato_regread+0xc/0x24) from [<80377450>] >> (kgsl_yamato_isr+) >> [<80377450>] (kgsl_yamato_isr+0x18/0x80) from [<80373b5c>] >> (kgsl_intr_isr+0x24/) >> [<80373b5c>] (kgsl_intr_isr+0x24/0x28) from [<803792dc>] >> (z430_irq_handler+0xc/) >> [<803792dc>] (z430_irq_handler+0xc/0x18) from [<800e9e50>] >> (handle_IRQ_event+0x) >> [<800e9e50>] (handle_IRQ_event+0x24/0xdc) from [<800eb8b4>] >> (handle_level_irq+0) >> [<800eb8b4>] (handle_level_irq+0xd8/0x184) from [<80090068>] >> (asm_do_IRQ+0x68/0) >> [<80090068>] (asm_do_IRQ+0x68/0x88) from [<80090bc8>] (__irq_usr+0x48/0xc0) >> Exception stack(0xc81dffb0 to 0xc81dfff8) >> ffa0: 32681000 01aae330 00003910 >> 00000000 >> ffc0: 01aac450 4c298b80 002f0498 01aac450 00001850 002f8420 00000000 >> 00000000 >> ffe0: 32682ec0 3216d934 4bef37e4 4bc6a0b0 20070010 ffffffff >> Code: e12fff1e e5903088 f57ff04f f57ff04f (e7933101) ---[ end trace >> 0efc6cf93f26278e ]--- >> Kernel panic - not syncing: Fatal exception in interrupt [<80095144>] >> (unwind_backtrace+0x0/0xe0) from [<804aacfc>] >> (panic+0x68/0xdc) >> [<804aacfc>] (panic+0x68/0xdc) from [<80094158>] (die+0x2a8/0x2f8) >> [<80094158>] (die+0x2a8/0x2f8) >> from [<8009026c>] (do_DataAbort+0x84/0x98) [<8009026c>] >> (do_DataAbort+0x84/0x98) from [<8009092c>] >> (__dabt_svc+0x4c/0x60) >> Exception stack(0xc81dff10 to 0xc81dff58) >> ff00: 806a0b28 000003b7 c81dff5c >> d0ac0000 >> ff20: 806a0b28 00000000 00000000 0000000c 00000000 c81de000 00000000 >> 00000000 >> ff40: ffffab5e c81dff58 80377450 80376c2c 60070193 ffffffff [<8009092c>] >> (__dabt_svc+0x4c/0x60) from [<80376c2c>] >> (kgsl_yamato_regread+0xc/) >> [<80376c2c>] (kgsl_yamato_regread+0xc/0x24) from [<80377450>] >> (kgsl_yamato_isr+) >> [<80377450>] (kgsl_yamato_isr+0x18/0x80) from [<80373b5c>] >> (kgsl_intr_isr+0x24/) >> [<80373b5c>] (kgsl_intr_isr+0x24/0x28) from [<803792dc>] >> (z430_irq_handler+0xc/) >> [<803792dc>] (z430_irq_handler+0xc/0x18) from [<800e9e50>] >> (handle_IRQ_event+0x) >> [<800e9e50>] (handle_IRQ_event+0x24/0xdc) from [<800eb8b4>] >> (handle_level_irq+0) >> [<800eb8b4>] (handle_level_irq+0xd8/0x184) from [<80090068>] >> (asm_do_IRQ+0x68/0) >> [<80090068>] (asm_do_IRQ+0x68/0x88) from [<80090bc8>] (__irq_usr+0x48/0xc0) >> Exception stack(0xc81dffb0 to 0xc81dfff8) >> ffa0: 32681000 01aae330 00003910 >> 00000000 >> ffc0: 01aac450 4c298b80 002f0498 01aac450 00001850 002f8420 00000000 >> 00000000 >> ffe0: 32682ec0 3216d934 4bef37e4 4bc6a0b0 20070010 ffffffff >> --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- >> >> >> >> >> >> >> -- >> _______________________________________________ >> meta-freescale mailing list >> meta-freescale@yoctoproject.org >> https://lists.yoctoproject.org/listinfo/meta-freescale >> --------------040103090101050000090709 Content-Type: text/x-patch; name="imx-amd-gpu-avoid-shared-memory-free-issue.patch" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="imx-amd-gpu-avoid-shared-memory-free-issue.patch" >From 3201b3740bd6c81e7077845bda605fd5043b0e6a Mon Sep 17 00:00:00 2001 From: gianluca Date: Thu, 13 Nov 2014 00:11:51 +0100 Subject: [meta-fsl-arm][PATCH] imx: amd-gpu: avoid shared memory free issue on application exit Signed-off-by: gianluca --- .../avoid-shared-memory-free-issue.patch | 26 ++++++++++++++++++++++ recipes-kernel/linux/linux-imx_2.6.35.3.bb | 1 + 2 files changed, 27 insertions(+) create mode 100644 recipes-kernel/linux/linux-imx-2.6.35.3/avoid-shared-memory-free-issue.patch diff --git a/recipes-kernel/linux/linux-imx-2.6.35.3/avoid-shared-memory-free-issue.patch b/recipes-kernel/linux/linux-imx-2.6.35.3/avoid-shared-memory-free-issue.patch new file mode 100644 index 0000000..a109cc0 --- /dev/null +++ b/recipes-kernel/linux/linux-imx-2.6.35.3/avoid-shared-memory-free-issue.patch @@ -0,0 +1,26 @@ +From 768a9f37734a9c6acb02ac1a832127af9f15da1b Mon Sep 17 00:00:00 2001 +From: gianluca +Date: Tue, 11 Nov 2014 22:25:17 +0100 +Subject: [PATCH] avoid shared memory free issue on application exit + +--- + drivers/mxc/amd-gpu/common/gsl_sharedmem.c | 3 +++ + 1 file changed, 3 insertions(+) + +diff --git a/drivers/mxc/amd-gpu/common/gsl_sharedmem.c b/drivers/mxc/amd-gpu/common/gsl_sharedmem.c +index 51e66f9..2529267 100644 +--- a/drivers/mxc/amd-gpu/common/gsl_sharedmem.c ++++ b/drivers/mxc/amd-gpu/common/gsl_sharedmem.c +@@ -430,6 +430,9 @@ kgsl_sharedmem_free0(gsl_memdesc_t *memdesc, unsigned int pid) + } + else + { ++ kgsl_hal_freephysical(memdesc->gpuaddr, NULL, NULL); // free the previously allocated memory if ++ // gpuaddress is present in gsl_linux_map_list ++ + status = GSL_FAILURE; + } + +-- +1.9.1 + diff --git a/recipes-kernel/linux/linux-imx_2.6.35.3.bb b/recipes-kernel/linux/linux-imx_2.6.35.3.bb index bfc56b7..ad1f10b 100644 --- a/recipes-kernel/linux/linux-imx_2.6.35.3.bb +++ b/recipes-kernel/linux/linux-imx_2.6.35.3.bb @@ -19,6 +19,7 @@ SRCBRANCH = "imx_2.6.35_maintain" SRC_URI += "file://NFS-Fix-nfsroot-support.patch \ file://NFS-allow-nfs-root-mount-to-use-alternate-rpc-ports.patch \ file://perf-avoid-use-sysroot-headers.patch \ + file://avoid-shared-memory-free-issue.patch \ " SRC_URI_append_mx28 = " \ -- 1.9.1 --------------040103090101050000090709--