From 314d225f3a60cc0ea63c292a2c2ffe3609e7c739 Mon Sep 17 00:00:00 2001 From: marha Date: Wed, 2 Dec 2009 17:33:15 +0000 Subject: Xserver git update --- xorg-server/hw/xfree86/os-support/linux/lnx_axp.c | 86 ----------------------- 1 file changed, 86 deletions(-) (limited to 'xorg-server/hw/xfree86/os-support/linux/lnx_axp.c') diff --git a/xorg-server/hw/xfree86/os-support/linux/lnx_axp.c b/xorg-server/hw/xfree86/os-support/linux/lnx_axp.c index 10b97b0d6..10fd9e865 100644 --- a/xorg-server/hw/xfree86/os-support/linux/lnx_axp.c +++ b/xorg-server/hw/xfree86/os-support/linux/lnx_axp.c @@ -4,10 +4,7 @@ #endif #include -#include -#include "os.h" #include "xf86.h" -#include "xf86Priv.h" #include "shared/xf86Axp.h" axpDevice lnxGetAXP(void); @@ -102,86 +99,3 @@ lnxGetAXP(void) count++; } while (1); } - -/* - * pciconfig_iobase wrappers and dynamic i/o selection - */ -#include "lnx.h" -#include -#include - -/* glibc versions (single hose only) */ -extern void _outb(char val, unsigned long port); -extern void _outw(short val, unsigned long port); -extern void _outl(int val, unsigned long port); -extern unsigned int _inb(unsigned long port); -extern unsigned int _inw(unsigned long port); -extern unsigned int _inl(unsigned long port); - -extern void _dense_outb(char, unsigned long); -extern void _dense_outw(short, unsigned long); -extern void _dense_outl(int, unsigned long); -extern unsigned int _dense_inb(unsigned long); -extern unsigned int _dense_inw(unsigned long); -extern unsigned int _dense_inl(unsigned long); - -_X_EXPORT void (*_alpha_outb)(char, unsigned long) = _outb; -_X_EXPORT void (*_alpha_outw)(short, unsigned long) = _outw; -_X_EXPORT void (*_alpha_outl)(int, unsigned long) = _outl; -_X_EXPORT unsigned int (*_alpha_inb)(unsigned long) = _inb; -_X_EXPORT unsigned int (*_alpha_inw)(unsigned long) = _inw; -_X_EXPORT unsigned int (*_alpha_inl)(unsigned long) = _inl; - -static long _alpha_iobase_query(unsigned, int, int, int); -long (*_iobase)(unsigned, int, int, int) = _alpha_iobase_query; - -static long -_alpha_iobase(unsigned flags, int hose, int bus, int devfn) -{ - if (bus < 0) { - bus = hose; - flags |= IOBASE_FROM_HOSE; - } - - return syscall(__NR_pciconfig_iobase, flags, bus, devfn); -} - -static long -_alpha_iobase_legacy(unsigned flags, int hose, int bus, int devfn) -{ - if (hose > 0) return -ENODEV; - if (flags & IOBASE_DENSE_MEM) return _bus_base(); - if (flags & IOBASE_SPARSE_MEM) return _bus_base_sparse(); - return 0; -} - -static long -_alpha_iobase_query(unsigned flags, int hose, int bus, int devfn) -{ - /* - * Only use iobase if the syscall is supported *and* it's - * a dense io system - */ - if (_alpha_iobase(IOBASE_DENSE_IO, 0, 0, 0) > 0) { - /* - * The syscall worked and it's a dense io system - take over the - * io subsystem - */ - _iobase = _alpha_iobase; - - /* - * Only take over the inx/outx functions if this is a dense I/O - * system *and* addressing domains are being used. The dense I/O - * routines expect I/O to be mapped (as done in xf86MapLegacyIO) - */ - _alpha_outb = _dense_outb; - _alpha_outw = _dense_outw; - _alpha_outl = _dense_outl; - _alpha_inb = _dense_inb; - _alpha_inw = _dense_inw; - _alpha_inl = _dense_inl; - } else _iobase = _alpha_iobase_legacy; - - return _iobase(flags, hose, bus, devfn); -} - -- cgit v1.2.3