<feed xmlns='http://www.w3.org/2005/Atom'>
<title>wireguard-linux/drivers/net/ethernet/broadcom/bgmac-platform.c, branch jd/orphan-parallel</title>
<subtitle>WireGuard for the Linux kernel</subtitle>
<id>https://git.zx2c4.com/wireguard-linux/atom/drivers/net/ethernet/broadcom/bgmac-platform.c?h=jd%2Forphan-parallel</id>
<link rel='self' href='https://git.zx2c4.com/wireguard-linux/atom/drivers/net/ethernet/broadcom/bgmac-platform.c?h=jd%2Forphan-parallel'/>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/wireguard-linux/'/>
<updated>2020-08-23T22:36:59Z</updated>
<entry>
<title>treewide: Use fallthrough pseudo-keyword</title>
<updated>2020-08-23T22:36:59Z</updated>
<author>
<name>Gustavo A. R. Silva</name>
<email>gustavoars@kernel.org</email>
</author>
<published>2020-08-23T22:36:59Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/wireguard-linux/commit/?id=df561f6688fef775baa341a0f5d960becd248b11'/>
<id>urn:sha1:df561f6688fef775baa341a0f5d960becd248b11</id>
<content type='text'>
Replace the existing /* fall through */ comments and its variants with
the new pseudo-keyword macro fallthrough[1]. Also, remove unnecessary
fall-through markings when it is the case.

[1] https://www.kernel.org/doc/html/v5.7/process/deprecated.html?highlight=fallthrough#implicit-switch-case-fall-through

