[U-Boot] [PATCH] board: ge: Use correct vpd_reader callback signature
Sebastian Reichel
sebastian.reichel at collabora.com
Sun Dec 9 23:07:54 UTC 2018
Fix compiler warning due to incorrect vpd_callback function
signature.
Signed-off-by: Sebastian Reichel <sebastian.reichel at collabora.com>
---
board/ge/mx53ppd/mx53ppd.c | 6 ++----
1 file changed, 2 insertions(+), 4 deletions(-)
diff --git a/board/ge/mx53ppd/mx53ppd.c b/board/ge/mx53ppd/mx53ppd.c
index f0c8abf0bb4d..a9d87163a4eb 100644
--- a/board/ge/mx53ppd/mx53ppd.c
+++ b/board/ge/mx53ppd/mx53ppd.c
@@ -290,11 +290,9 @@ struct vpd_cache {
/*
* Extracts MAC and product information from the VPD.
*/
-static int vpd_callback(void *userdata, u8 id, u8 version, u8 type, size_t size,
- u8 const *data)
+static int vpd_callback(struct vpd_cache *vpd, u8 id, u8 version, u8 type,
+ size_t size, u8 const *data)
{
- struct vpd_cache *vpd = (struct vpd_cache *)userdata;
-
if (id == VPD_BLOCK_HWID && version == 1 && type != VPD_TYPE_INVALID &&
size >= 1) {
vpd->product_id = data[0];
--
2.19.2
More information about the U-Boot
mailing list