Commit Graph

57 Commits

Author SHA1 Message Date
Tiago Vignatti
444723273a xfree86: reorganize pci code
- xf86PciVideoInfo doesn't need to be global
- remove unused macros

Signed-off-by: Tiago Vignatti <tiago.vignatti@nokia.com>
2009-08-05 22:48:02 +03:00
Tiago Vignatti
20169414e1 xfree86: remove unused functions
RAC trash.

Signed-off-by: Tiago Vignatti <tiago.vignatti@nokia.com>
2009-08-05 22:44:19 +03:00
Dave Airlie
4b42448a23 xserver: remove RAC/resource handling code.
This changes the ABI, but since the video ABI is at 6 already
it should be fine.

driver changes are in the pipeline after this.

Signed-off-by: Dave Airlie <airlied@redhat.com>
2009-07-28 15:14:28 +10:00
Dave Airlie
0a168401c4 pci: add support for pci is boot vga call.
This allows us to ask the kernel for the boot VGA device
instead of nasty guessing.
2009-07-28 14:19:24 +10:00
Matthias Hopf
43ee8d2ead Unclaim PCI slot if driver probing fails.
Otherwise no subsequent driver will be able to claim this pci slot.
Example for this: fbdev tries to claim, but framebuffer device is not
available. Later on VESA cannot claim the device.
2009-07-06 18:38:26 +02:00
Adam Jackson
eb35402d0a pci: Dump vendor/devices ids in the printed device list 2009-06-19 12:42:07 -04:00
Adam Jackson
a9d7d659a0 PCI: Remove pciBusAddrToHostAddr and associated nonsense
This was all a glorified no-op.  We rely on pciaccess to create device
maps anyway, so we should have no reason to care about what the host
address is.

Acked-by: Ian Romanick <ian.d.romanick at intel.com>
Signed-off-by: Adam Jackson <ajax@redhat.com>
2009-02-16 16:46:39 -05:00
Paulo Cesar Pereira de Andrade
49f77fff14 Rework symbol visibility for easier maintenance
Save in a few special cases, _X_EXPORT should not be used in C source
files. Instead, it should be used in headers, and the proper C source
include that header. Some special cases are symbols that need to be
shared between modules, but not expected to be used by external drivers,
and symbols that are accessible via LoaderSymbol/dlopen.

  This patch also adds conditionally some new sdk header files, depending
on extensions enabled. These files were added to match pattern for
other extensions/modules, that is, have the headers "deciding" symbol
visibility in the sdk. These headers are:
o Xext/panoramiXsrv.h, Xext/panoramiX.h
o fbpict.h (unconditionally)
o vidmodeproc.h
o mioverlay.h (unconditionally, used only by xaa)
o xfixes.h (unconditionally, symbols required by dri2)

  LoaderSymbol and similar functions now don't have different prototypes,
in loaderProcs.h and xf86Module.h, so that both headers can be included,
without the need of defining IN_LOADER.

  xf86NewInputDevice() device prototype readded to xf86Xinput.h, but
not exported (and with a comment about it).
2008-12-03 05:43:34 -02:00
Paulo Cesar Pereira de Andrade
16b11cd03d Correct static symbol XkmReadTOC and first pass on compile warning fixes.
The warnings corrected were only the ones that should correct
real problems. The most common one is 64 bit integers as
"printf %l" arguments.
  Note that there is a patch related to this at:
http://bugs.freedesktop.org/show_bug.cgi?id=18204
2008-11-30 02:59:34 -02:00
Paulo Cesar Pereira de Andrade
d6cbd4511e Export symbols defined in the sdk.
This is the biggest "visibility" patch. Instead of doing a "export"
symbol on demand, export everything in the sdk, so that if some module
fails due to an unresolved symbol, it is because it is using a symbol
not in the sdk.

  Most exported symbols shouldn't really be made visible, neither
advertised in the sdk, as they are only used by a single shared object.

  Symbols in the sdk (or referenced in sdk macros), but not defined
