summaryrefslogtreecommitdiff
path: root/util/superiotool/superiotool.h
diff options
context:
space:
mode:
authorRobinson P. Tryon <bishop.robinson@gmail.com>2008-01-15 22:30:55 +0000
committerUwe Hermann <uwe@hermann-uwe.de>2008-01-15 22:30:55 +0000
commit552cfb7b74cc0f39aee0c6babecdb045c81073e7 (patch)
treee1bd3b45ccdab7c806bc5742af4a4bb64754284c /util/superiotool/superiotool.h
parent6211ae13c3f366c0121a3b195196607f80cf29d3 (diff)
downloadcoreboot-552cfb7b74cc0f39aee0c6babecdb045c81073e7.tar.xz
Add new --list-supported switch for printing the list of Super I/Os
supported by superiotool (closes #91). Signed-off-by: Robinson P. Tryon <bishop.robinson@gmail.com> Acked-by: Uwe Hermann <uwe@hermann-uwe.de> git-svn-id: svn://svn.coreboot.org/coreboot/trunk@3050 2b7e53f0-3cfb-0310-b3e9-8179ed1497e1
Diffstat (limited to 'util/superiotool/superiotool.h')
-rw-r--r--util/superiotool/superiotool.h25
1 files changed, 24 insertions, 1 deletions
diff --git a/util/superiotool/superiotool.h b/util/superiotool/superiotool.h
index e7c4e2363b..5d402561a9 100644
--- a/util/superiotool/superiotool.h
+++ b/util/superiotool/superiotool.h
@@ -3,6 +3,7 @@
*
* Copyright (C) 2007 Carl-Daniel Hailfinger
* Copyright (C) 2007 Uwe Hermann <uwe@hermann-uwe.de>
+ * Copyright (C) 2008 Robinson P. Tryon <bishop.robinson@gmail.com>
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
@@ -29,8 +30,9 @@
#include <getopt.h>
#include <sys/io.h>
-#define USAGE "Usage: superiotool [-d] [-V] [-v] [-h]\n\n\
+#define USAGE "Usage: superiotool [-d] [-l] [-V] [-v] [-h]\n\n\
-d | --dump Dump Super I/O register contents\n\
+ -l | --list-supported Show the list of supported Super I/O chips\n\
-V | --verbose Verbose mode\n\
-v | --version Show the superiotool version\n\
-h | --help Show a short help text\n\n\
@@ -80,24 +82,32 @@ const char *get_superio_name(const struct superio_registers reg_table[],
void dump_superio(const char *name, const struct superio_registers reg_table[],
uint16_t port, uint16_t id);
void probing_for(const char *vendor, const char *info, uint16_t port);
+void print_vendor_chips(const char *vendor,
+ const struct superio_registers reg_table[]);
/* ali.c */
void probe_idregs_ali(uint16_t port);
+void print_ali_chips(void);
/* fintek.c */
void probe_idregs_fintek(uint16_t port);
+void print_fintek_chips(void);
/* ite.c */
void probe_idregs_ite(uint16_t port);
+void print_ite_chips(void);
/* nsc.c */
void probe_idregs_nsc(uint16_t port);
+void print_nsc_chips(void);
/* smsc.c */
void probe_idregs_smsc(uint16_t port);
+void print_smsc_chips(void);
/* winbond.c */
void probe_idregs_winbond(uint16_t port);
+void print_winbond_chips(void);
/** Table of which config ports to probe for each Super I/O family. */
static const struct {
@@ -112,4 +122,17 @@ static const struct {
{probe_idregs_winbond, {0x2e, 0x4e, 0x3f0, 0x370, 0x250, EOT}},
};
+
+/** Table of functions to print out supported Super I/O chips. */
+static const struct {
+ void (*print_list) (void);
+} vendor_print_functions[] = {
+ {print_ali_chips},
+ {print_fintek_chips},
+ {print_ite_chips},
+ {print_nsc_chips},
+ {print_smsc_chips},
+ {print_winbond_chips},
+};
+
#endif