<br>
<br><font size=2><tt>linuxppc-dev-bounces+hbabu=us.ibm.com@ozlabs.org wrote
on 04/03/2006 10:40:48 PM:<br>
<br>
&gt; On Mon, 2006-04-03 at 11:18 -0700, Haren Myneni wrote:<br>
&gt; &gt; Basically, kexec-tools looks the platform property to determine
whether <br>
&gt; &gt; to read tce-base, tce-size and htab-* properties. The attached
patch <br>
&gt; &gt; find out the platform info based on /proc/device-tree/chosen/htab-base
<br>
&gt; &gt; property. Not tested yet.<br>
&gt; <br>
&gt; Why don't we get rid of the platform variable entirely in kexec-ppc64.c,<br>
&gt; if the tce-* and htab-* properties are there, then we read them, if
not<br>
&gt; we don't.</tt></font>
<br><font size=2><tt><br>
&gt; <br>
&gt; There's also:<br>
&gt; <br>
&gt; if (platform == PLATFORM_PSERIES) {<br>
&gt; &nbsp; &nbsp; &nbsp; &nbsp; if (rmo_top &gt; 0x30000000UL)<br>
&gt; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; rmo_top =
0x30000000UL;<br>
&gt; }<br>
&gt; <br>
&gt; I'm not sure where that number comes from, perhaps we need to export
the<br>
&gt; RMO value like we do for the htab?</tt></font>
<br>
<br><font size=2><tt>Yes, we can remove this PLATFORM_* and read these
properties if exists. I believe, this large number is copied from prom_init.c.
I am not sure whether exporting rmo_top is needed since it is always the
size of first memory node unless the size is greater than 0x30000000UL.
PLATFORM_PSERIES is not needed anyway for this comparison.</tt></font>
<br>
<br><font size=2><tt><br>
&gt; <br>
&gt; While we're there that code could use a function to read<br>
&gt; a /proc/device-tree file and do error handling, there's a lot of<br>
&gt; duplicate code at the moment.<br>
&gt; </tt></font>
<br><font size=2><tt>Yes, there is some cleanup needed in kexec-tools.</tt></font>
<br>
<br><font size=2><tt>Thanks</tt></font>
<br><font size=2><tt>Haren</tt></font>
<br><font size=2><tt><br>
&gt; cheers<br>
&gt; <br>
&gt; -- <br>
&gt; Michael Ellerman<br>
&gt; IBM OzLabs<br>
&gt; <br>
&gt; wwweb: http://michael.ellerman.id.au<br>
&gt; phone: +61 2 6212 1183 (tie line 70 21183)<br>
&gt; <br>
&gt; We do not inherit the earth from our ancestors,<br>
&gt; we borrow it from our children. - S.M.A.R.T Person<br>
&gt; <br>
&gt; _______________________________________________<br>
&gt; Linuxppc-dev mailing list<br>
&gt; Linuxppc-dev@ozlabs.org<br>
&gt; https://ozlabs.org/mailman/listinfo/linuxppc-dev<br>
</tt></font>