51 lines
1.5 KiB
Diff
51 lines
1.5 KiB
Diff
|
commit 11cc3508d4b7594e2a429000d162b3582d242c20
|
||
|
Author: Miroslav Lichvar <mlichvar@redhat.com>
|
||
|
Date: Mon Nov 6 14:10:42 2023 +0100
|
||
|
|
||
|
Fix printf formats for 32-bit archs
|
||
|
|
||
|
Signed-off-by: Miroslav Lichvar <mlichvar@redhat.com>
|
||
|
|
||
|
diff --git a/config.c b/config.c
|
||
|
index 56fcbbd..723ff84 100644
|
||
|
--- a/config.c
|
||
|
+++ b/config.c
|
||
|
@@ -21,6 +21,7 @@
|
||
|
*/
|
||
|
#include <ctype.h>
|
||
|
#include <float.h>
|
||
|
+#include <inttypes.h>
|
||
|
#include <limits.h>
|
||
|
#include <stdio.h>
|
||
|
#include <stdlib.h>
|
||
|
@@ -767,7 +768,7 @@ config_get_u64(struct config *cfg, const char *section, const char *option)
|
||
|
pr_err("bug: config option %s type mismatch!", option);
|
||
|
exit(-1);
|
||
|
}
|
||
|
- pr_debug("config item %s.%s is %lu (0x%lx)", section, option,
|
||
|
+ pr_debug("config item %s.%s is %"PRIu64" (0x%"PRIx64")", section, option,
|
||
|
ci->val.u64, ci->val.u64);
|
||
|
return ci->val.u64;
|
||
|
}
|
||
|
diff --git a/nl_dpll.c b/nl_dpll.c
|
||
|
index f343de6..4dee01b 100644
|
||
|
--- a/nl_dpll.c
|
||
|
+++ b/nl_dpll.c
|
||
|
@@ -8,6 +8,7 @@
|
||
|
#include <netlink/genl/genl.h>
|
||
|
#include <netlink/genl/ctrl.h>
|
||
|
#include <linux/rtnetlink.h>
|
||
|
+#include <inttypes.h>
|
||
|
#include <errno.h>
|
||
|
#include "nl_dpll.h"
|
||
|
#include "print.h"
|
||
|
@@ -118,7 +119,7 @@ int nl_dpll_device_id_get(struct nl_sock *sk, struct sk_arg *arg,
|
||
|
pr_err("%s: failed to send request", __func__);
|
||
|
goto msg_free;
|
||
|
}
|
||
|
- pr_debug("DEVICE_ID_GET request sent dpll id: %lu %s, ret:%d",
|
||
|
+ pr_debug("DEVICE_ID_GET request sent dpll id: %"PRIu64" %s, ret:%d",
|
||
|
clock_id, module_name, ret);
|
||
|
|
||
|
arg->err = 0;
|