staging: comedi: remove unnecessary dev->board_name initialization
authorH Hartley Sweeten <hsweeten@visionengravers.com>
Mon, 8 Apr 2013 17:57:35 +0000 (10:57 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 8 Apr 2013 18:44:07 +0000 (11:44 -0700)
The dev->board_name is now initialized by the comedi core before calling
the(*attach) or (*auto_attach) function in a driver. As long as the driver
does no additional probing, it's no longer necessary initialize the board_name.

Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com>
Reviewed-by: Ian Abbott <abbotti@mev.co.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
51 files changed:
drivers/staging/comedi/drivers/8255.c
drivers/staging/comedi/drivers/addi_apci_1032.c
drivers/staging/comedi/drivers/addi_apci_1710.c
drivers/staging/comedi/drivers/addi_apci_2032.c
drivers/staging/comedi/drivers/addi_apci_2200.c
drivers/staging/comedi/drivers/addi_apci_3501.c
drivers/staging/comedi/drivers/adl_pci8164.c
drivers/staging/comedi/drivers/adl_pci9111.c
drivers/staging/comedi/drivers/adq12b.c
drivers/staging/comedi/drivers/adv_pci1723.c
drivers/staging/comedi/drivers/adv_pci1724.c
drivers/staging/comedi/drivers/aio_iiro_16.c
drivers/staging/comedi/drivers/c6xdigio.c
drivers/staging/comedi/drivers/cb_pcimdas.c
drivers/staging/comedi/drivers/cb_pcimdda.c
drivers/staging/comedi/drivers/comedi_parport.c
drivers/staging/comedi/drivers/comedi_test.c
drivers/staging/comedi/drivers/contec_pci_dio.c
drivers/staging/comedi/drivers/das16m1.c
drivers/staging/comedi/drivers/das6402.c
drivers/staging/comedi/drivers/dmm32at.c
drivers/staging/comedi/drivers/dt2814.c
drivers/staging/comedi/drivers/dt2815.c
drivers/staging/comedi/drivers/dt2817.c
drivers/staging/comedi/drivers/dt9812.c
drivers/staging/comedi/drivers/dyna_pci10xx.c
drivers/staging/comedi/drivers/fl512.c
drivers/staging/comedi/drivers/icp_multi.c
drivers/staging/comedi/drivers/ii_pci20kc.c
drivers/staging/comedi/drivers/jr3_pci.c
drivers/staging/comedi/drivers/ke_counter.c
drivers/staging/comedi/drivers/mpc624.c
drivers/staging/comedi/drivers/multiq3.c
drivers/staging/comedi/drivers/ni_daq_700.c
drivers/staging/comedi/drivers/ni_daq_dio24.c
drivers/staging/comedi/drivers/pcl725.c
drivers/staging/comedi/drivers/pcm3724.c
drivers/staging/comedi/drivers/pcm3730.c
drivers/staging/comedi/drivers/pcmda12.c
drivers/staging/comedi/drivers/pcmmio.c
drivers/staging/comedi/drivers/quatech_daqp_cs.c
drivers/staging/comedi/drivers/rti802.c
drivers/staging/comedi/drivers/s526.c
drivers/staging/comedi/drivers/s626.c
drivers/staging/comedi/drivers/serial2002.c
drivers/staging/comedi/drivers/skel.c
drivers/staging/comedi/drivers/ssv_dnp.c
drivers/staging/comedi/drivers/unioxx5.c
drivers/staging/comedi/drivers/usbdux.c
drivers/staging/comedi/drivers/usbduxfast.c
drivers/staging/comedi/drivers/usbduxsigma.c

index c7aa41ad842f8e2be8e82632825c6536613861d4..0237187389e44f1661cf0725b88621a244623fac 100644 (file)
@@ -354,8 +354,6 @@ static int dev_8255_attach(struct comedi_device *dev,
        unsigned long iobase;
        int i;
 
-       dev->board_name = "8255";
-
        for (i = 0; i < COMEDI_NDEVCONFOPTS; i++) {
                iobase = it->options[i];
                if (!iobase)
index 3d32448e4e69f555f49ba02cac630269dbfb7c0a..3d4878facc26994a5e31de3d52375acbe2358ad8 100644 (file)
@@ -296,8 +296,6 @@ static int apci1032_auto_attach(struct comedi_device *dev,
        struct comedi_subdevice *s;
        int ret;
 
-       dev->board_name = dev->driver->driver_name;
-
        devpriv = kzalloc(sizeof(*devpriv), GFP_KERNEL);
        if (!devpriv)
                return -ENOMEM;
index 3640c50f2cb0d0cc6e4ce0cf21b553a7c4b47fa1..acde462a69275e8d9ccd3f3103bd8618852e1c7a 100644 (file)
@@ -35,8 +35,6 @@ static int apci1710_auto_attach(struct comedi_device *dev,
        struct comedi_subdevice *s;
        int ret;
 
-       dev->board_name = dev->driver->driver_name;
-
        devpriv = kzalloc(sizeof(*devpriv), GFP_KERNEL);
        if (!devpriv)
                return -ENOMEM;
index 59e092eab9f3455b723eb151314f9d84a32c235a..e5fa20aa7f2d154827e578602ff0b4587b26490b 100644 (file)
@@ -287,8 +287,6 @@ static int apci2032_auto_attach(struct comedi_device *dev,
        struct comedi_subdevice *s;
        int ret;
 
-       dev->board_name = dev->driver->driver_name;
-
        ret = comedi_pci_enable(dev);
        if (ret)
                return ret;
index 0953f65ab0ad67f5a8f370f003856ffe732d139a..8cad37ccf73e792c8a3a4cb33721198385290914 100644 (file)
@@ -88,8 +88,6 @@ static int apci2200_auto_attach(struct comedi_device *dev,
        struct comedi_subdevice *s;
        int ret;
 
-       dev->board_name = dev->driver->driver_name;
-
        ret = comedi_pci_enable(dev);
        if (ret)
                return ret;
index 75a36e364932fd094102b87b0dc61b6c8ddf20d2..a0cf6ecdef0ee68c2557bbabe2a53616954c4f12 100644 (file)
@@ -339,8 +339,6 @@ static int apci3501_auto_attach(struct comedi_device *dev,
        int ao_n_chan;
        int ret;
 
-       dev->board_name = dev->driver->driver_name;
-
        devpriv = kzalloc(sizeof(*devpriv), GFP_KERNEL);
        if (!devpriv)
                return -ENOMEM;
index 469a51d97b82cc407078cec01fbaef229b6e3dd0..b3ec60afe3a040f9b55fa6667e2a870e5f0a0108 100644 (file)
@@ -78,8 +78,6 @@ static int adl_pci8164_auto_attach(struct comedi_device *dev,
        struct comedi_subdevice *s;
        int ret;
 
-       dev->board_name = dev->driver->driver_name;
-
        ret = comedi_pci_enable(dev);
        if (ret)
                return ret;
index 9c27e981db0c5255f545cf63bfc3c2b8b0b3857c..99bce7c74af754324bd6f20d85cd3348d05d9e33 100644 (file)
@@ -865,8 +865,6 @@ static int pci9111_auto_attach(struct comedi_device *dev,
        struct comedi_subdevice *s;
        int ret;
 
-       dev->board_name = dev->driver->driver_name;
-
        dev_private = kzalloc(sizeof(*dev_private), GFP_KERNEL);
        if (!dev_private)
                return -ENOMEM;
index f7950dfe2ddbca536a112310d56a54bb5bd12913..dd315972d927127e9235dd0b1d8f4d324bfe5e07 100644 (file)
@@ -217,8 +217,6 @@ static int adq12b_attach(struct comedi_device *dev, struct comedi_devconfig *it)
        int unipolar, differential;
        int ret;
 
-       dev->board_name = dev->driver->driver_name;
-
        iobase = it->options[0];
        unipolar = it->options[1];
        differential = it->options[2];
index 9e81e58a6e695d4a3f4ebc4f691aa121427c4f15..ccc114d6c08b4e183beb0c126606f7a75b7f2917 100644 (file)
@@ -242,8 +242,6 @@ static int pci1723_auto_attach(struct comedi_device *dev,
        struct comedi_subdevice *s;
        int ret;
 
-       dev->board_name = dev->driver->driver_name;
-
        devpriv = kzalloc(sizeof(*devpriv), GFP_KERNEL);
        if (!devpriv)
                return -ENOMEM;
index a33929e87a2f34ee112b2b67c9e62fd6f90324c5..e60f12578d44c2e9d6f3ec0f584e8854c02fa8a2 100644 (file)
@@ -358,8 +358,6 @@ static int adv_pci1724_auto_attach(struct comedi_device *dev,
                devpriv->gain_value[i] = -1;
        }
 
-       dev->board_name = dev->driver->driver_name;
-
        retval = comedi_pci_enable(dev);
        if (retval)
                return retval;
index 64c1ae58ce7fc1ac22d7243ac7273ad995df7f1d..29aba2bb396fe1381ad40ee9d7d63090640a6b09 100644 (file)
@@ -83,8 +83,6 @@ static int aio_iiro_16_attach(struct comedi_device *dev,
 
        printk(KERN_INFO "comedi%d: aio_iiro_16: ", dev->minor);
 
-       dev->board_name = dev->driver->driver_name;
-
        iobase = it->options[0];
 
        if (!request_region(iobase, AIO_IIRO_16_SIZE, dev->board_name)) {
index 070037c22db7ab25b7787b6179d01132c0b3e2c3..816b879c7e199d10586e04e7c3e23a2a87694aac 100644 (file)
@@ -431,7 +431,6 @@ static int c6xdigio_attach(struct comedi_device *dev,
                return -EIO;
        }
        dev->iobase = iobase;
-       dev->board_name = "c6xdigio";
 
        result = comedi_alloc_subdevices(dev, 2);
        if (result)
index f6d99a3a972e404b4c4dde01999f60fa5a43e9ce..29813c9d4a2a14783420b83021d312e016733b61 100644 (file)
@@ -215,8 +215,6 @@ static int cb_pcimdas_auto_attach(struct comedi_device *dev,
        unsigned long iobase_8255;
        int ret;
 
-       dev->board_name = dev->driver->driver_name;
-
        devpriv = kzalloc(sizeof(*devpriv), GFP_KERNEL);
        if (!devpriv)
                return -ENOMEM;
index d00f7f629d36fc8ab7f5d203792f8eb5b5344e10..f7d1136be652e9f21d2de54bc23f7f5ec4d0f329 100644 (file)
@@ -161,8 +161,6 @@ static int cb_pcimdda_auto_attach(struct comedi_device *dev,
        struct comedi_subdevice *s;
        int ret;
 
-       dev->board_name = dev->driver->driver_name;
-
        devpriv = kzalloc(sizeof(*devpriv), GFP_KERNEL);
        if (!devpriv)
                return -ENOMEM;
index 76d59dcbea07233bae7f46db7e19b3b3758f0f27..e392f6837ab1e4ca449ea5a4182cd2766800e6b6 100644 (file)
@@ -266,8 +266,6 @@ static int parport_attach(struct comedi_device *dev,
        unsigned long iobase;
        struct comedi_subdevice *s;
 
-       dev->board_name = dev->driver->driver_name;
-
        iobase = it->options[0];
        if (!request_region(iobase, PARPORT_SIZE, dev->board_name)) {
                dev_err(dev->class_dev, "I/O port conflict\n");
index 270fea5c6b512a7bc462173b7b9cade1210ba04d..c1d8e86f53a20e73b99196c05610c767640aa604 100644 (file)
@@ -384,8 +384,6 @@ static int waveform_attach(struct comedi_device *dev,
        int i;
        int ret;
 
-       dev->board_name = dev->driver->driver_name;
-
        devpriv = kzalloc(sizeof(*devpriv), GFP_KERNEL);
        if (!devpriv)
                return -ENOMEM;
index da0be62aef600097abd09d0efe983eeb31a52b60..f2230bfd4eb9c656ff0103085d1b5f460254e7bf 100644 (file)
@@ -77,8 +77,6 @@ static int contec_auto_attach(struct comedi_device *dev,
        struct comedi_subdevice *s;
        int ret;
 
-       dev->board_name = dev->driver->driver_name;
-
        ret = comedi_pci_enable(dev);
        if (ret)
                return ret;
index 7ba8fc7a02f697590b565d0e4b66244487045cbd..3c37a660a154a7b1ea01e7c75e4c539b5a07bb54 100644 (file)
@@ -573,8 +573,6 @@ static int das16m1_attach(struct comedi_device *dev,
        unsigned int irq;
        unsigned long iobase;
 
-       dev->board_name = dev->driver->driver_name;
-
        iobase = it->options[0];
 
        devpriv = kzalloc(sizeof(*devpriv), GFP_KERNEL);
index 2efddb89bbcb67c24f6d6f0dbb2a6b20f0e308bf..c2f20c281d48daae363a05889be41f133c596ae8 100644 (file)
@@ -288,8 +288,6 @@ static int das6402_attach(struct comedi_device *dev,
        int ret;
        struct comedi_subdevice *s;
 
-       dev->board_name = "das6402";
-
        iobase = it->options[0];
        if (iobase == 0)
                iobase = 0x300;
index 9e2124179a0cb2053351a2c4beb29a61b55ea16b..ca07e54de2eef06eca7b99b28af71515ad19f4c6 100644 (file)
@@ -698,8 +698,6 @@ static int dmm32at_attach(struct comedi_device *dev,
        unsigned long iobase;
        unsigned int irq;
 
-       dev->board_name = dev->driver->driver_name;
-
        iobase = it->options[0];
        irq = it->options[1];
 
index e520dbaaa194ecf83f3327f0e7cb16eec91df9c2..e4d629e6d06ec6e3e09d23eadc9499ef538ff8a9 100644 (file)
@@ -255,7 +255,6 @@ static int dt2814_attach(struct comedi_device *dev, struct comedi_devconfig *it)
                return -EIO;
        }
        dev->iobase = iobase;
-       dev->board_name = "dt2814";
 
        outb(0, dev->iobase + DT2814_CSR);
        udelay(100);
index 10828fc7e16cecfabaf7df0b2b1c25de9e03208b..ad18b1ac8d321adbc3289fb2c38098f2f099fa3a 100644 (file)
@@ -171,7 +171,6 @@ static int dt2815_attach(struct comedi_device *dev, struct comedi_devconfig *it)
        }
 
        dev->iobase = iobase;
-       dev->board_name = "dt2815";
 
        ret = comedi_alloc_subdevices(dev, 1);
        if (ret)
index 502e42e0753e448287acc077bb2d44f7ddce1c15..0dd6dd0f2a3d69c9a3b3b15328781bfb60638977 100644 (file)
@@ -135,7 +135,6 @@ static int dt2817_attach(struct comedi_device *dev, struct comedi_devconfig *it)
                return -EIO;
        }
        dev->iobase = iobase;
-       dev->board_name = "dt2817";
 
        ret = comedi_alloc_subdevices(dev, 1);
        if (ret)
index 9ca3488da4df747e49a3fc4d4c9637fe30f61c98..81eb5ed6ec97dae546c3ea9dfcbb0bdd46cdf9c3 100644 (file)
@@ -1012,8 +1012,6 @@ static int dt9812_attach(struct comedi_device *dev, struct comedi_devconfig *it)
        struct comedi_subdevice *s;
        int ret;
 
-       dev->board_name = "dt9812";
-
        devpriv = kzalloc(sizeof(*devpriv), GFP_KERNEL);
        if (!devpriv)
                return -ENOMEM;
index 17f9ec2a9072fc6b7358a762fb66645297192d18..93ec8e492cccbfa0b6abf90754bd2226225adeab 100644 (file)
@@ -187,8 +187,6 @@ static int dyna_pci10xx_auto_attach(struct comedi_device *dev,
        struct comedi_subdevice *s;
        int ret;
 
-       dev->board_name = dev->driver->driver_name;
-
        devpriv = kzalloc(sizeof(*devpriv), GFP_KERNEL);
        if (!devpriv)
                return -ENOMEM;
index 019c96eda6fd25b93f65c59524263bde72157fd7..07f9d6760364d750f3433d026ef7f7dc72112ad9 100644 (file)
@@ -125,7 +125,6 @@ static int fl512_attach(struct comedi_device *dev, struct comedi_devconfig *it)
                return -EIO;
        }
        dev->iobase = iobase;
-       dev->board_name = "fl512";
 
        devpriv = kzalloc(sizeof(*devpriv), GFP_KERNEL);
        if (!devpriv)
index f29a797fd9d5741da712f1532f7e55cb89b41ed1..2bd916e4bfe838f7dcc4172f1bb96d874d3f6082 100644 (file)
@@ -503,8 +503,6 @@ static int icp_multi_auto_attach(struct comedi_device *dev,
        resource_size_t iobase;
        int ret;
 
-       dev->board_name = dev->driver->driver_name;
-
        devpriv = kzalloc(sizeof(*devpriv), GFP_KERNEL);
        if (!devpriv)
                return -ENOMEM;
index 93584e2be35a50c8e97dbfec2a494e33e60cddae..03719f256d187563b0b524ba57355781b42cf07a 100644 (file)
@@ -212,7 +212,6 @@ static int pci20xxx_attach(struct comedi_device *dev,
        dev->private = devpriv;
 
        devpriv->ioaddr = (void __iomem *)(unsigned long)it->options[0];
-       dev->board_name = "pci20kc";
 
        /* Check PCI-20001 C-2A Carrier Board ID */
        if ((readb(devpriv->ioaddr) & PCI20000_ID) != PCI20000_ID) {
index f21ebb536a2d8fb97be68bd03510a6347cc3fab9..653c5c3891e1e55ddebcf15e7d309abeadba7be9 100644 (file)
@@ -700,7 +700,6 @@ static int jr3_pci_auto_attach(struct comedi_device *dev,
                return -EINVAL;
                break;
        }
-       dev->board_name = "jr3_pci";
 
        result = comedi_pci_enable(dev);
        if (result)
index bca29e5f4fc5e798b01aab348c5b300a96c91a1d..e0e64752e3103032e2724c6f9c541a7d1064ab74 100644 (file)
@@ -96,8 +96,6 @@ static int cnt_auto_attach(struct comedi_device *dev,
        struct comedi_subdevice *s;
        int ret;
 
-       dev->board_name = dev->driver->driver_name;
-
        ret = comedi_pci_enable(dev);
        if (ret)
                return ret;
index 67dc5ad81b0d883334c6ad51d479bfa749e87895..3b7a53f8a23588e9eb8b47ed8bd3e8ebcacfda6e 100644 (file)
@@ -296,7 +296,6 @@ static int mpc624_attach(struct comedi_device *dev, struct comedi_devconfig *it)
        }
 
        dev->iobase = iobase;
-       dev->board_name = "mpc624";
 
        devpriv = kzalloc(sizeof(*devpriv), GFP_KERNEL);
        if (!devpriv)
index 1f5f402f3d17245322c8387767c8ec7158cd3d6b..fe94a62de4383ed8ed5c65c4363529dd5a14afab 100644 (file)
@@ -252,7 +252,6 @@ static int multiq3_attach(struct comedi_device *dev,
                        dev->minor, irq);
        else
                printk(KERN_WARNING "comedi%d: no irq\n", dev->minor);
-       dev->board_name = "multiq3";
 
        result = comedi_alloc_subdevices(dev, 5);
        if (result)
index 9cc6092eacdd87df8d2fc4141e397d1ef085675a..d067ef70e194d3e736e28eb975d95502b4565392 100644 (file)
@@ -202,8 +202,6 @@ static int daq700_auto_attach(struct comedi_device *dev,
        struct comedi_subdevice *s;
        int ret;
 
-       dev->board_name = dev->driver->driver_name;
-
        link->config_flags |= CONF_AUTO_SET_IO;
        ret = comedi_pcmcia_enable(dev, NULL);
        if (ret)
index e1cc9d01f2000a9cadd10137cf3ce25ba05abbb1..c17ffe3cf5c41209ee532615b02ff5cf2bc32b14 100644 (file)
@@ -52,8 +52,6 @@ static int dio24_auto_attach(struct comedi_device *dev,
        struct comedi_subdevice *s;
        int ret;
 
-       dev->board_name = dev->driver->driver_name;
-
        link->config_flags |= CONF_AUTO_SET_IO;
        ret = comedi_pcmcia_enable(dev, NULL);
        if (ret)
index 21fbc1ae1e73ceca01bbeddacaff58c8cb0f346c..3cd5e7f04f428c290976b89ff86350855e5fff53 100644 (file)
@@ -54,7 +54,6 @@ static int pcl725_attach(struct comedi_device *dev, struct comedi_devconfig *it)
                printk("I/O port conflict\n");
                return -EIO;
        }
-       dev->board_name = "pcl725";
        dev->iobase = iobase;
        dev->irq = 0;
 
index 5f062df1ead4026bdc6310a5f80fcb3f780bce1c..d78aeebd17b5b5e43df4c1316b5c0066350ffe7a 100644 (file)
@@ -230,8 +230,6 @@ static int pcm3724_attach(struct comedi_device *dev,
        unsigned int iorange;
        int ret, i;
 
-       dev->board_name = dev->driver->driver_name;
-
        iobase = it->options[0];
        iorange = PCM3724_SIZE;
 
index 067f14d22610cf37afb4912dd0456409443e8263..d049194f366ab8d81e614a172cb12acccd5d7313 100644 (file)
@@ -64,7 +64,6 @@ static int pcm3730_attach(struct comedi_device *dev,
                return -EIO;
        }
        dev->iobase = iobase;
-       dev->board_name = "pcm3730";
        dev->iobase = dev->iobase;
        dev->irq = 0;
 
index 13f79f49748a3e5b5e169d6f4b5a8ec1a504c803..64b76e48c29069d2508940b16cd7a5ac6e30728f 100644 (file)
@@ -168,8 +168,6 @@ static int pcmda12_attach(struct comedi_device *dev,
        }
        dev->iobase = iobase;
 
-       dev->board_name = dev->driver->driver_name;
-
        devpriv = kzalloc(sizeof(*devpriv), GFP_KERNEL);
        if (!devpriv)
                return -ENOMEM;
index 5fa1fe08eb97f5f75da24e0aa755225e44c952b0..a342e3799c51d233c9af63b946bccaf70fd19097 100644 (file)
@@ -1038,8 +1038,6 @@ static int pcmmio_attach(struct comedi_device *dev, struct comedi_devconfig *it)
        unsigned int irq[MAX_ASICS];
        int ret;
 
-       dev->board_name = dev->driver->driver_name;
-
        iobase = it->options[0];
        irq[0] = it->options[1];
 
index 911eb6b32296c8e6f0c205db34357853e4bfbc55..e092ce87722e1af838fe74a43051c05f5250963f 100644 (file)
@@ -715,8 +715,6 @@ static int daqp_auto_attach(struct comedi_device *dev,
        struct comedi_subdevice *s;
        int ret;
 
-       dev->board_name = dev->driver->driver_name;
-
        devpriv = kzalloc(sizeof(*devpriv), GFP_KERNEL);
        if (!devpriv)
                return -ENOMEM;
index 2185ca1bcf020638914eb54621ad2c4696779544..1440162c841149a3d5402824783ea7a6d188aafd 100644 (file)
@@ -103,8 +103,6 @@ static int rti802_attach(struct comedi_device *dev, struct comedi_devconfig *it)
        }
        dev->iobase = iobase;
 
-       dev->board_name = "rti802";
-
        devpriv = kzalloc(sizeof(*devpriv), GFP_KERNEL);
        if (!devpriv)
                return -ENOMEM;
index 39232b359453395a98d08b771d809195827e57c1..b490b47b0bb847b85929971d496819b902e077cb 100644 (file)
@@ -555,8 +555,6 @@ static int s526_attach(struct comedi_device *dev, struct comedi_devconfig *it)
        int iobase;
        int ret;
 
-       dev->board_name = dev->driver->driver_name;
-
        iobase = it->options[0];
        if (!iobase || !request_region(iobase, S526_IOSIZE, dev->board_name)) {
                comedi_error(dev, "I/O port conflict");
index 02f9406f8f09e8a5b81a8799373abe7141d53433..b6c7cb980d3380e78b859535196fd2a8c3ec52e1 100644 (file)
@@ -2590,8 +2590,6 @@ static int s626_auto_attach(struct comedi_device *dev,
        struct comedi_subdevice *s;
        int ret;
 
-       dev->board_name = dev->driver->driver_name;
-
        devpriv = kzalloc(sizeof(*devpriv), GFP_KERNEL);
        if (!devpriv)
                return -ENOMEM;
index 21e3cf162636f8ef92b43f20246252340c83960d..8900086374db8a581d9781f2499d8f2e6a5791ec 100644 (file)
@@ -724,8 +724,6 @@ static int serial2002_attach(struct comedi_device *dev,
        struct comedi_subdevice *s;
        int ret;
 
-       dev->board_name = dev->driver->driver_name;
-
        devpriv = kzalloc(sizeof(*devpriv), GFP_KERNEL);
        if (!devpriv)
                return -ENOMEM;
index 6fb7d5d220946c4c313e3a74f9e77678cca0b6d6..6dc77fc0722014b4f203a1de0d0a6f2d28d3027e 100644 (file)
@@ -481,10 +481,12 @@ static int skel_attach(struct comedi_device *dev, struct comedi_devconfig *it)
 
        thisboard = comedi_board(dev);
 
-/*
- * Initialize dev->board_name.
- */
-       dev->board_name = thisboard->name;
+       /*
+        * The dev->board_name is initialized by the comedi core before
+        * calling the (*attach) function. It can be optionally set by
+        * the driver if additional probing has been done.
+        */
+       /* dev->board_name = thisboard->name; */
 
        /* Allocate the private data */
        devpriv = kzalloc(sizeof(*devpriv), GFP_KERNEL);
index afa4016f906ae4d63f816140223dff43dc2fd3a9..a76df092a57b149bc131f5460d0fa30273097a4d 100644 (file)
@@ -167,8 +167,6 @@ static int dnp_attach(struct comedi_device *dev, struct comedi_devconfig *it)
        struct comedi_subdevice *s;
        int ret;
 
-       dev->board_name = dev->driver->driver_name;
-
        ret = comedi_alloc_subdevices(dev, 1);
        if (ret)
                return ret;
index 74b974bf10324ae96cfc52ca78707409b757321f..fdeec4b5076b7937893d405f9433fdf292b0a8f5 100644 (file)
@@ -442,7 +442,6 @@ static int unioxx5_attach(struct comedi_device *dev,
 
        iobase = it->options[0];
 
-       dev->board_name = DRIVER_NAME;
        dev->iobase = iobase;
        iobase += UNIOXX5_SUBDEV_BASE;
 
index 148ecfcc5dd5705e1eaa4ea41b7fa45183ab652d..6f5da67e26cba8ab03fa39abf2532391ce5cb80a 100644 (file)
@@ -2207,8 +2207,6 @@ static int usbdux_attach_common(struct comedi_device *dev,
        /* pointer back to the corresponding comedi device */
        udev->comedidev = dev;
 
-       dev->board_name = "usbdux";
-
        /* set number of subdevices */
        if (udev->high_speed) {
                /* with pwm */
index 1ba0e3df492d1e9ceeedcebe4af3e85b82a08491..7f95af33085d42e6010c0e9b8ddad3dc302ac210 100644 (file)
@@ -1387,7 +1387,7 @@ static int usbduxfast_attach_common(struct comedi_device *dev,
        down(&udfs->sem);
        /* pointer back to the corresponding comedi device */
        udfs->comedidev = dev;
-       dev->board_name = "usbduxfast";
+
        ret = comedi_alloc_subdevices(dev, 1);
        if (ret) {
                up(&udfs->sem);
index 1c2bfb4423e3b5655662792c75bcc4c5e3450e14..d3bc1b9910a7d3cea18b57364b102f3e21bc0359 100644 (file)
@@ -2205,7 +2205,7 @@ static int usbduxsigma_attach_common(struct comedi_device *dev,
        down(&uds->sem);
        /* pointer back to the corresponding comedi device */
        uds->comedidev = dev;
-       dev->board_name = "usbduxsigma";
+
        /* set number of subdevices */
        if (uds->high_speed)
                n_subdevs = 4;  /* with pwm */