added recognize to use older name atmio-E
authorDavid Schleef <ds@schleef.org>
Wed, 6 Dec 2000 04:06:07 +0000 (04:06 +0000)
committerDavid Schleef <ds@schleef.org>
Wed, 6 Dec 2000 04:06:07 +0000 (04:06 +0000)
comedi/drivers/ni_atmio.c

index 23f68b317365514d692937f785e92ab44686a5ab..85191001bb2139cddef43309917bf02a29178fa5 100644 (file)
@@ -243,16 +243,31 @@ typedef struct{
 
 static int atmio_attach(comedi_device *dev,comedi_devconfig *it);
 static int atmio_detach(comedi_device *dev);
+static int atmio_recognize(const char *name);
 comedi_driver driver_atmio={
-       driver_name:    "atmio-E",
+       driver_name:    "ni_atmio",
        module:         THIS_MODULE,
        attach:         atmio_attach,
        detach:         atmio_detach,
+       recognize:      atmio_recognize,
 };
 
 
 #include "ni_mio_common.c"
 
+static int atmio_recognize(const char *name)
+{
+       if(!strcmp(name,"atmio-E")){
+               printk("Driver name 'atmio-E' deprecated.  Please use 'ni_atmio'.\n");
+               return 0;
+       }
+       if(!strcmp(name,"ni_atmio")){
+               return 0;
+       }
+
+       return -1;
+}
+
 
 static int init_stage2(comedi_device *dev,comedi_devconfig *it);
 static int ni_getboardtype(comedi_device *dev);