From: "tip-bot2 for 晏艳(采苓)" <tip-bot2@linutronix.de>
To: linux-tip-commits@vger.kernel.org
Cc: Yan Yan <yanyan.yan@antgroup.com>,
"Peter Zijlstra (Intel)" <peterz@infradead.org>,
x86@kernel.org, linux-kernel@vger.kernel.org
Subject: [tip: sched/core] sched/debug: Correct printing for rq->nr_uninterruptible
Date: Wed, 10 May 2023 13:49:08 -0000 [thread overview]
Message-ID: <168372654853.404.17704354733934460594.tip-bot2@tip-bot2> (raw)
In-Reply-To: <20230506074253.44526-1-yanyan.yan@antgroup.com>
The following commit has been merged into the sched/core branch of tip:
Commit-ID: a6fcdd8d95f7486150b3faadfea119fc3dfc3b74
Gitweb: https://git.kernel.org/tip/a6fcdd8d95f7486150b3faadfea119fc3dfc3b74
Author: 晏艳(采苓) <yanyan.yan@antgroup.com>
AuthorDate: Sat, 06 May 2023 15:42:53 +08:00
Committer: Peter Zijlstra <peterz@infradead.org>
CommitterDate: Mon, 08 May 2023 10:58:39 +02:00
sched/debug: Correct printing for rq->nr_uninterruptible
Commit e6fe3f422be1 ("sched: Make multiple runqueue task counters
32-bit") changed the type for rq->nr_uninterruptible from "unsigned
long" to "unsigned int", but left wrong cast print to
/sys/kernel/debug/sched/debug and to the console.
For example, nr_uninterruptible's value is fffffff7 with type
"unsigned int", (long)nr_uninterruptible shows 4294967287 while
(int)nr_uninterruptible prints -9. So using int cast fixes wrong
printing.
Signed-off-by: Yan Yan <yanyan.yan@antgroup.com>
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Link: https://lkml.kernel.org/r/20230506074253.44526-1-yanyan.yan@antgroup.com
---
kernel/sched/debug.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/kernel/sched/debug.c b/kernel/sched/debug.c
index 0b2340a..066ff1c 100644
--- a/kernel/sched/debug.c
+++ b/kernel/sched/debug.c
@@ -777,7 +777,7 @@ static void print_cpu(struct seq_file *m, int cpu)
#define P(x) \
do { \
if (sizeof(rq->x) == 4) \
- SEQ_printf(m, " .%-30s: %ld\n", #x, (long)(rq->x)); \
+ SEQ_printf(m, " .%-30s: %d\n", #x, (int)(rq->x)); \
else \
SEQ_printf(m, " .%-30s: %Ld\n", #x, (long long)(rq->x));\
} while (0)
prev parent reply other threads:[~2023-05-10 13:49 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-05-06 7:42 [PATCH v2] sched/debug: correct " 晏艳(采苓)
2023-05-10 13:49 ` tip-bot2 for 晏艳(采苓) [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=168372654853.404.17704354733934460594.tip-bot2@tip-bot2 \
--to=tip-bot2@linutronix.de \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-tip-commits@vger.kernel.org \
--cc=peterz@infradead.org \
--cc=x86@kernel.org \
--cc=yanyan.yan@antgroup.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®