aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/staging
diff options
context:
space:
mode:
authorDavid Kershner <david.kershner@unisys.com>2016-09-19 17:09:23 -0400
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2016-09-20 07:26:20 -0400
commit8a2853279b3316558d4a5a34b06b6890ebc65613 (patch)
treed06b62b278bf083d2560b9a200ecfc9c8fa05f61 /drivers/staging
parent511474a5077b088f92166a7875af5e6fa428e465 (diff)
staging: unisys: visorbus: move read_controlvm_event
The function read_controlvm_event needs to be moved lower in the file to avoid extraneous function prototypes. Reported-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Signed-off-by: David Kershner <david.kershner@unisys.com> Reviewed-by: Tim Sell <Timothy.Sell@unisys.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging')
-rw-r--r--drivers/staging/unisys/visorbus/visorchipset.c42
1 files changed, 21 insertions, 21 deletions
diff --git a/drivers/staging/unisys/visorbus/visorchipset.c b/drivers/staging/unisys/visorbus/visorchipset.c
index 168d42fca939..d8e58266c4f9 100644
--- a/drivers/staging/unisys/visorbus/visorchipset.c
+++ b/drivers/staging/unisys/visorbus/visorchipset.c
@@ -1357,27 +1357,6 @@ chipset_notready(struct controlvm_message_header *msg_hdr)
1357 controlvm_respond(msg_hdr, rc); 1357 controlvm_respond(msg_hdr, rc);
1358} 1358}
1359 1359
1360/**
1361 * read_controlvm_event() - retreives the next message from the
1362 * CONTROLVM_QUEUE_EVENT queue in the controlvm
1363 * channel
1364 * @msg: pointer to the retrieved message
1365 *
1366 * Return: true if a valid message was retrieved or false otherwise
1367 */
1368static bool
1369read_controlvm_event(struct controlvm_message *msg)
1370{
1371 if (visorchannel_signalremove(controlvm_channel,
1372 CONTROLVM_QUEUE_EVENT, msg)) {
1373 /* got a message */
1374 if (msg->hdr.flags.test_message == 1)
1375 return false;
1376 return true;
1377 }
1378 return false;
1379}
1380
1381/* 1360/*
1382 * The general parahotplug flow works as follows. The visorchipset 1361 * The general parahotplug flow works as follows. The visorchipset
1383 * driver receives a DEVICE_CHANGESTATE message from Command 1362 * driver receives a DEVICE_CHANGESTATE message from Command
@@ -2091,6 +2070,27 @@ handle_command(struct controlvm_message inmsg, u64 channel_addr)
2091 return true; 2070 return true;
2092} 2071}
2093 2072
2073/**
2074 * read_controlvm_event() - retreives the next message from the
2075 * CONTROLVM_QUEUE_EVENT queue in the controlvm
2076 * channel
2077 * @msg: pointer to the retrieved message
2078 *
2079 * Return: true if a valid message was retrieved or false otherwise
2080 */
2081static bool
2082read_controlvm_event(struct controlvm_message *msg)
2083{
2084 if (visorchannel_signalremove(controlvm_channel,
2085 CONTROLVM_QUEUE_EVENT, msg)) {
2086 /* got a message */
2087 if (msg->hdr.flags.test_message == 1)
2088 return false;
2089 return true;
2090 }
2091 return false;
2092}
2093
2094static void 2094static void
2095controlvm_periodic_work(struct work_struct *work) 2095controlvm_periodic_work(struct work_struct *work)
2096{ 2096{