]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
staging/lustre: Remove server code from class_get_type()
authorOleg Drokin <green@linuxhacker.ru>
Tue, 16 Feb 2016 05:46:41 +0000 (00:46 -0500)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 20 Feb 2016 22:33:11 +0000 (14:33 -0800)
class_get_type has some references to various server modules
that could not exist on the server, so get rid of them.

Signed-off-by: Oleg Drokin <green@linuxhacker.ru>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/lustre/lustre/obdclass/genops.c

index 5665655fd6eea5f4d2fd01fed152a3f87dbc4ac5..1cb68df63987a42eac2b03faf551d8337d872c54 100644 (file)
@@ -113,15 +113,6 @@ static struct obd_type *class_get_type(const char *name)
        if (!type) {
                const char *modname = name;
 
-               if (strcmp(modname, "obdfilter") == 0)
-                       modname = "ofd";
-
-               if (strcmp(modname, LUSTRE_LWP_NAME) == 0)
-                       modname = LUSTRE_OSP_NAME;
-
-               if (!strncmp(modname, LUSTRE_MDS_NAME, strlen(LUSTRE_MDS_NAME)))
-                       modname = LUSTRE_MDT_NAME;
-
                if (!request_module("%s", modname)) {
                        CDEBUG(D_INFO, "Loaded module '%s'\n", modname);
                        type = class_search_type(name);