Re: [PATCH net-next 2/3] drivers/net/bfin_mac.c: Use pr_<level>, netdev_<level>

From: Mike Frysinger
Date: Thu Jul 29 2010 - 20:17:46 EST


On Thu, Jul 29, 2010 at 19:58, Joe Perches wrote:
> Add and use pr_fmt, pr_<level> and netdev_<level>

your changelog says add pr_fmt, but i dont see it in the patch ...

> @@ -833,8 +830,7 @@ static void bfin_tx_hwtstamp(struct net_device *netdev, struct sk_buff *skb)
> Â Â Â Â Â Â Â Â Â Â Â (--timeout_cnt))
> Â Â Â Â Â Â Â Â Â Â Â Âudelay(1);
> Â Â Â Â Â Â Â Âif (timeout_cnt == 0)
> - Â Â Â Â Â Â Â Â Â Â Â printk(KERN_ERR DRV_NAME
> - Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â ": fails to timestamp the TX packet\n");
> + Â Â Â Â Â Â Â Â Â Â Â pr_err("failed to timestamp the TX packet\n");

this func has a net_device, so cant you use netdev_err here ?

> @@ -1102,8 +1097,7 @@ static void bfin_mac_rx(struct net_device *dev)
>
> Â Â Â Ânew_skb = dev_alloc_skb(PKT_BUF_SZ + NET_IP_ALIGN);
> Â Â Â Âif (!new_skb) {
> - Â Â Â Â Â Â Â printk(KERN_NOTICE DRV_NAME
> - Â Â Â Â Â Â Â Â Â Â Â": rx: low on mem - packet dropped\n");
> + Â Â Â Â Â Â Â pr_notice("rx: low on mem - packet dropped\n");

same here

otherwise this patch looks good
-mike
N‹§²æìr¸›yúèšØb²X¬¶ÇvØ^–)Þ{.nÇ+‰·¥Š{±‘êçzX§¶›¡Ü}©ž²ÆzÚ&j:+v‰¨¾«‘êçzZ+€Ê+zf£¢·hšˆ§~†­†Ûiÿûàz¹®w¥¢¸?™¨è­Ú&¢)ßf”ù^jÇy§m…á@A«a¶Úÿ 0¶ìh®å’i