diff mbox series

[RFC,v1,net-next,2/7] mfd: ocelot: add ocelot-serdes capability

Message ID 20230216075321.2898003-3-colin.foster@in-advantage.com (mailing list archive)
State RFC
Delegated to: Netdev Maintainers
Headers show
Series add support for ocelot external ports | expand

Checks

Context Check Description
netdev/tree_selection success Clearly marked for net-next
netdev/fixes_present success Fixes tag not required for -next series
netdev/subject_prefix success Link
netdev/cover_letter success Series has a cover letter
netdev/patch_count success Link
netdev/header_inline success No static functions without inline keyword in header files
netdev/build_32bit success Errors and warnings before: 0 this patch: 0
netdev/cc_maintainers success CCed 2 of 2 maintainers
netdev/build_clang success Errors and warnings before: 0 this patch: 0
netdev/module_param success Was 0 now: 0
netdev/verify_signedoff success Signed-off-by tag matches author and committer
netdev/check_selftest success No net selftest shell script
netdev/verify_fixes success No Fixes tag
netdev/build_allmodconfig_warn success Errors and warnings before: 0 this patch: 0
netdev/checkpatch warning WARNING: line length of 84 exceeds 80 columns
netdev/kdoc success Errors and warnings before: 0 this patch: 0
netdev/source_inline success Was 0 now: 0

Commit Message

Colin Foster Feb. 16, 2023, 7:53 a.m. UTC
Add support for the Ocelot SERDES module to support functionality of all
non-internal phy ports.

Signed-off-by: Colin Foster <colin.foster@in-advantage.com>
---
 drivers/mfd/ocelot-core.c | 13 +++++++++++++
 1 file changed, 13 insertions(+)

Comments

Lee Jones March 3, 2023, 10:48 a.m. UTC | #1
On Wed, 15 Feb 2023, Colin Foster wrote:

> Add support for the Ocelot SERDES module to support functionality of all
> non-internal phy ports.

Looks non-controversial.

Please provide some explanation of what SERDES means / is.
 
> Signed-off-by: Colin Foster <colin.foster@in-advantage.com>
> ---
>  drivers/mfd/ocelot-core.c | 13 +++++++++++++
>  1 file changed, 13 insertions(+)

I'd expect this to go in via MFD once it comes out of RFC.

