staging: wlags49_h2: remove custom ways of creating a module name
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 9 Jan 2014 17:36:29 +0000 (09:36 -0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 9 Jan 2014 17:36:29 +0000 (09:36 -0800)
Just use KBUILD_MODNAME, don't try to hand-roll the same thing with odd
logic.

Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/wlags49_h2/wl_cs.c
drivers/staging/wlags49_h2/wl_main.c
drivers/staging/wlags49_h2/wl_pci.c
drivers/staging/wlags49_h2/wl_version.h

index a33eea140113663587845219e26893b2f3efcb21..5077301134e04acd84b73811e0cd682d52873f21 100644 (file)
@@ -242,7 +242,7 @@ int wl_adapter_insert(struct pcmcia_device *link)
        SET_NETDEV_DEV(dev, &link->dev);
        ret = register_netdev(dev);
        if (ret != 0) {
-               printk("%s: register_netdev() failed\n", MODULE_NAME);
+               printk("%s: register_netdev() failed\n", KBUILD_MODNAME);
                goto failed;
        }
 
index 093366b6ab14f89426681af58a61aa6c5a63cdbc..632cebde985142b6b3ae06d285a321fe9f5c378d 100644 (file)
@@ -400,7 +400,7 @@ static p_u32    pc_debug = DBG_LVL;
  */ p_u32    DebugFlag = ~0; //recognizable "undefined value" rather then DBG_DEFAULTS;
 //MODULE_PARM(DebugFlag, "l");
 
-dbg_info_t   wl_info = { DBG_MOD_NAME, 0, 0 };
+dbg_info_t   wl_info = { KBUILD_MODNAME, 0, 0 };
 dbg_info_t  *DbgInfo = &wl_info;
 
 #endif /* DBG */
index e2108f49dee9d837ea9f873e84cdcb95af0b7ab6..9bde47cbe1e6b2f3da6287d5b4e1540e874f5efd 100644 (file)
@@ -160,7 +160,7 @@ void wl_pci_dma_hcf_reclaim_rx( struct wl_private *lp );
  * PCI module function registration
  ******************************************************************************/
 static struct pci_driver wl_driver = {
-       .name     = MODULE_NAME,
+       .name     = KBUILD_MODNAME,
        .id_table = wl_pci_tbl,
        .probe    = wl_pci_probe,
        .remove   = wl_pci_remove,
index 8f62e95fd3c42519582e319183272caf98e5eb0f..bbc484a6b80fdaf26ca41239387cef0e06e3cab8 100644 (file)
@@ -115,31 +115,12 @@ err: define bus type;
 #define DRV_VARIANT         2
 #endif // HERMES25
 
-#ifdef BUS_PCMCIA
-#if defined HERMES25
-#define MODULE_NAME         DRIVER_NAME "_h25_cs"
-#else
-#define MODULE_NAME         DRIVER_NAME "_h2_cs"
-#endif  /* HERMES25 */
-#elif defined BUS_PCI
-#if defined HERMES25
-#define MODULE_NAME         DRIVER_NAME "_h25"
-#else
-#define MODULE_NAME         DRIVER_NAME "_h2"
-#endif  /* HERMES25 */
-#endif  /* BUS_XXX */
-
-#define VERSION_INFO   MODULE_NAME " v" DRV_VERSION_STR        \
+#define VERSION_INFO   KBUILD_MODNAME " v" DRV_VERSION_STR     \
                        " for " BUS_TYPE ", by " VENDOR_NAME
 
 /* The version of wireless extensions we support */
 #define WIRELESS_SUPPORT    21
 
-//#define DBG_MOD_NAME         DRIVER_NAME ":" BUS_TYPE ":" HW_TYPE ":" FW_TYPE
-#define DBG_MOD_NAME        MODULE_NAME
-
-
-
 /*******************************************************************************
  *  bus architecture specific defines, includes, etc.
  ******************************************************************************/