Bug 27267 - Updated mesa packages fix Applications (ex.: Firefox, Xfwm4) segfaults with r300_dri.so
Summary: Updated mesa packages fix Applications (ex.: Firefox, Xfwm4) segfaults with r...
Status: RESOLVED FIXED
Alias: None
Product: Mageia
Classification: Unclassified
Component: RPM Packages (show other bugs)
Version: 7
Hardware: i586 Linux
Priority: Normal normal
Target Milestone: Mageia 7
Assignee: QA Team
QA Contact:
URL:
Whiteboard: MGA7-32-OK MGA7-64-OK
Keywords: advisory, validated_update
: 27028 27491 (view as bug list)
Depends on:
Blocks: 27028
  Show dependency treegraph
 
Reported: 2020-09-09 20:40 CEST by Ihar Areshchankau
Modified: 2020-11-08 15:15 CET (History)
6 users (show)

See Also:
Source RPM: mesa-20.0.7-3.mga7.src.rpm
CVE:
Status comment:


Attachments
Firefox tab crash explanation (32.35 KB, image/png)
2020-09-10 10:46 CEST, Ihar Areshchankau
Details

Description Ihar Areshchankau 2020-09-09 20:40:41 CEST
Description of problem:
Firefox web browser (firefox-68.12.0-2.mga7) crashes on opening websites that uses Yandex Metrika counter (mc.yandex.ru), as sample: https://tut.by

Version-Release number of selected component (if applicable):
firefox-68.12.0-2.mga7.i586

Hardware:
Biostar TA690G AM2, ATI Radeon X1200
OS version:
Linux version 5.4.12-desktop586-1.mga7 (iurt@rabbit.mageia.org) (gcc version 8.3.1 20191101 (Mageia 8.3.1-0.20191101.1.mga7)) #1 SMP Tue Jan 14 21:09:02 UTC 2020

How reproducible:
Every time when open web site that contains Yandex Metrika counter.

Steps to Reproduce:
1. Run Firefox web browser
2. Type URL: "tut.by" and press Enter key.
3. Wait until mc.yandex.ru counters code will be received.

dmesg lines on crash events:
[  173.790187] Web Content[2280]: segfault at 4f ip 9d746f19 sp bfa80bb0 error 4 in r300_dri.so[9d197000+d98000]
[  173.790204] Code: 81 ec 8c 00 00 00 0f b6 84 24 a8 00 00 00 8d 8f 28 d9 a8 ff 89 7c 24 0c 8b bc 24 a4 00 00 00 88 44 24 4f 8b 84 24 a0 00 00 00 <0f> be 50 4c c7 07 02 00 00 00 c7 87 38 07 00 00 02 00 00 00 8b 1c
[  276.099607] Web Content[2499]: segfault at 4f ip 9cf6bf19 sp bfc9fdc0 error 4 in r300_dri.so[9c9bc000+d98000]
[  276.099621] Code: 81 ec 8c 00 00 00 0f b6 84 24 a8 00 00 00 8d 8f 28 d9 a8 ff 89 7c 24 0c 8b bc 24 a4 00 00 00 88 44 24 4f 8b 84 24 a0 00 00 00 <0f> be 50 4c c7 07 02 00 00 00 c7 87 38 07 00 00 02 00 00 00 8b 1c
[  308.181544] Web Content[2537]: segfault at 4f ip 988a7f19 sp bf9d4050 error 4 in r300_dri.so[982f8000+d98000]
[  308.181562] Code: 81 ec 8c 00 00 00 0f b6 84 24 a8 00 00 00 8d 8f 28 d9 a8 ff 89 7c 24 0c 8b bc 24 a4 00 00 00 88 44 24 4f 8b 84 24 a0 00 00 00 <0f> be 50 4c c7 07 02 00 00 00 c7 87 38 07 00 00 02 00 00 00 8b 1c

Notes:
xfwm4 downgraded to the version 4.13.2-1.mga7.i586 due the same trouble.
Version firefox-67.0.4-1.mga7.i586 from "Core Release" works correct.
This bug may be related to #27028 (xfwm4 segfault in r300_dri.so on the same hardware).
Comment 1 Aurelien Oudelet 2020-09-09 21:02:20 CEST
Hi, thanks for reporting this bug.

