pcnet_cs: Use proper netdev_*-printouts
Subsystems (2)
PATCH 1/1 pcnet_cs: Use proper netdev_*-printouts
To prevent broken messages like:
[ 204.024291] eth%d: pcnet_reset_8390() did not complete.
---
There are 5 checkpatch-warnings regarding indentation. I did not fix them to keep the style of the rest of the driver. The code looks correct to me.
drivers/net/pcmcia/pcnet_cs.c | 58 +++++++++++++++++++---------------------- 1 files changed, 27 insertions(+), 31 deletions(-)
drivers/net/pcmcia/pcnet_cs.c +27 -31
@@ -646,12 +646,12 @@ static int pcnet_config(struct pcmcia_device *link)if (info->flags & (IS_DL10019 |IS_DL10022 )) {u_char id =inb (dev->base_addr +0x1a ); -printk (KERN_INFO "%s: NE2000 (DL100%d rev %02x): " , - dev->name, ((info->flags &IS_DL10022 ) ?22 :19 ), id); +netdev_info (dev,"NE2000 (DL100%d rev %02x): " , + (info->flags &IS_DL10022 ) ?22 :19 , id);if (info->pna_phy)printk ("PNA, " ); }else { -printk (KERN_INFO "%s: NE2000 Compatible: " , dev->name); +netdev_info (dev,"NE2000 Compatible: " ); }printk ("io %#3lx, irq %d," , dev->base_addr, dev->irq);if (info->flags &USE_SHMEM )
@@ -932,7 +932,7 @@ static void mii_phy_probe(struct net_device *dev) phyid = tmp <<16 ; phyid |=mdio_read (mii_addr, i,MII_PHYID_REG2 ); phyid &=MII_PHYID_REV_MASK ; -pr_debug ("%s: MII at %d is 0x%08x\n" , dev->name, i, phyid); +netdev_dbg (dev,"MII at %d is 0x%08x\n" , i, phyid);if (phyid ==AM79C9XX_HOME_PHY ) { info->pna_phy = i; }else if (phyid !=AM79C9XX_ETH_PHY ) {
@@ -1018,8 +1018,8 @@ static void pcnet_reset_8390(struct net_device *dev)outb_p (ENISR_RESET , nic_base +EN0_ISR );/* Ack intr. */ if (i ==100 ) -printk (KERN_ERR "%s: pcnet_reset_8390() did not complete.\n" , - dev->name); +netdev_err (dev,"pcnet_reset_8390() did not complete.\n" ); +set_misc_reg (dev); }/* pcnet_reset_8390 */
@@ -1035,8 +1035,7 @@ static int set_config(struct net_device *dev, struct ifmap *map)else if ((map->port <1 ) || (map->port >2 ))return -EINVAL ; dev->if_port = map->port; -printk (KERN_INFO "%s: switched to %s port\n" , - dev->name, if_names[dev->if_port]); +netdev_info (dev,"switched to %s port\n" , if_names[dev->if_port]);NS8390_init (dev,1 ); }return 0 ;
@@ -1071,7 +1070,7 @@ static void ei_watchdog(u_long arg)this, we can limp along even if the interrupt is blocked */ if (info->stale++ && (inb_p (nic_base +EN0_ISR ) &ENISR_ALL )) {if (!info->fast_poll) -printk (KERN_INFO "%s: interrupt(s) dropped!\n" , dev->name); +netdev_info (dev,"interrupt(s) dropped!\n" );ei_irq_wrapper (dev->irq, dev); info->fast_poll =HZ ; }
@@ -1091,7 +1090,7 @@ static void ei_watchdog(u_long arg)if (info->eth_phy) { info->phy_id = info->eth_phy =0 ; }else { -printk (KERN_INFO "%s: MII is missing!\n" , dev->name); +netdev_info (dev,"MII is missing!\n" ); info->flags &= ~HAS_MII ; } goto reschedule;
@@ -1100,8 +1099,7 @@ static void ei_watchdog(u_long arg) link &=0x0004 ;if (link != info->link_status) {u_short p =mdio_read (mii_addr, info->phy_id,5 ); -printk (KERN_INFO "%s: %s link beat\n" , dev->name, - (link) ?"found" :"lost" ); +netdev_info (dev,"%s link beat\n" , link ?"found" :"lost" );if (link && (info->flags &IS_DL10022 )) {/* Disable collision detection on full duplex links */ outb ((p &0x0140 ) ?4 :0 , nic_base +DLINK_DIAG );
@@ -1112,13 +1110,12 @@ static void ei_watchdog(u_long arg)if (link) {if (info->phy_id == info->eth_phy) {if (p) -printk (KERN_INFO "%s: autonegotiation complete: " -"%sbaseT-%cD selected\n" , dev->name, +netdev_info (dev,"autonegotiation complete: " +"%sbaseT-%cD selected\n" , ((p &0x0180 ) ?"100" :"10" ), ((p &0x0140 ) ?'F' :'H' ));else -printk (KERN_INFO "%s: link partner did not " -"autonegotiate\n" , dev->name); +netdev_info (dev,"link partner did not autonegotiate\n" ); }NS8390_init (dev,1 ); }
@@ -1131,7 +1128,7 @@ static void ei_watchdog(u_long arg)/* isolate this MII and try flipping to the other one */ mdio_write (mii_addr, info->phy_id,0 ,0x0400 ); info->phy_id ^= info->pna_phy ^ info->eth_phy; -printk (KERN_INFO "%s: switched to %s transceiver\n" , dev->name, +netdev_info (dev,"switched to %s transceiver\n" , (info->phy_id == info->eth_phy) ?"ethernet" :"PNA" );mdio_write (mii_addr, info->phy_id,0 , (info->phy_id == info->eth_phy) ?0x1000 :0 );
@@ -1191,9 +1188,9 @@ static void dma_get_8390_hdr(struct net_device *dev,unsigned int nic_base = dev->base_addr;if (ei_status.dmaing) { -printk (KERN_NOTICE "%s: DMAing conflict in dma_block_input." +netdev_notice (dev,"DMAing conflict in dma_block_input." "[DMAstat:%1x][irqlock:%1x]\n" , - dev->name, ei_status.dmaing, ei_status.irqlock); + ei_status.dmaing, ei_status.irqlock);return ; }
@@ -1224,11 +1221,11 @@ static void dma_block_input(struct net_device *dev, int count,char *buf = skb->data;if ((ei_debug >4 ) && (count !=4 )) -pr_debug ("%s: [bi=%d]\n" , dev->name, count+4 ); +netdev_dbg (dev,"[bi=%d]\n" , count+4 );if (ei_status.dmaing) { -printk (KERN_NOTICE "%s: DMAing conflict in dma_block_input." +netdev_notice (dev,"DMAing conflict in dma_block_input." "[DMAstat:%1x][irqlock:%1x]\n" , - dev->name, ei_status.dmaing, ei_status.irqlock); + ei_status.dmaing, ei_status.irqlock);return ; } ei_status.dmaing |=0x01 ;
@@ -1258,9 +1255,9 @@ static void dma_block_input(struct net_device *dev, int count, break; }while (--tries >0 );if (tries <=0 ) -printk (KERN_NOTICE "%s: RX transfer address mismatch," +netdev_notice (dev,"RX transfer address mismatch," "%#4.4x (expected) vs. %#4.4x (actual).\n" , - dev->name, ring_offset + xfer_count, addr); + ring_offset + xfer_count, addr); }#endif outb_p (ENISR_RDC , nic_base +EN0_ISR );/* Ack intr. */
@@ -1281,7 +1278,7 @@ static void dma_block_output(struct net_device *dev, int count,#ifdef PCMCIA_DEBUG if (ei_debug >4 ) -printk (KERN_DEBUG "%s: [bo=%d]\n" , dev->name, count); +netdev_dbg (dev,"[bo=%d]\n" , count);#endif /* Round the count up for word writes. Do we need to do this?
@@ -1290,9 +1287,9 @@ static void dma_block_output(struct net_device *dev, int count,if (count &0x01 ) count++;if (ei_status.dmaing) { -printk (KERN_NOTICE "%s: DMAing conflict in dma_block_output." +netdev_notice (dev,"DMAing conflict in dma_block_output." "[DMAstat:%1x][irqlock:%1x]\n" , - dev->name, ei_status.dmaing, ei_status.irqlock); + ei_status.dmaing, ei_status.irqlock);return ; } ei_status.dmaing |=0x01 ;
@@ -1329,9 +1326,9 @@ static void dma_block_output(struct net_device *dev, int count,break ; }while (--tries >0 );if (tries <=0 ) { -printk (KERN_NOTICE "%s: Tx packet transfer address mismatch," +netdev_notice (dev,"Tx packet transfer address mismatch," "%#4.4x (expected) vs. %#4.4x (actual).\n" , - dev->name, (start_page <<8 ) + count, addr); + (start_page <<8 ) + count, addr);if (retries++ ==0 ) goto retry; }
@@ -1340,8 +1337,7 @@ static void dma_block_output(struct net_device *dev, int count,while ((inb_p (nic_base +EN0_ISR ) &ENISR_RDC ) ==0 )if (time_after (jiffies, dma_start +PCNET_RDC_TIMEOUT )) { -printk (KERN_NOTICE "%s: timeout waiting for Tx RDC.\n" , - dev->name); +netdev_notice (dev,"timeout waiting for Tx RDC.\n" );pcnet_reset_8390 (dev);NS8390_init (dev,1 );break ;
Signature · 1 line
1.7.1
PATCH 1/1 pcnet_cs: Use pr_fmt and pr_<level>
It looks as if the printks in get_ax88190 are incorrect and were duplicated and superceded by a test in pcnet_config, so I removed them.
Changed the level of the ax88190 test to KERN_NOTICE to match the other message styles in pcnet_config.
Compiled but untested.
--- drivers/net/pcmcia/pcnet_cs.c | 26 +++++++++++++------------- 1 files changed, 13 insertions(+), 13 deletions(-)
drivers/net/pcmcia/pcnet_cs.c +13 -13
@@ -28,6 +28,8 @@======================================================================*/ +#define pr_fmt (fmt) KBUILD_MODNAME ": " fmt +#include <linux/kernel.h> #include <linux/module.h> #include <linux/init.h>
@@ -440,8 +442,6 @@ static hw_info_t *get_ax88190(struct pcmcia_device *link) dev->dev_addr[i] = j &0xff ; dev->dev_addr[i+1 ] = j >>8 ; } -printk (KERN_NOTICE "pcnet_cs: this is an AX88190 card!\n" ); -printk (KERN_NOTICE "pcnet_cs: use axnet_cs instead.\n" );return NULL ; }
@@ -574,15 +574,15 @@ static int pcnet_config(struct pcmcia_device *link)if ((if_port ==1 ) || (if_port ==2 )) dev->if_port = if_port;else -printk (KERN_NOTICE "pcnet_cs: invalid if_port requested\n" ); +pr_notice ("invalid if_port requested\n" ); }else { dev->if_port =0 ; }if ((link->conf.ConfigBase ==0x03c0 ) && (link->manf_id ==0x149 ) && (link->card_id ==0xc1ab )) { -printk (KERN_INFO "pcnet_cs: this is an AX88190 card!\n" ); -printk (KERN_INFO "pcnet_cs: use axnet_cs instead.\n" ); +pr_notice ("this is an AX88190 card!\n" ); +pr_notice ("use axnet_cs instead.\n" ); goto failed; }
@@ -597,8 +597,8 @@ static int pcnet_config(struct pcmcia_device *link) local_hw_info =get_hwired (link);if (local_hw_info ==NULL ) { -printk (KERN_NOTICE "pcnet_cs: unable to read hardware net" -" address for io base %#3lx\n" , dev->base_addr); +pr_notice ("unable to read hardware net address for io base %#3lx\n" , + dev->base_addr); goto failed; }
@@ -640,7 +640,7 @@ static int pcnet_config(struct pcmcia_device *link)SET_NETDEV_DEV (dev, &link->dev);if (register_netdev (dev) !=0 ) { -printk (KERN_NOTICE "pcnet_cs: register_netdev() failed\n" ); +pr_notice ("register_netdev() failed\n" ); goto failed; }
@@ -649,16 +649,16 @@ static int pcnet_config(struct pcmcia_device *link)netdev_info (dev,"NE2000 (DL100%d rev %02x): " , (info->flags &IS_DL10022 ) ?22 :19 , id);if (info->pna_phy) -printk ("PNA, " ); +pr_cont ("PNA, " ); }else {netdev_info (dev,"NE2000 Compatible: " ); } -printk ("io %#3lx, irq %d," , dev->base_addr, dev->irq); +pr_cont ("io %#3lx, irq %d," , dev->base_addr, dev->irq);if (info->flags &USE_SHMEM ) -printk (" mem %#5lx," , dev->mem_start); +pr_cont (" mem %#5lx," , dev->mem_start);if (info->flags &HAS_MISC_REG ) -printk (" %s xcvr," , if_names[dev->if_port]); -printk (" hw_addr %pM\n" , dev->dev_addr); +pr_cont (" %s xcvr," , if_names[dev->if_port]); +pr_cont (" hw_addr %pM\n" , dev->dev_addr);return 0 ; failed:
Quoted 8 lines · Wolfram Sang
To prevent broken messages like:
[ 204.024291] eth%d: pcnet_reset_8390() did not complete.Signed-off-by Wolfram Sang <[email protected]>Cc Dominik Brodowski <[email protected]>Cc Joe Perches <[email protected]>Cc David Miller <[email protected]>
and
Quoted 10 lines · Joe Perches
It looks as if the printks in
get_ax88190are incorrect and were duplicated and superceded by a test inpcnet_config, so I removed them.Changed the level of the ax88190 test to
KERN_NOTICEto match the other message styles inpcnet_config.Compiled but untested.
Signed-off-by Joe Perches <[email protected]>
look good from a PCMCIA point of view, therefore:
Thanks,
Dominik
PATCH 1/1 drivers/net/pcmcia: Use pr_<level> and netdev_<level>
Quoted 2 lines · Dominik Brodowski
look good from a PCMCIA point of view, therefore:
Signed-off-by Dominik Brodowski <[email protected]>
If PCMCIA is still being looked after, then here's another for you, maybe for 2.6.37.
Use the more descriptive logging message styles.
There are whitespace/indentation errors in the original sources that these changes do not modify, so checkpatch errors were cheerfully ignored.
--- drivers/net/pcmcia/3c574_cs.c | 73 ++++++++--------- drivers/net/pcmcia/3c589_cs.c | 13 ++-- drivers/net/pcmcia/axnet_cs.c | 164 ++++++++++++++++++++------------------ drivers/net/pcmcia/com20020_cs.c | 32 +++---- drivers/net/pcmcia/fmvj18x_cs.c | 60 +++++++------- drivers/net/pcmcia/ibmtr_cs.c | 13 ++-- drivers/net/pcmcia/nmclan_cs.c | 54 ++++++------- drivers/net/pcmcia/smc91c92_cs.c | 99 ++++++++++------------- drivers/net/pcmcia/xirc2ps_cs.c | 104 +++++++++++------------- 9 files changed, 298 insertions(+), 314 deletions(-)
drivers/net/pcmcia/3c574_cs.c +35 -38
@@ -69,6 +69,8 @@ earlier 3Com products.*/ +#define pr_fmt (fmt) KBUILD_MODNAME ": " fmt +#include <linux/module.h> #include <linux/kernel.h> #include <linux/init.h>
@@ -376,8 +378,8 @@ static int tc574_config(struct pcmcia_device *link)for (i =0 ; i <3 ; i++) phys_addr[i] =htons (read_eeprom (ioaddr, i +10 ));if (phys_addr[0 ] ==htons (0x6060 )) { -printk (KERN_NOTICE "3c574_cs: IO port conflict at 0x%03lx" -"-0x%03lx\n" , dev->base_addr, dev->base_addr+15 ); +pr_notice ("IO port conflict at 0x%03lx-0x%03lx\n" , + dev->base_addr, dev->base_addr+15 ); goto failed; } }
@@ -391,7 +393,7 @@ static int tc574_config(struct pcmcia_device *link)outw (2 <<11 , ioaddr + RunnerRdCtrl); mcr =inb (ioaddr +2 );outw (0 <<11 , ioaddr + RunnerRdCtrl); -printk (KERN_INFO " ASIC rev %d," , mcr>>3 ); +pr_info (" ASIC rev %d," , mcr>>3 );EL3WINDOW (3 ); config =inl (ioaddr + Wn3_Config); lp->default_media = (config & Xcvr) >> Xcvr_shift;
@@ -428,7 +430,7 @@ static int tc574_config(struct pcmcia_device *link) } }if (phy >32 ) { -printk (KERN_NOTICE " No MII transceivers found!\n" ); +pr_notice (" No MII transceivers found!\n" ); goto failed; } i =mdio_read (ioaddr, lp->phys,16 ) |0x40 ;
@@ -444,18 +446,16 @@ static int tc574_config(struct pcmcia_device *link)SET_NETDEV_DEV (dev, &link->dev);if (register_netdev (dev) !=0 ) { -printk (KERN_NOTICE "3c574_cs: register_netdev() failed\n" ); +pr_notice ("register_netdev() failed\n" ); goto failed; } -printk (KERN_INFO "%s: %s at io %#3lx, irq %d, " -"hw_addr %pM.\n" , - dev->name, cardname, dev->base_addr, dev->irq, - dev->dev_addr); -printk (" %dK FIFO split %s Rx:Tx, %sMII interface.\n" , -8 << config & Ram_size, - ram_split[(config & Ram_split) >> Ram_split_shift], - config & Autoselect ?"autoselect " :"" ); +netdev_info (dev,"%s at io %#3lx, irq %d, hw_addr %pM\n" , + cardname, dev->base_addr, dev->irq, dev->dev_addr); +netdev_info (dev," %dK FIFO split %s Rx:Tx, %sMII interface.\n" , +8 << config & Ram_size, + ram_split[(config & Ram_split) >> Ram_split_shift], + config & Autoselect ?"autoselect " :"" );return 0 ;
@@ -502,14 +502,14 @@ static void dump_status(struct net_device *dev) {unsigned int ioaddr = dev->base_addr;EL3WINDOW (1 ); -printk (KERN_INFO " irq status %04x, rx status %04x, tx status " -"%02x, tx free %04x\n" ,inw (ioaddr+EL3_STATUS ), -inw (ioaddr+RxStatus),inb (ioaddr+TxStatus), -inw (ioaddr+TxFree)); +netdev_info (dev," irq status %04x, rx status %04x, tx status %02x, tx free %04x\n" , +inw (ioaddr+EL3_STATUS ), +inw (ioaddr+RxStatus),inb (ioaddr+TxStatus), +inw (ioaddr+TxFree));EL3WINDOW (4 ); -printk (KERN_INFO " diagnostics: fifo %04x net %04x ethernet %04x" -" media %04x\n" ,inw (ioaddr+0x04 ),inw (ioaddr+0x06 ), -inw (ioaddr+0x08 ),inw (ioaddr+0x0a )); +netdev_info (dev," diagnostics: fifo %04x net %04x ethernet %04x media %04x\n" , +inw (ioaddr+0x04 ),inw (ioaddr+0x06 ), +inw (ioaddr+0x08 ),inw (ioaddr+0x0a ));EL3WINDOW (1 ); }
@@ -523,7 +523,7 @@ static void tc574_wait_for_completion(struct net_device *dev, int cmd)while (--i >0 )if (!(inw (dev->base_addr +EL3_STATUS ) &0x1000 ))break ;if (i ==0 ) -printk (KERN_NOTICE "%s: command 0x%04x did not complete!\n" , dev->name, cmd); +netdev_notice (dev,"command 0x%04x did not complete!\n" , cmd); }/* Read a word from the EEPROM using the regular EEPROM access register.
@@ -725,7 +725,7 @@ static void el3_tx_timeout(struct net_device *dev) {unsigned int ioaddr = dev->base_addr; -printk (KERN_NOTICE "%s: Transmit timed out!\n" , dev->name); +netdev_notice (dev,"Transmit timed out!\n" );dump_status (dev); dev->stats.tx_errors++; dev->trans_start = jiffies;/* prevent tx timeout */
@@ -848,8 +848,8 @@ static irqreturn_t el3_interrupt(int irq, void *dev_id)EL3WINDOW (4 ); fifo_diag =inw (ioaddr + Wn4_FIFODiag);EL3WINDOW (1 ); -printk (KERN_NOTICE "%s: adapter failure, FIFO diagnostic" -" register %04x.\n" , dev->name, fifo_diag); +netdev_notice (dev,"adapter failure, FIFO diagnostic register %04x\n" , + fifo_diag);if (fifo_diag &0x0400 ) {/* Tx overrun */ tc574_wait_for_completion (dev, TxReset);
@@ -903,7 +903,7 @@ static void media_check(unsigned long arg)this, we can limp along even if the interrupt is blocked */ if ((inw (ioaddr +EL3_STATUS ) & IntLatch) && (inb (ioaddr + Timer) ==0xff )) {if (!lp->fast_poll) -printk (KERN_INFO "%s: interrupt(s) dropped!\n" , dev->name); +netdev_info (dev,"interrupt(s) dropped!\n" );local_irq_save (flags);el3_interrupt (dev->irq, dev);
@@ -926,23 +926,21 @@ static void media_check(unsigned long arg)if (media != lp->media_status) {if ((media ^ lp->media_status) &0x0004 ) -printk (KERN_INFO "%s: %s link beat\n" , dev->name, - (lp->media_status &0x0004 ) ?"lost" :"found" ); +netdev_info (dev,"%s link beat\n" , + (lp->media_status &0x0004 ) ?"lost" :"found" );if ((media ^ lp->media_status) &0x0020 ) { lp->partner =0 ;if (lp->media_status &0x0020 ) { -printk (KERN_INFO "%s: autonegotiation restarted\n" , - dev->name); +netdev_info (dev,"autonegotiation restarted\n" ); }else if (partner) { partner &= lp->advertising; lp->partner = partner; -printk (KERN_INFO "%s: autonegotiation complete: " -"%sbaseT-%cD selected\n" , dev->name, - ((partner &0x0180 ) ?"100" :"10" ), - ((partner &0x0140 ) ?'F' :'H' )); +netdev_info (dev,"autonegotiation complete: " +"%dbaseT-%cD selected\n" , + (partner &0x0180 ) ?100 :10 , + (partner &0x0140 ) ?'F' :'H' ); }else { -printk (KERN_INFO "%s: link partner did not autonegotiate\n" , - dev->name); +netdev_info (dev,"link partner did not autonegotiate\n" ); }EL3WINDOW (3 );
@@ -952,10 +950,9 @@ static void media_check(unsigned long arg) }if (media &0x0010 ) -printk (KERN_INFO "%s: remote fault detected\n" , - dev->name); +netdev_info (dev,"remote fault detected\n" );if (media &0x0002 ) -printk (KERN_INFO "%s: jabber detected\n" , dev->name); +netdev_info (dev,"jabber detected\n" ); lp->media_status = media; }spin_unlock_irqrestore (&lp->window_lock, flags);
drivers/net/pcmcia/3c589_cs.c +7 -6
@@ -19,6 +19,8 @@======================================================================*/ +#define pr_fmt (fmt) KBUILD_MODNAME ": " fmt +#define DRV_NAME "3c589_cs"#define DRV_VERSION "1.162-ac"
@@ -274,8 +276,7 @@ static int tc589_config(struct pcmcia_device *link) phys_addr = (__be16 *)dev->dev_addr;/* Is this a 3c562? */ if (link->manf_id !=MANFID_3COM ) -printk (KERN_INFO "3c589_cs: hmmm, is this really a " -"3Com card??\n" ); +dev_info (&link->dev,"hmmm, is this really a 3Com card??\n" ); multi = (link->card_id ==PRODID_3COM_3C562 );/* For the 3c562, the base address must be xx00-xx7f */
@@ -315,8 +316,8 @@ static int tc589_config(struct pcmcia_device *link)for (i =0 ; i <3 ; i++) phys_addr[i] =htons (read_eeprom (ioaddr, i));if (phys_addr[0 ] ==htons (0x6060 )) { -printk (KERN_ERR "3c589_cs: IO port conflict at 0x%03lx" -"-0x%03lx\n" , dev->base_addr, dev->base_addr+15 ); +dev_err (&link->dev,"IO port conflict at 0x%03lx-0x%03lx\n" , + dev->base_addr, dev->base_addr+15 ); goto failed; } }
@@ -330,12 +331,12 @@ static int tc589_config(struct pcmcia_device *link)if ((if_port >=0 ) && (if_port <=3 )) dev->if_port = if_port;else -printk (KERN_ERR "3c589_cs: invalid if_port requested\n" ); +dev_err (&link->dev,"invalid if_port requested\n" );SET_NETDEV_DEV (dev, &link->dev);if (register_netdev (dev) !=0 ) { -printk (KERN_ERR "3c589_cs: register_netdev() failed\n" ); +dev_err (&link->dev,"register_netdev() failed\n" ); goto failed; }
drivers/net/pcmcia/axnet_cs.c +88 -76
348 lines not on this page · raw message
drivers/net/pcmcia/com20020_cs.c +14 -18
@@ -53,23 +53,23 @@#define VERSION "arcnet: COM20020 PCMCIA support loaded.\n" -#ifdef DEBUG static void regdump (struct net_device *dev) { +#ifdef DEBUG int ioaddr = dev->base_addr;int count; -printk ("com20020 register dump:\n" ); +netdev_dbg (dev,"register dump:\n" );for (count = ioaddr; count < ioaddr +16 ; count++) {if (!(count %16 )) -printk ("\n%04X: " , count); -printk ("%02X " ,inb (count)); +pr_cont ("%04X:" , count); +pr_cont (" %02X" ,inb (count)); } -printk ("\n" ); +pr_cont ("\n" ); -printk ("buffer0 dump:\n" ); +netdev_dbg (dev,"buffer0 dump:\n" );/* set up the address register */ count =0 ;outb ((count >>8 ) | RDDATAflag | AUTOINCflag, _ADDR_HI);
@@ -78,19 +78,15 @@ static void regdump(struct net_device *dev)for (count =0 ; count <256 +32 ; count++) {if (!(count %16 )) -printk ("\n%04X: " , count); +pr_cont ("%04X:" , count);/* copy the data */ -printk ("%02X " ,inb (_MEMDATA)); +pr_cont (" %02X" ,inb (_MEMDATA)); } - printk("\n"); +pr_cont ("\n" ); +#endif } -#else - -static inline void regdump (struct net_device *dev) { } - -#endif /*====================================================================*/
@@ -299,13 +295,13 @@ static int com20020_config(struct pcmcia_device *link) i =com20020_found (dev,0 );/* calls register_netdev */ if (i !=0 ) { -dev_printk (KERN_NOTICE , &link->dev, -"com20020_cs: com20020_found() failed\n" ); +dev_notice (&link->dev, +"com20020_found() failed\n" ); goto failed; } -dev_dbg (&link->dev,KERN_INFO "%s: port %#3lx, irq %d\n" , - dev->name, dev->base_addr, dev->irq); +netdev_dbg (dev,"port %#3lx, irq %d\n" , + dev->base_addr, dev->irq);return 0 ; failed:
drivers/net/pcmcia/fmvj18x_cs.c +30 -30
133 lines not on this page · raw message
drivers/net/pcmcia/ibmtr_cs.c +7 -6
@@ -45,6 +45,8 @@======================================================================*/ +#define pr_fmt (fmt) KBUILD_MODNAME ": " fmt +#include <linux/kernel.h> #include <linux/init.h> #include <linux/ptrace.h>
@@ -291,15 +293,14 @@ static int __devinit ibmtr_config(struct pcmcia_device *link) i =ibmtr_probe_card (dev);if (i !=0 ) { -printk (KERN_NOTICE "ibmtr_cs: register_netdev() failed\n" ); +pr_notice ("register_netdev() failed\n" ); goto failed; } -printk (KERN_INFO -"%s: port %#3lx, irq %d, mmio %#5lx, sram %#5lx, hwaddr=%pM\n" , - dev->name, dev->base_addr, dev->irq, - (u_long )ti->mmio, (u_long)(ti->sram_base <<12 ), - dev->dev_addr); +netdev_info (dev,"port %#3lx, irq %d, mmio %#5lx, sram %#5lx, hwaddr=%pM\n" , + dev->base_addr, dev->irq, + (u_long )ti->mmio, (u_long)(ti->sram_base <<12 ), + dev->dev_addr);return 0 ; failed:
drivers/net/pcmcia/nmclan_cs.c +26 -28
124 lines not on this page · raw message
drivers/net/pcmcia/smc91c92_cs.c +45 -54
250 lines not on this page · raw message
drivers/net/pcmcia/xirc2ps_cs.c +46 -58
269 lines not on this page · raw message
Signature · 1 line
1.7.2.19.g9a302
MAINTAINERS: PCMCIA SUBSYSTEM: Should F: drivers/net/pcmcia/ be added?
Quoted 3 lines · Joe Perches
Quoted 2 lines · Dominik Brodowski
look good from a PCMCIA point of view, therefore:
Signed-off-by Dominik Brodowski <[email protected]>
There's no maintainer entry for directory drivers/net/pcmcia/
Should
F: drivers/net/pcmcia/
be added to the existing PCMCIA SUBSYSTEM entry?
Re: MAINTAINERS: PCMCIA SUBSYSTEM: Should F: drivers/net/pcmcia/ be added?
Hey,
Quoted 5 lines · Joe Perches
Quoted 3 lines · Joe Perches
Quoted 2 lines · Dominik Brodowski
look good from a PCMCIA point of view, therefore:
Signed-off-by Dominik Brodowski <[email protected]>
Quoted 7 lines
There's no maintainer entry for directory
drivers/net/pcmcia/Should
F:
drivers/net/pcmcia/be added to the existing PCMCIA SUBSYSTEM entry?
in my opinion, no -- this entry is mostly about the PCMCIA core, not about specific drivers, same as the PCI bus guys aren't maintaining each and every PCI driver...
Best,
Dominik
Re: [PATCH net-next 2.6.37?] drivers/net/pcmcia: Use pr_<level> and netdev_<level>
In reply to Joe PerchesQuoted 6 lines · Joe Perches
Quoted 2 lines · Dominik Brodowski
look good from a PCMCIA point of view, therefore:
Signed-off-by Dominik Brodowski <[email protected]>If PCMCIA is still being looked after, then here's another for you, maybe for 2.6.37.
Well, as this is netdev-related, shouldn't it go in via netdev instead? David?
Quoted 7 lines
Use the more descriptive logging message styles.
There are whitespace/indentation errors in the original sources that these changes do not modify, so checkpatch errors were cheerfully ignored.
Signed-off-by Joe Perches <[email protected]>
Acked-by / Signed-off-by: Dominik Brodowski <[email protected]>
Re: [PATCH net-next 2.6.37?] drivers/net/pcmcia: Use pr_<level> and netdev_<level>
In reply to Joe PerchesFrom: Joe Perches <[email protected]>
Date: Thu, 12 Aug 2010 15:22:51 -0700
Quoted 7 lines · Dominik Brodowski
Quoted 2 lines
look good from a PCMCIA point of view, therefore:
Signed-off-by Dominik Brodowski <[email protected]>If PCMCIA is still being looked after, then here's another for you, maybe for 2.6.37.
Quoted 7 lines
Use the more descriptive logging message styles.
There are whitespace/indentation errors in the original sources that these changes do not modify, so checkpatch errors were cheerfully ignored.
Signed-off-by Joe Perches <[email protected]>
Applied.
Re: [PATCH] pcnet_cs: Use pr_fmt and pr_<level>
In reply to Joe PerchesFrom: Joe Perches <[email protected]>
Date: Sun, 08 Aug 2010 07:50:36 -0700
Quoted 10 lines
It looks as if the printks in
get_ax88190are incorrect and were duplicated and superceded by a test inpcnet_config, so I removed them.Changed the level of the ax88190 test to
KERN_NOTICEto match the other message styles inpcnet_config.Compiled but untested.
Signed-off-by Joe Perches <[email protected]>
Applied.
From: Wolfram Sang <[email protected]>
Date: Sun, 8 Aug 2010 14:32:05 +0200
Quoted 5 lines
To prevent broken messages like:
[ 204.024291] eth%d: pcnet_reset_8390() did not complete.Signed-off-by Wolfram Sang <[email protected]>
Applied.