linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
* DTS question
@ 2008-09-02 21:56 Gary Thomas
  2008-09-02 23:42 ` David Gibson
  2008-09-02 23:43 ` Scott Wood
  0 siblings, 2 replies; 20+ messages in thread
From: Gary Thomas @ 2008-09-02 21:56 UTC (permalink / raw)
  To: Linuxppc-dev

Following on with my RTC problem, I cut&pasted this from
the TQM5200 dts file:
                 i2c@3d40 {
                         #address-cells = <1>;
                         #size-cells = <0>;
                         compatible = "fsl,mpc5200-i2c","fsl-i2c";
                         reg = <0x3d40 0x40>;
                         interrupts = <2 16 0>;
                         interrupt-parent = <&mpc5200_pic>;
                         fsl5200-clocking;

                          rtc@68 {
                                 device_type = "rtc";
                                 compatible = "dallas,ds1307";
                                 reg = <0x68>;
                         };
                 };

However, the dts file I started with had this (*mine*):
		i2c@3d40 {
			#address-cells = <1>;
			#size-cells = <0>;
			compatible = "fsl,mpc5200-i2c","fsl-i2c";
			cell-index = <1>;
			reg = <3d40 40>;
			interrupts = <2 10 0>;
			interrupt-parent = <&mpc5200_pic>;
			fsl5200-clocking;
		};

Notice the different mix of hex (0xNNN) and implied hex values.
This is really confusing to me.  Even more so when I added the
RTC snippet cut directly from the TQM5200 file:

                          rtc@68 {
                                 device_type = "rtc";
                                 compatible = "dallas,ds1307";
                                 reg = <0x68>;
                         };

This yielded a syntax error when merged with my platform dts.
When I changed the 'reg=<0x68>' to 'reg=<68>', the syntax error
went away & it worked perfectly.

What gives?  Why is explicit hex sometimes an error and sometimes not?
Is the format of this file documented anywhere (I've not found it)?

-- 
------------------------------------------------------------
Gary Thomas                 |  Consulting for the
MLB Associates              |    Embedded world
------------------------------------------------------------

^ permalink raw reply	[flat|nested] 20+ messages in thread
* DTS question
@ 2008-03-20 21:33 Sean MacLennan
  2008-03-20 21:47 ` Segher Boessenkool
                   ` (2 more replies)
  0 siblings, 3 replies; 20+ messages in thread
From: Sean MacLennan @ 2008-03-20 21:33 UTC (permalink / raw)
  To: linuxppc-dev

The warp has an AD7414 chip hanging off the I2C bus. This chip can
raise an interrupt when it crosses a critical threshold.

This interrupt is tied to IRQ2 from the processor. What is the best
way to describe this interrupt in the DTS?

The warp.dts is available on request, but the one in the for-2.6.25
tree is relatively up to date.

Cheers,
   Sean

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

end of thread, other threads:[~2008-09-03  0:25 UTC | newest]

Thread overview: 20+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-09-02 21:56 DTS question Gary Thomas
2008-09-02 23:42 ` David Gibson
2008-09-03  0:14   ` Gary Thomas
2008-09-03  0:25     ` David Gibson
2008-09-02 23:43 ` Scott Wood
  -- strict thread matches above, loose matches on Subject: below --
2008-03-20 21:33 Sean MacLennan
2008-03-20 21:47 ` Segher Boessenkool
2008-03-20 21:48 ` Scott Wood
2008-03-20 22:19 ` Sean MacLennan
2008-03-20 22:26   ` Scott Wood
2008-03-21  4:12     ` Sean MacLennan
2008-03-21  4:34       ` Grant Likely
2008-03-21  5:09         ` Sean MacLennan
2008-03-21  7:05           ` David Gibson
2008-03-21 11:35             ` Segher Boessenkool
2008-03-25 22:12               ` David Gibson
2008-03-26 15:32                 ` Segher Boessenkool
2008-03-26 23:40                   ` David Gibson
2008-03-27  3:42                     ` Sean MacLennan
2008-03-21 11:31         ` Segher Boessenkool

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