2014-01-05 03:17:06 +03:00
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2007-09-28 22:42:14 -07:00
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2012-06-09 07:49:07 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2017-01-25 11:39:49 +01:00
|
|
|
|
2006-10-03 16:18:35 +01:00
|
|
|
|
2012-06-27 21:14:38 +00:00
|
|
|
|
2014-01-05 03:17:06 +03:00
|
|
|
|
|
|
|
|
|
2011-07-26 16:09:06 -07:00
|
|
|
|
2014-01-05 03:17:06 +03:00
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
|
|
|
|
|
2015-05-16 10:17:56 -07:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2007-03-06 02:41:48 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2005-08-24 18:46:21 -05:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2014-01-05 03:17:06 +03:00
|
|
|
|
2014-02-11 17:27:34 -08:00
|
|
|
|
2014-02-11 17:27:35 -08:00
|
|
|
|
|
|
|
|
|
2017-07-25 15:02:42 +01:00
|
|
|
|
2014-02-11 17:27:34 -08:00
|
|
|
|
2014-01-05 03:17:06 +03:00
|
|
|
|
2014-02-11 17:27:33 -08:00
|
|
|
|
2014-01-05 03:17:06 +03:00
|
|
|
|
2005-08-24 18:46:21 -05:00
|
|
|
|
|
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
2007-03-06 02:41:48 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2014-02-11 17:27:38 -08:00
|
|
|
|
2007-03-06 02:41:48 -08:00
|
|
|
|
2010-10-21 08:37:41 +00:00
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
|
|
|
|
|
2014-01-05 03:21:52 +03:00
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
2014-01-05 03:21:52 +03:00
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
|
|
|
|
|
2007-03-06 02:41:48 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2014-02-11 17:27:38 -08:00
|
|
|
|
2007-03-06 02:41:48 -08:00
|
|
|
|
2010-10-21 08:37:41 +00:00
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2014-01-05 03:21:52 +03:00
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
2014-01-05 03:21:52 +03:00
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
|
|
|
|
|
2017-06-05 12:23:00 +01:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
2007-03-06 02:41:48 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
2014-02-11 17:27:37 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
2016-11-10 17:10:46 -06:00
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
2017-02-23 14:22:19 -08:00
|
|
|
|
2014-02-11 17:27:37 -08:00
|
|
|
|
|
|
|
|
|
2017-06-05 12:22:55 +01:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2014-02-11 17:27:36 -08:00
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
2016-11-10 17:10:46 -06:00
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
2007-03-06 02:41:48 -08:00
|
|
|
|
net: phy: improve phylib correctness for non-autoneg settings
phylib has some undesirable behaviour when forcing a link mode through
ethtool. phylib uses this code:
idx = phy_find_valid(phy_find_setting(phydev->speed, phydev->duplex),
features);
to find an index in the settings table. phy_find_setting() starts at
index 0, and scans upwards looking for an exact speed and duplex match.
When it doesn't find it, it returns MAX_NUM_SETTINGS - 1, which is
10baseT-Half duplex.
phy_find_valid() then scans from the point (and effectively only checks
one entry) before bailing out, returning MAX_NUM_SETTINGS - 1.
phy_sanitize_settings() then sets ->speed to SPEED_10 and ->duplex to
DUPLEX_HALF whether or not 10baseT-Half is supported or not. This goes
against all the comments against these functions, and 10baseT-Half may
not even be supported by the hardware.
Rework these functions, introducing a new method of scanning the table.
There are two modes of lookup that phylib wants: exact, and inexact.
- in exact mode, we return either an exact match or failure
- in inexact mode, we return an exact match if it exists, a match at
the highest speed that is not greater than the requested speed
(ignoring duplex), or failing that, the lowest supported speed, or
failure.
The biggest difference is that we always check whether the entry is
supported before further consideration, so all unsupported entries are
not considered as candidates.
This results in arguably saner behaviour, better matches the comments,
and is probably what users would expect.
This becomes important as ethernet speeds increase, PHYs exist which do
not support the 10Mbit speeds, and half-duplex is likely to become
obsolete - it's already not even an option on 10Gbit and faster links.
Signed-off-by: Russell King <rmk+kernel@armlinux.org.uk>
Signed-off-by: David S. Miller <davem@davemloft.net>
2017-04-13 16:49:15 +01:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
net: phy: improve phylib correctness for non-autoneg settings
phylib has some undesirable behaviour when forcing a link mode through
ethtool. phylib uses this code:
idx = phy_find_valid(phy_find_setting(phydev->speed, phydev->duplex),
features);
to find an index in the settings table. phy_find_setting() starts at
index 0, and scans upwards looking for an exact speed and duplex match.
When it doesn't find it, it returns MAX_NUM_SETTINGS - 1, which is
10baseT-Half duplex.
phy_find_valid() then scans from the point (and effectively only checks
one entry) before bailing out, returning MAX_NUM_SETTINGS - 1.
phy_sanitize_settings() then sets ->speed to SPEED_10 and ->duplex to
DUPLEX_HALF whether or not 10baseT-Half is supported or not. This goes
against all the comments against these functions, and 10baseT-Half may
not even be supported by the hardware.
Rework these functions, introducing a new method of scanning the table.
There are two modes of lookup that phylib wants: exact, and inexact.
- in exact mode, we return either an exact match or failure
- in inexact mode, we return an exact match if it exists, a match at
the highest speed that is not greater than the requested speed
(ignoring duplex), or failing that, the lowest supported speed, or
failure.
The biggest difference is that we always check whether the entry is
supported before further consideration, so all unsupported entries are
not considered as candidates.
This results in arguably saner behaviour, better matches the comments,
and is probably what users would expect.
This becomes important as ethernet speeds increase, PHYs exist which do
not support the 10Mbit speeds, and half-duplex is likely to become
obsolete - it's already not even an option on 10Gbit and faster links.
Signed-off-by: Russell King <rmk+kernel@armlinux.org.uk>
Signed-off-by: David S. Miller <davem@davemloft.net>
2017-04-13 16:49:15 +01:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
net: phy: improve phylib correctness for non-autoneg settings
phylib has some undesirable behaviour when forcing a link mode through
ethtool. phylib uses this code:
idx = phy_find_valid(phy_find_setting(phydev->speed, phydev->duplex),
features);
to find an index in the settings table. phy_find_setting() starts at
index 0, and scans upwards looking for an exact speed and duplex match.
When it doesn't find it, it returns MAX_NUM_SETTINGS - 1, which is
10baseT-Half duplex.
phy_find_valid() then scans from the point (and effectively only checks
one entry) before bailing out, returning MAX_NUM_SETTINGS - 1.
phy_sanitize_settings() then sets ->speed to SPEED_10 and ->duplex to
DUPLEX_HALF whether or not 10baseT-Half is supported or not. This goes
against all the comments against these functions, and 10baseT-Half may
not even be supported by the hardware.
Rework these functions, introducing a new method of scanning the table.
There are two modes of lookup that phylib wants: exact, and inexact.
- in exact mode, we return either an exact match or failure
- in inexact mode, we return an exact match if it exists, a match at
the highest speed that is not greater than the requested speed
(ignoring duplex), or failing that, the lowest supported speed, or
failure.
The biggest difference is that we always check whether the entry is
supported before further consideration, so all unsupported entries are
not considered as candidates.
This results in arguably saner behaviour, better matches the comments,
and is probably what users would expect.
This becomes important as ethernet speeds increase, PHYs exist which do
not support the 10Mbit speeds, and half-duplex is likely to become
obsolete - it's already not even an option on 10Gbit and faster links.
Signed-off-by: Russell King <rmk+kernel@armlinux.org.uk>
Signed-off-by: David S. Miller <davem@davemloft.net>
2017-04-13 16:49:15 +01:00
|
|
|
|
|
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
2017-07-25 15:02:37 +01:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
|
|
|
|
|
2016-10-17 10:49:54 -05:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2017-07-25 15:02:37 +01:00
|
|
|
|
2016-10-17 10:49:54 -05:00
|
|
|
|
2017-07-25 15:02:47 +01:00
|
|
|
|
2016-10-17 10:49:54 -05:00
|
|
|
|
|
|
|
|
|
2015-02-17 09:36:22 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2017-07-25 15:02:37 +01:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2015-02-17 09:36:22 -08:00
|
|
|
|
|
|
|
|
|
2007-03-06 02:41:48 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
2007-03-06 02:41:48 -08:00
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
2007-03-06 02:41:48 -08:00
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
2010-10-21 08:37:41 +00:00
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
net: phy: improve phylib correctness for non-autoneg settings
phylib has some undesirable behaviour when forcing a link mode through
ethtool. phylib uses this code:
idx = phy_find_valid(phy_find_setting(phydev->speed, phydev->duplex),
features);
to find an index in the settings table. phy_find_setting() starts at
index 0, and scans upwards looking for an exact speed and duplex match.
When it doesn't find it, it returns MAX_NUM_SETTINGS - 1, which is
10baseT-Half duplex.
phy_find_valid() then scans from the point (and effectively only checks
one entry) before bailing out, returning MAX_NUM_SETTINGS - 1.
phy_sanitize_settings() then sets ->speed to SPEED_10 and ->duplex to
DUPLEX_HALF whether or not 10baseT-Half is supported or not. This goes
against all the comments against these functions, and 10baseT-Half may
not even be supported by the hardware.
Rework these functions, introducing a new method of scanning the table.
There are two modes of lookup that phylib wants: exact, and inexact.
- in exact mode, we return either an exact match or failure
- in inexact mode, we return an exact match if it exists, a match at
the highest speed that is not greater than the requested speed
(ignoring duplex), or failing that, the lowest supported speed, or
failure.
The biggest difference is that we always check whether the entry is
supported before further consideration, so all unsupported entries are
not considered as candidates.
This results in arguably saner behaviour, better matches the comments,
and is probably what users would expect.
This becomes important as ethernet speeds increase, PHYs exist which do
not support the 10Mbit speeds, and half-duplex is likely to become
obsolete - it's already not even an option on 10Gbit and faster links.
Signed-off-by: Russell King <rmk+kernel@armlinux.org.uk>
Signed-off-by: David S. Miller <davem@davemloft.net>
2017-04-13 16:49:15 +01:00
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2007-08-07 12:12:41 +02:00
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
net: phy: improve phylib correctness for non-autoneg settings
phylib has some undesirable behaviour when forcing a link mode through
ethtool. phylib uses this code:
idx = phy_find_valid(phy_find_setting(phydev->speed, phydev->duplex),
features);
to find an index in the settings table. phy_find_setting() starts at
index 0, and scans upwards looking for an exact speed and duplex match.
When it doesn't find it, it returns MAX_NUM_SETTINGS - 1, which is
10baseT-Half duplex.
phy_find_valid() then scans from the point (and effectively only checks
one entry) before bailing out, returning MAX_NUM_SETTINGS - 1.
phy_sanitize_settings() then sets ->speed to SPEED_10 and ->duplex to
DUPLEX_HALF whether or not 10baseT-Half is supported or not. This goes
against all the comments against these functions, and 10baseT-Half may
not even be supported by the hardware.
Rework these functions, introducing a new method of scanning the table.
There are two modes of lookup that phylib wants: exact, and inexact.
- in exact mode, we return either an exact match or failure
- in inexact mode, we return an exact match if it exists, a match at
the highest speed that is not greater than the requested speed
(ignoring duplex), or failing that, the lowest supported speed, or
failure.
The biggest difference is that we always check whether the entry is
supported before further consideration, so all unsupported entries are
not considered as candidates.
This results in arguably saner behaviour, better matches the comments,
and is probably what users would expect.
This becomes important as ethernet speeds increase, PHYs exist which do
not support the 10Mbit speeds, and half-duplex is likely to become
obsolete - it's already not even an option on 10Gbit and faster links.
Signed-off-by: Russell King <rmk+kernel@armlinux.org.uk>
Signed-off-by: David S. Miller <davem@davemloft.net>
2017-04-13 16:49:15 +01:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
|
|
|
|
|
2007-03-06 02:41:48 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
|
|
|
|
|
2017-05-12 09:35:46 -03:00
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2007-03-06 02:41:48 -08:00
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2011-04-27 18:32:39 +00:00
|
|
|
|
|
|
|
|
|
2016-01-06 20:11:16 +01:00
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
|
|
|
|
|
2014-01-05 03:17:06 +03:00
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2009-12-03 07:58:21 +00:00
|
|
|
|
2011-04-27 18:32:39 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2009-12-03 07:58:21 +00:00
|
|
|
|
|
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2011-04-27 18:32:39 +00:00
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2016-11-29 15:16:47 +05:30
|
|
|
|
2015-07-10 13:56:54 +12:00
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2007-01-20 16:38:26 -06:00
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
2016-04-15 00:35:00 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2016-11-29 15:16:47 +05:30
|
|
|
|
2016-04-15 00:35:00 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2017-06-13 10:09:46 +03:00
|
|
|
|
|
|
|
|
|
2016-04-15 00:35:00 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2017-09-20 15:52:14 -07:00
|
|
|
|
|
|
|
|
|
2016-04-15 00:35:00 +02:00
|
|
|
|
|
|
|
|
|
2016-11-29 15:16:47 +05:30
|
|
|
|
|
|
|
|
|
2016-04-15 00:35:00 +02:00
|
|
|
|
|
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
2007-03-06 02:41:48 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2010-08-09 13:41:59 +00:00
|
|
|
|
2007-03-06 02:41:48 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
2007-03-06 02:41:48 -08:00
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
2014-01-05 03:17:06 +03:00
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
2010-07-17 08:48:55 +00:00
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
2014-11-11 13:39:39 -07:00
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2016-01-06 20:11:16 +01:00
|
|
|
|
2008-09-18 03:06:52 +00:00
|
|
|
|
|
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
2016-01-06 20:11:16 +01:00
|
|
|
|
|
|
|
|
|
2011-03-10 06:52:13 +00:00
|
|
|
|
2014-01-05 03:21:52 +03:00
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
|
|
|
|
|
2016-01-06 20:11:16 +01:00
|
|
|
|
2013-12-17 21:38:12 -08:00
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
2014-11-11 13:39:39 -07:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
2014-11-11 13:39:39 -07:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
2014-11-11 13:39:39 -07:00
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
|
|
|
|
|
2014-11-11 13:39:39 -07:00
|
|
|
|
|
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2016-01-06 20:11:16 +01:00
|
|
|
|
2011-03-10 06:52:13 +00:00
|
|
|
|
|
|
|
|
|
2016-01-06 20:11:16 +01:00
|
|
|
|
2015-12-03 10:02:35 +01:00
|
|
|
|
2013-12-06 13:01:31 -08:00
|
|
|
|
2014-01-05 03:21:52 +03:00
|
|
|
|
2014-11-11 13:39:39 -07:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2014-01-05 03:21:52 +03:00
|
|
|
|
2007-11-28 19:56:34 +00:00
|
|
|
|
2010-07-17 08:49:36 +00:00
|
|
|
|
2017-02-17 16:07:34 -08:00
|
|
|
|
2010-07-17 08:49:36 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2007-11-28 19:56:34 +00:00
|
|
|
|
2008-09-18 03:06:52 +00:00
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
|
|
|
|
|
2007-09-17 22:21:40 +02:00
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
2007-03-06 02:41:48 -08:00
|
|
|
|
2017-04-20 14:00:04 +03:00
|
|
|
|
2007-03-06 02:41:48 -08:00
|
|
|
|
2017-04-20 14:00:04 +03:00
|
|
|
|
2005-08-24 18:46:21 -05:00
|
|
|
|
2007-03-06 02:41:48 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2005-08-24 18:46:21 -05:00
|
|
|
|
2017-04-20 14:00:04 +03:00
|
|
|
|
2005-08-24 18:46:21 -05:00
|
|
|
|
2017-04-20 14:00:04 +03:00
|
|
|
|
2005-08-24 18:46:21 -05:00
|
|
|
|
|
|
|
|
|
2017-02-17 16:07:34 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2008-01-29 10:05:09 -06:00
|
|
|
|
2005-08-24 18:46:21 -05:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2015-01-27 00:58:15 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2005-08-24 18:46:21 -05:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2017-04-20 14:00:04 +03:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2005-08-24 18:46:21 -05:00
|
|
|
|
2008-01-29 10:05:09 -06:00
|
|
|
|
2017-04-20 14:00:04 +03:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2005-08-24 18:46:21 -05:00
|
|
|
|
|
|
|
|
|
2017-04-20 14:00:04 +03:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2005-08-24 18:46:21 -05:00
|
|
|
|
|
|
|
|
|
2007-03-06 02:41:48 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
2007-03-06 02:41:48 -08:00
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
2017-07-26 12:05:38 -07:00
|
|
|
|
|
|
|
|
|
2014-01-05 03:27:17 +03:00
|
|
|
|
2007-03-06 02:41:48 -08:00
|
|
|
|
2014-01-05 03:27:17 +03:00
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
2013-04-24 17:12:55 +05:30
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
2017-07-25 15:03:03 +01:00
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
net: phy: Trigger state machine on state change and not polling.
The phy_start() is used to indicate the PHY is now ready to do its
work. The state is changed, normally to PHY_UP which means that both
the MAC and the PHY are ready.
If the phy driver is using polling, when the next poll happens, the
state machine notices the PHY is now in PHY_UP, and kicks off
auto-negotiation, if needed.
If however, the PHY is using interrupts, there is no polling. The phy
is stuck in PHY_UP until the next interrupt comes along. And there is
no reason for the PHY to interrupt.
Have phy_start() schedule the state machine to run, which both speeds
up the polling use case, and makes the interrupt use case actually
work.
This problems exists whenever there is a state change which will not
cause an interrupt. Trigger the state machine in these cases,
e.g. phy_error().
Signed-off-by: Andrew Lunn <andrew@lunn.ch>
Cc: Kyle Roeschley <kyle.roeschley@ni.com>
Tested-by: Kyle Roeschley <kyle.roeschley@ni.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2016-10-12 22:14:53 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2017-01-20 15:31:52 -08:00
|
|
|
|
net: phy: Trigger state machine on state change and not polling.
The phy_start() is used to indicate the PHY is now ready to do its
work. The state is changed, normally to PHY_UP which means that both
the MAC and the PHY are ready.
If the phy driver is using polling, when the next poll happens, the
state machine notices the PHY is now in PHY_UP, and kicks off
auto-negotiation, if needed.
If however, the PHY is using interrupts, there is no polling. The phy
is stuck in PHY_UP until the next interrupt comes along. And there is
no reason for the PHY to interrupt.
Have phy_start() schedule the state machine to run, which both speeds
up the polling use case, and makes the interrupt use case actually
work.
This problems exists whenever there is a state change which will not
cause an interrupt. Trigger the state machine in these cases,
e.g. phy_error().
Signed-off-by: Andrew Lunn <andrew@lunn.ch>
Cc: Kyle Roeschley <kyle.roeschley@ni.com>
Tested-by: Kyle Roeschley <kyle.roeschley@ni.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2016-10-12 22:14:53 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2017-04-20 14:00:04 +03:00
|
|
|
|
net: phy: Trigger state machine on state change and not polling.
The phy_start() is used to indicate the PHY is now ready to do its
work. The state is changed, normally to PHY_UP which means that both
the MAC and the PHY are ready.
If the phy driver is using polling, when the next poll happens, the
state machine notices the PHY is now in PHY_UP, and kicks off
auto-negotiation, if needed.
If however, the PHY is using interrupts, there is no polling. The phy
is stuck in PHY_UP until the next interrupt comes along. And there is
no reason for the PHY to interrupt.
Have phy_start() schedule the state machine to run, which both speeds
up the polling use case, and makes the interrupt use case actually
work.
This problems exists whenever there is a state change which will not
cause an interrupt. Trigger the state machine in these cases,
e.g. phy_error().
Signed-off-by: Andrew Lunn <andrew@lunn.ch>
Cc: Kyle Roeschley <kyle.roeschley@ni.com>
Tested-by: Kyle Roeschley <kyle.roeschley@ni.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2016-10-12 22:14:53 +02:00
|
|
|
|
2017-01-20 15:31:52 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
net: phy: Trigger state machine on state change and not polling.
The phy_start() is used to indicate the PHY is now ready to do its
work. The state is changed, normally to PHY_UP which means that both
the MAC and the PHY are ready.
If the phy driver is using polling, when the next poll happens, the
state machine notices the PHY is now in PHY_UP, and kicks off
auto-negotiation, if needed.
If however, the PHY is using interrupts, there is no polling. The phy
is stuck in PHY_UP until the next interrupt comes along. And there is
no reason for the PHY to interrupt.
Have phy_start() schedule the state machine to run, which both speeds
up the polling use case, and makes the interrupt use case actually
work.
This problems exists whenever there is a state change which will not
cause an interrupt. Trigger the state machine in these cases,
e.g. phy_error().
Signed-off-by: Andrew Lunn <andrew@lunn.ch>
Cc: Kyle Roeschley <kyle.roeschley@ni.com>
Tested-by: Kyle Roeschley <kyle.roeschley@ni.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2016-10-12 22:14:53 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2007-03-06 02:41:48 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
2017-07-26 12:05:38 -07:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2009-03-13 15:41:19 -07:00
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
2008-01-29 10:05:09 -06:00
|
|
|
|
2017-03-22 15:27:01 -05:00
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
2008-01-29 10:05:09 -06:00
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
|
|
|
|
|
2007-03-06 02:41:48 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2008-05-02 13:00:51 -05:00
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
2008-01-29 10:05:09 -06:00
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
2008-01-29 10:05:09 -06:00
|
|
|
|
net: phy: Trigger state machine on state change and not polling.
The phy_start() is used to indicate the PHY is now ready to do its
work. The state is changed, normally to PHY_UP which means that both
the MAC and the PHY are ready.
If the phy driver is using polling, when the next poll happens, the
state machine notices the PHY is now in PHY_UP, and kicks off
auto-negotiation, if needed.
If however, the PHY is using interrupts, there is no polling. The phy
is stuck in PHY_UP until the next interrupt comes along. And there is
no reason for the PHY to interrupt.
Have phy_start() schedule the state machine to run, which both speeds
up the polling use case, and makes the interrupt use case actually
work.
This problems exists whenever there is a state change which will not
cause an interrupt. Trigger the state machine in these cases,
e.g. phy_error().
Signed-off-by: Andrew Lunn <andrew@lunn.ch>
Cc: Kyle Roeschley <kyle.roeschley@ni.com>
Tested-by: Kyle Roeschley <kyle.roeschley@ni.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2016-10-12 22:14:53 +02:00
|
|
|
|
2017-01-20 15:31:52 -08:00
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
|
|
|
|
|
2007-03-06 02:41:48 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2005-08-24 18:46:21 -05:00
|
|
|
|
2007-03-06 02:41:48 -08:00
|
|
|
|
2016-10-16 19:56:51 +02:00
|
|
|
|
2005-08-24 18:46:21 -05:00
|
|
|
|
IRQ: Maintain regs pointer globally rather than passing to IRQ handlers
Maintain a per-CPU global "struct pt_regs *" variable which can be used instead
of passing regs around manually through all ~1800 interrupt handlers in the
Linux kernel.
The regs pointer is used in few places, but it potentially costs both stack
space and code to pass it around. On the FRV arch, removing the regs parameter
from all the genirq function results in a 20% speed up of the IRQ exit path
(ie: from leaving timer_interrupt() to leaving do_IRQ()).
Where appropriate, an arch may override the generic storage facility and do
something different with the variable. On FRV, for instance, the address is
maintained in GR28 at all times inside the kernel as part of general exception
handling.
Having looked over the code, it appears that the parameter may be handed down
through up to twenty or so layers of functions. Consider a USB character
device attached to a USB hub, attached to a USB controller that posts its
interrupts through a cascaded auxiliary interrupt controller. A character
device driver may want to pass regs to the sysrq handler through the input
layer which adds another few layers of parameter passing.
I've build this code with allyesconfig for x86_64 and i386. I've runtested the
main part of the code on FRV and i386, though I can't test most of the drivers.
I've also done partial conversion for powerpc and MIPS - these at least compile
with minimal configurations.
This will affect all archs. Mostly the changes should be relatively easy.
Take do_IRQ(), store the regs pointer at the beginning, saving the old one:
struct pt_regs *old_regs = set_irq_regs(regs);
And put the old one back at the end:
set_irq_regs(old_regs);
Don't pass regs through to generic_handle_irq() or __do_IRQ().
In timer_interrupt(), this sort of change will be necessary:
- update_process_times(user_mode(regs));
- profile_tick(CPU_PROFILING, regs);
+ update_process_times(user_mode(get_irq_regs()));
+ profile_tick(CPU_PROFILING);
I'd like to move update_process_times()'s use of get_irq_regs() into itself,
except that i386, alone of the archs, uses something other than user_mode().
Some notes on the interrupt handling in the drivers:
(*) input_dev() is now gone entirely. The regs pointer is no longer stored in
the input_dev struct.
(*) finish_unlinks() in drivers/usb/host/ohci-q.c needs checking. It does
something different depending on whether it's been supplied with a regs
pointer or not.
(*) Various IRQ handler function pointers have been moved to type
irq_handler_t.
Signed-Off-By: David Howells <dhowells@redhat.com>
(cherry picked from 1b16e7ac850969f38b375e511e3fa2f474a33867 commit)
2006-10-05 14:55:46 +01:00
|
|
|
|
2005-08-24 18:46:21 -05:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2006-10-03 16:18:35 +01:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2005-08-24 18:46:21 -05:00
|
|
|
|
2007-09-28 22:42:14 -07:00
|
|
|
|
2005-08-24 18:46:21 -05:00
|
|
|
|
2016-10-16 19:56:51 +02:00
|
|
|
|
2005-08-24 18:46:21 -05:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2007-03-06 02:41:48 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2010-10-21 08:37:41 +00:00
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
2014-01-05 03:23:19 +03:00
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
2005-08-24 18:46:21 -05:00
|
|
|
|
|
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
2014-01-05 03:23:19 +03:00
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
|
|
|
|
|
2007-03-06 02:41:48 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2010-10-21 08:37:41 +00:00
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2005-08-24 18:46:21 -05:00
|
|
|
|
2007-03-06 02:41:48 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2005-08-24 18:46:21 -05:00
|
|
|
|
2007-03-06 02:41:48 -08:00
|
|
|
|
|
|
|
|
|
2005-08-24 18:46:21 -05:00
|
|
|
|
|
|
|
|
|
2007-03-06 02:41:48 -08:00
|
|
|
|
2005-08-24 18:46:21 -05:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2007-09-28 22:42:14 -07:00
|
|
|
|
2016-10-16 19:56:50 +02:00
|
|
|
|
|
|
|
|
|
2016-10-16 19:56:52 +02:00
|
|
|
|
2012-06-09 07:49:07 +00:00
|
|
|
|
2016-01-06 20:11:16 +01:00
|
|
|
|
2005-08-24 18:46:21 -05:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2014-01-05 03:21:52 +03:00
|
|
|
|
2005-08-24 18:46:21 -05:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2007-03-06 02:41:48 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2005-08-24 18:46:21 -05:00
|
|
|
|
|
|
|
|
|
2014-01-05 03:23:19 +03:00
|
|
|
|
2005-08-24 18:46:21 -05:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2007-09-28 22:42:14 -07:00
|
|
|
|
|
|
|
|
|
2014-01-05 03:17:06 +03:00
|
|
|
|
2007-09-28 22:42:14 -07:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2005-08-24 18:46:21 -05:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2007-03-06 02:41:48 -08:00
|
|
|
|
2016-10-16 19:56:51 +02:00
|
|
|
|
|
|
|
|
|
2007-03-06 02:41:48 -08:00
|
|
|
|
2016-10-16 19:56:51 +02:00
|
|
|
|
2005-08-24 18:46:21 -05:00
|
|
|
|
2016-01-18 19:33:07 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2009-04-07 02:01:42 +00:00
|
|
|
|
2016-01-18 19:33:07 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2005-08-24 18:46:21 -05:00
|
|
|
|
2008-01-29 10:05:09 -06:00
|
|
|
|
2005-08-24 18:46:21 -05:00
|
|
|
|
|
|
|
|
|
2008-01-29 10:05:09 -06:00
|
|
|
|
2005-08-24 18:46:21 -05:00
|
|
|
|
2016-01-18 19:33:07 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2005-08-24 18:46:21 -05:00
|
|
|
|
2016-01-18 19:33:07 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2005-08-24 18:46:21 -05:00
|
|
|
|
2009-03-13 15:41:19 -07:00
|
|
|
|
2017-01-20 15:31:52 -08:00
|
|
|
|
2005-08-24 18:46:21 -05:00
|
|
|
|
|
|
|
|
|
2009-04-07 02:01:42 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2005-08-24 18:46:21 -05:00
|
|
|
|
|
|
|
|
|
2007-09-28 22:42:14 -07:00
|
|
|
|
2005-08-24 18:46:21 -05:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2016-10-16 19:56:51 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2007-03-06 02:41:48 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2005-08-24 18:46:21 -05:00
|
|
|
|
|
|
|
|
|
2008-01-29 10:05:09 -06:00
|
|
|
|
2005-08-24 18:46:21 -05:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2013-05-19 22:53:42 +00:00
|
|
|
|
2005-08-24 18:46:21 -05:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2006-10-03 16:18:35 +01:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2005-08-24 18:46:21 -05:00
|
|
|
|
2007-09-28 22:42:15 -07:00
|
|
|
|
|
|
|
|
|
2005-08-24 18:46:21 -05:00
|
|
|
|
2008-01-29 10:05:09 -06:00
|
|
|
|
2006-10-03 16:18:35 +01:00
|
|
|
|
2014-01-05 03:17:06 +03:00
|
|
|
|
2006-10-03 16:18:35 +01:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2005-08-24 18:46:21 -05:00
|
|
|
|
2014-01-05 03:17:06 +03:00
|
|
|
|
2005-08-24 18:46:21 -05:00
|
|
|
|
2007-03-06 02:41:48 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2005-08-24 18:46:21 -05:00
|
|
|
|
2007-03-06 02:41:48 -08:00
|
|
|
|
2005-08-24 18:46:21 -05:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2015-05-18 15:38:38 +12:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2008-01-29 10:05:09 -06:00
|
|
|
|
2005-08-24 18:46:21 -05:00
|
|
|
|
|
|
|
|
|
2013-12-17 21:38:12 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2015-05-18 15:38:38 +12:00
|
|
|
|
2016-05-10 17:42:26 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2015-05-18 15:38:38 +12:00
|
|
|
|
2013-12-17 21:38:12 -08:00
|
|
|
|
2015-05-18 15:38:38 +12:00
|
|
|
|
|
|
|
|
|
2013-12-17 21:38:12 -08:00
|
|
|
|
|
|
|
|
|
2005-08-24 18:46:21 -05:00
|
|
|
|
2008-01-29 10:05:09 -06:00
|
|
|
|
2015-05-18 15:38:38 +12:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
net: phy: Trigger state machine on state change and not polling.
The phy_start() is used to indicate the PHY is now ready to do its
work. The state is changed, normally to PHY_UP which means that both
the MAC and the PHY are ready.
If the phy driver is using polling, when the next poll happens, the
state machine notices the PHY is now in PHY_UP, and kicks off
auto-negotiation, if needed.
If however, the PHY is using interrupts, there is no polling. The phy
is stuck in PHY_UP until the next interrupt comes along. And there is
no reason for the PHY to interrupt.
Have phy_start() schedule the state machine to run, which both speeds
up the polling use case, and makes the interrupt use case actually
work.
This problems exists whenever there is a state change which will not
cause an interrupt. Trigger the state machine in these cases,
e.g. phy_error().
Signed-off-by: Andrew Lunn <andrew@lunn.ch>
Cc: Kyle Roeschley <kyle.roeschley@ni.com>
Tested-by: Kyle Roeschley <kyle.roeschley@ni.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2016-10-12 22:14:53 +02:00
|
|
|
|
2017-01-20 15:31:52 -08:00
|
|
|
|
2005-08-24 18:46:21 -05:00
|
|
|
|
|
|
|
|
|
2005-08-11 02:07:25 -04:00
|
|
|
|
2017-07-25 15:02:58 +01:00
|
|
|
|
2016-10-17 10:49:53 -05:00
|
|
|
|
2017-07-25 15:02:58 +01:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2016-10-17 10:49:55 -05:00
|
|
|
|
2016-10-17 10:49:53 -05:00
|
|
|
|
|
|
|
|
|
2008-01-29 10:05:09 -06:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2010-01-18 05:37:16 +00:00
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
2009-04-02 16:56:54 -07:00
|
|
|
|
2008-01-29 10:05:09 -06:00
|
|
|
|
2009-03-13 15:41:19 -07:00
|
|
|
|
2015-05-18 15:38:38 +12:00
|
|
|
|
2015-05-16 10:17:56 -07:00
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
2015-08-14 12:23:40 +08:00
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
2008-01-29 10:05:09 -06:00
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
2015-05-16 10:17:56 -07:00
|
|
|
|
|
|
|
|
|
2017-02-17 16:07:34 -08:00
|
|
|
|
2014-06-18 11:01:41 +02:00
|
|
|
|
|
|
|
|
|
2013-12-17 21:38:12 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2014-05-15 13:35:34 +08:00
|
|
|
|
2013-12-17 21:38:12 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
2013-12-17 21:38:12 -08:00
|
|
|
|
2014-01-05 03:17:06 +03:00
|
|
|
|
2013-12-17 21:38:12 -08:00
|
|
|
|
|
|
|
|
|
2017-07-25 15:02:58 +01:00
|
|
|
|
2013-12-17 21:38:12 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2014-01-05 03:17:06 +03:00
|
|
|
|
2013-12-17 21:38:12 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2017-07-25 15:02:58 +01:00
|
|
|
|
2014-04-09 09:03:45 +05:30
|
|
|
|
2014-05-15 13:35:34 +08:00
|
|
|
|
2013-12-17 21:38:12 -08:00
|
|
|
|
|
|
|
|
|
2015-11-16 23:36:46 +01:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2013-12-17 21:38:12 -08:00
|
|
|
|
|
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
2006-10-16 16:19:17 -05:00
|
|
|
|
2013-12-17 21:38:12 -08:00
|
|
|
|
2014-04-24 08:22:47 +05:30
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2013-12-17 21:38:12 -08:00
|
|
|
|
2017-07-25 15:02:58 +01:00
|
|
|
|
2013-12-17 21:38:12 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2006-10-16 16:19:17 -05:00
|
|
|
|
2013-12-17 21:38:12 -08:00
|
|
|
|
|
|
|
|
|
2017-07-25 15:02:58 +01:00
|
|
|
|
2013-12-17 21:38:12 -08:00
|
|
|
|
|
|
|
|
|
2014-05-15 13:35:34 +08:00
|
|
|
|
2017-07-25 15:02:58 +01:00
|
|
|
|
2013-12-17 21:38:12 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2016-01-18 19:33:06 -08:00
|
|
|
|
|
|
|
|
|
2013-12-17 21:38:12 -08:00
|
|
|
|
2016-01-18 19:33:06 -08:00
|
|
|
|
2015-08-14 12:23:40 +08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2017-01-06 12:14:48 +01:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2013-12-17 21:38:12 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2017-07-25 15:02:58 +01:00
|
|
|
|
2013-12-17 21:38:12 -08:00
|
|
|
|
|
|
|
|
|
2017-07-25 15:02:58 +01:00
|
|
|
|
2013-12-17 21:38:12 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2014-01-05 03:17:06 +03:00
|
|
|
|
2013-12-17 21:38:12 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2017-07-25 15:02:58 +01:00
|
|
|
|
2014-05-15 13:35:34 +08:00
|
|
|
|
2013-12-17 21:38:12 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2013-12-17 21:38:12 -08:00
|
|
|
|
2014-01-05 03:17:06 +03:00
|
|
|
|
|
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
2009-07-01 13:00:34 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2017-07-25 15:02:58 +01:00
|
|
|
|
2014-01-05 03:17:06 +03:00
|
|
|
|
2009-07-01 13:00:34 +00:00
|
|
|
|
2017-07-25 15:02:58 +01:00
|
|
|
|
2014-01-05 03:17:06 +03:00
|
|
|
|
2013-12-17 21:38:12 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2009-07-01 13:00:34 +00:00
|
|
|
|
2013-12-17 21:38:12 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2017-07-25 15:02:58 +01:00
|
|
|
|
2014-01-05 03:17:06 +03:00
|
|
|
|
2013-12-17 21:38:12 -08:00
|
|
|
|
2017-07-25 15:02:58 +01:00
|
|
|
|
2014-01-05 03:17:06 +03:00
|
|
|
|
2013-12-17 21:38:12 -08:00
|
|
|
|
|
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
|
|
|
|
|
2008-01-29 10:05:09 -06:00
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
|
|
|
|
|
2017-04-20 14:00:04 +03:00
|
|
|
|
2014-05-15 13:35:34 +08:00
|
|
|
|
2013-12-13 10:20:29 +01:00
|
|
|
|
|
|
|
|
|
2005-07-30 19:31:23 -04:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2017-07-28 13:18:30 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2015-05-16 10:17:56 -07:00
|
|
|
|
2016-01-18 19:33:06 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2008-01-29 10:05:09 -06:00
|
|
|
|
2012-06-27 21:14:38 +00:00
|
|
|
|
2016-10-16 19:56:51 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2013-05-19 22:53:43 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2016-01-18 19:33:07 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2013-05-19 22:53:43 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2012-06-27 21:14:38 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2017-02-17 16:07:34 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2012-06-27 21:14:38 +00:00
|
|
|
|
|
|
|
|
|
2017-03-31 10:37:18 +01:00
|
|
|
|
2012-06-27 21:14:38 +00:00
|
|
|
|
|
|
|
|
|
2014-03-04 17:35:44 -07:00
|
|
|
|
2012-06-27 21:14:38 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2017-03-21 16:36:53 +00:00
|
|
|
|
2014-08-26 09:26:52 +02:00
|
|
|
|
|
|
|
|
|
2012-06-27 21:14:38 +00:00
|
|
|
|
2012-08-20 04:55:29 +00:00
|
|
|
|
2012-06-27 21:14:38 +00:00
|
|
|
|
2014-08-26 09:26:52 +02:00
|
|
|
|
2012-06-27 21:14:38 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2017-03-21 16:36:53 +00:00
|
|
|
|
2014-08-26 09:26:52 +02:00
|
|
|
|
|
|
|
|
|
2012-06-27 21:14:38 +00:00
|
|
|
|
2017-03-21 16:36:53 +00:00
|
|
|
|
2014-08-26 09:26:52 +02:00
|
|
|
|
|
|
|
|
|
2012-06-27 21:14:38 +00:00
|
|
|
|
2012-08-20 04:55:29 +00:00
|
|
|
|
|
|
|
|
|
2015-02-17 09:36:22 -08:00
|
|
|
|
2014-08-26 09:26:52 +02:00
|
|
|
|
2012-06-27 21:14:38 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2017-03-21 16:36:53 +00:00
|
|
|
|
2012-06-27 21:14:38 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2017-03-21 16:36:53 +00:00
|
|
|
|
2012-06-27 21:14:38 +00:00
|
|
|
|
|
|
|
|
|
2014-01-05 03:21:52 +03:00
|
|
|
|
2012-06-27 21:14:38 +00:00
|
|
|
|
2014-08-26 09:26:52 +02:00
|
|
|
|
2014-01-05 03:21:52 +03:00
|
|
|
|
2012-06-27 21:14:38 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2017-02-17 16:07:34 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2017-03-21 16:36:53 +00:00
|
|
|
|
2012-06-27 21:14:38 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2017-02-17 16:07:34 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2012-06-27 21:14:38 +00:00
|
|
|
|
2017-03-21 16:36:53 +00:00
|
|
|
|
2012-06-27 21:14:38 +00:00
|
|
|
|
|
|
|
|
|
2012-08-20 04:55:29 +00:00
|
|
|
|
2012-06-27 21:14:38 +00:00
|
|
|
|
|
|
|
|
|
2017-03-21 16:36:53 +00:00
|
|
|
|
2012-06-27 21:14:38 +00:00
|
|
|
|
|
|
|
|
|
2012-08-20 04:55:29 +00:00
|
|
|
|
2012-06-27 21:14:38 +00:00
|
|
|
|
|
|
|
|
|
2017-03-21 16:36:53 +00:00
|
|
|
|
2012-06-27 21:14:38 +00:00
|
|
|
|
|
|
|
|
|
2012-08-20 04:55:29 +00:00
|
|
|
|
2012-06-27 21:14:38 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2017-03-31 10:37:12 +01:00
|
|
|
|
2012-06-27 21:14:38 +00:00
|
|
|
|
2017-02-17 16:07:34 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2017-03-31 10:37:07 +01:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2017-03-31 10:37:12 +01:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2017-03-31 10:37:07 +01:00
|
|
|
|
|
|
|
|
|
2016-11-28 10:46:46 +01:00
|
|
|
|
2017-03-31 10:37:07 +01:00
|
|
|
|
2016-11-28 10:46:46 +01:00
|
|
|
|
2017-03-31 10:37:12 +01:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2017-06-05 12:23:00 +01:00
|
|
|
|
2017-03-31 10:37:12 +01:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2012-06-27 21:14:38 +00:00
|
|
|
|
|
|
|
|
|
2013-03-11 13:56:44 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2017-02-17 16:07:34 -08:00
|
|
|
|
2013-03-11 13:56:44 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2017-02-17 16:07:34 -08:00
|
|
|
|
2013-03-11 13:56:44 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2016-05-10 00:19:41 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2017-06-13 10:09:46 +03:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2016-05-10 00:19:41 +02:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2016-11-15 10:06:30 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2017-02-17 16:07:34 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2017-06-05 12:23:00 +01:00
|
|
|
|
2016-11-15 10:06:30 -08:00
|
|
|
|
|
|
|
|
|