From nobody Tue Nov 26 12:43:47 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass(p=none dis=none) header.from=linaro.org ARC-Seal: i=1; a=rsa-sha256; t=1707323986; cv=none; d=zohomail.com; s=zohoarc; b=J/YNlpSYbFmXJrSQJNGi84qvXZCOApE+TuHEmLSsas/8gmqxUWJMnRH0JViEko+Sq21qZBUlcEzbNb5SLQqJZ/ZQ9Kg8cBWwat3YPXPEINu7s4nHjbbjHYUmYXR4UbDrXyOAskuhVzHO142qRpr6WcxrIYRpNhK9xwrz7UXH2hg= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1707323986; h=Content-Type:Content-Transfer-Encoding:Cc:Cc:Date:Date:From:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:Subject:To:To:Message-Id:Reply-To; bh=JB4Epfg8EtaZj5aKH+XSQiP5F2xLNHDHewznk8QZ/uQ=; b=XkjwAhwXsghtB1+Xob2U1YvnlVcuVBa53W9LCavziu/Lf1pbzD9Sp1ttwF1ldICHZeOnhGfL+DhV998so+0J4nt2mEqQirmOA4cuvR9bhJuG64UfgwzNHepAvO37dNoBtKilasbJp5blPwe4F5w2czkA/2zh9zxvFODtnVPSBpk= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1707323986404380.90398246263123; Wed, 7 Feb 2024 08:39:46 -0800 (PST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rXkwF-0002on-H6; Wed, 07 Feb 2024 11:38:19 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rXkwD-0002nw-RJ for qemu-devel@nongnu.org; Wed, 07 Feb 2024 11:38:17 -0500 Received: from mail-wm1-x330.google.com ([2a00:1450:4864:20::330]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rXkwA-00066Z-Uc for qemu-devel@nongnu.org; Wed, 07 Feb 2024 11:38:17 -0500 Received: by mail-wm1-x330.google.com with SMTP id 5b1f17b1804b1-40fff96d5d7so7338985e9.2 for ; Wed, 07 Feb 2024 08:38:14 -0800 (PST) Received: from draig.lan ([85.9.250.243]) by smtp.gmail.com with ESMTPSA id p22-20020a05600c359600b0040ffe1ca25bsm2621880wmq.21.2024.02.07.08.38.12 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 07 Feb 2024 08:38:13 -0800 (PST) Received: from draig.lan (localhost [IPv6:::1]) by draig.lan (Postfix) with ESMTP id 3C8BB5F7D3; Wed, 7 Feb 2024 16:38:12 +0000 (GMT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1707323893; x=1707928693; darn=nongnu.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=JB4Epfg8EtaZj5aKH+XSQiP5F2xLNHDHewznk8QZ/uQ=; b=S1/XuH9hhVCF17vL09deGuOPCEvDKTUWFGonrGvtfAQlnfYnDHLG9gurWZBPzu93JD mMAXEk2QzuU5g7qovS1sxb/IBZ38/UqeF9nPK1QvnqmtebkjusizrjWaC3L0/E9mnNdw VeCqeIMY1IwdvbmhNq+IEuepGT3YFZhiEBqcjGonyt8Cf8c5DiThSG960t3535KkT6ZX oUqg3s5Sf69QHoZYUJfAYXdTCceHa9Zb1qKP+aRGGDBwMUWmMDdXrO0n5Jq2lcCMj2OT l/oI0C6M00Jy7PhVkz5w/3fZ6eK1TMXVY+m6CXeok28/NPp+KiiDDit+ny4jDf4vHEA7 XLtw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1707323893; x=1707928693; 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=JB4Epfg8EtaZj5aKH+XSQiP5F2xLNHDHewznk8QZ/uQ=; b=JTvpIqGzWdk8yqd5xI+A2J19IBeB+p0AIjiK+pIdalQOsxiXSVMqFw3T9mXcTMN7Jb ETdcrtNUrayeFSYm1WLmnpmk8UpErB+4Au+hLjwNHRP1RMaZyGrubLzT2rWnC6VVCKaA gHChCJhv/Fe2HI/f30UX5eahaDCtMYRTNe0o3ePOSRkiyrkJLRAThLQJBoKCoPPRDCaa Lo0nGXr7Hpns7pGzNtHAMWDS7FPBxNkmLF/mUDmFnczTqVO1SHAvu+hik5xDgs2QdMzo ka4m90oHLeD9ymLxELq5sfqerY6z+LW4oHdYZghv/FX14KueqHWmHkA8vQdIJgX9aGWL ucvQ== X-Gm-Message-State: AOJu0YyvOTEIF7tH0Cw6bbQS5qc09V3pz2+Q8xurKJSlXj0mFOZEh+MA euFeGEorp9cb8jYP8VWEZ///R6ffjQkstHSZoEBW2srmLOBsRzQavorkPSsD48U= X-Google-Smtp-Source: AGHT+IEvPFJ9AiHPXUgrQGtYUNZtWpPgdfAya6MNHNQ9hp7Y4s+Nd6cMYbuiU69XSt7x4kxOo+adjQ== X-Received: by 2002:a05:600c:19c7:b0:40e:fc29:f503 with SMTP id u7-20020a05600c19c700b0040efc29f503mr5405118wmq.2.1707323893503; Wed, 07 Feb 2024 08:38:13 -0800 (PST) X-Forwarded-Encrypted: i=1; AJvYcCVp0oEbxQlW6lhYbqyiSfzsKgCLMiomGRKPA033C3MhkCfL8fILFps9xeAf/6Yl8ainmRYQ53W2P/oK0WJuCXotuRRzakC+kxGpY0oivDFJktSNHlI/GOKq0HFQqAf6ivyjx/yD5XhIln1qOPA0t088I5s+/ISRLlRpXigdaq/ZyZd2ewr+s+gZ7mN/1+ScxGBj7UW5NLdxFOjXjQCIYSTIHJmwMNji7mHrOVp9kvt4PHtXI6wl8DAP1uf7MrAFa80LAeuuqxk3sN8OLjP2iRmjimMiUjdaz1B8+oRWV5GOWKykDSpUPSlEl9W0goLRkS+7/aiiAwtwmGTQWqCwOfJy0zGX2gE1NskLgNPSh8fS+M9jL+TDNdeQUEq6B2GFA2bopBKOYQoF4EeVYwpbIa+w2BZ2bPYTQpUZsqyFhxgGfanNibpUyLBTDzBQ+ut45Kn7BtsJd7ZDWb7mjngI+UrOE2z14Y9Kg+cTMXGD2MSNiKKgnP85b+Y4hG7CL1jpCg6xK8EdnWrM52cQQsg2uRTRtqHcW55CNuk1ySQV+EbsG8808OgzUmzL5OxEMJFTA34TyywR+brmx9ZCjrfgpOxwiYIL5I/AaDS0PxiUE+Q9bnA93AHzIfKCdhRU/k19eLE0B4+HE9mxO7lsh+Kt0DumFz9JqtwrsvotX4SkwWQiBFf5pzNe6JxCMfZJsskUMIP6O3ezSpIUEDiG3XKp4Me/bCMZn/8gjs/7XR8WpTYt1iYqTLNsiJg9pbcixbGpyDVQeV99ED66J0F1fwi+H1iQt/2glPfy8PHUACCjuhTUoF0Et4gCJR2/nD4DQmrC7jiMn08JZ8ForUt/A3EijVwHLmEYmD4k6Nn+1rRsnJWnsg87Bbs7sOjME0VlwNvRYw== From: =?UTF-8?q?Alex=20Benn=C3=A9e?= To: qemu-devel@nongnu.org Cc: devel@lists.libvirt.org, Jiaxun Yang , Daniel Henrique Barboza , Chris Wulff , Weiwei Li , Bin Meng , Thomas Huth , qemu-riscv@nongnu.org, Marek Vasut , Liu Zhiwei , Aleksandar Rikalo , =?UTF-8?q?Marc-Andr=C3=A9=20Lureau?= , =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= , Alistair Francis , Warner Losh , Paolo Bonzini , Aurelien Jarno , Beraldo Leal , =?UTF-8?q?Daniel=20P=2E=20Berrang=C3=A9?= , Max Filippov , =?UTF-8?q?Alex=20Benn=C3=A9e?= , Ed Maste , Palmer Dabbelt , Li-Wen Hsu , Laurent Vivier , Kyle Evans , Wainer dos Santos Moschetta , Riku Voipio , Fabiano Rosas , Andrea Bolognani Subject: [PATCH v2 01/14] tests/docker: Add sqlite3 module to openSUSE Leap container Date: Wed, 7 Feb 2024 16:37:59 +0000 Message-Id: <20240207163812.3231697-2-alex.bennee@linaro.org> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20240207163812.3231697-1-alex.bennee@linaro.org> References: <20240207163812.3231697-1-alex.bennee@linaro.org> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=2a00:1450:4864:20::330; envelope-from=alex.bennee@linaro.org; helo=mail-wm1-x330.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZohoMail-DKIM: pass (identity @linaro.org) X-ZM-MESSAGEID: 1707323987613100005 From: Fabiano Rosas Avocado needs sqlite3: Failed to load plugin from module "avocado.plugins.journal": ImportError("Module 'sqlite3' is not installed. Use: sudo zypper install python311 to install it") >From 'zypper info python311': "This package supplies rich command line features provided by readline, and sqlite3 support for the interpreter core, thus forming a so called "extended" runtime." Include the appropriate package in the lcitool mappings which will guarantee the dockerfile gets properly updated when lcitool is run. Also include the updated dockerfile. Signed-off-by: Fabiano Rosas Suggested-by: Andrea Bolognani Reviewed-by: Philippe Mathieu-Daud=C3=A9 Message-Id: <20240117164227.32143-1-farosas@suse.de> Signed-off-by: Alex Benn=C3=A9e --- tests/docker/dockerfiles/opensuse-leap.docker | 1 + tests/lcitool/mappings.yml | 4 ++++ tests/lcitool/projects/qemu.yml | 1 + 3 files changed, 6 insertions(+) diff --git a/tests/docker/dockerfiles/opensuse-leap.docker b/tests/docker/d= ockerfiles/opensuse-leap.docker index dc0e36ce488..cf753383a45 100644 --- a/tests/docker/dockerfiles/opensuse-leap.docker +++ b/tests/docker/dockerfiles/opensuse-leap.docker @@ -90,6 +90,7 @@ RUN zypper update -y && \ pcre-devel-static \ pipewire-devel \ pkgconfig \ + python311 \ python311-base \ python311-pip \ python311-setuptools \ diff --git a/tests/lcitool/mappings.yml b/tests/lcitool/mappings.yml index 0b908882f1d..407c03301bf 100644 --- a/tests/lcitool/mappings.yml +++ b/tests/lcitool/mappings.yml @@ -59,6 +59,10 @@ mappings: CentOSStream8: OpenSUSELeap15: =20 + python3-sqlite3: + CentOSStream8: python38 + OpenSUSELeap15: python311 + python3-tomli: # test using tomllib apk: diff --git a/tests/lcitool/projects/qemu.yml b/tests/lcitool/projects/qemu.= yml index 82092c9f175..149b15de57b 100644 --- a/tests/lcitool/projects/qemu.yml +++ b/tests/lcitool/projects/qemu.yml @@ -97,6 +97,7 @@ packages: - python3-pip - python3-sphinx - python3-sphinx-rtd-theme + - python3-sqlite3 - python3-tomli - python3-venv - rpm2cpio --=20 2.39.2 From nobody Tue Nov 26 12:43:47 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass(p=none dis=none) header.from=linaro.org ARC-Seal: i=1; a=rsa-sha256; t=1707324044; cv=none; d=zohomail.com; s=zohoarc; b=DxuOaUAByDvRu/PbiqHe60eEzYdCmmCoXR11i+wvMCAC0Fr1hiRrwgJP79j2iqBsI1SkyOrpwUWdkq0hohNuZCmIa0aGMVJkO5EIGDbJB2+RTiTVOm1ilhKE+ZER1gWDTs+wVcGNTL5wOB1AdIRlISw+NSLOTQPpwpHFHoYUETA= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1707324044; h=Content-Type:Content-Transfer-Encoding:Cc:Cc:Date:Date:From:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:Subject:To:To:Message-Id:Reply-To; bh=LXky2CMDdzuIC8PBdEAHx/6nddz6mi+8QtS2LPbBGiM=; b=QFDvxRkzGzrfrXOU6AHbDxU8xxBQ7isuxt6dSN2tybRCzE8BDd6ASPif6C34os93SIVEnpEufTfLrSHCObyslNichTaWRnfHWcj5ciVCmbJ6xUUPMo6TkkW7SDuRFggVqFmFVZ4TsH3Kwbes48e8OorB1BHbxzawdXAlUmOIlog= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1707324044964315.86502634543353; Wed, 7 Feb 2024 08:40:44 -0800 (PST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rXkwG-0002p2-2y; Wed, 07 Feb 2024 11:38:20 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rXkwE-0002oO-Eo for qemu-devel@nongnu.org; Wed, 07 Feb 2024 11:38:18 -0500 Received: from mail-wr1-x433.google.com ([2a00:1450:4864:20::433]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rXkwC-00066r-Pq for qemu-devel@nongnu.org; Wed, 07 Feb 2024 11:38:18 -0500 Received: by mail-wr1-x433.google.com with SMTP id ffacd0b85a97d-33aeb088324so629375f8f.2 for ; Wed, 07 Feb 2024 08:38:16 -0800 (PST) Received: from draig.lan ([85.9.250.243]) by smtp.gmail.com with ESMTPSA id d11-20020adff2cb000000b0033b278cf5fesm1852878wrp.102.2024.02.07.08.38.12 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 07 Feb 2024 08:38:13 -0800 (PST) Received: from draig.lan (localhost [IPv6:::1]) by draig.lan (Postfix) with ESMTP id 510C05F88E; Wed, 7 Feb 2024 16:38:12 +0000 (GMT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1707323895; x=1707928695; darn=nongnu.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=LXky2CMDdzuIC8PBdEAHx/6nddz6mi+8QtS2LPbBGiM=; b=NAQQcfYHLL2BKX1Gdad3Jl6EucdWuXbq/UfjbsidFzBrd1PKuGRMfjnysWETedfrUg 3Oc4fNpGRe/pMo8itUwclDP80nX8gXUg5gem3m6oJ2rE3+zwUhSOFpgZ2sGPcXaWGZol NdM0OsJLi5ekbqetvtjzZbFU0gfEVMGbihbhamKOiPdSkKrE8i0Wix3doJu4jjkgB8bS 6yqJEkWguOfuAe0KBB+BPbG5Anxseje8hEAdOWHQCc7l7f8KCQ4TRGDYhJ8wfPS1E0XO z6JA05PDz2Guw4Q6AfNQ+K6BCEsIyZBWKZzgy4ycS3xkFFA8jEx3szwy2+rCJCmckjW8 UUlg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1707323895; x=1707928695; 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=LXky2CMDdzuIC8PBdEAHx/6nddz6mi+8QtS2LPbBGiM=; b=cyVXrI9+lZJFmcDJhGPXKiRJlSBti++p2nT2bAvfBh/SFCf5b/jI1Rg+nSLeVJLwzf UOo9t4kloXV/NIQyeeyxYrloCDdfn25Zg8U8bnJiMpeBHpBlbhGZkAMw5N4N8xEZPCtv iV6tX2IAwhj9JIzSbLpgR3y93f+rmtl/Fq9ojglfvaGYcDuAr+Rnc43eAzuSRNZGMAmd HgqfHg8TIflBUikAI6+9LZ4VUprJcnmcAceRudpiIRpmfPpqdyN5gTo05XXEAMqltrey 8RfuaXaJzyoDvHob6uwgc2UaTgUNkAJVAyCTSt6QA2EYLZk72XMQAfCqnjcj4ymt/rJ5 /rOA== X-Gm-Message-State: AOJu0YxC935s2x0GoGQ2zzFZFK7Xe7dYiQmYpwssTDI2QxBneVJI8AuN D/miF4eYCFkaY2QXhSX7RWj/5q9IVI0IUqn+krByrKDoFT3PDMACuvUl4P8Re3M= X-Google-Smtp-Source: AGHT+IHGEvKiiXfJtsUpanJg17mF2fKs5Eih1K368Ch8Oz/fe7APF/YeZkinCz0RuMWhMjnGU/oXyQ== X-Received: by 2002:adf:cf10:0:b0:33b:10ca:d190 with SMTP id o16-20020adfcf10000000b0033b10cad190mr4595531wrj.24.1707323895429; Wed, 07 Feb 2024 08:38:15 -0800 (PST) X-Forwarded-Encrypted: i=1; AJvYcCURBABIzhGa29GJYD85vS1JlzBfwWWDBHDHNWOOt+PDigk4w90BZ3LBumxAS0OFVAuoaDI4+lsk7CucyNvPbqBGgPHFsYFinOKkl294O8mFv60MgGCuy4cfDNpwcESvls/IDaLuI0xLuZGQBlceyDOcm1BtQsPS3DwPIKG1pJsY0CKXE85vkiCOC5bpv4NqsMvXlrNiH+66D4FXPhJwcAaludYFlGuXZOBw8TS5+hXHog7Y9RvVH9w+9ELXoC1WmIsTIIes1CL2f2PVsHhPrehOAtvLgyFiLJ2TY2Au27b6J3g+JqvLZ29ub+POWomgB+PZvRRHUiSMWJiyV79xsffnIeTMqpLKA7cpDE5F4FwGPreWAvQbOuURwQGIJJt1Szu/NdSEP+c66Esr/qN5KpgFBPNDAtz2lT/9snhtUuKUZGBDouVjzKZ3L24RVJMjGPfAGsbUJIBnLdIz8UTJBulXVxcHdpkKhoCz/wU0/v8QURznRA80nUFgw+iTHn8HJXQ+GALLM6tJtV6J3Eq1FOR6CBYU8TDS5Ice2wJYpkCDnciaCM8auI6l87jUoAKQ9ijqTHUjyOIuJb/fnbF5oHr/NTGKJENwmXEqPi2JCDMfzZHw7tC3nAxnjspSOP4VmYMenExo7E9CqLgFJ6OfWMMXy+uUSZIoeiPjYfH9aXhr0iVCaPTp6xPhD0ekVcwPDdT4Ju7JZ2HrqpS+p0WCKKGRKcWIioHe+C+jF7GnI/U7wwvYe604yr8Fu/G6KWhADhDIp7olwjkaVRbtCIMzmVry3dZKHrQcfb01tIExhqMdxWWhgKVOoteIuxjpO6C3GNgjB/GfazFo1yAIcZE4dgqfXCDvW2sOAczAePfKxKSSoNi6AC6DpL6QxjaITmtrmNZYo2pC From: =?UTF-8?q?Alex=20Benn=C3=A9e?= To: qemu-devel@nongnu.org Cc: devel@lists.libvirt.org, Jiaxun Yang , Daniel Henrique Barboza , Chris Wulff , Weiwei Li , Bin Meng , Thomas Huth , qemu-riscv@nongnu.org, Marek Vasut , Liu Zhiwei , Aleksandar Rikalo , =?UTF-8?q?Marc-Andr=C3=A9=20Lureau?= , =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= , Alistair Francis , Warner Losh , Paolo Bonzini , Aurelien Jarno , Beraldo Leal , =?UTF-8?q?Daniel=20P=2E=20Berrang=C3=A9?= , Max Filippov , =?UTF-8?q?Alex=20Benn=C3=A9e?= , Ed Maste , Palmer Dabbelt , Li-Wen Hsu , Laurent Vivier , Kyle Evans , Wainer dos Santos Moschetta , Riku Voipio , Rabin Vincent , "Edgar E . Iglesias" Subject: [PATCH v2 02/14] docs: mark CRIS support as deprecated Date: Wed, 7 Feb 2024 16:38:00 +0000 Message-Id: <20240207163812.3231697-3-alex.bennee@linaro.org> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20240207163812.3231697-1-alex.bennee@linaro.org> References: <20240207163812.3231697-1-alex.bennee@linaro.org> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=2a00:1450:4864:20::433; envelope-from=alex.bennee@linaro.org; helo=mail-wr1-x433.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZohoMail-DKIM: pass (identity @linaro.org) X-ZM-MESSAGEID: 1707324045843100007 This might be premature but while streamlining the avocado tests I realised the only tests we have are "check-tcg" ones. The ageing fedora-cris-cross image works well enough for developers but can't be used in CI as we need supported build platforms to build QEMU. Does this mean the writing is on the wall for this architecture? Signed-off-by: Alex Benn=C3=A9e Cc: Rabin Vincent Reviewed-by: Thomas Huth Acked-by: Edgar E. Iglesias Reviewed-by: Thomas Huth Message-Id: <20230925144854.1872513-5-alex.bennee@linaro.org> --- docs/about/deprecated.rst | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/docs/about/deprecated.rst b/docs/about/deprecated.rst index d4492b94604..82922476d72 100644 --- a/docs/about/deprecated.rst +++ b/docs/about/deprecated.rst @@ -183,6 +183,14 @@ Nios II CPU (since 8.2) The Nios II architecture is orphan. The ``nios2`` guest CPU support is deprecated and will be removed in a future version of QEMU. =20 +CRIS CPU architecture (since 9.0) +''''''''''''''''''''''''''''''''' + +The CRIS architecture was pulled from Linux in 4.17 and the compiler +is no longer packaged in any distro making it harder to run the +``check-tcg`` tests. Unless we can improve the testing situation there +is a chance the code will bitrot without anyone noticing. + =20 System emulator machines ------------------------ --=20 2.39.2 From nobody Tue Nov 26 12:43:47 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass(p=none dis=none) header.from=linaro.org ARC-Seal: i=1; a=rsa-sha256; t=1707324025; cv=none; d=zohomail.com; s=zohoarc; b=NhtOzGrwjmoGJcCv2rAT95qwQgjxiO61GJPMB0TuIB1lNTOa7MQEh2rbJ7fwNN3tnGCcPWs3LmN6MEs1xXjf7Hv5TW/tGmed30URv++knkJtXtTfREoZ28oBTDZeMXJ2DJStf+IuxobhM90sxMuSIbiwBnBCKPcY20gTuDvLUk4= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1707324025; h=Content-Type:Content-Transfer-Encoding:Cc:Cc:Date:Date:From:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:Subject:To:To:Message-Id:Reply-To; bh=4XrdlyPxX7fzqYNhg32fjbzatjpy7oOVQl+tyM0KqaA=; b=k9tWaBlSvRtbx1rVmv1Fs/2W+t6C/X/4qAhHBNOFCzyHnQHj9Hjhwu6eRBaW+RW6P/6K0natKXI+HnzGoKUdPasNLgcn2ZGraoEoggQQST3ct4XAjDYvaNx9BwIHy57l4ZkVBWZvMkuvUQWWiK1C9hQYZGnxlVRNXGdXv75pCHE= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1707324025379882.9240285666531; Wed, 7 Feb 2024 08:40:25 -0800 (PST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rXkwL-0002sl-22; Wed, 07 Feb 2024 11:38:25 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rXkwI-0002pf-M6 for qemu-devel@nongnu.org; Wed, 07 Feb 2024 11:38:22 -0500 Received: from mail-wm1-x334.google.com ([2a00:1450:4864:20::334]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rXkwE-00067K-OK for qemu-devel@nongnu.org; Wed, 07 Feb 2024 11:38:22 -0500 Received: by mail-wm1-x334.google.com with SMTP id 5b1f17b1804b1-40fe3141e1cso8096905e9.0 for ; Wed, 07 Feb 2024 08:38:18 -0800 (PST) Received: from draig.lan ([85.9.250.243]) by smtp.gmail.com with ESMTPSA id p22-20020a05600c359600b0040ffe1ca25bsm2621888wmq.21.2024.02.07.08.38.12 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 07 Feb 2024 08:38:13 -0800 (PST) Received: from draig.lan (localhost [IPv6:::1]) by draig.lan (Postfix) with ESMTP id 6709C5F890; Wed, 7 Feb 2024 16:38:12 +0000 (GMT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1707323897; x=1707928697; darn=nongnu.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=4XrdlyPxX7fzqYNhg32fjbzatjpy7oOVQl+tyM0KqaA=; b=snotOtLvwVpKbWPhm7wpatKLekwNvlVPtoYKSumMcrk+pBT4HZoElHixY+sDIio6sk QnG2BGi4uYqeGxNlYT+6hiC5qdI+iaVg3kIBkZID22k0/nI6nTSPLpari4EoTz4w04yy JLq9QxYNkt0sGli1lt5yDZxoO9ubF4aVzfQksEUXNtg5Zy8XkEPZFymzQ1ED3L9VfTOd mRgCBhT9D9vc8vqgLDpxC+6NQhV/Rs5lXFTMx6MUSGhN9qQiSRSGua9eE+Uggp8lhbbO yBGm0MyW7HLMZBEayr2MDgNz2hPyoAb5IEx7QBfKOwKWTcaDp//OJviUlzy3rM19T1tQ 1ciA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1707323897; x=1707928697; 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=4XrdlyPxX7fzqYNhg32fjbzatjpy7oOVQl+tyM0KqaA=; b=YrKmQOHl0sTJn6oibELSsZyyI8rkwO/meeg+gw4aiIXGmIFS5wtnjPLAUpfXg+a1qb zoheXY2PObGpnDYU/aMNA8KnNlvKzq/VB5poBM8BkwdSV5/Q7ypWlD92JB4u6uLN4JYS JD2FQ/LxROfi16QmQobsnV8cwOnbc8PAPW8F0V3/3hugMNGgJTjOsD1VkvpHGM33vNI+ Cb+3DvTTxSzj4hBXNfadoDytUw8MPq1/EEfsCSgL0F4vH/0Mn3MuOuDR/4gvCypmSE8N iHmD7ZX/95KqBGtwfSy4rnPFlvhLR7MUHsz5e/Z2pyyi3aAw3JV0I1IN/slTJXpIg0k4 xrGA== X-Gm-Message-State: AOJu0YyjfZazj3CanwOnFBobdD96TVRl/TPjPtWg58wlpdKLkfUKHEq9 +ZSM9McTHUGcMuJLz0HaoRJTHz0qc3LEd5k8X9tg3Ef7aVDQtpjJWi3tcRxRyag= X-Google-Smtp-Source: AGHT+IFQGxvwZitCIjiQ+EVKzNxoWSscx1eHsi9FZHJMvO9a1UWD6FjNkLw5mRtQ0nFveN87wXl8Rg== X-Received: by 2002:a05:600c:a08:b0:40e:fb8f:debe with SMTP id z8-20020a05600c0a0800b0040efb8fdebemr4884119wmp.38.1707323897182; Wed, 07 Feb 2024 08:38:17 -0800 (PST) X-Forwarded-Encrypted: i=1; AJvYcCXyZ5+acAuDUHb7TgMFnMsuwKsw3ljUwkqM34AK+NfpZnr7sWoJ37vTqNMlT1oRbxzAZOXObeySLPXnLBK7+4hzxOGV2pbYvkRU+sowfGEvZbY6aqidNUk8fVvW2KQGFs3kKfE6p/sY1/2l5mzRGqbhjAj21EMKolfmnAIPcYVXX8VZO/XbsJOc3cIQNYZFzw6rkI63QKcaSHkdLMvfLUIGi9pRbvmSCvYSsRlihLYfCv3WaWJ6jS3bQKc64tmMfPjmU+0bqWOIq+I3IHi7Rojsc5T4rHxJ74mWv6AuGsoJw+/rnonLz5Oo9zxHmv6NrT9t6LeC4mM2u4DoBYu/6aCCH5px7EbarTR8XqjuWUgn7rfGwCWyUuZajUNE+osp+wqcMkrgTDL2ABxQR548Tmnxxps3NRqiiC/xfL/a3yMzM636ZaI13s4luhrUDNuR6FY7gJXAvzl30CyFgmiiZK3I+LHmic0L6m6Bnn/EeaYhGr+MekZ3bjWr9Mq4Pyl/MdeO7nCThrQ4ApEctS2cTBexPqPptuap2rJZWGDBX7xGUpB48c/KrYFxrI4wWFOhXbJOvk2uQNtTjUtMNoRQas/h8l4HXXKEb30Vr4FlN5MCDmWBB2nIUMcvM2GqDtSGxp/40tV0lZ24FdgRHkOAoK5NvCOjiHotlyip61IC5ouFPjAt+OlmDaAVUDDh7aEET9fF0NhPw9SkSTu51am1736A44qTe7P8u/zqTDe+1NepefJO+stZyz/AvkJuM2QZm92D1oZ+VAfmIl8uXxxBZivTK2jqRJ5Opag2YoPl7tbEO+7kRSi+deJudFTkqWFlpeb2p1j9NVayvws= From: =?UTF-8?q?Alex=20Benn=C3=A9e?= To: qemu-devel@nongnu.org Cc: devel@lists.libvirt.org, Jiaxun Yang , Daniel Henrique Barboza , Chris Wulff , Weiwei Li , Bin Meng , Thomas Huth , qemu-riscv@nongnu.org, Marek Vasut , Liu Zhiwei , Aleksandar Rikalo , =?UTF-8?q?Marc-Andr=C3=A9=20Lureau?= , =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= , Alistair Francis , Warner Losh , Paolo Bonzini , Aurelien Jarno , Beraldo Leal , =?UTF-8?q?Daniel=20P=2E=20Berrang=C3=A9?= , Max Filippov , =?UTF-8?q?Alex=20Benn=C3=A9e?= , Ed Maste , Palmer Dabbelt , Li-Wen Hsu , Laurent Vivier , Kyle Evans , Wainer dos Santos Moschetta , Riku Voipio Subject: [PATCH v2 03/14] configure: run plugin TCG tests again Date: Wed, 7 Feb 2024 16:38:01 +0000 Message-Id: <20240207163812.3231697-4-alex.bennee@linaro.org> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20240207163812.3231697-1-alex.bennee@linaro.org> References: <20240207163812.3231697-1-alex.bennee@linaro.org> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=2a00:1450:4864:20::334; envelope-from=alex.bennee@linaro.org; helo=mail-wm1-x334.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=unavailable autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZohoMail-DKIM: pass (identity @linaro.org) X-ZM-MESSAGEID: 1707324025789100007 From: Paolo Bonzini Commit 39fb3cfc28b ("configure: clean up plugin option handling", 2023-10-1= 8) dropped the CONFIG_PLUGIN line from tests/tcg/config-host.mak, due to confu= sion caused by the shadowing of $config_host_mak. However, TCG tests were still expecting it. Oops. Put it back, in the meanwhile the shadowing is gone so it's clear that it g= oes in the tests/tcg configuration. Cc: Fixes: 39fb3cfc28b ("configure: clean up plugin option handling", 2023-10-1= 8) Signed-off-by: Paolo Bonzini Message-Id: <20240124115332.612162-1-pbonzini@redhat.com> Signed-off-by: Alex Benn=C3=A9e --- configure | 3 +++ 1 file changed, 3 insertions(+) diff --git a/configure b/configure index 3d8e24ae011..ff058d6c486 100755 --- a/configure +++ b/configure @@ -1644,6 +1644,9 @@ fi mkdir -p tests/tcg echo "# Automatically generated by configure - do not modify" > tests/tcg/= $config_host_mak echo "SRC_PATH=3D$source_path" >> tests/tcg/$config_host_mak +if test "$plugins" =3D "yes" ; then + echo "CONFIG_PLUGIN=3Dy" >> tests/tcg/$config_host_mak +fi =20 tcg_tests_targets=3D for target in $target_list; do --=20 2.39.2 From nobody Tue Nov 26 12:43:47 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass(p=none dis=none) header.from=linaro.org ARC-Seal: i=1; a=rsa-sha256; t=1707323960; cv=none; d=zohomail.com; s=zohoarc; b=M2gKglTp+nkVPqt1LuaD9ht5mNdpQQ5f+CKq2Ys70Avs+174VDgHQ0HyIOmsLODos/8VBHsnhz/3uZyMnuUARZ3LZscswO62LMU4ZIg/kyZlPLI0nJR+d4T2kvbCCWo/T1hqYJnhKNI/L6QgWBBnOzMVGFvcw7hArkw7ynJJxns= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1707323960; h=Content-Type:Content-Transfer-Encoding:Cc:Cc:Date:Date:From:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:Subject:To:To:Message-Id:Reply-To; bh=al2EF5joR1GpZYix/IJ7sorp1km6Nnx+serOjQtc33w=; b=mJQ4nN4hGtx3L8NZ6fxsvP7DYjIFV2fnwMQ2PZdAOseJk6vSvTCaITtZYpsRL0sskvlDDaD6QoNosW5B/ZqRAsH0PDHc/xJJu0bZOThaF8SWbO+hy8nU/XadyLIfCIZkC+LQiFDDdLJ8re6ctMhPKG6Yyifg9MF1Sqla/5BK/zo= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1707323960975530.7104918186508; Wed, 7 Feb 2024 08:39:20 -0800 (PST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rXkwJ-0002r6-Im; Wed, 07 Feb 2024 11:38:24 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rXkwH-0002pQ-Ln for qemu-devel@nongnu.org; Wed, 07 Feb 2024 11:38:21 -0500 Received: from mail-wm1-x333.google.com ([2a00:1450:4864:20::333]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rXkwE-00067G-Cr for qemu-devel@nongnu.org; Wed, 07 Feb 2024 11:38:21 -0500 Received: by mail-wm1-x333.google.com with SMTP id 5b1f17b1804b1-4101d096c92so4429365e9.1 for ; Wed, 07 Feb 2024 08:38:17 -0800 (PST) Received: from draig.lan ([85.9.250.243]) by smtp.gmail.com with ESMTPSA id az2-20020a05600c600200b00410141aa57csm2062945wmb.15.2024.02.07.08.38.12 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 07 Feb 2024 08:38:13 -0800 (PST) Received: from draig.lan (localhost [IPv6:::1]) by draig.lan (Postfix) with ESMTP id 7A6545F895; Wed, 7 Feb 2024 16:38:12 +0000 (GMT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1707323897; x=1707928697; darn=nongnu.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=al2EF5joR1GpZYix/IJ7sorp1km6Nnx+serOjQtc33w=; b=N+kFrznvTJ0P9ZboHnXtaevVALylMSNP24w386OGQE+l3iK6kH3jvDND58pQkemXD0 a+GoRlPmPN07imDVS90HOho+O3UdnuIfGczSDciXexfPguAVP/Gbd8jNI7CiuuUlpaC6 rtFDbQs3FQeBNND6Bnt32VlVXThcQ0BPlXDHTj8F66R5qvjErPqOVRA4fyuP2QqBfeNo LoVkw0rVcXMLpqXRLnOJuDRVHi9D3bB+OvHbMMNCzqeuIitE6A7NAKJqXbCy1SaX5cR1 5ly7UNsiDcxJfg4jkKNJXZIgNJYZxLKlIfQOduwbXnJYldB7Edb6BDqIWW1s+WjIsh+r rQMA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1707323897; x=1707928697; 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=al2EF5joR1GpZYix/IJ7sorp1km6Nnx+serOjQtc33w=; b=GGvcpTemdTbemJhzqwSmH/SEzqQDYML9aTFa4WZrvM0dpaAe2G2qSXoYDbDJ9W/r0P 3B69I6D/2pE9iEfgyU4E+UF17kPANRjs50ukn7qUaRXH81kxKt9+1zmo44Ur+UP0MiP8 evidrwoUKtyrbPGZtvrbtuwdv0PRX6kvh3ljE01b7saVLeCCgyjbXYfC9WNUkTzMjwZi Ui0zzKD5OPszsNsPN/hRXP2FZjvAq2erMMF2FkpFWKk4au0avGk/z4lDQvr+ZTupwF2a vrgnl8wHw/l5b9w2BS6OjthmMgTq+JpchUoFi0J9noDRDwXP9LhnplGScYPfr2qeECql w0vg== X-Gm-Message-State: AOJu0YwCzNcM73ga5dGZRN8IprctjfMdRC+ewmiXDmKThHuXNnJ0ecfv Rv1Sky1ddQ8+4X45nfl4r74D8pKpqei/s59eRwTAIciNUEOwZcKY7ZHisAxGirw= X-Google-Smtp-Source: AGHT+IEllApoBVS2Af8bGtwiTxz/SrARQDrYzHCX+zMsLKLvVQIjfNdJUEgGbhM6ZEDvEQgUjp9vOQ== X-Received: by 2002:a5d:6703:0:b0:33b:1ae4:10b1 with SMTP id o3-20020a5d6703000000b0033b1ae410b1mr3549305wru.47.1707323896841; Wed, 07 Feb 2024 08:38:16 -0800 (PST) X-Forwarded-Encrypted: i=1; AJvYcCU4pOfHiiGwCo4OdHghcmtkfTz/YfCpp7vi1P0k0xuEn7MMyfZkDp5SuiQyA+Dalk1TdFnzHYKAox7Cy2JBgUZvuV7AZWigReJq216WwBzezxWAcZ9bhnJQRXY2r0SV3mP8Tdnhel2lFPGIg2QKfsoGxAX6bATIC7y+sY9yBvBzKf8e/0ixlUCJFHy2ET3h4d9K4yPGT+UlK5zEtL3cEY0lRAFrRNFSNAEkudXO0jP81UW4Zl2AhKcYL6trJCRRZsToazF0RfHIgM+0nifwnqbafeCwP8Q+icMq2dVZkrxchd8ENxvMq3gtJWLuWTWIR0JNrfgc7BuLg4iQEYhNDmsRkTBnC6lqKreHleXYUqIkuoO17HJqdfmypDi+GS61iYaGNm6QSX95W4vqYBgJMLw1ukGO2Ziq3+aGhI+imBOSZ8HdelrkoaPUfJ/G2LGEGqCGLhvJk0RsOWyf8rUYpNr4E5VqVSNYF8rS7HI6wFQASzJeiVWZHPg2nrSjR+2USFDTG8FhgsMl/oWzZ2At9aXfcqxrwy9JRw9S71iJpLlNI6r1wkTvYKpgdcb3loyeVSRdBF9wk5mVZcMUCNprRJ7n6+OQbwWezf0y3wM7TNy6UYvOeKNQOSY8M76BnlFCy3Wfd0jYtU47cp02K7Vk1fw6bPr44uKVeyZQlwXfZFidPwYQESasogOqF1TYk/R/tCiAz4xyHqahKHEwaxfSwq7EGp5ChGqGqv8PakDLFUbxjElwOLUZ8halcTPZ2Fh72XskZVGrX/coi08kcBIduLGN3gKulq+c3/782DnwQc0MeM1LAPV+uT+DdlDYBBmjUDooTTp6Uu9WTxk= From: =?UTF-8?q?Alex=20Benn=C3=A9e?= To: qemu-devel@nongnu.org Cc: devel@lists.libvirt.org, Jiaxun Yang , Daniel Henrique Barboza , Chris Wulff , Weiwei Li , Bin Meng , Thomas Huth , qemu-riscv@nongnu.org, Marek Vasut , Liu Zhiwei , Aleksandar Rikalo , =?UTF-8?q?Marc-Andr=C3=A9=20Lureau?= , =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= , Alistair Francis , Warner Losh , Paolo Bonzini , Aurelien Jarno , Beraldo Leal , =?UTF-8?q?Daniel=20P=2E=20Berrang=C3=A9?= , Max Filippov , =?UTF-8?q?Alex=20Benn=C3=A9e?= , Ed Maste , Palmer Dabbelt , Li-Wen Hsu , Laurent Vivier , Kyle Evans , Wainer dos Santos Moschetta , Riku Voipio Subject: [PATCH v2 04/14] Revert "hw/elf_ops: Ignore loadable segments with zero size" Date: Wed, 7 Feb 2024 16:38:02 +0000 Message-Id: <20240207163812.3231697-5-alex.bennee@linaro.org> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20240207163812.3231697-1-alex.bennee@linaro.org> References: <20240207163812.3231697-1-alex.bennee@linaro.org> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=2a00:1450:4864:20::333; envelope-from=alex.bennee@linaro.org; helo=mail-wm1-x333.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZohoMail-DKIM: pass (identity @linaro.org) X-ZM-MESSAGEID: 1707323961521100001 This regressed qemu-system-xtensa: TEST test_load_store on xtensa qemu-system-xtensa: Some ROM regions are overlapping These ROM regions might have been loaded by direct user request or by def= ault. They could be BIOS/firmware images, a guest kernel, initrd or some other = file loaded into guest memory. Check whether you intended to load all this guest code, and whether it ha= s been built to load to the correct addresses. The following two regions overlap (in the memory address space): test_load_store ELF program header segment 1 (addresses 0x0000000000001= 000 - 0x0000000000001f26) test_load_store ELF program header segment 2 (addresses 0x0000000000001= ab8 - 0x0000000000001ab8) make[1]: *** [Makefile:187: run-test_load_store] Error 1 This reverts commit 62570f1434160d356311e1c217537e24a4ac85cd. Message-Id: <20240201122835.1712347-5-alex.bennee@linaro.org> Reviewed-by: Thomas Huth Signed-off-by: Alex Benn=C3=A9e --- include/hw/elf_ops.h | 75 +++++++++++++++++++++----------------------- 1 file changed, 36 insertions(+), 39 deletions(-) diff --git a/include/hw/elf_ops.h b/include/hw/elf_ops.h index 3e966ddd5a1..9c35d1b9da6 100644 --- a/include/hw/elf_ops.h +++ b/include/hw/elf_ops.h @@ -427,16 +427,6 @@ static ssize_t glue(load_elf, SZ)(const char *name, in= t fd, file_size =3D ph->p_filesz; /* Size of the allocated data */ data_offset =3D ph->p_offset; /* Offset where the data is loca= ted */ =20 - /* - * Some ELF files really do have segments of zero size; - * just ignore them rather than trying to set the wrong addr, - * or create empty ROM blobs, because the zero-length blob can - * falsely trigger the overlapping-ROM-blobs check. - */ - if (mem_size =3D=3D 0) { - continue; - } - if (file_size > 0) { if (g_mapped_file_get_length(mapped_file) < file_size + data_offset) { @@ -540,38 +530,45 @@ static ssize_t glue(load_elf, SZ)(const char *name, i= nt fd, *pentry =3D ehdr.e_entry - ph->p_vaddr + ph->p_paddr; } =20 - if (load_rom) { - g_autofree char *label =3D - g_strdup_printf("%s ELF program header segment %d", - name, i); - - /* - * rom_add_elf_program() takes its own reference to - * 'mapped_file'. - */ - rom_add_elf_program(label, mapped_file, data, file_size, - mem_size, addr, as); - } else { - MemTxResult res; - - res =3D address_space_write(as ? as : &address_space_memor= y, - addr, MEMTXATTRS_UNSPECIFIED, - data, file_size); - if (res !=3D MEMTX_OK) { - goto fail; - } - /* - * We need to zero'ify the space that is not copied - * from file - */ - if (file_size < mem_size) { - res =3D address_space_set(as ? as : &address_space_mem= ory, - addr + file_size, 0, - mem_size - file_size, - MEMTXATTRS_UNSPECIFIED); + /* Some ELF files really do have segments of zero size; + * just ignore them rather than trying to create empty + * ROM blobs, because the zero-length blob can falsely + * trigger the overlapping-ROM-blobs check. + */ + if (mem_size !=3D 0) { + if (load_rom) { + g_autofree char *label =3D + g_strdup_printf("%s ELF program header segment %d", + name, i); + + /* + * rom_add_elf_program() takes its own reference to + * 'mapped_file'. + */ + rom_add_elf_program(label, mapped_file, data, file_siz= e, + mem_size, addr, as); + } else { + MemTxResult res; + + res =3D address_space_write(as ? as : &address_space_m= emory, + addr, MEMTXATTRS_UNSPECIFIED, + data, file_size); if (res !=3D MEMTX_OK) { goto fail; } + /* + * We need to zero'ify the space that is not copied + * from file + */ + if (file_size < mem_size) { + res =3D address_space_set(as ? as : &address_space= _memory, + addr + file_size, 0, + mem_size - file_size, + MEMTXATTRS_UNSPECIFIED); + if (res !=3D MEMTX_OK) { + goto fail; + } + } } } =20 --=20 2.39.2 From nobody Tue Nov 26 12:43:47 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass(p=none dis=none) header.from=linaro.org ARC-Seal: i=1; a=rsa-sha256; t=1707324061; cv=none; d=zohomail.com; s=zohoarc; b=kdgVhDeSq0XPmbqTFLLb/DQ5jvlMQ1pWjcVk68WPp1gzK6/VSMLVLA6BvfjHMtDJy4pfZHiaxYew5mmnujppd5PzsuoRzIyRi8VcTgcUq1YmUGGu8Eah4jrmypypyItXiV1TwnjsFKprF5+1OEXJEHKDF0lXGrADHBeRm+5Dvig= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1707324061; h=Content-Type:Content-Transfer-Encoding:Cc:Cc:Date:Date:From:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:Subject:To:To:Message-Id:Reply-To; bh=7r6TD7yChzqzHwHFrhbxu1OMWzC/pBSk9CaZVccyvoc=; b=jwOR++2EH4n8mnvL9c2kPdidPQutNPeikdOKD2E9n0CMLDMBJ1aPleNxDgW2aEazq6LosyJDAfa+BBa0eIHxQfJSh/gU2Aoxm/T2apUdPqGDNbzZTM43OLw1OCD5YQItk6p28TqxuEEBLVP7A4XM63jfVhSrsoeWThaDIq91MAk= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1707324061578863.820667783305; Wed, 7 Feb 2024 08:41:01 -0800 (PST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rXkwK-0002sA-Ba; Wed, 07 Feb 2024 11:38:24 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rXkwJ-0002q4-0B for qemu-devel@nongnu.org; Wed, 07 Feb 2024 11:38:23 -0500 Received: from mail-wm1-x32b.google.com ([2a00:1450:4864:20::32b]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rXkwG-00067i-7x for qemu-devel@nongnu.org; Wed, 07 Feb 2024 11:38:22 -0500 Received: by mail-wm1-x32b.google.com with SMTP id 5b1f17b1804b1-40fc6578423so7467315e9.0 for ; Wed, 07 Feb 2024 08:38:19 -0800 (PST) Received: from draig.lan ([85.9.250.243]) by smtp.gmail.com with ESMTPSA id m14-20020a05600c3b0e00b004100826da82sm2653264wms.21.2024.02.07.08.38.13 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 07 Feb 2024 08:38:17 -0800 (PST) Received: from draig.lan (localhost [IPv6:::1]) by draig.lan (Postfix) with ESMTP id 8F7AA5F8DA; Wed, 7 Feb 2024 16:38:12 +0000 (GMT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1707323898; x=1707928698; darn=nongnu.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=7r6TD7yChzqzHwHFrhbxu1OMWzC/pBSk9CaZVccyvoc=; b=D0d76ixfydzCvymGynM4XSeC/0Wr35r779jBaRwDgQuzgPaugYpmhsOwAM1ajh0Qm7 YzgwGdAabvggaKK4uXEutdysALzzt29sUlg21F6pwohiA1ohmuvmOtodQM9/iQi88d+2 q/aB9R1dvBkka6410p/DaEFi+7xi38Lqi3IIfhUk6RMHSLFrXLqlLNDx05tBfdbyeyZX NpY/dVI3W6we2/O4RxnglDSn+pTYGVsHKYUjgENItTm8vZ62WMXEP+WwGsKp0fFPPfpO ECkIvZt74vY6PKBToTb6I1JQ/k7K8KehOl8KVSHk80B0938gW6ZqvsrpFyY7mSmb04eY 2Y5A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1707323898; x=1707928698; 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=7r6TD7yChzqzHwHFrhbxu1OMWzC/pBSk9CaZVccyvoc=; b=wlTcgluXIkoHiQTHTASLiO0NiYw5JytGCRh0cZ04sQM48sii6g/r1ywVGWA0uS0FNG EPb+LwA8dw5WEiSIySzxtf9rZoQGUKWT/EOzi9xb3BMquewCD1E85DzlAdk4Lgg8xOk8 PmQzUONolYIBkewRdDYxhZaxVvb1bQh4uLB5BowfaiTRuPg1rkQSZkzqdMV8+8wcYpIC A9S49CCK3PGrKBaN+M4zifJbWK+NGnqVrnHU5XBPe0qallPXS+Fiil9hgXyybIzZ49y1 Bmmzu1tzcwBVnX3dX1KjzPIiXFQGrwA8ovhMiI2Mrtzg8+DfM00tsgTUcZ2GSKxkmp2c KyAQ== X-Gm-Message-State: AOJu0YwYZbpx31XORdTgJ8dTf0ofir4RtHwCcO+P2aVq3skbakz6JSi/ HCV1oUhhY0WVphNRCmTPZlgpmejnW+SdrkBpPrF+4vBfYwUUV/4FAUjeCC7FzRU= X-Google-Smtp-Source: AGHT+IGHwl3tW2nUX2wfBLHUrlSOM6cjxqlwmBBgVdwDbJmr/R/vGDi2c3wnvq3QzxKL6BY7CYBQug== X-Received: by 2002:a05:600c:4509:b0:40e:61d4:5d3b with SMTP id t9-20020a05600c450900b0040e61d45d3bmr5501081wmo.20.1707323898707; Wed, 07 Feb 2024 08:38:18 -0800 (PST) X-Forwarded-Encrypted: i=1; AJvYcCU85CmzezWXYjs7d04q56iflk3XNrfO92Z/yFqfgWD8aHJHO0wKepHAKyLrXeM78NoyCem0hOqWjs//+iigpEwll3DGDCdotjlWHO9Vlii+1KZoYVv4UpRFTx4A9R1nWwBtPU6gkjW11JZpfg5QBcgJe/6k/KSCeNC/iTnLyYKckSeBQ4HBPXTiueMLYb9mXjJhcR08zAVu9VQxQp4UkWD/Xmmx0pjD+hoCVsRyIkIcFpuuK7pZVh3pUSkzB7MeuCtIQPARuUOrv4Krsd7lbteVU5RKdCfZF1q2ZAB0/lUlAQM68BJ6yfqiKfguHEjv5H6v1K5vzuLBzuwVT7Fk8iQQGYB8d7RMIFQ42UGsF3eUJCGD0Fz7MqH/+nhApqx4R6q2CMxmsOY/Lln/3x46LUWky2QZYHduRTqcBgkrUnLALtczONlSCTSdAYDy43qlUacDkffDWuflJ/HDF8LzeGvOqlArR9A13QYSQRuVgNGRgmBmIU2et8X6Q1qrKoJyJ1xZ27+fdqzaRMHwb85Pc2Z/g5KF6w15ZAzvFGzkzkMaDqFdPISrK5NpaGsHUC2YvZzzrJ/P6hHgYj+NzcGVT0mGSpUlzBPPP5kOpByjGwBfDGAzacgRz00mH+/E5QZrAIin44MdlWRsuBR0NGXi2EhjfLgRpfXNK6g1Ju5cyXCbfdmi3dmu8ldCMNNuL0P2c1uwLAthHHpcXA6uDiewoiFDufeM/G6Gnea/RyV9lXjjx7Xw8TxSKgQsbLrQHw4TBTVG4gOVTpoXlrE8ZiXUKZLj5FEnzYe5m4JHpWdhXJ7MPZgECXZFVgEP9aImd0lCwLjtf2hMMjLQW71uDBcRTCMdlG2MjzdGj8XHOg3c From: =?UTF-8?q?Alex=20Benn=C3=A9e?= To: qemu-devel@nongnu.org Cc: devel@lists.libvirt.org, Jiaxun Yang , Daniel Henrique Barboza , Chris Wulff , Weiwei Li , Bin Meng , Thomas Huth , qemu-riscv@nongnu.org, Marek Vasut , Liu Zhiwei , Aleksandar Rikalo , =?UTF-8?q?Marc-Andr=C3=A9=20Lureau?= , =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= , Alistair Francis , Warner Losh , Paolo Bonzini , Aurelien Jarno , Beraldo Leal , =?UTF-8?q?Daniel=20P=2E=20Berrang=C3=A9?= , Max Filippov , =?UTF-8?q?Alex=20Benn=C3=A9e?= , Ed Maste , Palmer Dabbelt , Li-Wen Hsu , Laurent Vivier , Kyle Evans , Wainer dos Santos Moschetta , Riku Voipio , Ilya Leoshkevich Subject: [PATCH v2 05/14] tests/vm: Set UseDNS=no in the sshd configuration Date: Wed, 7 Feb 2024 16:38:03 +0000 Message-Id: <20240207163812.3231697-6-alex.bennee@linaro.org> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20240207163812.3231697-1-alex.bennee@linaro.org> References: <20240207163812.3231697-1-alex.bennee@linaro.org> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=2a00:1450:4864:20::32b; envelope-from=alex.bennee@linaro.org; helo=mail-wm1-x32b.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZohoMail-DKIM: pass (identity @linaro.org) X-ZM-MESSAGEID: 1707324061869100001 From: Ilya Leoshkevich make vm-build-freebsd sometimes fails with "Connection timed out during banner exchange". The client strace shows: 13:59:30 write(3, "SSH-2.0-OpenSSH_9.3\r\n", 21) =3D 21 13:59:30 getpid() =3D 252655 13:59:30 poll([{fd=3D3, events=3DPOLLIN}], 1, 5000) =3D 1 ([{fd=3D3, re= vents=3DPOLLIN}]) 13:59:32 read(3, "S", 1) =3D 1 13:59:32 poll([{fd=3D3, events=3DPOLLIN}], 1, 3625) =3D 1 ([{fd=3D3, re= vents=3DPOLLIN}]) 13:59:32 read(3, "S", 1) =3D 1 13:59:32 poll([{fd=3D3, events=3DPOLLIN}], 1, 3625) =3D 1 ([{fd=3D3, re= vents=3DPOLLIN}]) 13:59:32 read(3, "H", 1) =3D 1 There is a 2s delay during connection, and ConnectTimeout is set to 1. Raising it makes the issue go away, but we can do better. The server truss shows: 888: 27.811414714 socket(PF_INET,SOCK_DGRAM|SOCK_CLOEXEC,0) =3D 5 (0x5) 888: 27.811765030 connect(5,{ AF_INET 10.0.2.3:53 },16) =3D 0 (0x0) 888: 27.812166941 sendto(5,"\^Z/\^A\0\0\^A\0\0\0\0\0\0\^A2"...,39,0,NUL= L,0) =3D 39 (0x27) 888: 29.363970743 poll({ 5/POLLRDNORM },1,5000) =3D 1 (0x1) So the delay is due to a DNS query. Disable DNS queries in the server config. Reviewed-by: Thomas Huth Signed-off-by: Ilya Leoshkevich Message-Id: <20240206002344.12372-2-iii@linux.ibm.com> Signed-off-by: Alex Benn=C3=A9e --- tests/vm/basevm.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/tests/vm/basevm.py b/tests/vm/basevm.py index 61725b83254..c0d62c08031 100644 --- a/tests/vm/basevm.py +++ b/tests/vm/basevm.py @@ -423,6 +423,8 @@ def console_ssh_init(self, prompt, user, pw): def console_sshd_config(self, prompt): self.console_wait(prompt) self.console_send("echo 'PermitRootLogin yes' >> /etc/ssh/sshd_con= fig\n") + self.console_wait(prompt) + self.console_send("echo 'UseDNS no' >> /etc/ssh/sshd_config\n") for var in self.envvars: self.console_wait(prompt) self.console_send("echo 'AcceptEnv %s' >> /etc/ssh/sshd_config= \n" % var) --=20 2.39.2 From nobody Tue Nov 26 12:43:47 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass(p=none dis=none) header.from=linaro.org ARC-Seal: i=1; a=rsa-sha256; t=1707324024; cv=none; d=zohomail.com; s=zohoarc; b=Q0sb+uP+Fovq+d+xrhv+x7iZ4+thaFZ2mT/yqIj77zWeKbJo6iyUkHFXH1BwqN+x7sOBgK9fdpggtzurggBWPivCG0X/u4NevQloRM73hhuilorxsCfKQ1wnacsCfHdxmbalJfsPwcHqQdm2un1PhHg89Ge8MIun7x28FXrS0m8= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1707324024; h=Content-Type:Content-Transfer-Encoding:Cc:Cc:Date:Date:From:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:Subject:To:To:Message-Id:Reply-To; bh=sv6+6UUCSeP9lDN9ptL/PjxKqIdnYqTvePhCbUVP8t0=; b=bQqBTA3Yy3Gcal7bv9HXG4NU9ICCgI0j4p3XGVvcvex4Jz2ni3svPiI7OLZJIbBzMHyVftXbJlu5eZeSd4mtHS0oKzSxW3CLpLIg2r2DB7l3HKWjrDBqR8WbUNicLzDHI4JNRRr9kwaTZROeNHQyw0+syGg0kkUgNKkAqYLIEvk= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 170732402437597.39115245729852; Wed, 7 Feb 2024 08:40:24 -0800 (PST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rXkwP-0002wg-5f; Wed, 07 Feb 2024 11:38:29 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rXkwL-0002t0-Bp for qemu-devel@nongnu.org; Wed, 07 Feb 2024 11:38:25 -0500 Received: from mail-wm1-x331.google.com ([2a00:1450:4864:20::331]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rXkwH-000683-UI for qemu-devel@nongnu.org; Wed, 07 Feb 2024 11:38:25 -0500 Received: by mail-wm1-x331.google.com with SMTP id 5b1f17b1804b1-41008ab427fso7700515e9.0 for ; Wed, 07 Feb 2024 08:38:21 -0800 (PST) Received: from draig.lan ([85.9.250.243]) by smtp.gmail.com with ESMTPSA id m14-20020a05600c3b0e00b004100826da82sm2653265wms.21.2024.02.07.08.38.13 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 07 Feb 2024 08:38:17 -0800 (PST) Received: from draig.lan (localhost [IPv6:::1]) by draig.lan (Postfix) with ESMTP id A44A85F8E1; Wed, 7 Feb 2024 16:38:12 +0000 (GMT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1707323900; x=1707928700; darn=nongnu.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=sv6+6UUCSeP9lDN9ptL/PjxKqIdnYqTvePhCbUVP8t0=; b=N5jsd9Eebr4ArqWnSXBa9iaQ438x/q7V8XQAXZEXZr1qRsRkuUIT9r4XRVJRMznGpw bPYjyLsg1CPxy68OLFmbUZfkVmFW4Gxe6+kLYlRvwYnNB8/xU+S9eny/2f711ncfeZhX OdQTdY/pDa8d7npNbnbkpNrQ7FJIiozpOkWifmhYo0KiYf0aPo1KaZUXbluiF9AY9pKz NwNJ3sdF1JGfFUpZw1CtfOzMWp9afn5yYlAqN/fyXROzznq5R58r/FVV8xWV8XUIBhEm HmGWMiFk229VY1THL6xMgikWUAPzLNyYziZCJklrHnY8jawzvBuHu5UYMxq4c7Ne/t3u kvLQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1707323900; x=1707928700; 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=sv6+6UUCSeP9lDN9ptL/PjxKqIdnYqTvePhCbUVP8t0=; b=pL1DVB+CfnUWy38uYYkBSnpSXSA2xo4GQPWPwbW9WH4js1EsC44fUWh+R+Ii3yrZPg jSREkY+T+isJyEjnTo93/XU2mcEmIzRosewSeUxIt5Fq9Kk1c/4kLhsbbARSZHL/nqHD xnW9p0zKvw8NiiJ8p7EHTHYvmiqdEubLwa1PvkpKb+CTR/FZ1U4hcalLvgjZzLCrQINm WBJ4HNtK4zTRzCg6S+XLgi20KPxzBA+QIa+sxIjROu48SC2W/Gdql8zvKC/7IHQdRnvQ WLyw0imJDB0qa+wv+hSTF8pG4IpJzSmK+YG9xgX68KawX8J9T46qrSoUnT6Mo8DVJQx7 LYSQ== X-Gm-Message-State: AOJu0YyvQnKWTqJX9nBdUOiYl50VVtmrXGt/bxiu5MWOoIdRHfohWGxe 33eaXr04Tp2FW2VA8nbJoFLYNWK6eXd5oatMfv8CuYtJB0okAVQesfX4Xls5SXs= X-Google-Smtp-Source: AGHT+IELwPIEg9gWx3ouz5N0hWJp20glM2q6RyKduffMLrY91xLqU1zUfcajWqOsQhUxRG1mZbaNtw== X-Received: by 2002:a05:600c:3b97:b0:410:8f2:262a with SMTP id n23-20020a05600c3b9700b0041008f2262amr2251051wms.13.1707323900427; Wed, 07 Feb 2024 08:38:20 -0800 (PST) X-Forwarded-Encrypted: i=1; AJvYcCUc+/g0VBasm2gywElwD8kgkQjRnvf+5mxqMQ475EaW3HDaBUlVqVt7TNQPLz7Hzmn8LVcnhGm48FKUkWT9Pxg90l511VSDBEDsWrCWkasgdcXw2uF/eFqZNlY+XfQgKAolJE5FqBu5ABTssn0oGjz+Y/3BWQqkJyrVTJTXX4Z6/x/2/9KbSYmyBiz4FmqQ363UhlfE4q3VKzNNFGZzSSWtswqqFwn3goXrqLR+XbFGBizgh6JIDHcE6obEgc7AYd50t8cyQlePKyCCRUKYRdUMR2OWOZJ6r2nvtxvfmGLLEgJDuxjBfdg40MQ5MKtt4Fk0ObLAbeh34lu/Uc17ZrNsXOVWNqHFLmdrRO8w5DtLsc/Nn8uikVkWvliX33qA3FWnf/sp7FcWGluRcx/bnhE+sxNldnp25XZVgj9A0WbPFJ8+oif1EJW+MWknZ2JSXMP6whEmMxI1eu7kEpS5cfD9JqFm0Qd86btp0eO0sAPmJB1TVau8Xp+SU4Kg3Qthdrp/HNbERDE8ngelmfVlf4d0yhnrk+qzxZTcb1PvdnSZYtacNCAAdjw5kN7W96s/ufqW7xBl+oKvGLtFQvXkOlP+nsqmVkJlZLmLYTjSDf7Vxy/IYj/M7DRYIDhmxPJDy+mhxGMScrSfWL5Yb1hfbpAV7pvZcQ2GyNP7N1bzy77WybqmciVkxjq+v3OYdgSuMv8d570ta7ZkgdBHga4DqgCqhaZJxxKON5bg+JgLjED+9ws8xYElslpGRrqgPjCqHjjd3i+ieb+LyxpOSVaKpbb7Fi0K720kVgDJ9DNX71gVWGXAvsea1gYMi9KrSsOmoPOT+55TOQGpfRt7kNRixr3RZekv/ga8mFZEzZ51 From: =?UTF-8?q?Alex=20Benn=C3=A9e?= To: qemu-devel@nongnu.org Cc: devel@lists.libvirt.org, Jiaxun Yang , Daniel Henrique Barboza , Chris Wulff , Weiwei Li , Bin Meng , Thomas Huth , qemu-riscv@nongnu.org, Marek Vasut , Liu Zhiwei , Aleksandar Rikalo , =?UTF-8?q?Marc-Andr=C3=A9=20Lureau?= , =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= , Alistair Francis , Warner Losh , Paolo Bonzini , Aurelien Jarno , Beraldo Leal , =?UTF-8?q?Daniel=20P=2E=20Berrang=C3=A9?= , Max Filippov , =?UTF-8?q?Alex=20Benn=C3=A9e?= , Ed Maste , Palmer Dabbelt , Li-Wen Hsu , Laurent Vivier , Kyle Evans , Wainer dos Santos Moschetta , Riku Voipio , Ilya Leoshkevich Subject: [PATCH v2 06/14] tests/vm/freebsd: Reload the sshd configuration Date: Wed, 7 Feb 2024 16:38:04 +0000 Message-Id: <20240207163812.3231697-7-alex.bennee@linaro.org> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20240207163812.3231697-1-alex.bennee@linaro.org> References: <20240207163812.3231697-1-alex.bennee@linaro.org> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=2a00:1450:4864:20::331; envelope-from=alex.bennee@linaro.org; helo=mail-wm1-x331.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=unavailable autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZohoMail-DKIM: pass (identity @linaro.org) X-ZM-MESSAGEID: 1707324025765100005 From: Ilya Leoshkevich After console_sshd_config(), the SSH server needs to be nudged to pick up the new configs. The scripts for the other BSD flavors already do this with a reboot, but a simple reload is sufficient. Reviewed-by: Thomas Huth Signed-off-by: Ilya Leoshkevich Message-Id: <20240206002344.12372-3-iii@linux.ibm.com> Signed-off-by: Alex Benn=C3=A9e Reviewed-by: Warner Losh --- tests/vm/freebsd | 1 + 1 file changed, 1 insertion(+) diff --git a/tests/vm/freebsd b/tests/vm/freebsd index b581bd17fb7..1247f40a385 100755 --- a/tests/vm/freebsd +++ b/tests/vm/freebsd @@ -108,6 +108,7 @@ class FreeBSDVM(basevm.BaseVM): prompt =3D "root@freebsd:~ #" self.console_ssh_init(prompt, "root", self._config["root_pass"]) self.console_sshd_config(prompt) + self.console_wait_send(prompt, "service sshd reload\n") =20 # setup virtio-blk #1 (tarfile) self.console_wait(prompt) --=20 2.39.2 From nobody Tue Nov 26 12:43:47 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass(p=none dis=none) header.from=linaro.org ARC-Seal: i=1; a=rsa-sha256; t=1707324023; cv=none; d=zohomail.com; s=zohoarc; b=hynDWsp4TQ4UEs7FDIqdxCkHM0ejz4MbTAqcW/lH+ObBPFSZ4raXzIRBOb9bx20NICWgz1tB5R2AYnGIgCaXQTNXBVtm+EB2e7Jr5mBK5hU5aBs5CCj74GUMeQDWg9rNSIVVdHRqwmKdQ8FjLTaBCA5Tm6T2WNdtM78SvDiXmIw= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1707324023; h=Content-Type:Content-Transfer-Encoding:Cc:Cc:Date:Date:From:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:Subject:To:To:Message-Id:Reply-To; bh=9IbvextsUKhbDQgPyuaeoL3jSODZ/hWaknGrv+i1g18=; b=STwbBo7zhAdnjfAoFfbLufdqWQ+3aHBQlXtmZ2n04UkMqxmmsH9s+JB8s240V2toP2Q9Iul/r/ASfb0nkUJTyUH8iUdUWe95kDB6djyLwTTDzTozktSC1EUVxIoEGIPfoDVymKOwdTRbij0toa4IClvYFS5bxWglevfVNLg45z0= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1707324023793652.5402258716255; Wed, 7 Feb 2024 08:40:23 -0800 (PST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rXkwL-0002tO-Qc; Wed, 07 Feb 2024 11:38:25 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rXkwK-0002sC-H0 for qemu-devel@nongnu.org; Wed, 07 Feb 2024 11:38:24 -0500 Received: from mail-wm1-x329.google.com ([2a00:1450:4864:20::329]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rXkwG-00067n-EE for qemu-devel@nongnu.org; Wed, 07 Feb 2024 11:38:23 -0500 Received: by mail-wm1-x329.google.com with SMTP id 5b1f17b1804b1-40ffd94a707so8029125e9.1 for ; Wed, 07 Feb 2024 08:38:20 -0800 (PST) Received: from draig.lan ([85.9.250.243]) by smtp.gmail.com with ESMTPSA id w14-20020a05600c474e00b00410232ffb2csm642397wmo.25.2024.02.07.08.38.13 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 07 Feb 2024 08:38:17 -0800 (PST) Received: from draig.lan (localhost [IPv6:::1]) by draig.lan (Postfix) with ESMTP id B8E675F8E3; Wed, 7 Feb 2024 16:38:12 +0000 (GMT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1707323899; x=1707928699; darn=nongnu.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=9IbvextsUKhbDQgPyuaeoL3jSODZ/hWaknGrv+i1g18=; b=CuiGozEyOhm69oPTra3QbwGv1ujJrl7spKqq1nSc9Soav9a4jHRHJlqaBWGo9w52tu xwNgzbgaIO9v5og1jX4xokyT9SHeMFF/UvdrLDY4zLS78DkjAEBJsM3Atr3v4Iod9Esu httmM1D6pO6ISUTmPqaipHDpcVjWIzneqnPrNfdAQjWMAF3AYvAR1sOUXD42Qb/APhJV 57uxaPfYhB3aneVqtu1eMT0aONloQ95zygqGf6grqAgd4Nodf+XtZsNccGWk0aXy/2tN PT3XYD4GU503dhPQcPxniiGMMVfzJTWbYi33jbKGHsVRrztdl5SLQh65JNKXWmGdUutb 48pg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1707323899; x=1707928699; 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=9IbvextsUKhbDQgPyuaeoL3jSODZ/hWaknGrv+i1g18=; b=hIon1bFfAFiK6pFYOfr5e/D6efnkZZ3opEfT9K8vDh1NmbED6L/QhqOTh+CqMwTYEU Vu9vQbaFlRVTqh0JII2K7SjPTmMHcoqwhCzM0KII++Zz57A6+EhupL183d6MvI1a5TLI Vw1JMxYENrDRRY7cxArrfoNReTZ77zHNCyKGTn1DoW1IWmOanBkXVXqBQ/2AHLUokJ2K WMawpnNZY/m4quCQa6ii76IuWYIdfgLNsDPa9EmdUL7ZW3AQ0UqnXfkaj/Z3ggXj+4wg XNXE93vtcb2PKiPtE7itiPt3Xf7uiPCU7O+GOxTl2HgrDDNae/4vehCzf9jPscbTyDKO wPUg== X-Gm-Message-State: AOJu0YwyqypnacpFZIQ/jENRdOH9HiXHTPwpFRXw7Tzd3dwBekVQGd4x 24b7fgbQSvfb8odIGF/x4XCWnHwtewXazJC9VpxzIq2T8c+KKQm4DG4fej4e7zI= X-Google-Smtp-Source: AGHT+IFjRUT+msrD2SiPps3yoAGzJKkJykfls7gYzHMq8saSuGNCfpdBwg7XDW7/VHQ/a/4boJir1w== X-Received: by 2002:a05:600c:a08:b0:40e:fb8f:debe with SMTP id z8-20020a05600c0a0800b0040efb8fdebemr4884205wmp.38.1707323899069; Wed, 07 Feb 2024 08:38:19 -0800 (PST) X-Forwarded-Encrypted: i=1; AJvYcCUhimZaeVtx0FbFGdLUmex+udSHN5v6slNAzSoXl1zK5iRAUFOlXiGyxUEPsIAB2Iw6yrfJpfy9JuFtECw1ez1I0fM0OiUxhmSd3VsQ4a4FINLxD3LzvA5fA1t+hj0BEY8du8uGuKhPI7FhZv1gYWRBNA0gytf/ZLiiHhvuIi630KxG2wUx8oxHpTPP7yfgjuAN+lESvm3k5gMaj/V3/k/8HpebV8NR99nt8a2ZpDXFYU1JfeqQMymopOj5ui5UpnALi4+keqhcBbhDM3dVbVlWYq+MlpFJntUv6+SzSkvQq3pd0IMPH14/kYspXRxw/PDoQSYld6+FO8CQe18ThwbpgTQbS9WELPTpMxBe0/OSO8iBB0cdtPpT/9m1ce1xzOg6dVSBYwsncfpClFmb3fzcZ/VK9CUxmlD2QMDSOaehe8Oan5kePrC8ceZYrbqY4pymxdAacVIPvqhRnN1MLewenZhTCXDQ8oE7WQluSJtMCxlwoEySZWbjm2ZcOAlZyXlRF8a2bYrYhaxIcdbN17/Ptn25JYTZabClpR1woxuDKVy7F+892PF2HEOhcvjMtwys8eJOgLa10bBxoA0d+TcGYPAdPJmsiRiWyTjytbeLi4eXgIZvxq/MP7qxsipagt88zTduIPWtmccczuTW6b9JDQniuRoZRNNLkfmZkEIShnrZNSWR5Jo+8Fl2/qUchSYk5IaiX6D0TQ5WhKU4hl1rlW1l4x3tmemdhrT57yHmdlrulASpAS4OaCJVuo8/r3LLkP44c8kSDWfBFPdkSW9TEAOpFXxncX69MHkzxjrjQFpyXrZT4TsV14ihoP032F7GgOv6KL1GwJbTPVEwAz33ICZ+e+rpZKqOwtQF From: =?UTF-8?q?Alex=20Benn=C3=A9e?= To: qemu-devel@nongnu.org Cc: devel@lists.libvirt.org, Jiaxun Yang , Daniel Henrique Barboza , Chris Wulff , Weiwei Li , Bin Meng , Thomas Huth , qemu-riscv@nongnu.org, Marek Vasut , Liu Zhiwei , Aleksandar Rikalo , =?UTF-8?q?Marc-Andr=C3=A9=20Lureau?= , =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= , Alistair Francis , Warner Losh , Paolo Bonzini , Aurelien Jarno , Beraldo Leal , =?UTF-8?q?Daniel=20P=2E=20Berrang=C3=A9?= , Max Filippov , =?UTF-8?q?Alex=20Benn=C3=A9e?= , Ed Maste , Palmer Dabbelt , Li-Wen Hsu , Laurent Vivier , Kyle Evans , Wainer dos Santos Moschetta , Riku Voipio , Ilya Leoshkevich Subject: [PATCH v2 07/14] test-util-filemonitor: Adapt to the FreeBSD inotify rename semantics Date: Wed, 7 Feb 2024 16:38:05 +0000 Message-Id: <20240207163812.3231697-8-alex.bennee@linaro.org> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20240207163812.3231697-1-alex.bennee@linaro.org> References: <20240207163812.3231697-1-alex.bennee@linaro.org> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=2a00:1450:4864:20::329; envelope-from=alex.bennee@linaro.org; helo=mail-wm1-x329.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZohoMail-DKIM: pass (identity @linaro.org) X-ZM-MESSAGEID: 1707324025771100006 From: Ilya Leoshkevich Unlike on Linux, on FreeBSD renaming a file when the destination already exists results in an IN_DELETE event for that existing file: $ FILEMONITOR_DEBUG=3D1 build/tests/unit/test-util-filemonitor Rename /tmp/test-util-filemonitor-K13LI2/fish/one.txt -> /tmp/test-util= -filemonitor-K13LI2/two.txt Event id=3D200000000 event=3D2 file=3Done.txt Queue event id 200000000 event 2 file one.txt Queue event id 100000000 event 2 file two.txt Queue event id 100000002 event 2 file two.txt Queue event id 100000000 event 0 file two.txt Queue event id 100000002 event 0 file two.txt Event id=3D100000000 event=3D0 file=3Dtwo.txt Expected event 0 but got 2 This difference in behavior is not expected to break the real users, so teach the test to accept it. Suggested-by: Daniel P. Berrange Signed-off-by: Ilya Leoshkevich Message-Id: <20240206002344.12372-4-iii@linux.ibm.com> Signed-off-by: Alex Benn=C3=A9e Reviewed-by: Warner Losh --- tests/unit/test-util-filemonitor.c | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/tests/unit/test-util-filemonitor.c b/tests/unit/test-util-file= monitor.c index a22de275955..02e67fc96ac 100644 --- a/tests/unit/test-util-filemonitor.c +++ b/tests/unit/test-util-filemonitor.c @@ -360,6 +360,14 @@ test_file_monitor_events(void) { .type =3D QFILE_MONITOR_TEST_OP_EVENT, .filesrc =3D "one.txt", .watchid =3D &watch4, .eventid =3D QFILE_MONITOR_EVENT_DELETED }, +#ifdef __FreeBSD__ + { .type =3D QFILE_MONITOR_TEST_OP_EVENT, + .filesrc =3D "two.txt", .watchid =3D &watch0, + .eventid =3D QFILE_MONITOR_EVENT_DELETED }, + { .type =3D QFILE_MONITOR_TEST_OP_EVENT, + .filesrc =3D "two.txt", .watchid =3D &watch2, + .eventid =3D QFILE_MONITOR_EVENT_DELETED }, +#endif { .type =3D QFILE_MONITOR_TEST_OP_EVENT, .filesrc =3D "two.txt", .watchid =3D &watch0, .eventid =3D QFILE_MONITOR_EVENT_CREATED }, --=20 2.39.2 From nobody Tue Nov 26 12:43:47 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass(p=none dis=none) header.from=linaro.org ARC-Seal: i=1; a=rsa-sha256; t=1707323968; cv=none; d=zohomail.com; s=zohoarc; b=M37JdtAzqcwutL72dDNqpbfsr6acq+rFp9SfgCfYQrJVedfjEiqSijCpk5dIbnji7BAGAOSnHhkHAWA1oIxKmcRBWNOHOe5V/KiuT4IvozlZVoHCb9HvMNHmkJ0TT/NuMSw8Gwh+tq96NeLt7PO/gO4KN35xiEFM+mxYS0ujzOE= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1707323968; h=Content-Type:Content-Transfer-Encoding:Cc:Cc:Date:Date:From:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:Subject:To:To:Message-Id:Reply-To; bh=fM5vrN0Mlz2zZCFNsOvOH4Md1jU+CHoqT++QO5pSQvE=; b=U5HH4QcYo8n0lXdd6NiUQrHnAV3/w1iKDwhQHfYwXB/6gYzUB7rJp7ejq9lcr1HtPCbDYg17O6NdyfSBotGB/bOYxiWDlsTij/UtTSO3naITgU4qJOaw/SQVuF8g2rMeISTEg7sN5ZPnc5GaVfu8KgzP+In1+zfIT03zY7Utg6A= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1707323968364213.88091380153037; Wed, 7 Feb 2024 08:39:28 -0800 (PST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rXkwN-0002uX-C7; Wed, 07 Feb 2024 11:38:27 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rXkwL-0002tP-Ux for qemu-devel@nongnu.org; Wed, 07 Feb 2024 11:38:25 -0500 Received: from mail-wm1-x32e.google.com ([2a00:1450:4864:20::32e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rXkwK-00068O-3u for qemu-devel@nongnu.org; Wed, 07 Feb 2024 11:38:25 -0500 Received: by mail-wm1-x32e.google.com with SMTP id 5b1f17b1804b1-40fc52c2ae4so7330965e9.3 for ; Wed, 07 Feb 2024 08:38:23 -0800 (PST) Received: from draig.lan ([85.9.250.243]) by smtp.gmail.com with ESMTPSA id dr9-20020a5d5f89000000b0033b14f22180sm1931991wrb.20.2024.02.07.08.38.13 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 07 Feb 2024 08:38:17 -0800 (PST) Received: from draig.lan (localhost [IPv6:::1]) by draig.lan (Postfix) with ESMTP id D06AA5F936; Wed, 7 Feb 2024 16:38:12 +0000 (GMT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1707323902; x=1707928702; darn=nongnu.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=fM5vrN0Mlz2zZCFNsOvOH4Md1jU+CHoqT++QO5pSQvE=; b=Dv8Ut1t3diR6G97LfsvjCNnKcaKw/2qnmaaGSUtBpzlbQBrOYuISqhFjmmlW2JCer3 Hfyt8rdvVB9SvNtKES7wp8WLph9VNq+MDBfOL52xoWagGAVVFTsZRiNEuNAL05vgraAc vSbs16hXE0z8+x5bNeOJYV+EAqkMqTm+yO6ZByMWmd9AojdUHXHxjdCHw5EymUHlWaP6 tm+xnQqA/0Ur2OCLphxhwj3+NX97JPrLdoiklpdZHpUn27QEt+hJqJA7jDcO8I+cI6D1 z/vN51HKtnfYvvxL5CpIlgrboSNBRJVgjHBds/W0tm4rCkF1xZX+N7SFCbH8/APLz2Tb aEng== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1707323902; x=1707928702; 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=fM5vrN0Mlz2zZCFNsOvOH4Md1jU+CHoqT++QO5pSQvE=; b=FKwc6ThjN1/0gJ2QkBryWvb+fymqWe9BsFzvJHHCQD6CzSze0fujt1JvRqPg92mr+Q 0bZAZBQ3F4GOHpZTMb1eYahMn8QXYlhv1/V3NVn/+R/fxDkUo3uNxwBOSJnVEmnq6AKx iYh0mMel98jxWUTVRxmV7L5nWedNm81ObSORcd/jjxRMgU9AkKhU/NiLsxUSPYlpFVMI kw34ZqxGzmgUtyjTfn8VPSnGtrbWNP05DXJKLEgueqXbvZJAHzJ5W27PNUXUwFyXtaU+ 0SOQIs7b6nsIWD+CAsKNZpjoqMdzBpnsHXaEci9fOH6XsjUSmBjmd3XUOYTqtYCEONrH EbIg== X-Gm-Message-State: AOJu0YyPu9Ors/T5srY6R5IB0xZu5CEuwrQKuQ2XT1dAHqyAkOhFgo4H Ve77B+jpMXlnG90e1TtPBoticzTtpQa9DXtwiy86XNcVuDhzCj51F3Cg+BRB4WU= X-Google-Smtp-Source: AGHT+IGRn8o+3PguwBMQKbgAfAf68TmGaanFkxmhOOIUWDE6pq12LGO9dPZ4sbxX968w/g0y+Ao1ug== X-Received: by 2002:a05:6000:1887:b0:33a:e9dd:5b6b with SMTP id a7-20020a056000188700b0033ae9dd5b6bmr5051977wri.9.1707323902065; Wed, 07 Feb 2024 08:38:22 -0800 (PST) X-Forwarded-Encrypted: i=1; AJvYcCUYag4D21fnS+Nt3Iaa0dWG4qWZq8iz7hwR054Tieh1RJruin5WpYjIvfHJUsbaIMXvRT0a8w0Y7xumZ62eTYqyk7M5dHRcd073VKqaempqxzU3NI3jMnLLMX1ouaZmTgS0y4gs6vgHt0JUXgU1HhOWnRQqW6XWyDDVCHNRid5ugUdq3Ex3o8zdgCEjQmyF51CVoJvMlwQSgBWFm1BJYnCZWfqQgVYVEvtShNto7qBgyNpXMV3ekxzMuGiuD/qRXcOCmfFIp/j7QuXexWYapukhaXU0c72UkvOlVP9HNrm7f4xJnS0IkJAg7k7+EDxbnQLlFpljISxnfi57XteE8g3ZHhqtGQPWqKD/A6YU+NCPq8rm45SzXwj7F7TL+3YI4/Ce4bk8V+Eu+PZFqfQuEh01tf3UQO0oKp8rFWUMnLpuLFijLiTv7g3GAun9BJA3IZLiHlYmdUAF3odWSigqf84aWgLHBo0pFBTbh9qb5ZQIjh2BHHLdseZbzvCGf8Rl+lyMdNcz0gyidQEUkamYgzJTBLmY072NCWj4BNad/X1FEseVZ1NhdnUleZ2WCBDQQYh/HQeppZzdUFnpmER0xxOzIPlsf8m6BHUaAE4W/C8PxNNK+Fef37M207yUmyNHrEN6B2tsa0+4vmttFuAp6q8/HNzQT9hwpLAwy4/sbChqabDwQjRU1WfBdFQnPEE/CytfnqGzqtLXTfGBYi0MR1jqktR/vCFBnQwS2W/D3uXbawLY9zAqUVTmaPrMTPxip9PXtfUkV+5xeheXSM1lV73AEO07XIZBL5g7TyZLT5JI+X+XjdHBAnIZXpvSDzIjunEZZrbnoMxWl75nXctY3GGHgdn1TVv7ZqYf+a6R From: =?UTF-8?q?Alex=20Benn=C3=A9e?= To: qemu-devel@nongnu.org Cc: devel@lists.libvirt.org, Jiaxun Yang , Daniel Henrique Barboza , Chris Wulff , Weiwei Li , Bin Meng , Thomas Huth , qemu-riscv@nongnu.org, Marek Vasut , Liu Zhiwei , Aleksandar Rikalo , =?UTF-8?q?Marc-Andr=C3=A9=20Lureau?= , =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= , Alistair Francis , Warner Losh , Paolo Bonzini , Aurelien Jarno , Beraldo Leal , =?UTF-8?q?Daniel=20P=2E=20Berrang=C3=A9?= , Max Filippov , =?UTF-8?q?Alex=20Benn=C3=A9e?= , Ed Maste , Palmer Dabbelt , Li-Wen Hsu , Laurent Vivier , Kyle Evans , Wainer dos Santos Moschetta , Riku Voipio , Ilya Leoshkevich Subject: [PATCH v2 08/14] meson: Link with libinotify on FreeBSD Date: Wed, 7 Feb 2024 16:38:06 +0000 Message-Id: <20240207163812.3231697-9-alex.bennee@linaro.org> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20240207163812.3231697-1-alex.bennee@linaro.org> References: <20240207163812.3231697-1-alex.bennee@linaro.org> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=2a00:1450:4864:20::32e; envelope-from=alex.bennee@linaro.org; helo=mail-wm1-x32e.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZohoMail-DKIM: pass (identity @linaro.org) X-ZM-MESSAGEID: 1707323969579100003 From: Ilya Leoshkevich make vm-build-freebsd fails with: ld: error: undefined symbol: inotify_init1 >>> referenced by filemonitor-inotify.c:183 (../src/util/filemonitor-in= otify.c:183) >>> util_filemonitor-inotify.c.o:(qemu_file_monitor_new) = in archive libqemuutil.a On FreeBSD the inotify functions are defined in libinotify.so. Add it to the dependencies. Signed-off-by: Ilya Leoshkevich Reviewed-by: Thomas Huth Message-Id: <20240206002344.12372-5-iii@linux.ibm.com> Signed-off-by: Alex Benn=C3=A9e Reviewed-by: Warner Losh --- meson.build | 23 +++++++++++++++++++---- util/meson.build | 6 +++++- 2 files changed, 24 insertions(+), 5 deletions(-) diff --git a/meson.build b/meson.build index b5d6dc94a83..e5d6f2d057e 100644 --- a/meson.build +++ b/meson.build @@ -2384,6 +2384,22 @@ else endif config_host_data.set('CONFIG_ASAN_IFACE_FIBER', have_asan_fiber) =20 +have_inotify_init =3D cc.has_header_symbol('sys/inotify.h', 'inotify_init') +have_inotify_init1 =3D cc.has_header_symbol('sys/inotify.h', 'inotify_init= 1') +inotify =3D not_found +if (have_inotify_init or have_inotify_init1) and host_os =3D=3D 'freebsd' + # libinotify-kqueue + inotify =3D cc.find_library('inotify') + if have_inotify_init + have_inotify_init =3D inotify.found() + endif + if have_inotify_init1 + have_inotify_init1 =3D inotify.found() + endif +endif +config_host_data.set('CONFIG_INOTIFY', have_inotify_init) +config_host_data.set('CONFIG_INOTIFY1', have_inotify_init1) + # has_header_symbol config_host_data.set('CONFIG_BLKZONED', cc.has_header_symbol('linux/blkzoned.h', 'BLKOPENZONE= ')) @@ -2400,10 +2416,6 @@ config_host_data.set('CONFIG_FIEMAP', config_host_data.set('CONFIG_GETRANDOM', cc.has_function('getrandom') and cc.has_header_symbol('sys/random.h', 'GRND_NONBLOCK')) -config_host_data.set('CONFIG_INOTIFY', - cc.has_header_symbol('sys/inotify.h', 'inotify_init')) -config_host_data.set('CONFIG_INOTIFY1', - cc.has_header_symbol('sys/inotify.h', 'inotify_init1'= )) config_host_data.set('CONFIG_PRCTL_PR_SET_TIMERSLACK', cc.has_header_symbol('sys/prctl.h', 'PR_SET_TIMERSLAC= K')) config_host_data.set('CONFIG_RTNETLINK', @@ -4407,6 +4419,9 @@ summary_info +=3D {'libudev': libudev} summary_info +=3D {'FUSE lseek': fuse_lseek.found()} summary_info +=3D {'selinux': selinux} summary_info +=3D {'libdw': libdw} +if host_os =3D=3D 'freebsd' + summary_info +=3D {'libinotify-kqueue': inotify} +endif summary(summary_info, bool_yn: true, section: 'Dependencies') =20 if host_arch =3D=3D 'unknown' diff --git a/util/meson.build b/util/meson.build index af3bf5692d8..0ef9886be04 100644 --- a/util/meson.build +++ b/util/meson.build @@ -104,7 +104,11 @@ if have_block util_ss.add(files('throttle.c')) util_ss.add(files('timed-average.c')) if config_host_data.get('CONFIG_INOTIFY1') - util_ss.add(files('filemonitor-inotify.c')) + freebsd_dep =3D [] + if host_os =3D=3D 'freebsd' + freebsd_dep =3D inotify + endif + util_ss.add(files('filemonitor-inotify.c'), freebsd_dep) else util_ss.add(files('filemonitor-stub.c')) endif --=20 2.39.2 From nobody Tue Nov 26 12:43:47 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass(p=none dis=none) header.from=linaro.org ARC-Seal: i=1; a=rsa-sha256; t=1707323985; cv=none; d=zohomail.com; s=zohoarc; b=S2xpjNrkOeZJwIgiilWDOrdyRuwmq1H1g+BRrcSPY8SpI7/Q27zZ62El/LrvWr7XiMA2Jw+zWWTtESJEVkbDBdvFefGL0onqbdTGD0krC9z3dvc/cTjNv1VrLSrFEo6o3IrftXhzWiiVLGY+MyMZdcaM4o0gD5TiTttghN4WWDM= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1707323985; h=Content-Type:Content-Transfer-Encoding:Cc:Cc:Date:Date:From:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:Subject:To:To:Message-Id:Reply-To; bh=Bsz/mh6XyPunNIOKbf6F3e4icAT2FQKVXxwZaYNEmKM=; b=N05J2ga3baguk1QXpBXGkg5UY0Cb55Oph3IgWBzmrgVC+2FSgTzSLxljrHwPeUu8GQg7s7OfvUvRzZtPWAnjpeoGys29UN3lpE2ySvvIrtyr7+7mGYKVQRa+C6BhCVjgpPs335bKLOQ46F99uXOz7skWwEsDDTTMqdYPIy1CYk4= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1707323985876759.5547099595651; Wed, 7 Feb 2024 08:39:45 -0800 (PST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rXkwQ-0002x9-15; Wed, 07 Feb 2024 11:38:30 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rXkwN-0002uW-8J for qemu-devel@nongnu.org; Wed, 07 Feb 2024 11:38:27 -0500 Received: from mail-wm1-x329.google.com ([2a00:1450:4864:20::329]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rXkwL-0006Al-DI for qemu-devel@nongnu.org; Wed, 07 Feb 2024 11:38:26 -0500 Received: by mail-wm1-x329.google.com with SMTP id 5b1f17b1804b1-41008ab427fso7701325e9.0 for ; Wed, 07 Feb 2024 08:38:25 -0800 (PST) Received: from draig.lan ([85.9.250.243]) by smtp.gmail.com with ESMTPSA id h6-20020adffa86000000b0033b0d2ba3a1sm1849517wrr.63.2024.02.07.08.38.15 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 07 Feb 2024 08:38:17 -0800 (PST) Received: from draig.lan (localhost [IPv6:::1]) by draig.lan (Postfix) with ESMTP id F07435F944; Wed, 7 Feb 2024 16:38:12 +0000 (GMT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1707323904; x=1707928704; darn=nongnu.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=Bsz/mh6XyPunNIOKbf6F3e4icAT2FQKVXxwZaYNEmKM=; b=rhHFl7tw2jpXI13lBCgMSK1yP/oh1HLPsr4H3127lyXODA1a8EAEN4IWXq9Q40Ut3u EDVZukVm3ltYiE5Ld679algo9UL6/6yyloBa5Z6Uvr/zVppdzWCTDCZPnKmFJfPEeQIV E2aM9oJqfiEaLhT5a8ImuHzAQhopdWmwYNfE989qX8oVfFXgYd8KRtf8duFvTfLqLJFd P3XqBx98LmXdKo/QxjWVout2zqm1fSL3S5plgAM1inwipYFiEab6yMgGIM6joIDWmZkf 1qdnyKwit1pTinebN0gh56KOMUrjt/gyA506gOH8eEbK2YrypZyHovQBp1R4kCfrjMwT mH/g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1707323904; x=1707928704; 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=Bsz/mh6XyPunNIOKbf6F3e4icAT2FQKVXxwZaYNEmKM=; b=dS7XxJepe1jRKU1tOyrPqGvMl570xTATaPftHYicwerEFxcPPSmZ1eQdcjmUNN5rRZ 1bHaFPl4/S5qgUB+DYpjG2ZY2kQ1J9YxM7/uNoTrb2JjgBoFaATvC46KDqa+BjLmNBqs rtf2OPudEM5wS/vlBn6g5trGpQbkwWYEAO8ZrjpZngl8CIV2+skZq8V1o5uag+8b/cc2 qLYF3Q/SZJfoW1HC5V+30m37uYOQiAHFrSVRj9FoVADf7796cgDXYr/bUE+is1RbyrxU XBoOk0X5C0Swkt4YT5qCW0ARu+xnCo2MANHBqmCNGCUUSO0+wDRxVMFtRLJ21k+Zc3ss iyZw== X-Gm-Message-State: AOJu0YyVQFHlzvu7Kbf/wdoAzhvUdOu3VmxmOuDuBzLm3jG+Y3ONdQsC K2d43J4nh+9CUYZjq2rY8F+LZyKt9JHf1Jg287WXLKoQad3EZn+qGPSrz1+5NR8= X-Google-Smtp-Source: AGHT+IHUFtCZuhHFqo6Q6cjDY4IATjHiYwqiO6zG4jeJc8GNcO6eSaJzHUJoIOMR4DtLxcaJg2fQ5Q== X-Received: by 2002:adf:ab09:0:b0:33b:26b7:5aa8 with SMTP id q9-20020adfab09000000b0033b26b75aa8mr4468170wrc.56.1707323904126; Wed, 07 Feb 2024 08:38:24 -0800 (PST) X-Forwarded-Encrypted: i=1; AJvYcCWKSKDs5pFpnSwz763rVAHqlB9UGVUPt3IyjFem9exc2KAdyjjmiMgWAn9O++Jv2MmvSBlVZJRubAZ2726Mx7oJ9uAy2fzCzZKz1HQiEzhp3HIq9JxCcnXjo0zTjpLPTyCz8kwIryVlDxSizi6pmIXOU5PMz6AD/Y9IXFi9xTVbjYzIUh/4MtnlGCDNoTLKFyhokg5jvgPXKu5CjBjmvkXtG5W80kKvE6thf2V9HNG3ODrZhjtq9oG6DPS+Ftuhjl1wSlkOJvylzyg2Pm4mVqv6zLtY3c4XGnygxaQWlWz8YXWGw3p64RCzbzexytTnHgOq1P2eFWTctPZIcJ1U74+3DEbd3ruzM6a9JcZgRlwt+ZX+iznBtwRd/QC7UM9si2cSy4YFjbsA1+SA66w7FB0CqR0hJI51473jjFI2hkKvmIUyzFtHoPSUo2dwVigMJw/qN4JihI9klknFMcbtDDOqSsm4Ywt+OlwvMUHGYbVphy3gZQY9OcPV93u3xCI+IGHY7KnGEGy7lp9bxlwvop+RkM7o/MzyYUFy08cMgqcGDJAjfnwrHyvduXNLqGC/LKJgLvK61S4fY9zJRClQ2madZr9clhNIRc94SIfuWTTHyHLexvAQ2hknO1HeAA2lfIF3TMh0gPk+oVkf6n+88s3dhqDbmZeytoNct91Hf1a/UfOr6WxrRrj8RP4k17hBzhM9rhUyXMpJwXYHPVmpDZRJxQckFqOJehI0lpxzAZXsrYqynWbo28ft3y/YNDp/PsD4pDqlqJyXDYKMsO5bV+7Odf8dMJp7NiazSfKFCMdsk27uzi/LAUirJwMoUiHmk1qQK8CLIroF3cI= From: =?UTF-8?q?Alex=20Benn=C3=A9e?= To: qemu-devel@nongnu.org Cc: devel@lists.libvirt.org, Jiaxun Yang , Daniel Henrique Barboza , Chris Wulff , Weiwei Li , Bin Meng , Thomas Huth , qemu-riscv@nongnu.org, Marek Vasut , Liu Zhiwei , Aleksandar Rikalo , =?UTF-8?q?Marc-Andr=C3=A9=20Lureau?= , =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= , Alistair Francis , Warner Losh , Paolo Bonzini , Aurelien Jarno , Beraldo Leal , =?UTF-8?q?Daniel=20P=2E=20Berrang=C3=A9?= , Max Filippov , =?UTF-8?q?Alex=20Benn=C3=A9e?= , Ed Maste , Palmer Dabbelt , Li-Wen Hsu , Laurent Vivier , Kyle Evans , Wainer dos Santos Moschetta , Riku Voipio Subject: [PATCH v2 09/14] kconfig: use "select" to enable semihosting Date: Wed, 7 Feb 2024 16:38:07 +0000 Message-Id: <20240207163812.3231697-10-alex.bennee@linaro.org> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20240207163812.3231697-1-alex.bennee@linaro.org> References: <20240207163812.3231697-1-alex.bennee@linaro.org> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=2a00:1450:4864:20::329; envelope-from=alex.bennee@linaro.org; helo=mail-wm1-x329.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZohoMail-DKIM: pass (identity @linaro.org) X-ZM-MESSAGEID: 1707323987652100006 From: Paolo Bonzini Just like all other dependencies, these can be expressed in Kconfig files rather than in the default configurations. Signed-off-by: Paolo Bonzini Acked-by: Alistair Francis Reviewed-by: Thomas Huth Message-Id: <20240201122835.1712347-6-alex.bennee@linaro.org> Message-Id: <20240129115809.1039924-1-pbonzini@redhat.com> Signed-off-by: Alex Benn=C3=A9e --- configs/devices/m68k-softmmu/default.mak | 2 -- configs/devices/mips-softmmu/common.mak | 3 --- configs/devices/nios2-softmmu/default.mak | 2 -- configs/devices/riscv32-softmmu/default.mak | 2 -- configs/devices/riscv64-softmmu/default.mak | 2 -- configs/devices/xtensa-softmmu/default.mak | 2 -- target/m68k/Kconfig | 1 + target/mips/Kconfig | 1 + target/nios2/Kconfig | 1 + target/riscv/Kconfig | 2 ++ target/xtensa/Kconfig | 1 + 11 files changed, 6 insertions(+), 13 deletions(-) diff --git a/configs/devices/m68k-softmmu/default.mak b/configs/devices/m68= k-softmmu/default.mak index 7f8619e4278..8dcaa28ed38 100644 --- a/configs/devices/m68k-softmmu/default.mak +++ b/configs/devices/m68k-softmmu/default.mak @@ -1,7 +1,5 @@ # Default configuration for m68k-softmmu =20 -CONFIG_SEMIHOSTING=3Dy - # Boards: # CONFIG_AN5206=3Dy diff --git a/configs/devices/mips-softmmu/common.mak b/configs/devices/mips= -softmmu/common.mak index 7da99327a77..1a853841b27 100644 --- a/configs/devices/mips-softmmu/common.mak +++ b/configs/devices/mips-softmmu/common.mak @@ -1,8 +1,5 @@ # Common mips*-softmmu CONFIG defines =20 -# CONFIG_SEMIHOSTING is always required on this architecture -CONFIG_SEMIHOSTING=3Dy - CONFIG_ISA_BUS=3Dy CONFIG_PCI=3Dy CONFIG_PCI_DEVICES=3Dy diff --git a/configs/devices/nios2-softmmu/default.mak b/configs/devices/ni= os2-softmmu/default.mak index 1bc4082ea99..e130d024e62 100644 --- a/configs/devices/nios2-softmmu/default.mak +++ b/configs/devices/nios2-softmmu/default.mak @@ -1,7 +1,5 @@ # Default configuration for nios2-softmmu =20 -CONFIG_SEMIHOSTING=3Dy - # Boards: # CONFIG_NIOS2_10M50=3Dy diff --git a/configs/devices/riscv32-softmmu/default.mak b/configs/devices/= riscv32-softmmu/default.mak index d847bd5692e..94a236c9c25 100644 --- a/configs/devices/riscv32-softmmu/default.mak +++ b/configs/devices/riscv32-softmmu/default.mak @@ -3,8 +3,6 @@ # Uncomment the following lines to disable these optional devices: # #CONFIG_PCI_DEVICES=3Dn -CONFIG_SEMIHOSTING=3Dy -CONFIG_ARM_COMPATIBLE_SEMIHOSTING=3Dy =20 # Boards: # diff --git a/configs/devices/riscv64-softmmu/default.mak b/configs/devices/= riscv64-softmmu/default.mak index bc69301fa4a..3f680594484 100644 --- a/configs/devices/riscv64-softmmu/default.mak +++ b/configs/devices/riscv64-softmmu/default.mak @@ -3,8 +3,6 @@ # Uncomment the following lines to disable these optional devices: # #CONFIG_PCI_DEVICES=3Dn -CONFIG_SEMIHOSTING=3Dy -CONFIG_ARM_COMPATIBLE_SEMIHOSTING=3Dy =20 # Boards: # diff --git a/configs/devices/xtensa-softmmu/default.mak b/configs/devices/x= tensa-softmmu/default.mak index 4fe1bf00c94..49e4c9da88c 100644 --- a/configs/devices/xtensa-softmmu/default.mak +++ b/configs/devices/xtensa-softmmu/default.mak @@ -1,7 +1,5 @@ # Default configuration for Xtensa =20 -CONFIG_SEMIHOSTING=3Dy - # Boards: # CONFIG_XTENSA_SIM=3Dy diff --git a/target/m68k/Kconfig b/target/m68k/Kconfig index 23debad519a..9eae71486ff 100644 --- a/target/m68k/Kconfig +++ b/target/m68k/Kconfig @@ -1,2 +1,3 @@ config M68K bool + select SEMIHOSTING diff --git a/target/mips/Kconfig b/target/mips/Kconfig index 6adf1453548..eb19c94c7d4 100644 --- a/target/mips/Kconfig +++ b/target/mips/Kconfig @@ -1,5 +1,6 @@ config MIPS bool + select SEMIHOSTING =20 config MIPS64 bool diff --git a/target/nios2/Kconfig b/target/nios2/Kconfig index 1529ab8950d..c65550c861a 100644 --- a/target/nios2/Kconfig +++ b/target/nios2/Kconfig @@ -1,2 +1,3 @@ config NIOS2 bool + select SEMIHOSTING diff --git a/target/riscv/Kconfig b/target/riscv/Kconfig index b9e5932f13f..adb7de3f37d 100644 --- a/target/riscv/Kconfig +++ b/target/riscv/Kconfig @@ -1,5 +1,7 @@ config RISCV32 bool + select ARM_COMPATIBLE_SEMIHOSTING # for do_common_semihosting() =20 config RISCV64 bool + select ARM_COMPATIBLE_SEMIHOSTING # for do_common_semihosting() diff --git a/target/xtensa/Kconfig b/target/xtensa/Kconfig index a3c8dc7f6d7..5e46049262d 100644 --- a/target/xtensa/Kconfig +++ b/target/xtensa/Kconfig @@ -1,2 +1,3 @@ config XTENSA bool + select SEMIHOSTING --=20 2.39.2 From nobody Tue Nov 26 12:43:47 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass(p=none dis=none) header.from=linaro.org ARC-Seal: i=1; a=rsa-sha256; t=1707323989; cv=none; d=zohomail.com; s=zohoarc; b=bsRQXKiuwcsXZfMQdW4cCJLfB+qKAnV2wq4Poz+Tvf64mXk183fscAzYmI8wG2vWYuUPnL0gE17zIQXSGOo09YAv7IdDSZ0tDHEfPznWBfzJc255Py01NgDw+JIlGmJK4RIrB5fVNxlTe0MgCfuq+qdDwSBLfWQZZFMrfVlUWKg= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1707323989; h=Content-Type:Content-Transfer-Encoding:Cc:Cc:Date:Date:From:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:Subject:To:To:Message-Id:Reply-To; bh=oWoGzkk5jlTntsP9Fp0ezGwzMskb1JgO0OTcfpG0rf4=; b=Zcp5XDbLec7BMTE+kXLd8RfZ/zfZPbo+YBhf9ShU/EbL4He7Nzlnnk6DlN3urbbcjNOMGlUl7YF6sYbrUQp1tS0eF+h4KkV/fP2ckIj6Zsua/c+pAySgGAre3/LL6Iv9qVb2Rfd03A45VK5kEwjRe9DVGiFTLIvpF9lR7k9ffEI= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1707323989451632.8472489859965; Wed, 7 Feb 2024 08:39:49 -0800 (PST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rXkwP-0002wu-Sf; Wed, 07 Feb 2024 11:38:29 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rXkwM-0002ty-EC for qemu-devel@nongnu.org; Wed, 07 Feb 2024 11:38:26 -0500 Received: from mail-wm1-x330.google.com ([2a00:1450:4864:20::330]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rXkwK-00068e-Br for qemu-devel@nongnu.org; Wed, 07 Feb 2024 11:38:26 -0500 Received: by mail-wm1-x330.google.com with SMTP id 5b1f17b1804b1-40fdc63f4feso7868025e9.3 for ; Wed, 07 Feb 2024 08:38:23 -0800 (PST) Received: from draig.lan ([85.9.250.243]) by smtp.gmail.com with ESMTPSA id fl16-20020a05600c0b9000b004101f27737asm1077895wmb.29.2024.02.07.08.38.15 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 07 Feb 2024 08:38:17 -0800 (PST) Received: from draig.lan (localhost [IPv6:::1]) by draig.lan (Postfix) with ESMTP id 13B8A5F949; Wed, 7 Feb 2024 16:38:13 +0000 (GMT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1707323902; x=1707928702; darn=nongnu.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=oWoGzkk5jlTntsP9Fp0ezGwzMskb1JgO0OTcfpG0rf4=; b=mCvzwygqxhve/FdYw7vM+UBP6w6qu/Tz7WK/foIeEyrQVW6k/i4Ydkb9gF9Qt+WT4W ZY+OwC1/9TBVMyJzGILuzy3eG6GdfU2obtNtfUgM3kJwqmCqO3QL+8Zi6G+Bt10t4MxO uhKQxhRJZZ+42XRpdAVF3IN43nBvmecRovbPNOlnS0yszWLs0PRHwsdndJLWfQK0Ol6E 24x9UiLhmUgPe2vTpvwHQaXuBMbpzTcB37XU3qhkjF/Jg4k6xkFg4Fbh1RFFZGl1uqnG Bu/xlEid0XNNnp0iZAqf/10Il2gEJll+T6o1DKJrWjTGrKEV4IyVJHKuA7WW53cr25xq qZvQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1707323902; x=1707928702; 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=oWoGzkk5jlTntsP9Fp0ezGwzMskb1JgO0OTcfpG0rf4=; b=jFHwJqxov0MJTJ4i+/gXSMN15RNEWYUxOPJhcAkSbSybJ7BTKUygBwlJ7NBvjAWpWR mSaOvfvbIebxm278bBaJrJbJCNvUah+gHUcf+KbOH8GfnYbKAaitEFy3dOQEjF2YlIVn p3jRwv45AuXx55UDatYtIYpJGESsBckU4XgntcUZRzdVbva/XfbODJPoI2qkwd1+BQ2w I0L5GgM5TTvPpiJvD1U1Ofyd8JcR9cYZdhhiqDe/sFqt6bLpY+cPEEt0JFY28+ah6G/P 4gGcfbOEc9Z3LISj8aK0JidzLmVrdN47XeUEr4uof6n1ZUmrXOnhpQI/jNOyFTA49r9u pM8Q== X-Gm-Message-State: AOJu0YyubnYky8f/2AgyzTJDyFO/VDH7HpLXauQMdSjoyZlkZm3YmQXu Q5nXVmrs/Ao/mkFqNc6LTdMiRjcfYmz3kZ3qjOf9XQb7IFoigIgB/YVPuZCw628= X-Google-Smtp-Source: AGHT+IFKZDWPp/Oeqr5xIx+FWTBf9UOkRI8o5K1IWgBIDljwhDfnmXTooMPXmAX57B0O5y42TgwpXA== X-Received: by 2002:a05:600c:4691:b0:40e:f154:752 with SMTP id p17-20020a05600c469100b0040ef1540752mr5391678wmo.20.1707323902442; Wed, 07 Feb 2024 08:38:22 -0800 (PST) X-Forwarded-Encrypted: i=1; AJvYcCWOTJ4esVaJckcJFrE2pkVh9RazJTeGt3av8oiPaGyDUIvMc4VJ5oqaZ5tCa3BM8uZeFYMPxrQ1xyVLHqFEn6qa5SARefa9pJ5qL555GzP5dh9DKCE1zeJQ47UzXpPEYVLaFCDA/smQoWpD+GHLMZguXFhoZSXuPMsBW3j4JCQ3n8J0SbbSVTktdMHmWTRj9cyAtm/QpON5VaD7RYqy4AC8n0RrRqrxS4ux4is6eApPuPkuCIy3ucmZ1k6bHnLFbYoPFIIrp24fNRF4XjExn/s7eZRZAdiNl8fwLbV3VI34ry3MosOI5SmU8V14cGJaS2sL1voYPm8z4BQiod08YKblO37LwlInE+j+DIhiFInFmHe+cjT79vgauLX3H6DKPlkicMxuXIy6nvgOIl99r9I5kWsib7cLX7XXhm0itfdcnwmu4aNBh+YqVb0EvyAbsuzzw61/YN9POghP1NBE5l34ClIzTyoi5lZJ00p+Hf3xCk9CSjIIs5LOxmkrPD7gGZGYlF49qJRTL6XnBqoMvUbSaMlg8mn5OlcQK+Q1aUUKD9v81sfmcGM0tr69WnUKVkLHsYDTCfU373ZIsWDxVtcZf+0jP30FWAbHfHyH0bP/cLJsUqgjLjw1r8Wb1xPuTgHwi1LgbOHm8O4DOGxP1hvaNaTHGM6dG2EfOLgySUQo5vYtBXQvbNLNvN7TGqnvsLsH22U/WLGATVK7jNwQ4GQHQiCJ/4Wmbr3FK9dbwciDQL3bW+yVZa6GlmQeeYv8C2P0LDavkCzuNoGq/eq0hYwXk3c1uUExTvH5UNUAlUjbM5jlQSu+2hLinU/D75agOpn+Iy5geOmZJgCsqovJUhKt+juyNPkjOzKL922q From: =?UTF-8?q?Alex=20Benn=C3=A9e?= To: qemu-devel@nongnu.org Cc: devel@lists.libvirt.org, Jiaxun Yang , Daniel Henrique Barboza , Chris Wulff , Weiwei Li , Bin Meng , Thomas Huth , qemu-riscv@nongnu.org, Marek Vasut , Liu Zhiwei , Aleksandar Rikalo , =?UTF-8?q?Marc-Andr=C3=A9=20Lureau?= , =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= , Alistair Francis , Warner Losh , Paolo Bonzini , Aurelien Jarno , Beraldo Leal , =?UTF-8?q?Daniel=20P=2E=20Berrang=C3=A9?= , Max Filippov , =?UTF-8?q?Alex=20Benn=C3=A9e?= , Ed Maste , Palmer Dabbelt , Li-Wen Hsu , Laurent Vivier , Kyle Evans , Wainer dos Santos Moschetta , Riku Voipio , Ilya Leoshkevich Subject: [PATCH v2 10/14] gdbstub: Expose TARGET_SIGTRAP in a target-agnostic way Date: Wed, 7 Feb 2024 16:38:08 +0000 Message-Id: <20240207163812.3231697-11-alex.bennee@linaro.org> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20240207163812.3231697-1-alex.bennee@linaro.org> References: <20240207163812.3231697-1-alex.bennee@linaro.org> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=2a00:1450:4864:20::330; envelope-from=alex.bennee@linaro.org; helo=mail-wm1-x330.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=unavailable autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZohoMail-DKIM: pass (identity @linaro.org) X-ZM-MESSAGEID: 1707323991608100003 From: Ilya Leoshkevich The upcoming syscall catchpoint support needs to send SIGTRAP stop packets to GDB. Being able to compile this support only once for all targets is a good thing, and it requires hiding TARGET_SIGTRAP behind a function call. Signed-off-by: Ilya Leoshkevich Message-Id: <20240202152506.279476-2-iii@linux.ibm.com> Signed-off-by: Alex Benn=C3=A9e Reviewed-by: Philippe Mathieu-Daud=C3=A9 --- gdbstub/internals.h | 1 + gdbstub/user-target.c | 5 +++++ 2 files changed, 6 insertions(+) diff --git a/gdbstub/internals.h b/gdbstub/internals.h index 5c0c725e54c..aeb0d9b5377 100644 --- a/gdbstub/internals.h +++ b/gdbstub/internals.h @@ -136,6 +136,7 @@ void gdb_append_thread_id(CPUState *cpu, GString *buf); int gdb_get_cpu_index(CPUState *cpu); unsigned int gdb_get_max_cpus(void); /* both */ bool gdb_can_reverse(void); /* softmmu, stub for user */ +int gdb_target_sigtrap(void); /* user */ =20 void gdb_create_default_process(GDBState *s); =20 diff --git a/gdbstub/user-target.c b/gdbstub/user-target.c index c4bba4c72c7..b7d4c37cd81 100644 --- a/gdbstub/user-target.c +++ b/gdbstub/user-target.c @@ -418,3 +418,8 @@ void gdb_handle_query_xfer_exec_file(GArray *params, vo= id *user_ctx) ts->bprm->filename + offset); gdb_put_strbuf(); } + +int gdb_target_sigtrap(void) +{ + return TARGET_SIGTRAP; +} --=20 2.39.2 From nobody Tue Nov 26 12:43:47 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass(p=none dis=none) header.from=linaro.org ARC-Seal: i=1; a=rsa-sha256; t=1707324053; cv=none; d=zohomail.com; s=zohoarc; b=gGcePd7ZALoB1k2xQaodg99yVFDtD3qORqdwQfAjwwlT6vdmJz3bI0A7iRBD3uMiU4yzaC50iMs3+QKAzGGneQZ6xTwma87hnlUsFYSZb4ulSiWrJ+dUsHZnFs7TEDGiX8oFoEkx3pujsCHCceEQx8jRhbzbDrnZXdv/YU8ETEo= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1707324053; h=Content-Type:Content-Transfer-Encoding:Cc:Cc:Date:Date:From:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:Subject:To:To:Message-Id:Reply-To; bh=NZEnJqnRtjHTYADU54FKGw8u/qLIoqp7a6/Lc+0JhOI=; b=S6WEkVPsQLd8YGatV4r0s04p4BnGRBggYcloKYcTAiLMD+a3u6x4uWvv1o3Jjb4vv2VdKvRdU3Um7/yJQQ3vPPbRR456t7KlTonJbwuku7t2NSUxeMvoSGxAFNhecgCPEYBCpwNnuhE13Jl1q+4qliDqQS8FBJehluhTy1hj6BI= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 170732405305684.8528139534028; Wed, 7 Feb 2024 08:40:53 -0800 (PST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rXkwT-00030O-F7; Wed, 07 Feb 2024 11:38:33 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rXkwR-0002yg-EB for qemu-devel@nongnu.org; Wed, 07 Feb 2024 11:38:31 -0500 Received: from mail-wm1-x32b.google.com ([2a00:1450:4864:20::32b]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rXkwO-0006CG-Sl for qemu-devel@nongnu.org; Wed, 07 Feb 2024 11:38:31 -0500 Received: by mail-wm1-x32b.google.com with SMTP id 5b1f17b1804b1-40ff28388a6so7630565e9.1 for ; Wed, 07 Feb 2024 08:38:28 -0800 (PST) Received: from draig.lan ([85.9.250.243]) by smtp.gmail.com with ESMTPSA id b15-20020a05600010cf00b0033b4e58746asm1809148wrx.69.2024.02.07.08.38.17 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 07 Feb 2024 08:38:24 -0800 (PST) Received: from draig.lan (localhost [IPv6:::1]) by draig.lan (Postfix) with ESMTP id 292D85F7B1; Wed, 7 Feb 2024 16:38:13 +0000 (GMT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1707323907; x=1707928707; darn=nongnu.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=NZEnJqnRtjHTYADU54FKGw8u/qLIoqp7a6/Lc+0JhOI=; b=gfcUw6FdsXwGE1FD/EB8khiaSdJWBLoVSCkCwzub66Pt9ORycJw6qomC4Ax0KEkTg+ 5pVXQwcuZxwr4HBP0vFIKWf02jbs/vDZ/Zslg+EyWGXoLuhpbBJKR+FfnTBc/Iy09MqB k/Vcl8lSdoG0koikOSBl1HNosyZTkED0pKCUY1qxahZoTCMCb2U/r674Y+v+ezb32kxA Wv3ZbEnZTGYFd8YxQqRerN5ELJR8so8nNUZyVAXvQme0IwOzHt/gvhgM1YSxXmJD/f3Y 4ECXlDQGaprGub9HHWStS46XBRUGsOZQxJYk/Pv+Va8NX25tYLSK3oC3y1sK9dTqk/pV 352A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1707323907; x=1707928707; 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=NZEnJqnRtjHTYADU54FKGw8u/qLIoqp7a6/Lc+0JhOI=; b=Rc+oORgAvldGKjsUd/36/udxOjq32YKfCos1CV0JVccCu9m88WLCTeCgWPrasgHUXB KyvVC34gJQNFV+m+ImU1MCTxhopXHw+WM2Zal0Z0gImywsvYX44+9EyEdNL5k17VJZlv 9vV7uqfmFMxR/ehfclzQjfp4ms1E95tKVEUhLSkdS5tzCob2odJTuLn/JmpUDMVgZdOH y7WSI7xZ1JfvL+v6syNc6q11r3ofHeEY1jO6JuUYdsTzQPd9ZMSZNR4Qw9BfCzr+3AkD WWbUn5LyAlHVJyQvz+djbXLipZVPFDBJa7g2eTO4sxu96fy2GodgeOxAwVBPD+TQXtPK wo1w== X-Gm-Message-State: AOJu0Yw0FaBl7ioFoeMh8bDMECloRdFwc3Vbr9RtwwT7vHPxdZXwQRCX rEFA7dM1zkJ3B5bnM93BvJ9bENpd1vn39tOtRuqqFNur1lUMkd0kvJ/q4OHkYsY= X-Google-Smtp-Source: AGHT+IEs5VzykUrPZZ/a8E0suhAGYeAe+JVPGaxzI2YNKpjCClE233UfaCR0f5RWvU2Zj+QL6HW2hg== X-Received: by 2002:a05:600c:1553:b0:410:2496:ccdd with SMTP id f19-20020a05600c155300b004102496ccddmr522761wmg.27.1707323907446; Wed, 07 Feb 2024 08:38:27 -0800 (PST) X-Forwarded-Encrypted: i=1; AJvYcCX2twQPA/imKU8TXnjh8RXEOe87TDnJV7LjaUystw7Iipdfu4tRqFIR6jmxZLiZvq8iJJbbUyUtf4zHNMB+e5LW+khol3VhtpuFOqOUoMbF+Ko03I6/r0pPjSAi88ffV7sVliFGwb/eZPufsf8tCuUYnjAh3OSskNSFkveT6EDZnMUBxAVjRlepPxNHnShJRn4PAxzXvomj4+CEuuqmNKkaZ2xJGAkNDuCj+6E2siTpTHVmlmd803nIe2OOGdGmF2q6lvmZ6r6bkk62g8fNRCw4JlH14azS1pNP8cC8mQf7FwSN9zcG4lLVKf5B9Ekhrv+o+Itxh1PI5Jro2/byTmwEGc5FRkH1Eb6B6cqzY701LO6UFFaFuh17a86Z3T8+0E8nrrxERyZ8pXL29bE8FYLrqY25Hy8kdElo/ajUHWuovys/uUIbtFVhhUtGBd/3XtAtNgPBlI0Q5X/Md9xsDm60zH/AOhMRye27qoo6Fiprj6T9WjnolNhmvELVKO+G9TFQKJKh0BCWSfjdZbNOIZLZ+4zHTshILfRU+VUcd5VWRuvow+/9w9pbyt4NFOY3hspWqanUGC0lnuDKrrSufHDhu74Xccrhvx9w9mQl0PCYa+HjGCS3rn2RouU7i28kQCH49irLXqLCiB0ewuQHIvGHN6YuNk5xk5chcipTG/0xgjy1P3t/iWKx704X1yCDuwB0yOHbmaA8twCpazeb8Kt0Fe+ReQ8FNk6t6h3dlkV91fTvdgdtSu1Po+NKixtglHHqO+TqKeueteFkLYiJwFWA1gEkgfp+hrHfo4g/YQOFp0Lp+7HiD3yqsny4W6jiFe4qAnoFonlWW4OQwdl+U+pi1MNw8g7pAT5JgiL8 From: =?UTF-8?q?Alex=20Benn=C3=A9e?= To: qemu-devel@nongnu.org Cc: devel@lists.libvirt.org, Jiaxun Yang , Daniel Henrique Barboza , Chris Wulff , Weiwei Li , Bin Meng , Thomas Huth , qemu-riscv@nongnu.org, Marek Vasut , Liu Zhiwei , Aleksandar Rikalo , =?UTF-8?q?Marc-Andr=C3=A9=20Lureau?= , =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= , Alistair Francis , Warner Losh , Paolo Bonzini , Aurelien Jarno , Beraldo Leal , =?UTF-8?q?Daniel=20P=2E=20Berrang=C3=A9?= , Max Filippov , =?UTF-8?q?Alex=20Benn=C3=A9e?= , Ed Maste , Palmer Dabbelt , Li-Wen Hsu , Laurent Vivier , Kyle Evans , Wainer dos Santos Moschetta , Riku Voipio , Ilya Leoshkevich Subject: [PATCH v2 11/14] gdbstub: Allow specifying a reason in stop packets Date: Wed, 7 Feb 2024 16:38:09 +0000 Message-Id: <20240207163812.3231697-12-alex.bennee@linaro.org> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20240207163812.3231697-1-alex.bennee@linaro.org> References: <20240207163812.3231697-1-alex.bennee@linaro.org> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=2a00:1450:4864:20::32b; envelope-from=alex.bennee@linaro.org; helo=mail-wm1-x32b.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=unavailable autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZohoMail-DKIM: pass (identity @linaro.org) X-ZM-MESSAGEID: 1707324053852100001 From: Ilya Leoshkevich The upcoming syscall catchpoint support needs to send stop packets with an associated reason to GDB. Add an extra parameter to gdb_handlesig() for that, and rename it to gdb_handlesig_reason(). Provide a compatibility wrapper with an old name. Signed-off-by: Ilya Leoshkevich Message-Id: <20240202152506.279476-3-iii@linux.ibm.com> Signed-off-by: Alex Benn=C3=A9e --- include/gdbstub/user.h | 16 ++++++++++++++-- gdbstub/user.c | 5 ++++- 2 files changed, 18 insertions(+), 3 deletions(-) diff --git a/include/gdbstub/user.h b/include/gdbstub/user.h index d392e510c59..1fc43e04af5 100644 --- a/include/gdbstub/user.h +++ b/include/gdbstub/user.h @@ -10,9 +10,10 @@ #define GDBSTUB_USER_H =20 /** - * gdb_handlesig() - yield control to gdb + * gdb_handlesig_reason() - yield control to gdb * @cpu: CPU * @sig: if non-zero, the signal number which caused us to stop + * @reason: stop reason for stop reply packet or NULL * * This function yields control to gdb, when a user-mode-only target * needs to stop execution. If @sig is non-zero, then we will send a @@ -24,7 +25,18 @@ * or 0 if no signal should be delivered, ie the signal that caused * us to stop should be ignored. */ -int gdb_handlesig(CPUState *, int); +int gdb_handlesig_reason(CPUState *, int, const char *); + +/** + * gdb_handlesig() - yield control to gdb + * @cpu CPU + * @sig: if non-zero, the signal number which caused us to stop + * @see gdb_handlesig_reason() + */ +static inline int gdb_handlesig(CPUState *cpu, int sig) +{ + return gdb_handlesig_reason(cpu, sig, NULL); +} =20 /** * gdb_signalled() - inform remote gdb of sig exit diff --git a/gdbstub/user.c b/gdbstub/user.c index dbe1d9b8875..63edca131ab 100644 --- a/gdbstub/user.c +++ b/gdbstub/user.c @@ -121,7 +121,7 @@ void gdb_qemu_exit(int code) exit(code); } =20 -int gdb_handlesig(CPUState *cpu, int sig) +int gdb_handlesig_reason(CPUState *cpu, int sig, const char *reason) { char buf[256]; int n; @@ -141,6 +141,9 @@ int gdb_handlesig(CPUState *cpu, int sig) "T%02xthread:", gdb_target_signal_to_gdb(sig)); gdb_append_thread_id(cpu, gdbserver_state.str_buf); g_string_append_c(gdbserver_state.str_buf, ';'); + if (reason) { + g_string_append(gdbserver_state.str_buf, reason); + } gdb_put_strbuf(); gdbserver_state.allow_stop_reply =3D false; } --=20 2.39.2 From nobody Tue Nov 26 12:43:47 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass(p=none dis=none) header.from=linaro.org ARC-Seal: i=1; a=rsa-sha256; t=1707324027; cv=none; d=zohomail.com; s=zohoarc; b=K4GUxZ+AcGk+3kT195GowF+DAXTXrGI7Ht82MYi4gxXv2iA5NGaci2PDDITVNjFTBq6NEfAyyTKQQeU5VA5JlbUybIuMQsomTQBL9301+aL3tNnmJyz0oXMVU6ZB7SfL067CeKbWx6A45wJz5Qyg9RgV08VkI1wcHrIWQV0NpmI= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1707324027; h=Content-Type:Content-Transfer-Encoding:Cc:Cc:Date:Date:From:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:Subject:To:To:Message-Id:Reply-To; bh=nUnXcCSSh6U29fLbXe/wbWbJ/XTPO8jPvZXYeKxJYts=; b=LoSi0b3LiZx2AdKAE9OXReUkW5omtUsK5CVwz8RpK2NaBh4hbfdwdilfAaHFRsUQk9iD3biUkYm/qw52k/BcKCF0ERX0SAKqluV9++auU/0Da9zJM6MSosoJEPGhfFsiWgmX4u5TGVrrA70v3Qz7gG89J0lfUdGqk1hVERkdgHY= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1707324027835584.8931966572184; Wed, 7 Feb 2024 08:40:27 -0800 (PST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rXkwR-0002yd-Bv; Wed, 07 Feb 2024 11:38:31 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rXkwP-0002wi-9B for qemu-devel@nongnu.org; Wed, 07 Feb 2024 11:38:29 -0500 Received: from mail-wm1-x32c.google.com ([2a00:1450:4864:20::32c]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rXkwM-0006BN-KO for qemu-devel@nongnu.org; Wed, 07 Feb 2024 11:38:29 -0500 Received: by mail-wm1-x32c.google.com with SMTP id 5b1f17b1804b1-40fc22f372cso7350405e9.1 for ; Wed, 07 Feb 2024 08:38:26 -0800 (PST) Received: from draig.lan ([85.9.250.243]) by smtp.gmail.com with ESMTPSA id w8-20020a05600c474800b00410219f126bsm779121wmo.37.2024.02.07.08.38.17 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 07 Feb 2024 08:38:22 -0800 (PST) Received: from draig.lan (localhost [IPv6:::1]) by draig.lan (Postfix) with ESMTP id 424755F94A; Wed, 7 Feb 2024 16:38:13 +0000 (GMT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1707323905; x=1707928705; darn=nongnu.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=nUnXcCSSh6U29fLbXe/wbWbJ/XTPO8jPvZXYeKxJYts=; b=dYPKpNZat1kg7Bzk79dTrSh7xTWlZIFoV++5iZaestZEIoNvUJVpF5OK1mRVtEVluy rLdi0lYkpY7PPq0pyN4utdzDI0zI6n8ofDCsmQRYN8CpSh8My1m99ShWnuRkcIe7W8EQ fj+QxCv0eIAq1fNAmj4djbNJSKFiYyTRXPMFd45TpZ3fiZriYiNb/fXsF+Wn+bJIggzD syxZdBWg9TJkIxqvwAq9nK11Xk4jMjX/D0vxV9EfntcdwSZmkA2n/bQibSt82FVWLU1+ rp2ZiRYH47yn6IyVRRkzlwYXoL8cYieQw4uuE56IzO1hlDM9/yZAmmS/5XwuCrWgjsZn IHMQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1707323905; x=1707928705; 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=nUnXcCSSh6U29fLbXe/wbWbJ/XTPO8jPvZXYeKxJYts=; b=CdxpRqCyWwZ/8P3qlk/rVTuBTYUun3zxUxB5iflr8bp5lptoNhf0n55KG34E5cC3MV RvbggMhzUwN3LdvC6OQktnlJFTFFzRGmg3fDnrvvT2wN1ZoUKzZJo9RE75amqOTwGXlk ulRIM4NDGHZuvR0GmpiB57Q1oEZ9ezmgW02xM8+JHXj/21scNnQRhONqlZWpOoFO6N2X oLhmpnb/1CgIplIZ5dSn5EmTVesAoJ8MCUe/ub7sdwuQqB+cWZJ0gGWzToP3fb0FcgOa DphPK4DHw+JPKN1iBkEww+TBqq55Ywi6JxNZhRaTIQn2nxeIGnnT3NnWMQ7LcIyQenOg yh9g== X-Gm-Message-State: AOJu0YyuOF+B9SK1lSptlLXdxXbWNzi/eo9hDJJ/rWOx5O4qCvDFGOv5 QN60x7GqKtfCpVF+JRbRg0mZ/YAQsmVcnDvotg3IUijZm/HvJaXihUe8j6NeVl4= X-Google-Smtp-Source: AGHT+IHWOH3+Y6dzVMWPSwfE1ua+TKP+nXGejC30x3sF+o/N8E89jj4nClzW6MEa8GwnWbdEZrfvoA== X-Received: by 2002:a05:600c:1910:b0:40e:c6a6:5111 with SMTP id j16-20020a05600c191000b0040ec6a65111mr4417992wmq.11.1707323905332; Wed, 07 Feb 2024 08:38:25 -0800 (PST) X-Forwarded-Encrypted: i=1; AJvYcCWhyaD1vupT/FNfVmORb9ZE7cv2foxFCinjPT9uXP8f9AAyFqzRcblYR8DkLUd4MRMpU80Kh9knP9Xp/N34knFALV1YwEDmfa7ufQFAswE8J+cey7zgurjX40sWDb76CMmQcWtgjhFid5dPrZ5F2JaYOv/gOeuJsNN+t0mwV+O98nDgqrr3vwyLp32/1OFZSInOM2CG9HHeV2CTPvZdVgjiruo0DPrSV3mKh/zx2iI1QWEZtR/RHTvC2exI9SZ1vivntZkp/LBWNESzL1xpg0XskBO1mkpcDf4N6XHvg6plb46ZKMlqtC+7x9yodxM8lUmdOMvZSB4cioBZlM4vXpWRmDkDM8Z03bdZYU4ueKRd0YCkV4kdotAwoSOZ7NmhY+B4cBlQSsnO+8VeVCJw3VKwELEOfjAdIPU3E4S47HZYsUAoGierf4mcmpttDPyD3Gqe601N75ZrTi9RiFD0zbekxRnK9NhLq3KjxF8RgGi5Cc9vN1+JgXylYaf0RY+0ivn1hx3SKXnE3cbJo4BNiArQ4JEGvoa8XfYBg2LTky/dTVCUfFQU2j4OK/l4cWDJCty0CONgxKRZxHLPhbCY+kDxa7u/FLQCjkXlzixFKruSeGJ+4y2acbF7QQxx7zPkkp63gM2cQZQzT0lexbqWcJ/hRVXfkM9kxgT4d3jlzF9O70i9EB728P9UP87Ok2RdcRE59YC02MTk3hW5QDMs/8cKlKdjfP06gRSarINiDPiiOd1mwPBx8oawc1HxlAPqZPcZo1pjaqesKNLItT6FGKhoi2IKFo6lDgaM5VOZVMhJxzwSlNvFs0+wBuDqIMJa9j49ehzX0nmZN0MBRaZr8MmTuLCaswIYsTk3GI1l From: =?UTF-8?q?Alex=20Benn=C3=A9e?= To: qemu-devel@nongnu.org Cc: devel@lists.libvirt.org, Jiaxun Yang , Daniel Henrique Barboza , Chris Wulff , Weiwei Li , Bin Meng , Thomas Huth , qemu-riscv@nongnu.org, Marek Vasut , Liu Zhiwei , Aleksandar Rikalo , =?UTF-8?q?Marc-Andr=C3=A9=20Lureau?= , =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= , Alistair Francis , Warner Losh , Paolo Bonzini , Aurelien Jarno , Beraldo Leal , =?UTF-8?q?Daniel=20P=2E=20Berrang=C3=A9?= , Max Filippov , =?UTF-8?q?Alex=20Benn=C3=A9e?= , Ed Maste , Palmer Dabbelt , Li-Wen Hsu , Laurent Vivier , Kyle Evans , Wainer dos Santos Moschetta , Riku Voipio , Ilya Leoshkevich Subject: [PATCH v2 12/14] gdbstub: Add syscall entry/return hooks Date: Wed, 7 Feb 2024 16:38:10 +0000 Message-Id: <20240207163812.3231697-13-alex.bennee@linaro.org> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20240207163812.3231697-1-alex.bennee@linaro.org> References: <20240207163812.3231697-1-alex.bennee@linaro.org> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=2a00:1450:4864:20::32c; envelope-from=alex.bennee@linaro.org; helo=mail-wm1-x32c.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=unavailable autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZohoMail-DKIM: pass (identity @linaro.org) X-ZM-MESSAGEID: 1707324029755100015 From: Ilya Leoshkevich The upcoming syscall catchpoint support needs to get control on syscall entry and return. Provide the necessary hooks for that, which are no-ops for now. Signed-off-by: Ilya Leoshkevich Message-Id: <20240202152506.279476-4-iii@linux.ibm.com> Signed-off-by: Alex Benn=C3=A9e --- include/gdbstub/user.h | 13 +++++++++++++ include/user/syscall-trace.h | 7 +++++-- gdbstub/user.c | 8 ++++++++ 3 files changed, 26 insertions(+), 2 deletions(-) diff --git a/include/gdbstub/user.h b/include/gdbstub/user.h index 1fc43e04af5..68b6534130c 100644 --- a/include/gdbstub/user.h +++ b/include/gdbstub/user.h @@ -51,5 +51,18 @@ void gdb_signalled(CPUArchState *as, int sig); */ void gdbserver_fork(CPUState *cs); =20 +/** + * gdb_syscall_entry() - inform gdb of syscall entry and yield control to = it + * @cs: CPU + * @num: syscall number + */ +void gdb_syscall_entry(CPUState *cs, int num); + +/** + * gdb_syscall_entry() - inform gdb of syscall return and yield control to= it + * @cs: CPU + * @num: syscall number + */ +void gdb_syscall_return(CPUState *cs, int num); =20 #endif /* GDBSTUB_USER_H */ diff --git a/include/user/syscall-trace.h b/include/user/syscall-trace.h index 557f881a79b..b48b2b2d0ae 100644 --- a/include/user/syscall-trace.h +++ b/include/user/syscall-trace.h @@ -11,6 +11,7 @@ #define SYSCALL_TRACE_H =20 #include "exec/user/abitypes.h" +#include "gdbstub/user.h" #include "qemu/plugin.h" #include "trace/trace-root.h" =20 @@ -20,7 +21,7 @@ * could potentially unify the -strace code here as well. */ =20 -static inline void record_syscall_start(void *cpu, int num, +static inline void record_syscall_start(CPUState *cpu, int num, abi_long arg1, abi_long arg2, abi_long arg3, abi_long arg4, abi_long arg5, abi_long arg6, @@ -29,11 +30,13 @@ static inline void record_syscall_start(void *cpu, int = num, qemu_plugin_vcpu_syscall(cpu, num, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8); + gdb_syscall_entry(cpu, num); } =20 -static inline void record_syscall_return(void *cpu, int num, abi_long ret) +static inline void record_syscall_return(CPUState *cpu, int num, abi_long = ret) { qemu_plugin_vcpu_syscall_ret(cpu, num, ret); + gdb_syscall_return(cpu, num); } =20 =20 diff --git a/gdbstub/user.c b/gdbstub/user.c index 63edca131ab..2ba01c17faf 100644 --- a/gdbstub/user.c +++ b/gdbstub/user.c @@ -502,3 +502,11 @@ void gdb_syscall_handling(const char *syscall_packet) gdb_put_packet(syscall_packet); gdb_handlesig(gdbserver_state.c_cpu, 0); } + +void gdb_syscall_entry(CPUState *cs, int num) +{ +} + +void gdb_syscall_return(CPUState *cs, int num) +{ +} --=20 2.39.2 From nobody Tue Nov 26 12:43:47 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass(p=none dis=none) header.from=linaro.org ARC-Seal: i=1; a=rsa-sha256; t=1707324041; cv=none; d=zohomail.com; s=zohoarc; b=Zq7i5qLUATo6cQePYo9waP4r6JAwIQcRgjVNzIzPzKBe1SHPjlq1qsuODS6qnDlHM281+t3/1u75EttRgxfhL7D3FI+73RSm0VGsh77RarLGLojc4Vz3XYusT23Gg+Q+Tfe0RdzOOaZxoqyaHOpotKfHTkpITcvv0sDIwpvl9Zw= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1707324041; h=Content-Type:Content-Transfer-Encoding:Cc:Cc:Date:Date:From:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:Subject:To:To:Message-Id:Reply-To; bh=z2vgt/WjJf2HA0KugTv1vBfaaG9X3Kl8endzGiNtDT8=; b=A+eIVF+mSloqO/xu6F3QTklLeCu560jfnzMEpcqvVWxrZhjEy0Je+VX5joDoHPPNgF/c4YCMHssgr2o5pqmZByvdBfIeG0fP5ll0bZIMbNGHk0uaSJ210NhtHe/OTGWKw9hCgWuuvcWe5w98qAk7IOFIBAmSLAXRTjUh80PkZrg= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1707324041629110.08997101639318; Wed, 7 Feb 2024 08:40:41 -0800 (PST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rXkwT-00030Z-R6; Wed, 07 Feb 2024 11:38:33 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rXkwS-0002zp-Cx for qemu-devel@nongnu.org; Wed, 07 Feb 2024 11:38:32 -0500 Received: from mail-wr1-x42d.google.com ([2a00:1450:4864:20::42d]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rXkwP-0006CO-9M for qemu-devel@nongnu.org; Wed, 07 Feb 2024 11:38:32 -0500 Received: by mail-wr1-x42d.google.com with SMTP id ffacd0b85a97d-33b0e5d1e89so735567f8f.0 for ; Wed, 07 Feb 2024 08:38:28 -0800 (PST) Received: from draig.lan ([85.9.250.243]) by smtp.gmail.com with ESMTPSA id y16-20020a5d6150000000b0033b443a7aa7sm1829371wrt.97.2024.02.07.08.38.17 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 07 Feb 2024 08:38:24 -0800 (PST) Received: from draig.lan (localhost [IPv6:::1]) by draig.lan (Postfix) with ESMTP id 5A4ED5F951; Wed, 7 Feb 2024 16:38:13 +0000 (GMT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1707323908; x=1707928708; darn=nongnu.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=z2vgt/WjJf2HA0KugTv1vBfaaG9X3Kl8endzGiNtDT8=; b=Rger1u/EA5hB/OPg2o7wlBnAcehbs/KAx/zLTduzfZafJEs6DB9/oc8qVhdW8kvV7c KO4UugWVRYcku7q5HwRZBENFfyD/LVMqFzpXexKtfs71rZn5fihPz8IC1TyqRORti0Yu GuQWU37dV0Qs2X54ore7gJp83PJ3El/56+ZJnSzuf32SSsKuUR0+S7X1lceR6qHTq33n LXGhlzfW7YTHqYqdvVsCQtBnZJ48NSfNTbv38GRYVZ7Maw7+84S2Pie1pmkgWLHfGZ+G 8K0kBlcaBP/yVnH5KDcFpZ5nIex+ZaQS5EJhBuA+L/bRjDy3iS1krD+fvFv3WvbG7S/y RYZw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1707323908; x=1707928708; 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=z2vgt/WjJf2HA0KugTv1vBfaaG9X3Kl8endzGiNtDT8=; b=hKy4OYw33327U6uMpqSgVF+1S3uG+CzeNxcGpjhQ4bjjKC+r/+HMH0AamllGGsupfH AzzdIe9e27nNQ0K+ZNgiHEuZ3YUUu+1+YQD/hbeDEJWlUQL96FvtBDNhvwj33W07xrlo NRKt15zaQTMnFF4wKOGUrQlQtzJYmwh5Kz355wybuzJe2xOBTE24EuAjR/d6cmISXFE7 mCxigxjqdE4mfn/X4L5q4oWQ5/4MELK1rsWPblsNNYRLzEhMIEyI1w0AS0SIdcILmdoH vsEgntxQoT3Wlxqg3J/efofWHSNJZjujr8qoYWqrXLB2MaMNxueNVrdFmiKrXXc7kABY cOJw== X-Gm-Message-State: AOJu0YzGB/d2RfBxh8BxNIUrvcu7B36tX9do7ma1ZbMI1xQ4wO3NCFiZ 9D+YjOkHRhNAiYSxknJrXxZDrx5/wNXEZSqR7siAUQXCpc/Dsmrxwhm1lMaV+p4= X-Google-Smtp-Source: AGHT+IEKKrSH9TvE15V4DeeR704L/Bk2TeAzEHO0Yq3f62/MiSfujIaWP0z45XJEoBodYKePZS99pQ== X-Received: by 2002:a5d:4523:0:b0:33b:1ac8:aebe with SMTP id j3-20020a5d4523000000b0033b1ac8aebemr4863574wra.44.1707323907793; Wed, 07 Feb 2024 08:38:27 -0800 (PST) X-Forwarded-Encrypted: i=1; AJvYcCUgaPKcBeGwVcF6F+SJ0hnc3uIR62pO2+ap1TjSypdzohrcatPumrhMX0akevBZfKLOfqcrDRzsQIQjrFGyyNlrG7SAcJZXQMoDCcMReckIaeAV8Z//SGrX0AHMjt7RW7q2xOws8W5fKApdCc4o9woSEsq8F98zbeBAUtxWMcBOVjK3rHrxSd2ueaOT6AzEOcpkGhcBUdXtH2uy8Mo82p0Z9SJ/yivEjR5YWtfcJ2M6hnR+SBQ4YhsFWJwurXcSXeJto8KRGLlqZBuaQmLqklmhaJ128nbNu/UomVUd+29BYe9aBe9EfCaL3DL2WiOjeJUEQQ5jbddFRfsWWBWdWvDuV0fm3SqajHpb/1uNbU3NktxQVK8j4aZ+9z+H8PeNPVUytM14riF1MpNEQbs4DLmDJsNTyefVQm9VOfCjZcNBJ5Qrh/NNx8sXqn1F5QLzP/lopJCu0pkqVx/GMmeSHmBOjc//pqStLNe8s2JBtdK43q+2lLwsOvFpL4RZnG6N2X8fd5cvLUIhHyGvGm1aYvC6Wb6a27UoNoCHwmaK89VH/AST6QuZubu2FNFT31j5L9I9+bvV9CxJxZgwrt8MfuQvY2OoFqids2x2v0q1tpzyGmMX6KWNJao940ZKguac0uKBZ0+YKhKQjPS5mlM7/9vC3pXZzU+Z3GgFL9xQ+mf+OF5DxTyciLF/82OZkJ3sM6TU2CSQ4ojpE78WblY33uOt/l3Mr6k/YwoTSDlJ+ZhXBvAb5AgVBFUbBlMVyixS7wCfqP6PRnqeB77Mfm0ZbEX2YugAcUrqEnr+YccYcsthugdgLC4Q/+jBOptYfFbOktfRhhnFwW1P/JlgCtK/QJk4+tPJ1srbDPQ2k61Y From: =?UTF-8?q?Alex=20Benn=C3=A9e?= To: qemu-devel@nongnu.org Cc: devel@lists.libvirt.org, Jiaxun Yang , Daniel Henrique Barboza , Chris Wulff , Weiwei Li , Bin Meng , Thomas Huth , qemu-riscv@nongnu.org, Marek Vasut , Liu Zhiwei , Aleksandar Rikalo , =?UTF-8?q?Marc-Andr=C3=A9=20Lureau?= , =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= , Alistair Francis , Warner Losh , Paolo Bonzini , Aurelien Jarno , Beraldo Leal , =?UTF-8?q?Daniel=20P=2E=20Berrang=C3=A9?= , Max Filippov , =?UTF-8?q?Alex=20Benn=C3=A9e?= , Ed Maste , Palmer Dabbelt , Li-Wen Hsu , Laurent Vivier , Kyle Evans , Wainer dos Santos Moschetta , Riku Voipio , Ilya Leoshkevich Subject: [PATCH v2 13/14] gdbstub: Implement catching syscalls Date: Wed, 7 Feb 2024 16:38:11 +0000 Message-Id: <20240207163812.3231697-14-alex.bennee@linaro.org> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20240207163812.3231697-1-alex.bennee@linaro.org> References: <20240207163812.3231697-1-alex.bennee@linaro.org> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=2a00:1450:4864:20::42d; envelope-from=alex.bennee@linaro.org; helo=mail-wr1-x42d.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZohoMail-DKIM: pass (identity @linaro.org) X-ZM-MESSAGEID: 1707324043833100003 From: Ilya Leoshkevich GDB supports stopping on syscall entry and exit using the "catch syscall" command. It relies on 3 packets, which are currently not supported by QEMU: * qSupported:QCatchSyscalls+ [1] * QCatchSyscalls: [2] * T05syscall_entry: and T05syscall_return: [3] Implement generation and handling of these packets. [1] https://sourceware.org/gdb/current/onlinedocs/gdb.html/General-Query-Pa= ckets.html#qSupported [2] https://sourceware.org/gdb/current/onlinedocs/gdb.html/General-Query-Pa= ckets.html#QCatchSyscalls [3] https://sourceware.org/gdb/current/onlinedocs/gdb.html/Stop-Reply-Packe= ts.html Signed-off-by: Ilya Leoshkevich Message-Id: <20240202152506.279476-5-iii@linux.ibm.com> [AJB: GString -> g_strdup_printf] Signed-off-by: Alex Benn=C3=A9e --- gdbstub/internals.h | 1 + gdbstub/gdbstub.c | 9 +++++ gdbstub/user.c | 91 +++++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 101 insertions(+) diff --git a/gdbstub/internals.h b/gdbstub/internals.h index aeb0d9b5377..56b7c13b750 100644 --- a/gdbstub/internals.h +++ b/gdbstub/internals.h @@ -195,6 +195,7 @@ void gdb_handle_v_file_close(GArray *params, void *user= _ctx); /* user */ void gdb_handle_v_file_pread(GArray *params, void *user_ctx); /* user */ void gdb_handle_v_file_readlink(GArray *params, void *user_ctx); /* user */ void gdb_handle_query_xfer_exec_file(GArray *params, void *user_ctx); /* u= ser */ +void gdb_handle_set_catch_syscalls(GArray *params, void *user_ctx); /* use= r */ =20 void gdb_handle_query_attached(GArray *params, void *user_ctx); /* both */ =20 diff --git a/gdbstub/gdbstub.c b/gdbstub/gdbstub.c index 46d752bbc2c..7e73e916bdc 100644 --- a/gdbstub/gdbstub.c +++ b/gdbstub/gdbstub.c @@ -1617,6 +1617,7 @@ static void handle_query_supported(GArray *params, vo= id *user_ctx) if (gdbserver_state.c_cpu->opaque) { g_string_append(gdbserver_state.str_buf, ";qXfer:auxv:read+"); } + g_string_append(gdbserver_state.str_buf, ";QCatchSyscalls+"); #endif g_string_append(gdbserver_state.str_buf, ";qXfer:exec-file:read+"); #endif @@ -1810,6 +1811,14 @@ static const GdbCmdParseEntry gdb_gen_set_table[] = =3D { .schema =3D "l0" }, #endif +#if defined(CONFIG_USER_ONLY) + { + .handler =3D gdb_handle_set_catch_syscalls, + .cmd =3D "CatchSyscalls:", + .cmd_startswith =3D 1, + .schema =3D "s0", + }, +#endif }; =20 static void handle_gen_query(GArray *params, void *user_ctx) diff --git a/gdbstub/user.c b/gdbstub/user.c index 2ba01c17faf..14918d1a217 100644 --- a/gdbstub/user.c +++ b/gdbstub/user.c @@ -10,6 +10,7 @@ */ =20 #include "qemu/osdep.h" +#include "qemu/bitops.h" #include "qemu/cutils.h" #include "qemu/sockets.h" #include "exec/hwaddr.h" @@ -21,11 +22,20 @@ #include "trace.h" #include "internals.h" =20 +#define GDB_NR_SYSCALLS 1024 +typedef unsigned long GDBSyscallsMask[BITS_TO_LONGS(GDB_NR_SYSCALLS)]; + /* User-mode specific state */ typedef struct { int fd; char *socket_path; int running_state; + /* + * Store syscalls mask without memory allocation in order to avoid + * implementing synchronization. + */ + bool catch_all_syscalls; + GDBSyscallsMask catch_syscalls_mask; } GDBUserState; =20 static GDBUserState gdbserver_user_state; @@ -503,10 +513,91 @@ void gdb_syscall_handling(const char *syscall_packet) gdb_handlesig(gdbserver_state.c_cpu, 0); } =20 +static bool should_catch_syscall(int num) +{ + if (gdbserver_user_state.catch_all_syscalls) { + return true; + } + if (num < 0 || num >=3D GDB_NR_SYSCALLS) { + return false; + } + return test_bit(num, gdbserver_user_state.catch_syscalls_mask); +} + void gdb_syscall_entry(CPUState *cs, int num) { + if (should_catch_syscall(num)) { + g_autofree char *reason =3D g_strdup_printf("syscall_entry:%x;", n= um); + gdb_handlesig_reason(cs, gdb_target_sigtrap(), reason); + } } =20 void gdb_syscall_return(CPUState *cs, int num) { + if (should_catch_syscall(num)) { + g_autofree char *reason =3D g_strdup_printf("syscall_return:%x;", = num); + gdb_handlesig_reason(cs, gdb_target_sigtrap(), reason); + } +} + +void gdb_handle_set_catch_syscalls(GArray *params, void *user_ctx) +{ + const char *param =3D get_param(params, 0)->data; + GDBSyscallsMask catch_syscalls_mask; + bool catch_all_syscalls; + unsigned int num; + const char *p; + + /* "0" means not catching any syscalls. */ + if (strcmp(param, "0") =3D=3D 0) { + gdbserver_user_state.catch_all_syscalls =3D false; + memset(gdbserver_user_state.catch_syscalls_mask, 0, + sizeof(gdbserver_user_state.catch_syscalls_mask)); + gdb_put_packet("OK"); + return; + } + + /* "1" means catching all syscalls. */ + if (strcmp(param, "1") =3D=3D 0) { + gdbserver_user_state.catch_all_syscalls =3D true; + gdb_put_packet("OK"); + return; + } + + /* + * "1;..." means catching only the specified syscalls. + * The syscall list must not be empty. + */ + if (param[0] =3D=3D '1' && param[1] =3D=3D ';') { + catch_all_syscalls =3D false; + memset(catch_syscalls_mask, 0, sizeof(catch_syscalls_mask)); + for (p =3D ¶m[2];; p++) { + if (qemu_strtoui(p, &p, 16, &num) || (*p && *p !=3D ';')) { + goto err; + } + if (num >=3D GDB_NR_SYSCALLS) { + /* + * Fall back to reporting all syscalls. Reporting extra + * syscalls is inefficient, but the spec explicitly allows= it. + * Keep parsing in case there is a syntax error ahead. + */ + catch_all_syscalls =3D true; + } else { + set_bit(num, catch_syscalls_mask); + } + if (!*p) { + break; + } + } + gdbserver_user_state.catch_all_syscalls =3D catch_all_syscalls; + if (!catch_all_syscalls) { + memcpy(gdbserver_user_state.catch_syscalls_mask, + catch_syscalls_mask, sizeof(catch_syscalls_mask)); + } + gdb_put_packet("OK"); + return; + } + +err: + gdb_put_packet("E00"); } --=20 2.39.2 From nobody Tue Nov 26 12:43:47 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass(p=none dis=none) header.from=linaro.org ARC-Seal: i=1; a=rsa-sha256; t=1707323964; cv=none; d=zohomail.com; s=zohoarc; b=JwJJQLXpzpJcvBBUphp6vE1tb0RZyQdA7Ud6BoHBadSMe2zGoMO4H0VvRTaWKCqkSycWQKm2sVW3v0LyR8wr3Ac1BZp62FvlqGDXe3rn6D/BjtvP1zMzzAQam10Is86rKCFBYgw4OAbOBKb9huzjJ0fCuuG1auUV2KdmIAGX8ac= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1707323964; h=Content-Type:Content-Transfer-Encoding:Cc:Cc:Date:Date:From:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:Subject:To:To:Message-Id:Reply-To; bh=5KJnAd/m0KGguzc/ly2OcxGET3ckYILVYJ7JRk/PTxI=; b=YF54AOIlEr/k4+yH/qCddopxlWv+fyv6b/l4T0NJuo4lAa7BHFi02FhG05WPhU4FznwDMZhGYAHnqSv9oDYliJu+9fewuHQDCG/sdmXx6IXOsO+OithLGgmgxpTUnEw+wtji0WfinySLgKV4kGgio+HhZE4GQ++Gz+QNiN36kV8= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1707323964127712.1412621813515; Wed, 7 Feb 2024 08:39:24 -0800 (PST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rXkwV-00031f-Pk; Wed, 07 Feb 2024 11:38:35 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rXkwS-0002zh-4y for qemu-devel@nongnu.org; Wed, 07 Feb 2024 11:38:32 -0500 Received: from mail-wr1-x429.google.com ([2a00:1450:4864:20::429]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rXkwN-0006Bb-91 for qemu-devel@nongnu.org; Wed, 07 Feb 2024 11:38:31 -0500 Received: by mail-wr1-x429.google.com with SMTP id ffacd0b85a97d-33b0f36b808so658469f8f.3 for ; Wed, 07 Feb 2024 08:38:26 -0800 (PST) Received: from draig.lan ([85.9.250.243]) by smtp.gmail.com with ESMTPSA id d11-20020adff2cb000000b0033b278cf5fesm1852996wrp.102.2024.02.07.08.38.17 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 07 Feb 2024 08:38:24 -0800 (PST) Received: from draig.lan (localhost [IPv6:::1]) by draig.lan (Postfix) with ESMTP id 761775F9CF; Wed, 7 Feb 2024 16:38:13 +0000 (GMT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1707323905; x=1707928705; darn=nongnu.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=5KJnAd/m0KGguzc/ly2OcxGET3ckYILVYJ7JRk/PTxI=; b=s6PDiUegFVlSnXH8YTlwNfbdqhWilqYNpzqCzBuNhDAuDdZ361PB+GxrBaJ+Bf0NCK +Jx2dqdVkf+sZSyH84ucV4gmrk8/ZJb1vnyEOI9RM/Z+kk8Au2i8fibQZ11u/D1dDHLi CRsntqg3/qeYd0mEb/Nw+vEUqu3Af4yGqf9zsYF5xpnMjNB9zVyWwI/PA0wT8jz20IPy OV/k2NwtOsrYpfaMLKXUgoX7UM6AEkEm3wEyoRmKbU+xmtsWL+Gsp0ST71XB2swr0wBb WtWTyTRFAfcAkKBOyMMOADVlzrkRq4XMSQAszDePWd3I23YdZuwOTcj5dqxScCW22yAK G42Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1707323905; x=1707928705; 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=5KJnAd/m0KGguzc/ly2OcxGET3ckYILVYJ7JRk/PTxI=; b=sN/vR0xl3kRSRPzDffVvu3sCkDfcZh5y1YJqLtfX1+bOk1un8WvZGePhj/WEZ9GRcf aaWBPjmiJhKecMC7eFycZSCHoVpxlMjPntUna7J9i9vGVZxm4Sk1Yp6r0XFIiItF0q9i LllpMoDkIUxfF34iXd4MVrnPqzxrCGbwr2QfPmzziBrlGFIecwMyinuzN3hQuehrUQKj OXLyny90OqXYiaLUXrc2jhAiYFcUgjp6D82e/Y1Ydwu1QOexR02plGPTHQ1MGyvb6ntC DUzgmfmTz0qkbhn/CqRmHYOgVtvjIy1auxvyj4tDgbOcFJfNjofJPt4IuMRNXe/Gptd9 DI2Q== X-Gm-Message-State: AOJu0Ywt6FX4YuVtBdjFUeYVSIlHv4O6VE7ygo/JlTmbv5CsJ+MG4nga qJ2pfI5j4K22LdyRAAZfjUQtyEAp09qCk9Df+cLjPsCLJyottQ2wuTGtpcwSjmI= X-Google-Smtp-Source: AGHT+IF9VickhyecZOJwME0QBAJAMHWcwaQQF970D9Gx+XhaMtGVndh8N+3ffgzOPMo3aKT0qGuCZw== X-Received: by 2002:adf:ecc3:0:b0:33b:37f6:2388 with SMTP id s3-20020adfecc3000000b0033b37f62388mr4149932wro.58.1707323905659; Wed, 07 Feb 2024 08:38:25 -0800 (PST) X-Forwarded-Encrypted: i=1; AJvYcCV4xwNCVOQMPGULI/JYjc6IgG/O8Um2nQJ+6HOUuNEu2CqPr5Rj+E8wUXYIkPZTciNs9c6zu7wk7b8BE2gYNUeRQi0ZpqinY9LeYQ7f83qubpvSdlIu4Er9c43b/1nFBYCM5uBx6UMWHFSO9EbAFxMjAU3KjnCOKXhT6JwUqyyXyqItny7G4xcN3oyD2w4vXkzSWYukbrABOzyoD2VYXmRe7eocIEZJ14esXqKuhT/4fDVJ2XdF7bxQj2nTHOfK08IGGqzhC34hwmpx+DpERXic05oZzvHGRBWBMGGlxt9Sr5HcVfSh5jQgoK5Qj/AfvI5N6Tt335AWI1K2SyhF51uvBHVkPUPGpIe9kEHk+hN7M973woNexzYMWktqqpO9txLjplLtesr/nzEHBZf7S+tUnfdt+aYovEuC4lKqczw9DhRRgxJVwImupnAO39r/lYxdmedXtua0tcXmCF/gkjc+ePOLNzs14abo1bARa9jeV0LHUHak1eoB/PDKmhrMMHeAVTXPQnNPTtXAW5ihNlWsiH6KHEk90HU5Eihr3J6yqk7tDHnaqMMBMCtqr7JGCrd2FFOMQZQ9q8t0pIghRiQnqM+a2dbNc3ApnqdwqEerI+cNLV5BUwCd951FCc8nJeQ1ekXFUzYaSJqiBwicOedgCbsh/xoPjamBV91MGC3uZ+oLrqi3SRzEkIhmPpNU4br0gz6Qw/PcD1fBigdQTYLeBdenL07LrjJTOng7k/CPm/x1eiIryBHf6hcebcGYDNALygoWTxWKqeaOMN5FkfY6Tzv9sZBeiTRoZl7dWHm34KP1eUyzZDbUEmGxW6tsn7rSXWr1Tgmrj89eRduEMcg8ewcDfIEZ25MfklRv From: =?UTF-8?q?Alex=20Benn=C3=A9e?= To: qemu-devel@nongnu.org Cc: devel@lists.libvirt.org, Jiaxun Yang , Daniel Henrique Barboza , Chris Wulff , Weiwei Li , Bin Meng , Thomas Huth , qemu-riscv@nongnu.org, Marek Vasut , Liu Zhiwei , Aleksandar Rikalo , =?UTF-8?q?Marc-Andr=C3=A9=20Lureau?= , =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= , Alistair Francis , Warner Losh , Paolo Bonzini , Aurelien Jarno , Beraldo Leal , =?UTF-8?q?Daniel=20P=2E=20Berrang=C3=A9?= , Max Filippov , =?UTF-8?q?Alex=20Benn=C3=A9e?= , Ed Maste , Palmer Dabbelt , Li-Wen Hsu , Laurent Vivier , Kyle Evans , Wainer dos Santos Moschetta , Riku Voipio , Ilya Leoshkevich Subject: [PATCH v2 14/14] tests/tcg: Add the syscall catchpoint gdbstub test Date: Wed, 7 Feb 2024 16:38:12 +0000 Message-Id: <20240207163812.3231697-15-alex.bennee@linaro.org> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20240207163812.3231697-1-alex.bennee@linaro.org> References: <20240207163812.3231697-1-alex.bennee@linaro.org> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=2a00:1450:4864:20::429; envelope-from=alex.bennee@linaro.org; helo=mail-wr1-x429.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, T_SCC_BODY_TEXT_LINE=-0.01, T_SPF_TEMPERROR=0.01 autolearn=unavailable autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZohoMail-DKIM: pass (identity @linaro.org) X-ZM-MESSAGEID: 1707323965705100007 From: Ilya Leoshkevich Check that adding/removing syscall catchpoints works. Reviewed-by: Alex Benn=C3=A9e Signed-off-by: Ilya Leoshkevich Message-Id: <20240202152506.279476-6-iii@linux.ibm.com> Signed-off-by: Alex Benn=C3=A9e --- tests/tcg/multiarch/catch-syscalls.c | 51 ++++++++++++++++++ tests/tcg/multiarch/Makefile.target | 10 +++- tests/tcg/multiarch/gdbstub/catch-syscalls.py | 53 +++++++++++++++++++ 3 files changed, 113 insertions(+), 1 deletion(-) create mode 100644 tests/tcg/multiarch/catch-syscalls.c create mode 100644 tests/tcg/multiarch/gdbstub/catch-syscalls.py diff --git a/tests/tcg/multiarch/catch-syscalls.c b/tests/tcg/multiarch/cat= ch-syscalls.c new file mode 100644 index 00000000000..d1ff1936a7a --- /dev/null +++ b/tests/tcg/multiarch/catch-syscalls.c @@ -0,0 +1,51 @@ +/* + * Test GDB syscall catchpoints. + * + * SPDX-License-Identifier: GPL-2.0-or-later + */ +#define _GNU_SOURCE +#include +#include + +const char *catch_syscalls_state =3D "start"; + +void end_of_main(void) +{ +} + +int main(void) +{ + int ret =3D EXIT_FAILURE; + char c0 =3D 'A', c1; + int fd[2]; + + catch_syscalls_state =3D "pipe2"; + if (pipe2(fd, 0)) { + goto out; + } + + catch_syscalls_state =3D "write"; + if (write(fd[1], &c0, sizeof(c0)) !=3D sizeof(c0)) { + goto out_close; + } + + catch_syscalls_state =3D "read"; + if (read(fd[0], &c1, sizeof(c1)) !=3D sizeof(c1)) { + goto out_close; + } + + catch_syscalls_state =3D "check"; + if (c0 =3D=3D c1) { + ret =3D EXIT_SUCCESS; + } + +out_close: + catch_syscalls_state =3D "close"; + close(fd[0]); + close(fd[1]); + +out: + catch_syscalls_state =3D "end"; + end_of_main(); + return ret; +} diff --git a/tests/tcg/multiarch/Makefile.target b/tests/tcg/multiarch/Make= file.target index 315a2e13588..e10951a8016 100644 --- a/tests/tcg/multiarch/Makefile.target +++ b/tests/tcg/multiarch/Makefile.target @@ -108,13 +108,21 @@ run-gdbstub-prot-none: prot-none --bin $< --test $(MULTIARCH_SRC)/gdbstub/prot-none.py, \ accessing PROT_NONE memory) =20 +run-gdbstub-catch-syscalls: catch-syscalls + $(call run-test, $@, $(GDB_SCRIPT) \ + --gdb $(GDB) \ + --qemu $(QEMU) --qargs "$(QEMU_OPTS)" \ + --bin $< --test $(MULTIARCH_SRC)/gdbstub/catch-syscalls.py, \ + hitting a syscall catchpoint) + else run-gdbstub-%: $(call skip-test, "gdbstub test $*", "need working gdb with $(patsubst -%= ,,$(TARGET_NAME)) support") endif EXTRA_RUNS +=3D run-gdbstub-sha1 run-gdbstub-qxfer-auxv-read \ run-gdbstub-proc-mappings run-gdbstub-thread-breakpoint \ - run-gdbstub-registers run-gdbstub-prot-none + run-gdbstub-registers run-gdbstub-prot-none \ + run-gdbstub-catch-syscalls =20 # ARM Compatible Semi Hosting Tests # diff --git a/tests/tcg/multiarch/gdbstub/catch-syscalls.py b/tests/tcg/mult= iarch/gdbstub/catch-syscalls.py new file mode 100644 index 00000000000..ccce35902fb --- /dev/null +++ b/tests/tcg/multiarch/gdbstub/catch-syscalls.py @@ -0,0 +1,53 @@ +"""Test GDB syscall catchpoints. + +SPDX-License-Identifier: GPL-2.0-or-later +""" +from test_gdbstub import main, report + + +def check_state(expected): + """Check the catch_syscalls_state value""" + actual =3D gdb.parse_and_eval("catch_syscalls_state").string() + report(actual =3D=3D expected, "{} =3D=3D {}".format(actual, expected)) + + +def run_test(): + """Run through the tests one by one""" + gdb.Breakpoint("main") + gdb.execute("continue") + + # Check that GDB stops for pipe2/read calls/returns, but not for write. + gdb.execute("delete") + try: + gdb.execute("catch syscall pipe2 read") + except gdb.error as exc: + exc_str =3D str(exc) + if "not supported on this architecture" in exc_str: + print("SKIP: {}".format(exc_str)) + return + raise + for _ in range(2): + gdb.execute("continue") + check_state("pipe2") + for _ in range(2): + gdb.execute("continue") + check_state("read") + + # Check that deletion works. + gdb.execute("delete") + gdb.Breakpoint("end_of_main") + gdb.execute("continue") + check_state("end") + + # Check that catch-all works (libc should at least call exit). + gdb.execute("delete") + gdb.execute("catch syscall") + gdb.execute("continue") + gdb.execute("delete") + gdb.execute("continue") + + exitcode =3D int(gdb.parse_and_eval("$_exitcode")) + report(exitcode =3D=3D 0, "{} =3D=3D 0".format(exitcode)) + + +main(run_test) --=20 2.39.2