diff options
author | Adrian Chadd <adrian@FreeBSD.org> | 2017-01-30 22:29:21 +0000 |
---|---|---|
committer | Adrian Chadd <adrian@FreeBSD.org> | 2017-01-30 22:29:21 +0000 |
commit | 4691c88fee556efee9cdd132b9bd8a8c940901d1 (patch) | |
tree | f132e866828e8757cd7e4dbfae7a5cf04c356220 /sys/modules | |
parent | 450aba5b34d82f38f995ef6ed3821466ddfda939 (diff) | |
download | src-4691c88fee556efee9cdd132b9bd8a8c940901d1.tar.gz src-4691c88fee556efee9cdd132b9bd8a8c940901d1.zip |
[mips] add some (temporary, I hope!) mips24k/mips74k hwpmc modules.
Ideally we'd have a top level hwpmc module with the shared bits, then
cpu specific glue as needed. However, on the MIPS side, there's no
probe code - {mips24k, mips74k, octeon} implement a set of methods
that hwpmc_mips.c expects.
So this populates separate modules with duplicate code.
Ew, but it does work.
This gets me off the hook - these work fine as copied into the relevant
mfsroot for mips24k/mips74k systems.
TODO:
* do it the "right" way in the future. Note that modules/hwpmc/ does
build fine on MIPS, it jusn't DO anything. So it'd be nice to
maybe call that "hwpmc_core" and then "hwpmc" can be the CPU/arch glue.
Notes
Notes:
svn path=/head/; revision=312998
Diffstat (limited to 'sys/modules')
-rw-r--r-- | sys/modules/Makefile | 7 | ||||
-rw-r--r-- | sys/modules/hwpmc_mips24k/Makefile | 14 | ||||
-rw-r--r-- | sys/modules/hwpmc_mips74k/Makefile | 14 |
3 files changed, 35 insertions, 0 deletions
diff --git a/sys/modules/Makefile b/sys/modules/Makefile index f6859228cf64..0a9fb06a323d 100644 --- a/sys/modules/Makefile +++ b/sys/modules/Makefile @@ -138,6 +138,8 @@ SUBDIR= \ ${_hptnr} \ ${_hptrr} \ hwpmc \ + ${_hwpmc_mips24k} \ + ${_hwpmc_mips74k} \ ${_hyperv} \ i2c \ ${_ibcore} \ @@ -520,6 +522,11 @@ _cxgbe= cxgbe SUBDIR+= zfs .endif +.if ${MACHINE_CPUARCH} == "mips" + _hwpmc_mips24k= hwpmc_mips24k + _hwpmc_mips74k= hwpmc_mips74k +.endif + .if ${MACHINE_CPUARCH} != "aarch64" && ${MACHINE_CPUARCH} != "arm" && \ ${MACHINE_CPUARCH} != "mips" && ${MACHINE_CPUARCH} != "powerpc" && \ ${MACHINE_CPUARCH} != "riscv" diff --git a/sys/modules/hwpmc_mips24k/Makefile b/sys/modules/hwpmc_mips24k/Makefile new file mode 100644 index 000000000000..772fa563b4cb --- /dev/null +++ b/sys/modules/hwpmc_mips24k/Makefile @@ -0,0 +1,14 @@ +# +# $FreeBSD$ +# + +.PATH: ${.CURDIR}/../../dev/hwpmc + +KMOD= hwpmc_mips24k + +SRCS= hwpmc_mod.c hwpmc_logging.c hwpmc_soft.c vnode_if.h +SRCS+= hwpmc_mips.c + +SRCS+= hwpmc_mips24k.c + +.include <bsd.kmod.mk> diff --git a/sys/modules/hwpmc_mips74k/Makefile b/sys/modules/hwpmc_mips74k/Makefile new file mode 100644 index 000000000000..204455c9cf35 --- /dev/null +++ b/sys/modules/hwpmc_mips74k/Makefile @@ -0,0 +1,14 @@ +# +# $FreeBSD$ +# + +.PATH: ${.CURDIR}/../../dev/hwpmc + +KMOD= hwpmc_mips74k + +SRCS= hwpmc_mod.c hwpmc_logging.c hwpmc_soft.c vnode_if.h +SRCS+= hwpmc_mips.c + +SRCS+= hwpmc_mips74k.c + +.include <bsd.kmod.mk> |