[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20220131180946.sqxcbnhu54ajc5am@microsemi.com>
Date: Mon, 31 Jan 2022 23:39:46 +0530
From: Raju Lakkaraju <Raju.Lakkaraju@...rochip.com>
To: Andrew Lunn <andrew@...n.ch>
CC: <netdev@...r.kernel.org>, <davem@...emloft.net>, <kuba@...nel.org>,
<UNGLinuxDriver@...rochip.com>
Subject: Re: [PATCH net-next 4/5] net: lan743x: Add support of selection
between SGMII and GMII Interface
Hi Andrew,
Thank you for review comments.
The 01/27/2022 23:08, Andrew Lunn wrote:
> EXTERNAL EMAIL: Do not click links or open attachments unless you know the content is safe
>
> > + /* GPY211 Interface enable */
> > + chip_ver = lan743x_csr_read(adapter, FPGA_REV);
> > + if (chip_ver) {
> > + netif_info(adapter, drv, adapter->netdev,
> > + "FPGA Image version: 0x%08X\n", chip_ver);
>
> We try to avoid spamming the kernel logs, so:
>
> netif_dbg()
>
Accepted. I will change
> > + if (chip_ver & FPGA_SGMII_OP) {
> > + sgmii_ctl = lan743x_csr_read(adapter, SGMII_CTL);
> > + sgmii_ctl |= SGMII_CTL_SGMII_ENABLE_;
> > + sgmii_ctl &= ~SGMII_CTL_SGMII_POWER_DN_;
> > + lan743x_csr_write(adapter, SGMII_CTL, sgmii_ctl);
> > + netif_info(adapter, drv, adapter->netdev, "SGMII operation\n");
> > + } else {
> > + sgmii_ctl = lan743x_csr_read(adapter, SGMII_CTL);
> > + sgmii_ctl &= ~SGMII_CTL_SGMII_ENABLE_;
> > + sgmii_ctl |= SGMII_CTL_SGMII_POWER_DN_;
> > + lan743x_csr_write(adapter, SGMII_CTL, sgmii_ctl);
> > + netif_info(adapter, drv, adapter->netdev, "GMII operation\n");
> > + }
> > + } else {
> > + chip_ver = lan743x_csr_read(adapter, STRAP_READ);
> > + netif_info(adapter, drv, adapter->netdev,
> > + "ASIC Image version: 0x%08X\n", chip_ver);
>
> Here as well
>
Accepted. I will change.
> > + if (chip_ver & STRAP_READ_SGMII_EN_) {
> > + sgmii_ctl = lan743x_csr_read(adapter, SGMII_CTL);
> > + sgmii_ctl |= SGMII_CTL_SGMII_ENABLE_;
> > + sgmii_ctl &= ~SGMII_CTL_SGMII_POWER_DN_;
> > + lan743x_csr_write(adapter, SGMII_CTL, sgmii_ctl);
> > + netif_info(adapter, drv, adapter->netdev, "SGMII operation\n");
>
> And def initially this and the next one.
>
I did not get "def initially" means ?
Can you please some more information about this comment ?
> > + } else {
> > + sgmii_ctl = lan743x_csr_read(adapter, SGMII_CTL);
> > + sgmii_ctl &= ~SGMII_CTL_SGMII_ENABLE_;
> > + sgmii_ctl |= SGMII_CTL_SGMII_POWER_DN_;
> > + lan743x_csr_write(adapter, SGMII_CTL, sgmii_ctl);
> > + netif_info(adapter, drv, adapter->netdev, "GMII operation\n");
> > + }
> > + }
>
> Andrew
--
Thanks,
Raju
Powered by blists - more mailing lists