- more 2.6.17 port work (still does not build)
[linux-flexiantxendom0-3.2.10.git] / include / linux / dump_netdev.h
1 /*
2  *  linux/drivers/net/netconsole.h
3  *
4  *  Copyright (C) 2001  Ingo Molnar <mingo@redhat.com>
5  *
6  *  This file contains the implementation of an IRQ-safe, crash-safe
7  *  kernel console implementation that outputs kernel messages to the
8  *  network.
9  *
10  * Modification history:
11  *
12  * 2001-09-17    started by Ingo Molnar.
13  */
14
15 /****************************************************************
16  *      This program is free software; you can redistribute it and/or modify
17  *      it under the terms of the GNU General Public License as published by
18  *      the Free Software Foundation; either version 2, or (at your option)
19  *      any later version.
20  *
21  *      This program is distributed in the hope that it will be useful,
22  *      but WITHOUT ANY WARRANTY; without even the implied warranty of
23  *      MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
24  *      GNU General Public License for more details.
25  *
26  *      You should have received a copy of the GNU General Public License
27  *      along with this program; if not, write to the Free Software
28  *      Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
29  *
30  ****************************************************************/
31
32 #define NETCONSOLE_VERSION 0x03
33
34 enum netdump_commands {
35         COMM_NONE = 0,
36         COMM_SEND_MEM = 1,
37         COMM_EXIT = 2,
38         COMM_REBOOT = 3,
39         COMM_HELLO = 4,
40         COMM_GET_NR_PAGES = 5,
41         COMM_GET_PAGE_SIZE = 6,
42         COMM_START_NETDUMP_ACK = 7,
43         COMM_GET_REGS = 8,
44         COMM_GET_MAGIC = 9,
45         COMM_START_WRITE_NETDUMP_ACK = 10,
46 };
47
48 typedef struct netdump_req_s {
49         u64 magic;
50         u32 nr;
51         u32 command;
52         u32 from;
53         u32 to;
54 } req_t;
55
56 enum netdump_replies {
57         REPLY_NONE = 0,
58         REPLY_ERROR = 1,
59         REPLY_LOG = 2,
60         REPLY_MEM = 3,
61         REPLY_RESERVED = 4,
62         REPLY_HELLO = 5,
63         REPLY_NR_PAGES = 6,
64         REPLY_PAGE_SIZE = 7,
65         REPLY_START_NETDUMP = 8,
66         REPLY_END_NETDUMP = 9,
67         REPLY_REGS = 10,
68         REPLY_MAGIC = 11,
69         REPLY_START_WRITE_NETDUMP = 12,
70 };
71
72 typedef struct netdump_reply_s {
73         u32 nr;
74         u32 code;
75         u32 info;
76 } reply_t;
77
78 #define HEADER_LEN (1 + sizeof(reply_t))
79
80