From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id AC63FA09E4; Fri, 29 Jan 2021 12:27:43 +0100 (CET) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 98DE5240134; Fri, 29 Jan 2021 12:27:43 +0100 (CET) Received: from out1-smtp.messagingengine.com (out1-smtp.messagingengine.com [66.111.4.25]) by mails.dpdk.org (Postfix) with ESMTP id C5F2D40694 for ; Fri, 29 Jan 2021 12:27:42 +0100 (CET) Received: from compute2.internal (compute2.nyi.internal [10.202.2.42]) by mailout.nyi.internal (Postfix) with ESMTP id B9F985C01D8; Fri, 29 Jan 2021 06:27:40 -0500 (EST) Received: from mailfrontend2 ([10.202.2.163]) by compute2.internal (MEProxy); Fri, 29 Jan 2021 06:27:40 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=monjalon.net; h= from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding:content-type; s=fm3; bh= ARJiHPVXOgN2VKBqxIka35E2sOB2UWNc7SCelA6NTD8=; b=x6VX1Dsl7E/d6ln2 bZ5FUP5HPxV744l0xn8eKq4RcTMhNETpSnXUj5tMV+jtcAJLDFVGKo5F7n+aacU+ gWED+hZQyq9mn6ZIRORho64fYhAjrSpWViKy2N1PHQoHWe0Jv6YStpH+bGgxLI+6 eZELr3UV51N85Xd0Dw2rB/jvKjURNo+5vYHhrdSOz8JJHKd4xIzdsXrbRz7v0HVh yhYCsQPXjmnpktYrkvUd7Nx5ieam4l04tZLlM25KKBzm8VVXv4s4D+LbZI0S2Ib9 gPtlFgaCYjEkIP0+h/h1JPPElplxmMRfZlNjEGTx16ufAVH4iPuV1EMkeTleIsYt YBT/ZA== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-transfer-encoding:content-type :date:from:in-reply-to:message-id:mime-version:references :subject:to:x-me-proxy:x-me-proxy:x-me-sender:x-me-sender :x-sasl-enc; s=fm1; bh=ARJiHPVXOgN2VKBqxIka35E2sOB2UWNc7SCelA6NT D8=; b=en+2sXh7LUXQkCvf9PF3KSRDegT1S8E/F/seuq8Dq+r3cB9bzypQKUf0l NvdjUMlIPkaldH9TTRlFI8QW2qkvUmC3LtgbNgwEsLtt8wjDxVvBKSncw6/THJX0 RfgxiVT3WFY7cSQsW2ePBoDUWv2OupKNknyW4COGWFhq2TzhY5uwDAoRdeVsGsFj 3yyHjOTleZd7RAGW3eTLcJ2Dt1RVKCV8G9gPmMXK10cngutQyLSSzWpyWQOycLM2 Do3wMdTXsSZd8+THmhCrF393S8OmSqPrAFOYowfjniX3BN+9C4vDX+RIACVfJWwY nnTkgLMb5A28oe7Z1ahn+ioSr4O3Q== X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeduledrfedvgddvkecutefuodetggdotefrodftvf curfhrohhfihhlvgemucfhrghsthforghilhdpqfgfvfdpuffrtefokffrpgfnqfghnecu uegrihhlohhuthemuceftddtnecusecvtfgvtghiphhivghnthhsucdlqddutddtmdenuc fjughrpefhvffufffkjghfggfgtgesthfuredttddtvdenucfhrhhomhepvfhhohhmrghs ucfoohhnjhgrlhhonhcuoehthhhomhgrshesmhhonhhjrghlohhnrdhnvghtqeenucggtf frrghtthgvrhhnpedugefgvdefudfftdefgeelgffhueekgfffhfeujedtteeutdejueei iedvffegheenucfkphepjeejrddvtdehrdduhedvrdejleenucevlhhushhtvghrufhiii gvpedunecurfgrrhgrmhepmhgrihhlfhhrohhmpehthhhomhgrshesmhhonhhjrghlohhn rdhnvght X-ME-Proxy: Received: from xps.localnet (79.152.205.77.rev.sfr.net [77.205.152.79]) by mail.messagingengine.com (Postfix) with ESMTPA id C1D361080057; Fri, 29 Jan 2021 06:27:39 -0500 (EST) From: Thomas Monjalon To: Anatoly Burakov Cc: dev@dpdk.org Date: Fri, 29 Jan 2021 12:27:36 +0100 Message-ID: <2185319.EHbmnTtgEt@thomas> In-Reply-To: References: MIME-Version: 1.0 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" Subject: Re: [dpdk-dev] [PATCH v20 2/4] eal: improve comments around power monitoring API X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" 22/01/2021 18:12, Anatoly Burakov: > Currently, the API documentation is ambiguous as to what happens when > certain conditions are met. Document the behavior explicitly, as well as > fix some typos and outdated comments. > > Fixes: 6a17919b0e2a ("eal: change power intrinsics API") > > Signed-off-by: Anatoly Burakov > --- > * Monitor specific address for changes. This will cause the CPU to enter an > * architecture-defined optimized power state until either the specified > * memory address is written to, a certain TSC timestamp is reached, or other > * reasons cause the CPU to wake up. > * > - * Additionally, an `expected` 64-bit value and 64-bit mask are provided. If > - * mask is non-zero, the current value pointed to by the `p` pointer will be > - * checked against the expected value, and if they match, the entering of > - * optimized power state may be aborted. > + * Additionally, an expected value (`pmc->val`), mask (`pmc->mask`), and data > + * size (`pmc->size`) are provided in the `pmc` power monitoring condition. If > + * the mask is non-zero, the current value pointed to by the `pmc->addr` pointer > + * will be read and compared against the expected value, and if they match, the > + * entering of optimized power state will be aborted. This is intended to > + * prevent the CPU from entering optimized power state and waiting on a write > + * that has already happened by the time this API is called. I think that's a lot better. Thank you. Acked-by: Thomas Monjalon