]> xenbits.xensource.com Git - osstest/rumprun.git/commitdiff
Switch to new-style pci hypercall defs
authorAntti Kantee <pooka@iki.fi>
Tue, 17 May 2016 12:28:59 +0000 (12:28 +0000)
committerAntti Kantee <pooka@iki.fi>
Tue, 17 May 2016 12:28:59 +0000 (12:28 +0000)
Fixes issue #38

build-rr.sh
lib/Makefile.pcicommon [deleted file]
platform/hw/pci/Makefile [new file with mode: 0644]
platform/hw/pci/Makefile.pci [deleted file]
platform/hw/pci/Makefile.pcihyperdefs [new file with mode: 0644]
platform/xen/pci/Makefile [new file with mode: 0644]
platform/xen/pci/Makefile.pci [deleted file]
platform/xen/pci/Makefile.pcihyperdefs [new file with mode: 0644]

index 549b099f52724c6e4f5c2eda1f90f873e56ab213..30054ca3bf93f2b89547283b812d6f312eef40f6 100755 (executable)
@@ -439,9 +439,12 @@ buildpci ()
 {
 
        if eval ${PLATFORM_PCI_P}; then
-               ${RUMPMAKE} -f ${PLATFORMDIR}/pci/Makefile.pci ${STDJ} obj
-               ${RUMPMAKE} -f ${PLATFORMDIR}/pci/Makefile.pci ${STDJ} dependall
-               ${RUMPMAKE} -f ${PLATFORMDIR}/pci/Makefile.pci ${STDJ} install
+               (
+                       cd ${PLATFORMDIR}/pci
+                       ${RUMPMAKE} ${STDJ} obj
+                       ${RUMPMAKE} ${STDJ} dependall
+                       ${RUMPMAKE} ${STDJ} install
+               )
        fi
 }
 
