From patchwork Tue Nov 10 15:36:00 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ivan Khoronzhuk X-Patchwork-Id: 56339 Delivered-To: patch@linaro.org Received: by 10.112.155.196 with SMTP id vy4csp841919lbb; Tue, 10 Nov 2015 07:40:37 -0800 (PST) X-Received: by 10.107.44.210 with SMTP id s201mr5305038ios.62.1447170035638; Tue, 10 Nov 2015 07:40:35 -0800 (PST) Return-Path: Received: from lists.linaro.org (lists.linaro.org. [54.225.227.206]) by mx.google.com with ESMTP id c18si5431052igr.66.2015.11.10.07.40.35; Tue, 10 Nov 2015 07:40:35 -0800 (PST) Received-SPF: pass (google.com: domain of lng-odp-bounces@lists.linaro.org designates 54.225.227.206 as permitted sender) client-ip=54.225.227.206; Authentication-Results: mx.google.com; spf=pass (google.com: domain of lng-odp-bounces@lists.linaro.org designates 54.225.227.206 as permitted sender) smtp.mailfrom=lng-odp-bounces@lists.linaro.org; dkim=neutral (body hash did not verify) header.i=@linaro_org.20150623.gappssmtp.com Received: by lists.linaro.org (Postfix, from userid 109) id 0177761952; Tue, 10 Nov 2015 15:40:34 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on ip-10-142-244-252 X-Spam-Level: X-Spam-Status: No, score=-2.5 required=5.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_LOW, RCVD_IN_MSPIKE_H3, RCVD_IN_MSPIKE_WL, T_DKIM_INVALID, URIBL_BLOCKED autolearn=disabled version=3.4.0 Received: from [127.0.0.1] (localhost [127.0.0.1]) by lists.linaro.org (Postfix) with ESMTP id ECCAE61D2B; Tue, 10 Nov 2015 15:38:23 +0000 (UTC) X-Original-To: lng-odp@lists.linaro.org Delivered-To: lng-odp@lists.linaro.org Received: by lists.linaro.org (Postfix, from userid 109) id 6DE3561815; Tue, 10 Nov 2015 15:38:21 +0000 (UTC) Received: from mail-lf0-f52.google.com (mail-lf0-f52.google.com [209.85.215.52]) by lists.linaro.org (Postfix) with ESMTPS id B686161815 for ; Tue, 10 Nov 2015 15:36:13 +0000 (UTC) Received: by lfs39 with SMTP id 39so104412lfs.3 for ; Tue, 10 Nov 2015 07:36:12 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro_org.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=RUBQqB3cjP3lUuBrDs/zLT3Y3Psr13T1WmwuB7hNGIU=; b=QDXxkKSk9n40OnyGT9z4uOXRT0SGCOQq+/V6FNWswXJ/hd6aD9CNyLCPVDO8qQyLtK Nw37zYYcaeA/p/5AH3NStHO3VAvvbUdO95VvZu+2iGOKxxtPvXBNfo9TVzNaQhxnVs0W RCXhUXyzmYnR2i2ENdkOjQiqgzE2mrmSdbBx6nzXX9uQNupbqpAqJWMflKaOKaTw/Esh HPLG6Z6HUvscLxsfNTQJNXQQkjieTP9rJ/3asuayk20bHQmt/zW2gyWavgzotp2iecQX vgAQi6eioCg82ddutcjCNApchN5YLnFXD8omH/s6OYcuITkT5n1JHqOjsRwHRDBy2k9V QkWw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=RUBQqB3cjP3lUuBrDs/zLT3Y3Psr13T1WmwuB7hNGIU=; b=Fo9Nt06IvudQTV5FGvVos3gTXHBk2KFiFRpaG6/ZwQwp6h/TXgBYpZYO6E+ZWbR79V 6oWguKlpVbSa7qW6/MQ2Pg9A0cL/bTIay514HdIX8lXkOBJ2j4O4NhxkUaGFVK1tQKRX A4R/Ayf0hg6RFj4G6hDW+lctGZ4mNdaV87+z1F/L9SPW7S++7EFDoKpWuoMmP5zd7Zcw cF+WYL17jHRTmJSiNZ9dIC0T03QymxZVcahq+ILkDuMu1C3xj0HL+3Ylba1n7fC3klFf fojaogWR7XGiBJZ161+/iyxKiC3z2DwqIpxJJjCerRrKZiQKF0mFcTRCR6GOh24m6aCA O2kg== X-Gm-Message-State: ALoCoQkaEQx6/tKQ4KQwYk6gZO3k8cMipf1MBfMQp2/foAhmMsMExcYVWv5XjItw/q+dT1XI3367 X-Received: by 10.25.41.134 with SMTP id p128mr1873677lfp.75.1447169772551; Tue, 10 Nov 2015 07:36:12 -0800 (PST) Received: from localhost.localdomain ([195.238.92.128]) by smtp.gmail.com with ESMTPSA id h37sm625049lfi.8.2015.11.10.07.36.11 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Tue, 10 Nov 2015 07:36:11 -0800 (PST) From: Ivan Khoronzhuk To: lng-odp@lists.linaro.org Date: Tue, 10 Nov 2015 17:36:00 +0200 Message-Id: <1447169760-15258-4-git-send-email-ivan.khoronzhuk@linaro.org> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1447169760-15258-1-git-send-email-ivan.khoronzhuk@linaro.org> References: <1447169760-15258-1-git-send-email-ivan.khoronzhuk@linaro.org> X-Topics: patch Subject: [lng-odp] [PATCH 3/3 v3] linux-generic: cpumask: warn that CPU0 is used by control and worker thread X-BeenThere: lng-odp@lists.linaro.org X-Mailman-Version: 2.1.16 Precedence: list List-Id: "The OpenDataPlane \(ODP\) List" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: lng-odp-bounces@lists.linaro.org Sender: "lng-odp" By default all control threads on CPU0, and odp_cpumask_default_control returns it. It shouldn't overlap with worker cpumask, but for some cases it's correct to use potential processing capability, so better leave this choice to application and only draw attention to it when cpumask for worker thread is read. Signed-off-by: Ivan Khoronzhuk --- platform/linux-generic/odp_cpumask_task.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/platform/linux-generic/odp_cpumask_task.c b/platform/linux-generic/odp_cpumask_task.c index 535891c..b4b4f23 100644 --- a/platform/linux-generic/odp_cpumask_task.c +++ b/platform/linux-generic/odp_cpumask_task.c @@ -40,6 +40,10 @@ int odp_cpumask_default_worker(odp_cpumask_t *mask, int num) } } + if (odp_cpumask_isset(mask, 0)) + ODP_DBG("\n\tCPU0 will be used for control and worker thread.\n" + "\tIt can have impact on worker thread\n"); + return cpu; }