Received: by 2002:ab2:3350:0:b0:1f4:6588:b3a7 with SMTP id o16csp1285620lqe; Mon, 8 Apr 2024 04:54:43 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCXQEgbQWdS8rtH5IT0hVXWHqTKzbnIUzap8LE5d8o3A25+9TK3gbcKymCAowLbQ+tt5r2W5fhlkCxPmX+oo3qCRRk76J1Ier3cthbt1lg== X-Google-Smtp-Source: AGHT+IGQkn5iLbgBAwBZDrva3fimgbp8HXNa9DNsviC4vfTuxt44octqqmv7J7G1PaiOKL6kuGbM X-Received: by 2002:a05:6a00:80f:b0:6ea:b818:f499 with SMTP id m15-20020a056a00080f00b006eab818f499mr11182580pfk.19.1712577283217; Mon, 08 Apr 2024 04:54:43 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1712577283; cv=pass; d=google.com; s=arc-20160816; b=U7TYmvOU9yN0sYKF5lPS9ltGOBNoVTLA35KHAD//sgua8inIke70Up7XOQCE7oso2Y jmmtcCbdUPMzR93Zx4STWRmqqO/8WzpzjmonMRDeQ2gI1jRLiKPHFlG0TpLp/e+y6J3O mF+b5A14dUKs6EbdGKaFaYDIdSjwdJsvaY5IMuRw+5HhT6EMYAnbdnksYLydZVBOyiJ1 pKtXkOGmrzaFXw0LoTBuvzOClT1XZ3OiZpQprrupkwnXBNt0ukQtPiLeAYnB0XYi+mBq QF8OSY3NEGr8P57I4H68x5h2r0ZmACIhN2Gznd0ve1O/m63B3c0paj7yE/B+umfkgb/5 SAJw== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:in-reply-to:from:content-language :references:to:subject:cc:user-agent:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:date:message-id:dkim-signature; bh=ecE/uj9QnylrBOizcZYIwoobA+wyfEu4MPH84XD8Yzw=; fh=riU51rh8uux8RkZGaNYNDicdGHlL2536MfUp4ZO1OOo=; b=Nx0cS/SYuyVAcceT+o9+iBkYXIrpb3mpOGFFs/EXdY7uV57ws4oGbeUB7vFpqx3Xbh p8feKOse0FyPzVGEYHQnNLdqATY/1v9tXUQzx8fjRrbX5eFzzu8xnp4TZZD3XGdxR0Fv XgD69KytU1O2Fe+X7rfaidsVvIr6eIEgsLzgeofPuNCyDWqXv1GZVr2fk3BQUNFl7G4x HSMcuCcSbuj5CoIHsMUb/yXdPwYGkUsmpp20UBJjD8iBhDpNCkfplwQqZLf78lazJGY4 FvFXXwRU8dUF4AlJiaQgd+BQaWQZTeid+Hgf0NTL/I2MEHyXHt7uU03VM4sLpn/cmAJF QOBw==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@collabora.com header.s=mail header.b="LOVQ3p/3"; arc=pass (i=1 spf=pass spfdomain=collabora.com dkim=pass dkdomain=collabora.com dmarc=pass fromdomain=collabora.com); spf=pass (google.com: domain of linux-kernel+bounces-135289-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-kernel+bounces-135289-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=collabora.com Return-Path: Received: from sy.mirrors.kernel.org (sy.mirrors.kernel.org. [147.75.48.161]) by mx.google.com with ESMTPS id i5-20020a056a00004500b006e6c056f450si6061810pfk.213.2024.04.08.04.54.42 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 08 Apr 2024 04:54:43 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-135289-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) client-ip=147.75.48.161; Authentication-Results: mx.google.com; dkim=pass header.i=@collabora.com header.s=mail header.b="LOVQ3p/3"; arc=pass (i=1 spf=pass spfdomain=collabora.com dkim=pass dkdomain=collabora.com dmarc=pass fromdomain=collabora.com); spf=pass (google.com: domain of linux-kernel+bounces-135289-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-kernel+bounces-135289-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=collabora.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sy.mirrors.kernel.org (Postfix) with ESMTPS id 1C407B23639 for ; Mon, 8 Apr 2024 11:52:58 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 038FD6A333; Mon, 8 Apr 2024 11:52:49 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=collabora.com header.i=@collabora.com header.b="LOVQ3p/3" Received: from madrid.collaboradmins.com (madrid.collaboradmins.com [46.235.227.194]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id B0F48657CB; Mon, 8 Apr 2024 11:52:46 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=46.235.227.194 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1712577168; cv=none; b=gbeGS662RWZiAAmiweNb8DeA+Ngw9w5f8Ner2IdAVRCRKN+yxrReVAI15PDP3eJkmc57M5YNbhJW/swibM6ykYJwN7eqOJeO2gHgNmCcI6rehrPm9cpPwtoz8uDHAl0/odIqqZcAq6NbnaToA7KfvYfOZF4OYxSIUTWRUwEjWts= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1712577168; c=relaxed/simple; bh=9TcqgVCdebpUEtPloXV2xwkuH5UyaU8oSE1S2N9IZMw=; h=Message-ID:Date:MIME-Version:Cc:Subject:To:References:From: In-Reply-To:Content-Type; b=uKeDazVsSghEC63BCw31/7Wn9t0cto6tPzGUl0B95IVinuBtRPeMP9j+K1W0nTZCEkMuShjjm7zzB6UbAmC7nOOoTAjB7M9MYmTjZnDYHMQn1yfpchh/JyZgpLErtGnxSHkS3ADymcq2UGtuDF83j+PxRq5xamwNbRaX5lXqVF0= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=collabora.com; spf=pass smtp.mailfrom=collabora.com; dkim=pass (2048-bit key) header.d=collabora.com header.i=@collabora.com header.b=LOVQ3p/3; arc=none smtp.client-ip=46.235.227.194 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=collabora.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=collabora.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=collabora.com; s=mail; t=1712577164; bh=9TcqgVCdebpUEtPloXV2xwkuH5UyaU8oSE1S2N9IZMw=; h=Date:Cc:Subject:To:References:From:In-Reply-To:From; b=LOVQ3p/31BEegWocwBzMmKRuGOXUjKNbDGMyX1aUKsjGFNyGJH0UFM8mCzKZb6dbz AWa3bMlprII5kWnXhjSM0u6BwoHzrQGrK+YN0qvLbunMm6sntZMW3uBVTtgtvsvpku TtmscyRlvZvz0a7X0jePsuQNa+6ckn5O8gxBVRM0Fx2vRYeQ7RZHLFI8yL13yr1ofl ekda8FQp4FMAyocuhVl5Ai2fXshSvbqBgbaVRjf5cjqUQd2Fgkr29ugbzl5A8cizsb YT0jJXE3PcAUcUFz4XuRaZYIgkLtcD7xWU0aj0nqlx1+SiqDW9wo1WyDps9brkjqLD QLD9QUOmaBUUQ== Received: from [10.193.1.1] (broslavsky.collaboradmins.com [68.183.210.73]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) (Authenticated sender: usama.anjum) by madrid.collaboradmins.com (Postfix) with ESMTPSA id 6E5753780894; Mon, 8 Apr 2024 11:52:39 +0000 (UTC) Message-ID: <41dd9c5a-0e07-4b98-9dfb-fb57eaa74fa2@collabora.com> Date: Mon, 8 Apr 2024 16:53:11 +0500 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Cc: Muhammad Usama Anjum , cgroups@vger.kernel.org, linux-doc@vger.kernel.org, linux-kernel@vger.kernel.org, linux-kselftest@vger.kernel.org, Tejun Heo , Zefan Li , Johannes Weiner , Jonathan Corbet , Shuah Khan Subject: Re: [RFC PATCH v3 6/9] selftests: cgroup: Add basic tests for pids controller To: =?UTF-8?Q?Michal_Koutn=C3=BD?= References: <20240405170548.15234-1-mkoutny@suse.com> <20240405170548.15234-7-mkoutny@suse.com> Content-Language: en-US From: Muhammad Usama Anjum In-Reply-To: Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit On 4/8/24 4:29 PM, Michal Koutný wrote: > On Sun, Apr 07, 2024 at 02:37:44AM +0500, Muhammad Usama Anjum wrote: >> The >> ksft_print_header(); >> ksft_set_plan(total_number_of_tests); >> are missing. Please use all of the ksft APIs to make the test TAP compliant. > > Will do. > >>> + for (i = 0; i < ARRAY_SIZE(tests); i++) { >>> + switch (tests[i].fn(root)) { >>> + case KSFT_PASS: >>> + ksft_test_result_pass("%s\n", tests[i].name); >>> + break; >>> + case KSFT_SKIP: >>> + ksft_test_result_skip("%s\n", tests[i].name); >>> + break; >>> + default: >>> + ret = EXIT_FAILURE; >>> + ksft_test_result_fail("%s\n", tests[i].name); >>> + break; >> Use ksft_test_result_report() instead of swith-case here. > > Do you mean ksft_test_result()? That one cannot distinguish the > KSFT_SKIP case. > Or ksft_test_result_code(tests[i].fn(root), tests[i].name)? No, this doesn't seem useful here. > > Would the existing ksft_test_resul_*() calls inside switch-case still > TAP-work? This part of your switch-case are correct. It just that by using ksft_test_result_report you can achieve the same thing. It has has SKIP support. ksft_test_result_report(tests[i].fn(root), tests[i].name) > > Thanks, > Michal -- BR, Muhammad Usama Anjum