> diff --git a/drivers/mfd/ocelot-core.c b/drivers/mfd/ocelot-core.c
> index b0ff05c1759f..c2224f8a16c0 100644
> --- a/drivers/mfd/ocelot-core.c
> +++ b/drivers/mfd/ocelot-core.c
> @@ -45,6 +45,9 @@
>  #define VSC7512_SIO_CTRL_RES_START	0x710700f8
>  #define VSC7512_SIO_CTRL_RES_SIZE	0x00000100
>  
> +#define VSC7512_HSIO_RES_START		0x710d0000
> +#define VSC7512_HSIO_RES_SIZE		0x00000128
> +
>  #define VSC7512_ANA_RES_START		0x71880000
>  #define VSC7512_ANA_RES_SIZE		0x00010000
>  
> @@ -129,8 +132,13 @@ static const struct resource vsc7512_sgpio_resources[] = {
>  	DEFINE_RES_REG_NAMED(VSC7512_SIO_CTRL_RES_START, VSC7512_SIO_CTRL_RES_SIZE, "gcb_sio"),
>  };
>  
> +static const struct resource vsc7512_serdes_resources[] = {
> +	DEFINE_RES_REG_NAMED(VSC7512_HSIO_RES_START, VSC7512_HSIO_RES_SIZE, "hsio"),
> +};
> +
>  static const struct resource vsc7512_switch_resources[] = {
>  	DEFINE_RES_REG_NAMED(VSC7512_ANA_RES_START, VSC7512_ANA_RES_SIZE, "ana"),
> +	DEFINE_RES_REG_NAMED(VSC7512_HSIO_RES_START, VSC7512_HSIO_RES_SIZE, "hsio"),
>  	DEFINE_RES_REG_NAMED(VSC7512_QS_RES_START, VSC7512_QS_RES_SIZE, "qs"),
>  	DEFINE_RES_REG_NAMED(VSC7512_QSYS_RES_START, VSC7512_QSYS_RES_SIZE, "qsys"),
>  	DEFINE_RES_REG_NAMED(VSC7512_REW_RES_START, VSC7512_REW_RES_SIZE, "rew"),
> @@ -176,6 +184,11 @@ static const struct mfd_cell vsc7512_devs[] = {
>  		.use_of_reg = true,
>  		.num_resources = ARRAY_SIZE(vsc7512_miim1_resources),
>  		.resources = vsc7512_miim1_resources,
> +	}, {
> +		.name = "ocelot-serdes",
> +		.of_compatible = "mscc,vsc7514-serdes",
> +		.num_resources = ARRAY_SIZE(vsc7512_serdes_resources),
> +		.resources = vsc7512_serdes_resources,
>  	}, {
>  		.name = "ocelot-switch",
>  		.of_compatible = "mscc,vsc7512-switch",
> -- 
> 2.25.1
>
Colin Foster March 3, 2023, 3:12 p.m. UTC | #2
On Fri, Mar 03, 2023 at 10:48:07AM +0000, Lee Jones wrote:
> On Wed, 15 Feb 2023, Colin Foster wrote:
> 
> > Add support for the Ocelot SERDES module to support functionality of all
> > non-internal phy ports.
> 
> Looks non-controversial.
> 
> Please provide some explanation of what SERDES means / is.

Will do.

>  
> > Signed-off-by: Colin Foster <colin.foster@in-advantage.com>
> > ---
> >  drivers/mfd/ocelot-core.c | 13 +++++++++++++
> >  1 file changed, 13 insertions(+)
> 
> I'd expect this to go in via MFD once it comes out of RFC.

Understood. I'll be sure to make it clear that some sync will be needed
between MFD and net-next in the cover letter this time.

Thanks Lee!
Lee Jones March 3, 2023, 9:57 p.m. UTC | #3
On Fri, 03 Mar 2023, Colin Foster wrote:

> On Fri, Mar 03, 2023 at 10:48:07AM +0000, Lee Jones wrote:
> > On Wed, 15 Feb 2023, Colin Foster wrote:
> > 
> > > Add support for the Ocelot SERDES module to support functionality of all
> > > non-internal phy ports.
> > 
> > Looks non-controversial.
> > 
> > Please provide some explanation of what SERDES means / is.
> 
> Will do.
> 
> >  
> > > Signed-off-by: Colin Foster <colin.foster@in-advantage.com>
> > > ---
> > >  drivers/mfd/ocelot-core.c | 13 +++++++++++++
> > >  1 file changed, 13 insertions(+)
> > 
> > I'd expect this to go in via MFD once it comes out of RFC.
> 
> Understood. I'll be sure to make it clear that some sync will be needed
> between MFD and net-next in the cover letter this time.

To be honest, I don't think that's required this time.

This patch looks orthogonal, unless there's something I'm missing.
 
> Thanks Lee!

NP
diff mbox series

Patch

diff --git a/drivers/mfd/ocelot-core.c b/drivers/mfd/ocelot-core.c
index b0ff05c1759f..c2224f8a16c0 100644
--- a/drivers/mfd/ocelot-core.c
+++ b/drivers/mfd/ocelot-core.c
@@ -45,6 +45,9 @@ 
 #define VSC7512_SIO_CTRL_RES_START	0x710700f8
 #define VSC7512_SIO_CTRL_RES_SIZE	0x00000100
 
+#define VSC7512_HSIO_RES_START		0x710d0000
+#define VSC7512_HSIO_RES_SIZE		0x00000128
+
 #define VSC7512_ANA_RES_START		0x71880000
 #define VSC7512_ANA_RES_SIZE		0x00010000
 
@@ -129,8 +132,13 @@  static const struct resource vsc7512_sgpio_resources[] = {
 	DEFINE_RES_REG_NAMED(VSC7512_SIO_CTRL_RES_START, VSC7512_SIO_CTRL_RES_SIZE, "gcb_sio"),
 };
 
+static const struct resource vsc7512_serdes_resources[] = {
+	DEFINE_RES_REG_NAMED(VSC7512_HSIO_RES_START, VSC7512_HSIO_RES_SIZE, "hsio"),
+};
+
 static const struct resource vsc7512_switch_resources[] = {
 	DEFINE_RES_REG_NAMED(VSC7512_ANA_RES_START, VSC7512_ANA_RES_SIZE, "ana"),
+	DEFINE_RES_REG_NAMED(VSC7512_HSIO_RES_START, VSC7512_HSIO_RES_SIZE, "hsio"),
 	DEFINE_RES_REG_NAMED(VSC7512_QS_RES_START, VSC7512_QS_RES_SIZE, "qs"),
 	DEFINE_RES_REG_NAMED(VSC7512_QSYS_RES_START, VSC7512_QSYS_RES_SIZE, "qsys"),
 	DEFINE_RES_REG_NAMED(VSC7512_REW_RES_START, VSC7512_REW_RES_SIZE, "rew"),
@@ -176,6 +184,11 @@  static const struct mfd_cell vsc7512_devs[] = {
 		.use_of_reg = true,
 		.num_resources = ARRAY_SIZE(vsc7512_miim1_resources),
 		.resources = vsc7512_miim1_resources,
+	}, {
+		.name = "ocelot-serdes",
+		.of_compatible = "mscc,vsc7514-serdes",
+		.num_resources = ARRAY_SIZE(vsc7512_serdes_resources),
+		.resources = vsc7512_serdes_resources,
 	}, {
 		.name = "ocelot-switch",
 		.of_compatible = "mscc,vsc7512-switch",