From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751335AbdEaPVt (ORCPT ); Wed, 31 May 2017 11:21:49 -0400 Received: from merlin.infradead.org ([205.233.59.134]:41258 "EHLO merlin.infradead.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751011AbdEaPVo (ORCPT ); Wed, 31 May 2017 11:21:44 -0400 Message-Id: <20170531152019.671439590@infradead.org> User-Agent: quilt/0.63-1 Date: Wed, 31 May 2017 17:16:14 +0200 From: Peter Zijlstra To: mingo@kernel.org, tglx@linutronix.de, rostedt@goodmis.org, bigeasy@linutronix.de Cc: linux-kernel@vger.kernel.org, peterz@infradead.org Subject: [RFC][PATCH 2/3] locking/selftest: Remove the bad unlock ordering test References: <20170531151612.797882111@infradead.org> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Disposition: inline; filename=peterz-locking-selftest-remove-unlock-order.patch Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org There is no such thing as a bad unlock order. Signed-off-by: Peter Zijlstra (Intel) --- lib/locking-selftest.c | 29 ----------------------------- 1 file changed, 29 deletions(-) --- a/lib/locking-selftest.c +++ b/lib/locking-selftest.c @@ -516,34 +516,6 @@ GENERATE_TESTCASE(double_unlock_rsem) #undef E /* - * Bad unlock ordering: - */ -#define E() \ - \ - LOCK(A); \ - LOCK(B); \ - UNLOCK(A); /* fail */ \ - UNLOCK(B); - -/* - * 6 testcases: - */ -#include "locking-selftest-spin.h" -GENERATE_TESTCASE(bad_unlock_order_spin) -#include "locking-selftest-wlock.h" -GENERATE_TESTCASE(bad_unlock_order_wlock) -#include "locking-selftest-rlock.h" -GENERATE_TESTCASE(bad_unlock_order_rlock) -#include "locking-selftest-mutex.h" -GENERATE_TESTCASE(bad_unlock_order_mutex) -#include "locking-selftest-wsem.h" -GENERATE_TESTCASE(bad_unlock_order_wsem) -#include "locking-selftest-rsem.h" -GENERATE_TESTCASE(bad_unlock_order_rsem) - -#undef E - -/* * initializing a held lock: */ #define E() \ @@ -1825,7 +1797,6 @@ void locking_selftest(void) DO_TESTCASE_6R("A-B-C-D-B-C-D-A deadlock", ABCDBCDA); DO_TESTCASE_6("double unlock", double_unlock); DO_TESTCASE_6("initialize held", init_held); - DO_TESTCASE_6_SUCCESS("bad unlock order", bad_unlock_order); printk(" --------------------------------------------------------------------------\n"); print_testname("recursive read-lock");