Re: [PATCH xserver 4/7] xfree86: Remove Option "BiosBase"
On Tue, 2017-02-14 at 13:39 -0800, Aaron Plattner wrote: > On 02/14/2017 12:30 PM, Adam Jackson wrote: > > > > diff --git a/hw/xfree86/parser/xf86tokens.h b/hw/xfree86/parser/xf86tokens.h > > index 15792c6..4aa17a7 100644 > > --- a/hw/xfree86/parser/xf86tokens.h > > +++ b/hw/xfree86/parser/xf86tokens.h > > @@ -181,7 +181,6 @@ typedef enum { > > IOBASE, > > RAMDAC, > > DACSPEED, > > -BIOSBASE, > > I really hope no configurations are actually using this keyword, but if > they are, this will break them. Fine with me, as long as that's intentional. Mmm. AFAICT the keyword stuff here is a legacy of trying to be compatible with XFree86 3.x configs, which didn't have the Option syntax. Given there are only two drivers that would honor whatever value you'd set - both of which normally DTRT from PCI configuration - I don't imagine anyone is relying on this keyword actually taking effect. But you're right, this would turn a no-op into a parse error, that's not cool. I'll drop the keyword bits when merging this, thanks for the catch. - ajax ___ xorg-devel@lists.x.org: X.Org development Archives: http://lists.x.org/archives/xorg-devel Info: https://lists.x.org/mailman/listinfo/xorg-devel
Re: [PATCH xserver 4/7] xfree86: Remove Option "BiosBase"
On 02/14/2017 12:30 PM, Adam Jackson wrote: Just no. The ddxDesign chunk removes the whole para about xf86FixPciResource, since it turns out that function doesn't exist at all anymore. i128 and mga do use this slot, but they oughtn't. Signed-off-by: Adam Jackson --- hw/xfree86/common/xf86Config.c| 1 - hw/xfree86/common/xf86Configure.c | 1 - hw/xfree86/common/xf86str.h | 2 -- hw/xfree86/doc/ddxDesign.xml | 29 - hw/xfree86/man/xorg.conf.man | 6 -- hw/xfree86/parser/Device.c| 8 hw/xfree86/parser/xf86Parser.h| 1 - hw/xfree86/parser/xf86tokens.h| 1 - 8 files changed, 49 deletions(-) diff --git a/hw/xfree86/common/xf86Config.c b/hw/xfree86/common/xf86Config.c index f03acf3..89861e0 100644 --- a/hw/xfree86/common/xf86Config.c +++ b/hw/xfree86/common/xf86Config.c @@ -2105,7 +2105,6 @@ configDevice(GDevPtr devicep, XF86ConfDevicePtr conf_device, Bool active, Bool g devicep->driver = conf_device->dev_driver; devicep->active = active; devicep->videoRam = conf_device->dev_videoram; -devicep->BiosBase = conf_device->dev_bios_base; devicep->MemBase = conf_device->dev_mem_base; devicep->IOBase = conf_device->dev_io_base; devicep->clockchip = conf_device->dev_clockchip; diff --git a/hw/xfree86/common/xf86Configure.c b/hw/xfree86/common/xf86Configure.c index f975b98..668a551 100644 --- a/hw/xfree86/common/xf86Configure.c +++ b/hw/xfree86/common/xf86Configure.c @@ -268,7 +268,6 @@ configureDeviceSection(int screennum) for (i = 0; i < MAXDACSPEEDS; i++) ptr->dev_dacSpeeds[i] = DevToConfig[screennum].GDev.dacSpeeds[i]; ptr->dev_videoram = DevToConfig[screennum].GDev.videoRam; -ptr->dev_bios_base = DevToConfig[screennum].GDev.BiosBase; ptr->dev_mem_base = DevToConfig[screennum].GDev.MemBase; ptr->dev_io_base = DevToConfig[screennum].GDev.IOBase; ptr->dev_clockchip = DevToConfig[screennum].GDev.clockchip; diff --git a/hw/xfree86/common/xf86str.h b/hw/xfree86/common/xf86str.h index 4df10a5..b060575 100644 --- a/hw/xfree86/common/xf86str.h +++ b/hw/xfree86/common/xf86str.h @@ -303,7 +303,6 @@ typedef struct { Bool active; Bool inUse; int videoRam; -unsigned long BiosBase; /* Base address of video BIOS */ unsigned long MemBase; /* Frame buffer base address */ unsigned long IOBase; int chipID; @@ -648,7 +647,6 @@ typedef struct _ScrnInfoRec { int numClocks; /* number of clocks */ int clock[MAXCLOCKS]; /* list of clock frequencies */ int videoRam; /* amount of video ram (kb) */ -unsigned long biosBase; /* Base address of video BIOS */ unsigned long memPhysBase; /* Physical address of FB */ unsigned long fbOffset; /* Offset of FB in the above */ int memClk; /* memory clock */ diff --git a/hw/xfree86/doc/ddxDesign.xml b/hw/xfree86/doc/ddxDesign.xml index df5f64b..0a14139 100644 --- a/hw/xfree86/doc/ddxDesign.xml +++ b/hw/xfree86/doc/ddxDesign.xml @@ -1208,7 +1208,6 @@ Here is what InitOutput() does: numClocks (if not programmable) clock[] (if not programmable) videoRam - biosBase memBase memClk driverPrivate @@ -2920,34 +2919,6 @@ Two functions are provided to obtain a resource range of a given type: -Some PCI devices are broken in the sense that they return invalid size -information for a certain resource. In this case the driver can supply -the correct size and make sure that the resource range allocated for -the card is large enough to hold the address range decoded by the card. -The function xf86FixPciResource() can be used to do this: - - -Bool xf86FixPciResource(int entityIndex, unsigned int prt, -CARD32 alignment, long type); - - - This function fixes a PCI resource allocation. The - prt parameter contains the number of the PCI base - register that needs to be fixed (0-5, and - 6 for the BIOS base register). The size is - specified by the alignment. Since PCI resources need to span an - integral range of size 2ˆn, the alignm ent also - specifies the number of addresses that will be decoded. If the - driver specifies a type mask it can override the default type for - PCI resources which is ResShared. The resource - broker needs to know that to find a matching resource range. This - function should be called before calling - xf86RegisterResources(). The return value is - TRUE when the function succeeds. - - - - Bool xf86CheckPciMemBase(pciVideoPtr pPci, memType base); diff --git a/hw/xfree86/man/xorg.conf.man b/hw/xfree86/man/xorg.conf.man index 00ebf56..25af3aa 100644 --- a/hw/xfree86/man/xorg
[PATCH xserver 4/7] xfree86: Remove Option "BiosBase"
Just no. The ddxDesign chunk removes the whole para about xf86FixPciResource, since it turns out that function doesn't exist at all anymore. i128 and mga do use this slot, but they oughtn't. Signed-off-by: Adam Jackson --- hw/xfree86/common/xf86Config.c| 1 - hw/xfree86/common/xf86Configure.c | 1 - hw/xfree86/common/xf86str.h | 2 -- hw/xfree86/doc/ddxDesign.xml | 29 - hw/xfree86/man/xorg.conf.man | 6 -- hw/xfree86/parser/Device.c| 8 hw/xfree86/parser/xf86Parser.h| 1 - hw/xfree86/parser/xf86tokens.h| 1 - 8 files changed, 49 deletions(-) diff --git a/hw/xfree86/common/xf86Config.c b/hw/xfree86/common/xf86Config.c index f03acf3..89861e0 100644 --- a/hw/xfree86/common/xf86Config.c +++ b/hw/xfree86/common/xf86Config.c @@ -2105,7 +2105,6 @@ configDevice(GDevPtr devicep, XF86ConfDevicePtr conf_device, Bool active, Bool g devicep->driver = conf_device->dev_driver; devicep->active = active; devicep->videoRam = conf_device->dev_videoram; -devicep->BiosBase = conf_device->dev_bios_base; devicep->MemBase = conf_device->dev_mem_base; devicep->IOBase = conf_device->dev_io_base; devicep->clockchip = conf_device->dev_clockchip; diff --git a/hw/xfree86/common/xf86Configure.c b/hw/xfree86/common/xf86Configure.c index f975b98..668a551 100644 --- a/hw/xfree86/common/xf86Configure.c +++ b/hw/xfree86/common/xf86Configure.c @@ -268,7 +268,6 @@ configureDeviceSection(int screennum) for (i = 0; i < MAXDACSPEEDS; i++) ptr->dev_dacSpeeds[i] = DevToConfig[screennum].GDev.dacSpeeds[i]; ptr->dev_videoram = DevToConfig[screennum].GDev.videoRam; -ptr->dev_bios_base = DevToConfig[screennum].GDev.BiosBase; ptr->dev_mem_base = DevToConfig[screennum].GDev.MemBase; ptr->dev_io_base = DevToConfig[screennum].GDev.IOBase; ptr->dev_clockchip = DevToConfig[screennum].GDev.clockchip; diff --git a/hw/xfree86/common/xf86str.h b/hw/xfree86/common/xf86str.h index 4df10a5..b060575 100644 --- a/hw/xfree86/common/xf86str.h +++ b/hw/xfree86/common/xf86str.h @@ -303,7 +303,6 @@ typedef struct { Bool active; Bool inUse; int videoRam; -unsigned long BiosBase; /* Base address of video BIOS */ unsigned long MemBase; /* Frame buffer base address */ unsigned long IOBase; int chipID; @@ -648,7 +647,6 @@ typedef struct _ScrnInfoRec { int numClocks; /* number of clocks */ int clock[MAXCLOCKS]; /* list of clock frequencies */ int videoRam; /* amount of video ram (kb) */ -unsigned long biosBase; /* Base address of video BIOS */ unsigned long memPhysBase; /* Physical address of FB */ unsigned long fbOffset; /* Offset of FB in the above */ int memClk; /* memory clock */ diff --git a/hw/xfree86/doc/ddxDesign.xml b/hw/xfree86/doc/ddxDesign.xml index df5f64b..0a14139 100644 --- a/hw/xfree86/doc/ddxDesign.xml +++ b/hw/xfree86/doc/ddxDesign.xml @@ -1208,7 +1208,6 @@ Here is what InitOutput() does: numClocks (if not programmable) clock[] (if not programmable) videoRam - biosBase memBase memClk driverPrivate @@ -2920,34 +2919,6 @@ Two functions are provided to obtain a resource range of a given type: -Some PCI devices are broken in the sense that they return invalid size -information for a certain resource. In this case the driver can supply -the correct size and make sure that the resource range allocated for -the card is large enough to hold the address range decoded by the card. -The function xf86FixPciResource() can be used to do this: - - -Bool xf86FixPciResource(int entityIndex, unsigned int prt, -CARD32 alignment, long type); - - - This function fixes a PCI resource allocation. The - prt parameter contains the number of the PCI base - register that needs to be fixed (0-5, and - 6 for the BIOS base register). The size is - specified by the alignment. Since PCI resources need to span an - integral range of size 2ˆn, the alignm ent also - specifies the number of addresses that will be decoded. If the - driver specifies a type mask it can override the default type for - PCI resources which is ResShared. The resource - broker needs to know that to find a matching resource range. This - function should be called before calling - xf86RegisterResources(). The return value is - TRUE when the function succeeds. - - - - Bool xf86CheckPciMemBase(pciVideoPtr pPci, memType base); diff --git a/hw/xfree86/man/xorg.conf.man b/hw/xfree86/man/xorg.conf.man index 00ebf56..25af3aa 100644 --- a/hw/xfree86/man/xorg.conf.man +++ b/hw/xfree86/man/xorg.conf.man