urpmf -f r300_dri.so
lib64dri-drivers
urpmq -i lib64dri-drivers
mesa

Seems a bug related to mesa stack.

Assigned to the package maintainer.
(Packager: Please set the status to 'assigned' if you are working on it)

Assignee: bugsquad => thierry.vignaud
Target Milestone: --- => Mageia 7
Source RPM: (none) => mesa
Keywords: (none) => Triaged

Aurelien Oudelet 2020-09-09 21:02:41 CEST

Assignee: thierry.vignaud => kernel
CC: (none) => thierry.vignaud

Lewis Smith 2020-09-09 22:22:48 CEST

See Also: (none) => https://bugs.mageia.org/show_bug.cgi?id=27028

Comment 2 Lewis Smith 2020-09-09 22:39:36 CEST
What software is at fault? On my up-to-date x64 M7 system,
 firefox-68.12.0-2.mga7
this bug does not happen. https://www.tut.by/ views correctly during a long time.
No mention of r300_dri.so in dmesg nor system journal. Its host package is:
 lib64dri-drivers-20.0.7-3.mga7   (updated 24 May 2020)

The related bug 27028 does not happen here either.
Is this a 32-bit-only problem?

CC: (none) => lewyssmith

Comment 3 Ihar Areshchankau 2020-09-10 10:41:51 CEST
(In reply to Lewis Smith from comment #2)
> What software is at fault? On my up-to-date x64 M7 system,
>  firefox-68.12.0-2.mga7
> this bug does not happen. https://www.tut.by/ views correctly during a long
> time.
> No mention of r300_dri.so in dmesg nor system journal. Its host package is:
>  lib64dri-drivers-20.0.7-3.mga7   (updated 24 May 2020)
> 
> The related bug 27028 does not happen here either.
> Is this a 32-bit-only problem?

firefox 67.0.4-1.mga7 - ok
firefox 68.0-1.1.mga7 - segfault

I use 32 bit system only and cannot say about 64 bit system.

I found that the system uses kernel 5.4.12-desktop586-1.mga7 while the latest is 5.7.19-1.mga7. I will configure the bootloader for it and report the results later.
Comment 4 Ihar Areshchankau 2020-09-10 10:46:15 CEST
Created attachment 11874 [details]
Firefox tab crash explanation
Comment 5 Ihar Areshchankau 2020-09-10 16:04:44 CEST
(In reply to Aurelien Oudelet from comment #1)
> Hi, thanks for reporting this bug.
> 
> urpmf -f r300_dri.so
> lib64dri-drivers
> urpmq -i lib64dri-drivers
> mesa
> 
> Seems a bug related to mesa stack.
> 
> Assigned to the package maintainer.
> (Packager: Please set the status to 'assigned' if you are working on it)

I found that downgrade to the version {mesa,libmesagl1,libdri-drivers}-19.3.4-1.mga7.i586 solves the segfault of both firefox (this bug) and xfwm4 (bug #27028). And installing {mesa,libmesagl1,libdri-drivers}-20.0.1-1.mga7.i586 brings the segfault back again.

I verified this on actual kernel version 5.7.19-desktop586-1.mga7.

Thank you very much for the detailed description how to find the source of the problem.
Comment 6 Ihar Areshchankau 2020-09-10 16:09:25 CEST
(In reply to Lewis Smith from comment #2)
> What software is at fault?

{mesa,libmesagl1,libdri-drivers}-19.3.4-1.mga7.i586 - Ok
{mesa,libmesagl1,libdri-drivers}-20.0.1-1.mga7.i586 - segfault

This is true for the both cases #27028 and #27267.
Comment 7 Lewis Smith 2020-09-10 21:43:00 CEST
Thank you for the package version details above. It should help to locate the fault.

My question "What software is at fault?" in comment 2  was not directed at you, but a generic one. Your comments 5 & 6 rather answer it; and accord with Aurelian's c1 "Seems a bug related to mesa stack".

For M7, mesa was done by tmb; for M8, ghibo. Changing the CC to the latter.

CC: lewyssmith, thierry.vignaud => ghibomgx
Source RPM: mesa => mesa-20.0.1-1.mga7.src.rpm

Comment 8 Giuseppe Ghibò 2020-09-10 22:21:10 CEST
I think it's worthwhile to upgrade mesa in mga7 too, as there were a lot of bug fixes. Current cauldron mesa spec file can be easily compiled on mga7 (there are a few version binary conmpiled on copr for testing if needed). 20.1.7 works, 20.2.0-rc4 too. Final 20.2.0 should arrive next week. I had no problems on both. Only extra-requirement for compiling is a new meson 0.52.1 backport (0.54 won't backport correctly in mga7).

In the meanwhile he can try whether using only software acceleration would cause the same segfault too, e.g. launching firefox with "LIBGL_ALWAYS_SOFTWARE=1 firefox".
Comment 9 Ihar Areshchankau 2020-09-11 09:15:08 CEST
(In reply to Giuseppe Ghibò from comment #8)
> In the meanwhile he can try whether using only software acceleration would
> cause the same segfault too, e.g. launching firefox with
> "LIBGL_ALWAYS_SOFTWARE=1 firefox".

I added the line "LIBGL_ALWAYS_SOFTWARE=1" to the file "/etc/environment" and this workaround solves both bugs. The latest versions of xfm4 and firefox both works like a charm using mesa-20.0.7-3. Thank you.
Comment 10 Giuseppe Ghibò 2020-09-11 22:40:39 CEST
There is available a newer mesa-20.1.7-1.mga7 in updates_testing of mga7 you might want to test.
Comment 11 Ihar Areshchankau 2020-09-13 09:59:04 CEST
(In reply to Giuseppe Ghibò from comment #10)
> There is available a newer mesa-20.1.7-1.mga7 in updates_testing of mga7 you
> might want to test.

I installed mesa-20.1.7-1.mga7 with its dependencies and removed the LIBGL_ALWAYS_SOFTWARE variable from the environment. The system works correct, the segfault error has left from the both xfwm4 and firefox.

So the bug of the tickets #27028 and #27267 is found and solved. Thank you.
Comment 12 Aurelien Oudelet 2020-09-13 10:46:44 CEST
Seems we have a candidate update. Don't close this bug until we release this.

CC: (none) => ouaurelien

Aurelien Oudelet 2020-09-13 10:49:59 CEST

Blocks: (none) => 27028

Comment 13 Giuseppe Ghibò 2020-10-15 12:35:25 CEST
Hi, FYI, since it can be a candidate for official update, I updated the mesa for mga7 to 20.2.1 (sync with cauldron), currently in updates_testing. Other packages to be bundled/needed for building this update: libdrm 2.4.102, meson 0.52.1 (both in updates_testing).
Comment 14 David Walser 2020-10-15 18:54:03 CEST
Please provide a package list (RPMs and SRPMs) and an advisory and assign the update to QA.
Comment 15 David Walser 2020-10-28 23:28:03 CET
(In reply to David Walser from comment #14)
> Please provide a package list (RPMs and SRPMs) and an advisory and assign
> the update to QA.

Ping Giuseppe.
Comment 16 Giuseppe Ghibò 2020-10-29 20:57:03 CET
See #27491
Aurelien Oudelet 2020-10-29 21:06:12 CET

Depends on: (none) => 27491

Comment 17 Aurelien Oudelet 2020-10-29 21:17:55 CET
On behalf of Giuseppe Ghibò:

----------------------------------------
Suggested advisory:

Updated mesa libdrm and meson packages fix r300_dri.so flaws and other fixes

Current mesa-20.0.1 has some flaws in r300_dri.so driver (see bug #27267) causing crashes on firefox68; Mesa 20.1.x fixes it, among other bugs. However, Mesa 20.1.x series arrived at end of life and upstream advised to update to 20.2.x series (see https://www.mesa3d.org/news/releases/mesa-20-1-10-is-released/).

Here is a list of SRPMS packages required (in building order, actually in updates_testing) for building mesa 20.2.1:

SRPMS:

- meson-0.52.1-1.mga7.src.rpm
- libdrm-2.4.102-1.mga7.src.rpm
- mesa-20.2.1-1.mga7.src.rpm

and here is the resulting RPMS for i586 and x86_64:

i586:
drm-utils-2.4.102-1.mga7.i586.rpm
libdrm-common-2.4.102-1.mga7.i586.rpm
libdrm-devel-2.4.102-1.mga7.i586.rpm
libdrm2-2.4.102-1.mga7.i586.rpm
libdrm_amdgpu1-2.4.102-1.mga7.i586.rpm
libdrm_intel1-2.4.102-1.mga7.i586.rpm
libdrm_nouveau2-2.4.102-1.mga7.i586.rpm
libdrm_radeon1-2.4.102-1.mga7.i586.rpm
libkms1-2.4.102-1.mga7.i586.rpm
libd3d1-20.2.1-1.mga7.i586.rpm
libd3d1-devel-20.2.1-1.mga7.i586.rpm
libdri-drivers-20.2.1-1.mga7.i586.rpm
libgbm1-20.2.1-1.mga..>
libgbm1-20.2.1-1.mga7.i586.rpm
libgbm1-devel-20.2.1-1.mga7.i586.rpm
libglapi0-20.2.1-1.mga7.i586.rpm
libglapi0-devel-20.2.1-1.mga7.i586.rpm
libmesaegl1-20.2.1-1.mga7.i586.rpm
libmesaegl1-devel-20.2.1-1.mga7.i586.rpm
libmesagl1-20.2.1-1.mga7.i586.rpm
libmesagl1-devel-20.2.1-1.mga7.i586.rpm
libmesaglesv1_1-20.2.1-1.mga7.i586.rpm
libmesaglesv1_1-devel-20.2.1-1.mga7.i586.rpm
libmesaglesv2_2-20.2.1-1.mga7.i586.rpm
libmesaglesv2_2-devel-20.2.1-1.mga7.i586.rpm
libmesakhr-devel-20.2.1-1.mga7.i586.rpm
libmesaopencl-devel-20.2.1-1.mga7.i586.rpm
libmesaopencl1-20.2.1-1.mga7.i586.rpm
libmesavulkan-devel-20.2.1-1.mga7.i586.rpm
libmesavulkan-drivers-20.2.1-1.mga7.i586.rpm
libosmesa-devel-20.2.1-1.mga7.i586.rpm
libosmesa8-20.2.1-1.mga7.i586.rpm
libvdpau-driver-nouveau-20.2.1-1.mga7.i586.rpm
libvdpau-driver-r300-20.2.1-1.mga7.i586.rpm
libvdpau-driver-r600-20.2.1-1.mga7.i586.rpm
libvdpau-driver-radeonsi-20.2.1-1.mga7.i586.rpm
libxatracker2-20.2.1-1.mga7.i586.rpm
libxatracker2-devel-20.2.1-1.mga7.i586.rpm
mesa-20.2.1-1.mga7.i586.rpm
mesa-common-devel-20.2.1-1.mga7.i586.rpm
mesa-omx-drivers-20.2.1-1.mga7.i586.rpm
meson-0.52.1-1.mga7.noarch.rpm

x86_64:
drm-utils-2.4.102-1.mga7.x86_64.rpm
lib64drm-devel-2.4.102-1.mga7.x86_64.rpm
lib64drm2-2.4.102-1.mga7.x86_64.rpm
lib64drm_amdgpu1-2.4.102-1.mga7.x86_64.rpm
lib64drm_intel1-2.4.102-1.mga7.x86_64.rpm
lib64drm_nouveau2-2.4.102-1.mga7.x86_64.rpm
lib64drm_radeon1-2.4.102-1.mga7.x86_64.rpm
lib64kms1-2.4.102-1.mga7.x86_64.rpm
libdrm-common-2.4.102-1.mga7.x86_64.rpm
lib64d3d1-20.2.1-1.mga7.x86_64.rpm
lib64d3d1-devel-20.2.1-1.mga7.x86_64.rpm
lib64dri-drivers-20.2.1-1.mga7.x86_64.rpm
lib64gbm1-20.2.1-1.mga7.x86_64.rpm
lib64gbm1-devel-20.2.1-1.mga7.x86_64.rpm
lib64glapi0-20.2.1-1.mga7.x86_64.rpm
lib64glapi0-devel-20.2.1-1.mga7.x86_64.rpm
lib64mesaegl1-20.2.1-1.mga7.x86_64.rpm
lib64mesaegl1-devel-20.2.1-1.mga7.x86_64.rpm
lib64mesagl1-20.2.1-1.mga7.x86_64.rpm
lib64mesagl1-devel-20.2.1-1.mga7.x86_64.rpm
lib64mesaglesv1_1-20.2.1-1.mga7.x86_64.rpm
lib64mesaglesv1_1-devel-20.2.1-1.mga7.x86_64.rpm
lib64mesaglesv2_2-20.2.1-1.mga7.x86_64.rpm
lib64mesaglesv2_2-devel-20.2.1-1.mga7.x86_64.rpm
lib64mesakhr-devel-20.2.1-1.mga7.x86_64.rpm
lib64mesaopencl-devel-20.2.1-1.mga7.x86_64.rpm
lib64mesaopencl1-20.2.1-1.mga7.x86_64.rpm
lib64mesavulkan-devel-20.2.1-1.mga7.x86_64.rpm
lib64mesavulkan-drivers-20.2.1-1.mga7.x86_64.rpm
lib64openswr0-20.2.1-1.mga7.x86_64.rpm
lib64osmesa-devel-20.2.1-1.mga7.x86_64.rpm
lib64osmesa8-20.2.1-1.mga7.x86_64.rpm
lib64vdpau-driver-nouveau-20.2.1-1.mga7.x86_64.rpm
lib64vdpau-driver-r300-20.2.1-1.mga7.x86_64.rpm
lib64vdpau-driver-r600-20.2.1-1.mga7.x86_64.rpm
lib64vdpau-driver-radeonsi-20.2.1-1.mga7.x86_64.rpm
lib64xatracker2-20.2.1-1.mga7.x86_64.rpm
lib64xatracker2-devel-20.2.1-1.mga7.x86_64.rpm
mesa-20.2.1-1.mga7.x86_64.rpm
mesa-common-devel-20.2.1-1.mga7.x86_64.rpm
mesa-omx-drivers-20.2.1-1.mga7.x86_64.rpm
meson-0.52.1-1.mga7.noarch.rpm


Sending this to QA.

Keywords: Triaged => (none)
Assignee: kernel => qa-bugs

Aurelien Oudelet 2020-10-29 21:18:04 CET

Depends on: 27491 => (none)

Comment 18 Aurelien Oudelet 2020-10-29 21:20:29 CET
*** Bug 27028 has been marked as a duplicate of this bug. ***
Aurelien Oudelet 2020-10-29 21:27:06 CET

Source RPM: mesa-20.0.1-1.mga7.src.rpm => mesa-20.0.7-3.mga7.src.rpm
Summary: Firefox web browser segfault in r300_dri.so => Updated mesa packages fix Applications (ex.: Firefox, Xfwm4) segfaults with r300_dri.so

Comment 19 James Kerr 2020-10-30 19:59:55 CET
on mga7-64  plasma  kernel-desktop

Packages installed cleanly:
- lib64dri-drivers-20.2.1-1.mga7.x86_64
- lib64drm2-2.4.102-1.mga7.x86_64
- lib64drm_amdgpu1-2.4.102-1.mga7.x86_64
- lib64drm_intel1-2.4.102-1.mga7.x86_64
- lib64drm_nouveau2-2.4.102-1.mga7.x86_64
- lib64drm_radeon1-2.4.102-1.mga7.x86_64
- lib64gbm1-20.2.1-1.mga7.x86_64
- lib64glapi0-20.2.1-1.mga7.x86_64
- lib64mesaegl1-20.2.1-1.mga7.x86_64
- lib64mesagl1-20.2.1-1.mga7.x86_64
- lib64mesavulkan-drivers-20.2.1-1.mga7.x86_64
- lib64xatracker2-20.2.1-1.mga7.x86_64
- libdrm-common-2.4.102-1.mga7.x86_64
- mesa-20.2.1-1.mga7.x86_64

no regressions observed 

looks OK for mga7-64 on this system:

Card: Intel HD Graphics 530
CPU: Quad core Intel Core i7-6700 (-HT-MCP-

CC: (none) => jim

Comment 20 David Walser 2020-10-30 20:13:27 CET
*** Bug 27491 has been marked as a duplicate of this bug. ***
Comment 21 Len Lawrence 2020-10-31 21:28:31 CET
mga7, x86_64

Ensured that the stack was fully furnished before updating.  42 packages in the list, starting here with versions 20.0.7 et alii.

Tried tut.by site, which came up OK - all Cyrillic characters, a news site by the look of it.  Links opened OK.  So, no sign of a crash in Firefox 78.4.0esr.

Everything updated cleanly.
My mesa-demos package seems to be out-of-date because nothing will compile any more.
Tried out a few applications, like xine, which uses xine-ui, vlc and xplayer.  No problems there.

Reinforcing comment 19.

CC: (none) => tarazed25

Comment 22 Len Lawrence 2020-10-31 21:42:54 CET
Apropos mesa-demos.  The installed package  works fine.  The earlier reference was to source code.
Comment 23 Thomas Andrews 2020-11-01 00:50:35 CET
Since this bug was filed against 32-bit, I decided to test with my 32-bit hardware: Dell Inspiron 5100, 32-bit P4, 2GB RAM, Radeon RV200 graphics, Atheros wifi, 32-bit Xfce system.

Even before the update, the example link in Comment 0 appeared to display correctly in Firefox 78.4, making it difficult to confirm that this update solves the reported problem. However...

The published 32-bit package list contains one extra line that caused QARepo to throw an error: libgbm1-20.2.1-1.mga..> It appears to be some sort of mistake, an incomplete version of the line following it.

The following 15 packages are going to be installed:

- libdri-drivers-20.2.1-1.mga7.i586
- libdrm-common-2.4.102-1.mga7.i586
- libdrm2-2.4.102-1.mga7.i586
- libdrm_amdgpu1-2.4.102-1.mga7.i586
- libdrm_intel1-2.4.102-1.mga7.i586
- libdrm_nouveau2-2.4.102-1.mga7.i586
- libdrm_radeon1-2.4.102-1.mga7.i586
- libgbm1-20.2.1-1.mga7.i586
- libglapi0-20.2.1-1.mga7.i586
- libmesaegl1-20.2.1-1.mga7.i586
- libmesagl1-20.2.1-1.mga7.i586
- libmesavulkan-drivers-20.2.1-1.mga7.i586
- libvulkan-loader1-1.1.106.0-1.mga7.i586
- libxatracker2-20.2.1-1.mga7.i586
- mesa-20.2.1-1.mga7.i586

No installation issues. After a reboot, no new issues were noted. The link in Comment 0 still displays correctly, as do all others that I tried. Looks OK on this hardware.

CC: (none) => andrewsfarm
Whiteboard: (none) => MGA7-32-OK

Comment 24 Len Lawrence 2020-11-01 01:10:25 CET
Well spotted TJ - the double entry for libgbm1.  So, 41 packages in the stack.
Comment 25 Thomas Andrews 2020-11-01 16:51:38 CET
Len, the extra package line only appears in the list of 32-bit packages. The 64-bit list downloads as listed with QARepo.

 (In reply to Len Lawrence from comment #22)
> Apropos mesa-demos.  The installed package  works fine.  The earlier
> reference was to source code.

Based on this and the comment before it, I'm going to give this a 64-bit OK and validate it. Len, if you have any objections, please let me know. Advisory in Comment 17.

CC: (none) => sysadmin-bugs
Keywords: (none) => validated_update
Whiteboard: MGA7-32-OK => MGA7-32-OK MGA7-64-OK

Comment 26 Thomas Andrews 2020-11-01 16:57:04 CET
Just to try it, I did install the packages on one of my 64-bit Plasma systems, and tried loading the link from Comment 0. The link worked on that system with Firefox 78.4 as well, both before and after the update, and nothing seems to be broken.

So, confirming the OK.
Comment 27 Len Lawrence 2020-11-01 18:08:25 CET
@TJ re comment 25.
Just ignore me.  This dementia thing is getting out of hand. ;-)
Comment 28 Aurelien Oudelet 2020-11-02 19:58:07 CET
Advisory pushed to SVN.

Keywords: (none) => advisory

Comment 29 Mageia Robot 2020-11-08 15:15:43 CET
An update for this issue has been pushed to the Mageia Updates repository.

https://advisories.mageia.org/MGAA-2020-0225.html

Resolution: (none) => FIXED
Status: NEW => RESOLVED


Note You need to log in before you can comment on or make changes to this bug.