aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/char
diff options
context:
space:
mode:
authorDominik Brodowski <linux@dominikbrodowski.net>2010-03-20 14:35:12 -0400
committerDominik Brodowski <linux@dominikbrodowski.net>2010-05-10 04:23:15 -0400
commitded6a1a341cb38c4cfeb09d3d01ffe16b5c804b3 (patch)
treec430b9dc1ee04ecbe39da798524684b2db779b0f /drivers/char
parent317b6d63000b3cc48c43d582d76063500e531a6c (diff)
pcmcia: dev_node removal (drivers with updated printk call)
As a second step, remove any usage of dev_node_t from drivers which only wrote to this typedef/struct, except one printk() which can easily be replaced by a dev_info()/dev_warn() call. CC: Harald Welte <laforge@gnumonks.org> CC: linux-ide@vger.kernel.org CC: linux-wireless@vger.kernel.org CC: netdev@vger.kernel.org CC: linux-usb@vger.kernel.org Acked-by: Karsten Keil <isdn@linux-pingi.de> Signed-off-by: Dominik Brodowski <linux@dominikbrodowski.net>
Diffstat (limited to 'drivers/char')
-rw-r--r--drivers/char/pcmcia/cm4000_cs.c9
-rw-r--r--drivers/char/pcmcia/synclink_cs.c10
2 files changed, 3 insertions, 16 deletions
diff --git a/drivers/char/pcmcia/cm4000_cs.c b/drivers/char/pcmcia/cm4000_cs.c
index 90b199f97bec..e7956acf2ad6 100644
--- a/drivers/char/pcmcia/cm4000_cs.c
+++ b/drivers/char/pcmcia/cm4000_cs.c
@@ -106,7 +106,6 @@ static int major; /* major number we get from the kernel */
106 106
107struct cm4000_dev { 107struct cm4000_dev {
108 struct pcmcia_device *p_dev; 108 struct pcmcia_device *p_dev;
109 dev_node_t node; /* OS node (major,minor) */
110 109
111 unsigned char atr[MAX_ATR]; 110 unsigned char atr[MAX_ATR];
112 unsigned char rbuf[512]; 111 unsigned char rbuf[512];
@@ -884,8 +883,7 @@ static void monitor_card(unsigned long p)
884 /* slow down warning, but prompt immediately after insertion */ 883 /* slow down warning, but prompt immediately after insertion */
885 if (dev->cwarn == 0 || dev->cwarn == 10) { 884 if (dev->cwarn == 0 || dev->cwarn == 10) {
886 set_bit(IS_BAD_CARD, &dev->flags); 885 set_bit(IS_BAD_CARD, &dev->flags);
887 printk(KERN_WARNING MODULE_NAME ": device %s: ", 886 dev_warn(&dev->p_dev->dev, MODULE_NAME ": ");
888 dev->node.dev_name);
889 if (test_bit(IS_BAD_CSUM, &dev->flags)) { 887 if (test_bit(IS_BAD_CSUM, &dev->flags)) {
890 DEBUGP(4, dev, "ATR checksum (0x%.2x, should " 888 DEBUGP(4, dev, "ATR checksum (0x%.2x, should "
891 "be zero) failed\n", dev->atr_csum); 889 "be zero) failed\n", dev->atr_csum);
@@ -1781,11 +1779,6 @@ static int cm4000_config(struct pcmcia_device * link, int devno)
1781 goto cs_release; 1779 goto cs_release;
1782 1780
1783 dev = link->priv; 1781 dev = link->priv;
1784 sprintf(dev->node.dev_name, DEVICE_NAME "%d", devno);
1785 dev->node.major = major;
1786 dev->node.minor = devno;
1787 dev->node.next = NULL;
1788 link->dev_node = &dev->node;
1789 1782
1790 return 0; 1783 return 0;
1791 1784
diff --git a/drivers/char/pcmcia/synclink_cs.c b/drivers/char/pcmcia/synclink_cs.c
index 027690b70d2c..308903ec8bf8 100644
--- a/drivers/char/pcmcia/synclink_cs.c
+++ b/drivers/char/pcmcia/synclink_cs.c
@@ -220,7 +220,6 @@ typedef struct _mgslpc_info {
220 220
221 /* PCMCIA support */ 221 /* PCMCIA support */
222 struct pcmcia_device *p_dev; 222 struct pcmcia_device *p_dev;
223 dev_node_t node;
224 int stop; 223 int stop;
225 224
226 /* SPPP/Cisco HDLC device parts */ 225 /* SPPP/Cisco HDLC device parts */
@@ -614,13 +613,8 @@ static int mgslpc_config(struct pcmcia_device *link)
614 info->io_base = link->io.BasePort1; 613 info->io_base = link->io.BasePort1;
615 info->irq_level = link->irq; 614 info->irq_level = link->irq;
616 615
617 /* add to linked list of devices */ 616 dev_info(&link->dev, "index 0x%02x:",
618 sprintf(info->node.dev_name, "mgslpc0"); 617 link->conf.ConfigIndex);
619 info->node.major = info->node.minor = 0;
620 link->dev_node = &info->node;
621
622 printk(KERN_INFO "%s: index 0x%02x:",
623 info->node.dev_name, link->conf.ConfigIndex);
624 if (link->conf.Attributes & CONF_ENABLE_IRQ) 618 if (link->conf.Attributes & CONF_ENABLE_IRQ)
625 printk(", irq %d", link->irq); 619 printk(", irq %d", link->irq);
626 if (link->io.NumPorts1) 620 if (link->io.NumPorts1)