Re: [PATCH] de2104x: disable media debug messages by default

From: Michał Mirosław
Date: Thu Sep 30 2010 - 05:46:54 EST


2010/9/28 Ondrej Zary <linux@xxxxxxxxxxxxxxxxxxxx>:
> Print media debug messages only when HW debug is enabled.
>
> Signed-off-by: Ondrej Zary <linux@xxxxxxxxxxxxxxxxxxxx>
>
> --- linux-2.6.36-rc3-/drivers/net/tulip/de2104x.c       2010-09-28 19:50:51.000000000 +0200
> +++ linux-2.6.36-rc3/drivers/net/tulip/de2104x.c        2010-09-28 20:05:34.000000000 +0200
> @@ -948,8 +948,9 @@ static void de_set_media (struct de_priv
>        else
>                macmode &= ~FullDuplex;
>
> -       if (netif_msg_link(de)) {
> +       if (netif_msg_link(de))
>                dev_info(&de->dev->dev, "set link %s\n", media_name[media]);

You can use netif_info(de, link, de->dev, ...) instead and get 'ethX:
' prefix for free.

> +       if (netif_msg_hw(de)) {
>                dev_info(&de->dev->dev, "mode 0x%x, sia 0x%x,0x%x,0x%x,0x%x\n",
>                         dr32(MacMode), dr32(SIAStatus),
>                         dr32(CSR13), dr32(CSR14), dr32(CSR15));

Same here.

Best Regards,
Michał Mirosław
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/