From patchwork Mon Oct 22 10:59:44 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Miguel Ojeda X-Patchwork-Id: 10651921 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 568E514E5 for ; Mon, 22 Oct 2018 10:59:54 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 2DCC72890F for ; Mon, 22 Oct 2018 10:59:54 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 1BC532890E; Mon, 22 Oct 2018 10:59:54 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.0 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FROM,FSL_HELO_FAKE,MAILING_LIST_MULTI, RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 8668E2890E for ; Mon, 22 Oct 2018 10:59:53 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728694AbeJVTR5 (ORCPT ); Mon, 22 Oct 2018 15:17:57 -0400 Received: from mail-wr1-f66.google.com ([209.85.221.66]:42936 "EHLO mail-wr1-f66.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728674AbeJVTR5 (ORCPT ); Mon, 22 Oct 2018 15:17:57 -0400 Received: by mail-wr1-f66.google.com with SMTP id f8-v6so4932614wro.9; Mon, 22 Oct 2018 03:59:51 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=date:from:to:cc:subject:message-id:mime-version:content-disposition :user-agent; bh=DQ/BGw3c1pgniBHBs7s426UMJFj91Fj2ea87hVs35No=; b=ewbkJ+DPMdTuWByvcEmKMsj0NUnsauVtFZXwQ+i+Ax8N5v3aPMw8LB/wBsSQQz87EK Qp7kqi15qLKS44khYwRIMf7E6tCjHxTY6CPuiT+Lh6x9d/tUiDQe1QGKlo5nERUdbS7J Z41cUv9nFVnD0cSyhE2wdde2h4EqgefbMGrthynKurL+SZy9iROyytMxD4EtegSv48FC MyVzn3MO86M0cXbva83ZVm3xL5uLcGnrhVQtqYmctCPQdawz9n6+70pywpnssfimgDUM GnM6GlpsTO2hBXwPywJLedMeQctwtRr1tD+DTOSonDrR+riU8yzHlP9jCNLz66dhyDqy 4Ueg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:mime-version :content-disposition:user-agent; bh=DQ/BGw3c1pgniBHBs7s426UMJFj91Fj2ea87hVs35No=; b=diQeZfZ5WklQDP+YTo6+z9d9lK62k0EHBtAPmmkGlH3Ht+KLFted5ShQAoZhg0Ubsu ZrJ37s7taZPhuv7RYqnHWDvmLIh8EkZTFoHEVjwkyBNEI7CrUbWk0Y7VmX+CaywO5ZWh MCtXOpKuTgruTsRnjyOc0bsKMuyeuJDJGpGIUR8oVRoZ79Pi2UvJ1NyNw6jUT4VRUQQp OQIdeuWIVwghSib7Re+bYXQNcg0q1LfavxrLK1Hd418Du25i+tIWo1dsvo0vMjk3Pdf0 8sIDnvBQo0o7m10xbuFq/n3Ov7ZDcExR4nYR4gz3xhcUj3FwROzDE6GLV44zXXAyOtfL Rl3Q== X-Gm-Message-State: AGRZ1gKevsjUrmSB4Mx0fDnTD3OL+aAdqawClqsHbYx322m2XpWaSUSo VCJd/4WGRfz9hKouJpJUCA8= X-Google-Smtp-Source: AJdET5ecZ2d3QUOfrNKZOxzxgGjoBNFCL5vJDj+D6FmkyaUyjvegaBPQrvH76BQ3H4E1hDs0rKnqBw== X-Received: by 2002:a5d:6944:: with SMTP id r4-v6mr8803486wrw.197.1540205990218; Mon, 22 Oct 2018 03:59:50 -0700 (PDT) Received: from gmail.com (62.83.35.8.dyn.user.ono.com. [62.83.35.8]) by smtp.gmail.com with ESMTPSA id v1-v6sm28651553wrd.24.2018.10.22.03.59.47 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Mon, 22 Oct 2018 03:59:49 -0700 (PDT) Date: Mon, 22 Oct 2018 12:59:44 +0200 From: Miguel Ojeda To: Linus Torvalds Cc: Dan Carpenter , Andreas Dilger , Masahiro Yamada , Michal Marek , Steven Rostedt , Mauro Carvalho Chehab , Olof Johansson , Konstantin Ryabitsev , "David S. Miller" , Andrey Ryabinin , Kees Cook , Thomas Gleixner , Ingo Molnar , Paul Lawrence , Sandipan Das , Andrey Konovalov , David Woodhouse , Will Deacon , Philippe Ombredanne , Paul Burton , David Rientjes , Willy Tarreau , Martin Sebor , Christopher Li , Jonathan Corbet , Theodore Ts'o , Geert Uytterhoeven , Rasmus Villemoes , Joe Perches , Arnd Bergmann , Dominique Martinet , Stefan Agner , Luc Van Oostenryck , Nick Desaulniers , Andrew Morton , Greg Kroah-Hartman , Linus Torvalds , linux-doc@vger.kernel.org, linux-ext4@vger.kernel.org, linux-sparse@vger.kernel.org, linux-kbuild@vger.kernel.org Subject: [GIT PULL] Compiler Attributes for v4.20-rc1 Message-ID: <20181022105944.GA1411@gmail.com> MIME-Version: 1.0 Content-Disposition: inline User-Agent: elm/2 Sender: linux-sparse-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-sparse@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Hi Linus, Here it is the Compiler Attributes series/tree, which tries to disentangle the include/linux/compiler*.h headers and bring them up to date. The patches have been in linux-next for a while, *except* the last two from Nick which came a bit later. Since AFAIU there will be no linux-next this week, I included them here; but let me know if you prefer to take them out. You may see merge conflicts from a few other trees, from what we have seen in linux-next. I am not sure if you followed this, so please let me know if there is anything you don't agree with. And welcome back! Cheers, Miguel The following changes since commit 17b57b1883c1285f3d0dc2266e8f79286a7bef38: Linux 4.19-rc6 (2018-09-30 07:15:35 -0700) are available in the Git repository at: https://github.com/ojeda/linux.git tags/compiler-attributes-for-linus-4.20-rc1 for you to fetch changes up to 1ff2fea5e30ca15752777441ecb64a169fe22e9e: compiler-gcc: remove comment about gcc 4.5 from unreachable() (2018-10-19 08:47:30 +0200) ---------------------------------------------------------------- The Compiler Attributes series This is an effort to disentangle the include/linux/compiler*.h headers and bring them up to date. The main idea behind the series is to use feature checking macros (i.e. __has_attribute) instead of compiler version checks (e.g. GCC_VERSION), which are compiler-agnostic (so they can be shared, reducing the size of compiler-specific headers) and version-agnostic. Other related improvements have been performed in the headers as well, which on top of the use of __has_attribute it has amounted to a significant simplification of these headers (e.g. GCC_VERSION is now only guarding a few non-attribute macros). This series should also help the efforts to support compiling the kernel with clang and icc. A fair amount of documentation and comments have also been added, clarified or removed; and the headers are now more readable, which should help kernel developers in general. The series was triggered due to the move to gcc >= 4.6. In turn, this series has also triggered Sparse to gain the ability to recognize __has_attribute on its own. Finally, the __nonstring variable attribute series has been also applied on top; plus two related patches from Nick Desaulniers for unreachable() that came a bit afterwards. ---------------------------------------------------------------- Miguel Ojeda (15): Compiler Attributes: remove unused attributes Compiler Attributes: always use the extra-underscores syntax Compiler Attributes: remove unneeded tests Compiler Attributes: homogenize __must_be_array Compiler Attributes: remove unneeded sparse (__CHECKER__) tests Compiler Attributes: add missing SPDX ID in compiler_types.h Compiler Attributes: use feature checks instead of version checks Compiler Attributes: KENTRY used twice the "used" attribute Compiler Attributes: remove uses of __attribute__ from compiler.h Compiler Attributes: add Doc/process/programming-language.rst Compiler Attributes: add MAINTAINERS entry Compiler Attributes: add support for __nonstring (gcc >= 8) Compiler Attributes: enable -Wstringop-truncation on W=1 (gcc >= 8) Compiler Attributes: auxdisplay: panel: use __nonstring Compiler Attributes: ext4: remove local __nonstring definition ndesaulniers@google.com (2): compiler.h: update definition of unreachable() compiler-gcc: remove comment about gcc 4.5 from unreachable() Documentation/process/index.rst | 1 + Documentation/process/programming-language.rst | 45 +++++ MAINTAINERS | 5 + drivers/auxdisplay/panel.c | 7 +- fs/ext4/ext4.h | 9 - include/linux/compiler-clang.h | 5 - include/linux/compiler-gcc.h | 74 +------ include/linux/compiler-intel.h | 9 - include/linux/compiler.h | 24 +-- include/linux/compiler_attributes.h | 258 +++++++++++++++++++++++++ include/linux/compiler_types.h | 101 ++-------- scripts/Makefile.extrawarn | 1 + 12 files changed, 345 insertions(+), 194 deletions(-) create mode 100644 Documentation/process/programming-language.rst create mode 100644 include/linux/compiler_attributes.h Signed-off-by: Martin Schwidefsky Acked-by: Steven Rostedt (VMware)