linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
* mxs: enable phy-clock in the driver?
@ 2012-01-08 14:45 Wolfram Sang
  2012-01-09  1:34 ` Shawn Guo
  2012-01-11 10:59 ` Marek Vasut
  0 siblings, 2 replies; 8+ messages in thread
From: Wolfram Sang @ 2012-01-08 14:45 UTC (permalink / raw)
  To: linux-arm-kernel

Hi Shawn,

I recently noticed that my tx28 board did not have net when booting from NAND
(before that, barebox was setting up the network). Adding lines like these from
mx28evk helped:

228         /* Enable fec phy clock */
229         clk = clk_get_sys("pll2", NULL);
230         if (!IS_ERR(clk))
231                 clk_enable(clk);

So, if every board seems to need this, I'd think this should rather be in the
driver? Am I correct or is there something I have overlooked?

Regards,

   Wolfram

-- 
Pengutronix e.K.                           | Wolfram Sang                |
Industrial Linux Solutions                 | http://www.pengutronix.de/  |
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 198 bytes
Desc: Digital signature
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20120108/33bc4499/attachment.sig>

^ permalink raw reply	[flat|nested] 8+ messages in thread

* mxs: enable phy-clock in the driver?
  2012-01-08 14:45 mxs: enable phy-clock in the driver? Wolfram Sang
@ 2012-01-09  1:34 ` Shawn Guo
  2012-01-09  6:40   ` Lothar Waßmann
  2012-01-11 10:59 ` Marek Vasut
  1 sibling, 1 reply; 8+ messages in thread
From: Shawn Guo @ 2012-01-09  1:34 UTC (permalink / raw)
  To: linux-arm-kernel

On Sun, Jan 08, 2012 at 03:45:58PM +0100, Wolfram Sang wrote:
> Hi Shawn,
> 
> I recently noticed that my tx28 board did not have net when booting from NAND
> (before that, barebox was setting up the network). Adding lines like these from
> mx28evk helped:
> 
> 228         /* Enable fec phy clock */
> 229         clk = clk_get_sys("pll2", NULL);
> 230         if (!IS_ERR(clk))
> 231                 clk_enable(clk);
> 
> So, if every board seems to need this, I'd think this should rather be in the
> driver? Am I correct or is there something I have overlooked?
> 
Hmm, as far as I know, at least m28evk from denx does not need this.
Different from that imx28 supplies clock to phy on mx28evk board,
m28evk has phy supply clock to imx28. 

-- 
Regards,
Shawn

^ permalink raw reply	[flat|nested] 8+ messages in thread

* mxs: enable phy-clock in the driver?
  2012-01-09  1:34 ` Shawn Guo
@ 2012-01-09  6:40   ` Lothar Waßmann
  2012-01-09  6:58     ` Shawn Guo
  0 siblings, 1 reply; 8+ messages in thread
From: Lothar Waßmann @ 2012-01-09  6:40 UTC (permalink / raw)
  To: linux-arm-kernel

Hi,

Shawn Guo writes:
> On Sun, Jan 08, 2012 at 03:45:58PM +0100, Wolfram Sang wrote:
> > Hi Shawn,
> > 
> > I recently noticed that my tx28 board did not have net when booting from NAND
> > (before that, barebox was setting up the network). Adding lines like these from
> > mx28evk helped:
> > 
> > 228         /* Enable fec phy clock */
> > 229         clk = clk_get_sys("pll2", NULL);
> > 230         if (!IS_ERR(clk))
> > 231                 clk_enable(clk);
> > 
> > So, if every board seems to need this, I'd think this should rather be in the
> > driver? Am I correct or is there something I have overlooked?
> > 
> Hmm, as far as I know, at least m28evk from denx does not need this.
> Different from that imx28 supplies clock to phy on mx28evk board,
> m28evk has phy supply clock to imx28. 
> 
The TX28 derives its PHY clock from the ENET_CLK pin of the
processor. Thus the CLK_ENET_TIME should be enabled by the driver as
mentioned in <20120108033238.GA19721@S2101-09.ap.freescale.net>


