Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp1969862imu; Sun, 18 Nov 2018 12:45:52 -0800 (PST) X-Google-Smtp-Source: AJdET5cZfgwUrue0EK4797XNBnOIXnlZcOQTUg7i1na3J15gg715d0xG/aAPHGNTV+5K+ziZqnnn X-Received: by 2002:a17:902:163:: with SMTP id 90-v6mr19902656plb.87.1542573952667; Sun, 18 Nov 2018 12:45:52 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1542573952; cv=none; d=google.com; s=arc-20160816; b=saDXuNCf0QctE9tD6x7fUy9SrJta4l/NBOiFiZ+t0F8VvSSAptBxOl/ED6OubmDO6N qNV8dt2IS5e89VaIGhTyj8j36SwTCgjue8sBF5LSwZaZMJnLCeNxryyrTfsNQrLP+44n Ywz1E5gfososmozYSwf981IduIXjgzDeHCWmLBdSgRVL2RZM8HbvgdzHmiRNTEwaOJoI mrPmFLt5Hx9mNsdsYI2fVxQrmZ7bPNmFsf5gWmCUz/1zRizW0YzL/ivzzFX86W/LJy/x qlNq/XNkILxdIzF/KeD1nZTcVnQO24n6bbMROIotokyqOgNT7HCrYMuDuPODHrhBmyUG gCpw== 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:organization:from:references:to:subject:cc :dkim-signature; bh=mfwWaMSXAnGvCyZhknK3dgKH0DCrI3zzR88U8BnZDvE=; b=phPE4whwV+hBy2kLRgA4QNuN5nVnoIPbohCUvGuUUYSdB+G6umaG83kq4NsoMRkMYS zrwVjGc34KdVi7b24LrhZj66Lw5xmJqfw2JCtXQXJBzjfCnEsG+5zWlesGsjFiedAdGf q3pxypeCZ6Asx8LKYsy58XC+4Un0D7Y0sjRF3bATb92GBZGWxhHXTb10XvBu0fiAWMrZ 8obd4gF4/FtSmbC/bMHlVVuo2Z1Fmd6vYe1fa9mnM7uPQWwleVbFUQy2e99HkZACQ2En tI3oLUhFMfKg+c+iq1N02vLLhKL9QPWIxw0QHWTWeQKj2yQZujlXXaCIdHk3SSdfbt9t Sq+g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=EhARRW6k; 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 194si34655716pgg.519.2018.11.18.12.45.37; Sun, 18 Nov 2018 12:45:52 -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=EhARRW6k; 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 S1727332AbeKSHGO (ORCPT + 99 others); Mon, 19 Nov 2018 02:06:14 -0500 Received: from mail-qk1-f196.google.com ([209.85.222.196]:41397 "EHLO mail-qk1-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726095AbeKSHGO (ORCPT ); Mon, 19 Nov 2018 02:06:14 -0500 Received: by mail-qk1-f196.google.com with SMTP id 189so45636814qkj.8 for ; Sun, 18 Nov 2018 12:44:55 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=cc:subject:to:references:from:organization:message-id:date :user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=mfwWaMSXAnGvCyZhknK3dgKH0DCrI3zzR88U8BnZDvE=; b=EhARRW6ki4ocJ9XuCpNesbqQ2455skDLMYtuSIFRgXlFxk7z4xESfIUSGWBUmmtE65 PEf7toCdY7aaTLgk+5WhqfQ/Muho/Vnoya4mq6MlCW1kjBQscmbTY6aB638jc/wMy3XE pE2WUHFCAoQ/DYUsyyzaozHeny5RJXSsgYBTw= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:cc:subject:to:references:from:organization :message-id:date:user-agent:mime-version:in-reply-to :content-language:content-transfer-encoding; bh=mfwWaMSXAnGvCyZhknK3dgKH0DCrI3zzR88U8BnZDvE=; b=H9nQGm3wKH7AS+Wxn6U3m5FjgNcjRdkdtTaa2TYcUWkEn7F0Q2YnbaKRxttJ2iUhcq CrTM+AEJZRUA9RNBb6tHacd0RrZxjb2mtSt0odrKbSJK7mRq2RdW3kFRREbDRr0eRz/R eYWG0n0AfHDwEBb/s0jMDj6gs9FHTbFpqGfBc3jaclboJHquSGeBAu0VYrVI01pg4DS/ AqhD9X2zcQ0lytPmt5OJ0PKBz4n2R55cXSMkvHf+sFnIDJoWVQjgd+Z0GPol3YPyDp1J gO8MgAnAEGqS1++1sIXEWkGWz5CUwFa6snDxLAiwnCZ0xUCcVz6kwmRj9SwxaEqPohru yhzg== X-Gm-Message-State: AGRZ1gJVhGYCrsIb3qeoSR0Kn/pPegHIJoBX/IuEbPSjuflJupZtVWaV 7g4KaeWluzqJg22A3sRUUeneoA== X-Received: by 2002:ac8:35eb:: with SMTP id l40mr19014369qtb.165.1542573895426; Sun, 18 Nov 2018 12:44:55 -0800 (PST) Received: from [192.168.48.13] ([168.194.160.89]) by smtp.gmail.com with ESMTPSA id b20sm18313777qkb.17.2018.11.18.12.44.51 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sun, 18 Nov 2018 12:44:54 -0800 (PST) Cc: Rafael David Tinoco , linux-kernel@vger.kernel.org, linux-kselftest@vger.kernel.org, peterz@infradead.org, tglx@linutronix.de, mingo@kernel.org, mathieu.desnoyers@efficios.com Subject: Re: [PATCH v5] selftests: membarrier: re-organize test To: shuah@kernel.org References: <20181109154911.24464-1-rafael.tinoco@linaro.org> From: Rafael David Tinoco Organization: Linaro Message-ID: <4b31ee44-6463-6f6b-ca43-f03af8b06e35@linaro.org> Date: Sun, 18 Nov 2018 18:44:50 -0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.3.0 MIME-Version: 1.0 In-Reply-To: <20181109154911.24464-1-rafael.tinoco@linaro.org> Content-Type: text/plain; charset=utf-8; format=flowed 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 >> Why do we need to add new routines for these conditions. Why can't handle these strings in array. For example you can define an array of strings for passed unexpectedly etc. and the pass the string to appropriate ksft_* interface instead of adding of these routines. Also it is hard to review the code this way. I was able to fit all the logic in the 80 char limit and, still, give a notion what was being called on each condition (instead of using an array number or equivalent). Considering this is not the core code, and the this has been already accepted and reviewed in LTP project, would you mind accepting it so both can be maintained together ? It is much better than the existing one, anyway... Note: I have removed the part where we test for older return codes, since kselftest is not focusing in those (but LTP does). >> I do like the direction though. Also please run get_maintainer.pl and cc everybody it suggests. Done in v5. Thanks a lot. >> >> thanks, >> -- Shuah > This commit re-organizes membarrier test, solving issues when testing > LTS kernels. Now, the code: > > - always run the same amount of tests (even on older kernels). > - allows each test to succeed, fail or be skipped independently. > - allows testing features even when explicitly unsupported (force=1). > - checks false positive/negative by checking ret code and errno. > - can be extended easily: to expand an array with commands. > > Note: like this, the test is pretty close to the LTP membarrier basic > tests, and both can be maintained together. > > Link: https://bugs.linaro.org/show_bug.cgi?id=3771 > Link: http://lists.linux.it/pipermail/ltp/2018-October/009578.html > Signed-off-by: Rafael David Tinoco > --- -- Rafael D. Tinoco Linaro Kernel Validation