From a1483f88b6e21dd3ea481a021e5d4f7f273204c6 Mon Sep 17 00:00:00 2001 From: "Michael S. Tsirkin" Date: Wed, 5 Feb 2014 21:57:55 +0200 Subject: [PATCH] loader: document that errno is set Document that get_image_size sets errno on failure. Suggested-by: Peter Maydell Reviewed-by: Eric Blake Signed-off-by: Michael S. Tsirkin --- include/hw/loader.h | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/include/hw/loader.h b/include/hw/loader.h index 7a23d6bdc1..91b01224a3 100644 --- a/include/hw/loader.h +++ b/include/hw/loader.h @@ -4,6 +4,13 @@ #include "hw/nvram/fw_cfg.h" /* loader.c */ +/** + * get_image_size: retrieve size of an image file + * @filename: Path to the image file + * + * Returns the size of the image file on success, -1 otherwise. + * On error, errno is also set as appropriate. + */ int get_image_size(const char *filename); int load_image(const char *filename, uint8_t *addr); /* deprecated */ int load_image_targphys(const char *filename, hwaddr,