Received: by 2002:a25:1506:0:0:0:0:0 with SMTP id 6csp253203ybv; Tue, 18 Feb 2020 22:27:47 -0800 (PST) X-Google-Smtp-Source: APXvYqwW5+C/vlScGuXmiNTnVUpVm+LV08kEOGAF/+C26vH0O8rY7ihjOuLQm42oSe18/dOgoOrV X-Received: by 2002:aca:f487:: with SMTP id s129mr3778378oih.75.1582093667506; Tue, 18 Feb 2020 22:27:47 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1582093667; cv=none; d=google.com; s=arc-20160816; b=Eow0e2LIzyyM52VaLrwaPxr4QTFsgH9//QjgNy3yhde65yzHRkRBwNOaM2y3W7FNo2 FQtu/y4MxN+/UJ94oogRUf/liIaBwSAulUiu/IFXwvpL30XMvA6K3ZltFzCKnQXn8+9a 3WOI3vZH2wdf+SMcpEem64nJPQEUxGfRio1VD7QYeX+1BSm7Oo3ZniXVL/PGTUvM6rEu cZDf01YJftHrI0XHV014h8D2nm9lt98oZQSdE6TA8TEoguadslX2vjU28TbjMXRwuu7e a+2lPB94naitlNaOVvI5URwl+As3OQ4JOceGMNPTQqqnQBCdstd8A3HsMYQTSkMCULlS qVjg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=hXaVpGqqToiZNRZTnPuTvkrof7XCekzeFTv2omJ7ql0=; b=PEII7OPkBDJycMoGTNv7MhSWdpg7E1gwVF+KXWDTsq0BKfsQJW2kO5+BrbxBLlYezB Xw7a3kPIlBvkgk9oa606+dUUcVXGjGObm3qvL05BWHh1E0bA7FCuN/VgO3aqp4uzk9Hb VSmdWyFB888UaM4kXjXhWRzgWxv+e+mFbZsWvZ5CmlsstL6vkj9Oh6G+qFh/U5hAGviy W93ONm3ilYP5jiNLnGItNBH+xKszMmVtYwGy2txp5WTcPtjixnbW1BjAJebRe1iZJX8/ XKUET+orY1OfGu0C2YUOQtJfS/DcmA7rzcHmn5xxtyUNfQDB538QvW63p9umEr4t4isw MFWg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=aTGJxfGa; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id g2si726761otn.117.2020.02.18.22.27.35; Tue, 18 Feb 2020 22:27:47 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=aTGJxfGa; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726636AbgBSG0z (ORCPT + 99 others); Wed, 19 Feb 2020 01:26:55 -0500 Received: from mail-qv1-f65.google.com ([209.85.219.65]:42270 "EHLO mail-qv1-f65.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726121AbgBSG0m (ORCPT ); Wed, 19 Feb 2020 01:26:42 -0500 Received: by mail-qv1-f65.google.com with SMTP id dc14so10324674qvb.9; Tue, 18 Feb 2020 22:26:41 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=hXaVpGqqToiZNRZTnPuTvkrof7XCekzeFTv2omJ7ql0=; b=aTGJxfGaQguG/6WoGHY8BrKiu17y3QOpcCYo76xvmyaS/GSok2dRM6n59tD8pavXWj f+V0zsR/stnq5zPkngYrYCjvtH2CRDnugF1neZiMHEtSamCv1ZZRijR6wI1l8dpG0kGW 6JYlpj1Bq0u7dkfpM5AFpfEkh1pZOTVrsY5HgmKfCdWAL24uuiM8u8UMlToBKpUFcOrF fJIeENfBZMjRxwhCp41/Lr1hKQLZ1MpOaC3eLqbH4E/Nygwx6CST/oMNCA8YsBlmTRds pC4nc/ZS1I5Wpyi+Jvodp1DCKKxx+lFaxsKZr7Hv9OwqxSqVj4ToVvu/bcSZ79wx2NsC JDmg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=hXaVpGqqToiZNRZTnPuTvkrof7XCekzeFTv2omJ7ql0=; b=UkOdQbfUEGjbR0k3HH4GEiDWry/VjMitArrm7QO7aXSnPyl9cEh20fo3hB5JmORjnT VQYIMffLxFp+DhEZGdam1DLiGTDLFkdBk8DpOtGT2rtbszouNJmx9ZyH9sQem9yrkStn kN8abPi/COzHlP/a5M61VtWo8w9v8S5v9QX2s/OSYJ+2K9ra+LwuqaMSCwPsGSbmVLxV iy6legj25x6Kg88I1xi8/1bOBpMRF+YNh5utRyxdafUxlXHmRT7lEFCqQ8cHajBMSyNc 4oMmgsBl7tMp48h3eynIJUcUwAsJvf8zGEmLKopB0D2OJjR7Hb4qykZYkt1WXRKXkpo3 0j0A== X-Gm-Message-State: APjAAAUucx/AL9RFKFYeAB3SIkTu/cdnzLfHW6MBjgvUmch2jZ9e6SsZ 63VWpuJ4TlpOch0Frz36Btw= X-Received: by 2002:a0c:e453:: with SMTP id d19mr231732qvm.217.1582093601083; Tue, 18 Feb 2020 22:26:41 -0800 (PST) Received: from auth1-smtp.messagingengine.com (auth1-smtp.messagingengine.com. [66.111.4.227]) by smtp.gmail.com with ESMTPSA id o55sm499907qtf.46.2020.02.18.22.26.39 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 18 Feb 2020 22:26:39 -0800 (PST) Received: from compute6.internal (compute6.nyi.internal [10.202.2.46]) by mailauth.nyi.internal (Postfix) with ESMTP id 7B4442205E; Wed, 19 Feb 2020 01:26:38 -0500 (EST) Received: from mailfrontend1 ([10.202.2.162]) by compute6.internal (MEProxy); Wed, 19 Feb 2020 01:26:38 -0500 X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedugedrjeelgdelgecutefuodetggdotefrodftvf curfhrohhfihhlvgemucfhrghsthforghilhdpqfgfvfdpuffrtefokffrpgfnqfghnecu uegrihhlohhuthemuceftddtnecusecvtfgvtghiphhivghnthhsucdlqddutddtmdenuc fjughrpefhvffufffkofgjfhgggfestdekredtredttdenucfhrhhomhepuehoqhhunhcu hfgvnhhguceosghoqhhunhdrfhgvnhhgsehgmhgrihhlrdgtohhmqeenucffohhmrghinh epkhgvrhhnvghlrdhorhhgnecukfhppeehvddrudehhedrudduuddrjedunecuvehluhhs thgvrhfuihiivgeptdenucfrrghrrghmpehmrghilhhfrhhomhepsghoqhhunhdomhgvsh hmthhprghuthhhphgvrhhsohhnrghlihhthidqieelvdeghedtieegqddujeejkeehheeh vddqsghoqhhunhdrfhgvnhhgpeepghhmrghilhdrtghomhesfhhigihmvgdrnhgrmhgv X-ME-Proxy: Received: from localhost (unknown [52.155.111.71]) by mail.messagingengine.com (Postfix) with ESMTPA id AC32D328005E; Wed, 19 Feb 2020 01:26:35 -0500 (EST) From: Boqun Feng To: linux-kernel@vger.kernel.org Cc: Alan Stern , Andrea Parri , Will Deacon , Peter Zijlstra , Boqun Feng , Nicholas Piggin , David Howells , Jade Alglave , Luc Maranget , "Paul E. McKenney" , Akira Yokosawa , Daniel Lustig , Jonathan Corbet , Mauro Carvalho Chehab , "David S. Miller" , Rob Herring , Greg Kroah-Hartman , Jonathan Cameron , linux-arch@vger.kernel.org, linux-doc@vger.kernel.org Subject: [RFC v2 2/4] Documentation/locking/atomic: Introduce atomic-tests directory Date: Wed, 19 Feb 2020 14:26:25 +0800 Message-Id: <20200219062627.104736-3-boqun.feng@gmail.com> X-Mailer: git-send-email 2.25.0 In-Reply-To: <20200219062627.104736-1-boqun.feng@gmail.com> References: <20200219062627.104736-1-boqun.feng@gmail.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Although we have atomic_t.txt and its friends to describe the semantics of atomic APIs and lib/atomic64_test.c for build testing and testing in UP mode, the tests for our atomic APIs in real SMP mode are still missing. Since now we have the LKMM tool in kernel and litmus tests can be used to generate kernel modules for testing purpose with "klitmus" (a tool from the LKMM toolset), it makes sense to put a few typical litmus tests into kernel so that 1) they are the examples to describe the conceptual mode of the semantics of atomic APIs, and 2) they can be used to generate kernel test modules for anyone who is interested to test the atomic APIs implementation (in most cases, is the one who implements the APIs for a new arch) Therefore, introduce the atomic-tests directory for this purpose. The directory is maintained by the LKMM group to make sure the litmus tests are always aligned with our memory model. Signed-off-by: Boqun Feng --- Documentation/atomic-tests/README | 4 ++++ MAINTAINERS | 1 + 2 files changed, 5 insertions(+) create mode 100644 Documentation/atomic-tests/README diff --git a/Documentation/atomic-tests/README b/Documentation/atomic-tests/README new file mode 100644 index 000000000000..ae61201a4271 --- /dev/null +++ b/Documentation/atomic-tests/README @@ -0,0 +1,4 @@ +This directory contains litmus tests that are typical to describe the semantics +of our atomic APIs. For more information about how to "run" a litmus test or +how to generate a kernel test module based on a litmus test, please see +tools/memory-model/README. diff --git a/MAINTAINERS b/MAINTAINERS index ffc7d5712735..ebca5f6263bb 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -9718,6 +9718,7 @@ T: git git://git.kernel.org/pub/scm/linux/kernel/git/paulmck/linux-rcu.git dev F: tools/memory-model/ F: Documentation/atomic_bitops.txt F: Documentation/atomic_t.txt +F: Documentation/atomic-tests/ F: Documentation/core-api/atomic_ops.rst F: Documentation/core-api/refcount-vs-atomic.rst F: Documentation/memory-barriers.txt -- 2.25.0