]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
staging: unisys: fix up ULTRA_CHANNEL_CLIENT_TRANSITION macro
authorBenjamin Romer <benjamin.romer@unisys.com>
Thu, 23 Oct 2014 18:30:00 +0000 (14:30 -0400)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 27 Oct 2014 02:33:09 +0000 (10:33 +0800)
Rename the macro to SPAR_CHANNEL_CLIENT_TRANSITION, and fix CamelCase
parameters:

pChan => ch
chanId => id
logCtx => log

Update all places the macro was used to call the new name.

Signed-off-by: Benjamin Romer <benjamin.romer@unisys.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/unisys/common-spar/include/channels/channel.h
drivers/staging/unisys/virthba/virthba.c
drivers/staging/unisys/virtpci/virtpci.c

index c68d36cf5d48a211cef12c8782910ae4e0791bc2..0f575e861d16dbfa67db119e35d9f542f4a2e0be 100644 (file)
@@ -128,26 +128,24 @@ ULTRA_CHANNELCLI_STRING(u32 v)
                                line);                          \
        } while (0)
 
-#define ULTRA_CHANNEL_CLIENT_TRANSITION(pChan, chanId,                 \
-                                       newstate, logCtx)               \
+#define SPAR_CHANNEL_CLIENT_TRANSITION(ch, id, newstate, log)          \
        do {                                                            \
                SPAR_CHANNEL_CLIENT_CHK_TRANSITION(                     \
-                       readl(&(((struct channel_header __iomem *) \
-                                (pChan))->cli_state_os)),              \
-                       newstate,                                       \
-                       chanId, logCtx, __FILE__, __LINE__);            \
+                       readl(&(((struct channel_header __iomem *)\
+                                (ch))->cli_state_os)),         \
+                       newstate, id, log, __FILE__, __LINE__);         \
                        pr_info("%s Channel StateTransition (%s) %s(%d)-->%s(%d) @%s:%d\n", \
-                               chanId, "CliStateOS",                   \
+                               id, "CliStateOS",                       \
                                ULTRA_CHANNELCLI_STRING( \
                                      readl(&((struct channel_header __iomem *)\
-                                             (pChan))->cli_state_os)), \
-                               readl(&((struct channel_header __iomem *) \
-                                     (pChan))->cli_state_os),          \
+                                             (ch))->cli_state_os)),    \
+                               readl(&((struct channel_header __iomem *)\
+                                     (ch))->cli_state_os),             \
                                ULTRA_CHANNELCLI_STRING(newstate),      \
                                newstate,                               \
                                pathname_last_n_nodes(__FILE__, 4), __LINE__); \
-               writel(newstate, &((struct channel_header __iomem *) \
-                                  (pChan))->cli_state_os);             \
+               writel(newstate, &((struct channel_header __iomem *)\
+                                  (ch))->cli_state_os);                \
                mb(); /* required for channel synch */                  \
        } while (0)
 
index 3e9a56d78815262c4fb9686775474d835fc9b777..9e98af8451b3a03ceae81feafe0cf35089bd9223 100644 (file)
@@ -1498,9 +1498,9 @@ virthba_serverup(struct virtpci_dev *virtpcidev)
        /* Must transition channel to ATTACHED state BEFORE we
         * can start using the device again
         */
-       ULTRA_CHANNEL_CLIENT_TRANSITION(virthbainfo->chinfo.queueinfo->chan,
-                                       dev_name(&virtpcidev->generic_dev),
-                                       CHANNELCLI_ATTACHED, NULL);
+       SPAR_CHANNEL_CLIENT_TRANSITION(virthbainfo->chinfo.queueinfo->chan,
+                                      dev_name(&virtpcidev->generic_dev),
+                                      CHANNELCLI_ATTACHED, NULL);
 
        /* Start Processing the IOVM Response Queue Again */
        if (!uisthread_start(&virthbainfo->chinfo.threadinfo,
index 160ed8284e88e93a96967d34ee4375a89178cf2d..eaae4e8b9b451e28fcd33a5e1bacc66ea07cecee 100644 (file)
@@ -1009,9 +1009,9 @@ static int virtpci_device_add(struct device *parentbus, int devtype,
         * queues can begin at any time after device_register().
         */
        pDev = &virtpcidev->generic_dev;
-       ULTRA_CHANNEL_CLIENT_TRANSITION(addparams->chanptr,
-                                       BUS_ID(pDev),
-                                       CHANNELCLI_ATTACHED, NULL);
+       SPAR_CHANNEL_CLIENT_TRANSITION(addparams->chanptr,
+                                      BUS_ID(pDev),
+                                      CHANNELCLI_ATTACHED, NULL);
 
        /* don't register until device has been added to
        * list. Otherwise, a device_unregister from this function can
@@ -1032,9 +1032,9 @@ static int virtpci_device_add(struct device *parentbus, int devtype,
        if (ret) {
                LOGERR("device_register returned %d\n", ret);
                pDev = &virtpcidev->generic_dev;
-               ULTRA_CHANNEL_CLIENT_TRANSITION(addparams->chanptr,
-                                               BUS_ID(pDev),
-                                               CHANNELCLI_DETACHED, NULL);
+               SPAR_CHANNEL_CLIENT_TRANSITION(addparams->chanptr,
+                                              BUS_ID(pDev),
+                                              CHANNELCLI_DETACHED, NULL);
                /* remove virtpcidev, the one we just added, from the list */
                write_lock_irqsave(&VpcidevListLock, flags);
                for (tmpvpcidev = VpcidevListHead, prev = NULL;