From: "Wieczor-Retman, Maciej" <maciej.wieczor-retman@intel.com> To: Nhat Pham <nphamcs@gmail.com>, Johannes Weiner <hannes@cmpxchg.org>, Shuah Khan <shuah@kernel.org> Cc: ilpo.jarvinen@linux.intel.com, reinette.chatre@intel.com, "Wieczor-Retman, Maciej" <maciej.wieczor-retman@intel.com>, Wieczor-Retman@kvack.org, linux-mm@kvack.org, linux-kselftest@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 2/6] selftests/cachestat: Fix print_cachestat format Date: Mon, 28 Aug 2023 12:49:06 +0200 [thread overview] Message-ID: <8417dcd7ebdc464d12850873d6c48f95293e673c.1693216959.git.maciej.wieczor-retman@intel.com> (raw) In-Reply-To: <cover.1693216959.git.maciej.wieczor-retman@intel.com> The format specifier in printf() call expects long int variables and received long long int. Change format specifiers to long long int so they match passed variables. Signed-off-by: Wieczor-Retman, Maciej <maciej.wieczor-retman@intel.com> --- tools/testing/selftests/cachestat/test_cachestat.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/testing/selftests/cachestat/test_cachestat.c b/tools/testing/selftests/cachestat/test_cachestat.c index 77620e7ecf56..a7adf42afb20 100644 --- a/tools/testing/selftests/cachestat/test_cachestat.c +++ b/tools/testing/selftests/cachestat/test_cachestat.c @@ -25,7 +25,7 @@ static const char * const dev_files[] = { void print_cachestat(struct cachestat *cs) { ksft_print_msg( - "Using cachestat: Cached: %lu, Dirty: %lu, Writeback: %lu, Evicted: %lu, Recently Evicted: %lu\n", + "Using cachestat: Cached: %llu, Dirty: %llu, Writeback: %llu, Evicted: %llu, Recently Evicted: %llu\n", cs->nr_cache, cs->nr_dirty, cs->nr_writeback, cs->nr_evicted, cs->nr_recently_evicted); } -- 2.42.0
WARNING: multiple messages have this Message-ID (diff)
From: "Wieczor-Retman, Maciej" <maciej.wieczor-retman@intel.com> To: Nhat Pham <nphamcs@gmail.com>, Johannes Weiner <hannes@cmpxchg.org>, Shuah Khan <shuah@kernel.org> Cc: ilpo.jarvinen@linux.intel.com, reinette.chatre@intel.com, "Wieczor-Retman, Maciej" <maciej.wieczor-retman@intel.com>, Wieczor-Retman@vger.kernel.org, linux-mm@kvack.org, linux-kselftest@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 2/6] selftests/cachestat: Fix print_cachestat format Date: Mon, 28 Aug 2023 12:49:06 +0200 [thread overview] Message-ID: <8417dcd7ebdc464d12850873d6c48f95293e673c.1693216959.git.maciej.wieczor-retman@intel.com> (raw) In-Reply-To: <cover.1693216959.git.maciej.wieczor-retman@intel.com> The format specifier in printf() call expects long int variables and received long long int. Change format specifiers to long long int so they match passed variables. Signed-off-by: Wieczor-Retman, Maciej <maciej.wieczor-retman@intel.com> --- tools/testing/selftests/cachestat/test_cachestat.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/testing/selftests/cachestat/test_cachestat.c b/tools/testing/selftests/cachestat/test_cachestat.c index 77620e7ecf56..a7adf42afb20 100644 --- a/tools/testing/selftests/cachestat/test_cachestat.c +++ b/tools/testing/selftests/cachestat/test_cachestat.c @@ -25,7 +25,7 @@ static const char * const dev_files[] = { void print_cachestat(struct cachestat *cs) { ksft_print_msg( - "Using cachestat: Cached: %lu, Dirty: %lu, Writeback: %lu, Evicted: %lu, Recently Evicted: %lu\n", + "Using cachestat: Cached: %llu, Dirty: %llu, Writeback: %llu, Evicted: %llu, Recently Evicted: %llu\n", cs->nr_cache, cs->nr_dirty, cs->nr_writeback, cs->nr_evicted, cs->nr_recently_evicted); } -- 2.42.0
next prev parent reply other threads:[~2023-08-28 10:50 UTC|newest] Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top 2023-08-28 10:48 [PATCH 0/6] Add printf attribute to kselftest functions Wieczor-Retman, Maciej 2023-08-28 10:49 ` [PATCH 1/6] selftests: Add printf attribute to ksefltest prints Wieczor-Retman, Maciej 2023-08-28 10:49 ` Wieczor-Retman, Maciej [this message] 2023-08-28 10:49 ` [PATCH 2/6] selftests/cachestat: Fix print_cachestat format Wieczor-Retman, Maciej 2023-08-28 14:00 ` Nhat Pham 2023-08-28 14:04 ` Nhat Pham 2023-08-28 10:49 ` [PATCH 3/6] selftests/openat2: Fix wrong format specifier Wieczor-Retman, Maciej 2023-08-30 12:25 ` Ilpo Järvinen 2023-08-28 10:49 ` [PATCH 4/6] selftests/pidfd: Fix ksft print formats Wieczor-Retman, Maciej 2023-08-28 11:01 ` Ilpo Järvinen 2023-08-28 13:07 ` Maciej Wieczór-Retman 2023-08-28 10:49 ` [PATCH 5/6] selftests/sigaltstack: Fix wrong format specifier Wieczor-Retman, Maciej 2023-08-30 12:02 ` Ilpo Järvinen 2023-08-28 10:49 ` [PATCH 6/6] selftests/kvm: Replace attribute with macro Wieczor-Retman, Maciej 2023-08-30 12:22 ` Ilpo Järvinen 2023-08-30 13:40 ` Maciej Wieczór-Retman 2023-08-31 14:33 ` Andrew Jones
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=8417dcd7ebdc464d12850873d6c48f95293e673c.1693216959.git.maciej.wieczor-retman@intel.com \ --to=maciej.wieczor-retman@intel.com \ --cc=Wieczor-Retman@kvack.org \ --cc=hannes@cmpxchg.org \ --cc=ilpo.jarvinen@linux.intel.com \ --cc=linux-kernel@vger.kernel.org \ --cc=linux-kselftest@vger.kernel.org \ --cc=linux-mm@kvack.org \ --cc=nphamcs@gmail.com \ --cc=reinette.chatre@intel.com \ --cc=shuah@kernel.org \ /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: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes, see mirroring instructions on how to clone and mirror all data and code used by this external index.