mail archive of the barebox mailing list
 help / color / mirror / Atom feed
From: Steffen Trumtrar <s.trumtrar@pengutronix.de>
To: "Jan Lübbe" <jlu@pengutronix.de>
Cc: barebox@lists.infradead.org
Subject: Re: [PATCH v2 3/3] ARM: socfpga: add Altera SoCFPGA Development Kit support
Date: Wed, 25 Feb 2015 09:44:29 +0100	[thread overview]
Message-ID: <20150225084429.GR7994@pengutronix.de> (raw)
In-Reply-To: <1424683689.29479.3.camel@pengutronix.de>

On Mon, Feb 23, 2015 at 10:28:09AM +0100, Jan Lübbe wrote:
> On Mo, 2015-02-23 at 10:15 +0100, Steffen Trumtrar wrote:
> > --- /dev/null
> > +++ b/arch/arm/boards/altera-socdk/board.c
> > @@ -0,0 +1,38 @@
> 
> > +static int ksz9021rn_phy_fixup(struct phy_device *dev)
> > +{
> > +	phy_write(dev, 0x09, 0x0f00);
> > +
> > +	/* rx skew */
> > +	phy_write(dev, 0x0b, 0x8105);
> > +	phy_write(dev, 0x0c, 0x0000);
> > +
> > +	/* clk/ctrl skew */
> > +	phy_write(dev, 0x0b, 0x8104);
> > +	phy_write(dev, 0x0c, 0xa0d0);
> > +
> > +	return 0;
> > +}
> > +
> > +static int socfpga_console_init(void)
> > +{
> > +	if (!of_machine_is_compatible("altr,socdk"))
> > +		return 0;
> > +
> > +	phy_register_fixup_for_uid(PHY_ID_KSZ9021, MICREL_PHY_ID_MASK,
> > +					   ksz9021rn_phy_fixup);
> > +
> > +	return 0;
> > +}
> > +console_initcall(socfpga_console_init);
> 
> > --- /dev/null
> > +++ b/arch/arm/dts/socfpga_cyclone5_socdk.dts
> 
> > +&gmac1 {
> > +	status = "okay";
> > +	phy-mode = "rgmii";
> > +
> > +	rxd0-skew-ps = <0>;
> > +	rxd1-skew-ps = <0>;
> > +	rxd2-skew-ps = <0>;
> > +	rxd3-skew-ps = <0>;
> > +	txen-skew-ps = <0>;
> > +	txc-skew-ps = <2600>;
> > +	rxdv-skew-ps = <0>;
> > +	rxc-skew-ps = <2000>;
> > +};
> 
> It seems that with the DT-based configuration of the skew values, the
> phy_fixup in board.c is not necessary.

Yes, one would expect that. But it didn't work, so I decided to not
debug this right now.
The socfpga-DT section needs an overhaul anyway; gpio and clkmgr bindings
are not correct anymore.

Regards,
Steffen

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

  reply	other threads:[~2015-02-25  8:44 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-02-23  9:15 [PATCH v2 0/3] Socfpga: handoff importer updates + SOCDK support Steffen Trumtrar
2015-02-23  9:15 ` [PATCH v2 1/3] scripts: add socfpga preloader-files importer Steffen Trumtrar
2015-02-23  9:15 ` [PATCH v2 2/3] scripts: socfpga: add coccinelle magic Steffen Trumtrar
2015-02-23  9:15 ` [PATCH v2 3/3] ARM: socfpga: add Altera SoCFPGA Development Kit support Steffen Trumtrar
2015-02-23  9:28   ` Jan Lübbe
2015-02-25  8:44     ` Steffen Trumtrar [this message]
2015-03-02  6:45       ` Sascha Hauer

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=20150225084429.GR7994@pengutronix.de \
    --to=s.trumtrar@pengutronix.de \
    --cc=barebox@lists.infradead.org \
    --cc=jlu@pengutronix.de \
    /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