diff options
Diffstat (limited to 'drivers/staging/unisys/visorchannel/visorchannel.h')
-rw-r--r-- | drivers/staging/unisys/visorchannel/visorchannel.h | 48 |
1 files changed, 10 insertions, 38 deletions
diff --git a/drivers/staging/unisys/visorchannel/visorchannel.h b/drivers/staging/unisys/visorchannel/visorchannel.h index 62d29a233fd0..ecf0d11117e9 100644 --- a/drivers/staging/unisys/visorchannel/visorchannel.h +++ b/drivers/staging/unisys/visorchannel/visorchannel.h @@ -1,6 +1,6 @@ /* visorchannel.h * - * Copyright © 2010 - 2013 UNISYS CORPORATION + * Copyright (C) 2010 - 2013 UNISYS CORPORATION * All rights reserved. * * This program is free software; you can redistribute it and/or modify @@ -18,6 +18,8 @@ #ifndef __VISORCHANNEL_H__ #define __VISORCHANNEL_H__ +#include <linux/uuid.h> + #include "commontypes.h" #include "memregion.h" #include "channel.h" @@ -38,15 +40,15 @@ typedef struct VISORCHANNEL_Tag VISORCHANNEL; * In this case, the values can simply be read from the channel header. */ VISORCHANNEL *visorchannel_create(HOSTADDRESS physaddr, - ulong channelBytes, GUID guid); + ulong channelBytes, uuid_le guid); VISORCHANNEL *visorchannel_create_overlapped(ulong channelBytes, VISORCHANNEL *parent, ulong off, - GUID guid); + uuid_le guid); VISORCHANNEL *visorchannel_create_with_lock(HOSTADDRESS physaddr, - ulong channelBytes, GUID guid); + ulong channelBytes, uuid_le guid); VISORCHANNEL *visorchannel_create_overlapped_with_lock(ulong channelBytes, VISORCHANNEL *parent, - ulong off, GUID guid); + ulong off, uuid_le guid); void visorchannel_destroy(VISORCHANNEL *channel); int visorchannel_read(VISORCHANNEL *channel, ulong offset, void *local, ulong nbytes); @@ -64,43 +66,13 @@ ulong visorchannel_get_nbytes(VISORCHANNEL *channel); char *visorchannel_id(VISORCHANNEL *channel, char *s); char *visorchannel_zoneid(VISORCHANNEL *channel, char *s); U64 visorchannel_get_clientpartition(VISORCHANNEL *channel); -GUID visorchannel_get_GUID(VISORCHANNEL *channel); +uuid_le visorchannel_get_uuid(VISORCHANNEL *channel); MEMREGION *visorchannel_get_memregion(VISORCHANNEL *channel); -char *visorchannel_GUID_id(GUID *guid, char *s); +char *visorchannel_uuid_id(uuid_le *guid, char *s); void visorchannel_debug(VISORCHANNEL *channel, int nQueues, struct seq_file *seq, U32 off); void visorchannel_dump_section(VISORCHANNEL *chan, char *s, int off, int len, struct seq_file *seq); -void *visorchannel_get_header(VISORCHANNEL *channel); - -#define VISORCHANNEL_CHANGE_SERVER_STATE(chan, chanId, newstate) \ - do { \ - U8 *p = (U8 *)visorchannel_get_header(chan); \ - if (p) { \ - ULTRA_CHANNEL_SERVER_TRANSITION(p, chanId, SrvState, \ - newstate, logCtx); \ - visorchannel_write \ - (chan, \ - offsetof(ULTRA_CHANNEL_PROTOCOL, SrvState), \ - p + \ - offsetof(ULTRA_CHANNEL_PROTOCOL, SrvState), \ - sizeof(U32)); \ - } \ - } while (0) - -#define VISORCHANNEL_CHANGE_CLIENT_STATE(chan, chanId, newstate) \ - do { \ - U8 *p = (U8 *)visorchannel_get_header(chan); \ - if (p) { \ - ULTRA_CHANNEL_CLIENT_TRANSITION(p, chanId, \ - newstate, logCtx); \ - visorchannel_write \ - (chan, \ - offsetof(ULTRA_CHANNEL_PROTOCOL, CliStateOS), \ - p + \ - offsetof(ULTRA_CHANNEL_PROTOCOL, CliStateOS), \ - sizeof(U32)); \ - } \ - } while (0) +void __iomem *visorchannel_get_header(VISORCHANNEL *channel); #endif |