Received: by 2002:ab2:6816:0:b0:1f9:5764:f03e with SMTP id t22csp454148lqo; Thu, 16 May 2024 10:47:39 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCWcUKXSSizepERNvqb3QihNeneUehtGQLT1FqaLbR3vzRg00vreIfVfxR0i46TXWJV+Q40J4/SK/ZFsxc548SZCbpNJDsyFHbZ+aWyZiw== X-Google-Smtp-Source: AGHT+IFt4Yqd2fO0yhlEqeK0xGvhzEzcokNemNB+GdebfSLQInbdYXHpuvtni9Fu5+n2TRv1q2Jh X-Received: by 2002:a17:907:7803:b0:a5c:d4b2:6a44 with SMTP id a640c23a62f3a-a5cd4b26c51mr517575666b.16.1715881659562; Thu, 16 May 2024 10:47:39 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1715881659; cv=pass; d=google.com; s=arc-20160816; b=SAtmv067rXgC4eFkCB3Obwm4c4/zDgP8Y/fV6zszGNNF6neH6L11si0bcR4VB/vXJp NhcRT9rJvBSjmvEeq/KPhz/LS4cVjkp1eAnqcAa6u/7NJMNEQ66L99Kh1wo2X7qGc2fV eZew/uZMSAfrgckcPay/lIXHJ4I9flkElBTsdjMTXn1aPlo0QREd6P+gKWCO6ZDCV+tq epD1Jx6o7eoUyrlmmoXMj6JYli4wEp9SKZt1rEK3TSWZGBmiDxPXW3t0ylg+tqtOD+FH skQYM0O8vFzo5t6SXgyV9KgxrLQlSj9SybkwjjoE0OnxxZcj+MGuWRrxXUryTif6nvhK Fdig== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:in-reply-to:message-id :date:subject:cc:to:from:dkim-signature; bh=4LvzjOZ0xVdD8uYH97G1FDu1gcEeUac6frsU7264pgw=; fh=8j/KWJf+jhQ0RBqtfcdhRQWP3RepaakKZg/d36ZnJZc=; b=xcOteNf+2JWYqzivTxiaiHPnp5JawTQ7pnU1vlPRmpjfpiYviZx4tdDDWOBrUoKr7f KpLC9RCd3t4hDgs8s793cFM2ccnCgBGViZHlowCtZx52yXreVySV/Dh38UABoHInbgYF x8ph+pIix6GMQMESX1HXIgtk4p8mf/L+8tauwyuNgymWNPTpBcIUmKaM35trSimJwClb YliwfXm3mzLgMj9S7L+zGkMRitlq7Y9cN98MkHTFAi+uy6dfTqD8XKTgiiwZLlIHJhOA OPbxV/Wtj40LQUu1wgZaGpM8BKEnrtRIGgG/ygdRJEOmlqIqm/423Y0Y8+OSAPvqG63i T/bw==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=AFx7Uqoz; arc=pass (i=1 spf=pass spfdomain=gmail.com dkim=pass dkdomain=gmail.com dmarc=pass fromdomain=gmail.com); spf=pass (google.com: domain of linux-kernel+bounces-181398-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) smtp.mailfrom="linux-kernel+bounces-181398-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from am.mirrors.kernel.org (am.mirrors.kernel.org. [2604:1380:4601:e00::3]) by mx.google.com with ESMTPS id a640c23a62f3a-a5a17c2c670si905067366b.992.2024.05.16.10.47.39 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 16 May 2024 10:47:39 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-181398-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) client-ip=2604:1380:4601:e00::3; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=AFx7Uqoz; arc=pass (i=1 spf=pass spfdomain=gmail.com dkim=pass dkdomain=gmail.com dmarc=pass fromdomain=gmail.com); spf=pass (google.com: domain of linux-kernel+bounces-181398-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) smtp.mailfrom="linux-kernel+bounces-181398-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.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 am.mirrors.kernel.org (Postfix) with ESMTPS id 4F4511F22995 for ; Thu, 16 May 2024 17:47:39 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 7475B157465; Thu, 16 May 2024 17:45:01 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="AFx7Uqoz" Received: from mail-io1-f52.google.com (mail-io1-f52.google.com [209.85.166.52]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 24FA4156871 for ; Thu, 16 May 2024 17:44:59 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.166.52 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1715881500; cv=none; b=sbCAQUKgX6jWYjVoTc4EnQvQFRJ58P8KQwZ7YeXnXKd+0BqLMjkv8lfdKyuBZE+jfHviSnHeHtLYb3zB1ZAwPX3EkYE5uE9vp53ShQEX7I8fxHWzyLNtK7MiBb3Bdx1HMnVHMkFlhdm75+4DD2/5HGpkTNiDtvO+b68oX55I+Ok= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1715881500; c=relaxed/simple; bh=W/ixAni8SUOXaOT3Pv81/RNqnJOi7m94kvHfKRq5YLc=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=ScS8qPb5NPL/VghrGlzGODG/ZIzNPfZIoPURKebnds1U9lby3yBpiI0FyY9mYZ2V6QeEYsTowgGcJwkvViJI4AFaXJj3x6P/vDaJE9BqtY7l9bNkFd/+YxWGOMhxnDDsKczSvvA/DKh4f/ylx1UQdMr6K6tIIcS9cKTqAB2yx0w= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=AFx7Uqoz; arc=none smtp.client-ip=209.85.166.52 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Received: by mail-io1-f52.google.com with SMTP id ca18e2360f4ac-7e1f984312cso63551639f.2 for ; Thu, 16 May 2024 10:44:58 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1715881498; x=1716486298; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=4LvzjOZ0xVdD8uYH97G1FDu1gcEeUac6frsU7264pgw=; b=AFx7Uqozwfk+rVCjww3FdQL95H/A1dIBABpiIyokuSkGZ1ljq1Hxz30/sYzQ3yIjZ1 wHBYUsiIaQ5v9HI5Zomgm8f0tQJkDqdl3PL0i5vRuxjNoz5+6oCNKcAxFz1xatYPCda9 LxQXpczECasua1H+GomRGBzj0hlinfr/QHClVIN4SDL8GTcj16p/5idVHV4kWQcSAOd3 1occz3VQ7b2laRYnmkcUZxtZ4C0A/hBkktmT/zYAby3HE1Z3nRoLxwDNmrsRz3K2s8xe QTNsHFtqOkVSuAUZ4UrVu3KD5YCVQpuKCPVfS6Fw2m7Z5y1Wxroydoum1xpJJrBt4ZwO LZVw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1715881498; x=1716486298; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=4LvzjOZ0xVdD8uYH97G1FDu1gcEeUac6frsU7264pgw=; b=iL250IHir0NotaKGbML/N6g4ZtUKTJNoL5YlJZNZj6qSmaQPmHb8LgGPrh8R1R7ylq 30+D6HGf94r3dFj9GlWzVtLzOABzsjSxwtzWnIf8KxpcBVl159Wm8vW1aUdcR4ZOu6Zy HyesP7kWyHsWuYpwm8CVgm9qvKvHWXSzKrJMu8idk+QDmZPmC0xRM/YvkScIf8ctg7Rs oB3l8P3SZ+bJnCrmdo55hvM06HhISwKcqwRsybJEbYVnCG/TpEgEFvkQBtvhOR0kfZof qzHJUysGjbj11IsF5x1jEP1PVPd63ctLGVmX23hR2EDUea3NM9dRUfaH6AAV9k3X4pHi E6Mg== X-Forwarded-Encrypted: i=1; AJvYcCX9lOTW7ZIsNeOyryRMm6HMC+pZ8mgojOy/oHJ+iJQ9GkajezS0a2WNTxg+iX4fcxd5JHsNIzx7iY4EPi0/a3A/GL2lWhH7ddZXfVt8 X-Gm-Message-State: AOJu0YypB1fRRGCyL+jmDcp+H/FuU2Pn75RoqPzUK7CO5v8Ig8mXL1zr WXV3SN/oRDFLswg/GlwizMa1Hjwbk9Y0PVWH2sPD7MF3W0MiBwsm X-Received: by 2002:a6b:7b08:0:b0:7e1:8633:5a80 with SMTP id ca18e2360f4ac-7e1b521b447mr2122214339f.19.1715881498384; Thu, 16 May 2024 10:44:58 -0700 (PDT) Received: from frodo.. (c-73-78-62-130.hsd1.co.comcast.net. [73.78.62.130]) by smtp.googlemail.com with ESMTPSA id 8926c6da1cb9f-4893715057csm4273595173.80.2024.05.16.10.44.57 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 16 May 2024 10:44:57 -0700 (PDT) From: Jim Cromie To: jbaron@akamai.com, gregkh@linuxfoundation.org, linux-kernel@vger.kernel.org Cc: ukaszb@chromium.org, linux@rasmusvillemoes.dk, joe@perches.com, mcgrof@kernel.org, daniel.vetter@ffwll.ch, tvrtko.ursulin@linux.intel.com, jani.nikula@intel.com, ville.syrjala@linux.intel.com, seanpaul@chromium.org, robdclark@gmail.com, groeck@google.com, yanivt@google.com, bleung@google.com, Jim Cromie Subject: [PATCH v8-RESEND 17/33] selftests-dyndbg: exit 127 if no facility Date: Thu, 16 May 2024 11:43:41 -0600 Message-ID: <20240516174357.26755-18-jim.cromie@gmail.com> X-Mailer: git-send-email 2.45.0 In-Reply-To: <20240516174357.26755-1-jim.cromie@gmail.com> References: <20240516174357.26755-1-jim.cromie@gmail.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Test if /proc/dynamic_debug/control exists, exit 127 otherwise. This distinguishes an untestable config from both pass & fail. The 127 choice is pretty arbitrary, but imitating bisect. That control file's presense guarantees that dynamic-debugging is configured (unless /proc is off, unusually), without dealing with the mount. Signed-off-by: Jim Cromie --- tools/testing/selftests/dynamic_debug/dyndbg_selftest.sh | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/tools/testing/selftests/dynamic_debug/dyndbg_selftest.sh b/tools/testing/selftests/dynamic_debug/dyndbg_selftest.sh index 1be70af26a38..cb77ae142520 100755 --- a/tools/testing/selftests/dynamic_debug/dyndbg_selftest.sh +++ b/tools/testing/selftests/dynamic_debug/dyndbg_selftest.sh @@ -11,6 +11,11 @@ CYAN="\033[0;36m" NC="\033[0;0m" error_msg="" +[ -e /proc/dynamic_debug/control ] || { + echo -e "${RED}: kernel not configured for this test ${NC}" + exit 127 +} + function vx () { echo $1 > /sys/module/dynamic_debug/parameters/verbose } -- 2.45.0