[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <622f88b1-9607-48d6-b44d-8aeec8acfd34@lunn.ch>
Date: Thu, 27 Apr 2023 14:25:03 +0200
From: Andrew Lunn <andrew@...n.ch>
To: Hayes Wang <hayeswang@...ltek.com>
Cc: kuba@...nel.org, davem@...emloft.net, netdev@...r.kernel.org,
nic_swsd@...ltek.com, linux-kernel@...r.kernel.org,
linux-usb@...r.kernel.org
Subject: Re: [PATCH net v2 2/3] r8152: fix the poor throughput for 2.5G
devices
> @@ -7554,6 +7558,11 @@ static void r8156_hw_phy_cfg(struct r8152 *tp)
> ((swap_a & 0x1f) << 8) |
> ((swap_a >> 8) & 0x1f));
> }
> +
> + /* set intr_en[3] */
> + data = ocp_reg_read(tp, OCP_INTR_EN);
> + data |= INTR_SPEED_FORCE;
Which is more meaningful, set intr_en[3], or data |= INTR_SPEED_FORCE
I would say the second. The code is now pretty readable, it says
what it is doing. So if you want to add a comment, you really should
be commenting on why, not what.
Andrew
Powered by blists - more mailing lists