diff --git a/lib/Makefile.pcicommon b/lib/Makefile.pcicommon
deleted file mode 100644 (file)
index 4ba0222..0000000
+++ /dev/null
@@ -1,30 +0,0 @@
-# Used via $platform/Makefile.pci
-# (i.e. not really a lib.  but can't think of a better place
-# where to stuff this file)
-
-RUMPTOP= ${TOPRUMP}
-MYDIR:=        ${.PARSEDIR}
-
-RUMPCOMP_USER_SRCS.rumpdev_pci=                ${PCI_HYPERCALLS}
-RUMPCOMP_USER_PATH.rumpdev_pci=                ${PCI_HYPERCALLS_PATH}
-RUMPCOMP_USER_CPPFLAGS.rumpdev_pci=    ${PCI_CPPFLAGS}
-RUMPCOMP_USER_CPPFLAGS.rumpdev_pci+=   -I${MYDIR}/../include
-RUMPCOMP_USER_CPPFLAGS.rumpdev_pci+=   -I${RROBJ}/include
-RUMPCOMP_USER_CPPFLAGS.rumpdev_pci+=   -I${PCI_HYPERCALLS_PATH}
-RUMPCOMP_USER_CFLAGS.rumpdev_pci=      ${BUILDRUMP_TOOL_CFLAGS}
-
-RUMPCOMP_CPPFLAGS.rumpdev_pci=         -I${PCI_HYPERCALLS_PATH}
-
-.export RUMPCOMP_USER_SRCS.rumpdev_pci
-.export RUMPCOMP_USER_PATH.rumpdev_pci
-.export RUMPCOMP_USER_CFLAGS.rumpdev_pci
-.export RUMPCOMP_USER_CPPFLAGS.rumpdev_pci
-.export RUMPCOMP_CPPFLAGS.rumpdev_pci
-
-.include "${RUMPTOP}/dev/Makefile.rumpdevcomp"
-
-.for pcidev in ${RUMPPCIDEVS}
-SUBDIR+= ${RUMPTOP}/dev/lib/lib${pcidev}
-.endfor
-
-.include <bsd.subdir.mk>
diff --git a/platform/hw/pci/Makefile b/platform/hw/pci/Makefile
new file mode 100644 (file)
index 0000000..08114d9
--- /dev/null
@@ -0,0 +1,21 @@
+RUMPTOP= ${TOPRUMP}
+
+.include "${RUMPRUN_MKCONF}"
+.include "${BUILDRUMP_TOOLFLAGS}"
+
+RUMPCOMP_MAKEFILEINC_rumpdev_pci:= ${.PARSEDIR}/Makefile.pcihyperdefs
+.export RUMPCOMP_MAKEFILEINC_rumpdev_pci
+
+RUMPRUN_OBJDIR=${RROBJ}
+RUMPRUN_TOOL_CFLAGS=${BUILDRUMP_TOOL_CFLAGS}
+
+.export RUMPRUN_OBJDIR
+.export RUMPRUN_TOOL_CFLAGS
+
+.include "${RUMPTOP}/dev/Makefile.rumpdevcomp"
+
+.for pcidev in ${RUMPPCIDEVS}
+SUBDIR+= ${RUMPTOP}/dev/lib/lib${pcidev}
+.endfor
+
+.include <bsd.subdir.mk>
diff --git a/platform/hw/pci/Makefile.pci b/platform/hw/pci/Makefile.pci
deleted file mode 100644 (file)
index 59ac4b9..0000000
+++ /dev/null
@@ -1,10 +0,0 @@
-PCIDIR:= ${.PARSEDIR}
-
-.include "${RUMPRUN_MKCONF}"
-.include "${BUILDRUMP_TOOLFLAGS}"
-
-PCI_HYPERCALLS=                rumppci.c rumpdma.c
-PCI_HYPERCALLS_PATH:=  ${PCIDIR}
-PCI_CPPFLAGS:=         -I${PCIDIR}/../include
-
-.include "${PCIDIR}/../../../lib/Makefile.pcicommon"
diff --git a/platform/hw/pci/Makefile.pcihyperdefs b/platform/hw/pci/Makefile.pcihyperdefs
new file mode 100644 (file)
index 0000000..9834e45
--- /dev/null
@@ -0,0 +1,17 @@
+# make defs for hypercalls for PCI component
+
+RUMPRUN_PCIDIR:= ${.PARSEDIR}
+.PATH: ${RUMPRUN_PCIDIR}
+
+.ifndef RUMPRUN_OBJDIR
+.error ${.PARSEDIR} invoked improperly
+.endif
+
+RUMPCOMP_USER_SRCS=    rumppci.c rumpdma.c
+RUMPCOMP_USER_CPPFLAGS+=-I${RUMPRUN_PCIDIR}
+RUMPCOMP_USER_CPPFLAGS+=-I${RUMPRUN_PCIDIR}/../include
+RUMPCOMP_USER_CPPFLAGS+=-I${RUMPRUN_PCIDIR}/../../../include
+RUMPCOMP_USER_CPPFLAGS+=-I${RUMPRUN_OBJDIR}/include
+RUMPCOMP_USER_CFLAGS+= ${RUMPRUN_TOOL_CFLAGS}
+
+CPPFLAGS+=             -I${RUMPRUN_PCIDIR}
diff --git a/platform/xen/pci/Makefile b/platform/xen/pci/Makefile
new file mode 100644 (file)
index 0000000..08114d9
--- /dev/null
@@ -0,0 +1,21 @@
+RUMPTOP= ${TOPRUMP}
+
+.include "${RUMPRUN_MKCONF}"
+.include "${BUILDRUMP_TOOLFLAGS}"
+
+RUMPCOMP_MAKEFILEINC_rumpdev_pci:= ${.PARSEDIR}/Makefile.pcihyperdefs
+.export RUMPCOMP_MAKEFILEINC_rumpdev_pci
+
+RUMPRUN_OBJDIR=${RROBJ}
+RUMPRUN_TOOL_CFLAGS=${BUILDRUMP_TOOL_CFLAGS}
+
+.export RUMPRUN_OBJDIR
+.export RUMPRUN_TOOL_CFLAGS
+
+.include "${RUMPTOP}/dev/Makefile.rumpdevcomp"
+
+.for pcidev in ${RUMPPCIDEVS}
+SUBDIR+= ${RUMPTOP}/dev/lib/lib${pcidev}
+.endfor
+
+.include <bsd.subdir.mk>
diff --git a/platform/xen/pci/Makefile.pci b/platform/xen/pci/Makefile.pci
deleted file mode 100644 (file)
index 7c0748d..0000000
+++ /dev/null
@@ -1,10 +0,0 @@
-PCIDIR:= ${.PARSEDIR}
-
-.include "${RUMPRUN_MKCONF}"
-.include "${BUILDRUMP_TOOLFLAGS}"
-
-PCI_HYPERCALLS=                rumphyper_pci.c rumphyper_dma.c
-PCI_HYPERCALLS_PATH:=  ${PCIDIR}
-PCI_CPPFLAGS:=         -I${PCIDIR}/../xen/include
-
-.include "${PCIDIR}/../../../lib/Makefile.pcicommon"
diff --git a/platform/xen/pci/Makefile.pcihyperdefs b/platform/xen/pci/Makefile.pcihyperdefs
new file mode 100644 (file)
index 0000000..dfa5a75
--- /dev/null
@@ -0,0 +1,17 @@
+# make defs for hypercalls for PCI component
+
+RUMPRUN_PCIDIR:= ${.PARSEDIR}
+.PATH: ${RUMPRUN_PCIDIR}
+
+.ifndef RUMPRUN_OBJDIR
+.error ${.PARSEDIR} invoked improperly
+.endif
+
+RUMPCOMP_USER_SRCS=    rumphyper_pci.c rumphyper_dma.c
+RUMPCOMP_USER_CPPFLAGS+=-I${RUMPRUN_PCIDIR}/../xen/include
+RUMPCOMP_USER_CPPFLAGS+=-I${RUMPRUN_PCIDIR}
+RUMPCOMP_USER_CPPFLAGS+=-I${RUMPRUN_PCIDIR}/../../../include
+RUMPCOMP_USER_CPPFLAGS+=-I${RUMPRUN_OBJDIR}/include
+RUMPCOMP_USER_CFLAGS+= ${RUMPRUN_TOOL_CFLAGS}
+
+CPPFLAGS+=             -I${RUMPRUN_PCIDIR}