[PATCH net-next v2 2/5] net: phy: mediatek: Add token ring access helper functions in mtk-phy-lib
Andrew Lunn
andrew at lunn.ch
Sun Feb 16 08:47:42 PST 2025
On Thu, Feb 13, 2025 at 04:05:50PM +0800, Sky Huang wrote:
> From: Sky Huang <skylake.huang at mediatek.com>
>
> This patch adds TR(token ring) manipulations and adds correct
> macro names for those magic numbers. TR is a way to access
> proprietary registers on page 52b5. Use these helper functions
> so we can see which fields we're going to modify/set/clear.
>
> TR functions with __* prefix mean that the operations inside
> aren't wrapped by page select/restore functions.
>
> This patch doesn't really change registers' settings but just
> enhances readability and maintainability.
>
> Signed-off-by: Sky Huang <skylake.huang at mediatek.com>
This is better, a bit smaller, but still pretty big. If you have made
a typo, and broken it, it is going to take a while to find it, no help
from git bisect.
Reviewed-by: Andrew Lunn <andrew at lunn.ch>
Andrew
More information about the linux-arm-kernel
mailing list