Re: [PATCH v3 net-next 1/2] lan743x: Add main source files for new lan743x driver

2018-03-02 Thread Andrew Lunn
> Hi Andrew, > > The phy is built in for LAN7430, and external for LAN7431. But the > same reset should work in both cases because it asserts the normal > phy reset line. Assuming the PHY reset is connect to the external line, not a GPIO. So this is O.K. > > Assuming it is built in, does the

RE: [PATCH v3 net-next 1/2] lan743x: Add main source files for new lan743x driver

2018-03-02 Thread Bryan.Whitehead
> > > > +static int lan743x_phy_reset(struct lan743x_adapter *adapter) { > > > > + u32 data; > > > > + > > > > + data = lan743x_csr_read(adapter, PMT_CTL); > > > > + data |= PMT_CTL_ETH_PHY_RST_; > > > > + lan743x_csr_write(adapter, PMT_CTL, data); > > > > + > > > > +

Re: [PATCH v3 net-next 1/2] lan743x: Add main source files for new lan743x driver

2018-03-02 Thread Andrew Lunn
On Fri, Mar 02, 2018 at 05:57:54AM +, bryan.whiteh...@microchip.com wrote: > > > +static int lan743x_phy_reset(struct lan743x_adapter *adapter) { > > > + u32 data; > > > + > > > + data = lan743x_csr_read(adapter, PMT_CTL); > > > + data |= PMT_CTL_ETH_PHY_RST_; > > > +

RE: [PATCH v3 net-next 1/2] lan743x: Add main source files for new lan743x driver

2018-03-01 Thread Bryan.Whitehead
> > +static int lan743x_phy_reset(struct lan743x_adapter *adapter) { > > + u32 data; > > + > > + data = lan743x_csr_read(adapter, PMT_CTL); > > + data |= PMT_CTL_ETH_PHY_RST_; > > + lan743x_csr_write(adapter, PMT_CTL, data); > > + > > + return readx_poll_timeout(LAN743X_CSR_READ_OP,

Re: [PATCH v3 net-next 1/2] lan743x: Add main source files for new lan743x driver

2018-03-01 Thread Andrew Lunn
On Thu, Mar 01, 2018 at 04:00:08PM -0500, Bryan Whitehead wrote: > +static int lan743x_phy_reset(struct lan743x_adapter *adapter) > +{ > + u32 data; > + > + data = lan743x_csr_read(adapter, PMT_CTL); > + data |= PMT_CTL_ETH_PHY_RST_; > + lan743x_csr_write(adapter, PMT_CTL, data);