[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <48CC14B7.5090304@garzik.org>
Date: Sat, 13 Sep 2008 15:29:59 -0400
From: Jeff Garzik <jeff@...zik.org>
To: Florian Fainelli <florian.fainelli@...ecomint.eu>
CC: Francois Romieu <romieu@...zoreil.com>, netdev@...r.kernel.org
Subject: Re: [PATCH resend] r6040: fix bad usage of udelay
Florian Fainelli wrote:
> Hi Francois, Jeff,
>
> This patch applies to the patch sent previously entitled :
> [PATCH] r6040: remove unused includes.
>
> Thanks.
> --
> From: Florian Fainelli <florian.fainelli@...ecomint.eu>
> Subject: [PATCH resend] r6040: fix bad usage of udelay
>
> This patch fixes the bad usage of udelay(5000), which in turns is a
> mdelay(5). It causes compilation for ARM where udelay maximum value
> is checked.
>
> Reported-by: Martin Michlmayr <tbm@...ius.com>
> Signed-off-by: Florian Fainelli <florian.fainelli@...ecomint.eu>
> ---
> diff --git a/drivers/net/r6040.c b/drivers/net/r6040.c
> index d453987..d837bef 100644
> --- a/drivers/net/r6040.c
> +++ b/drivers/net/r6040.c
> @@ -364,7 +364,7 @@ static void r6040_init_mac_regs(struct net_device *dev)
> /* Reset internal state machine */
> iowrite16(2, ioaddr + MAC_SM);
> iowrite16(0, ioaddr + MAC_SM);
> - udelay(5000);
> + mdelay(5);
>
> /* MAC Bus Control Register */
> iowrite16(MBCR_DEFAULT, ioaddr + MBCR);
> @@ -800,7 +800,7 @@ static void r6040_mac_address(struct net_device *dev)
> iowrite16(0x01, ioaddr + MCR1); /* Reset MAC */
> iowrite16(2, ioaddr + MAC_SM); /* Reset internal state machine */
> iowrite16(0, ioaddr + MAC_SM);
> - udelay(5000);
> + mdelay(5);
>
> /* Restore MAC Address */
applied
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists