Received: by 2002:a5b:505:0:0:0:0:0 with SMTP id o5csp4413792ybp; Mon, 7 Oct 2019 08:08:09 -0700 (PDT) X-Google-Smtp-Source: APXvYqyfIAy6MxUYQK/ROo9y0nmMHOHrgWZDFT5lIWokp2V9layr0LWMWU4nTrIJvqkgFHg/RTh/ X-Received: by 2002:a17:906:c282:: with SMTP id r2mr336691ejz.207.1570460889375; Mon, 07 Oct 2019 08:08:09 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1570460889; cv=none; d=google.com; s=arc-20160816; b=H1KLTxixlsj2rS7MYWdUY1ZFAGIGm0KaNDhtPc3KJeic4jL01SgbTA5yDNfptxkFWi EfyvP92OAcksdnih7SZIR3B8DPAh18Sp2yxX2o8vM4ddp+tanZnxjTsBGrplqlsuzyTA TZUIoUFhUxK723q6qgsuXno2t2+PcZDswLoeuYRF2IuS3mdKG0oMFwYXUgrO/RR7RfpG CtjOx/tkE0/L1u+h5lAuo61DoVyJxe3YyVhY5Eg91c4SYldFykvXBEo4aJgshgLyQqYO T7d6TlJXFm4dKedtLyrCGBD/ZOWNHXPfDp96LnUYBzYYspMCb7RdmAhhbFa1FptPAaRw SFWA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:openpgp:from:references:cc:to:subject; bh=2o0eUn9XQmaO3vyP+98zE6rGqN0+sCYt7aS5tzY/kSE=; b=ubKvRmTqeVNthCKEcbR1Q+0eA6cEpDeCb8Uu5zfri6pFFBYtsFbKlEAfE8Ci2co8SZ XvR4vupmhGbv5MLb+m/HR1R/2Ad+0uLHrA1ymBsNwcSZe7Mops9XEAOYkFJlFTAWtpfp 08+8PMWFwqSQjK0669vhL27QKsNp6zZF46ezpEKhLynG+G1RxNuZxAp7LmmcvWU3lDBu WLKa84aIj4//Teu9oim4l1uFYwtp+46wbQnh2EbjxuO1W7zPOWWmnN0fGrKk/KPMPon5 syup2xBYKsXufWexDk4ijFDw/VqxeF3LwMtrJBsgaD2IsvYvyfz/85kYLt0vktI8/77F pB4A== 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id p20si6683038eju.109.2019.10.07.08.07.44; Mon, 07 Oct 2019 08:08:09 -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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728289AbfJGPFV (ORCPT + 99 others); Mon, 7 Oct 2019 11:05:21 -0400 Received: from mx1.redhat.com ([209.132.183.28]:60248 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728238AbfJGPFU (ORCPT ); Mon, 7 Oct 2019 11:05:20 -0400 Received: from mail-wm1-f72.google.com (mail-wm1-f72.google.com [209.85.128.72]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 47800CA377 for ; Mon, 7 Oct 2019 15:05:20 +0000 (UTC) Received: by mail-wm1-f72.google.com with SMTP id 190so6342285wme.4 for ; Mon, 07 Oct 2019 08:05:20 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:cc:references:from:openpgp:message-id :date:user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=2o0eUn9XQmaO3vyP+98zE6rGqN0+sCYt7aS5tzY/kSE=; b=Bh4Bbi8GX8MviYme1KjyrI3XvmgRijm7s5lbPNWAhTu3HmzHEgnj2iUiVnnzKQI0DG 1rzhV7rh0pAAA2Stl6Pp1lUCDRe3qgVlsCzVcrAfjWpWPjq8pgGNpo9Pxu7As02zWGEk T3yHZVQyNS7arNjSbL5eoPfH4l8QGSDvT/QkwfKxxOqmWjSDipwy4TC9C8L9HtMNzFdG TF6lrRqFm1MpLK+Knv9lEQc1gJwMPDDTIz5eL1VaTpXl11dnCNWXTR2DHIyedessxGSS d3ixourOfB+8GfF7bnHhjcq4Fa7aW/zbASCKGZ9/2PVL+ZCECksbnO4k8gfTsG4+8B0j av8Q== X-Gm-Message-State: APjAAAXu+DSSgx3IQgBPtGa9mPFMeb+bTyWlvaZcCC9tPrz7RnU99rIm IPhDTSBCmOEq91hn4lToa0HDFGwb7pymuITJNTx+KX3Kiiz+fj5uemwkvz8VcIoZB+TwFhFEztw 1v0nu9vry/6iRL0+slzGGH+8/ X-Received: by 2002:a05:600c:2219:: with SMTP id z25mr20024674wml.109.1570460718619; Mon, 07 Oct 2019 08:05:18 -0700 (PDT) X-Received: by 2002:a05:600c:2219:: with SMTP id z25mr20024634wml.109.1570460718321; Mon, 07 Oct 2019 08:05:18 -0700 (PDT) Received: from ?IPv6:2001:b07:6468:f312:9dd9:ce92:89b5:d1f2? ([2001:b07:6468:f312:9dd9:ce92:89b5:d1f2]) by smtp.gmail.com with ESMTPSA id r20sm30166993wrg.61.2019.10.07.08.05.15 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Mon, 07 Oct 2019 08:05:17 -0700 (PDT) Subject: Re: [PATCH 1/3] perf/core: Provide a kernel-internal interface to recalibrate event period To: "Liang, Kan" , Like Xu , kvm@vger.kernel.org, rkrcmar@redhat.com, sean.j.christopherson@intel.com, vkuznets@redhat.com, peterz@infradead.org, Jim Mattson Cc: Ingo Molnar , Arnaldo Carvalho de Melo , ak@linux.intel.com, wei.w.wang@intel.com, kan.liang@intel.com, like.xu@intel.com, ehankland@google.com, arbel.moshe@oracle.com, linux-kernel@vger.kernel.org References: <20190930072257.43352-1-like.xu@linux.intel.com> <20190930072257.43352-2-like.xu@linux.intel.com> <6439df1c-df4a-9820-edb2-0ff41b581d37@redhat.com> From: Paolo Bonzini Openpgp: preference=signencrypt Message-ID: <4a2c164f-4a83-436b-c177-0d641d6be529@redhat.com> Date: Mon, 7 Oct 2019 17:05:19 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.8.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 07/10/19 15:25, Liang, Kan wrote: > >> On 30/09/19 09:22, Like Xu wrote: >>> -static int perf_event_period(struct perf_event *event, u64 __user *arg) >>> +static int _perf_event_period(struct perf_event *event, u64 value) >> >> __perf_event_period or perf_event_period_locked would be more consistent >> with other code in Linux. >> > > But that will be not consistent with current perf code. For example, > _perf_event_enable(), _perf_event_disable(), _perf_event_reset() and > _perf_event_refresh(). > Currently, The function name without '_' prefix is the one exported and > with lock. The function name with '_' prefix is the main body. > > If we have to use the "_locked" or "__", I think we'd better change the > name for other functions as well. Oh, sorry I missed that. Paolo