From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (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 DE2C725DD1E for ; Fri, 25 Jul 2025 20:34:20 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1753475660; cv=none; b=EJlWAV9Oq9UqcTifVu2fKstOePYJyI5HpTSaovQbZBWRtr0jLOv27paQeN6Mkz6zWPv7YxsYSBaj8ZsloY4vif/XOcexhbRkhC55htK1OZ8VUA+pJf8khhNddVIyqIL4N1xD6EclHFfs9oQDbnb55Ht6DK2Y4/9wD3C+wJ+w4lg= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1753475660; c=relaxed/simple; bh=v3dRc6gn7lynJJ8xeHW8GTHQpld+ulORhv4T4YMRbqo=; h=Message-ID:Date:From:To:Cc:Subject:References:MIME-Version: Content-Type; b=LMLq2CQ5+ZmRWC0o7VteHKHDf6mu5z+8uSQmxRTDfuW9cNDNt277/hEVAjEFxS7+y87f468gE14QJ0920NKgU1omAmuyJLUZRgQeuG7WOXI7/uvo7RPXAJRfw0XJxMCzjaxUl9zOlWl1i9Nvl2dInb0dNoF934MEM1cDtEDusyE= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=fAPZoiw9; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="fAPZoiw9" Received: by smtp.kernel.org (Postfix) with ESMTPSA id C14A2C4CEEF; Fri, 25 Jul 2025 20:34:20 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1753475660; bh=v3dRc6gn7lynJJ8xeHW8GTHQpld+ulORhv4T4YMRbqo=; h=Date:From:To:Cc:Subject:References:From; b=fAPZoiw9iaD3nENTz5hl19Nx1sIBM0dhhzWUePsXIo70lo0Xtqypjw26G/Ceu0lVl K6waiVKpcgnYBSGn0bE1UsxTnMIlg852zscpToBpiI7kF8Twbl9E6EV1ifNaCA6owI /6Etchoh6ObQgVxXdavFWGm3PmpcgkSftLmKpvTSXXekMe3c+FZHYRm2hlL+h0Q91u RQerX66Q/1FlclXGmj0s6htvGJ14ntOtiG67Q0oBrXiSvNkDeN4n3f3AQoOTRAj5ro wR/cieIJF2+Z0QZhqJl744ElyQxumVDefH2D39OEJhqXrip4sDBAOAC1ECdzOZNzLz XDy9FejB46SyQ== Received: from rostedt by gandalf with local (Exim 4.98.2) (envelope-from ) id 1ufP7a-00000001QkL-3w2j; Fri, 25 Jul 2025 16:34:26 -0400 Message-ID: <20250725203426.791145358@kernel.org> User-Agent: quilt/0.68 Date: Fri, 25 Jul 2025 16:34:14 -0400 From: Steven Rostedt To: linux-kernel@vger.kernel.org Cc: Tomas Glozar , John Kacur , Nam Cao , Juri Lelli , Clark Williams , Gabriele Monaco Subject: [for-next][PATCH 17/25] tools/rv: Stop gracefully also on SIGTERM References: <20250725203357.087558746@kernel.org> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 From: Gabriele Monaco Currently the userspace RV tool starts a monitor and waits for the user to press Ctrl-C (SIGINT) to terminate and stop the monitor. This doesn't account for a scenario where a user starts RV in background and simply kills it (SIGTERM unless the user specifies differently). E.g.: # rv mon wip & # kill % Would terminate RV without stopping the monitor and next RV executions won't start correctly. Register the signal handler used for SIGINT also to SIGTERM. Cc: Nam Cao Cc: Tomas Glozar Cc: Juri Lelli Cc: Clark Williams Cc: John Kacur Link: https://lore.kernel.org/20250723161240.194860-3-gmonaco@redhat.com Signed-off-by: Gabriele Monaco Signed-off-by: Steven Rostedt (Google) --- tools/verification/rv/src/rv.c | 1 + 1 file changed, 1 insertion(+) diff --git a/tools/verification/rv/src/rv.c b/tools/verification/rv/src/rv.c index 239de054d1e0..b8fe24a87d97 100644 --- a/tools/verification/rv/src/rv.c +++ b/tools/verification/rv/src/rv.c @@ -191,6 +191,7 @@ int main(int argc, char **argv) * and exit. */ signal(SIGINT, stop_rv); + signal(SIGTERM, stop_rv); rv_mon(argc - 1, &argv[1]); } -- 2.47.2