mirror of
https://git.FreeBSD.org/src.git
synced 2024-12-17 10:26:15 +00:00
Make this file C++ safe. It defines many useful functions (inb, outb)
that people use from userland in C++ programs. I've had this in my tree for ages and just got bit by it not being in the real tree again. This is a MFC candidate.
This commit is contained in:
parent
f6958f21cd
commit
29d5de8ad0
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=75139
@ -40,6 +40,9 @@
|
||||
#ifndef _MACHINE_CPUFUNC_H_
|
||||
#define _MACHINE_CPUFUNC_H_
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
|
||||
__BEGIN_DECLS
|
||||
#define readb(va) (*(volatile u_int8_t *) (va))
|
||||
#define readw(va) (*(volatile u_int16_t *) (va))
|
||||
#define readl(va) (*(volatile u_int32_t *) (va))
|
||||
@ -544,5 +547,6 @@ u_int rcr3 __P((void));
|
||||
u_int rcr4 __P((void));
|
||||
void load_dr6 __P((u_int dr6));
|
||||
void reset_dbregs __P((void));
|
||||
__END_DECLS
|
||||
|
||||
#endif /* !_MACHINE_CPUFUNC_H_ */
|
||||
|
@ -40,6 +40,9 @@
|
||||
#ifndef _MACHINE_CPUFUNC_H_
|
||||
#define _MACHINE_CPUFUNC_H_
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
|
||||
__BEGIN_DECLS
|
||||
#define readb(va) (*(volatile u_int8_t *) (va))
|
||||
#define readw(va) (*(volatile u_int16_t *) (va))
|
||||
#define readl(va) (*(volatile u_int32_t *) (va))
|
||||
@ -544,5 +547,6 @@ u_int rcr3 __P((void));
|
||||
u_int rcr4 __P((void));
|
||||
void load_dr6 __P((u_int dr6));
|
||||
void reset_dbregs __P((void));
|
||||
__END_DECLS
|
||||
|
||||
#endif /* !_MACHINE_CPUFUNC_H_ */
|
||||
|
Loading…
Reference in New Issue
Block a user