staging: unisys: remove U32 type
[deliverable/linux.git] / drivers / staging / unisys / visorchannel / visorchannel.h
1 /* visorchannel.h
2 *
3 * Copyright (C) 2010 - 2013 UNISYS CORPORATION
4 * All rights reserved.
5 *
6 * This program is free software; you can redistribute it and/or modify
7 * it under the terms of the GNU General Public License as published by
8 * the Free Software Foundation; either version 2 of the License, or (at
9 * your option) any later version.
10 *
11 * This program is distributed in the hope that it will be useful, but
12 * WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE, GOOD TITLE or
14 * NON INFRINGEMENT. See the GNU General Public License for more
15 * details.
16 */
17
18 #ifndef __VISORCHANNEL_H__
19 #define __VISORCHANNEL_H__
20
21 #include <linux/uuid.h>
22
23 #include "commontypes.h"
24 #include "memregion.h"
25 #include "channel.h"
26 #ifndef HOSTADDRESS
27 #define HOSTADDRESS U64
28 #endif
29 #ifndef BOOL
30 #define BOOL int
31 #endif
32
33 /* VISORCHANNEL is an opaque structure to users.
34 * Fields are declared only in the implementation .c files.
35 */
36 typedef struct VISORCHANNEL_Tag VISORCHANNEL;
37
38 /* Note that for visorchannel_create() and visorchannel_create_overlapped(),
39 * <channelBytes> and <guid> arguments may be 0 if we are a channel CLIENT.
40 * In this case, the values can simply be read from the channel header.
41 */
42 VISORCHANNEL *visorchannel_create(HOSTADDRESS physaddr,
43 ulong channelBytes, uuid_le guid);
44 VISORCHANNEL *visorchannel_create_overlapped(ulong channelBytes,
45 VISORCHANNEL *parent, ulong off,
46 uuid_le guid);
47 VISORCHANNEL *visorchannel_create_with_lock(HOSTADDRESS physaddr,
48 ulong channelBytes, uuid_le guid);
49 VISORCHANNEL *visorchannel_create_overlapped_with_lock(ulong channelBytes,
50 VISORCHANNEL *parent,
51 ulong off, uuid_le guid);
52 void visorchannel_destroy(VISORCHANNEL *channel);
53 int visorchannel_read(VISORCHANNEL *channel, ulong offset,
54 void *local, ulong nbytes);
55 int visorchannel_write(VISORCHANNEL *channel, ulong offset,
56 void *local, ulong nbytes);
57 int visorchannel_clear(VISORCHANNEL *channel, ulong offset,
58 u8 ch, ulong nbytes);
59 BOOL visorchannel_signalremove(VISORCHANNEL *channel, u32 queue, void *msg);
60 BOOL visorchannel_signalinsert(VISORCHANNEL *channel, u32 queue, void *msg);
61 int visorchannel_signalqueue_slots_avail(VISORCHANNEL *channel, u32 queue);
62 int visorchannel_signalqueue_max_slots(VISORCHANNEL *channel, u32 queue);
63
64 HOSTADDRESS visorchannel_get_physaddr(VISORCHANNEL *channel);
65 ulong visorchannel_get_nbytes(VISORCHANNEL *channel);
66 char *visorchannel_id(VISORCHANNEL *channel, char *s);
67 char *visorchannel_zoneid(VISORCHANNEL *channel, char *s);
68 U64 visorchannel_get_clientpartition(VISORCHANNEL *channel);
69 uuid_le visorchannel_get_uuid(VISORCHANNEL *channel);
70 MEMREGION *visorchannel_get_memregion(VISORCHANNEL *channel);
71 char *visorchannel_uuid_id(uuid_le *guid, char *s);
72 void visorchannel_debug(VISORCHANNEL *channel, int nQueues,
73 struct seq_file *seq, u32 off);
74 void visorchannel_dump_section(VISORCHANNEL *chan, char *s,
75 int off, int len, struct seq_file *seq);
76 void __iomem *visorchannel_get_header(VISORCHANNEL *channel);
77
78 #endif
This page took 0.032331 seconds and 5 git commands to generate.