Signed-off-by: Gustavo A. R. Silva &lt;gustavoars@kernel.org&gt;
</content>
</entry>
<entry>
<title>net: broadcom: fix a mistake about ioremap resource</title>
<updated>2020-05-05T18:11:12Z</updated>
<author>
<name>Dejin Zheng</name>
<email>zhengdejin5@gmail.com</email>
</author>
<published>2020-05-05T02:03:29Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/wireguard-linux/commit/?id=755f5738ff981769211a0bfac709d514ef5b9f86'/>
<id>urn:sha1:755f5738ff981769211a0bfac709d514ef5b9f86</id>
<content type='text'>
Commit d7a5502b0bb8b ("net: broadcom: convert to
devm_platform_ioremap_resource_byname()") will broke this driver.
idm_base and nicpm_base were optional, after this change, they are
mandatory. it will probe fails with -22 when the dtb doesn't have them
defined. so revert part of this commit and make idm_base and nicpm_base
as optional.

Fixes: d7a5502b0bb8bde ("net: broadcom: convert to devm_platform_ioremap_resource_byname()")
Reported-by: Jonathan Richardson &lt;jonathan.richardson@broadcom.com&gt;
Cc: Scott Branden &lt;scott.branden@broadcom.com&gt;
Cc: Ray Jui &lt;ray.jui@broadcom.com&gt;
Cc: Florian Fainelli &lt;f.fainelli@gmail.com&gt;
Cc: David S. Miller &lt;davem@davemloft.net&gt;
Signed-off-by: Dejin Zheng &lt;zhengdejin5@gmail.com&gt;
Acked-by: Florian Fainelli &lt;f.fainelli@gmail.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>net: broadcom: convert to devm_platform_ioremap_resource_byname()</title>
<updated>2020-04-21T22:53:54Z</updated>
<author>
<name>Dejin Zheng</name>
<email>zhengdejin5@gmail.com</email>
</author>
<published>2020-04-20T15:06:41Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/wireguard-linux/commit/?id=d7a5502b0bb8bde54973a2ee73e7bd72e6cb195c'/>
<id>urn:sha1:d7a5502b0bb8bde54973a2ee73e7bd72e6cb195c</id>
<content type='text'>
Use the function devm_platform_ioremap_resource_byname() to simplify
source code which calls the functions platform_get_resource_byname()
and devm_ioremap_resource(). Remove also a few error messages which
became unnecessary with this software refactoring.

Suggested-by: Markus Elfring &lt;Markus.Elfring@web.de&gt;
Signed-off-by: Dejin Zheng &lt;zhengdejin5@gmail.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>net: Remove dev_err() usage after platform_get_irq()</title>
<updated>2019-07-30T21:37:35Z</updated>
<author>
<name>Stephen Boyd</name>
<email>swboyd@chromium.org</email>
</author>
<published>2019-07-30T18:15:51Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/wireguard-linux/commit/?id=d1a55841ab24c6d1e4087e5c285601a9dffb8641'/>
<id>urn:sha1:d1a55841ab24c6d1e4087e5c285601a9dffb8641</id>
<content type='text'>
We don't need dev_err() messages when platform_get_irq() fails now that
platform_get_irq() prints an error message itself when something goes
wrong. Let's remove these prints with a simple semantic patch.

// &lt;smpl&gt;
@@
expression ret;
struct platform_device *E;
@@

ret =
(
platform_get_irq(E, ...)
|
platform_get_irq_byname(E, ...)
);

if ( \( ret &lt; 0 \| ret &lt;= 0 \) )
{
(
-if (ret != -EPROBE_DEFER)
-{ ...
-dev_err(...);
-... }
|
...
-dev_err(...);
)
...
}
// &lt;/smpl&gt;

While we're here, remove braces on if statements that only have one
statement (manually).

Cc: "David S. Miller" &lt;davem@davemloft.net&gt;
Cc: Kalle Valo &lt;kvalo@codeaurora.org&gt;
Cc: Saeed Mahameed &lt;saeedm@mellanox.com&gt;
Cc: Jeff Kirsher &lt;jeffrey.t.kirsher@intel.com&gt;
Cc: Felix Fietkau &lt;nbd@nbd.name&gt;
Cc: Lorenzo Bianconi &lt;lorenzo@kernel.org&gt;
Cc: netdev@vger.kernel.org
Cc: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
Signed-off-by: Stephen Boyd &lt;swboyd@chromium.org&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>net: ethernet: support of_get_mac_address new ERR_PTR error</title>
<updated>2019-05-07T19:22:47Z</updated>
<author>
<name>Petr Štetiar</name>
<email>ynezz@true.cz</email>
</author>
<published>2019-05-06T21:27:04Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/wireguard-linux/commit/?id=a51645f70f6384ae3329551750f7f502cb8de5fc'/>
<id>urn:sha1:a51645f70f6384ae3329551750f7f502cb8de5fc</id>
<content type='text'>
There was NVMEM support added to of_get_mac_address, so it could now
return ERR_PTR encoded error values, so we need to adjust all current
users of of_get_mac_address to this new fact.

While at it, remove superfluous is_valid_ether_addr as the MAC address
returned from of_get_mac_address is always valid and checked by
is_valid_ether_addr anyway.

Fixes: d01f449c008a ("of_net: add NVMEM support to of_get_mac_address")
Signed-off-by: Petr Štetiar &lt;ynezz@true.cz&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>net: ethernet: bgmac: mark expected switch fall-through</title>
<updated>2017-11-11T09:49:26Z</updated>
<author>
<name>Gustavo A. R. Silva</name>
<email>garsilva@embeddedor.com</email>
</author>
<published>2017-11-08T17:24:57Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/wireguard-linux/commit/?id=d9b9c0e027c93160c94dae07b6d29acc5cdd6d54'/>
<id>urn:sha1:d9b9c0e027c93160c94dae07b6d29acc5cdd6d54</id>
<content type='text'>
In preparation to enabling -Wimplicit-fallthrough, mark switch cases
where we are expecting to fall through.

Addresses-Coverity-ID: 1397972
Signed-off-by: Gustavo A. R. Silva &lt;garsilva@embeddedor.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>net: ethernet: bgmac: Make IDM register space optional</title>
<updated>2017-07-15T21:28:27Z</updated>
<author>
<name>Abhishek Shah</name>
<email>abhishek.shah@broadcom.com</email>
</author>
<published>2017-07-13T19:04:08Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/wireguard-linux/commit/?id=a163bdb02beb7df8b2768ce7c74a2b17803c96f9'/>
<id>urn:sha1:a163bdb02beb7df8b2768ce7c74a2b17803c96f9</id>
<content type='text'>
IDM operations are usually one time ops and should be done in
firmware itself. Driver is not supposed to touch IDM registers.

However, for some SoCs', driver is performing IDM read/writes.
So this patch masks IDM operations in case firmware is taking
care of IDM operations.

Signed-off-by: Abhishek Shah &lt;abhishek.shah@broadcom.com&gt;
Reviewed-by: Oza Oza &lt;oza.oza@broadcom.com&gt;
Reviewed-by: Ray Jui &lt;ray.jui@broadcom.com&gt;
Reviewed-by: Scott Branden &lt;scott.branden@broadcom.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>net: ethernet: bgmac: Remove unnecessary 'return' from platform_bgmac_idm_write</title>
<updated>2017-07-15T21:28:27Z</updated>
<author>
<name>Abhishek Shah</name>
<email>abhishek.shah@broadcom.com</email>
</author>
<published>2017-07-13T19:04:07Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/wireguard-linux/commit/?id=83a5c5af26ef8005caebd50ce62383a02c5bae82'/>
<id>urn:sha1:83a5c5af26ef8005caebd50ce62383a02c5bae82</id>
<content type='text'>
Return type for idm register write callback should be void as 'writel'
API is used for write operation. However, there no need to have 'return'
in this function.

Signed-off-by: Abhishek Shah &lt;abhishek.shah@broadcom.com&gt;
Reviewed-by: Oza Oza &lt;oza.oza@broadcom.com&gt;
Reviewed-by: Ray Jui &lt;ray.jui@broadcom.com&gt;
Reviewed-by: Scott Branden &lt;scott.branden@broadcom.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>net: ethernet: bgmac: driver power manangement</title>
<updated>2017-03-07T01:17:47Z</updated>
<author>
<name>Joey Zhong</name>
<email>zhongx@broadcom.com</email>
</author>
<published>2017-02-28T18:51:01Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/wireguard-linux/commit/?id=f3537b3494c06a98a8636c375b6d7a5060c5ac2d'/>
<id>urn:sha1:f3537b3494c06a98a8636c375b6d7a5060c5ac2d</id>
<content type='text'>
Implement suspend/resume callbacks in the bgmac driver. This makes sure
that we de-initialize and re-initialize the hardware correctly before
entering suspend and when resuming.

Signed-off-by: Joey Zhong &lt;zhongx@broadcom.com&gt;
Signed-off-by: Jon Mason &lt;jon.mason@broadcom.com&gt;
Reviewed-by: Florian Fainelli &lt;f.fainelli@gmail.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>net: ethernet: bgmac: init sequence bug</title>
<updated>2017-03-03T17:44:28Z</updated>
<author>
<name>Jon Mason</name>
<email>jon.mason@broadcom.com</email>
</author>
<published>2017-03-02T22:59:56Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/wireguard-linux/commit/?id=16206524f6ea57d6dcd56fe46f9f4a06d4a1b113'/>
<id>urn:sha1:16206524f6ea57d6dcd56fe46f9f4a06d4a1b113</id>
<content type='text'>
Fix a bug in the 'bgmac' driver init sequence that blind writes for init
sequence where it should preserve most bits other than the ones it is
deliberately manipulating.

The code now checks to see if the adapter needs to be brought out of
reset (where as before it was doing an IDM write to bring it out of
reset regardless of whether it was in reset or not).  Also, removed
unnecessary usleeps (as there is already a read present to flush the
IDM writes).

Signed-off-by: Zac Schroff &lt;zschroff@broadcom.com&gt;
Signed-off-by: Jon Mason &lt;jon.mason@broadcom.com&gt;
Fixes: f6a95a24957 ("net: ethernet: bgmac: Add platform device support")
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
</feed>
