summaryrefslogtreecommitdiff
path: root/tools/kwbimage.h
diff options
context:
space:
mode:
authorMarek BehĂșn <marek.behun@nic.cz>2021-09-25 00:07:00 +0300
committerStefan Roese <sr@denx.de>2021-10-01 12:07:13 +0300
commitacb0b38d6a2acd47cfef34ae002b3cd8be4fa16a (patch)
tree800607f475ed5aeb5328af94bed3234c3ab2bbf5 /tools/kwbimage.h
parentf2c644e0b8bc7dc842c8b27e65c69e503687296f (diff)
downloadu-boot-acb0b38d6a2acd47cfef34ae002b3cd8be4fa16a.tar.xz
tools: kwbimage: Refactor image_version()
Rename this function to kwbimage_version() and don't cast argument if not needed. Signed-off-by: Marek BehĂșn <marek.behun@nic.cz> Reviewed-by: Stefan Roese <sr@denx.de>
Diffstat (limited to 'tools/kwbimage.h')
-rw-r--r--tools/kwbimage.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/tools/kwbimage.h b/tools/kwbimage.h
index a09dbf19ad..643977685a 100644
--- a/tools/kwbimage.h
+++ b/tools/kwbimage.h
@@ -229,7 +229,7 @@ void init_kwb_image_type (void);
* header, byte 8 was reserved, and always set to 0. In the v1 header,
* byte 8 has been changed to a proper field, set to 1.
*/
-static inline unsigned int image_version(const void *header)
+static inline unsigned int kwbimage_version(const void *header)
{
const unsigned char *ptr = header;
return ptr[8];
@@ -258,7 +258,7 @@ static inline int opt_hdr_v1_valid_size(const struct opt_hdr_v1 *ohdr,
static inline struct opt_hdr_v1 *opt_hdr_v1_first(void *img) {
struct main_hdr_v1 *mhdr;
- if (image_version(img) != 1)
+ if (kwbimage_version(img) != 1)
return NULL;
mhdr = img;