Bug 166571 - Xserver infinite loop if xf86PciBus list contains bridge with primary bus value of -1
Xserver infinite loop if xf86PciBus list contains bridge with primary bus val...
Status: CLOSED ERRATA
Product: Red Hat Enterprise Linux 4
Classification: Red Hat
Component: xorg-x11 (Show other bugs)
4.0
i686 Linux
medium Severity medium
: ---
: ---
Assigned To: Mike A. Harris
:
Depends On:
Blocks: 168429
  Show dependency treegraph
 
Reported: 2005-08-23 10:15 EDT by Bruce Vessey
Modified: 2007-11-30 17:07 EST (History)
4 users (show)

See Also:
Fixed In Version: RHBA-2006-0072
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2006-03-07 13:15:46 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Bruce Vessey 2005-08-23 10:15:45 EDT
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.7.5) Gecko/20041107 Firefox/1.0

Description of problem:
There is a bug in the Xserver on RHEL4 which will cause the Xserver to hang in an infinite loop on startup on Unisys ES7000/600 systems. The problem is in source file xc/programs/Xserver/hw/xfree86/common/xf86pciBus.c in routine FindPCIVideoInfo. The while(TRUE) loop will never break if the xf86PciBus list contains a bridge with a primary bus value of negative one. There is a patch, XFree86-4.3.0-ia64-pci-infinite-loop.patch, in the source RPM, xorg-x11-6.8.1-23.EL.src.rpm, which fixes this problem. However, the patch is ifdef’ed ia64 only, and the bug is not unique to ia64 systems. The problem can occur on any system that leaves the primary bus on a bridge as -1, like the ES7000/600 running in x86_64 or ia32 mode. The loop should never continue past a bus number of -1 on any system, so the ifdef’s should be removed from the patch, and the while(TRUE) code should be replaced with the while(j >= 0) code unconditionally. 

As an alternative to the current patch file in the Redhat source, Egbert Eich released a patch on 10-12-2004 to the head of the Xorg tree (cvs revision 1.5) to routine xf86GetPciBridgeInfo. His patch addresses the problem more close to the root by preventing table entries with a primary bus value of negative one from occurring in the first place.

[I've opened this bug on behalf of Bill Jordan -- william.jordan@unisys.com -- because he's still in the process of getting his bugzilla id set up.]

Version-Release number of selected component (if applicable):


How reproducible:
Always

Steps to Reproduce:
1.  This can be reproduced on an ES7000/600 simply by entering GUI mode.  HOWEVER, Unisys has detoured this modifying the BIOS to turn off the VGA_EN bit in the PCI-to-PCI bridge hosting the video chip.  Therefore, you'll need to get a test BIOS from Unisys to restore the original behavior.  


Actual Results:  You never successfully enter GUI mode; Xserver hangs in a loop.

Expected Results:  Enter GUI mode.

Additional info:

Additional details about the ES7000/600's internal architecture and how it exposed this bug can be provided upon request.  Please feel free to contact William.Jordan@unisys.com or Jason.Davis@unisys.com
Comment 6 Andrius Benokraitis 2005-08-30 10:59:27 EDT
Bruce, could you create an Issue Tracker for this? I don't recall discussing
this in our meeting today... Thanks! :-)
Comment 12 Mike A. Harris 2005-11-29 07:34:20 EST
(In reply to comment #3)
> This one will need extensive testing since it is known that some x86-64 
> systems have issues with this hack (at least they did on the kernel level)

As such, rather than making the patch apply to non-ia64, I decided to backport
the patch from CVS instead, as it seems like the better long term solution:

>As an alternative to the current patch file in the Redhat source, Egbert Eich
>released a patch on 10-12-2004 to the head of the Xorg tree (cvs revision 1.5)
>to routine xf86GetPciBridgeInfo. His patch addresses the problem more close to
>the root by preventing table entries with a primary bus value of negative one
>from occurring in the first place.

Comment 13 Mike A. Harris 2005-11-29 08:08:58 EST
* Tue Nov 29 2005 Mike A. Harris <mharris@redhat.com> 6.8.2-1.EL.13.22
- Added xorg-x11-6.8.2-Xserver-pci-infinite-loop.patch, replacing previous
  workaround XFree86-4.3.0-ia64-pci-infinite-loop.patch which was
  conditionalized to ia64, which fixes bug (#166571).
Comment 17 Red Hat Bugzilla 2006-03-07 13:15:48 EST
An advisory has been issued which should help the problem
described in this bug report. This report is therefore being
closed with a resolution of ERRATA. For more information
on the solution and/or where to find the updated files,
please follow the link below. You may reopen this bug report
if the solution does not work for you.

http://rhn.redhat.com/errata/RHBA-2006-0072.html

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