public inbox for linuxppc-dev@ozlabs.org 
 help / color / mirror / Atom feed
From: Domen Puncer <domen.puncer@telargo•com>
To: Matt Sealey <matt@genesi-usa•com>
Cc: Domen Puncer <domen@coderock•org>, linuxppc-embedded@ozlabs•org
Subject: Re: [RFC PATCH v0.1] net driver: mpc52xx fec
Date: Mon, 20 Aug 2007 10:31:37 +0200	[thread overview]
Message-ID: <20070820083137.GJ13994@moe.telargo.com> (raw)
In-Reply-To: <46C8643B.7010104@genesi-usa.com>

On 19/08/07 16:39 +0100, Matt Sealey wrote:
> Domen,
> 
> Do it in a Forth script, or in nvramrc (after probe-all). Don't clutter
> Linux with more fixups. The Efika PHY isn't going to change to something
> else and it's a bog standard no-frills MII PHY anyway.

Fine with me, but I'm worried people won't update nvramrc.

Currently I have this:
--- start ---

s" /builtin" find-device

new-device
        1 encode-int s" #address-cells" property
        0 encode-int s" #size-cells" property
        s" mdio" 2dup device-name device-type
        s" mpc5200b-fec-phy" s" compatible" property
        0xf0003000 0x400 reg

        0x2 encode-int
        0x5 encode-int
        0x3 encode-int
        encode+ encode+
        s" interupts" property

        new-device
                s" ethernet-phy@0" device-name
                s" ethernet-phy" device-type
                0 encode-int s" reg" property

                my-self \ save our phandle to stack
                ihandle>phandle
        finish-device
finish-device

s" /builtin/ethernet" find-device
        encode-int      \ phy's phandle
        s" phy-handle" property
device-end

---  end  ---

But I have a problem with it, possibly due to my not-knowledge of Forth.
Compatible keep getting set to:
	compatible            "/builtin/etherne"



<spin>
> If you insist on using prom_init and fixups, yaboot has the best
> examples of call-method and interpret, both readable and fairly
> easily available.

Thanks.


	Domen

> > On 10/08/07 11:51 +0200, Domen Puncer wrote:
> >> Index: work-powerpc.git/arch/powerpc/boot/dts/lite5200b.dts
> >> ===================================================================
> >> --- work-powerpc.git.orig/arch/powerpc/boot/dts/lite5200b.dts
> >> +++ work-powerpc.git/arch/powerpc/boot/dts/lite5200b.dts
> >> +		mdio@3000 {
> >> +			#address-cells = <1>;
> >> +			#size-cells = <0>;
> >> +			device_type = "mdio";
> >> +			compatible = "mpc5200b-fec-phy";
> >> +			reg = <3000 400>;	// fec range, since we need to setup fec interrupts
> >> +			interrupts = <2 5 0>;	// these are for "mii command finished", not link changes & co.
> >> +			interrupt-parent = <&mpc5200_pic>;
> >> +
> >> +			phy0:ethernet-phy@0 {
> >> +				device_type = "ethernet-phy";
> >> +				reg = <0>;
> >> +			};
> >>  		};
> > 
> > I am struggling with this part on Efika.
> > I would like to add this to the device tree from
> > fixup_device_tree_efika() (arch/powerpc/kernel/prom_init.c).
> > 
> > AFAICS client-services doesn't offer anything like new-device,
> > so I guess "interpret" or "call-method" will have to be used.
> > 
> > I have read some docs, but I'm still wandering in the dark.
> > Can I please get an example?
> > Pretty please with a cherry on top?
> > 
> > 
> > 	Domen
> _______________________________________________
> Linuxppc-embedded mailing list
> Linuxppc-embedded@ozlabs•org
> https://ozlabs.org/mailman/listinfo/linuxppc-embedded

  reply	other threads:[~2007-08-20  8:31 UTC|newest]

Thread overview: 47+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-08-10  9:51 [RFC PATCH v0.1] net driver: mpc52xx fec Domen Puncer
2007-08-10 13:02 ` Arnaldo Carvalho de Melo
2007-08-13  7:21   ` Domen Puncer
2007-08-18 10:06 ` Domen Puncer
2007-08-19 15:39   ` Matt Sealey
2007-08-20  8:31     ` Domen Puncer [this message]
2007-08-20 13:13       ` Domen Puncer
2007-08-20 19:02         ` Matt Sealey
2007-08-21  5:49           ` Domen Puncer
2007-09-02  7:41 ` [RFC PATCH v0.2] " Domen Puncer
2007-09-03 15:57   ` Grant Likely
2007-09-03 16:09     ` Jon Smirl
2007-09-03 16:41       ` Grant Likely
2007-09-15 12:14     ` Domen Puncer
2007-09-17  9:53       ` Sven Luther
2007-09-17 20:21         ` [PATCH] phy: export phy_mii_ioctl Domen Puncer
2007-09-17 22:08           ` Jon Smirl
2007-09-18 15:16             ` Domen Puncer
2007-09-18 19:17               ` Jon Smirl
2007-09-19 11:56                 ` Domen Puncer
2007-09-19 18:44                   ` Jon Smirl
2007-09-19 21:18                     ` Jon Smirl
2007-09-18 19:29               ` Jon Smirl
2007-09-19  8:54                 ` Pedro Luis D. L.
2007-09-19 10:37                   ` Juergen Beisert
2007-09-19 11:38                     ` Pedro Luis D. L.
2007-09-19 14:51                       ` Juergen Beisert
2007-09-19 15:11                         ` Pedro Luis D. L.
2007-09-19 13:56                   ` Jon Smirl
2007-09-19 14:31                     ` Pedro Luis D. L.
2007-09-19  8:54                 ` Pedro Luis D. L.
2007-09-20  6:36           ` Jeff Garzik
2007-10-02 12:49   ` [RFC PATCH v0.2] net driver: mpc52xx fec Sascha Hauer
2007-10-02 14:32     ` Domen Puncer
2007-10-02 15:46       ` Robert Schwebel
2007-09-27 17:07 ` [RFC PATCH v0.1] " Juergen Beisert
2007-09-27 18:12   ` Jon Smirl
2007-09-27 18:43     ` Scott Wood
2007-09-28  9:12       ` Juergen Beisert
2007-09-28 15:40         ` Scott Wood
2007-10-08  8:48         ` Sascha Hauer
2007-10-08  9:01         ` Sascha Hauer
2007-10-08 16:46           ` Jon Smirl
2007-09-28 15:07   ` Juergen Beisert
2007-09-28 15:38     ` Jon Smirl
2007-10-01  8:35       ` Juergen Beisert
2007-10-01 16:24         ` Juergen Beisert

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=20070820083137.GJ13994@moe.telargo.com \
    --to=domen.puncer@telargo$(echo .)com \
    --cc=domen@coderock$(echo .)org \
    --cc=linuxppc-embedded@ozlabs$(echo .)org \
    --cc=matt@genesi-usa$(echo .)com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html
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