From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752654AbdFTJDO (ORCPT ); Tue, 20 Jun 2017 05:03:14 -0400 Received: from terminus.zytor.com ([65.50.211.136]:58887 "EHLO terminus.zytor.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751174AbdFTJDK (ORCPT ); Tue, 20 Jun 2017 05:03:10 -0400 Date: Tue, 20 Jun 2017 02:00:56 -0700 From: tip-bot for Arnaldo Carvalho de Melo Message-ID: Cc: jolsa@kernel.org, adrian.hunter@intel.com, linux-kernel@vger.kernel.org, dsahern@gmail.com, wangnan0@huawei.com, hpa@zytor.com, mingo@kernel.org, namhyung@kernel.org, acme@redhat.com, tglx@linutronix.de Reply-To: wangnan0@huawei.com, hpa@zytor.com, linux-kernel@vger.kernel.org, dsahern@gmail.com, mingo@kernel.org, acme@redhat.com, namhyung@kernel.org, tglx@linutronix.de, adrian.hunter@intel.com, jolsa@kernel.org To: linux-tip-commits@vger.kernel.org Subject: [tip:perf/core] tools: Adopt __aligned from kernel sources Git-Commit-ID: 5c97cac63ac24c78c8126958a453774e49e706dd X-Mailer: tip-git-log-daemon Robot-ID: Robot-Unsubscribe: Contact to get blacklisted from these emails MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain; charset=UTF-8 Content-Disposition: inline Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Commit-ID: 5c97cac63ac24c78c8126958a453774e49e706dd Gitweb: http://git.kernel.org/tip/5c97cac63ac24c78c8126958a453774e49e706dd Author: Arnaldo Carvalho de Melo AuthorDate: Fri, 16 Jun 2017 11:39:15 -0300 Committer: Arnaldo Carvalho de Melo CommitDate: Mon, 19 Jun 2017 15:27:08 -0300 tools: Adopt __aligned from kernel sources To have a more compact way to ask the compiler to use a specific alignment, making tools/ look more like kernel source code. Cc: Adrian Hunter Cc: David Ahern Cc: Jiri Olsa Cc: Namhyung Kim Cc: Wang Nan Link: http://lkml.kernel.org/n/tip-8jiem6ubg9rlpbs7c2p900no@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo --- tools/include/linux/compiler-gcc.h | 1 + tools/perf/util/evlist.h | 3 ++- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/tools/include/linux/compiler-gcc.h b/tools/include/linux/compiler-gcc.h index 0f57a48..bd39b20 100644 --- a/tools/include/linux/compiler-gcc.h +++ b/tools/include/linux/compiler-gcc.h @@ -26,5 +26,6 @@ #define __noreturn __attribute__((noreturn)) +#define __aligned(x) __attribute__((aligned(x))) #define __printf(a, b) __attribute__((format(printf, a, b))) #define __scanf(a, b) __attribute__((format(scanf, a, b))) diff --git a/tools/perf/util/evlist.h b/tools/perf/util/evlist.h index 94cea43..8d601fb 100644 --- a/tools/perf/util/evlist.h +++ b/tools/perf/util/evlist.h @@ -1,6 +1,7 @@ #ifndef __PERF_EVLIST_H #define __PERF_EVLIST_H 1 +#include #include #include #include @@ -34,7 +35,7 @@ struct perf_mmap { refcount_t refcnt; u64 prev; struct auxtrace_mmap auxtrace_mmap; - char event_copy[PERF_SAMPLE_MAX_SIZE] __attribute__((aligned(8))); + char event_copy[PERF_SAMPLE_MAX_SIZE] __aligned(8); }; static inline size_t