linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
From: f.fainelli@gmail.com (Florian Fainelli)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 5/7] net: ethernet: bgmac: Add platform device support
Date: Thu, 30 Jun 2016 16:26:00 -0700	[thread overview]
Message-ID: <5775AA88.60800@gmail.com> (raw)
In-Reply-To: <1467327554-22074-6-git-send-email-jon.mason@broadcom.com>

[snip]

+
> +	return 0;
> +
> +err2:
> +	devm_iounmap(&pdev->dev, bgmac->plat.idm_base);
> +err1:
> +	devm_iounmap(&pdev->dev, bgmac->plat.base);
> +err:
> +	devm_kfree(&pdev->dev, bgmac);


This is not needed actually, now that you use the device managed helper
functions.

> +
> +	return rc;
> +}
> +
> +static int bgmac_remove(struct platform_device *pdev)
> +{
> +	struct bgmac *bgmac = platform_get_drvdata(pdev);
> +
> +	bgmac_enet_remove(bgmac);
> +	devm_iounmap(&pdev->dev, bgmac->plat.idm_base);
> +	devm_iounmap(&pdev->dev, bgmac->plat.base);
> +	devm_kfree(&pdev->dev, bgmac);

Same here.
-- 
Florian

  reply	other threads:[~2016-06-30 23:26 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-06-30 22:59 [PATCH 0/7] net: ethernet: bgmac: Add platform device support Jon Mason
2016-06-30 22:59 ` [PATCH 1/7] net: ethernet: bgmac: change bgmac_* prints to dev_* prints Jon Mason
2016-06-30 22:59 ` [PATCH 2/7] net: ethernet: bgmac: add dma_dev pointer Jon Mason
2016-06-30 22:59 ` [PATCH 3/7] net: ethernet: bgmac: move BCMA MDIO Phy code into a separate file Jon Mason
2016-06-30 22:59 ` [PATCH 4/7] net: ethernet: bgmac: convert to feature flags Jon Mason
2016-06-30 22:59 ` [PATCH 5/7] net: ethernet: bgmac: Add platform device support Jon Mason
2016-06-30 23:26   ` Florian Fainelli [this message]
2016-06-30 22:59 ` [PATCH 6/7] dt-bindings: net: bgmac: add bindings documentation for bgmac Jon Mason
2016-07-01  2:56   ` Rob Herring
2016-07-01 14:29     ` Jon Mason
2016-07-01  9:46   ` Arnd Bergmann
2016-07-01 15:17     ` Jon Mason
2016-07-01 15:42       ` Arnd Bergmann
2016-07-04 16:34         ` Ray Jui
2016-07-05 13:37           ` Arnd Bergmann
2016-07-05 23:18             ` Jon Mason
2016-07-06  7:34               ` Arnd Bergmann
2016-07-07 22:42                 ` Jon Mason
2016-06-30 22:59 ` [PATCH 7/7] ARM: dts: NSP: Add bgmac entries Jon Mason
2016-07-01  9:49 ` [PATCH 0/7] net: ethernet: bgmac: Add platform device support Arnd Bergmann

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=5775AA88.60800@gmail.com \
    --to=f.fainelli@gmail.com \
    --cc=linux-arm-kernel@lists.infradead.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).