msrtool: Add FreeBSD support using /dev/cpuctl ioctl interface
Signed-off-by: Andriy Gapon <avg@icyb.net.ua> Acked-by: Peter Stuge <peter@stuge.se> git-svn-id: svn://svn.coreboot.org/coreboot/trunk@4965 2b7e53f0-3cfb-0310-b3e9-8179ed1497e1
This commit is contained in:
committed by
Peter Stuge
parent
7df17af13b
commit
d80e57c9c8
@@ -28,6 +28,10 @@
|
||||
#define __DARWIN__
|
||||
#include <DirectIO/darwinio.h>
|
||||
#endif
|
||||
#if defined(__FreeBSD__)
|
||||
#include <sys/ioctl.h>
|
||||
#include <sys/cpuctl.h>
|
||||
#endif
|
||||
#include <pci/pci.h>
|
||||
|
||||
#define HEXCHARS "0123456789abcdefABCDEF"
|
||||
@@ -186,6 +190,12 @@ extern int darwin_open(uint8_t cpu, enum SysModes mode);
|
||||
extern int darwin_close(uint8_t cpu);
|
||||
extern int darwin_rdmsr(uint8_t cpu, uint32_t addr, struct msr *val);
|
||||
|
||||
/* freebsd.c */
|
||||
extern int freebsd_probe(const struct sysdef *system);
|
||||
extern int freebsd_open(uint8_t cpu, enum SysModes mode);
|
||||
extern int freebsd_close(uint8_t cpu);
|
||||
extern int freebsd_rdmsr(uint8_t cpu, uint32_t addr, struct msr *val);
|
||||
|
||||
/** target externs **/
|
||||
|
||||
/* geodelx.c */
|
||||
|
Reference in New Issue
Block a user