summaryrefslogtreecommitdiffstats
path: root/recipes-kernel/ceetm
diff options
context:
space:
mode:
authorTing Liu <ting.liu@nxp.com>2021-04-15 21:45:16 +0800
committerOtavio Salvador <otavio@ossystems.com.br>2021-04-15 11:18:16 -0300
commit4caa559c6a19ed183dd6d6a55313d4c9eac595b3 (patch)
tree73d783bdb8baafb6f5983a26a9043824d2ec6e69 /recipes-kernel/ceetm
parentca079524add69fb4c395e9983a158455178986d5 (diff)
downloadmeta-freescale-4caa559c6a19ed183dd6d6a55313d4c9eac595b3.tar.gz
ceetm: use new api tc_print_rate from iproute2
Fix the build issue due to api change in iproute2: | dpaa1_ceetm.c:637:4: error: too few arguments to function 'print_rate' | print_rate(buf, sizeof(buf), qopt->rate); | ^~~~~~~~~~ Signed-off-by: Ting Liu <ting.liu@nxp.com>
Diffstat (limited to 'recipes-kernel/ceetm')
-rw-r--r--recipes-kernel/ceetm/ceetm/0001-use-new-api-tc_print_rate.patch71
-rw-r--r--recipes-kernel/ceetm/ceetm_git.bb1
2 files changed, 72 insertions, 0 deletions
diff --git a/recipes-kernel/ceetm/ceetm/0001-use-new-api-tc_print_rate.patch b/recipes-kernel/ceetm/ceetm/0001-use-new-api-tc_print_rate.patch
new file mode 100644
index 00000000..bd077f8a
--- /dev/null
+++ b/recipes-kernel/ceetm/ceetm/0001-use-new-api-tc_print_rate.patch
@@ -0,0 +1,71 @@
1From 1eeee62be6f4f4c0564a1ebbf47b5d1ebd7ab282 Mon Sep 17 00:00:00 2001
2From: Ting Liu <ting.liu@nxp.com>
3Date: Thu, 15 Apr 2021 14:43:31 +0530
4Subject: [PATCH] use new api tc_print_rate
5
6Fix the build issue due to api change in iproute2:
7| dpaa1_ceetm.c:637:4: error: too few arguments to function 'print_rate'
8| print_rate(buf, sizeof(buf), qopt->rate);
9| ^~~~~~~~~~
10
11Upstream-Status: Pending
12
13Signed-off-by: Ting Liu <ting.liu@nxp.com>
14---
15 dpaa1_ceetm.c | 12 ++++--------
16 dpaa2_ceetm.c | 6 ++----
17 2 files changed, 6 insertions(+), 12 deletions(-)
18
19diff --git a/dpaa1_ceetm.c b/dpaa1_ceetm.c
20index 15a2cd8..347e79a 100644
21--- a/dpaa1_ceetm.c
22+++ b/dpaa1_ceetm.c
23@@ -634,11 +634,9 @@ int dpaa1_ceetm_print_qopt(struct qdisc_util *qu, FILE *f,
24 fprintf(f, "type root");
25
26 if (qopt->shaped) {
27- print_rate(buf, sizeof(buf), qopt->rate);
28- fprintf(f, " shaped rate %s ", buf);
29+ tc_print_rate(PRINT_FP, NULL, " shaped rate %s ", qopt->rate);
30
31- print_rate(buf, sizeof(buf), qopt->ceil);
32- fprintf(f, "ceil %s ", buf);
33+ tc_print_rate(PRINT_FP, NULL, "ceil %s ", qopt->ceil);
34
35 fprintf(f, "overhead %u ", qopt->overhead);
36
37@@ -692,11 +690,9 @@ int dpaa1_ceetm_print_copt(struct qdisc_util *qu, FILE *f,
38 fprintf(f, "type root ");
39
40 if (copt->shaped) {
41- print_rate(buf, sizeof(buf), copt->rate);
42- fprintf(f, "shaped rate %s ", buf);
43+ tc_print_rate(PRINT_FP, NULL, "shaped rate %s ", copt->rate);
44
45- print_rate(buf, sizeof(buf), copt->ceil);
46- fprintf(f, "ceil %s ", buf);
47+ tc_print_rate(PRINT_FP, NULL, "ceil %s ", copt->ceil);
48
49 } else {
50 fprintf(f, "unshaped tbl %d", copt->tbl);
51diff --git a/dpaa2_ceetm.c b/dpaa2_ceetm.c
52index 6b1b033..0505046 100644
53--- a/dpaa2_ceetm.c
54+++ b/dpaa2_ceetm.c
55@@ -516,11 +516,9 @@ int dpaa2_ceetm_print_copt(struct qdisc_util *qu, FILE *f, struct rtattr *opt)
56 fprintf(f, "type root ");
57
58 if (copt->shaped) {
59- print_rate(buf, sizeof(buf), copt->shaping_cfg.cir);
60- fprintf(f, "CIR %s ", buf);
61+ tc_print_rate(PRINT_FP, NULL, "CIR %s ", copt->shaping_cfg.cir);
62
63- print_rate(buf, sizeof(buf), copt->shaping_cfg.eir);
64- fprintf(f, "EIR %s ", buf);
65+ tc_print_rate(PRINT_FP, NULL, "EIR %s ", copt->shaping_cfg.eir);
66
67 fprintf(f, "CBS %d EBS %d ", copt->shaping_cfg.cbs, copt->shaping_cfg.ebs);
68
69--
702.25.1
71
diff --git a/recipes-kernel/ceetm/ceetm_git.bb b/recipes-kernel/ceetm/ceetm_git.bb
index 68fb67e0..2e92ad49 100644
--- a/recipes-kernel/ceetm/ceetm_git.bb
+++ b/recipes-kernel/ceetm/ceetm_git.bb
@@ -5,6 +5,7 @@ LIC_FILES_CHKSUM = "file://COPYING;md5=bac620b9883d38a84dfb73ca7122d915"
5SRC_URI = "git://source.codeaurora.org/external/qoriq/qoriq-components/ceetm;nobranch=1" 5SRC_URI = "git://source.codeaurora.org/external/qoriq/qoriq-components/ceetm;nobranch=1"
6SRCREV = "6a7f2ec2091df2f4380cb8d25a36c399aed5af1b" 6SRCREV = "6a7f2ec2091df2f4380cb8d25a36c399aed5af1b"
7SRC_URI_append = " file://0001-Makefile-update-CFLAGS.patch \ 7SRC_URI_append = " file://0001-Makefile-update-CFLAGS.patch \
8 file://0001-use-new-api-tc_print_rate.patch \
8" 9"
9DEPENDS = "iproute2" 10DEPENDS = "iproute2"
10 11