All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jeff Garzik <jgarzik@pobox.com>
To: Francois Romieu <romieu@fr.zoreil.com>
Cc: Julia Lawall <julia@diku.dk>,
	netdev@vger.kernel.org, linux-kernel@vger.kernel.org,
	kernel-janitors@vger.kernel.org
Subject: Re: [PATCH] au1000_eth: remove useless check
Date: Thu, 22 May 2008 10:22:22 +0000	[thread overview]
Message-ID: <4835495E.8020506@pobox.com> (raw)
In-Reply-To: <20080512164421.GB22190@electric-eye.fr.zoreil.com>

Francois Romieu wrote:
> The lifespan of the device covers the request_irq .. free_irq interval.
> 
> The cast of a void * pointer is not needed either.
> 
> Signed-off-by: Francois Romieu <romieu@fr.zoreil.com>
> 
> diff --git a/drivers/net/au1000_eth.c b/drivers/net/au1000_eth.c
> index 3634b5f..7023d77 100644
> --- a/drivers/net/au1000_eth.c
> +++ b/drivers/net/au1000_eth.c
> @@ -1239,12 +1239,7 @@ static int au1000_rx(struct net_device *dev)
>   */
>  static irqreturn_t au1000_interrupt(int irq, void *dev_id)
>  {
> -	struct net_device *dev = (struct net_device *) dev_id;
> -
> -	if (dev = NULL) {
> -		printk(KERN_ERR "%s: isr: null dev ptr\n", dev->name);
> -		return IRQ_RETVAL(1);
> -	}
> +	struct net_device *dev = dev_id;
>  

applied



WARNING: multiple messages have this Message-ID (diff)
From: Jeff Garzik <jgarzik@pobox.com>
To: Francois Romieu <romieu@fr.zoreil.com>
Cc: Julia Lawall <julia@diku.dk>,
	netdev@vger.kernel.org, linux-kernel@vger.kernel.org,
	kernel-janitors@vger.kernel.org
Subject: Re: [PATCH] au1000_eth: remove useless check
Date: Thu, 22 May 2008 06:22:22 -0400	[thread overview]
Message-ID: <4835495E.8020506@pobox.com> (raw)
In-Reply-To: <20080512164421.GB22190@electric-eye.fr.zoreil.com>

Francois Romieu wrote:
> The lifespan of the device covers the request_irq .. free_irq interval.
> 
> The cast of a void * pointer is not needed either.
> 
> Signed-off-by: Francois Romieu <romieu@fr.zoreil.com>
> 
> diff --git a/drivers/net/au1000_eth.c b/drivers/net/au1000_eth.c
> index 3634b5f..7023d77 100644
> --- a/drivers/net/au1000_eth.c
> +++ b/drivers/net/au1000_eth.c
> @@ -1239,12 +1239,7 @@ static int au1000_rx(struct net_device *dev)
>   */
>  static irqreturn_t au1000_interrupt(int irq, void *dev_id)
>  {
> -	struct net_device *dev = (struct net_device *) dev_id;
> -
> -	if (dev == NULL) {
> -		printk(KERN_ERR "%s: isr: null dev ptr\n", dev->name);
> -		return IRQ_RETVAL(1);
> -	}
> +	struct net_device *dev = dev_id;
>  

applied



  reply	other threads:[~2008-05-22 10:22 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-05-12 13:37 [PATCH 3/6] drivers/net: remove null pointer dereference Julia Lawall
2008-05-12 13:37 ` Julia Lawall
2008-05-12 16:17 ` Francois Romieu
2008-05-12 16:17   ` Francois Romieu
2008-05-12 16:53   ` Julia Lawall
2008-05-12 16:53     ` Julia Lawall
2008-05-12 16:44     ` [PATCH] au1000_eth: remove useless check Francois Romieu
2008-05-12 16:44       ` Francois Romieu
2008-05-22 10:22       ` Jeff Garzik [this message]
2008-05-22 10:22         ` Jeff Garzik
2008-05-12 17:06     ` [PATCH 3/6] drivers/net: remove null pointer dereference Jeff Garzik
2008-05-12 17:06       ` Jeff Garzik
2008-05-12 18:48       ` Julia Lawall
2008-05-12 18:48         ` Julia Lawall

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4835495E.8020506@pobox.com \
    --to=jgarzik@pobox.com \
    --cc=julia@diku.dk \
    --cc=kernel-janitors@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=romieu@fr.zoreil.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.