summaryrefslogtreecommitdiff
path: root/flash.h
diff options
context:
space:
mode:
authorstefanct <stefanct@2b7e53f0-3cfb-0310-b3e9-8179ed1497e1>2014-08-08 23:52:33 +0000
committerstefanct <stefanct@2b7e53f0-3cfb-0310-b3e9-8179ed1497e1>2014-08-08 23:52:33 +0000
commit823451c426864c43f113b81aa77551328a585418 (patch)
tree9501e463b76abf831d62bfd1a9a9ac2f8939476e /flash.h
parentf69f0c63b93e60c9c3bfd2cb6f88544479ce2918 (diff)
downloadflashrom-823451c426864c43f113b81aa77551328a585418.tar.gz
Refactor some CLI-relevant parts.
Begin to move functions that clearly belong to the (command line) user interface out of flashrom's core files like flashrom.c. - Refine messages within check_chip_supported(), rename it to print_chip_support_status() and move it to newly created cli_common.c. - Move flashbuses_to_text() to cli_common.c as well. - Move global verbosity variables to cli_output.c. Signed-off-by: Stefan Tauner <stefan.tauner@alumni.tuwien.ac.at> Acked-by: Carl-Daniel Hailfinger <c-d.hailfinger.devel.2006@gmx.net> git-svn-id: https://code.coreboot.org/svn/flashrom/trunk@1841 2b7e53f0-3cfb-0310-b3e9-8179ed1497e1
Diffstat (limited to 'flash.h')
-rw-r--r--flash.h9
1 files changed, 6 insertions, 3 deletions
diff --git a/flash.h b/flash.h
index 8271da9..301eb7a 100644
--- a/flash.h
+++ b/flash.h
@@ -238,7 +238,6 @@ uint32_t chip_readl(const struct flashctx *flash, const chipaddr addr);
void chip_readn(const struct flashctx *flash, uint8_t *buf, const chipaddr addr, size_t len);
/* print.c */
-char *flashbuses_to_text(enum chipbustype bustype);
int print_supported(void);
void print_supported_wiki(void);
@@ -251,8 +250,6 @@ char *strcat_realloc(char *dest, const char *src);
void tolower_string(char *str);
/* flashrom.c */
-extern int verbose_screen;
-extern int verbose_logfile;
extern const char flashrom_version[];
extern const char *chip_to_probe;
void map_flash_registers(struct flashctx *flash);
@@ -285,7 +282,13 @@ int write_buf_to_file(const unsigned char *buf, unsigned long size, const char *
*/
#define ERROR_FLASHROM_LIMIT -201
+/* cli_common.c */
+char *flashbuses_to_text(enum chipbustype bustype);
+void print_chip_support_status(const struct flashchip *chip);
+
/* cli_output.c */
+extern int verbose_screen;
+extern int verbose_logfile;
#ifndef STANDALONE
int open_logfile(const char * const filename);
int close_logfile(void);