From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-13.0 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH, MAILING_LIST_MULTI,SIGNED_OFF_BY,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED, USER_AGENT_GIT autolearn=unavailable autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 36D8CC433E4 for ; Wed, 15 Jul 2020 02:07:29 +0000 (UTC) Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 01DB320663 for ; Wed, 15 Jul 2020 02:07:29 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="mMBk0HZ9"; dkim=fail reason="signature verification failed" (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b="pOWWp9Yn" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 01DB320663 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=linaro.org Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=merlin.20170209; h=Sender:Content-Transfer-Encoding: Content-Type:MIME-Version:Cc:List-Subscribe:List-Help:List-Post:List-Archive: List-Unsubscribe:List-Id:References:In-Reply-To:Message-Id:Date:Subject:To: From:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=Bt0Pi+7pIrIRcWMKMDyKxi9EJSQlzwo8kFtij0Zct4Q=; b=mMBk0HZ9TzPPoVkkBjFDPMAmOc ktJhQqE8q+k8+8KGMYujtAHNJHM01+KHlheCCkGS2wLtb3tr2USnuPtYi/2+dAeoDg8wJebrMsmQ4 kajQXIW3nDDpWtyNxNDo3l54nucpw5cfrJcmLuVa6+tooNV2TxoQ2ZeqjdG7z0T13vHMK5g/0xivk R4Txcwhz81m1z+qPK7+GXsoWKZhf0gcl1+/A0xGJpFVI+BHAwcCWxSzbfodVThU524D58qB7Yqsaj w37jekKlAyRyTiaoR/51xM1SO9NEa4mSzFVxaPnEUA9yEm8wSEMWksmR8ooCmKiUvURhP9e9R0PEo Q01hgMFA==; Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1jvWoO-0007Ye-Ax; Wed, 15 Jul 2020 02:06:20 +0000 Received: from mail-pj1-x1044.google.com ([2607:f8b0:4864:20::1044]) by merlin.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1jvWoL-0007Wx-0C for linux-arm-kernel@lists.infradead.org; Wed, 15 Jul 2020 02:06:18 +0000 Received: by mail-pj1-x1044.google.com with SMTP id t15so1265645pjq.5 for ; Tue, 14 Jul 2020 19:06:16 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=5uEgZcOvxySkXqr8EUPn06IShVdK3dXiQkAlG2OoJgw=; b=pOWWp9YnQGbRhp8vnvcjFzCjOY/Ptp60xa3w+pOU/QVau8l+iZKApRVWCKB3OwQiBz lnTthcfCxJWWgteowrvSvu9Ti0/yvZr7r2iOrdMZGCBtWv8Z64IB5X55LfjRyyv0LWwV ECtZ7d190zXrgGaiPuYqxOjtk+G1YIEMZvgUrNkmRus9DLuwT4FMnkNOrX5ZZdlCO4fo 9xU0aanlhWpSxHmnqv8Zuczc2G7bTv5vRNPZ5tVDm0CgGdkypgdzom7wh8oUlSfTRB5F VpHstdK1QuNugsk8R3KmLMcmmqqyYeVacr35ZR5SWwUrhtbmrWTEwu4T2LHA3/xL0iIW 59KA== 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; bh=5uEgZcOvxySkXqr8EUPn06IShVdK3dXiQkAlG2OoJgw=; b=Pp3sB9GOzII/ZviYHIsuSt+XOev8+5XUwf4GiEy8oKh8O71VJsSLvgOB9Br5moXd3S hLpns5DNiIfLvqKsZaypSADl8SlmQ8EHvMiLMozcPTZ+UWuyZvYvf3prtkyEviL5AHRf oVefIZo6mRLsrYWKMYSjqROrw1ioOy+fURc4swdI+WoXqn7V33AU4KtlXFZKXQSpF/dx kosf/q+gqx2X50t7ADmK+r14NHZGqpUbX6QuL4nLdVsPJiiqZ26DBgvl8L+LfKtqueLL BdbXzLEOBPbgVL467TIGEEuLDCXUXYohsjTMPUQo6daYneEAfKjXBuFcYIQfCNsAdM1+ seEw== X-Gm-Message-State: AOAM533YoLMoktlKVxdJz0u8VO5xX64rFqKVe9pNw3cHqvJSTpCNuEEr SoJjI5SbORAzLCoqYAYQ7b4ZOA== X-Google-Smtp-Source: ABdhPJwMXpKq4bmzp8Tj2k831gLgHkghRRnoLsBK25hBLPT1cNEMu++Q/+CeJ5hpYTHTn55V9DEsVQ== X-Received: by 2002:a17:90b:1c12:: with SMTP id oc18mr7615246pjb.160.1594778774962; Tue, 14 Jul 2020 19:06:14 -0700 (PDT) Received: from localhost ([2400:8904::f03c:91ff:fe8a:bbe4]) by smtp.gmail.com with ESMTPSA id c134sm369404pfc.115.2020.07.14.19.06.13 (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Tue, 14 Jul 2020 19:06:14 -0700 (PDT) From: Leo Yan To: Will Deacon , Mark Rutland , Peter Zijlstra , Ingo Molnar , Arnaldo Carvalho de Melo , Alexander Shishkin , Jiri Olsa , Namhyung Kim , Catalin Marinas , Thomas Gleixner , Paul Cercueil , "Ben Dooks (Codethink)" , "Ahmed S. Darwish" , Adrian Hunter , Kan Liang , linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org Subject: [PATCH v2 6/6] tools headers UAPI: Update tools's copy of linux/perf_event.h Date: Wed, 15 Jul 2020 10:05:12 +0800 Message-Id: <20200715020512.20991-7-leo.yan@linaro.org> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20200715020512.20991-1-leo.yan@linaro.org> References: <20200715020512.20991-1-leo.yan@linaro.org> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20200714_220617_114571_B7EAECF9 X-CRM114-Status: GOOD ( 16.77 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Leo Yan MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org To get the changes in the commit: "perf: Add perf_event_mmap_page::cap_user_time_short ABI" This update is a prerequisite to add support for short clock counters related ABI extension. Signed-off-by: Leo Yan --- tools/include/uapi/linux/perf_event.h | 23 ++++++++++++++++++++--- 1 file changed, 20 insertions(+), 3 deletions(-) diff --git a/tools/include/uapi/linux/perf_event.h b/tools/include/uapi/linux/perf_event.h index 7b2d6fc9e6ed..21a1edd08cbe 100644 --- a/tools/include/uapi/linux/perf_event.h +++ b/tools/include/uapi/linux/perf_event.h @@ -532,9 +532,10 @@ struct perf_event_mmap_page { cap_bit0_is_deprecated : 1, /* Always 1, signals that bit 0 is zero */ cap_user_rdpmc : 1, /* The RDPMC instruction can be used to read counts */ - cap_user_time : 1, /* The time_* fields are used */ + cap_user_time : 1, /* The time_{shift,mult,offset} fields are used */ cap_user_time_zero : 1, /* The time_zero field is used */ - cap_____res : 59; + cap_user_time_short : 1, /* the time_{cycle,mask} fields are used */ + cap_____res : 58; }; }; @@ -593,13 +594,29 @@ struct perf_event_mmap_page { * ((rem * time_mult) >> time_shift); */ __u64 time_zero; + __u32 size; /* Header size up to __reserved[] fields. */ + __u32 __reserved_1; + + /* + * If cap_usr_time_short, the hardware clock is less than 64bit wide + * and we must compute the 'cyc' value, as used by cap_usr_time, as: + * + * cyc = time_cycles + ((cyc - time_cycles) & time_mask) + * + * NOTE: this form is explicitly chosen such that cap_usr_time_short + * is a correction on top of cap_usr_time, and code that doesn't + * know about cap_usr_time_short still works under the assumption + * the counter doesn't wrap. + */ + __u64 time_cycles; + __u64 time_mask; /* * Hole for extension of the self monitor capabilities */ - __u8 __reserved[118*8+4]; /* align to 1k. */ + __u8 __reserved[116*8]; /* align to 1k. */ /* * Control data for the mmap() data buffer. -- 2.17.1 _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel