[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <Y3KjFLibpFlws1N5@lunn.ch>
Date: Mon, 14 Nov 2022 21:20:36 +0100
From: Andrew Lunn <andrew@...n.ch>
To: Alexander Lobakin <alexandr.lobakin@...el.com>
Cc: Mengyuan Lou <mengyuanlou@...-swift.com>, netdev@...r.kernel.org,
jiawenwu@...stnetic.com
Subject: Re: [PATCH net-next 3/5] net: txgbe: Support to setup link
On Mon, Nov 14, 2022 at 04:48:24PM +0100, Alexander Lobakin wrote:
> From: Mengyuan Lou <mengyuanlou@...-swift.com>
> Date: Tue, 8 Nov 2022 19:19:05 +0800
>
> > From: Jiawen Wu <jiawenwu@...stnetic.com>
> >
> > Get link capabilities, setup MAC and PHY link, and support to enable
> > or disable Tx laser.
> >
> > Signed-off-by: Jiawen Wu <jiawenwu@...stnetic.com>
> > ---
> >
> > [...]
> >
> > @@ -46,6 +55,13 @@ struct txgbe_adapter {
> > struct timer_list service_timer;
> > struct work_struct service_task;
> >
> > + u32 flags;
> > +
> > + bool link_up;
>
> Use can reuse the previous field flags to store link status.
>
> Also pls try to avoid placing bools in structures, there are lots of
> discussions around it and how compilers place/declare them, but
> better to know for sure it would work the same way on each setup,
> right?
It is likely a lot of this code goes away one phylink it used.
Andrew
Powered by blists - more mailing lists