X-Git-Url: https://git.sur5r.net/?a=blobdiff_plain;f=arch%2Fsandbox%2Finclude%2Fasm%2Fstate.h;h=e876ba29784171fa177dee815bf9328cdf7bc410;hb=9723563aa821e9c9b881dfe6a082f6301ca69826;hp=a0c24ba1e053fec66990626812332a60302b6276;hpb=b9cb64825b5e6efeb715abd8b48d9b12f98973e9;p=u-boot diff --git a/arch/sandbox/include/asm/state.h b/arch/sandbox/include/asm/state.h index a0c24ba1e0..e876ba2978 100644 --- a/arch/sandbox/include/asm/state.h +++ b/arch/sandbox/include/asm/state.h @@ -7,6 +7,7 @@ #define __SANDBOX_STATE_H #include +#include #include #include @@ -42,6 +43,7 @@ struct sandbox_spi_info { struct sandbox_state { const char *cmd; /* Command to execute */ bool interactive; /* Enable cmdline after execute */ + bool run_distro_boot; /* Automatically run distro bootcommands */ const char *fdt_fname; /* Filename of FDT binary */ const char *parse_err; /* Error to report from parsing */ int argc; /* Program arguments */ @@ -58,7 +60,10 @@ struct sandbox_state { bool write_state; /* Write sandbox state on exit */ bool ignore_missing_state_on_read; /* No error if state missing */ bool show_lcd; /* Show LCD on start-up */ + enum reset_t last_reset; /* Last reset type */ + bool reset_allowed[RESET_COUNT]; /* Allowed reset types */ enum state_terminal_raw term_raw; /* Terminal raw/cooked */ + bool skip_delays; /* Ignore any time delays (for test) */ /* Pointer to information for each SPI bus/cs */ struct sandbox_spi_info spi[CONFIG_SANDBOX_SPI_MAX_BUS] @@ -180,6 +185,24 @@ int sandbox_write_state(struct sandbox_state *state, const char *fname); */ int state_setprop(int node, const char *prop_name, const void *data, int size); +/** + * Control skipping of time delays + * + * Some tests have unnecessay time delays (e.g. USB). Allow these to be + * skipped to speed up testing + * + * @param skip_delays true to skip delays from now on, false to honour delay + * requests + */ +void state_set_skip_delays(bool skip_delays); + +/** + * See if delays should be skipped + * + * @return true if delays should be skipped, false if they should be honoured + */ +bool state_get_skip_delays(void); + /** * Initialize the test system state */