loader: document that errno is set
authorMichael S. Tsirkin <mst@redhat.com>
Wed, 5 Feb 2014 19:57:55 +0000 (21:57 +0200)
committerMichael S. Tsirkin <mst@redhat.com>
Mon, 10 Feb 2014 08:23:35 +0000 (10:23 +0200)
Document that get_image_size sets errno
on failure.

Suggested-by: Peter Maydell <peter.maydell@linaro.org>
Reviewed-by: Eric Blake <eblake@redhat.com>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
include/hw/loader.h

index 7a23d6bdc1b722d0b1c972d1917bb80fa34129e0..91b01224a3f1d219f7824b0e911522deac3dd280 100644 (file)
@@ -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,