mirror of
https://github.com/AsahiLinux/u-boot
synced 2024-12-12 06:12:58 +00:00
1a28d38c39
Move FASTBOOT_VERSION to include/fastboot.h so when we merge the UDP code we only have one definition. Signed-off-by: Alex Kiernan <alex.kiernan@gmail.com> Reviewed-by: Simon Glass <sjg@chromium.org> Acked-by: Joe Hershberger <joe.hershberger@ni.com>
47 lines
1.3 KiB
C
47 lines
1.3 KiB
C
/* SPDX-License-Identifier: GPL-2.0+ */
|
|
/*
|
|
* (C) Copyright 2008 - 2009
|
|
* Windriver, <www.windriver.com>
|
|
* Tom Rix <Tom.Rix@windriver.com>
|
|
*
|
|
* Copyright 2011 Sebastian Andrzej Siewior <bigeasy@linutronix.de>
|
|
*
|
|
* Copyright 2014 Linaro, Ltd.
|
|
* Rob Herring <robh@kernel.org>
|
|
*/
|
|
#ifndef _FASTBOOT_H_
|
|
#define _FASTBOOT_H_
|
|
|
|
#define FASTBOOT_VERSION "0.4"
|
|
|
|
/* The 64 defined bytes plus \0 */
|
|
#define FASTBOOT_RESPONSE_LEN (64 + 1)
|
|
|
|
/**
|
|
* fastboot_response() - Writes a response of the form "$tag$reason".
|
|
*
|
|
* @tag: The first part of the response
|
|
* @response: Pointer to fastboot response buffer
|
|
* @format: printf style format string
|
|
*/
|
|
void fastboot_response(const char *tag, char *response,
|
|
const char *format, ...)
|
|
__attribute__ ((format (__printf__, 3, 4)));
|
|
|
|
/**
|
|
* fastboot_fail() - Write a FAIL response of the form "FAIL$reason".
|
|
*
|
|
* @reason: Pointer to returned reason string
|
|
* @response: Pointer to fastboot response buffer
|
|
*/
|
|
void fastboot_fail(const char *reason, char *response);
|
|
|
|
/**
|
|
* fastboot_okay() - Write an OKAY response of the form "OKAY$reason".
|
|
*
|
|
* @reason: Pointer to returned reason string, or NULL to send a bare "OKAY"
|
|
* @response: Pointer to fastboot response buffer
|
|
*/
|
|
void fastboot_okay(const char *reason, char *response);
|
|
int fastboot_set_reboot_flag(void);
|
|
#endif /* _FASTBOOT_H_ */
|