Received: by 2002:a25:e74b:0:0:0:0:0 with SMTP id e72csp991852ybh; Tue, 21 Jul 2020 12:59:55 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxDIiXPT2I//hKsbwcLvlIlq2yMn2lRD6T3goKSWaWr8IOzOPzoHaEPkzUd+wGJrwQifCjD X-Received: by 2002:a17:906:8157:: with SMTP id z23mr28176098ejw.349.1595361594951; Tue, 21 Jul 2020 12:59:54 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1595361594; cv=none; d=google.com; s=arc-20160816; b=vFg+TgiHfkpRhxWAD2EM5mThQFvqeCbuhtwZeq5bcoeAbZdCtU0Fsz5aELXX7KfPrG GC8Fe0zj8YvC33BGIzUfmFpOaEDCbe2YSdnjyrTG0oXvyE1y82Br3iHXmwgGJnXwlYOW Qsa1VjE7OsJz6r4erPaXcJomt3zq2i+FcykK1IlnYZi/Bk6sfG3K2iX2d2vcYVDY7/Gf v43ClM0VRwS866S+J3oln8KUgVzp7qV5GS6rv3watZC49qhj+BtCdwPI6GqpKuWGscBd pAKhwSxTYjdnJH1hfhl71jsXkk3RVxcxGAGJzEpjlsaUaPxisccOKub7pgioAbIHGnAv g8MQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date :dkim-signature; bh=/zdUPjFpphNAwdj4beaJ8GxFg+sLiwzmnp5KQFJ69qw=; b=HhnTSBfh6yLvTs03c3Of1800QX3t1ZJAyo8PoJBJIln8Aq6PT24kYgx+jUD+4CAwen 9FOdJlBxJA+3wIgF3hC61/A16igvhz28gzwITF3o3mkMQRV8Ex73U86Kag5OihfmldER a0Pvbwd8FEz5OD7aaPvoReKKIrNrOwssWSSQyreMz/pQdzTyJFoy3ATEN542J3YYkyIm CWdkZ4FvEMMWjkWDi843fk5I/oQVNnH//5k51yF42yBcnE6lnPA/hMCVUF3IYqnKnaie qgXOssvZIob+AEIA0cKIqWlh+ykzrCVhP8z+Fe0o7aXE45aDkSyCOjDbN2TxNQoXQHOY nM8Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b="laRS/bbq"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id mb7si12866283ejb.316.2020.07.21.12.59.32; Tue, 21 Jul 2020 12:59:54 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b="laRS/bbq"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729928AbgGUT7W (ORCPT + 99 others); Tue, 21 Jul 2020 15:59:22 -0400 Received: from mail.kernel.org ([198.145.29.99]:43318 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726892AbgGUT7W (ORCPT ); Tue, 21 Jul 2020 15:59:22 -0400 Received: from quaco.ghostprotocols.net (unknown [179.97.37.151]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id D424A2072E; Tue, 21 Jul 2020 19:59:21 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1595361562; bh=gGb8g+UjwDX3j/bDtdfbUK7CDgRFPOiHWmMZoe62cyU=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=laRS/bbq7IgIVRlG0PhI2fEtI/3uizRIhXywei56/svMY0xMUoaerbVaRbi7GQPgU S9xMDWZqGlHaPe/Udeqw6g2IcEgKiRp+bFfKJZHZQn2izhkvmoq4icB0aCn9XyZ5Z9 z53z61S47BooFAMTBRAciOTaXN/8gAp6ml1ek8Zw= Received: by quaco.ghostprotocols.net (Postfix, from userid 1000) id C70C3404B1; Tue, 21 Jul 2020 16:59:19 -0300 (-03) Date: Tue, 21 Jul 2020 16:59:19 -0300 From: Arnaldo Carvalho de Melo To: Alexey Budankov Cc: Jiri Olsa , Namhyung Kim , Alexander Shishkin , Peter Zijlstra , Ingo Molnar , Andi Kleen , linux-kernel Subject: Re: [PATCH v12 03/15] tools/libperf: avoid counting of nonfilterable fdarray fds Message-ID: <20200721195919.GH77866@kernel.org> References: <8d91c3a0-3db4-0a7a-ae13-299adb444bd6@linux.intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-Url: http://acmel.wordpress.com Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Em Fri, Jul 17, 2020 at 10:00:15AM +0300, Alexey Budankov escreveu: > > Avoid counting of struct pollfd *entries objects with > fdarray_flag__nonfilterable flag by fdarray__filter(). > Nonfilterable objects are still processed if requested > revents have been signaled for them. Thanks, applied. - Arnaldo > Signed-off-by: Alexey Budankov > Acked-by: Jiri Olsa > Acked-by: Namhyung Kim > --- > tools/lib/api/fd/array.c | 3 ++- > 1 file changed, 2 insertions(+), 1 deletion(-) > > diff --git a/tools/lib/api/fd/array.c b/tools/lib/api/fd/array.c > index 01b3b89f9797..5e6cb9debe37 100644 > --- a/tools/lib/api/fd/array.c > +++ b/tools/lib/api/fd/array.c > @@ -109,7 +109,8 @@ int fdarray__filter(struct fdarray *fda, short revents, > continue; > } > > - ++nr; > + if (!(fda->priv[fd].flags & fdarray_flag__nonfilterable)) > + ++nr; > } > > return nr; > -- > 2.24.1 > > -- - Arnaldo