* [PATCH] net: phy: Add micrel KSZ8031
@ 2013-10-22 10:46 Markus Pargmann
2013-10-22 14:26 ` Jean-Christophe PLAGNIOL-VILLARD
2013-10-26 8:12 ` Sascha Hauer
0 siblings, 2 replies; 4+ messages in thread
From: Markus Pargmann @ 2013-10-22 10:46 UTC (permalink / raw)
To: Sascha Hauer; +Cc: barebox
KSZ8031 is similar to KSZ8021. It can use the same functions.
Signed-off-by: Markus Pargmann <mpa@pengutronix.de>
---
drivers/net/phy/micrel.c | 9 +++++++++
include/linux/micrel_phy.h | 1 +
2 files changed, 10 insertions(+)
diff --git a/drivers/net/phy/micrel.c b/drivers/net/phy/micrel.c
index c0bcdd1..3cba2c4 100644
--- a/drivers/net/phy/micrel.c
+++ b/drivers/net/phy/micrel.c
@@ -122,6 +122,15 @@ static struct phy_driver ksphy_driver[] = {
.config_aneg = genphy_config_aneg,
.read_status = genphy_read_status,
}, {
+ .phy_id = PHY_ID_KSZ8031,
+ .phy_id_mask = 0x00ffffff,
+ .drv.name = "Micrel KSZ8031",
+ .features = (PHY_BASIC_FEATURES | SUPPORTED_Pause |
+ SUPPORTED_Asym_Pause),
+ .config_init = ksz8021_config_init,
+ .config_aneg = genphy_config_aneg,
+ .read_status = genphy_read_status,
+}, {
.phy_id = PHY_ID_KSZ8041,
.phy_id_mask = 0x00fffff0,
.drv.name = "Micrel KSZ8041",
diff --git a/include/linux/micrel_phy.h b/include/linux/micrel_phy.h
index 9dbb41a..8752dbb 100644
--- a/include/linux/micrel_phy.h
+++ b/include/linux/micrel_phy.h
@@ -19,6 +19,7 @@
#define PHY_ID_KSZ9021 0x00221610
#define PHY_ID_KS8737 0x00221720
#define PHY_ID_KSZ8021 0x00221555
+#define PHY_ID_KSZ8031 0x00221556
#define PHY_ID_KSZ8041 0x00221510
#define PHY_ID_KSZ8051 0x00221550
/* same id: ks8001 Rev. A/B, and ks8721 Rev 3. */
--
1.8.4.rc3
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] net: phy: Add micrel KSZ8031
2013-10-22 10:46 [PATCH] net: phy: Add micrel KSZ8031 Markus Pargmann
@ 2013-10-22 14:26 ` Jean-Christophe PLAGNIOL-VILLARD
2013-10-22 14:39 ` Markus Pargmann
2013-10-26 8:12 ` Sascha Hauer
1 sibling, 1 reply; 4+ messages in thread
From: Jean-Christophe PLAGNIOL-VILLARD @ 2013-10-22 14:26 UTC (permalink / raw)
To: Markus Pargmann; +Cc: barebox
On 12:46 Tue 22 Oct , Markus Pargmann wrote:
> KSZ8031 is similar to KSZ8021. It can use the same functions.
>
> Signed-off-by: Markus Pargmann <mpa@pengutronix.de>
> ---
> drivers/net/phy/micrel.c | 9 +++++++++
> include/linux/micrel_phy.h | 1 +
> 2 files changed, 10 insertions(+)
>
> diff --git a/drivers/net/phy/micrel.c b/drivers/net/phy/micrel.c
> index c0bcdd1..3cba2c4 100644
> --- a/drivers/net/phy/micrel.c
> +++ b/drivers/net/phy/micrel.c
> @@ -122,6 +122,15 @@ static struct phy_driver ksphy_driver[] = {
> .config_aneg = genphy_config_aneg,
> .read_status = genphy_read_status,
> }, {
> + .phy_id = PHY_ID_KSZ8031,
> + .phy_id_mask = 0x00ffffff,
> + .drv.name = "Micrel KSZ8031",
> + .features = (PHY_BASIC_FEATURES | SUPPORTED_Pause |
> + SUPPORTED_Asym_Pause),
> + .config_init = ksz8021_config_init,
> + .config_aneg = genphy_config_aneg,
> + .read_status = genphy_read_status,
> +}, {
> .phy_id = PHY_ID_KSZ8041,
> .phy_id_mask = 0x00fffff0,
> .drv.name = "Micrel KSZ8041",
> diff --git a/include/linux/micrel_phy.h b/include/linux/micrel_phy.h
> index 9dbb41a..8752dbb 100644
> --- a/include/linux/micrel_phy.h
> +++ b/include/linux/micrel_phy.h
> @@ -19,6 +19,7 @@
> #define PHY_ID_KSZ9021 0x00221610
> #define PHY_ID_KS8737 0x00221720
> #define PHY_ID_KSZ8021 0x00221555
> +#define PHY_ID_KSZ8031 0x00221556
you really need this?
because if you use a phy_id_mask of 0x00fffff0 you can use the entry as
PHY_ID_KSZ8021
Best Regards,
J.
> #define PHY_ID_KSZ8041 0x00221510
> #define PHY_ID_KSZ8051 0x00221550
> /* same id: ks8001 Rev. A/B, and ks8721 Rev 3. */
> --
> 1.8.4.rc3
>
>
> _______________________________________________
> barebox mailing list
> barebox@lists.infradead.org
> http://lists.infradead.org/mailman/listinfo/barebox
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] net: phy: Add micrel KSZ8031
2013-10-22 14:26 ` Jean-Christophe PLAGNIOL-VILLARD
@ 2013-10-22 14:39 ` Markus Pargmann
0 siblings, 0 replies; 4+ messages in thread
From: Markus Pargmann @ 2013-10-22 14:39 UTC (permalink / raw)
To: Jean-Christophe PLAGNIOL-VILLARD; +Cc: barebox
On Tue, Oct 22, 2013 at 04:26:33PM +0200, Jean-Christophe PLAGNIOL-VILLARD wrote:
> On 12:46 Tue 22 Oct , Markus Pargmann wrote:
> > KSZ8031 is similar to KSZ8021. It can use the same functions.
> >
> > Signed-off-by: Markus Pargmann <mpa@pengutronix.de>
> > ---
> > drivers/net/phy/micrel.c | 9 +++++++++
> > include/linux/micrel_phy.h | 1 +
> > 2 files changed, 10 insertions(+)
> >
> > diff --git a/drivers/net/phy/micrel.c b/drivers/net/phy/micrel.c
> > index c0bcdd1..3cba2c4 100644
> > --- a/drivers/net/phy/micrel.c
> > +++ b/drivers/net/phy/micrel.c
> > @@ -122,6 +122,15 @@ static struct phy_driver ksphy_driver[] = {
> > .config_aneg = genphy_config_aneg,
> > .read_status = genphy_read_status,
> > }, {
> > + .phy_id = PHY_ID_KSZ8031,
> > + .phy_id_mask = 0x00ffffff,
> > + .drv.name = "Micrel KSZ8031",
> > + .features = (PHY_BASIC_FEATURES | SUPPORTED_Pause |
> > + SUPPORTED_Asym_Pause),
> > + .config_init = ksz8021_config_init,
> > + .config_aneg = genphy_config_aneg,
> > + .read_status = genphy_read_status,
> > +}, {
> > .phy_id = PHY_ID_KSZ8041,
> > .phy_id_mask = 0x00fffff0,
> > .drv.name = "Micrel KSZ8041",
> > diff --git a/include/linux/micrel_phy.h b/include/linux/micrel_phy.h
> > index 9dbb41a..8752dbb 100644
> > --- a/include/linux/micrel_phy.h
> > +++ b/include/linux/micrel_phy.h
> > @@ -19,6 +19,7 @@
> > #define PHY_ID_KSZ9021 0x00221610
> > #define PHY_ID_KS8737 0x00221720
> > #define PHY_ID_KSZ8021 0x00221555
> > +#define PHY_ID_KSZ8031 0x00221556
> you really need this?
>
> because if you use a phy_id_mask of 0x00fffff0 you can use the entry as
> PHY_ID_KSZ8021
Yes, it is necessary, the mask you suggest is already in use for
#define PHY_ID_KSZ8051 0x00221550
Regards,
Markus Pargmann
--
Pengutronix e.K. | |
Industrial Linux Solutions | http://www.pengutronix.de/ |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 |
Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 |
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] net: phy: Add micrel KSZ8031
2013-10-22 10:46 [PATCH] net: phy: Add micrel KSZ8031 Markus Pargmann
2013-10-22 14:26 ` Jean-Christophe PLAGNIOL-VILLARD
@ 2013-10-26 8:12 ` Sascha Hauer
1 sibling, 0 replies; 4+ messages in thread
From: Sascha Hauer @ 2013-10-26 8:12 UTC (permalink / raw)
To: Markus Pargmann; +Cc: barebox
On Tue, Oct 22, 2013 at 12:46:17PM +0200, Markus Pargmann wrote:
> KSZ8031 is similar to KSZ8021. It can use the same functions.
>
> Signed-off-by: Markus Pargmann <mpa@pengutronix.de>
Applied, thanks
Sascha
> ---
> drivers/net/phy/micrel.c | 9 +++++++++
> include/linux/micrel_phy.h | 1 +
> 2 files changed, 10 insertions(+)
>
> diff --git a/drivers/net/phy/micrel.c b/drivers/net/phy/micrel.c
> index c0bcdd1..3cba2c4 100644
> --- a/drivers/net/phy/micrel.c
> +++ b/drivers/net/phy/micrel.c
> @@ -122,6 +122,15 @@ static struct phy_driver ksphy_driver[] = {
> .config_aneg = genphy_config_aneg,
> .read_status = genphy_read_status,
> }, {
> + .phy_id = PHY_ID_KSZ8031,
> + .phy_id_mask = 0x00ffffff,
> + .drv.name = "Micrel KSZ8031",
> + .features = (PHY_BASIC_FEATURES | SUPPORTED_Pause |
> + SUPPORTED_Asym_Pause),
> + .config_init = ksz8021_config_init,
> + .config_aneg = genphy_config_aneg,
> + .read_status = genphy_read_status,
> +}, {
> .phy_id = PHY_ID_KSZ8041,
> .phy_id_mask = 0x00fffff0,
> .drv.name = "Micrel KSZ8041",
> diff --git a/include/linux/micrel_phy.h b/include/linux/micrel_phy.h
> index 9dbb41a..8752dbb 100644
> --- a/include/linux/micrel_phy.h
> +++ b/include/linux/micrel_phy.h
> @@ -19,6 +19,7 @@
> #define PHY_ID_KSZ9021 0x00221610
> #define PHY_ID_KS8737 0x00221720
> #define PHY_ID_KSZ8021 0x00221555
> +#define PHY_ID_KSZ8031 0x00221556
> #define PHY_ID_KSZ8041 0x00221510
> #define PHY_ID_KSZ8051 0x00221550
> /* same id: ks8001 Rev. A/B, and ks8721 Rev 3. */
> --
> 1.8.4.rc3
>
>
--
Pengutronix e.K. | |
Industrial Linux Solutions | http://www.pengutronix.de/ |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 |
Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 |
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2013-10-26 8:12 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-10-22 10:46 [PATCH] net: phy: Add micrel KSZ8031 Markus Pargmann
2013-10-22 14:26 ` Jean-Christophe PLAGNIOL-VILLARD
2013-10-22 14:39 ` Markus Pargmann
2013-10-26 8:12 ` Sascha Hauer
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox