From patchwork Tue Mar 6 15:10:04 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Anders Roxell X-Patchwork-Id: 130817 Delivered-To: patch@linaro.org Received: by 10.46.66.2 with SMTP id p2csp4050866lja; Tue, 6 Mar 2018 07:10:17 -0800 (PST) X-Google-Smtp-Source: AG47ELtz7oTM5AvwclmhnM5QZdjXxtVjEAHhBWjIigx2XhUY7u00fHhCQrcarDNiHaQ03263YyoM X-Received: by 10.101.83.3 with SMTP id m3mr10115001pgq.197.1520349017609; Tue, 06 Mar 2018 07:10:17 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1520349017; cv=none; d=google.com; s=arc-20160816; b=H+ANCpnwBHbxdLaKlDwqoAoi5vx62P1mf0iLf8CqahJWAf697xOBe3suNI4wKPG3Km 41sCgoClweR8EwYUZND2XeWRqfru1BpuX5IFKGVwtmCHxKfLIwQDdsAjE0EFdlQeMj6e GCwww6TiZ2qkog3quDP+ZYFX+5ZwXzwawm5Y0DkRC9csuTUSIdJgsyVbUhUk/YnolVU0 SD8wdSvZg7cUOEErbdWe2uyIMB2VvoFOqHC/2V9wWe6N+P+ecM9h+Wbc6fUzniEYR8fz 8E6p7jrAOBF/0vvdY5452pg0Drmlh5NhbBB/6gqa/s9PgJheXse3llE17ANtpld0T4IJ KeXw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:date:subject:cc:to:from :dkim-signature:arc-authentication-results; bh=KLLi53zxRuws/WbckjD//8LGHBmnZG0iCopa//ii4tQ=; b=V8uxhyjSeYcATTjDS89vRC59/SZ3nC+kWZV2KLIMwS7uLy+UVQFtpDDQdMmAMeSKLJ ToKGDHZUP7JAvRbyQFc1toFs2Iv/qbhGLRO8KPhpP01z+C6RbCFbyXFUovux4QlHKa7i fvr7dy0eWKf15IXVjSKQV64zv1kOEjaybEyaFh/HQc6IbPt3J9ZjhxDdW0ifA7AGRkEC zyU+B1+gN7ps7MFfhLJMTBXOvMv6E7sa9Ak1nveoPKo2AvceAwWGlMS0npiU7kHOkpFB tIzuuzgEYqYLVKgTTb5vvFpaaa7OVaODHUPe7iElRHTj88w3sx7Ez9qazIu2Sthq7fAq 6hQQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=cNVYxO5K; 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=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id x2si12139440pfk.231.2018.03.06.07.10.17; Tue, 06 Mar 2018 07:10:17 -0800 (PST) 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; dkim=pass header.i=@linaro.org header.s=google header.b=cNVYxO5K; 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=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753775AbeCFPKP (ORCPT + 28 others); Tue, 6 Mar 2018 10:10:15 -0500 Received: from mail-lf0-f65.google.com ([209.85.215.65]:37864 "EHLO mail-lf0-f65.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753627AbeCFPKM (ORCPT ); Tue, 6 Mar 2018 10:10:12 -0500 Received: by mail-lf0-f65.google.com with SMTP id y19so28997712lfd.4 for ; Tue, 06 Mar 2018 07:10:12 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id; bh=KLLi53zxRuws/WbckjD//8LGHBmnZG0iCopa//ii4tQ=; b=cNVYxO5KfC2i1MrAqLJwvaCr3SxyXtXO9fMYGMbsnTc8ZwVdTykg6ztJxlcklGaW2R 6ot66R8o/hBGuaFmxTqB6dLIp9SbQbcjIJGTG8aOuX79xfS3rpLbYXwHfsomdtlbtSQf 28+chV9K4LdxXJw0q+yI/MRFZpLthFNS0dT98= 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; bh=KLLi53zxRuws/WbckjD//8LGHBmnZG0iCopa//ii4tQ=; b=px764UPUqKAbON7IIIr4NsOg6cKm0ecOKYnkdCFu72YA2Y+RGOM7vCWMvttbFa7ylF uXeIzmyHS30nIYCmXqEgnMRN0wSyHLEDUOOdTN0AuKWXg0rF3CL2tdmSXKn1TmSGxSkv 0K8rfachcWCvfK93uzkdqRuyIieWJwW0CreQfGfT0YrhI4IN8QdB8z9rMnh6fcZhyhn6 IpjF4l6Sm84Uuk5KdhinCdjtQZCyb+cZ+vjAAxpZWwe3XXpALxBIFj1+Z/P87DakS0tY 5iBgGjx6fDL5y4v+NGXpfe+zSqWhxzDjGWS25ZBpMoWPucdzugsAK9qK/gR4IebZzkem +dVA== X-Gm-Message-State: AElRT7FJvP94hIKX1O8cuM4cknBmnnMcZmOH4TLTEf4ccwgjFiYxFpKZ t/6U5ZHpiGZ5ISuqDK5NLQtQGQ== X-Received: by 10.25.80.25 with SMTP id e25mr12570905lfb.79.1520349011171; Tue, 06 Mar 2018 07:10:11 -0800 (PST) Received: from localhost (c-2c3d70d5.07-21-73746f28.cust.bredbandsbolaget.se. [213.112.61.44]) by smtp.gmail.com with ESMTPSA id o88sm3221251lfg.34.2018.03.06.07.10.09 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Tue, 06 Mar 2018 07:10:10 -0800 (PST) From: Anders Roxell To: davem@davemloft.net, shuah@kernel.org Cc: netdev@vger.kernel.org, linux-kselftest@vger.kernel.org, linux-kernel@vger.kernel.org, Anders Roxell Subject: [PATCH] selftest: net: reuseport_bpf_numa: don't fail if no numa support Date: Tue, 6 Mar 2018 16:10:04 +0100 Message-Id: <20180306151004.31336-1-anders.roxell@linaro.org> X-Mailer: git-send-email 2.11.0 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The reuseport_bpf_numa test case fails there's no numa support. The test shouldn't fail if there's no support it should be skipped with a pass. Fixes: 3c2c3c16aaf6 ("reuseport, bpf: add test case for bpf_get_numa_node_id") Signed-off-by: Anders Roxell --- tools/testing/selftests/net/reuseport_bpf_numa.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) -- 2.11.0 diff --git a/tools/testing/selftests/net/reuseport_bpf_numa.c b/tools/testing/selftests/net/reuseport_bpf_numa.c index 365c32e84189..9245c14165b7 100644 --- a/tools/testing/selftests/net/reuseport_bpf_numa.c +++ b/tools/testing/selftests/net/reuseport_bpf_numa.c @@ -228,8 +228,10 @@ int main(void) { int *rcv_fd, nodes; - if (numa_available() < 0) - error(1, errno, "no numa api support"); + if (numa_available() < 0) { + fprintf(stderr, "no numa api support"); + return 0; + } nodes = numa_max_node() + 1;