Re: Re: [PATCH net-next v2 1/2] mv88e6xxx: Refactor 6352's serdes functions

From: Fidan Aliyeva

Date: Sun May 03 2026 - 17:45:27 EST


> > > > I wanted to make those functions generic and not introduce new
> > > > functions other than 6321_serdes_get_lane. However, those
> > > > functions cannot be generalised the obvious way because they run
> > > > with reg_lock already taken which would cause deadlock in mv88e6352_serdes_get_lane function.
> > >
> > > Ah, the scratch register. None of the other serdes_get_lane() functions need to read a register. O.K.
> > >
> > > So we don't expect the scratch register to change at runtime do we?
> > >
> > > Nope, the value in it is read during reset. After that, it does not matter what happens to the pin, the value in the scratch register is fixed. So maybe read it during mv88e6xxx_setup_port() and store the value in struct mv88e6xxx_port?
> >
> > Hi again. Thank you for your feedback. I can make the proposed change.
> > But I do not have the functional specification for 6352 to refer the
> > change to, neither do I have access to a 6352 to be able to test the change on.
> > Do you have the functional specification document of the switch, maybe?
>
> I have a 6352 board i can test with. It does not have any fibre ports, but i can test it does not deadlock, or give an error message about the lock not being held.

That is kind of you. We appreciate your help, thank you!

We will prepare the patch and send it for RFC.

Best,
Fidan