anywhere include:
XkbBuildCoreState()
XkbInitialMap
XkbXIUnsupported
XkbCheckActionVMods()
XkbSendCompatNotify()
XkbDDXFakePointerButton()
XkbDDXApplyConfig()
_XkbStrCaseCmp()
_XkbErrMessages[]
_XkbErrCode
_XkbErrLocation
_XkbErrData
XkbAccessXDetailText()
XkbNKNDetailMaskText()
XkbLookupGroupAndLevel()
XkbInitAtoms()
XkbGetOrderedDrawables()
XkbFreeOrderedDrawables()
XkbConvertXkbComponents()
XkbWriteXKBSemantics()
XkbWriteXKBLayout()
XkbWriteXKBKeymap()
XkbWriteXKBFile()
XkbWriteCFile()
XkbWriteXKMFile()
XkbWriteToServer()
XkbMergeFile()
XkmFindTOCEntry()
XkmReadFileSection()
XkmReadFileSectionName()
InitExtInput()
xf86CheckButton()
xf86SwitchCoreDevice()
RamDacSetGamma()
RamDacRestoreDACValues()
xf86Bpp
xf86ConfigPix24
xf86MouseCflags[]
xf86SupportedMouseTypes[]
xf86NumMouseTypes
xf86ChangeBusIndex()
xf86EntityEnter()
xf86EntityLeave()
xf86WrapperInit()
xf86RingBell()
xf86findOptionBoolean()
xf86debugListOptions()
LoadSubModuleLocal()
LoaderSymbolLocal()
getInt10Rec()
xf86CurrentScreen
xf86ReallocatePciResources()
xf86NewSerialNumber()
xf86RandRSetInitialMode()
fbCompositeSolidMask_nx1xn
fbCompositeSolidMask_nx8888x0565C
fbCompositeSolidMask_nx8888x8888C
fbCompositeSolidMask_nx8x0565
fbCompositeSolidMask_nx8x0888
fbCompositeSolidMask_nx8x8888
fbCompositeSrc_0565x0565
fbCompositeSrc_8888x0565
fbCompositeSrc_8888x0888
fbCompositeSrc_8888x8888
fbCompositeSrcAdd_1000x1000
fbCompositeSrcAdd_8000x8000
fbCompositeSrcAdd_8888x8888
fbGeneration
fbIn
fbOver
fbOver24
fbOverlayGeneration
fbRasterizeEdges
fbRestoreAreas
fbSaveAreas
composeFunctions
VBEBuildVbeModeList()
VBECalcVbeModeIndex()
TIramdac3030CalculateMNPForClock()
shadowBufPtr
shadowFindBuf()
miRRGetScreenInfo()
RRSetScreenConfig()
RRModePruneUnused()
PixmanImageFromPicture()
extern int miPointerGetMotionEvents()
miClipPicture()
miRasterizeTriangle()
fbPush1toN()
fbInitializeBackingStore()
ddxBeforeReset()
SetupSprite()
InitSprite()
DGADeliverEvent()

  SPECIAL CASES
o defined as _X_INTERNAL
	xf86NewInputDevice()
o defined as static
	fbGCPrivateKey
	fbOverlayScreenPrivateKey
	fbScreenPrivateKey
	fbWinPrivateKey
o defined in libXfont.so, but declared in xorg/dixfont.h
	GetGlyphs()
	QueryGlyphExtents()
	QueryTextExtents()
	ParseGlyphCachingMode()
	InitGlyphCaching()
	SetGlyphCachingMode()
