Subject: Re: [PATCH 2/5] Add legacy devices to mpc8641_hpcn.dts

From: Arnd Bergmann <[email-masked]>
Date: Sat, 7 Jul 2007 20:39:48 +0200

On Saturday 07 July 2007, Sergei Shtylyov wrote:
> =A0 =A0Yet it's kinda accepted years ago, see:
>=20
> http://playground.sun.com/1275/proposals/Closed/Accepted/381-it.txt
>=20
> =A0 =A0 Ugh, it's hard to find these documents... All "name", "device_typ=
e", and=20
> "compatible" must all be "8042".
>=20

Right. I've just checked an OF based machine that has 8042 keyboard
controller (the OLPC laptop), to see what's in there.

Here, we have=20

8042@i60 {
	device_type =3D "8042";
	reg =3D <1 60 1 1 64 1>;
	interrupts <1 3 c 3>;
	/* no interrupt-parent, this gets inherited from ISA node */
	model =3D "INT,80c42";
	compatible =3D "ps2-keyboard-controller" "INTC,80c42";
	name =3D "8042"
	#size-cells <0>;
	#address-cells <1>;

	mouse@aux {
		reg =3D <1>;
		compatible =3D "pnpPNP,f03";
		device_type =3D "mouse";
		name =3D "mouse";
	}

	keyboard@ {
		reg =3D <0>;
		language =3D "EN";
		keyboard-type =3D "us";
		device-type =3D "keyboard";
		compatible =3D "pnpPNP,303";
		name =3D "keyboard";
	}
}

My interpretation of the document you cited is that the #size-cells and
#address-cells as well as the child nodes are actually required by the
standard, but it seems that Linux doesn't care.

The model and compatible properties in the 8042 node are not standard
compliant in my machine, so I'm not sure what to best put in there.
It is very clear on name and device-type though.

	Arnd <><