kdb.h revision 131903
1169691Skan/*
2169691Skan * Copyright (c) 2004 Marcel Moolenaar
3169691Skan * All rights reserved.
4169691Skan *
5169691Skan * Redistribution and use in source and binary forms, with or without
6169691Skan * modification, are permitted provided that the following conditions
7169691Skan * are met:
8169691Skan *
9169691Skan * 1. Redistributions of source code must retain the above copyright
10169691Skan *    notice, this list of conditions and the following disclaimer.
11169691Skan * 2. Redistributions in binary form must reproduce the above copyright
12169691Skan *    notice, this list of conditions and the following disclaimer in the
13169691Skan *    documentation and/or other materials provided with the distribution.
14169691Skan *
15169691Skan * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
16169691Skan * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
17169691Skan * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
18169691Skan * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
19169691Skan * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
20169691Skan * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
21169691Skan * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
22169691Skan * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
23169691Skan * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
24169691Skan * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
25169691Skan *
26169691Skan * $FreeBSD: head/sys/i386/include/kdb.h 131903 2004-07-10 18:40:12Z marcel $
27169691Skan */
28169691Skan
29169691Skan#ifndef _MACHINE_KDB_H_
30169691Skan#define _MACHINE_KDB_H_
31169691Skan
32169691Skan#include <machine/frame.h>
33169691Skan#include <machine/psl.h>
34169691Skan
35169691Skanstatic __inline void
36169691Skankdb_cpu_clear_singlestep(void)
37169691Skan{
38169691Skan	kdb_frame->tf_eflags &= ~PSL_T;
39169691Skan}
40169691Skan
41169691Skanstatic __inline void
42169691Skankdb_cpu_set_singlestep(void)
43169691Skan{
44169691Skan	kdb_frame->tf_eflags |= PSL_T;
45169691Skan}
46169691Skan
47169691Skanstatic __inline void
48169691Skankdb_cpu_trap(int type, int code)
49169691Skan{
50169691Skan}
51169691Skan
52169691Skan#endif /* _MACHINE_KDB_H_ */
53169691Skan