addi_common: Just use the driver name in the call to comedi_request_irq()
authorIan Abbott <abbotti@mev.co.uk>
Wed, 24 Mar 2010 17:04:59 +0000 (17:04 +0000)
committerIan Abbott <abbotti@mev.co.uk>
Wed, 24 Mar 2010 17:04:59 +0000 (17:04 +0000)
instead of a static char buffer that gets overwritten.

comedi/drivers/addi-data/addi_common.c

index a6ab05f64a492df6c1c22b8e4016ee315844a73f..6f65f5e6b0162eef65d8f984b48eedefa5d7c32a 100644 (file)
@@ -2574,10 +2574,6 @@ static int i_ADDI_Attach(comedi_device * dev, comedi_devconfig * it)
        struct pcilst_struct *card = NULL;
        unsigned char pci_bus, pci_slot, pci_func;
        int i_Dma = 0;
-       static char c_Identifier[150];
-
-       sprintf(c_Identifier, "Addi-Data GmbH Comedi %s",
-               this_board->pc_DriverName);
 
        if ((ret = alloc_private(dev, sizeof(addi_private))) < 0) {
                return -ENOMEM;
@@ -2651,7 +2647,7 @@ static int i_ADDI_Attach(comedi_device * dev, comedi_devconfig * it)
 
        if (irq > 0) {
                if (comedi_request_irq(irq, v_ADDI_Interrupt, IRQF_SHARED,
-                               c_Identifier, dev) < 0) {
+                               ADDIDATA_DRIVER_NAME, dev) < 0) {
                        printk(", unable to allocate IRQ %u, DISABLING IT",
                                irq);
                        irq = 0;        /* Can't use IRQ */