Lothar Wa?mann
-- 
___________________________________________________________

Ka-Ro electronics GmbH | Pascalstra?e 22 | D - 52076 Aachen
Phone: +49 2408 1402-0 | Fax: +49 2408 1402-10
Gesch?ftsf?hrer: Matthias Kaussen
Handelsregistereintrag: Amtsgericht Aachen, HRB 4996

www.karo-electronics.de | info at karo-electronics.de
___________________________________________________________

^ permalink raw reply	[flat|nested] 8+ messages in thread

* mxs: enable phy-clock in the driver?
  2012-01-09  6:40   ` Lothar Waßmann
@ 2012-01-09  6:58     ` Shawn Guo
  2012-01-09  7:05       ` Lothar Waßmann
  0 siblings, 1 reply; 8+ messages in thread
From: Shawn Guo @ 2012-01-09  6:58 UTC (permalink / raw)
  To: linux-arm-kernel

On Mon, Jan 09, 2012 at 07:40:47AM +0100, Lothar Wa?mann wrote:
> The TX28 derives its PHY clock from the ENET_CLK pin of the
> processor. Thus the CLK_ENET_TIME should be enabled by the driver as
> mentioned in <20120108033238.GA19721@S2101-09.ap.freescale.net>
> 
Can you give a web link for that message?

-- 
Regards,
Shawn

^ permalink raw reply	[flat|nested] 8+ messages in thread

* mxs: enable phy-clock in the driver?
  2012-01-09  6:58     ` Shawn Guo
@ 2012-01-09  7:05       ` Lothar Waßmann
  2012-01-09  7:21         ` Shawn Guo
  0 siblings, 1 reply; 8+ messages in thread
From: Lothar Waßmann @ 2012-01-09  7:05 UTC (permalink / raw)
  To: linux-arm-kernel

Hi,

Shawn Guo writes:
> On Mon, Jan 09, 2012 at 07:40:47AM +0100, Lothar Wa?mann wrote:
> > The TX28 derives its PHY clock from the ENET_CLK pin of the
> > processor. Thus the CLK_ENET_TIME should be enabled by the driver as
> > mentioned in <20120108033238.GA19721@S2101-09.ap.freescale.net>
> > 
> Can you give a web link for that message?
> 
It's your own email from "Sun, 8 Jan 2012 11:32:40 +0800" with the
subject "Re: MX28 fec clock frequency":
http://lists.infradead.org/pipermail/linux-arm-kernel/2012-January/079556.html


Lothar Wa?mann
-- 
___________________________________________________________

Ka-Ro electronics GmbH | Pascalstra?e 22 | D - 52076 Aachen
Phone: +49 2408 1402-0 | Fax: +49 2408 1402-10
Gesch?ftsf?hrer: Matthias Kaussen
Handelsregistereintrag: Amtsgericht Aachen, HRB 4996

www.karo-electronics.de | info at karo-electronics.de
___________________________________________________________

^ permalink raw reply	[flat|nested] 8+ messages in thread

* mxs: enable phy-clock in the driver?
  2012-01-09  7:21         ` Shawn Guo
@ 2012-01-09  7:17           ` Lothar Waßmann
  0 siblings, 0 replies; 8+ messages in thread
From: Lothar Waßmann @ 2012-01-09  7:17 UTC (permalink / raw)
  To: linux-arm-kernel

Hi,

Shawn Guo writes:
> On Mon, Jan 09, 2012 at 08:05:14AM +0100, Lothar Wa?mann wrote:
> > Hi,
> > 
> > Shawn Guo writes:
> > > On Mon, Jan 09, 2012 at 07:40:47AM +0100, Lothar Wa?mann wrote:
> > > > The TX28 derives its PHY clock from the ENET_CLK pin of the
> > > > processor. Thus the CLK_ENET_TIME should be enabled by the driver as
> > > > mentioned in <20120108033238.GA19721@S2101-09.ap.freescale.net>
> > > > 
> > > Can you give a web link for that message?
> > > 
> > It's your own email from "Sun, 8 Jan 2012 11:32:40 +0800" with the
> > subject "Re: MX28 fec clock frequency":
> > http://lists.infradead.org/pipermail/linux-arm-kernel/2012-January/079556.html
> > 
> Ah, yes.  But what I said there is the CLK_ENET_TIME should be enabled
> by PTP support, not the need of clocking external phy required by
> particular board design.
> 
My point was, that it is the same clock. Thus, not "pll2" but
"enet_ptp" or whatever it's name will be needs to be enabled for the
Ethernet PHY on TX28.


