summaryrefslogtreecommitdiffstats
path: root/libdha
diff options
context:
space:
mode:
authornick <nick@b3059339-0415-0410-9bf9-f77b7e298cf2>2002-01-12 18:00:25 +0000
committernick <nick@b3059339-0415-0410-9bf9-f77b7e298cf2>2002-01-12 18:00:25 +0000
commitcdc6ca805cbeffaf459818c06f05e5852c4b1c1e (patch)
treea54da631936c2875585f384c2aa3667288fc2678 /libdha
parentc89764b22049311970e8c19320446a71cb8c038e (diff)
downloadmpv-cdc6ca805cbeffaf459818c06f05e5852c4b1c1e.tar.bz2
mpv-cdc6ca805cbeffaf459818c06f05e5852c4b1c1e.tar.xz
Alpha patch by Falk Hueffner <falk.hueffner@student.uni-tuebingen.de>
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@4113 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'libdha')
-rw-r--r--libdha/AsmMacros.h13
-rw-r--r--libdha/pci.c23
2 files changed, 5 insertions, 31 deletions
diff --git a/libdha/AsmMacros.h b/libdha/AsmMacros.h
index feb5ce02d1..3a1a9a5e52 100644
--- a/libdha/AsmMacros.h
+++ b/libdha/AsmMacros.h
@@ -61,18 +61,7 @@
#if defined(__GNUC__)
#if defined(linux) && (defined(__alpha__) || defined(__ia64__))
-#undef inb
-#undef inw
-#undef inl
-#undef outb
-#undef outw
-#undef outl
-#define inb _inb
-#define inw _inw
-#define inl _inl
-#define outb(p,v) _outb((v),(p))
-#define outw(p,v) _outw((v),(p))
-#define outl(p,v) _outl((v),(p))
+#include <sys/io.h>
#else
#if defined(__sparc__)
#ifndef ASI_PL
diff --git a/libdha/pci.c b/libdha/pci.c
index e1d417fa17..2daa48c36a 100644
--- a/libdha/pci.c
+++ b/libdha/pci.c
@@ -269,7 +269,11 @@ static void outl(int port, unsigned long value) {
#if defined(__GLIBC__) && __GLIBC__ >= 2
#if defined(linux)
+#ifdef __i386__
#include <sys/perm.h>
+#else
+#include <sys/io.h>
+#endif
#endif
#endif
@@ -278,25 +282,6 @@ static void outl(int port, unsigned long value) {
#include <asm/unistd.h>
#define BUS(tag) (((tag)>>16)&0xff)
#define DFN(tag) (((tag)>>8)&0xff)
-static int pciconfig_read(
- unsigned char bus,
- unsigned char dfn,
- unsigned char off,
- unsigned char len,
- void * buf)
-{
- return syscall(__NR_pciconfig_read, bus, dfn, off, len, buf);
-}
-
-static int pciconfig_write(
- unsigned char bus,
- unsigned char dfn,
- unsigned char off,
- unsigned char len,
- void * buf)
-{
- return syscall(__NR_pciconfig_write, bus, dfn, off, len, buf);
-}
#else
Generate compiler error - scanpci unsupported on non-linux alpha platforms
#endif /* linux */