From: Andrew Lunn <andrew@lunn.ch>
To: Stefan Chulski <stefanc@marvell.com>
Cc: Russell King - ARM Linux admin <linux@armlinux.org.uk>,
"netdev@vger.kernel.org" <netdev@vger.kernel.org>,
"thomas.petazzoni@bootlin.com" <thomas.petazzoni@bootlin.com>,
"davem@davemloft.net" <davem@davemloft.net>,
Nadav Haklai <nadavh@marvell.com>,
Yan Markman <ymarkman@marvell.com>,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
"kuba@kernel.org" <kuba@kernel.org>,
"mw@semihalf.com" <mw@semihalf.com>,
"atenart@kernel.org" <atenart@kernel.org>
Subject: Re: [EXT] Re: [PATCH v2 RFC net-next 04/18] net: mvpp2: add PPv23 version definition
Date: Sun, 24 Jan 2021 20:03:48 +0100 [thread overview]
Message-ID: <YA3ElJbfk9Km2HiF@lunn.ch> (raw)
In-Reply-To: <CO6PR18MB387343A510B3C5A9C5E004B2B0BE9@CO6PR18MB3873.namprd18.prod.outlook.com>
On Sun, Jan 24, 2021 at 01:55:42PM +0000, Stefan Chulski wrote:
> > > Signed-off-by: Stefan Chulski <stefanc@marvell.com>
> > > ---
> > > drivers/net/ethernet/marvell/mvpp2/mvpp2.h | 24 ++++++++++++------
> > --
> > > drivers/net/ethernet/marvell/mvpp2/mvpp2_main.c | 17 +++++++++-----
> > > 2 files changed, 25 insertions(+), 16 deletions(-)
> > >
> > > diff --git a/drivers/net/ethernet/marvell/mvpp2/mvpp2.h
> > > b/drivers/net/ethernet/marvell/mvpp2/mvpp2.h
> > > index aec9179..89b3ede 100644
> > > --- a/drivers/net/ethernet/marvell/mvpp2/mvpp2.h
> > > +++ b/drivers/net/ethernet/marvell/mvpp2/mvpp2.h
> > > @@ -60,6 +60,9 @@
> > > /* Top Registers */
> > > #define MVPP2_MH_REG(port) (0x5040 + 4 * (port))
> > > #define MVPP2_DSA_EXTENDED BIT(5)
> > > +#define MVPP2_VER_ID_REG 0x50b0
> > > +#define MVPP2_VER_PP22 0x10
> > > +#define MVPP2_VER_PP23 0x11
> >
> > Looking at the Armada 8040 docs, it seems this register exists on
> > PPv2.1 as well, and holds the value zero there.
> >
> > I wonder whether we should instead read it's value directly into hw_version,
> > and test against these values, rather than inventing our own verison enum.
> >
> > I've also been wondering whether your != MVPP21 comparisons should
> > instead be >= MVPP22.
> >
> > Any thoughts?
>
> We cannot access PPv2 register space before enabling clocks(done in mvpp2_probe) , PP21 and PP22/23 have different sets of clocks.
> So diff between PP21 and PP22/23 should be stored in device tree(in
> of_device_id), with MVPP22 and MVPP21 stored as .data
Hi Stefan
As far as i can see, you are not adding a new compatible. So
'marvell,armada-7k-pp2' means PPv2.2 and PPv2.3? It would be good to
update the comment at the beginning of marvell-pp2.txt to indicate
this.
Andrew
next prev parent reply other threads:[~2021-01-24 19:04 UTC|newest]
Thread overview: 36+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-01-24 11:43 [PATCH v2 RFC net-next 00/18] net: mvpp2: Add TX Flow Control support stefanc
2021-01-24 11:43 ` [PATCH v2 RFC net-next 01/18] doc: marvell: add cm3-mem device tree bindings description stefanc
2021-01-24 11:43 ` [PATCH v2 RFC net-next 02/18] dts: marvell: add CM3 SRAM memory to cp115 ethernet device tree stefanc
2021-01-24 11:43 ` [PATCH v2 RFC net-next 03/18] net: mvpp2: add CM3 SRAM memory map stefanc
2021-01-24 12:28 ` Russell King - ARM Linux admin
2021-01-24 12:44 ` Russell King - ARM Linux admin
2021-01-24 18:51 ` Andrew Lunn
2021-01-24 18:46 ` Andrew Lunn
2021-01-25 7:16 ` [EXT] " Stefan Chulski
2021-01-24 11:43 ` [PATCH v2 RFC net-next 04/18] net: mvpp2: add PPv23 version definition stefanc
2021-01-24 13:18 ` Russell King - ARM Linux admin
2021-01-24 13:55 ` [EXT] " Stefan Chulski
2021-01-24 19:03 ` Andrew Lunn [this message]
2021-01-25 7:12 ` Stefan Chulski
2021-01-24 11:43 ` [PATCH v2 RFC net-next 05/18] net: mvpp2: always compare hw-version vs MVPP21 stefanc
2021-01-24 11:43 ` [PATCH v2 RFC net-next 06/18] net: mvpp2: increase BM pool size to 2048 buffers stefanc
2021-01-24 11:43 ` [PATCH v2 RFC net-next 07/18] net: mvpp2: increase RXQ size to 1024 descriptors stefanc
2021-01-24 11:43 ` [PATCH v2 RFC net-next 08/18] net: mvpp2: add FCA periodic timer configurations stefanc
2021-01-24 12:14 ` Russell King - ARM Linux admin
2021-01-24 14:43 ` [EXT] " Stefan Chulski
2021-01-24 19:11 ` Andrew Lunn
2021-01-25 7:15 ` Stefan Chulski
2021-01-24 11:43 ` [PATCH v2 RFC net-next 09/18] net: mvpp2: add FCA RXQ non occupied descriptor threshold stefanc
2021-01-24 13:01 ` Russell King - ARM Linux admin
2021-01-24 13:24 ` [EXT] " Stefan Chulski
2021-01-24 11:43 ` [PATCH v2 RFC net-next 10/18] net: mvpp2: add spinlock for FW FCA configuration path stefanc
2021-01-24 11:44 ` [PATCH v2 RFC net-next 11/18] net: mvpp2: enable global flow control stefanc
2021-01-24 11:44 ` [PATCH v2 RFC net-next 12/18] net: mvpp2: add RXQ flow control configurations stefanc
2021-01-24 11:44 ` [PATCH v2 RFC net-next 13/18] net: mvpp2: add ethtool flow control configuration support stefanc
2021-01-24 12:35 ` Russell King - ARM Linux admin
2021-01-24 12:39 ` [EXT] " Stefan Chulski
2021-01-24 11:44 ` [PATCH v2 RFC net-next 14/18] net: mvpp2: add BM protection underrun feature support stefanc
2021-01-24 11:44 ` [PATCH v2 RFC net-next 15/18] net: mvpp2: add PPv23 RX FIFO flow control stefanc
2021-01-24 11:44 ` [PATCH v2 RFC net-next 16/18] net: mvpp2: set 802.3x GoP Flow Control mode stefanc
2021-01-24 11:44 ` [PATCH v2 RFC net-next 17/18] net: mvpp2: limit minimum ring size to 1024 descriptors stefanc
2021-01-24 11:44 ` [PATCH v2 RFC net-next 18/18] net: mvpp2: add TX FC firmware check stefanc
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=YA3ElJbfk9Km2HiF@lunn.ch \
--to=andrew@lunn.ch \
--cc=atenart@kernel.org \
--cc=davem@davemloft.net \
--cc=kuba@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux@armlinux.org.uk \
--cc=mw@semihalf.com \
--cc=nadavh@marvell.com \
--cc=netdev@vger.kernel.org \
--cc=stefanc@marvell.com \
--cc=thomas.petazzoni@bootlin.com \
--cc=ymarkman@marvell.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).