<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux-stable.git/drivers/net/phy, branch v4.14.78</title>
<subtitle>Linux kernel stable tree</subtitle>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux-stable.git/'/>
<entry>
<title>net: phy: xgmiitorgmii: Check phy_driver ready before accessing</title>
<updated>2018-10-04T00:00:51+00:00</updated>
<author>
<name>Brandon Maier</name>
<email>brandon.maier@rockwellcollins.com</email>
</author>
<published>2018-06-26T17:50:48+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux-stable.git/commit/?id=3f7056e1822d648f8022997497edc6cad2ad1e73'/>
<id>3f7056e1822d648f8022997497edc6cad2ad1e73</id>
<content type='text'>
[ Upstream commit ab4e6ee578e88a659938db8fbf33720bc048d29c ]

Since a phy_device is added to the global mdio_bus list during
phy_device_register(), but a phy_device's phy_driver doesn't get
attached until phy_probe(). It's possible of_phy_find_device() in
xgmiitorgmii will return a valid phy with a NULL phy_driver. Leading to
a NULL pointer access during the memcpy().

Fixes this Oops:

Unable to handle kernel NULL pointer dereference at virtual address 00000000
pgd = c0004000
[00000000] *pgd=00000000
Internal error: Oops: 5 [#1] PREEMPT SMP ARM
Modules linked in:
CPU: 0 PID: 1 Comm: swapper/0 Not tainted 4.14.40 #1
Hardware name: Xilinx Zynq Platform
task: ce4c8d00 task.stack: ce4ca000
PC is at memcpy+0x48/0x330
LR is at xgmiitorgmii_probe+0x90/0xe8
pc : [&lt;c074bc68&gt;]    lr : [&lt;c0529548&gt;]    psr: 20000013
sp : ce4cbb54  ip : 00000000  fp : ce4cbb8c
r10: 00000000  r9 : 00000000  r8 : c0c49178
r7 : 00000000  r6 : cdc14718  r5 : ce762800  r4 : cdc14710
r3 : 00000000  r2 : 00000054  r1 : 00000000  r0 : cdc14718
Flags: nzCv  IRQs on  FIQs on  Mode SVC_32  ISA ARM  Segment none
Control: 18c5387d  Table: 0000404a  DAC: 00000051
Process swapper/0 (pid: 1, stack limit = 0xce4ca210)
...
[&lt;c074bc68&gt;] (memcpy) from [&lt;c0529548&gt;] (xgmiitorgmii_probe+0x90/0xe8)
[&lt;c0529548&gt;] (xgmiitorgmii_probe) from [&lt;c0526a94&gt;] (mdio_probe+0x28/0x34)
[&lt;c0526a94&gt;] (mdio_probe) from [&lt;c04db98c&gt;] (driver_probe_device+0x254/0x414)
[&lt;c04db98c&gt;] (driver_probe_device) from [&lt;c04dbd58&gt;] (__device_attach_driver+0xac/0x10c)
[&lt;c04dbd58&gt;] (__device_attach_driver) from [&lt;c04d96f4&gt;] (bus_for_each_drv+0x84/0xc8)
[&lt;c04d96f4&gt;] (bus_for_each_drv) from [&lt;c04db5bc&gt;] (__device_attach+0xd0/0x134)
[&lt;c04db5bc&gt;] (__device_attach) from [&lt;c04dbdd4&gt;] (device_initial_probe+0x1c/0x20)
[&lt;c04dbdd4&gt;] (device_initial_probe) from [&lt;c04da8fc&gt;] (bus_probe_device+0x98/0xa0)
[&lt;c04da8fc&gt;] (bus_probe_device) from [&lt;c04d8660&gt;] (device_add+0x43c/0x5d0)
[&lt;c04d8660&gt;] (device_add) from [&lt;c0526cb8&gt;] (mdio_device_register+0x34/0x80)
[&lt;c0526cb8&gt;] (mdio_device_register) from [&lt;c0580b48&gt;] (of_mdiobus_register+0x170/0x30c)
[&lt;c0580b48&gt;] (of_mdiobus_register) from [&lt;c05349c4&gt;] (macb_probe+0x710/0xc00)
[&lt;c05349c4&gt;] (macb_probe) from [&lt;c04dd700&gt;] (platform_drv_probe+0x44/0x80)
[&lt;c04dd700&gt;] (platform_drv_probe) from [&lt;c04db98c&gt;] (driver_probe_device+0x254/0x414)
[&lt;c04db98c&gt;] (driver_probe_device) from [&lt;c04dbc58&gt;] (__driver_attach+0x10c/0x118)
[&lt;c04dbc58&gt;] (__driver_attach) from [&lt;c04d9600&gt;] (bus_for_each_dev+0x8c/0xd0)
[&lt;c04d9600&gt;] (bus_for_each_dev) from [&lt;c04db1fc&gt;] (driver_attach+0x2c/0x30)
[&lt;c04db1fc&gt;] (driver_attach) from [&lt;c04daa98&gt;] (bus_add_driver+0x50/0x260)
[&lt;c04daa98&gt;] (bus_add_driver) from [&lt;c04dc440&gt;] (driver_register+0x88/0x108)
[&lt;c04dc440&gt;] (driver_register) from [&lt;c04dd6b4&gt;] (__platform_driver_register+0x50/0x58)
[&lt;c04dd6b4&gt;] (__platform_driver_register) from [&lt;c0b31248&gt;] (macb_driver_init+0x24/0x28)
[&lt;c0b31248&gt;] (macb_driver_init) from [&lt;c010203c&gt;] (do_one_initcall+0x60/0x1a4)
[&lt;c010203c&gt;] (do_one_initcall) from [&lt;c0b00f78&gt;] (kernel_init_freeable+0x15c/0x1f8)
[&lt;c0b00f78&gt;] (kernel_init_freeable) from [&lt;c0763d10&gt;] (kernel_init+0x18/0x124)
[&lt;c0763d10&gt;] (kernel_init) from [&lt;c0112d74&gt;] (ret_from_fork+0x14/0x20)
Code: ba000002 f5d1f03c f5d1f05c f5d1f07c (e8b151f8)
---[ end trace 3e4ec21905820a1f ]---

Signed-off-by: Brandon Maier &lt;brandon.maier@rockwellcollins.com&gt;
Reviewed-by: Andrew Lunn &lt;andrew@lunn.ch&gt;
Reviewed-by: Florian Fainelli &lt;f.fainelli@gmail.com&gt;

Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;

Signed-off-by: Sasha Levin &lt;alexander.levin@microsoft.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
[ Upstream commit ab4e6ee578e88a659938db8fbf33720bc048d29c ]

Since a phy_device is added to the global mdio_bus list during
phy_device_register(), but a phy_device's phy_driver doesn't get
attached until phy_probe(). It's possible of_phy_find_device() in
xgmiitorgmii will return a valid phy with a NULL phy_driver. Leading to
a NULL pointer access during the memcpy().

Fixes this Oops:

Unable to handle kernel NULL pointer dereference at virtual address 00000000
pgd = c0004000
[00000000] *pgd=00000000
Internal error: Oops: 5 [#1] PREEMPT SMP ARM
Modules linked in:
CPU: 0 PID: 1 Comm: swapper/0 Not tainted 4.14.40 #1
Hardware name: Xilinx Zynq Platform
task: ce4c8d00 task.stack: ce4ca000
PC is at memcpy+0x48/0x330
LR is at xgmiitorgmii_probe+0x90/0xe8
pc : [&lt;c074bc68&gt;]    lr : [&lt;c0529548&gt;]    psr: 20000013
sp : ce4cbb54  ip : 00000000  fp : ce4cbb8c
r10: 00000000  r9 : 00000000  r8 : c0c49178
r7 : 00000000  r6 : cdc14718  r5 : ce762800  r4 : cdc14710
r3 : 00000000  r2 : 00000054  r1 : 00000000  r0 : cdc14718
Flags: nzCv  IRQs on  FIQs on  Mode SVC_32  ISA ARM  Segment none
Control: 18c5387d  Table: 0000404a  DAC: 00000051
Process swapper/0 (pid: 1, stack limit = 0xce4ca210)
...
[&lt;c074bc68&gt;] (memcpy) from [&lt;c0529548&gt;] (xgmiitorgmii_probe+0x90/0xe8)
[&lt;c0529548&gt;] (xgmiitorgmii_probe) from [&lt;c0526a94&gt;] (mdio_probe+0x28/0x34)
[&lt;c0526a94&gt;] (mdio_probe) from [&lt;c04db98c&gt;] (driver_probe_device+0x254/0x414)
[&lt;c04db98c&gt;] (driver_probe_device) from [&lt;c04dbd58&gt;] (__device_attach_driver+0xac/0x10c)
[&lt;c04dbd58&gt;] (__device_attach_driver) from [&lt;c04d96f4&gt;] (bus_for_each_drv+0x84/0xc8)
[&lt;c04d96f4&gt;] (bus_for_each_drv) from [&lt;c04db5bc&gt;] (__device_attach+0xd0/0x134)
[&lt;c04db5bc&gt;] (__device_attach) from [&lt;c04dbdd4&gt;] (device_initial_probe+0x1c/0x20)
[&lt;c04dbdd4&gt;] (device_initial_probe) from [&lt;c04da8fc&gt;] (bus_probe_device+0x98/0xa0)
[&lt;c04da8fc&gt;] (bus_probe_device) from [&lt;c04d8660&gt;] (device_add+0x43c/0x5d0)
[&lt;c04d8660&gt;] (device_add) from [&lt;c0526cb8&gt;] (mdio_device_register+0x34/0x80)
[&lt;c0526cb8&gt;] (mdio_device_register) from [&lt;c0580b48&gt;] (of_mdiobus_register+0x170/0x30c)
[&lt;c0580b48&gt;] (of_mdiobus_register) from [&lt;c05349c4&gt;] (macb_probe+0x710/0xc00)
[&lt;c05349c4&gt;] (macb_probe) from [&lt;c04dd700&gt;] (platform_drv_probe+0x44/0x80)
[&lt;c04dd700&gt;] (platform_drv_probe) from [&lt;c04db98c&gt;] (driver_probe_device+0x254/0x414)
[&lt;c04db98c&gt;] (driver_probe_device) from [&lt;c04dbc58&gt;] (__driver_attach+0x10c/0x118)
[&lt;c04dbc58&gt;] (__driver_attach) from [&lt;c04d9600&gt;] (bus_for_each_dev+0x8c/0xd0)
[&lt;c04d9600&gt;] (bus_for_each_dev) from [&lt;c04db1fc&gt;] (driver_attach+0x2c/0x30)
[&lt;c04db1fc&gt;] (driver_attach) from [&lt;c04daa98&gt;] (bus_add_driver+0x50/0x260)
[&lt;c04daa98&gt;] (bus_add_driver) from [&lt;c04dc440&gt;] (driver_register+0x88/0x108)
[&lt;c04dc440&gt;] (driver_register) from [&lt;c04dd6b4&gt;] (__platform_driver_register+0x50/0x58)
[&lt;c04dd6b4&gt;] (__platform_driver_register) from [&lt;c0b31248&gt;] (macb_driver_init+0x24/0x28)
[&lt;c0b31248&gt;] (macb_driver_init) from [&lt;c010203c&gt;] (do_one_initcall+0x60/0x1a4)
[&lt;c010203c&gt;] (do_one_initcall) from [&lt;c0b00f78&gt;] (kernel_init_freeable+0x15c/0x1f8)
[&lt;c0b00f78&gt;] (kernel_init_freeable) from [&lt;c0763d10&gt;] (kernel_init+0x18/0x124)
[&lt;c0763d10&gt;] (kernel_init) from [&lt;c0112d74&gt;] (ret_from_fork+0x14/0x20)
Code: ba000002 f5d1f03c f5d1f05c f5d1f07c (e8b151f8)
---[ end trace 3e4ec21905820a1f ]---

Signed-off-by: Brandon Maier &lt;brandon.maier@rockwellcollins.com&gt;
Reviewed-by: Andrew Lunn &lt;andrew@lunn.ch&gt;
Reviewed-by: Florian Fainelli &lt;f.fainelli@gmail.com&gt;

Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;

Signed-off-by: Sasha Levin &lt;alexander.levin@microsoft.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>net: phy: xgmiitorgmii: Check read_status results</title>
<updated>2018-10-04T00:00:51+00:00</updated>
<author>
<name>Brandon Maier</name>
<email>brandon.maier@rockwellcollins.com</email>
</author>
<published>2018-06-26T17:50:50+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux-stable.git/commit/?id=0f4ca55e441cf3bdf3b3d6467690d58adc681d44'/>
<id>0f4ca55e441cf3bdf3b3d6467690d58adc681d44</id>
<content type='text'>
[ Upstream commit 8d0752d11312be830c33e84dfd1016e6a47c2938 ]

We're ignoring the result of the attached phy device's read_status().
Return it so we can detect errors.

Signed-off-by: Brandon Maier &lt;brandon.maier@rockwellcollins.com&gt;
Reviewed-by: Andrew Lunn &lt;andrew@lunn.ch&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
Signed-off-by: Sasha Levin &lt;alexander.levin@microsoft.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
[ Upstream commit 8d0752d11312be830c33e84dfd1016e6a47c2938 ]

We're ignoring the result of the attached phy device's read_status().
Return it so we can detect errors.

Signed-off-by: Brandon Maier &lt;brandon.maier@rockwellcollins.com&gt;
Reviewed-by: Andrew Lunn &lt;andrew@lunn.ch&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
Signed-off-by: Sasha Levin &lt;alexander.levin@microsoft.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>net: phy: Fix the register offsets in Broadcom iProc mdio mux driver</title>
<updated>2018-09-19T20:43:39+00:00</updated>
<author>
<name>Arun Parameswaran</name>
<email>arun.parameswaran@broadcom.com</email>
</author>
<published>2018-08-02T00:53:47+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux-stable.git/commit/?id=47a6917f4b7220cbabe9d9e11219c589abd8902d'/>
<id>47a6917f4b7220cbabe9d9e11219c589abd8902d</id>
<content type='text'>
[ Upstream commit 77fefa93bfebe4df44f154f2aa5938e32630d0bf ]

Modify the register offsets in the Broadcom iProc mdio mux to start
from the top of the register address space.

Earlier, the base address pointed to the end of the block's register
space. The base address will now point to the start of the mdio's
address space. The offsets have been fixed to match this.

Signed-off-by: Arun Parameswaran &lt;arun.parameswaran@broadcom.com&gt;
Reviewed-by: Andrew Lunn &lt;andrew@lunn.ch&gt;
Reviewed-by: Florian Fainelli &lt;f.fainelli@gmail.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
Signed-off-by: Sasha Levin &lt;alexander.levin@microsoft.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
[ Upstream commit 77fefa93bfebe4df44f154f2aa5938e32630d0bf ]

Modify the register offsets in the Broadcom iProc mdio mux to start
from the top of the register address space.

Earlier, the base address pointed to the end of the block's register
space. The base address will now point to the start of the mdio's
address space. The offsets have been fixed to match this.

Signed-off-by: Arun Parameswaran &lt;arun.parameswaran@broadcom.com&gt;
Reviewed-by: Andrew Lunn &lt;andrew@lunn.ch&gt;
Reviewed-by: Florian Fainelli &lt;f.fainelli@gmail.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
Signed-off-by: Sasha Levin &lt;alexander.levin@microsoft.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>net: mdio-mux: bcm-iproc: fix wrong getter and setter pair</title>
<updated>2018-08-03T05:50:44+00:00</updated>
<author>
<name>Anton Vasilyev</name>
<email>vasilyev@ispras.ru</email>
</author>
<published>2018-07-27T15:57:47+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux-stable.git/commit/?id=e071e2fdf45e1505436ad61e42b0d44904db1997'/>
<id>e071e2fdf45e1505436ad61e42b0d44904db1997</id>
<content type='text'>
[ Upstream commit b0753408aadf32c7ece9e6b765017881e54af833 ]

mdio_mux_iproc_probe() uses platform_set_drvdata() to store md pointer
in device, whereas mdio_mux_iproc_remove() restores md pointer by
dev_get_platdata(&amp;pdev-&gt;dev). This leads to wrong resources release.

The patch replaces getter to platform_get_drvdata.

Fixes: 98bc865a1ec8 ("net: mdio-mux: Add MDIO mux driver for iProc SoCs")
Signed-off-by: Anton Vasilyev &lt;vasilyev@ispras.ru&gt;
Reviewed-by: Andrew Lunn &lt;andrew@lunn.ch&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
[ Upstream commit b0753408aadf32c7ece9e6b765017881e54af833 ]

mdio_mux_iproc_probe() uses platform_set_drvdata() to store md pointer
in device, whereas mdio_mux_iproc_remove() restores md pointer by
dev_get_platdata(&amp;pdev-&gt;dev). This leads to wrong resources release.

The patch replaces getter to platform_get_drvdata.

Fixes: 98bc865a1ec8 ("net: mdio-mux: Add MDIO mux driver for iProc SoCs")
Signed-off-by: Anton Vasilyev &lt;vasilyev@ispras.ru&gt;
Reviewed-by: Andrew Lunn &lt;andrew@lunn.ch&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>net: phy: phylink: Release link GPIO</title>
<updated>2018-08-03T05:50:35+00:00</updated>
<author>
<name>Florian Fainelli</name>
<email>f.fainelli@gmail.com</email>
</author>
<published>2018-05-10T20:17:30+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux-stable.git/commit/?id=240bc678f72629b9bf420d7dd75462fdcb70b2a8'/>
<id>240bc678f72629b9bf420d7dd75462fdcb70b2a8</id>
<content type='text'>
[ Upstream commit daab3349ad1a69663ccad278ed71d55974d104b4 ]

We are not releasing the link GPIO descriptor with gpiod_put() which results in
subsequent probing to get -EBUSY when calling fwnode_get_named_gpiod(). Fix this
by doing the release in phylink_destroy().

Fixes: 9525ae83959b ("phylink: add phylink infrastructure")
Signed-off-by: Florian Fainelli &lt;f.fainelli@gmail.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
Signed-off-by: Sasha Levin &lt;alexander.levin@microsoft.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
[ Upstream commit daab3349ad1a69663ccad278ed71d55974d104b4 ]

We are not releasing the link GPIO descriptor with gpiod_put() which results in
subsequent probing to get -EBUSY when calling fwnode_get_named_gpiod(). Fix this
by doing the release in phylink_destroy().

Fixes: 9525ae83959b ("phylink: add phylink infrastructure")
Signed-off-by: Florian Fainelli &lt;f.fainelli@gmail.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
Signed-off-by: Sasha Levin &lt;alexander.levin@microsoft.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>net: phy: consider PHY_IGNORE_INTERRUPT in phy_start_aneg_priv</title>
<updated>2018-07-28T05:55:42+00:00</updated>
<author>
<name>Heiner Kallweit</name>
<email>hkallweit1@gmail.com</email>
</author>
<published>2018-07-19T06:15:16+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux-stable.git/commit/?id=50b464d33964282fb09be7d6d8a6063475f63814'/>
<id>50b464d33964282fb09be7d6d8a6063475f63814</id>
<content type='text'>
[ Upstream commit 215d08a85b9acf5e1fe9dbf50f1774cde333efef ]

The situation described in the comment can occur also with
PHY_IGNORE_INTERRUPT, therefore change the condition to include it.

Fixes: f555f34fdc58 ("net: phy: fix auto-negotiation stall due to unavailable interrupt")
Signed-off-by: Heiner Kallweit &lt;hkallweit1@gmail.com&gt;
Reviewed-by: Andrew Lunn &lt;andrew@lunn.ch&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
[ Upstream commit 215d08a85b9acf5e1fe9dbf50f1774cde333efef ]

The situation described in the comment can occur also with
PHY_IGNORE_INTERRUPT, therefore change the condition to include it.

Fixes: f555f34fdc58 ("net: phy: fix auto-negotiation stall due to unavailable interrupt")
Signed-off-by: Heiner Kallweit &lt;hkallweit1@gmail.com&gt;
Reviewed-by: Andrew Lunn &lt;andrew@lunn.ch&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>net: phy: fix flag masking in __set_phy_supported</title>
<updated>2018-07-25T09:25:09+00:00</updated>
<author>
<name>Heiner Kallweit</name>
<email>hkallweit1@gmail.com</email>
</author>
<published>2018-07-03T20:34:54+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux-stable.git/commit/?id=811ad4b366a60a7e05b20c3c8262bb95e69d4ade'/>
<id>811ad4b366a60a7e05b20c3c8262bb95e69d4ade</id>
<content type='text'>
[ Upstream commit df8ed346d4a806a6eef2db5924285e839604b3f9 ]

Currently also the pause flags are removed from phydev-&gt;supported because
they're not included in PHY_DEFAULT_FEATURES. I don't think this is
intended, especially when considering that this function can be called
via phy_set_max_speed() anywhere in a driver. Change the masking to mask
out only the values we're going to change. In addition remove the
misleading comment, job of this small function is just to adjust the
supported and advertised speeds.

Fixes: f3a6bd393c2c ("phylib: Add phy_set_max_speed helper")
Signed-off-by: Heiner Kallweit &lt;hkallweit1@gmail.com&gt;
Reviewed-by: Andrew Lunn &lt;andrew@lunn.ch&gt;
Reviewed-by: Florian Fainelli &lt;f.fainelli@gmail.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
[ Upstream commit df8ed346d4a806a6eef2db5924285e839604b3f9 ]

Currently also the pause flags are removed from phydev-&gt;supported because
they're not included in PHY_DEFAULT_FEATURES. I don't think this is
intended, especially when considering that this function can be called
via phy_set_max_speed() anywhere in a driver. Change the masking to mask
out only the values we're going to change. In addition remove the
misleading comment, job of this small function is just to adjust the
supported and advertised speeds.

Fixes: f3a6bd393c2c ("phylib: Add phy_set_max_speed helper")
Signed-off-by: Heiner Kallweit &lt;hkallweit1@gmail.com&gt;
Reviewed-by: Andrew Lunn &lt;andrew@lunn.ch&gt;
Reviewed-by: Florian Fainelli &lt;f.fainelli@gmail.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>net: phy: marvell: clear wol event before setting it</title>
<updated>2018-06-20T19:02:47+00:00</updated>
<author>
<name>Jingju Hou</name>
<email>Jingju.Hou@synaptics.com</email>
</author>
<published>2018-04-23T07:22:49+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux-stable.git/commit/?id=9148e21d7624fd4d6b69383c8988978c7ec84ef8'/>
<id>9148e21d7624fd4d6b69383c8988978c7ec84ef8</id>
<content type='text'>
[ Upstream commit b6a930fa88083b41d26ddf1cab95cbd740936c22 ]

If WOL event happened once, the LED[2] interrupt pin will not be
cleared unless we read the CSISR register. If interrupts are in use,
the normal interrupt handling will clear the WOL event. Let's clear the
WOL event before enabling it if !phy_interrupt_is_valid().

Signed-off-by: Jingju Hou &lt;Jingju.Hou@synaptics.com&gt;
Signed-off-by: Jisheng Zhang &lt;Jisheng.Zhang@synaptics.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
Signed-off-by: Sasha Levin &lt;alexander.levin@microsoft.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
[ Upstream commit b6a930fa88083b41d26ddf1cab95cbd740936c22 ]

If WOL event happened once, the LED[2] interrupt pin will not be
cleared unless we read the CSISR register. If interrupts are in use,
the normal interrupt handling will clear the WOL event. Let's clear the
WOL event before enabling it if !phy_interrupt_is_valid().

Signed-off-by: Jingju Hou &lt;Jingju.Hou@synaptics.com&gt;
Signed-off-by: Jisheng Zhang &lt;Jisheng.Zhang@synaptics.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
Signed-off-by: Sasha Levin &lt;alexander.levin@microsoft.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>net: phy: broadcom: Fix auxiliary control register reads</title>
<updated>2018-06-11T20:49:21+00:00</updated>
<author>
<name>Florian Fainelli</name>
<email>f.fainelli@gmail.com</email>
</author>
<published>2018-05-22T23:22:26+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux-stable.git/commit/?id=900679988fdf24d687c746e909b10e47e442ad05'/>
<id>900679988fdf24d687c746e909b10e47e442ad05</id>
<content type='text'>
[ Upstream commit 733a969a7ed14fc5786bcc59c1bdda83c7ddb46e ]

We are currently doing auxiliary control register reads with the shadow
register value 0b111 (0x7) which incidentally is also the selector value
that should be present in bits [2:0]. Fix this by using the appropriate
selector mask which is defined (MII_BCM54XX_AUXCTL_SHDWSEL_MASK).

This does not have a functional impact yet because we always access the
MII_BCM54XX_AUXCTL_SHDWSEL_MISC (0x7) register in the current code.
This might change at some point though.

Fixes: 5b4e29005123 ("net: phy: broadcom: add bcm54xx_auxctl_read")
Signed-off-by: Florian Fainelli &lt;f.fainelli@gmail.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
[ Upstream commit 733a969a7ed14fc5786bcc59c1bdda83c7ddb46e ]

We are currently doing auxiliary control register reads with the shadow
register value 0b111 (0x7) which incidentally is also the selector value
that should be present in bits [2:0]. Fix this by using the appropriate
selector mask which is defined (MII_BCM54XX_AUXCTL_SHDWSEL_MASK).

This does not have a functional impact yet because we always access the
MII_BCM54XX_AUXCTL_SHDWSEL_MISC (0x7) register in the current code.
This might change at some point though.

Fixes: 5b4e29005123 ("net: phy: broadcom: add bcm54xx_auxctl_read")
Signed-off-by: Florian Fainelli &lt;f.fainelli@gmail.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>net: phy: broadcom: Fix bcm_write_exp()</title>
<updated>2018-06-11T20:49:20+00:00</updated>
<author>
<name>Florian Fainelli</name>
<email>f.fainelli@gmail.com</email>
</author>
<published>2018-05-23T00:04:49+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux-stable.git/commit/?id=8acb0708ab6d7d29db9276befc08bbc20271ab44'/>
<id>8acb0708ab6d7d29db9276befc08bbc20271ab44</id>
<content type='text'>
[ Upstream commit 79fb218d97980d4fee9a64f4c8ff05289364ba25 ]

On newer PHYs, we need to select the expansion register to write with
setting bits [11:8] to 0xf. This was done correctly by bcm7xxx.c prior
to being migrated to generic code under bcm-phy-lib.c which
unfortunately used the older implementation from the BCM54xx days.

Fix this by creating an inline stub: bcm_write_exp_sel() which adds the
correct value (MII_BCM54XX_EXP_SEL_ER) and update both the Cygnus PHY
and BCM7xxx PHY drivers which require setting these bits.

broadcom.c is unchanged because some PHYs even use a different selector
method, so let them specify it directly (e.g: SerDes secondary selector).

Fixes: a1cba5613edf ("net: phy: Add Broadcom phy library for common interfaces")
Signed-off-by: Florian Fainelli &lt;f.fainelli@gmail.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
[ Upstream commit 79fb218d97980d4fee9a64f4c8ff05289364ba25 ]

On newer PHYs, we need to select the expansion register to write with
setting bits [11:8] to 0xf. This was done correctly by bcm7xxx.c prior
to being migrated to generic code under bcm-phy-lib.c which
unfortunately used the older implementation from the BCM54xx days.

Fix this by creating an inline stub: bcm_write_exp_sel() which adds the
correct value (MII_BCM54XX_EXP_SEL_ER) and update both the Cygnus PHY
and BCM7xxx PHY drivers which require setting these bits.

broadcom.c is unchanged because some PHYs even use a different selector
method, so let them specify it directly (e.g: SerDes secondary selector).

Fixes: a1cba5613edf ("net: phy: Add Broadcom phy library for common interfaces")
Signed-off-by: Florian Fainelli &lt;f.fainelli@gmail.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</pre>
</div>
</content>
</entry>
</feed>
