Am 31.01.2012 06:51 schrieb Stefan Tauner:
Previously only the generic "unknown XXXX SPI chips" were ignored (because their name started with "unknown". This patch adds also all chips whose vendor starts with "Unknown" (none so far). Change the vendor of the entry for the opaque programmer framework to "Unknown" to ignore it.
Could you undo the "Programmer"->"unknown" conversion and just ignore chips with vendor name "Programmer" as well? "Unknown" conveys some insecurity, but for opaque programmers that insecurity is not what we want.
Another patch will add the SFDP chip template also with an "Unknown" vendor field.
Rationale: these entries do not contain any useful information when shown in -L or wiki output. It would be better to add them to a general feature section or similar.
Signed-off-by: Stefan Tauner stefan.tauner@student.tuwien.ac.at
Acked-by: Carl-Daniel Hailfinger c-d.hailfinger.devel.2006@gmx.net
diff --git a/flashchips.c b/flashchips.c index ca1c57f..0c8257b 100644 --- a/flashchips.c +++ b/flashchips.c @@ -8874,7 +8874,7 @@ const struct flashchip flashchips[] = { },
{
.vendor = "Programmer",
.name = "Opaque flash chip", .bustype = BUS_PROG, .manufacture_id = PROGMANUF_ID,.vendor = "Unknown",
diff --git a/print.c b/print.c index 0e152a6..ba86ebb 100644 --- a/print.c +++ b/print.c @@ -74,8 +74,9 @@ static void print_supported_chips(void)
/* calculate maximum column widths and by iterating over all chips */ for (f = flashchips; f->name != NULL; f++) {
/* Ignore "unknown XXXX SPI chip" entries. */
if (!strncmp(f->name, "unknown", 7))
/* Ignore generic entries. */
if (!strncmp(f->vendor, "Unknown", 7) ||
chipcount++;!strncmp(f->name, "unknown", 7)) continue;
@@ -161,8 +162,9 @@ static void print_supported_chips(void) msg_ginfo("(P = PROBE, R = READ, E = ERASE, W = WRITE)\n\n");
for (f = flashchips; f->name != NULL; f++) {
/* Don't print "unknown XXXX SPI chip" entries. */
if (!strncmp(f->name, "unknown", 7))
/* Don't print generic entries. */
if (!strncmp(f->vendor, "Unknown", 7) ||
!strncmp(f->name, "unknown", 7)) continue;
/* support for multiline vendor names:
diff --git a/print_wiki.c b/print_wiki.c index 1c9241e..70f4427 100644 --- a/print_wiki.c +++ b/print_wiki.c @@ -216,9 +216,9 @@ static void print_supported_chips_wiki(int cols) char vmin[6];
for (f = flashchips; f->name != NULL; f++) {
/* Don't count "unknown XXXX SPI chip" entries. */
if (!strncmp(f->name, "unknown", 7))
continue;
/* Don't count generic entries. */
if (!strncmp(f->vendor, "Unknown", 7) ||
chipcount++; }!strncmp(f->name, "unknown", 7))
@@ -227,8 +227,9 @@ static void print_supported_chips_wiki(int cols) "| valign="top"|\n\n%s", chipcount, chip_th);
for (f = flashchips; f->name != NULL; f++, i++) {
/* Don't print "unknown XXXX SPI chip" entries. */
if (!strncmp(f->name, "unknown", 7))
/* Don't print generic entries. */
if (!strncmp(f->vendor, "Unknown", 7) ||
!strncmp(f->name, "unknown", 7)) continue;
/* Alternate colors if the vendor changes. */
Regards, Carl-Daniel