2008-11-29 23:56:06 -02:00
Adam Jackson
df14682a31 Bus: Remove ISA support.
No, really.  PCI is old enough to drive now.  If you want this, get the kernel
to expose a framebuffer device.
2008-11-24 23:40:06 -05:00
Tiago Vignatti
f19f7b8e53 Clean some garbage caused when pciaccess was merged:
FindPCIVideoInfo() function isn't need anymore.

    xf86scanpci() is being called only once so we don't need permanent
    (static) variables there.

    restorePciState() is not used for now (until we find why multiple
    cards aren't working).
2008-02-25 17:07:07 -03:00
Ian Romanick
ab7a6d860d Merge branch 'master' of git+ssh://git.freedesktop.org/git/xorg/xserver into pci-rework
Conflicts:

	hw/xfree86/os-support/bus/Pci.c
	hw/xfree86/os-support/bus/linuxPci.c
2007-06-18 16:51:13 -07:00
Ian Romanick
637b19b3ee Eliminate pciControlBridge, pciGetBridgeBuses, and pciGetBridgeResources. 2007-01-22 09:58:33 -08:00
Ian Romanick
88f248e671 Replace PciBusId with 'struct pci_device *'
There's no need to store the slot information for a PCI device as its
ID.  Instead, skip the middle man and just store a pointer to the
pci_device structure.
2007-01-17 14:04:43 -08:00
Ian Romanick
c1808f1484 Convert xf86IsolateDevice to a 'struct pci_slot_match'. 2007-01-17 13:02:27 -08:00
Ian Romanick
28976bebec Eliminate unused fields in pciAccRec. 2007-01-17 12:15:09 -08:00
Ian Romanick
31bd8d1507 Fix domain insanity.
Eliminate xf86GetPciDomain.  The domain from libpciaccess is the
domain.  Period.  This means that 0 is a valid domain.  Make sure that
INCLUDE_XF86_NO_DOMAIN is *not* set.  Always run in "domain mode,"
even if the only domain possible is 0.
2007-01-15 15:19:30 -08:00
Ian Romanick
d8bd0c41de Convert to new pci_device_cfg_write_u* interface. 2007-01-15 11:38:22 -08:00
Ian Romanick
3936caa005 Refactor pciTagConvertRange2Host and pciConvertRange2Host. 2007-01-12 10:59:35 -08:00
Ian Romanick
60c5e023e8 Eliminate some dead code. 2007-01-12 10:24:03 -08:00
Ian Romanick
dd12a94885 Eliminate xf86GetPciEntity from public interface.
xf86GetPciEntity was folded into the only place (xf86CheckPciSlot) in
the tree that still called it.
2007-01-12 10:21:25 -08:00
Matthias Hopf
16c5043fc0 Fix 2 warnings. 2006-11-03 18:59:51 +01:00
Ian Romanick
190f229ed7 Make xf86PciVideoInfo static since it is only used within this file.
Dummy out all of the PCI bus and device access control functions.  We
need a better way to do this, and that will probably be in
libpciaccess and / or the kernel.

Refactor xf86GetPciInfoForEntity to use pci_device_find_by_slot.

Refector xf86CheckPciSlot to use xf86GetPciEntity.

Eliminate disablePciBios and the one place that calls it.
2006-08-08 16:47:32 -07:00
Ian Romanick
a0f2e1cae4 Move xf86FindPciDeviceVendor and xf86FindPciClass from xf86pciBus.c to
xf86int10.c.  Refactor common code from those functions to do_find.
2006-08-02 10:54:41 -07:00
Ian Romanick
de8234606f Modify xf86FindPciDeviceVendor and xf86FindPciClass to use the
pci_interator interface instead of the xf86PciVideoInfo array.
2006-08-02 10:44:11 -07:00
Ian Romanick
23f44df900 Remove pciConfigPtr and all of the associated cruft. 2006-08-02 09:55:32 -07:00
Ian Romanick
ef1aecaaf6 Pass correct pointer to xf86MapLegacyIO. 2006-07-26 13:25:13 -07:00
Ian Romanick
28ba8d5691 Gut anything having to do with the PciBusPtr (or PciBusRec) type.
Bump required version of libpciaccess to 0.5.0 so that
pci_device_get_bridge_buses can be used.
2006-07-25 15:38:09 -07:00
Ian Romanick
380b51d605 Merge branch 'master' of git+ssh://git.freedesktop.org/git/xorg/xserver into pci-rework
Conflicts:

	hw/xfree86/common/xf86Init.c
	hw/xfree86/int10/pci.c
	hw/xfree86/scanpci/xf86PciData.h
	hw/xfree86/scanpci/xf86PciStdIds.h
	hw/xfree86/scanpci/xf86PciStr.h
	hw/xfree86/scanpci/xf86ScanPci.h
	hw/xfree86/utils/pcitweak/pcitweak.c
	hw/xfree86/utils/scanpci/scanpci.c

Re-removed most of the conflicting files.
2006-07-25 11:30:04 -07:00
Ian Romanick
82f6b7e75e Don't re-look-up pointers that are already stored in structures. 2006-07-24 13:52:58 -07:00
Ian Romanick
2fd6b995ff Global s/xf86MapDomainIO/xf86MapLegacyIO/. Let's call a duck a duck,
okay?  Since xf86MapLegacyIO is called from only one place, cut the
parameter list down to the one parameter that actually conveys some
information:  the one that gives a PCI device.  Change from using a
PCITAG to a pci_device.
2006-07-24 13:33:34 -07:00
Adam Jackson
0aaac95b0d Remove RCS tags. Fix Xprint makefile braindamage. 2006-07-21 17:56:00 -04:00
Daniel Stone
84683f19b4 get rid of XFree86LOADER, XFree86Server, XFree86Module, and IN_MODULE
Get rid of almost all uses of these definitions.  They're still defined for
delinquent out-of-tree drivers, and also for the Mesa build.  As well as
for miinitext.c.  But largely gone.
2006-07-18 18:17:38 -04:00
Ian Romanick
a3c26d01a1 Move declaration of "j" inside #ifdef block where it is used to
eliminate compiler warning.
2006-06-21 14:38:07 -07:00
Ian Romanick
46f55f5dea Initial batch of changes for PCI rework. All future changes will be
tracked individually.
2006-06-07 14:09:02 -07:00
Adam Jackson
deebf6bd51 Bug #4139: Fix a BAR remapping bug that could lead to IERR and system hang.
(Egbert Eich)
2006-05-18 23:52:51 +00:00
Dave Airlie
c339b221d3 Bug #6750: This patch detects Intel bridges that are transparent but aren't
reported as such. From the Linux kernel fixups. This patch also removes
    the reserved BIOS area from the area to allocate resources in.
2006-04-26 11:31:07 +00:00
Adam Jackson
a68c11bb1d Mark everything in xf86sym.c as _X_EXPORT. 2006-03-25 19:52:05 +00:00
Ian Romanick
2e6f801fe1 Numerous amounts refactoring and comment adding (see ChangeLog for file by
file details). The primary intention for these changes is to pave the
    way for the new device probing and PCI configuration code that I'm
    working on.
2006-03-07 23:58:22 +00:00
Ian Romanick
5fd0f94006 Eliminate all the code for querying the PCI class from the PCI ID database.
Class information is not, and never has been, stored there. Therefore,
    this is just a bunch of elaborate code to read 0x00000000.
This has received testing on x86 and x86-64 Linux.
2006-02-20 23:45:50 +00:00
Adam Jackson
7586ac6ede Bug #2216: Multiseat support. From various Debian and Ubuntu patches by
Aivils Stoss, Andreas Schuldei, Branden Robinson, and Daniel Stone.
2005-07-04 18:41:04 +00:00
Daniel Stone
0bb669638f Change <X11/misc.h> and <X11/os.h> to "misc.h" and "os.h". 2005-07-03 08:53:54 +00:00
Daniel Stone
e03198972c Add Xtrans definitions (FONT_t, TRANS_CLIENT) to clean up warnings.
Add XSERV_t, TRANS_SERVER, TRANS_REOPEN to quash warnings.
Add #include <dix-config.h> or <xorg-config.h>, as appropriate, to all
    source files in the xserver/xorg tree, predicated on defines of
    HAVE_{DIX,XORG}_CONFIG_H. Change all Xfont includes to
    <X11/fonts/foo.h>.
2005-07-03 07:02:09 +00:00
Daniel Stone
9b1debcdb6 Change all misc.h and os.h references to <X11/foo.h>. 2005-07-01 22:43:43 +00:00
Adam Jackson
16c2499b8f Bug #2373: SGI Altix platform support. (Shrijeet Mukherjee, Jesse Barnes,
Bjorn Helgaas, Egbert Eich.)
2005-04-22 16:49:22 +00:00
Daniel Stone
292c4cff26 Fix includes right throughout the Xserver tree:
change "foo.h" to <X11/foo.h> for core headers, e.g. X.h, Xpoll.h;
change "foo.h", "extensions/foo.h" and "X11/foo.h" to
    <X11/extensions/foo.h> for extension headers, e.g. Xv.h;
change "foo.[ch]" to <X11/Xtrans/foo.[ch]> for Xtrans files.
2005-04-20 12:25:48 +00:00
Egbert Eich
e7369daba5 Added PCI2Host bus translations for linux PPC and fixed fixed bugs in
macros that apply these functions (Bill Randle Bugzilla #325 and #327).
2005-02-09 11:12:54 +00:00
Egbert Eich
59c7005bb1 When we tested if a PCI base address was unassigned we didn't take into
account that this bar could have been the upper part of a 64bit base
    address. This fix makes this code 64bit bar aware (Bugzilla #2382).
2005-01-26 15:50:17 +00:00
Egbert Eich
13b5a93b70 Fix interpretation of 64bit PCI bases: read hi long word from the right bar
(Michael Yaroslavtsev, Bugzilla #2322).
2005-01-25 10:08:18 +00:00