Lothar Wa?mann
-- 
___________________________________________________________

Ka-Ro electronics GmbH | Pascalstra?e 22 | D - 52076 Aachen
Phone: +49 2408 1402-0 | Fax: +49 2408 1402-10
Gesch?ftsf?hrer: Matthias Kaussen
Handelsregistereintrag: Amtsgericht Aachen, HRB 4996

www.karo-electronics.de | info at karo-electronics.de
___________________________________________________________

^ permalink raw reply	[flat|nested] 8+ messages in thread

* mxs: enable phy-clock in the driver?
  2012-01-09  7:05       ` Lothar Waßmann
@ 2012-01-09  7:21         ` Shawn Guo
  2012-01-09  7:17           ` Lothar Waßmann
  0 siblings, 1 reply; 8+ messages in thread
From: Shawn Guo @ 2012-01-09  7:21 UTC (permalink / raw)
  To: linux-arm-kernel

On Mon, Jan 09, 2012 at 08:05:14AM +0100, Lothar Wa?mann wrote:
> Hi,
> 
> Shawn Guo writes:
> > On Mon, Jan 09, 2012 at 07:40:47AM +0100, Lothar Wa?mann wrote:
> > > The TX28 derives its PHY clock from the ENET_CLK pin of the
> > > processor. Thus the CLK_ENET_TIME should be enabled by the driver as
> > > mentioned in <20120108033238.GA19721@S2101-09.ap.freescale.net>
> > > 
> > Can you give a web link for that message?
> > 
> It's your own email from "Sun, 8 Jan 2012 11:32:40 +0800" with the
> subject "Re: MX28 fec clock frequency":
> http://lists.infradead.org/pipermail/linux-arm-kernel/2012-January/079556.html
> 
Ah, yes.  But what I said there is the CLK_ENET_TIME should be enabled
by PTP support, not the need of clocking external phy required by
particular board design.

-- 
Regards,
Shawn

^ permalink raw reply	[flat|nested] 8+ messages in thread

* mxs: enable phy-clock in the driver?
  2012-01-08 14:45 mxs: enable phy-clock in the driver? Wolfram Sang
  2012-01-09  1:34 ` Shawn Guo
@ 2012-01-11 10:59 ` Marek Vasut
  1 sibling, 0 replies; 8+ messages in thread
From: Marek Vasut @ 2012-01-11 10:59 UTC (permalink / raw)
  To: linux-arm-kernel

> Hi Shawn,
> 
> I recently noticed that my tx28 board did not have net when booting from
> NAND (before that, barebox was setting up the network). Adding lines like
> these from mx28evk helped:
> 
> 228         /* Enable fec phy clock */
> 229         clk = clk_get_sys("pll2", NULL);
> 230         if (!IS_ERR(clk))
> 231                 clk_enable(clk);
> 
> So, if every board seems to need this, I'd think this should rather be in
> the driver? Am I correct or is there something I have overlooked?
> 
> Regards,
> 
>    Wolfram

Did you really disable the clock to FEC or only the PHY didn't have clock?

M

^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2012-01-11 10:59 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-01-08 14:45 mxs: enable phy-clock in the driver? Wolfram Sang
2012-01-09  1:34 ` Shawn Guo
2012-01-09  6:40   ` Lothar Waßmann
2012-01-09  6:58     ` Shawn Guo
2012-01-09  7:05       ` Lothar Waßmann
2012-01-09  7:21         ` Shawn Guo
2012-01-09  7:17           ` Lothar Waßmann
2012-01-11 10:59 ` Marek Vasut

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).