summaryrefslogtreecommitdiff
path: root/hwaccess.c
diff options
context:
space:
mode:
authorruik <ruik@2b7e53f0-3cfb-0310-b3e9-8179ed1497e1>2010-04-25 22:47:50 +0000
committerruik <ruik@2b7e53f0-3cfb-0310-b3e9-8179ed1497e1>2010-04-25 22:47:50 +0000
commit6cf27267fce651ed67c2300239386882a0daf769 (patch)
tree3984257535f8147f22220157a0952834f6760e35 /hwaccess.c
parent0db07a3871f847216ac56fd7287306a4cc6b4bdd (diff)
downloadflashrom-6cf27267fce651ed67c2300239386882a0daf769.tar.gz
Fix the DOS port. Now the DS selector limit is set to 4GB and all mmio accesses goes through DS,
the 1:1 mapping is fixed so the _DS base is taken onto account. Plus is that the hwaccess.c needs no change and memcpy etc can be used on mmaped space. Signed-off-by: Rudolf Marek <r.marek@assembler.cz> Acked-by: Carl-Daniel Hailfinger <c-d.hailfinger.devel.2006@gmx.net> git-svn-id: https://code.coreboot.org/svn/flashrom/trunk@995 2b7e53f0-3cfb-0310-b3e9-8179ed1497e1
Diffstat (limited to 'hwaccess.c')
-rw-r--r--hwaccess.c39
1 files changed, 0 insertions, 39 deletions
diff --git a/hwaccess.c b/hwaccess.c
index 10e67bd..36ea6f4 100644
--- a/hwaccess.c
+++ b/hwaccess.c
@@ -54,44 +54,6 @@ void release_io_perms(void)
#endif
}
-#ifdef __DJGPP__
-
-extern unsigned short segFS;
-
-#include <sys/farptr.h>
-
-void mmio_writeb(uint8_t val, void *addr)
-{
- _farpokeb(segFS, (unsigned long) addr, val);
-}
-
-void mmio_writew(uint16_t val, void *addr)
-{
- _farpokew(segFS, (unsigned long) addr, val);
-}
-
-void mmio_writel(uint32_t val, void *addr)
-{
- _farpokel(segFS, (unsigned long) addr, val);
-}
-
-uint8_t mmio_readb(void *addr)
-{
- return _farpeekb(segFS, (unsigned long) addr);
-}
-
-uint16_t mmio_readw(void *addr)
-{
- return _farpeekw(segFS, (unsigned long) addr);
-}
-
-uint32_t mmio_readl(void *addr)
-{
- return _farpeekl(segFS, (unsigned long) addr);
-}
-
-#else
-
void mmio_writeb(uint8_t val, void *addr)
{
*(volatile uint8_t *) addr = val;
@@ -121,4 +83,3 @@ uint32_t mmio_readl(void *addr)
{
return *(volatile uint32_t *) addr;
}
-#endif