<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
<HTML>
<HEAD>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=iso-8859-1">
<META NAME="Generator" CONTENT="MS Exchange Server version 6.5.7638.1">
<TITLE>AW: [coreboot] flashrom: Probe for up to 3 flash chips. [was: Fix ambiguity, if a board is equipped with more than one chip]</TITLE>
</HEAD>
<BODY>
<!-- Converted from text/plain format -->

<P><FONT SIZE=2>-----Ursprüngliche Nachricht-----<BR>
Von: Peter Stuge [<A HREF="mailto:peter@stuge.se">mailto:peter@stuge.se</A>]<BR>
Gesendet: Mo 5/5/2008 17:49<BR>
An: coreboot@coreboot.org<BR>
Cc: Claus Gindhart<BR>
Betreff: Re: [coreboot] flashrom: Probe for up to 3 flash chips. [was: Fix ambiguity, if a board is equipped with more than one chip]<BR>
<BR>
On Mon, May 05, 2008 at 05:07:45PM +0200, Carl-Daniel Hailfinger wrote:<BR>
> Can we support probing for an arbitrary number of chips instead?<BR>
<BR>
I think that is overly ambitious.<BR>
<BR>
flashrom assumes that flash chips are top-aligned at 4GB so there<BR>
will not be very many flash chips actually connected in a way that<BR>
flashrom understands today.<BR>
<BR>
<BR>
> By using an array flash[] instead of flash, flash2 and flash3 this<BR>
> could be done in a loop without limits on the number of detected<BR>
> chips.<BR>
<BR>
I thought [] too, but I set a fixed size. It's simple and cheap to<BR>
increase the size should there be need, and the code will deal.<BR>
<BR>
<BR>
> What happens if there are multiple flash chips of the same<BR>
> technology?<BR>
<BR>
If same name, then same size and at same address => larger problem.<BR>
<BR>
<BR>
> Overall, I really like what the patch does.<BR>
<BR>
Yes, me too.<BR>
<BR>
<BR>
Claus, can you please test the attached patch and send an Acked-by<BR>
line it if it works, then I'll commit.<BR>
<BR>
Thanks!<BR>
<BR>
<BR>
//Peter<BR>
<BR>
Hi Peter,<BR>
<BR>
i've tested the patch, it worked; i've acked-by the attached patch.<BR>
<BR>
This was my screen output<BR>
------------8-<----------<BR>
Multiple flash chips were detected: SST49LF008A M25P16@ICH9<BR>
Please specify which chip to use with the -c <chipname> option.<BR>
----------8-<----------<BR>
<BR>
About the question "Multiple flash chips of the same technology": In my opinion, this is a problem, which has to be solved in a different way, even in regards, how this could be presented to the user. One possible approach could be the following:<BR>
<BR>
If we have multiple chips of the same type, all will be detected by the same probe-function. If we know, that this technology can support up to n identical chips, we could add n lines to flashchips.c, with the device names<BR>
   "chipxxx#1"<BR>
   "chipxxx#2"<BR>
   ...<BR>
   "chipxxx#n"<BR>
It's up to the probe function then, to handle this; the flashrom.c would need to be changed.<BR>
<BR>
But for the moment i would recommend to wait, until such a board appears on somebody's desk.<BR>
<BR>
<BR>
--<BR>
<BR>
Mit freundlichen Grüßen / Best regards<BR>
<BR>
 Claus Gindhart<BR>
 SW R&D<BR>
 Kontron Modular Computers<BR>
 phone :++49 (0)8341-803-374<BR>
 <A HREF="mailto:claus.gindhart@kontron.com">mailto:claus.gindhart@kontron.com</A><BR>
<BR>
<BR>
</FONT>
</P>

<br>

<div class=Section1>

<p class=MsoNormal><b><span style='font-size:8.0pt;font-family:"Arial","sans-serif"'>Kontron
Modular Computers GmbH</span></b><span style='font-size:8.0pt'><o:p></o:p></span></p>

<p class=MsoNormal><span class=SpellE><span style='font-size:7.0pt;font-family:
"Arial","sans-serif"'>Geschaeftsfuehrer</span></span><span style='font-size:
7.0pt;font-family:"Arial","sans-serif"'> Managing <span class=SpellE>Directors</span>:
Ulrich Gehrmann, Thomas Sabisch </span><span style='font-size:7.0pt'><o:p></o:p></span></p>

<p class=MsoNormal><span style='font-size:7.0pt;font-family:"Arial","sans-serif"'>Sitz
der Gesellschaft / Registered Office: Kaufbeuren, Rechtsform / Legal Form: GmbH
</span><span style='font-size:7.0pt'><o:p></o:p></span></p>

