From patchwork Thu Jul 26 08:13:24 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arnd Bergmann X-Patchwork-Id: 142943 Delivered-To: patch@linaro.org Received: by 2002:a2e:9754:0:0:0:0:0 with SMTP id f20-v6csp173629ljj; Thu, 26 Jul 2018 01:15:08 -0700 (PDT) X-Google-Smtp-Source: AAOMgpfsA+p2/3PvbW0byrESATcY/52DYMCqc12Oipa7Ags2NHnJoPySJAUZmbl8euX4eqHiwunu X-Received: by 2002:a65:5cc5:: with SMTP id b5-v6mr935811pgt.425.1532592908667; Thu, 26 Jul 2018 01:15:08 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1532592908; cv=none; d=google.com; s=arc-20160816; b=JqEAvFpV+4lDC0umXNtCLsnNYCvDgboVrfLC6bmPgOlEBm7biHo3xV+i0IFQAeGKA3 nqFyBe9d+cc5LlCW5tabVh/bbn3godmfMqGxwzmDAnvJkjcBa1z0JgsxseU6XzSrjEWr KEPTJoz52MYaCGiw96Gimf9Ikoja6jkCikPEcDUG6uHh6UsWpVE5/TdACeWNIi5DvMtB 6Qt1WCREIa+nu7TBVzmCh1w2rTvSyyvc8YhKebCifniXAxee+4kkR2X73HJncER9o8SL 9brPD0DzsogPCsaTZOrTLmxIk2nHlzYPiGj5/vZZMC56n/QQj6YU359sdNM2asnVLast O3VA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:arc-authentication-results; bh=l+rxQjkoaEx2iTvZt1DQ1938KGT7Wr5tQRzJ4XmVVzE=; b=VjTaVY6tvTOz/GEcBAnK/mWu4SURNH6CWa73v7WWfQw2h6eaqxfB1fMNVEPl3lRq4J TAskiOEQoQV9yHFGIQl4lJcI8rxzAFdPbT2e+oF+2P5EzII9YMiSqml5fZ36wIKkzUgS 4lREUWOg9yUSnYwVKJqhsfXambEIYD9OhGbevNGkiEmzTA8kP60OQ+Y6K8Jrbdv6TkO2 eupkNaL8EPF0hTnLseUnt3CXjziJdZuiR7oGOfmqIzoQ+xCT3yyN+rydW6ROOWnwDSyZ mmS6DbUheu+VkweFX6XlLErlljNYuKElG6dZIDEejkF5NSQy3wCSmVlNqwrf0m3XhElH Hk8w== ARC-Authentication-Results: i=1; mx.google.com; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id o23-v6si808834pgm.170.2018.07.26.01.15.08; Thu, 26 Jul 2018 01:15:08 -0700 (PDT) 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; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729227AbeGZJar (ORCPT + 31 others); Thu, 26 Jul 2018 05:30:47 -0400 Received: from mout.kundenserver.de ([212.227.17.10]:60869 "EHLO mout.kundenserver.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728807AbeGZJar (ORCPT ); Thu, 26 Jul 2018 05:30:47 -0400 Received: from wuerfel.lan ([109.193.40.16]) by mrelayeu.kundenserver.de (mreue105 [212.227.15.145]) with ESMTPA (Nemesis) id 0Lx7s1-1g27Ml2ctV-016hjM; Thu, 26 Jul 2018 10:14:46 +0200 From: Arnd Bergmann To: stable@vger.kernel.org, Michal Marek Cc: gregkh@linuxfoundation.org, Arnd Bergmann , Daniel Borkmann , linux-kbuild@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH] [stable 4.4] turn off -Wattribute-alias Date: Thu, 26 Jul 2018 10:13:24 +0200 Message-Id: <20180726081358.3829157-3-arnd@arndb.de> X-Mailer: git-send-email 2.18.0 In-Reply-To: <20180726081358.3829157-1-arnd@arndb.de> References: <20180726081358.3829157-1-arnd@arndb.de> X-Provags-ID: V03:K1:GihAiSmE8BnNsDQw6v3tzy9UyBR1tQ3B1YBbajITLQOYOObhYz1 4QSBxBUTuN3YulbopGq08LbM0SQlY1DMuSPsAixqoD5O9Ybh8KZp0hS/2GJ/VticnvZc7z3 cOHMMmUJryqgzB9eRyQJJk9rylTjB29Pwk3xTPIsgos4sMv3oG363Isb5RjQn2mITh6kOWR FSdhPuAY6Bp3unR7+BSGg== X-UI-Out-Filterresults: notjunk:1; V01:K0:gOUurGlAMi4=:PVZ2qdz1z2WbcKJsnnuCan GmDUeeRNaJL/lqHR5Ihvp3kxgF3+niHVjOUGux9ab4Rz9gevRKfeijcIw3MUobj5PRC2WYiuA GhFNo6ot7yWoIjBLyvxBaxN2xL9EznJJd/lfloGqreoyuxU+jWRBLiy8A0PyOChBzc+S0d5HQ yEgEz2esRE7k/l7R/s4MZnnX6O+068TDBXZLileyFcDbsTMIOwT7Vma1MK7kQ3rfwLJgHu8wQ ++WNUFKIFNm8YALDhu7AafDhFlIyp6qfCwy7fRG3jJPVyrgkEoO27xFxD22i9WCXJDPpjiATR RBA2OkCWpUGkx3u7zJgCGM8qJNvAwvvbTBwuK+Z/USJWHvKZ6qAMJNsODqdJ4lVl0nDYpG7o3 bJx5FtsysJouXxok+xUUt1/FLsZsJyn50xLuSKIhw89QibKUQMD+lIoJxh2oQrGH/gSfNYcvN C6qBb1KCC9XscqavRmed1/Dtm7owR79ABQA9o0KMj/GB1jGnlo6+4HWVqYH3am5/F+zTB9V4X GChY0c4LI+V1AZKqlftCP4gzW5acax4qgkBrYMXFrGvks+KSWH2g+IsjvwKrAHUNV1NaqBlEK 9WwQ7aassc+qFq+x1izpPQiZXDf2Lw2wpT0iqbRD1vYkbsOpDgytZYm3l4KVvvKiEMLMZNNqz geDFwZSKtyZc+74eCMOUHWQx+nRR5XcsSEjcROjXN18R+EF4myFgx5iYLeAHIFd2rgHM= Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Starting with gcc-8.1, we get a warning about all system call definitions, which use an alias between functions with incompatible prototypes, e.g.: In file included from ../mm/process_vm_access.c:19: ../include/linux/syscalls.h:211:18: warning: 'sys_process_vm_readv' alias between functions of incompatible types 'long int(pid_t, const struct iovec *, long unsigned int, const struct iovec *, long unsigned int, long unsigned int)' {aka 'long int(int, const struct iovec *, long unsigned int, const struct iovec *, long unsigned int, long unsigned int)'} and 'long int(long int, long int, long int, long int, long int, long int)' [-Wattribute-alias] asmlinkage long sys##name(__MAP(x,__SC_DECL,__VA_ARGS__)) \ ^~~ ../include/linux/syscalls.h:207:2: note: in expansion of macro '__SYSCALL_DEFINEx' __SYSCALL_DEFINEx(x, sname, __VA_ARGS__) ^~~~~~~~~~~~~~~~~ ../include/linux/syscalls.h:201:36: note: in expansion of macro 'SYSCALL_DEFINEx' #define SYSCALL_DEFINE6(name, ...) SYSCALL_DEFINEx(6, _##name, __VA_ARGS__) ^~~~~~~~~~~~~~~ ../mm/process_vm_access.c:300:1: note: in expansion of macro 'SYSCALL_DEFINE6' SYSCALL_DEFINE6(process_vm_readv, pid_t, pid, const struct iovec __user *, lvec, ^~~~~~~~~~~~~~~ ../include/linux/syscalls.h:215:18: note: aliased declaration here asmlinkage long SyS##name(__MAP(x,__SC_LONG,__VA_ARGS__)) \ ^~~ ../include/linux/syscalls.h:207:2: note: in expansion of macro '__SYSCALL_DEFINEx' __SYSCALL_DEFINEx(x, sname, __VA_ARGS__) ^~~~~~~~~~~~~~~~~ ../include/linux/syscalls.h:201:36: note: in expansion of macro 'SYSCALL_DEFINEx' #define SYSCALL_DEFINE6(name, ...) SYSCALL_DEFINEx(6, _##name, __VA_ARGS__) ^~~~~~~~~~~~~~~ ../mm/process_vm_access.c:300:1: note: in expansion of macro 'SYSCALL_DEFINE6' SYSCALL_DEFINE6(process_vm_readv, pid_t, pid, const struct iovec __user *, lvec, This is really noisy and does not indicate a real problem. In the latest mainline kernel, this was addressed by commit bee20031772a ("disable -Wattribute-alias warning for SYSCALL_DEFINEx()"), which seems too invasive to backport. This takes a much simpler approach and just disables the warning across the kernel. Signed-off-by: Arnd Bergmann --- Makefile | 1 + 1 file changed, 1 insertion(+) -- 2.18.0 diff --git a/Makefile b/Makefile index 54690fee0485..4812b35df210 100644 --- a/Makefile +++ b/Makefile @@ -624,6 +624,7 @@ KBUILD_CFLAGS += $(call cc-disable-warning,frame-address,) KBUILD_CFLAGS += $(call cc-disable-warning, format-truncation) KBUILD_CFLAGS += $(call cc-disable-warning, format-overflow) KBUILD_CFLAGS += $(call cc-disable-warning, int-in-bool-context) +KBUILD_CFLAGS += $(call cc-disable-warning, attribute-alias) ifdef CONFIG_CC_OPTIMIZE_FOR_SIZE KBUILD_CFLAGS += -Os