Skip to content

net: sun8i-emac fixes and cleanups

Andre Przywara u-boot 1 version New

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest15 patches 0 repliesNew

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/15net: sun8i-emac: Bail out on PHY errordrivers/net/sun8i_emac.c+4 -10 replies
2/15net: sun8i_emac: Don't hand out TX descriptor too earlydrivers/net/sun8i_emac.c+1 -10 replies
3/15net: sun8i_emac: Simplify mdio_read/mdio_write functionsdrivers/net/sun8i_emac.c+22 -410 replies
4/15net: sun8i_emac: Remove pointless wrapper functionsdrivers/net/sun8i_emac.c+16 -460 replies
5/15net: sun8i_emac: Name magic bits and simplify read-modify-write callsdrivers/net/sun8i_emac.c+61 -520 replies
6/15net: sun8i_emac: Improve cache maintenance on RX descriptor initdrivers/net/sun8i_emac.c+9 -40 replies
7/15net: sun8i_emac: Reduce cache maintenance on TX descriptor initdrivers/net/sun8i_emac.c+2 -20 replies
8/15net: sun8i_emac: Drop unneeded cache invalidation before sendingdrivers/net/sun8i_emac.c+0 -30 replies
9/15net: sun8i_emac: Wrap and simplify cache maintenance operationsdrivers/net/sun8i_emac.c+14 -190 replies
10/15net: sun8i_emac: Fix overlong linesdrivers/net/sun8i_emac.c+10 -120 replies
11/15net: sun8i_emac: Fix MAC soft resetdrivers/net/sun8i_emac.c+7 -140 replies
12/15net: sun8i_emac: Simplify and fix error handling for RXdrivers/net/sun8i_emac.c+30 -260 replies
13/15net: sun8i-emac: Make internal PHY handling more robustdrivers/net/sun8i_emac.c+16 -320 replies
14/15net: sun8i-emac: Lower MDIO frequencydrivers/net/sun8i_emac.c+17 -01 reply
14/15net: sun8i-emac: Lower MDIO frequency+0 -00 replies
15/15sunxi: Pine-H64: Explicitly enable PHY regulatorconfigs/pine_h64_defconfig+1 -00 replies

Reviews trailers per patch

None of the 16 patches has a Reviewed-by or Acked-by of their own; the series has one for all of them.

PatchMaxime RipardAmit Singh Tomar
SeriesA-b T-b
1/15
2/15
3/15
4/15
5/15
6/15
7/15
8/15
9/15
10/15
11/15
12/15
13/15
14/15
14/15
15/15

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v1 thread

Cover letter [PATCH 00/15] net: sun8i-emac fixes and cleanups

Hi,

while looking at several U-Boot network drivers in the past year, I typically compared them to the sun8i-emac driver, as a kind of personal reference. While doing so, I figured that there are quite some things broken in here, and other things are not so nice.
This series attempts the fix those shortcomings.
Fix-wise we get proper handling of PHY failures (try without a cable connected), support for external RMII PHYs (as seen on the Pine64-non-plus model), and more future-proof internal PHY handling. The rest of the patches are cleanups, which fix things that are wrong, but we get away with so far, for one or another reason.
This also cleans up a good part of the cache maintenance. There is more to be done (and I have patches for that), but that requires to drop the overzealous alignment checks in cache_v7.c first, which is part of another, upcoming series.

A git repo with those patches can be found here:
https://github.com/apritzel/u-boot/commits/sun8i-emac-cleanup

Please have a look and send comments!

Cheers,
Andre

Andre Przywara (15):
net: sun8i-emac: Bail out on PHY error
net: sun8i_emac: Don't hand out TX descriptor too early
net: sun8i_emac: Simplify mdio_read/mdio_write functions
net: sun8i_emac: Remove pointless wrapper functions
net: sun8i_emac: Name magic bits and simplify read-modify-write calls
net: sun8i_emac: Improve cache maintenance on RX descriptor init
net: sun8i_emac: Reduce cache maintenance on TX descriptor init
net: sun8i_emac: Drop unneeded cache invalidation before sending
net: sun8i_emac: Wrap and simplify cache maintenance operations
net: sun8i_emac: Fix overlong lines
net: sun8i_emac: Fix MAC soft reset
net: sun8i_emac: Simplify and fix error handling for RX
net: sun8i-emac: Make internal PHY handling more robust
net: sun8i-emac: Lower MDIO frequency
sunxi: Pine-H64: Explicitly enable PHY regulator

 configs/pine_h64_defconfig |   1 +
 drivers/net/sun8i_emac.c   | 458 +++++++++++++++++--------------------
 2 files changed, 208 insertions(+), 251 deletions(-)
Signature · 1 line
2.17.5