aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/staging
diff options
context:
space:
mode:
authorDavid Kershner <david.kershner@unisys.com>2016-09-19 17:09:26 -0400
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2016-09-20 07:26:21 -0400
commit5f2513950f1f8b9acc740720b89389b2aa24ac72 (patch)
tree8f1eb9b6b2a40856e6648f7f0921f67c38afb9e8 /drivers/staging
parent992228b2b0f2d7a1efc9cc21c21f1a3dea9c50f5 (diff)
staging: unisys: visorbus: remove controlvm_respond_chipset_init prototype
Remove the unneeded controlvm_respond_chipset_init prototype by moving the functions controlvm_init_response and controlvm_respond_chipset_init up in the file. 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.c63
1 files changed, 30 insertions, 33 deletions
diff --git a/drivers/staging/unisys/visorbus/visorchipset.c b/drivers/staging/unisys/visorbus/visorchipset.c
index 6f530ea4c59a..7dcf0b3a1017 100644
--- a/drivers/staging/unisys/visorbus/visorchipset.c
+++ b/drivers/staging/unisys/visorbus/visorchipset.c
@@ -271,9 +271,6 @@ static struct platform_device visorchipset_platform_device = {
271}; 271};
272 272
273/* Function prototypes */ 273/* Function prototypes */
274static void controlvm_respond_chipset_init(
275 struct controlvm_message_header *msg_hdr, int response,
276 enum ultra_chipset_feature features);
277static void controlvm_respond_physdev_changestate( 274static void controlvm_respond_physdev_changestate(
278 struct controlvm_message_header *msg_hdr, int response, 275 struct controlvm_message_header *msg_hdr, int response,
279 struct spar_segment_state state); 276 struct spar_segment_state state);
@@ -638,6 +635,36 @@ struct visor_device *visorbus_get_device_by_id(u32 bus_no, u32 dev_no,
638} 635}
639 636
640static void 637static void
638controlvm_init_response(struct controlvm_message *msg,
639 struct controlvm_message_header *msg_hdr, int response)
640{
641 memset(msg, 0, sizeof(struct controlvm_message));
642 memcpy(&msg->hdr, msg_hdr, sizeof(struct controlvm_message_header));
643 msg->hdr.payload_bytes = 0;
644 msg->hdr.payload_vm_offset = 0;
645 msg->hdr.payload_max_bytes = 0;
646 if (response < 0) {
647 msg->hdr.flags.failed = 1;
648 msg->hdr.completion_status = (u32)(-response);
649 }
650}
651
652static void
653controlvm_respond_chipset_init(struct controlvm_message_header *msg_hdr,
654 int response,
655 enum ultra_chipset_feature features)
656{
657 struct controlvm_message outmsg;
658
659 controlvm_init_response(&outmsg, msg_hdr, response);
660 outmsg.cmd.init_chipset.features = features;
661 if (!visorchannel_signalinsert(controlvm_channel,
662 CONTROLVM_QUEUE_REQUEST, &outmsg)) {
663 return;
664 }
665}
666
667static void
641chipset_init(struct controlvm_message *inmsg) 668chipset_init(struct controlvm_message *inmsg)
642{ 669{
643 static int chipset_inited; 670 static int chipset_inited;
@@ -672,21 +699,6 @@ out_respond:
672} 699}
673 700
674static void 701static void
675controlvm_init_response(struct controlvm_message *msg,
676 struct controlvm_message_header *msg_hdr, int response)
677{
678 memset(msg, 0, sizeof(struct controlvm_message));
679 memcpy(&msg->hdr, msg_hdr, sizeof(struct controlvm_message_header));
680 msg->hdr.payload_bytes = 0;
681 msg->hdr.payload_vm_offset = 0;
682 msg->hdr.payload_max_bytes = 0;
683 if (response < 0) {
684 msg->hdr.flags.failed = 1;
685 msg->hdr.completion_status = (u32)(-response);
686 }
687}
688
689static void
690controlvm_respond(struct controlvm_message_header *msg_hdr, int response) 702controlvm_respond(struct controlvm_message_header *msg_hdr, int response)
691{ 703{
692 struct controlvm_message outmsg; 704 struct controlvm_message outmsg;
@@ -701,21 +713,6 @@ controlvm_respond(struct controlvm_message_header *msg_hdr, int response)
701 } 713 }
702} 714}
703 715
704static void
705controlvm_respond_chipset_init(struct controlvm_message_header *msg_hdr,
706 int response,
707 enum ultra_chipset_feature features)
708{
709 struct controlvm_message outmsg;
710
711 controlvm_init_response(&outmsg, msg_hdr, response);
712 outmsg.cmd.init_chipset.features = features;
713 if (!visorchannel_signalinsert(controlvm_channel,
714 CONTROLVM_QUEUE_REQUEST, &outmsg)) {
715 return;
716 }
717}
718
719static void controlvm_respond_physdev_changestate( 716static void controlvm_respond_physdev_changestate(
720 struct controlvm_message_header *msg_hdr, int response, 717 struct controlvm_message_header *msg_hdr, int response,
721 struct spar_segment_state state) 718 struct spar_segment_state state)