]> git.karo-electronics.de Git - linux-beck.git/commitdiff
staging: unisys: Add a function to set the clientpartition
authorDon Zickus <dzickus@redhat.com>
Wed, 13 May 2015 17:22:20 +0000 (13:22 -0400)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sun, 24 May 2015 20:28:56 +0000 (13:28 -0700)
This patch is an attempt to help hide the channel info behind
accessory functions.  I was trying to keep visorchannel as private
as possible.

The only function missing that seemed to be needed for now was
the ability to set the clientpartition.  So I expose that here.

Signed-off-by: Don Zickus <dzickus@redhat.com>
Signed-off-by: Benjamin Romer <benjamin.romer@unisys.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/unisys/include/visorbus.h
drivers/staging/unisys/visorbus/visorchannel.c

index 14f6f8e9426ddabe6ba92466ab9d501352c7c20e..3375ffdc7304ab62fb91c5fdccdf0948e542e4e4 100644 (file)
@@ -210,6 +210,8 @@ ulong visorchannel_get_nbytes(struct visorchannel *channel);
 char *visorchannel_id(struct visorchannel *channel, char *s);
 char *visorchannel_zoneid(struct visorchannel *channel, char *s);
 u64 visorchannel_get_clientpartition(struct visorchannel *channel);
+int visorchannel_set_clientpartition(struct visorchannel *channel,
+                                    u64 partition_handle);
 uuid_le visorchannel_get_uuid(struct visorchannel *channel);
 char *visorchannel_uuid_id(uuid_le *guid, char *s);
 void visorchannel_debug(struct visorchannel *channel, int num_queues,
index a9c3ae160ce549b72db613f810dba6cb09c3c60d..1789f9d89c0db39569e7105acee2ebd6a326209e 100644 (file)
@@ -190,6 +190,15 @@ visorchannel_get_clientpartition(struct visorchannel *channel)
 }
 EXPORT_SYMBOL_GPL(visorchannel_get_clientpartition);
 
+int
+visorchannel_set_clientpartition(struct visorchannel *channel,
+                                u64 partition_handle)
+{
+       channel->chan_hdr.partition_handle = partition_handle;
+       return 0;
+}
+EXPORT_SYMBOL_GPL(visorchannel_set_clientpartition);
+
 uuid_le
 visorchannel_get_uuid(struct visorchannel *channel)
 {