xserver-xorg-core_21.1.3-2ubuntu2.5 segfaults

Bug #1999852 reported by Markus
10
This bug affects 1 person
Affects Status Importance Assigned to Milestone
xorg-server (Ubuntu)
New
Undecided
Unassigned

Bug Description

Running xserver-xorg-core_21.1.3-2ubuntu2.3_amd64.deb was fine.
Since the recent update to xserver-xorg-core_21.1.3-2ubuntu2.5_amd64.deb Xorg always segfaults at startup.
Going back to xserver-xorg-core_21.1.3-2ubuntu2.3_amd64.deb works again.
(Tried it multiple times and it is reproducable.)

The errors from the last Xorg.log:
[ 54.562] (EE) Backtrace:
[ 54.563] (EE) 0: /usr/lib/xorg/Xorg (OsLookupColor+0x139) [0x560707b09719]
[ 54.564] (EE) 1: /lib/x86_64-linux-gnu/libc.so.6 (__sigaction+0x50) [0x7f40658cd520]
[ 54.564] (EE) 2: /usr/lib/xorg/Xorg (xf86ModeVRefresh+0x4) [0x560707a0e724]
[ 54.565] (EE) unw_get_proc_name failed: no unwind info found [-10]
[ 54.565] (EE) 3: /usr/lib/xorg/modules/drivers/modesetting_drv.so (?+0x0) [0x7f406513b9b0]
[ 54.565] (EE) 4: /usr/lib/xorg/Xorg (xf86ProbeOutputModes+0x147) [0x560707a07e47]
[ 54.565] (EE) 5: /usr/lib/xorg/Xorg (xf86InitialConfiguration+0x191) [0x560707a089b1]
[ 54.565] (EE) unw_get_proc_name failed: no unwind info found [-10]
[ 54.565] (EE) 6: /usr/lib/xorg/modules/drivers/modesetting_drv.so (?+0x0) [0x7f406513f07c]
[ 54.566] (EE) unw_get_proc_name failed: no unwind info found [-10]
[ 54.566] (EE) 7: /usr/lib/xorg/modules/drivers/modesetting_drv.so (?+0x0) [0x7f40651374bf]
[ 54.566] (EE) 8: /usr/lib/xorg/Xorg (InitOutput+0xb8b) [0x5607079d73ab]
[ 54.566] (EE) 9: /usr/lib/xorg/Xorg (InitFonts+0x1dc) [0x56070799734c]
[ 54.567] (EE) 10: /lib/x86_64-linux-gnu/libc.so.6 (__libc_init_first+0x90) [0x7f40658b4d90]
[ 54.567] (EE) 11: /lib/x86_64-linux-gnu/libc.so.6 (__libc_start_main+0x80) [0x7f40658b4e40]
[ 54.568] (EE) 12: /usr/lib/xorg/Xorg (_start+0x25) [0x560707980605]
[ 54.568] (EE)
[ 54.568] (EE) Segmentation fault at address 0xa8
[ 54.568] (EE)
Fatal server error:
[ 54.568] (EE) Caught signal 11 (Segmentation fault). Server aborting
[ 54.568] (EE)
[ 54.568] (EE)

Revision history for this message
Markus (markusxxl) wrote (last edit ):

Did some manual builds:
build xserver-xorg-core_21.1.3-2ubuntu2.5 as installed => it segfaults
removed all patches that were added since 2.3 => worked

bisecting ended with the bad patch being re-calculate-the-clock-and-refresh-rate.diff.

Verified with xserver-xorg-core_21.1.3-2ubuntu2.5 and only disabled that patch => worked

Revision history for this message
Markus (markusxxl) wrote :
Revision history for this message
Markus (markusxxl) wrote :
Revision history for this message
Markus (markusxxl) wrote :

The problem is "preferred" being accessed unconditionally.
All the other usages are covered by a check of "preferred", so I added it.
Now it works again.

Chia-Lin Kao (AceLan) should double check, as it is his patch.
Commented in his upstream MR:
https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/993

Revision history for this message
Markus (markusxxl) wrote :
tags: added: patch
Revision history for this message
Ubuntu Foundations Team Bug Bot (crichton) wrote :

The attachment "Adjusted patch" seems to be a patch. If it isn't, please remove the "patch" flag from the attachment, remove the "patch" tag, and if you are a member of the ~ubuntu-reviewers, unsubscribe the team.

[This is an automated message performed by a Launchpad user owned by ~brian-murray, for any issues please contact him.]

Revision history for this message
Timo Aaltonen (tjaalton) wrote :

yes, the issue is known and the fixed patch is on the sru queue

https://bugs.launchpad.net/ubuntu/+source/xorg-server/+bug/1999008

Revision history for this message
Markus (markusxxl) wrote (last edit ):

Its related to the same patch, but not sure it will solve this issue.
The linked upstream MR checks for xf86ModeVRefresh returning 0 but still fails for me.
(This problem/bug is not xf86ModeVRefresh returning 0 and then dividing by 0 and SIGABRT, but calling it with a NULL pointer and SIGSEGV.)

Is the new patch available for me to test?

Revision history for this message
AceLan Kao (acelankao) wrote :

Hi Markus,

Thanks for reporting the preferred issue, I'll submit new MR soon.

Revision history for this message
Markus (markusxxl) wrote :

I didnt say you can skip the check for xf86ModeVRefresh returning 0.

The two bug reports may report two different bugs, triggered by different inputs.
(So maybe both checks are neccessary, but I cannot speak for #1999008, because I dont face that specific behaviour.)

Revision history for this message
AceLan Kao (acelankao) wrote :

Right, I updated the check, will verify it again, thanks.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.