From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753319AbbDGTGf (ORCPT ); Tue, 7 Apr 2015 15:06:35 -0400 Received: from mail-ie0-f169.google.com ([209.85.223.169]:36166 "EHLO mail-ie0-f169.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752959AbbDGTGe (ORCPT ); Tue, 7 Apr 2015 15:06:34 -0400 Message-ID: <55242AB7.9040602@gmail.com> Date: Tue, 07 Apr 2015 13:06:31 -0600 From: David Ahern User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.10; rv:31.0) Gecko/20100101 Thunderbird/31.6.0 MIME-Version: 1.0 To: Arnaldo Carvalho de Melo , Ingo Molnar CC: linux-kernel@vger.kernel.org, Peter Zijlstra , "H. Peter Anvin" , Adrian Hunter , Andrew Morton , Jiri Olsa , John Stultz , Linus Torvalds , Stephane Eranian , Thomas Gleixner , Arnaldo Carvalho de Melo Subject: Re: [PATCH 15/16] perf record: Add clockid parameter References: <1428424862-30032-1-git-send-email-acme@kernel.org> <1428424862-30032-16-git-send-email-acme@kernel.org> In-Reply-To: <1428424862-30032-16-git-send-email-acme@kernel.org> Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org fails to compile on RHEL6/CentOS6/OL6 ... On 4/7/15 10:41 AM, Arnaldo Carvalho de Melo wrote: > +/* > + * Doesn't appear to have made it into userspace so define here if missing. > + */ > +#ifndef CLOCK_TAI > +#define CLOCK_TAI 11 > +#endif > + > +static const struct clockid_map clockids[] = { > + /* available for all events, NMI safe */ > + CLOCKID_MAP("monotonic", CLOCK_MONOTONIC), > + CLOCKID_MAP("monotonic_raw", CLOCK_MONOTONIC_RAW), > + > + /* available for some events */ > + CLOCKID_MAP("realtime", CLOCK_REALTIME), > + CLOCKID_MAP("boottime", CLOCK_BOOTTIME), > + CLOCKID_MAP("tai", CLOCK_TAI), > + > + /* available for the lazy */ > + CLOCKID_MAP("mono", CLOCK_MONOTONIC), > + CLOCKID_MAP("raw", CLOCK_MONOTONIC_RAW), > + CLOCKID_MAP("real", CLOCK_REALTIME), > + CLOCKID_MAP("boot", CLOCK_BOOTTIME), > + builtin-record.c:738: error: ‘CLOCK_BOOTTIME’ undeclared here (not in a function) make[2]: *** [/tmp/perf/builtin-record.o] Error 1 make[1]: *** [/tmp/perf/perf-in.o] Error 2 make: *** [all] Error 2 Need this similar to CLOCK_TAI: diff --git a/tools/perf/builtin-record.c b/tools/perf/builtin-record.c index f32edba4f84a..dbf1d508a1c0 100644 --- a/tools/perf/builtin-record.c +++ b/tools/perf/builtin-record.c @@ -728,6 +728,10 @@ struct clockid_map { #define CLOCK_TAI 11 #endif +#ifndef CLOCK_BOOTTIME +#define CLOCK_BOOTTIME 7 +#endif + static const struct clockid_map clockids[] = { /* available for all events, NMI safe */ CLOCKID_MAP("monotonic", CLOCK_MONOTONIC), It would be best to add this delta before Ingo pulls it in to maintain git-bisect. David