From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from simark.ca by simark.ca with LMTP id s95EHmOEPWphPhgAWB0awg (envelope-from ) for ; Thu, 25 Jun 2026 15:41:23 -0400 Authentication-Results: simark.ca; dkim=pass (1024-bit key; unprotected) header.d=arm.com header.i=@arm.com header.a=rsa-sha256 header.s=selector1 header.b=a8mQWrRR; dkim=pass (1024-bit key) header.d=arm.com header.i=@arm.com header.a=rsa-sha256 header.s=selector1 header.b=a8mQWrRR; dkim-atps=neutral Received: by simark.ca (Postfix, from userid 112) id 6B9D91E098; Thu, 25 Jun 2026 15:41:23 -0400 (EDT) X-Spam-Checker-Version: SpamAssassin 4.0.1 (2024-03-25) on simark.ca X-Spam-Level: X-Spam-Status: No, score=-5.4 required=5.0 tests=ARC_SIGNED,ARC_VALID,BAYES_00, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,MAILING_LIST_MULTI, RCVD_IN_DNSWL_MED autolearn=ham autolearn_force=no version=4.0.1 Received: from vm01.sourceware.org (vm01.sourceware.org [IPv6:2620:52:6:3111::32]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange x25519 server-signature ECDSA (prime256v1) server-digest SHA256) (No client certificate requested) by simark.ca (Postfix) with ESMTPS id EF4341E070 for ; Thu, 25 Jun 2026 15:41:21 -0400 (EDT) Received: from vm01.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 053204BA7992 for ; Thu, 25 Jun 2026 19:41:20 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 053204BA7992 Authentication-Results: sourceware.org; dkim=pass (1024-bit key, unprotected) header.d=arm.com header.i=@arm.com header.a=rsa-sha256 header.s=selector1 header.b=a8mQWrRR; dkim=pass (1024-bit key) header.d=arm.com header.i=@arm.com header.a=rsa-sha256 header.s=selector1 header.b=a8mQWrRR Received: from MRWPR03CU001.outbound.protection.outlook.com (mail-francesouthazon11011050.outbound.protection.outlook.com [40.107.130.50]) by sourceware.org (Postfix) with ESMTPS id B1A4B4BA23F1 for ; Thu, 25 Jun 2026 19:40:50 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org B1A4B4BA23F1 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=arm.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=arm.com ARC-Filter: OpenARC Filter v1.0.0 sourceware.org B1A4B4BA23F1 Authentication-Results: sourceware.org; arc=pass smtp.remote-ip=40.107.130.50 ARC-Seal: i=3; a=rsa-sha256; d=sourceware.org; s=key; t=1782416451; cv=pass; b=xNX5TbrKm+AZbrD98FgcbiWS7ass0m4mbvebEzMTAafwnWZIzyR8NZiDOA572KWFlO0zBtkDMY9vnRMgs87LF0y6FDBTjMhPUYd++V7eG0j8JKqGv44LDdnnkhd6LTdIa0fKjy5aCjvZDnBaN5m1mCeKU89gg0JBDvsVlDamkQs= ARC-Message-Signature: i=3; a=rsa-sha256; d=sourceware.org; s=key; t=1782416451; c=relaxed/simple; bh=sH2Ns6P/GSuSQyWUkSqGU0U4XVYHu1sS1VkLOyj4J4k=; h=DKIM-Signature:DKIM-Signature:From:To:Subject:Date:Message-ID: MIME-Version; b=qgE55UoFLg4iY/1xXWF2IPZOyWLrtW9DpwAURH7tGi+myXsBnWqx+tThE075pNLUWOP8gpjaJAPen6DCI/5lBCoUhi3wplwkZrW3nNWVtYwLjldt6R4HlChR7DOkFwY0IkoxO7JHDJLKl7zQa2uiGRu463ABAuOsqhdrALKk3Vo= ARC-Authentication-Results: i=3; sourceware.org; dkim=pass (1024-bit key, unprotected) header.d=arm.com header.i=@arm.com header.a=rsa-sha256 header.s=selector1 header.b=a8mQWrRR; dkim=pass (1024-bit key) header.d=arm.com header.i=@arm.com header.a=rsa-sha256 header.s=selector1 header.b=a8mQWrRR DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org B1A4B4BA23F1 ARC-Seal: i=2; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=pass; b=Z85WcfG9GihUjNXg7ks9LMRFpVQGhwgqrSjRdbraKiQ9zuUJIl4lHyGeOt9R8HNJWNSuosS9dWUUFbNI4ItlWciIiEHWQLex/T2d2clggE+nAc/8KA11qhgR3VpGvBZ5QUSc76/0Prwt430K/bvncuxKGKdO1O1P2mZ8OqrxZQVQN9DlAbynpEWHl+5fem7wyZxFJtEbaXTRbTTfu8v7ojmbjbqv4vZl/CW3g15Be0SSOALnbMIn3X+9Ni1wbaUljGd8CFTEs+DxNdx6EBJgn6ucXdijAQcgZEh/2aQ1YdhynkYEyg9mGnNAbhOZVgInpkq2bgrArw5OzsXO2cbFtg== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=nbhwlcGC+uJ+tnM+cKVbzyfwtt1inZbb4VhBh+KU7Mk=; b=Gu7T+EjmUoX+41KUt+JPbrf034ckPmumMFNtWklRrSAqiKS/e0mbpnpx+vXX4Pkx2ze5qBd3S/mv3De4oQEneTvhOrPJF1n4L4gwlhgPYpJzFwZ/HOu7x+S3KKLRfIDQHA4zxLkwZa7SpbsU0hZu7ldCKUE2nFodQfmI0F0FMp34iw3kBJXBT4LZY48mcQLhkABwe9tiBbEbbHC3rfX5qwdNAGAqDCWMe0K+L1l51zqxeltpSyJUInA4YU2ut/yWLJtDE4/WI29MqzGmy+g54xcbbsOmGRReE9VXTik5dgzh0ZkaFiv7qYfLlJ18r1Cb4MdxT7uHknx6jwm6wjZO4g== ARC-Authentication-Results: i=2; mx.microsoft.com 1; spf=pass (sender ip is 4.158.2.129) smtp.rcpttodomain=sourceware.org smtp.mailfrom=arm.com; dmarc=pass (p=none sp=none pct=100) action=none header.from=arm.com; dkim=pass (signature was verified) header.d=arm.com; arc=pass (0 oda=1 ltdi=1 spf=[1,1,smtp.mailfrom=arm.com] dmarc=[1,1,header.from=arm.com]) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=arm.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=nbhwlcGC+uJ+tnM+cKVbzyfwtt1inZbb4VhBh+KU7Mk=; b=a8mQWrRRd6d+C61nLg6wubooXZopscUV/HDEquCZwYN0vaw2OzlXpp/dRpct9a1euj/7X/u7rEVyqnuFYCqVGU4HajsQVQj49EVuXdzY/q1UwYHJ5uatOu+O+X65Bi/Q8v81gNdRY36s4drVYxLOPNvkk4XwzzGm3dQZ2jLnCxE= Received: from DB9PR06CA0013.eurprd06.prod.outlook.com (2603:10a6:10:1db::18) by DBAPR08MB5607.eurprd08.prod.outlook.com (2603:10a6:10:1ae::13) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.21.159.17; Thu, 25 Jun 2026 19:40:46 +0000 Received: from DB1PEPF00039231.eurprd03.prod.outlook.com (2603:10a6:10:1db:cafe::46) by DB9PR06CA0013.outlook.office365.com (2603:10a6:10:1db::18) with Microsoft SMTP Server (version=TLS1_3, cipher=TLS_AES_256_GCM_SHA384) id 15.21.159.16 via Frontend Transport; Thu, 25 Jun 2026 19:40:45 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 4.158.2.129) smtp.mailfrom=arm.com; dkim=pass (signature was verified) header.d=arm.com;dmarc=pass action=none header.from=arm.com; Received-SPF: Pass (protection.outlook.com: domain of arm.com designates 4.158.2.129 as permitted sender) receiver=protection.outlook.com; client-ip=4.158.2.129; helo=outbound-uk1.az.dlp.m.darktrace.com; pr=C Received: from outbound-uk1.az.dlp.m.darktrace.com (4.158.2.129) by DB1PEPF00039231.mail.protection.outlook.com (10.167.8.104) with Microsoft SMTP Server (version=TLS1_3, cipher=TLS_AES_256_GCM_SHA384) id 15.21.181.6 via Frontend Transport; Thu, 25 Jun 2026 19:40:44 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=G4X8oHBIZNiLhM5n2D0fs5cokXawaVxaXaF147lnV/RVoQUkG5jdEyV5XnS+eGjkEdYrSd23RgohCIfoKFeAFtg29C65mBLaKK/mIm7DGhToGI2B6rsKdxYK+lXQzkneVnTjWAt2EK4HtXeFyM7OaQCJMNkW5eZBQj5KztMXB/cmr0ybJj6sxD3/N4Va1vpgT6AMUXuWYXfmbYRpHsdwnpDvGcvQ9mpyCyQK4NrOLkQhCoeiDgrHhkLFIJz0Quu+TRQjMeCrKBvQVpJETZQMcAprRDMfmf4zA3ktcpZVzx/Mo/13kkxxPYM3Y7PQbW8nEVkxq6QUfgg4oVg66ByKNg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=nbhwlcGC+uJ+tnM+cKVbzyfwtt1inZbb4VhBh+KU7Mk=; b=s92iWHt0i/Ge8ezbzmK4VKzuuURfNBysfAJOr2CxgIIAwSNUyTIMKphcXSDz22pjuoie4l0y/jc+zWvo70iWvKQt/jWKLMu326qI6QSywZir2yxAxYEQb9fb5bYVIZ57h1HbEi4mIoHAVKAQWu0nI8ojrGdgTHjv/0fB2+Fgq63t6dZKTe7NfJPBDLCgDITG+FybxlmeCsMLMZTkD6wPZppuHyoaV4onq3nKvNyrijcQqKPkCwaHJRxKRPp9W40LKGPnwsBnBagmNe6zQST8W1hCw69n6zT2MOOqAVEE5zG8misVMeXy995uMgQBrRis+e9v/dVVopVa4bzQ4PuWkA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 172.205.89.229) smtp.rcpttodomain=sourceware.org smtp.mailfrom=arm.com; dmarc=pass (p=none sp=none pct=100) action=none header.from=arm.com; dkim=none (message not signed); arc=none (0) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=arm.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=nbhwlcGC+uJ+tnM+cKVbzyfwtt1inZbb4VhBh+KU7Mk=; b=a8mQWrRRd6d+C61nLg6wubooXZopscUV/HDEquCZwYN0vaw2OzlXpp/dRpct9a1euj/7X/u7rEVyqnuFYCqVGU4HajsQVQj49EVuXdzY/q1UwYHJ5uatOu+O+X65Bi/Q8v81gNdRY36s4drVYxLOPNvkk4XwzzGm3dQZ2jLnCxE= Received: from DU7P250CA0025.EURP250.PROD.OUTLOOK.COM (2603:10a6:10:54f::14) by DB9PR08MB8268.eurprd08.prod.outlook.com (2603:10a6:10:3c4::15) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.21.139.19; Thu, 25 Jun 2026 19:39:40 +0000 Received: from DB1PEPF0003922D.eurprd03.prod.outlook.com (2603:10a6:10:54f:cafe::40) by DU7P250CA0025.outlook.office365.com (2603:10a6:10:54f::14) with Microsoft SMTP Server (version=TLS1_3, cipher=TLS_AES_256_GCM_SHA384) id 15.21.159.16 via Frontend Transport; Thu, 25 Jun 2026 19:39:40 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 172.205.89.229) smtp.mailfrom=arm.com; dkim=none (message not signed) header.d=none;dmarc=pass action=none header.from=arm.com; Received-SPF: Pass (protection.outlook.com: domain of arm.com designates 172.205.89.229 as permitted sender) receiver=protection.outlook.com; client-ip=172.205.89.229; helo=nebula.arm.com; pr=C Received: from nebula.arm.com (172.205.89.229) by DB1PEPF0003922D.mail.protection.outlook.com (10.167.8.100) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.21.181.6 via Frontend Transport; Thu, 25 Jun 2026 19:39:39 +0000 Received: from AZ-NEU-EXJ02.Arm.com (10.240.25.139) by AZ-NEU-EX04.Arm.com (10.240.25.138) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.2562.29; Thu, 25 Jun 2026 19:39:38 +0000 Received: from AZ-NEU-EX04.Arm.com (10.240.25.138) by AZ-NEU-EXJ02.Arm.com (10.240.25.139) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.2562.29; Thu, 25 Jun 2026 19:39:38 +0000 Received: from PF4S4363.arm.com (10.57.40.91) by mail.arm.com (10.240.25.138) with Microsoft SMTP Server id 15.2.2562.29 via Frontend Transport; Thu, 25 Jun 2026 19:39:38 +0000 From: Matthieu Longo To: CC: Thiago Jung Bauermann , Tom Tromey , Andrew Burgess , Matthieu Longo Subject: [PATCH v2] gdb: align siginfo_t with the Linux kernel definition Date: Thu, 25 Jun 2026 20:39:33 +0100 Message-ID: <20260625193933.7994-1-matthieu.longo@arm.com> X-Mailer: git-send-email 2.54.0 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain X-EOPAttributedMessage: 1 X-MS-TrafficTypeDiagnostic: DB1PEPF0003922D:EE_|DB9PR08MB8268:EE_|DB1PEPF00039231:EE_|DBAPR08MB5607:EE_ X-MS-Office365-Filtering-Correlation-Id: 5947eda2-604e-4eb7-a2e2-08ded2f1a619 x-checkrecipientrouted: true NoDisclaimer: true X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam-Untrusted: BCL:0; ARA:13230040|36860700016|1800799024|82310400026|23010399003|376014|18002099003|13003099007|56012099006|11063799006; X-Microsoft-Antispam-Message-Info-Original: 9sFho6d7YI+Ng1tc7ryBTkbf4sVxn24194QBcbdf5CPyOHsyVDSHGwsCknTBlY5vggT84QJ3SPs9sRxiWwViqz8FeUyvJmrpaIbHecWcFCc8SqDx3YEvN4NEwHpgr4il26nKCR/JFd7ylMn+urG8inKmLJKWZE6KIl/A0GKQ0KjEKAdPzr3lfJNsuGTVGdqvCxvtSHQ7V1FmGuhyaVDfmXlPIJYOpol28EdRteKuRYmCFEXFbcGucsLeSG07imQpSTQooiE8m7KhTQhfgT7lGijsytXqEA1kq8VoPDRrWTs/wVIIwFyKw6noE6FZEl+zHGH1I6kf21sYczvFQDQdsRlffJbmUBfus89eVg3MglhBKw1aHkaM7w+s1frpI88sf4KFO5PVzIPSy0WdnavtTeN7kgAHU62zF2r5PMtwPUNf/S/g9KEGQe3qWsX6tlulH6M1t3iqii7WPzFHwjejXsQitoatvA1ycaEyOv2RgLISdOZokytAdfyI9v8W6veROVAUw8IhrlHbhRaPL5ExYcOf+TOO0y+QHqszYwTaOtNICsX2sm7e3Nos8Rb+o+2QOHVJM/XbKiqUzCHsXYOia3KiDwA/7ExWXA27YiLykubmV8YUAO01qVzquTDeZQkfoJy2nvclHq6xSNFtx3YSnVUZiy34YmDoyHOyXQQz5mI7mynrR9juFCWtJpXjriCX8Q175Vee8Omys+ZS7gCyhw== X-Forefront-Antispam-Report-Untrusted: CIP:172.205.89.229; CTRY:IE; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:nebula.arm.com; PTR:InfoDomainNonexistent; CAT:NONE; SFS:(13230040)(36860700016)(1800799024)(82310400026)(23010399003)(376014)(18002099003)(13003099007)(56012099006)(11063799006); DIR:OUT; SFP:1101; X-Exchange-RoutingPolicyChecked: ZQDVxULqxTRFOJq4fopnglKT4aQDqaW0OPz0+yaw5/oQ48A2yBlMIRkXwfzv1JD7L3vuaDi4PlFKVJnMwwf7v0jTfMYnsY78rCa35ZpRQSbD5gKPvkBAsbU5SgY/fY8WXMB3hDxYcEBCMMmFooqhoZlLscDg5GB7a15LHs4RWB3M979oTxqK4UfEpVvT7NRKbL3KNixd7XearsYu5tA+qXPATAM8IuAUWke/pIHmZtXQC3WxIasdL5nTluJu3S6hmfoNLEn9h78QBGr4aVR+scOIxhgwUhlvSkZ1jg5zS6h7DTLPFQlivPIRgOKrq8foTAGIe1FebO5YeHxMqzez4Q== X-MS-Exchange-Transport-CrossTenantHeadersStamped: DB9PR08MB8268 X-MS-Exchange-Transport-CrossTenantHeadersStripped: DB1PEPF00039231.eurprd03.prod.outlook.com X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id-Prvs: ce0cda65-cbb0-4023-c4bd-08ded2f17edf X-Microsoft-Antispam: BCL:0; ARA:13230040|23010399003|36860700016|376014|82310400026|1800799024|35042699022|14060799003|11063799006|56012099006|13003099007|18002099003; X-Microsoft-Antispam-Message-Info: Lf3yiiOAju7U0TgIjOWdH+rdVQbFB5ooxVSzVZ5Mska3emlwxBlf8TAQJP2hg3wkY9j2n3az+WY92ccbCgkcHeKeN6LpIWv6+v6XBEABVVa2iyNISenMNvgY1gIO0NuoM87KPHDBvW7I/p0equ2A5Q2MDAL+0RjCwxRCv6OCZyYGArYduGdrjPHc3CsnJ2MA19sG2wdSON6smYPtlgJOcw7l0Xsb/ncNegmTAaMTUixmXQHkMdoHdZBLYAzKMtF3bDToKRkDq1q1t0vQmt9zS7sMw3HmT2g7XHklSP9DbsXaJWqZH47K9I2kAGpXdNNcdE8vG6Y3RiSl3Pj//xS//mjpBKFpChk+1EooSsicIihjFjheL51+Wa7u7m+X4CRASYYivKWk4rnYTnF/REpLZTjW4VTIZFr2BbndhWTp9EB4H9a32Eb4AhRIdDNVndd7SgsovDWMxmXF+fFeVO43REbb/fpk73/Bk2hugYVXoBRoAIEbgztcvN4wXjxqn3WbOw3er25RU22PfXRiTR58Jo9LMiPDOGFCk0NQQYICJPkC6/2ooJ57m9lujE7TR1CC6I5/Y3y0JL42ae9tkZexlyydThzb8BR4MmOZBULhbOAcrMzuw4D/wRE6oZo2J341a6OYuZPPcazVpYpLXQTPdrFUOplTnyxwC4PGUXLOKF829xwze4yoBUomUPcMB2dM54fRtevYsTHAmsW/NsiOGQ== X-Forefront-Antispam-Report: CIP:4.158.2.129; CTRY:GB; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:outbound-uk1.az.dlp.m.darktrace.com; PTR:InfoDomainNonexistent; CAT:NONE; SFS:(13230040)(23010399003)(36860700016)(376014)(82310400026)(1800799024)(35042699022)(14060799003)(11063799006)(56012099006)(13003099007)(18002099003); DIR:OUT; SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: Gh3wui8v41G5uWVONik+XfMsIdkQ5Ia3EaNKNNnY3DSQAIGfgiuUAa9Q2Jvpi2HG2pXgOMRixiR9fCi43uKYUuxcdKwSowQq6rMj+KPTBdJHAZRJrPBxzZqO8o+BbRqACaAqRqTh+140buz3M8yzC4F1RjyaIVULRuh6sfu/yRyMJTkfH1V61GeckSvuw5v41TULLQwrGHmA1FIWshBGNgj95jbtSZIIVwpmsW8zrF39mbYERvIf4TwtlmM9P+nTwjXoiq+ADyXxAw1gAgGVs/aFyLSmcAfWegxEFHwej7sbGQPxy8D4ZGvCwh8qxCU49awdqtFL1acTubIXee36X/VfrGZi1cEr6oZDBNcGFfrIUiu+uTNFd9jzE8T1K/i0QhxLSzm2OgonTdfACsMr+216xg6J7E7Pr6AUtGoJBTnp0V1Rge6YZ7kLcK9SaG83 X-OriginatorOrg: arm.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 25 Jun 2026 19:40:44.7858 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 5947eda2-604e-4eb7-a2e2-08ded2f1a619 X-MS-Exchange-CrossTenant-Id: f34e5979-57d9-4aaa-ad4d-b122a662184d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=f34e5979-57d9-4aaa-ad4d-b122a662184d; Ip=[4.158.2.129]; Helo=[outbound-uk1.az.dlp.m.darktrace.com] X-MS-Exchange-CrossTenant-AuthSource: DB1PEPF00039231.eurprd03.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: DBAPR08MB5607 X-BeenThere: gdb-patches@sourceware.org X-Mailman-Version: 2.1.30 Precedence: list List-Id: Gdb-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: gdb-patches-bounces~public-inbox=simark.ca@sourceware.org GDB's current definition of siginfo_t is missing many fields present in the Linux kernel definition [1]. These fields are useful for providing detailed, user-friendly diagnostics when a fault occurs. Some new AArch64 extensions, such as Permission Overlay Enhancement used to implement Protection Keys [2], require the debugger to inspect 'si_pkey' alongside 'si_addr' to help the user identify the problematic key. This patch aligns GDB's definition of the __sifields._sigfault member of siginfo_t with the definition from the Linux kernel master branch. [1]: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/ tree/include/uapi/asm-generic/siginfo.h#n69 [2]: https://lore.kernel.org/all/20160212210213.ABC488FA@viggo.jf.intel.com/ Reviewed-by: Thiago Jung Bauermann --- gdb/linux-tdep.c | 46 ++++++++++++++++++++++++++++++++++++++++++++-- 1 file changed, 44 insertions(+), 2 deletions(-) diff --git a/gdb/linux-tdep.c b/gdb/linux-tdep.c index a7381677498..19289cf4b3f 100644 --- a/gdb/linux-tdep.c +++ b/gdb/linux-tdep.c @@ -275,7 +275,7 @@ linux_get_siginfo_type (struct gdbarch *gdbarch) struct type *void_ptr_type; struct type *uid_type, *pid_type; struct type *sigval_type, *clock_type; - struct type *siginfo_type, *sifields_type; + struct type *siginfo_type, *sifields_type, *sigfault_union_type; struct type *type; linux_gdbarch_data = get_linux_gdbarch_data (gdbarch); @@ -285,11 +285,21 @@ linux_get_siginfo_type (struct gdbarch *gdbarch) type_allocator alloc (gdbarch); const struct builtin_type *builtin_types = builtin_type (gdbarch); + struct type *short_type = builtin_types->builtin_short; struct type *int_type = builtin_types->builtin_int; struct type *uint_type = builtin_types->builtin_unsigned_int; struct type *long_type = builtin_types->builtin_long; + struct type *unsigned_long_type = builtin_types->builtin_unsigned_long; + struct type *uint32_type = builtin_types->builtin_uint32; void_ptr_type = lookup_pointer_type (builtin_type (gdbarch)->builtin_void); + /* Compute padding length, i.e. __ADDR_BND_PKEY_PAD. */ + unsigned alignof_void_ptr = type_align (void_ptr_type); + unsigned padding_size = (alignof_void_ptr < sizeof(short) + ? sizeof(short) + : alignof_void_ptr); + struct type *addr_bnd_pkey_padding_type + = init_vector_type (builtin_types->builtin_uint8, padding_size); /* sival_t */ sigval_type = arch_composite_type (gdbarch, NULL, TYPE_CODE_UNION); @@ -364,9 +374,41 @@ linux_get_siginfo_type (struct gdbarch *gdbarch) append_composite_type_field (type, "si_stime", clock_type); append_composite_type_field (sifields_type, "_sigchld", type); - /* _sigfault */ + /* Begin _sigfault's anonymous union. */ + sigfault_union_type = arch_composite_type (gdbarch, NULL, TYPE_CODE_UNION); + /* used on alpha and sparc */ + append_composite_type_field (sigfault_union_type, "si_trapno", int_type); + /* used when si_code=BUS_MCEERR_AR or used when si_code=BUS_MCEERR_AO */ + append_composite_type_field (sigfault_union_type, "si_addr_lsb", short_type); + + /* used when si_code=SEGV_BNDERR */ + type = arch_composite_type (gdbarch, NULL, TYPE_CODE_STRUCT); + append_composite_type_field (type, "_dummy_bnd", addr_bnd_pkey_padding_type); + append_composite_type_field (type, "si_lower", void_ptr_type); + append_composite_type_field (type, "si_upper", void_ptr_type); + append_composite_type_field (sigfault_union_type, "_addr_bnd", type); + + /* used when si_code=SEGV_PKUERR */ + type = arch_composite_type (gdbarch, NULL, TYPE_CODE_STRUCT); + append_composite_type_field (type, "_dummy_pkey", addr_bnd_pkey_padding_type); + append_composite_type_field (type, "si_pkey", uint32_type); + append_composite_type_field (sigfault_union_type, "_addr_pkey", type); + + /* used when si_code=TRAP_PERF */ + type = arch_composite_type (gdbarch, NULL, TYPE_CODE_STRUCT); + append_composite_type_field (type, "si_perf_data", unsigned_long_type); + append_composite_type_field (type, "si_perf_type", uint32_type); + append_composite_type_field (type, "si_perf_flags", uint32_type); + append_composite_type_field (sigfault_union_type, "_perf", type); + + /* End _sigfault's anonymous union. */ + + /* _sigfault is set by SIGILL, SIGFPE, SIGSEGV, SIGBUS, SIGTRAP, SIGEMT */ type = arch_composite_type (gdbarch, NULL, TYPE_CODE_STRUCT); append_composite_type_field (type, "si_addr", void_ptr_type); + /* Since there is no possiblity to declare an anonymous union, + using '_' instead. */ + append_composite_type_field (type, "_", sigfault_union_type); append_composite_type_field (sifields_type, "_sigfault", type); /* _sigpoll */ -- 2.54.0