From: Alex Shi <alex.shi@linux.alibaba.com>
To: unlisted-recipients:; (no To-header on input)
Cc: Peter Zijlstra <peterz@infradead.org>,
Ingo Molnar <mingo@redhat.com>, Will Deacon <will@kernel.org>,
linux-kernel@vger.kernel.org
Subject: [PATCH] locking/selftest: remove unused macros
Date: Tue, 21 Jan 2020 16:34:49 +0800 [thread overview]
Message-ID: <1579595689-251576-1-git-send-email-alex.shi@linux.alibaba.com> (raw)
WLU is never used. and DO_TESTCASE_6_SUCCESS isn't used from
commit cfb6133399a4 ("locking/selftest: Remove the bad unlock ordering test")
So better to remove them.
Signed-off-by: Alex Shi <alex.shi@linux.alibaba.com>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Ingo Molnar <mingo@redhat.com>
Cc: Will Deacon <will@kernel.org>
Cc: linux-kernel@vger.kernel.org
---
lib/locking-selftest.c | 12 ------------
1 file changed, 12 deletions(-)
diff --git a/lib/locking-selftest.c b/lib/locking-selftest.c
index 14f44f59e733..6b0f55581485 100644
--- a/lib/locking-selftest.c
+++ b/lib/locking-selftest.c
@@ -216,7 +216,6 @@ static void init_shared_classes(void)
#define WL(x) write_lock(&rwlock_##x)
#define WU(x) write_unlock(&rwlock_##x)
-#define WLU(x) WL(x); WU(x)
#define RL(x) read_lock(&rwlock_##x)
#define RU(x) read_unlock(&rwlock_##x)
@@ -1224,17 +1223,6 @@ static inline void print_testname(const char *testname)
dotest_rt(name##_rtmutex, FAILURE, LOCKTYPE_RTMUTEX); \
pr_cont("\n");
-#define DO_TESTCASE_6_SUCCESS(desc, name) \
- print_testname(desc); \
- dotest(name##_spin, SUCCESS, LOCKTYPE_SPIN); \
- dotest(name##_wlock, SUCCESS, LOCKTYPE_RWLOCK); \
- dotest(name##_rlock, SUCCESS, LOCKTYPE_RWLOCK); \
- dotest(name##_mutex, SUCCESS, LOCKTYPE_MUTEX); \
- dotest(name##_wsem, SUCCESS, LOCKTYPE_RWSEM); \
- dotest(name##_rsem, SUCCESS, LOCKTYPE_RWSEM); \
- dotest_rt(name##_rtmutex, SUCCESS, LOCKTYPE_RTMUTEX); \
- pr_cont("\n");
-
/*
* 'read' variant: rlocks must not trigger.
*/
--
1.8.3.1
reply other threads:[~2020-01-21 8:34 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=1579595689-251576-1-git-send-email-alex.shi@linux.alibaba.com \
--to=alex.shi@linux.alibaba.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@redhat.com \
--cc=peterz@infradead.org \
--cc=will@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: 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;
as well as URLs for NNTP newsgroup(s).