greybus: svc: remove the DDB function message support
authorMatt Porter <mporter@linaro.org>
Wed, 22 Oct 2014 07:22:48 +0000 (03:22 -0400)
committerGreg Kroah-Hartman <greg@kroah.com>
Wed, 22 Oct 2014 10:29:35 +0000 (18:29 +0800)
We removed the DDB function messages from the spec as they are
not needed. Now remove it from the code.

Signed-off-by: Matt Porter <mporter@linaro.org>
Signed-off-by: Greg Kroah-Hartman <greg@kroah.com>
drivers/staging/greybus/ap.c
drivers/staging/greybus/svc_msg.h

index 1a9112a..8156df0 100644 (file)
@@ -201,19 +201,6 @@ static void svc_hotplug(struct svc_function_hotplug *hotplug,
        }
 }
 
-static void svc_ddb(struct svc_function_ddb *ddb,
-                   int payload_length, struct greybus_host_device *hd)
-{
-       /*
-        * Need to properly validate payload_length once we start
-        * to handle ddb messages, but for now, we don't, so no need to check
-        * anything.
-        */
-
-       /* What?  An AP should not get this message */
-       dev_err(hd->parent, "Got an svc DDB message???\n");
-}
-
 static void svc_power(struct svc_function_power *power,
                      int payload_length, struct greybus_host_device *hd)
 {
@@ -315,9 +302,6 @@ static void ap_process_event(struct work_struct *work)
        case SVC_FUNCTION_HOTPLUG:
                svc_hotplug(&svc_msg->hotplug, payload_length, hd);
                break;
-       case SVC_FUNCTION_DDB:
-               svc_ddb(&svc_msg->ddb, payload_length, hd);
-               break;
        case SVC_FUNCTION_POWER:
                svc_power(&svc_msg->power, payload_length, hd);
                break;
index 661cbae..d76b621 100644 (file)
@@ -18,10 +18,9 @@ enum svc_function_id {
        SVC_FUNCTION_HANDSHAKE                  = 0x00,
        SVC_FUNCTION_UNIPRO_NETWORK_MANAGEMENT  = 0x01,
        SVC_FUNCTION_HOTPLUG                    = 0x02,
-       SVC_FUNCTION_DDB                        = 0x03,
-       SVC_FUNCTION_POWER                      = 0x04,
-       SVC_FUNCTION_EPM                        = 0x05,
-       SVC_FUNCTION_SUSPEND                    = 0x06,
+       SVC_FUNCTION_POWER                      = 0x03,
+       SVC_FUNCTION_EPM                        = 0x04,
+       SVC_FUNCTION_SUSPEND                    = 0x05,
 };
 
 enum svc_msg_type {
@@ -92,37 +91,6 @@ struct svc_function_hotplug {
        __u8    data[0];
 };
 
-enum svc_function_ddb_type {
-       SVC_DDB_GET             = 0x00,
-       SVC_DDB_RESPONSE        = 0x01,
-};
-
-/* XXX
- * Will only the first interface block in a module be responsible
- * for this?  If a module has two interface blocks, will both supply
- * the same information, or will it be partitioned?  For now assume
- * it's a per-module thing.
- */
-struct svc_function_ddb_get {
-       __u8    module_id;
-       __u8    message_id;
-};
-
-struct svc_function_ddb_response {
-       __u8    module_id;
-       __u8    message_id;
-       __le16  descriptor_length;
-       __u8    ddb[0];
-};
-
-struct svc_function_ddb {
-       __u8    ddb_type;       /* enum svc_function_ddb_type */
-       union {
-               struct svc_function_ddb_get             ddb_get;
-               struct svc_function_ddb_response        ddb_response;
-       };
-};
-
 enum svc_function_power_type {
        SVC_POWER_BATTERY_STATUS                = 0x00,
        SVC_POWER_BATTERY_STATUS_REQUEST        = 0x01,
@@ -187,7 +155,6 @@ struct svc_msg {
                struct svc_function_handshake           handshake;
                struct svc_function_unipro_management   management;
                struct svc_function_hotplug             hotplug;
-               struct svc_function_ddb                 ddb;
                struct svc_function_power               power;
                struct svc_function_epm                 epm;
                struct svc_function_suspend             suspend;