netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Rob Herring <rob.herring@calxeda.com>
To: Jingoo Han <jg1.han@samsung.com>
Cc: "'David S. Miller'" <davem@davemloft.net>,
	netdev@vger.kernel.org, Dan Carpenter <dan.carpenter@oracle.com>
Subject: Re: [PATCH 10/36] net: ethernet: calxeda: remove unnecessary platform_set_drvdata()
Date: Tue, 07 May 2013 09:49:50 -0500	[thread overview]
Message-ID: <5189148E.3040603@calxeda.com> (raw)
In-Reply-To: <001a01ce4ada$e498ace0$adca06a0$@samsung.com>

On 05/06/2013 11:25 PM, Jingoo Han wrote:
> The driver core clears the driver data to NULL after device_release
> or on probe failure, since commit 0998d0631001288a5974afc0b2a5f568bcdecb4d
> (device-core: Ensure drvdata = NULL when no driver is bound).
> Thus, it is not needed to manually clear the device driver data to NULL.
> 
> Signed-off-by: Jingoo Han <jg1.han@samsung.com>

netdev is closed during the merge window except for fixes, so you will
have to resubmit this. But when you do:

Acked-by: Rob Herring <rob.herring@calxeda.com>

> ---
>  drivers/net/ethernet/calxeda/xgmac.c |    2 --
>  1 files changed, 0 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/net/ethernet/calxeda/xgmac.c b/drivers/net/ethernet/calxeda/xgmac.c
> index 4a1f2fa..7cb148c 100644
> --- a/drivers/net/ethernet/calxeda/xgmac.c
> +++ b/drivers/net/ethernet/calxeda/xgmac.c
> @@ -1790,7 +1790,6 @@ err_io:
>  	free_netdev(ndev);
>  err_alloc:
>  	release_mem_region(res->start, resource_size(res));
> -	platform_set_drvdata(pdev, NULL);
>  	return ret;
>  }
>  
> @@ -1813,7 +1812,6 @@ static int xgmac_remove(struct platform_device *pdev)
>  	free_irq(ndev->irq, ndev);
>  	free_irq(priv->pmt_irq, ndev);
>  
> -	platform_set_drvdata(pdev, NULL);
>  	unregister_netdev(ndev);
>  	netif_napi_del(&priv->napi);
>  
> 

      reply	other threads:[~2013-05-07 14:58 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-05-07  4:25 [PATCH 10/36] net: ethernet: calxeda: remove unnecessary platform_set_drvdata() Jingoo Han
2013-05-07 14:49 ` Rob Herring [this message]

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=5189148E.3040603@calxeda.com \
    --to=rob.herring@calxeda.com \
    --cc=dan.carpenter@oracle.com \
    --cc=davem@davemloft.net \
    --cc=jg1.han@samsung.com \
    --cc=netdev@vger.kernel.org \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).