![](https://seccdn.libravatar.org/avatar/af22e20b6884acbc89be6d7736c43e92.jpg?s=120&d=mm&r=g)
Hello community, here is the log from the commit of package xorg-x11 checked in at Sat Jun 3 01:02:06 CEST 2006. -------- --- xorg-x11/xorg-x11.changes 2006-05-31 18:24:45.000000000 +0200 +++ xorg-x11/xorg-x11.changes 2006-06-02 16:22:49.000000000 +0200 @@ -1,0 +2,10 @@ +Fri Jun 2 12:25:54 CEST 2006 - sndirsch@suse.de + +- pc_xf86-pci.diff: + * fixes broken BIOS reading (due to changes in recent Linux + kernels), which is required for dual card support (Bug #171453, + X.Org Bug #6751) +- removed no longer required patch + "p_xlib_skip_select_substructure_redirect.diff" again (Bug #151836) + +------------------------------------------------------------------- Old: ---- p_xlib_skip_select_substructure_redirect.diff ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ xorg-x11.spec ++++++ --- /var/tmp/diff_new_pack.T9xuj4/_old 2006-06-03 01:01:28.000000000 +0200 +++ /var/tmp/diff_new_pack.T9xuj4/_new 2006-06-03 01:01:28.000000000 +0200 @@ -40,7 +40,7 @@ %endif Autoreqprov: on Version: 6.9.0 -Release: 56 +Release: 57 Summary: The basic X Window System package Source: xorg-6.9.0.tar.bz2 Source1: xdm.tar.gz @@ -124,7 +124,6 @@ Patch365: p_xorg-fbcompose-radek2.diff Patch366: pc_xf86-pci.diff Patch367: p_xlib_skip_ext_env.diff -Patch368: p_xlib_skip_select_substructure_redirect.diff Patch400: p_bug96328.diff BuildRoot: %{_tmppath}/%{name}-%{version}-build @@ -1559,12 +1558,10 @@ %endif pushd programs/Xserver/ %patch365 -p0 -# needs to be rewritten first -#%patch366 -p0 popd +%patch366 -p0 pushd lib/X11 %patch367 -p0 -%patch368 -p0 popd # UTS_RELEASE=`uname -r` @@ -2723,6 +2720,13 @@ %clean %changelog -n xorg-x11 +* Fri Jun 02 2006 - sndirsch@suse.de +- pc_xf86-pci.diff: + * fixes broken BIOS reading (due to changes in recent Linux + kernels), which is required for dual card support (Bug #171453, + X.Org Bug #6751) +- removed no longer required patch + "p_xlib_skip_select_substructure_redirect.diff" again (Bug #151836) * Wed May 31 2006 - sndirsch@suse.de - generate /usr/X11R6/lib/X11/fonts/misc/fonts.dir on s390/s390x during %%install (Bug #178315) ++++++ FILES ++++++ --- xorg-x11/FILES 2006-05-29 14:05:34.000000000 +0200 +++ xorg-x11/FILES 2006-06-02 16:20:46.000000000 +0200 @@ -177,5 +177,3 @@ p_xlib_skip_ext_env.diff [KEEP?] - added support for disabling extensions through environment variables (Bug #167317) -p_xlib_skip_select_substructure_redirect.diff [KEEP?] -- fool java swing apps that no WM is running (Bug #151836) ++++++ pc_xf86-pci.diff ++++++ --- /var/tmp/diff_new_pack.T9xuj4/_old 2006-06-03 01:01:32.000000000 +0200 +++ /var/tmp/diff_new_pack.T9xuj4/_new 2006-06-03 01:01:32.000000000 +0200 @@ -1,57 +1,219 @@ ---- hw/xfree86/os-support/bus/Pci.c.orig 2006-05-23 11:26:01.000000000 +0200 -+++ hw/xfree86/os-support/bus/Pci.c 2006-05-23 11:37:57.000000000 +0200 +Index: programs/Xserver/hw/xfree86/os-support/bus/Pci.c +=================================================================== +RCS file: /cvs/xorg/xc/programs/Xserver/hw/xfree86/os-support/bus/Pci.c,v +retrieving revision 1.10 +diff -u -r1.10 Pci.c +--- programs/Xserver/hw/xfree86/os-support/bus/Pci.c 8 Nov 2005 19:04:56 -0000 1.10 ++++ programs/Xserver/hw/xfree86/os-support/bus/Pci.c 31 May 2006 13:33:46 -0000 @@ -233,6 +233,8 @@ static pciConfigPtr pci_devp[MAX_PCI_DEVICES + 1] = {NULL, }; -+static int (*pciOSHandleBIOS)(PCITAG Tag, int basereg, unsigned char *buf, int len); ++static int (*pciOSHandleBIOS)(PCITAG Tag, ADDRESS offset, int len, unsigned char *buf); + /* * Platform specific PCI function pointers. * -@@ -266,6 +268,11 @@ +@@ -266,6 +268,13 @@ #endif } -+void pciSetOSBIOSPtr(int (*bios_fn)(PCITAG Tag, int basereg, unsigned char * buf, int len)) ++void ++pciSetOSBIOSPtr(int (*bios_fn) ++ (PCITAG Tag, ADDRESS offset, int len, unsigned char * buf)) +{ -+ pciOSHandleBIOS = bios_fn; ++ pciOSHandleBIOS = bios_fn; +} + PCITAG pciFindFirst(CARD32 id, CARD32 mask) { -@@ -1376,6 +1383,13 @@ - PCITAG *pTag; - int i; - -+ /* fall back to the old code if the OS code fails */ -+ if (pciOSHandleBIOS) { -+ n = pciOSHandleBIOS(Tag, basereg, func, ptr); -+ if (n) -+ return n; -+ } +@@ -1113,14 +1122,13 @@ + + static int + handlePciBIOS(PCITAG Tag, int basereg, +- int (*func)(PCITAG, CARD8*, ADDRESS, pointer), ++ int (*func)(PCITAG, ADDRESS, pointer), + pointer args) + { + CARD32 romsave = 0; + int i; + romBaseSource b_reg; + ADDRESS hostbase; +- CARD8 tmp[64]; + int ret = 0; + + romsave = pciReadLong(Tag, PCI_MAP_ROM_REG); +@@ -1174,19 +1183,15 @@ + + hostbase = pciBusAddrToHostAddr(Tag, PCI_MEM, PCIGETROM(romaddr)); + +- if ((xf86ReadDomainMemory(Tag, hostbase, sizeof(tmp), tmp) != +- sizeof(tmp)) || +- (tmp[0] != 0x55) || (tmp[1] != 0xaa) || !tmp[2] ) { ++ ret = (*func)(Tag, hostbase, args); + /* Restore the base registers if they were changed. */ +- pciWriteLong(Tag, PCI_MAP_ROM_REG, romsave); +- if (savebase) pciWriteLong(Tag, PCI_MAP_REG_START + (b_reg << 2), +- (CARD32) savebase); ++ pciWriteLong(Tag, PCI_MAP_ROM_REG, romsave); ++ if (savebase) pciWriteLong(Tag, PCI_MAP_REG_START + (b_reg << 2), ++ (CARD32) savebase); + +- /* No BIOS found: try another address */ +- continue; +- } ++ /* No BIOS found: try another address */ ++ if (ret < 0) continue; + +- ret = (*func)(Tag, tmp, hostbase, args); + + /* Restore the base register if it was changed. */ + if (savebase) pciWriteLong(Tag, PCI_MAP_REG_START + (b_reg << 2), +@@ -1208,20 +1213,28 @@ + PciBiosType BiosType; + } readBios, *readBiosPtr; + ++typedef int(*ReadBIOSFunc)(PCITAG Tag, ADDRESS base, int len, unsigned char *buf); + - n = handlePciBIOS(Tag,basereg,func,ptr); - if (n) - return n; ---- hw/xfree86/os-support/bus/Pci.h.orig 2006-05-23 11:26:01.000000000 +0200 -+++ hw/xfree86/os-support/bus/Pci.h 2006-05-23 11:26:01.000000000 +0200 -@@ -431,6 +431,7 @@ + static int +-readPciBios(PCITAG Tag, CARD8* tmp, ADDRESS hostbase, pointer args) ++readPciBios(PCITAG Tag, ReadBIOSFunc func, ADDRESS base, pointer args) + { + unsigned int image_length = 0; + readBiosPtr rd = args; + int ret; ++ CARD8 tmp[64]; + ++ if ((func(Tag, base, sizeof(tmp), tmp) != ++ sizeof(tmp)) || ++ (tmp[0] != 0x55) || (tmp[1] != 0xaa) || !tmp[2] ) ++ return -1; ++ + /* We found a PCI BIOS Image. Now we look for the correct type */ + while ((tmp[0] == 0x55) && (tmp[1] == 0xAA)) { + unsigned short data_off = tmp[0x18] | (tmp[0x19] << 8); + unsigned char data[0x18]; + unsigned char type; + +- if ((xf86ReadDomainMemory(Tag, hostbase + data_off, sizeof(data), data) ++ if ((func(Tag, base + data_off, sizeof(data), data) + != sizeof(data)) || + (data[0] != 'P') || + (data[1] != 'C') || +@@ -1242,8 +1255,8 @@ + ErrorF("data image length: 0x%x, ind: 0x%x\n", + image_length, indicator); + #endif +- hostbase += i_length; +- if (xf86ReadDomainMemory(Tag, hostbase, sizeof(tmp), tmp) ++ base += i_length; ++ if (func(Tag, base, sizeof(tmp), tmp) + != sizeof(tmp)) + break; + continue; +@@ -1283,19 +1296,47 @@ + } + + /* Read BIOS */ +- ret = xf86ReadDomainMemory(Tag, hostbase + rd->Offset, rd->Len, rd->Buf); ++ ret = func(Tag, base + rd->Offset, rd->Len, rd->Buf); + } + + return ret; + } + + static int +-getPciBIOSTypes(PCITAG Tag, CARD8* tmp, ADDRESS hostbase, pointer arg) ++readPciBiosFromDomainMem(PCITAG Tag, ADDRESS hostbase, ++ pointer args) ++{ ++#ifdef PRINT_PCI ++ ErrorF("readPciBiosFromDomainMem\n"); ++#endif ++ return readPciBios(Tag, xf86ReadDomainMemory, hostbase, args); ++} ++ ++static int ++readPciBiosFromOS(PCITAG Tag, pointer args) ++{ ++#ifdef PRINT_PCI ++ ErrorF("readPciBiosFromOS\n"); ++#endif ++ if (pciOSHandleBIOS) ++ return readPciBios(Tag, pciOSHandleBIOS, 0, args); ++ else ++ return 0; ++} ++ ++static int ++getPciBIOSTypes(PCITAG Tag, ADDRESS hostbase, pointer arg) + { + int n = 0; + PciBiosType *Buf = arg; ++ CARD8 tmp[64]; ++ ++ if ((xf86ReadDomainMemory(Tag, hostbase, sizeof(tmp), tmp) != ++ sizeof(tmp)) || ++ (tmp[0] != 0x55) || (tmp[1] != 0xaa) || !tmp[2] ) ++ return -1; + +- /* We found a PCI BIOS Image. Now we collect the types type */ ++ /* We found a PCI BIOS Image. Now we collect the types type */ + do { + unsigned short data_off = tmp[0x18] | (tmp[0x19] << 8); + unsigned char data[0x16]; +@@ -1339,7 +1380,7 @@ + + static int + HandlePciBios(PCITAG Tag, int basereg, +- int (*func)(PCITAG, CARD8*, ADDRESS, pointer), ++ int (*func)(PCITAG, ADDRESS, pointer), + pointer ptr) + { + int n, num; +@@ -1393,7 +1434,10 @@ + rb.Buf = Buf; + rb.BiosType = Type; + +- return HandlePciBios(Tag, basereg, readPciBios, &rb); ++ if (pciOSHandleBIOS) ++ return readPciBiosFromOS(Tag, &rb); ++ ++ return HandlePciBios(Tag, basereg, readPciBiosFromDomainMem, &rb); + } + + int +Index: programs/Xserver/hw/xfree86/os-support/bus/Pci.h +=================================================================== +RCS file: /cvs/xorg/xc/programs/Xserver/hw/xfree86/os-support/bus/Pci.h,v +retrieving revision 1.10 +diff -u -r1.10 Pci.h +--- programs/Xserver/hw/xfree86/os-support/bus/Pci.h 8 Nov 2005 19:04:56 -0000 1.10 ++++ programs/Xserver/hw/xfree86/os-support/bus/Pci.h 31 May 2006 13:33:46 -0000 +@@ -430,7 +430,9 @@ + CARD32 pciByteSwap(CARD32); Bool pciMfDev(int, int); ADDRESS pciAddrNOOP(PCITAG tag, PciAddrType type, ADDRESS); - -+extern void pciSetOSBIOSPtr(int (*bios_fn)(PCITAG Tag, int basereg, unsigned char * buf, int len)); +- ++extern void pciSetOSBIOSPtr(int (*bios_fn) ++ (PCITAG Tag, ADDRESS offset, int len, unsigned char * buf)); ++ extern PCITAG (*pciFindFirstFP)(void); extern PCITAG (*pciFindNextFP)(void); ---- hw/xfree86/os-support/bus/linuxPci.c.orig 2006-05-23 11:26:01.000000000 +0200 -+++ hw/xfree86/os-support/bus/linuxPci.c 2006-05-23 12:01:26.000000000 +0200 +Index: programs/Xserver/hw/xfree86/os-support/bus/linuxPci.c +=================================================================== +RCS file: /cvs/xorg/xc/programs/Xserver/hw/xfree86/os-support/bus/linuxPci.c,v +retrieving revision 1.10 +diff -u -r1.10 linuxPci.c +--- programs/Xserver/hw/xfree86/os-support/bus/linuxPci.c.orig 2006-06-02 12:58:52.000000000 +0200 ++++ programs/Xserver/hw/xfree86/os-support/bus/linuxPci.c 2006-06-02 13:08:58.000000000 +0200 @@ -74,6 +74,7 @@ static void linuxPciCfgWriteByte(PCITAG tag, int off, CARD8 val); static CARD16 linuxPciCfgReadWord(PCITAG tag, int off); static void linuxPciCfgWriteWord(PCITAG tag, int off, CARD16 val); -+static int linuxPciHandleBIOS(PCITAG Tag, int basereg, unsigned char *buf, int len); ++static int linuxPciHandleBIOS(PCITAG Tag, ADDRESS offset, int len, unsigned char *buf); static Bool linuxDomainSupport(void); static pciBusFuncs_t linuxFuncs0 = { @@ -63,11 +225,12 @@ return; } -@@ -943,6 +945,47 @@ +@@ -943,6 +945,45 @@ #endif /* !INCLUDE_XF86_NO_DOMAIN */ -+int linuxPciHandleBIOS(PCITAG Tag, int basereg, unsigned char *buf, int len) ++int ++linuxPciHandleBIOS(PCITAG Tag, ADDRESS offset, int len, unsigned char *buf) +{ + unsigned int dom, bus, dev, func; + unsigned int fd; @@ -83,14 +246,11 @@ + sprintf(file, "/sys/bus/pci/devices/%04x:%02x:%02x.%1x/rom", + dom, bus, dev, func); + -+ if (stat(file, &st) == 0) -+ { -+ if ((fd = open(file, O_RDWR))) -+ basereg = 0x0; ++ if (stat(file, &st) == 0 && (fd = open(file, O_RDWR))) { + + /* enable the ROM first */ + write(fd, "1", 2); -+ lseek(fd, 0, SEEK_SET); ++ lseek(fd, offset, SEEK_SET); + do { + /* copy the ROM until we hit Len, EOF or read error */ + ret = read(fd, buf+sofar, len-sofar); ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Remember to have fun... --------------------------------------------------------------------- To unsubscribe, e-mail: opensuse-commit-unsubscribe@opensuse.org For additional commands, e-mail: opensuse-commit-help@opensuse.org
participants (1)
-
root@suse.de