From 3c8f98f5fed5c6f03bb185b79191477885748b14 Mon Sep 17 00:00:00 2001 From: Maxime Ripard Date: Thu, 15 Oct 2015 14:34:13 +0200 Subject: fastboot: Move fastboot response functions to fastboot core The functions and a few define to generate a fastboot message to be sent back to the host were so far duplicated among the users. Move them all to a common place. Signed-off-by: Maxime Ripard Reviewed-by: Tom Rini --- include/fastboot.h | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) create mode 100644 include/fastboot.h (limited to 'include/fastboot.h') diff --git a/include/fastboot.h b/include/fastboot.h new file mode 100644 index 0000000..db826d2 --- /dev/null +++ b/include/fastboot.h @@ -0,0 +1,22 @@ +/* + * (C) Copyright 2008 - 2009 + * Windriver, + * Tom Rix + * + * Copyright 2011 Sebastian Andrzej Siewior + * + * Copyright 2014 Linaro, Ltd. + * Rob Herring + * + * SPDX-License-Identifier: GPL-2.0+ + */ +#ifndef _FASTBOOT_H_ +#define _FASTBOOT_H_ + +/* The 64 defined bytes plus \0 */ +#define FASTBOOT_RESPONSE_LEN (64 + 1) + +void fastboot_fail(char *response, const char *reason); +void fastboot_okay(char *response, const char *reason); + +#endif /* _FASTBOOT_H_ */ -- cgit v1.1