android_kernel_xiaomi_sdm845/arch/powerpc
Paul Mackerras 16124f10df powerpc: Fix pciconfig_iobase system call on PCI-Express powermac
X has been failing to start on my quad G5 powermac since commit
1fd0f52583 ("powerpc: Fix domain numbers
in /proc on 64-bit") went in.  The reason is that the change allows X
to see the PCI-PCI bridge above the video card (previously it was
obscured by the fact that there were two "00" directories in
/proc/bus/pci), and the pciconfig_iobase system call on the bridge is
failing because of a hack that we have to return information about the
AGP bus when X asks about bus 0.  This machine doesn't have an AGP bus
(it has PCI Express) and so the pciconfig_iobase call is returning -1,
which ultimately causes X to fail to start.

This fixes it by checking that we have an AGP bridge before
redirecting the pciconfig_iobase call to return information about the
AGP bus.  With this, X starts successfully both on a quad G5 with
PCI Express and on an older dual G5 with AGP.

Signed-off-by: Paul Mackerras <paulus@samba.org>
Acked-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
2009-01-08 16:25:11 +11:00
..
boot powerpc: Copy bootable images in the default install script 2009-01-08 16:25:09 +11:00
configs powerpc/85xx: Add SMP support to MPC8572 DS 2008-12-30 11:30:42 -06:00
include/asm Merge commit 'origin/master' into next 2009-01-08 16:24:38 +11:00
kernel powerpc: Fix pciconfig_iobase system call on PCI-Express powermac 2009-01-08 16:25:11 +11:00
kvm KVM: Consolidate userspace memory capability reporting into common code 2008-12-31 16:55:46 +02:00
lib Merge branch 'next' of git://git.kernel.org/pub/scm/linux/kernel/git/paulus/powerpc 2008-12-28 16:54:33 -08:00
math-emu powerpc: Add SPE/EFP math emulation for E500v1/v2 processors. 2008-12-03 08:19:16 -06:00
mm powerpc/mm: Cleanup careful_allocation(): consolidate memset() 2009-01-08 16:25:09 +11:00
oprofile trivial: fix then -> than typos in comments and documentation 2009-01-06 11:28:06 +01:00
platforms powerpc/pasemi: Use DEFINE_SPINLOCK 2009-01-08 16:25:11 +11:00
sysdev Merge commit 'origin/master' into next 2009-01-08 16:24:38 +11:00
xmon powerpc: Prepare xmon_save_regs for use with kdump 2008-12-23 15:13:28 +11:00
Kconfig Merge branch 'next' of git://git.kernel.org/pub/scm/linux/kernel/git/paulus/powerpc 2008-12-28 16:54:33 -08:00
Kconfig.debug powerpc: Allow the max stack trace depth to be configured 2008-12-03 20:46:35 +11:00
Makefile powerpc: Remove unncessary SPE related compiler flag 2008-12-03 08:19:10 -06:00