<p class=MsoNormal><span class=SpellE><span lang=EN-US style='font-size:7.0pt;
font-family:"Arial","sans-serif";mso-ansi-language:EN-US'>Amtsgericht</span></span><span
lang=EN-US style='font-size:7.0pt;font-family:"Arial","sans-serif";mso-ansi-language:
EN-US'> / Local District Court: Kempten, HRB Nr. / Trade Register No.:
6195</span><span lang=EN-US style='font-size:7.0pt;mso-ansi-language:EN-US'><o:p></o:p></span></p>

<p class=MsoNormal><span lang=EN-US style='font-size:7.0pt;mso-ansi-language:
EN-US'><o:p> </o:p></span></p>

<p class=MsoNormal style='mso-layout-grid-align:none;text-autospace:none'><span
lang=EN-US style='font-size:7.0pt;font-family:"Arial","sans-serif";mso-fareast-font-family:
"Times New Roman";mso-ansi-language:EN-US'>The information contained in this
document is CONFIDENTIAL and property of Kontron.<o:p></o:p></span></p>

<p class=MsoNormal style='mso-layout-grid-align:none;text-autospace:none'><span
lang=EN-US style='font-size:7.0pt;font-family:"Arial","sans-serif";mso-fareast-font-family:
"Times New Roman";mso-ansi-language:EN-US'>Any unauthorized review, use,
disclosure or distribution is prohibited without express<o:p></o:p></span></p>

<p class=MsoNormal style='mso-layout-grid-align:none;text-autospace:none'><span
class=GramE><span lang=EN-US style='font-size:7.0pt;font-family:"Arial","sans-serif";
mso-fareast-font-family:"Times New Roman";mso-ansi-language:EN-US'>written</span></span><span
lang=EN-US style='font-size:7.0pt;font-family:"Arial","sans-serif";mso-fareast-font-family:
"Times New Roman";mso-ansi-language:EN-US'> consent of Kontron. If you are not
the intended recipient, please contact the<o:p></o:p></span></p>

<p class=MsoNormal><span class=GramE><span lang=EN-US style='font-size:7.0pt;
font-family:"Arial","sans-serif";mso-fareast-font-family:"Times New Roman";
mso-ansi-language:EN-US'>sender</span></span><span lang=EN-US style='font-size:
7.0pt;font-family:"Arial","sans-serif";mso-fareast-font-family:"Times New Roman";
mso-ansi-language:EN-US'> and destroy all copies of the original message and
enclosed attachments.</span><span lang=EN-US style='font-size:7.0pt;font-family:
"Arial","sans-serif";color:#1F497D;mso-ansi-language:EN-US'> <o:p></o:p></span></p>

<p class=MsoNormal><span lang=EN-US style='font-size:7.0pt;font-family:"Arial","sans-serif";
color:#1F497D;mso-ansi-language:EN-US'><o:p> </o:p></span></p>

<p class=MsoNormal style='mso-layout-grid-align:none;text-autospace:none'><span
style='font-size:7.0pt;font-family:"Arial","sans-serif";mso-fareast-font-family:
"Times New Roman"'>Diese E-Mail <span class=SpellE>enthaelt</span> vertrauliche
und/oder rechtlich <span class=SpellE>geschuetzte</span> Informationen und ist<o:p></o:p></span></p>

<p class=MsoNormal style='mso-layout-grid-align:none;text-autospace:none'><span
style='font-size:7.0pt;font-family:"Arial","sans-serif";mso-fareast-font-family:
"Times New Roman"'>Eigentum von Kontron. Die Verwendung und Weitergabe von
jeglichen Inhalten ist<o:p></o:p></span></p>

<p class=MsoNormal style='mso-layout-grid-align:none;text-autospace:none'><span
style='font-size:7.0pt;font-family:"Arial","sans-serif";mso-fareast-font-family:
"Times New Roman"'>ohne <span class=SpellE>ausdrueckliche</span> schriftliche
Genehmigung von Kontron strikt untersagt. Wenn Sie<o:p></o:p></span></p>

<p class=MsoNormal style='mso-layout-grid-align:none;text-autospace:none'><span
style='font-size:7.0pt;font-family:"Arial","sans-serif";mso-fareast-font-family:
"Times New Roman"'>diese E-Mail <span class=SpellE>irrtuemlich</span> erhalten
haben, informieren Sie bitte sofort den Absender und<o:p></o:p></span></p>

<p class=MsoNormal><span style='font-size:7.0pt;font-family:"Arial","sans-serif";
mso-fareast-font-family:"Times New Roman"'>vernichten diese Mail und enthaltene
Dokumente.</span><span style='font-size:8.0pt'><o:p></o:p></span></p>

</div>

<br></BODY>
</HTML>