Re: [PATCH v2 resub 1/2] net: include: mii: Refactor: Define LPA_* in terms of ADVERTISE_*

From: Csókás Bence
Date: Fri Jun 21 2024 - 03:48:48 EST


Hi

On 6/20/24 21:07, Andrew Lunn wrote:
On Wed, Jun 19, 2024 at 02:46:22PM +0200, Csókás, Bence wrote:
Ethernet specification mandates that these bits will be equal.
To reduce the amount of magix hex'es in the code, just define
them in terms of each other.

I have a quick email exchange with other PHY maintainers, and we
agree. We will reject these changes, they are just churn and bring no
real benefit.

NACK

Andrew


The benefit is that I don't have to constantly convert between "n-th bit set" (which is how virtually all datasheets, specifications, documentation etc. represent MII bits) and these hex values. In most places in the kernel, register bits are already represented with BIT() et al., so why not here?

Bence