Thread (24 messages) flat view 24 messages, 3 authors, 2021-05-26

Re: [RFC PATCH v2 linux-next 13/14] net: dsa: sja1105: expose the SGMII PCS as an mdio_device

From: Vladimir Oltean <olteanv@gmail.com>
Date: 2021-05-26 15:41:14

On Wed, May 26, 2021 at 04:29:11PM +0100, Russell King (Oracle) wrote:
On Wed, May 26, 2021 at 04:55:34PM +0300, Vladimir Oltean wrote:
quoted
Since we touch all PCS accessors again, now it is a good time to check
for error codes from the hardware access as well. We can't propagate the
errors very far due to phylink returning void for mac_config and
mac_link_up, but at least we print them to the console.
phylink doesn't have much option on what it could do if we error out at
those points - I suppose we could print a non-specific error and then
lock-out the interface in a similar way that phylib does, but to me that
seems really unfriendly if you're remotely accessing a box and the error
is intermittent.
I would like to have intermittent errors at this level logged, because
to me they would be quite unexpected and I would like to have some rope
to pull while debugging - an error code, something.

If there's an error of any sort, the interface won't be fully
initialized anyway, so not functional.

The reason why I added error checking in this patch is because I was
working on the MDIO bus accessors and I wanted to make sure that the
errors returned there are propagated somewhere.
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help