From patchwork Thu Jan 2 21:22:38 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Lizhi Hou X-Patchwork-Id: 13924964 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 0F28AE77188 for ; Thu, 2 Jan 2025 21:22:59 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 2A78410E11E; Thu, 2 Jan 2025 21:22:59 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=pass (1024-bit key; unprotected) header.d=amd.com header.i=@amd.com header.b="0aDgeIqZ"; dkim-atps=neutral Received: from NAM11-CO1-obe.outbound.protection.outlook.com (mail-co1nam11on2044.outbound.protection.outlook.com [40.107.220.44]) by gabe.freedesktop.org (Postfix) with ESMTPS id 6D51410E11E for ; Thu, 2 Jan 2025 21:22:57 +0000 (UTC) ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=HUpSndJ1b8lOYVcEZ1QCKi4gKQhqfiGAMXeIn7ovEAMylquzhUjQaSDnra8BlB9f9aCBcoWJWiXhNkAoLrh/CPBTMfEk8GUMnt6+K1cdvI2woEzQNAkhl1IlcN6rKZUgff3RugmGTnm78PWOtPNzBcPw3JjM4LGYBLOiB9BUV46vBQMQF2/8fuNhHXnaqx/uopJWccaM64+8EKH0FrmAXmqrEh2P/9E2iyI3Pw/N64/5skrNaiBZJMU7cXngwpB1ypbRNpu0VBQ/c0roLtv8WVThDUXLgubzCFWI0Tub/mBy2SDgvAU0e8AZzghDj88SHrOzKlTgkm3tjVBkx0eHTg== 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=y61Q+m3dkiYoPcf+w1VOyHK4ueH7qAXIHFMVeZY/fYQ=; b=p79MaOsYsvj777xfVHWr5fnyncPa9dKhTvXV2uw61J3q+YkqUil9D+HrczPSbQFRCPC3ebORIljaz6RREa8GmhsfuM2rqhaQafUtc5zNLtFxg9xqcsg/b2SqEaphvySJBpcEaqmBfqhemAvVcjNR/4UNIrreNZt00hiCvmPYQD+KP9r++0JJLIk9pQlUX5m89v9putlSWkpiG2ixp9otArU/vsjUtM07ZwMjlIhHCo4Zyat7Goy74wYD79u8oNPZtYE8FIql0Xm/JWjF0z5HteKq1TtbLzVYXkiN+cHLXwnuEPVsRzqAu7yTMhaWNiWyo4mKGf/Z5tKsh8xJlGlWAQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 165.204.84.17) smtp.rcpttodomain=kernel.org smtp.mailfrom=amd.com; dmarc=pass (p=quarantine sp=quarantine pct=100) action=none header.from=amd.com; dkim=none (message not signed); arc=none (0) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amd.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=y61Q+m3dkiYoPcf+w1VOyHK4ueH7qAXIHFMVeZY/fYQ=; b=0aDgeIqZ6NspWAUyRUNkOmDIxR2622ZWeRY3WJrbfphrgHY8xlzzd3ybx5has0XoG9AkXpqxbiHTk6ZM8GRtsHy8W/GeMpAJhSbFzNI8SEYraMy+u4G+eItlSTlhpJ08Iyn7XsLYtSIK05pMWJYzS0ESWZ2ogNUd8bEpyMjhJO4= Received: from CH2PR07CA0013.namprd07.prod.outlook.com (2603:10b6:610:20::26) by SJ2PR12MB7867.namprd12.prod.outlook.com (2603:10b6:a03:4cd::21) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.8314.11; Thu, 2 Jan 2025 21:22:50 +0000 Received: from CH1PEPF0000AD83.namprd04.prod.outlook.com (2603:10b6:610:20:cafe::a9) by CH2PR07CA0013.outlook.office365.com (2603:10b6:610:20::26) with Microsoft SMTP Server (version=TLS1_3, cipher=TLS_AES_256_GCM_SHA384) id 15.20.8314.12 via Frontend Transport; Thu, 2 Jan 2025 21:22:50 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 165.204.84.17) smtp.mailfrom=amd.com; dkim=none (message not signed) header.d=none;dmarc=pass action=none header.from=amd.com; Received-SPF: Pass (protection.outlook.com: domain of amd.com designates 165.204.84.17 as permitted sender) receiver=protection.outlook.com; client-ip=165.204.84.17; helo=SATLEXMB04.amd.com; pr=C Received: from SATLEXMB04.amd.com (165.204.84.17) by CH1PEPF0000AD83.mail.protection.outlook.com (10.167.244.85) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.20.8314.11 via Frontend Transport; Thu, 2 Jan 2025 21:22:50 +0000 Received: from SATLEXMB06.amd.com (10.181.40.147) by SATLEXMB04.amd.com (10.181.40.145) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.39; Thu, 2 Jan 2025 15:22:49 -0600 Received: from SATLEXMB03.amd.com (10.181.40.144) by SATLEXMB06.amd.com (10.181.40.147) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.39; Thu, 2 Jan 2025 15:22:49 -0600 Received: from xsjlizhih51.xilinx.com (10.180.168.240) by SATLEXMB03.amd.com (10.181.40.144) with Microsoft SMTP Server id 15.1.2507.39 via Frontend Transport; Thu, 2 Jan 2025 15:22:48 -0600 From: Lizhi Hou To: , , CC: Lizhi Hou , , , , , , , kernel test robot Subject: [PATCH V1 1/7] accel/amdxdna: Declare npu device profile as static variables Date: Thu, 2 Jan 2025 13:22:38 -0800 Message-ID: <20250102212244.1586340-1-lizhi.hou@amd.com> X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: CH1PEPF0000AD83:EE_|SJ2PR12MB7867:EE_ X-MS-Office365-Filtering-Correlation-Id: a34203cb-c850-47fb-4f2c-08dd2b739c91 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; ARA:13230040|1800799024|36860700013|82310400026|376014; X-Microsoft-Antispam-Message-Info: 74Ab4S/RZEErz3DWYCZV8Ytky1U2t8EOLnBwjLBPiOP0t1QWTFLy6VgZ7RtIKP/QGETQvBP7FS4y8o59hX/wxTQTK+PuRw013bYQAn/qCGkyOHhwI6xhXC7phefaqXJqm1vQusiwitoYHHu+4plCWX9eeSo3fNDYD1mu7RHgo3Xn1vYTM/aZ7xy5rSr04j2M+W0It1Medvec/LGCulCr67r9voanhzj2EsTqwIkrkRO9hO45Ej+XTDuepAdQpC8YSR1uQ+sV0l2hnTpYUCMlOfNaAkY6SG83aQ560sFZtvbHyOzk4ERSAR/MYfj0jSbn5gpUXdk/XU4RYu3LOCmUqL3Gy7RKEpNboC1IGNLTMBIUCVORoDAfTEWqJw9FvKk5iTVzeuR625MJdNAe0ahNElqlclKz6Z7PJYlXxZ8J8LP9kAv3dwD5TKsD2DBTLW+PGryLkXTZwU4VewScfHKXykav1KNzklEdNNpiYppQwNYyXelU5xazoT+WMnuNjWR5Ho6yqjFMygHWDrLG2E9iEpYy2udruIx+l6RnfJ6x0Zu6Vk2+soe/rFrS91JyBhCXzzaXctFHSCm/u7ELy9O500++9R8GN9lFY3FD/z/NlOfNlnH8j/LB8PTo42uaHk1qcmqEuzZ1cGBHbMxxl8sfmhJr7Tv7Oux8NZEVKDdZyWz9YbAflVCfj9PIMtrFnS37QvZzk80j1phHYgkz6gIgJOp8MiTDNNENO6kCO6UNyHhEcwWEZnPhGIk2UuIrZkse2gnJ5AitGH961fC9qWUfnFF6FBmhnDLXZbqaiPrj4D1c6eCcgtXr68Kamq3DVXw7ZIw8UgAeQqTYRjyTiKI2Vp61+hoozBZ6a8j/Gtk73GBaiwiOVa5apLBvTE6aS3CuKrl2fr3H/REuSQwF9m0eM5pC8lwHR5Vfp4CP+zfCrdga2ltao5qe4xtJ35vvFut+mMo5GDWrXyGzhRyOib8QJ2fW1MXWjrUOI230tPZ6wrAn1c4xBtcTO6cD4cL3u/La7MCKV3CAM31+4uFLYGl21WPVOfslVZoe1xc18qr4HchD66rVKK88+h6EPxnONKQbRTbffnsFaG7R4a3DFhCtceJEjUwkJ3p5sCZZjVTbMHmWsSdE/g/R52dKCIEzFj36J5qwmpD4ajzRfosEJB5PWQDrHpE/0kQaQxkN8ZaH6ferkyGEkaZgZs9CgDK49XBHlcn/HX1FBxcENUr8WWt0E2PTLIcjgvQxdBCfdmRh4Hrne7NEBy7VvdtYWEdSYRH/uDkIoIsLR9tEWRU+eccjO/r6TNXHAW4kO26SKEB3xwfhNTVbSYLmtT5edp1fZS0drbhhFQouaej51/lNVkEIWX9haa/H8K6XC7gp/EpDcGFJUk79iLIc3YUPPWP+0fpwVvH78S1OvSrPcQzPDtONCMpEKrZaNjraRcsFDMkM8YC2ghjto7ig+h3sms6PmnEmj8te8WsYKx2nm1WTVN6pKuuyIdI+Tr1emZriLga8Y+w= X-Forefront-Antispam-Report: CIP:165.204.84.17; CTRY:US; LANG:en; SCL:1; SRV:; IPV:CAL; SFV:NSPM; H:SATLEXMB04.amd.com; PTR:InfoDomainNonexistent; CAT:NONE; SFS:(13230040)(1800799024)(36860700013)(82310400026)(376014); DIR:OUT; SFP:1101; X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 02 Jan 2025 21:22:50.3543 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: a34203cb-c850-47fb-4f2c-08dd2b739c91 X-MS-Exchange-CrossTenant-Id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=3dd8961f-e488-4e60-8e11-a82d994e183d; Ip=[165.204.84.17]; Helo=[SATLEXMB04.amd.com] X-MS-Exchange-CrossTenant-AuthSource: CH1PEPF0000AD83.namprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: SJ2PR12MB7867 X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" Declare the variables as static to fix the sparse warnings: symbol 'npu5_dev_priv' was not declared. Should it be static? symbol 'npu1_dev_priv' was not declared. Should it be static? symbol 'npu4_dev_priv' was not declared. Should it be static? symbol 'npu2_dev_priv' was not declared. Should it be static? Fixes: 8c9ff1b181ba ("accel/amdxdna: Add a new driver for AMD AI Engine") Reported-by: kernel test robot Closes: https://lore.kernel.org/oe-kbuild-all/202412310648.dtMHgGem-lkp@intel.com/ Signed-off-by: Lizhi Hou Reviewed-by: Mario Limonciello --- drivers/accel/amdxdna/npu1_regs.c | 2 +- drivers/accel/amdxdna/npu2_regs.c | 2 +- drivers/accel/amdxdna/npu4_regs.c | 2 +- drivers/accel/amdxdna/npu5_regs.c | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/drivers/accel/amdxdna/npu1_regs.c b/drivers/accel/amdxdna/npu1_regs.c index e408af57e378..e4f6dac7d00f 100644 --- a/drivers/accel/amdxdna/npu1_regs.c +++ b/drivers/accel/amdxdna/npu1_regs.c @@ -62,7 +62,7 @@ const struct dpm_clk_freq npu1_dpm_clk_table[] = { { 0 } }; -const struct amdxdna_dev_priv npu1_dev_priv = { +static const struct amdxdna_dev_priv npu1_dev_priv = { .fw_path = "amdnpu/1502_00/npu.sbin", .protocol_major = 0x5, .protocol_minor = 0x7, diff --git a/drivers/accel/amdxdna/npu2_regs.c b/drivers/accel/amdxdna/npu2_regs.c index 286bd0d475e2..a081cac75ee0 100644 --- a/drivers/accel/amdxdna/npu2_regs.c +++ b/drivers/accel/amdxdna/npu2_regs.c @@ -61,7 +61,7 @@ #define NPU2_SMU_BAR_BASE MMNPU_APERTURE4_BASE #define NPU2_SRAM_BAR_BASE MMNPU_APERTURE1_BASE -const struct amdxdna_dev_priv npu2_dev_priv = { +static const struct amdxdna_dev_priv npu2_dev_priv = { .fw_path = "amdnpu/17f0_00/npu.sbin", .protocol_major = 0x6, .protocol_minor = 0x6, diff --git a/drivers/accel/amdxdna/npu4_regs.c b/drivers/accel/amdxdna/npu4_regs.c index 00c52833ce89..9f2e33182ec6 100644 --- a/drivers/accel/amdxdna/npu4_regs.c +++ b/drivers/accel/amdxdna/npu4_regs.c @@ -82,7 +82,7 @@ const struct dpm_clk_freq npu4_dpm_clk_table[] = { { 0 } }; -const struct amdxdna_dev_priv npu4_dev_priv = { +static const struct amdxdna_dev_priv npu4_dev_priv = { .fw_path = "amdnpu/17f0_10/npu.sbin", .protocol_major = 0x6, .protocol_minor = 12, diff --git a/drivers/accel/amdxdna/npu5_regs.c b/drivers/accel/amdxdna/npu5_regs.c index 118849272f27..5f1cf83461c4 100644 --- a/drivers/accel/amdxdna/npu5_regs.c +++ b/drivers/accel/amdxdna/npu5_regs.c @@ -61,7 +61,7 @@ #define NPU5_SMU_BAR_BASE MMNPU_APERTURE4_BASE #define NPU5_SRAM_BAR_BASE MMNPU_APERTURE1_BASE -const struct amdxdna_dev_priv npu5_dev_priv = { +static const struct amdxdna_dev_priv npu5_dev_priv = { .fw_path = "amdnpu/17f0_11/npu.sbin", .protocol_major = 0x6, .protocol_minor = 12, From patchwork Thu Jan 2 21:22:39 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Lizhi Hou X-Patchwork-Id: 13924967 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 269F9E77197 for ; Thu, 2 Jan 2025 21:23:06 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 21D2810E7B8; Thu, 2 Jan 2025 21:23:02 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=pass (1024-bit key; unprotected) header.d=amd.com header.i=@amd.com header.b="bSPgEPYh"; dkim-atps=neutral Received: from NAM02-DM3-obe.outbound.protection.outlook.com (mail-dm3nam02on2062.outbound.protection.outlook.com [40.107.95.62]) by gabe.freedesktop.org (Postfix) with ESMTPS id 1C9CA10E3F9 for ; Thu, 2 Jan 2025 21:23:00 +0000 (UTC) ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=uXc10AXHZ6wEMWHdCdGpBITDpGWfJQG6gQSo4x1Gk3H2rEJ3b3UVaNNU5BK4gCWInnFKGC7AB2Kd6DNQKMgaKH7Q0KtQyQkEokFY1cLqPt8QAJ2eo5YQOyJhfbSlY64agGnq769AjcaTuVPmy56huaf62WjJWWl0xygW2PciRlx/uVzcULhdun/54tTbCDwUFLGWBOWft/qaK07c4VuoTWocuVz/SylYaICfaW3Z/2voKPp/955vOEDx/HS87JMCYi3DpC9RU7ENgPYUVdb180MqbnAWWq6wiaH1+ctUg6PxwBXV9n+z+Q5qmL+zWQmemlr86Um4zR3T8fzPnRZN7g== 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=BMz9TsvgUCKgi51LjihlbvhsmpzjvwPH8C4G6HZruHA=; b=QrAaa5KAUUtSQ7nP9Pj/dHs8y8oa9HzK4fwGSbFHZikKeklwGFTl1gt4owGL8euRGZUA/C5lEUWCKM0FZRNOzzsiz79gjEEbS9z9BCuGj05YfA8cQwwdooES3V7LIsHuzxQxXIhYVckWo+6GwXrgks1m4Q4o/R0cKs2W3yKOGwb6MBg7jQhKf2pu4bIoREmrOHw8OnYPRUos3yysJSTWOJr14gYGsyCcSShqvVoxXWCuwPuqeGgqFZ/dqUnp5NRUR9zI7g1QddsF4WxxgbCXh16ZHEXpDy3an7HHY/7CDDw+Kok3IsiyWX3FVzJAG5ApptbOZZllsyr7P9OwANS/Sw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 165.204.84.17) smtp.rcpttodomain=kernel.org smtp.mailfrom=amd.com; dmarc=pass (p=quarantine sp=quarantine pct=100) action=none header.from=amd.com; dkim=none (message not signed); arc=none (0) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amd.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=BMz9TsvgUCKgi51LjihlbvhsmpzjvwPH8C4G6HZruHA=; b=bSPgEPYhHCpP/URSYmrXqqM9MDiGdHCo0uo7q8Et8T6WWreYudNSvuOczMupipnkdv9sakH+LqV/B+JnfHMfprKhwXEJpiCUqmTBNszCqGHEltDAUV9WQU/7RiXP38DdULYEPIgonPqViTAhg1oCv63LgQVENBMJkeN6JOPlftg= Received: from SJ0PR03CA0387.namprd03.prod.outlook.com (2603:10b6:a03:3a1::32) by CH3PR12MB9217.namprd12.prod.outlook.com (2603:10b6:610:195::10) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.8314.11; Thu, 2 Jan 2025 21:22:52 +0000 Received: from SJ5PEPF000001F0.namprd05.prod.outlook.com (2603:10b6:a03:3a1:cafe::65) by SJ0PR03CA0387.outlook.office365.com (2603:10b6:a03:3a1::32) with Microsoft SMTP Server (version=TLS1_3, cipher=TLS_AES_256_GCM_SHA384) id 15.20.8314.13 via Frontend Transport; Thu, 2 Jan 2025 21:22:51 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 165.204.84.17) smtp.mailfrom=amd.com; dkim=none (message not signed) header.d=none;dmarc=pass action=none header.from=amd.com; Received-SPF: Pass (protection.outlook.com: domain of amd.com designates 165.204.84.17 as permitted sender) receiver=protection.outlook.com; client-ip=165.204.84.17; helo=SATLEXMB03.amd.com; pr=C Received: from SATLEXMB03.amd.com (165.204.84.17) by SJ5PEPF000001F0.mail.protection.outlook.com (10.167.242.68) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.20.8314.11 via Frontend Transport; Thu, 2 Jan 2025 21:22:51 +0000 Received: from SATLEXMB03.amd.com (10.181.40.144) by SATLEXMB03.amd.com (10.181.40.144) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.39; Thu, 2 Jan 2025 15:22:50 -0600 Received: from xsjlizhih51.xilinx.com (10.180.168.240) by SATLEXMB03.amd.com (10.181.40.144) with Microsoft SMTP Server id 15.1.2507.39 via Frontend Transport; Thu, 2 Jan 2025 15:22:49 -0600 From: Lizhi Hou To: , , CC: Lizhi Hou , , , , , , , kernel test robot Subject: [PATCH V1 2/7] accel/amdxdna: Declare mailbox register base as __iomem pointer Date: Thu, 2 Jan 2025 13:22:39 -0800 Message-ID: <20250102212244.1586340-2-lizhi.hou@amd.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20250102212244.1586340-1-lizhi.hou@amd.com> References: <20250102212244.1586340-1-lizhi.hou@amd.com> MIME-Version: 1.0 Received-SPF: None (SATLEXMB03.amd.com: lizhi.hou@amd.com does not designate permitted sender hosts) X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: SJ5PEPF000001F0:EE_|CH3PR12MB9217:EE_ X-MS-Office365-Filtering-Correlation-Id: 72c53397-9022-4e9a-ad07-08dd2b739d46 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; ARA:13230040|1800799024|376014|36860700013|82310400026; X-Microsoft-Antispam-Message-Info: Poq8YT4xMcfbB2li16Y16gmMlmd6ltEeyi4bBnlWzBqkKfh8qAasfvCfhRgXti7F5mWeZz/arLvr3GroJ+t+I5HSRYDgt3zh6gR/zHaIaOGZ8m2i5Qx2EpY/oadw7OY4a0b3ekMNLRurCgdmYOML7E5e8ZX1H9ELrCFLGW7MQ90/jM+esV1SPUE8H1TySIFfpxfqv5R1yYwmmldv/Pr3ZB/bHAf239jCeH+otNwBxZVZk74h3afSiMsJePU2dI7ZpEdV1Y1JSO58LAnN3Y1X/OeBbegKuWryAqgMjiXe+4xUNUFeGAm0ayQHSZf6D4jyAdjK8BRo6h654iaipCG545IrcS5CVrUBry91/uFyoLTGKvaC+TFTddTsFmw6VHpaHR3wdcZJurEwUjY5Dtbzt7GugLzZ1RG33OLO/rJMVTQB65avUVO/vnQfVTvi4PzRUCp78vzh0dwlB+Rxy6UOkAKuKQKj4jYcUol3dX4+iWIYPC92nhu6UkmpNxDO7J+pAvzK3V0i0AJAOHOr8cDDy3quWfCkhID4lmcQwOPxlorxAtj/NBi74ydgKmsTuHOUpvOKTYXQ/LYNCd+u9MiSIxsieAg1aoVYKcBSfgOUrqGfVMvoFT1XFNpnTxxV+5HeJ3oxchbU1OQxJY1xodBrBZrnoWDQZxs3sgr/Uy8NqLXy/46C+ye0aWcccHOjiLbzMJjULORl/WO9SFPyOxvIgQRPAGrdLd3dNqtUMDz0ZCfqgjeKAR27gFxHC/Ds5rfm0GlBSbqFYdKaX6UqhyRAjz63ZAZsnU+K8ySmRdI3MQilh/m+EB5IOvPZ3eu00+WGWBVlI9TfEFuqHzMWZxhN2KiEiggA1WIt3AF9Rb6psgc8ZT+eartUwGYNs/BNAWstNDLq8rn5nlpJHVJwj3S6MB5hfwDYQXEtJaWFU4BtAMt3exlGTM0xCBBg9DU7pQFfY6y9poeF9O0piZCxKHmcx4oitKcYNEnqDiD1I6i+gbj1U/+RXNxdj8/axcQxY7kf4vafuO1DiIBCTcOcnEnxKEtB19AYw3i/JorC4Shhyf3pWmYgIo6SnOXNXSSH4lSZiiU4mdIm7zw4WEf6kb44cX5b/QSFaitDj+XeJNTXY8ZyJUfKZbZZkyJNFDniIxentnKkmQDtlw2ItwDuhze6BkEtPHO4GionQ1QThqp0VudidusUDk+7dT6xbB4lKg4XF+6AtQQR8SPI5zrorvORdFTP6NGoO8HtCvX17VWFiT9visLKPONDg/mogvpZH9ejVeRDUxeaeFv7cEHKa/lbYCpZzaBvZuFU0d6FD0I5BtxvBEPtj7NN+LvrCW/LgLgMQCzuoH9/kfRd79QztIdlQvVOkppb8qFnpiKXghJXf1smcjrB7TcZkAwRRJjdWGdgwSBD39/+mQsBR7vyxFjodXMXb4pXmR/pRjFO5u/6XpP0IIvswFqJzOxXRn2LC08HwFwxSs5YcGRbxqbQ+YANTJVGnNZ5Jbpe0WTOVeBjhKM= X-Forefront-Antispam-Report: CIP:165.204.84.17; CTRY:US; LANG:en; SCL:1; SRV:; IPV:CAL; SFV:NSPM; H:SATLEXMB03.amd.com; PTR:InfoDomainNonexistent; CAT:NONE; SFS:(13230040)(1800799024)(376014)(36860700013)(82310400026); DIR:OUT; SFP:1101; X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 02 Jan 2025 21:22:51.4804 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 72c53397-9022-4e9a-ad07-08dd2b739d46 X-MS-Exchange-CrossTenant-Id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=3dd8961f-e488-4e60-8e11-a82d994e183d; Ip=[165.204.84.17]; Helo=[SATLEXMB03.amd.com] X-MS-Exchange-CrossTenant-AuthSource: SJ5PEPF000001F0.namprd05.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: CH3PR12MB9217 X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" Declare mailbox ringbuf_base and mbox_base as 'void __iomem *' to fix sparse warnings: cast removes address space '__iomem' of expression incorrect type in argument 2 (different address spaces) Fixes: b87f920b9344 ("accel/amdxdna: Support hardware mailbox") Reported-by: kernel test robot Closes: https://lore.kernel.org/oe-kbuild-all/202412310857.syD1sXXO-lkp@intel.com/ Signed-off-by: Lizhi Hou --- drivers/accel/amdxdna/aie2_pci.c | 4 ++-- drivers/accel/amdxdna/amdxdna_mailbox.c | 24 ++++++++++++------------ drivers/accel/amdxdna/amdxdna_mailbox.h | 4 ++-- 3 files changed, 16 insertions(+), 16 deletions(-) diff --git a/drivers/accel/amdxdna/aie2_pci.c b/drivers/accel/amdxdna/aie2_pci.c index 8de8f3bd4987..8b273bc7db44 100644 --- a/drivers/accel/amdxdna/aie2_pci.c +++ b/drivers/accel/amdxdna/aie2_pci.c @@ -380,9 +380,9 @@ static int aie2_hw_start(struct amdxdna_dev *xdna) goto stop_psp; } - mbox_res.ringbuf_base = (u64)ndev->sram_base; + mbox_res.ringbuf_base = ndev->sram_base; mbox_res.ringbuf_size = pci_resource_len(pdev, xdna->dev_info->sram_bar); - mbox_res.mbox_base = (u64)ndev->mbox_base; + mbox_res.mbox_base = ndev->mbox_base; mbox_res.mbox_size = MBOX_SIZE(ndev); mbox_res.name = "xdna_mailbox"; ndev->mbox = xdnam_mailbox_create(&xdna->ddev, &mbox_res); diff --git a/drivers/accel/amdxdna/amdxdna_mailbox.c b/drivers/accel/amdxdna/amdxdna_mailbox.c index 1afc8079e3d1..814b16bb1953 100644 --- a/drivers/accel/amdxdna/amdxdna_mailbox.c +++ b/drivers/accel/amdxdna/amdxdna_mailbox.c @@ -98,27 +98,27 @@ struct mailbox_msg { static void mailbox_reg_write(struct mailbox_channel *mb_chann, u32 mbox_reg, u32 data) { struct xdna_mailbox_res *mb_res = &mb_chann->mb->res; - u64 ringbuf_addr = mb_res->mbox_base + mbox_reg; + void __iomem *ringbuf_addr = mb_res->mbox_base + mbox_reg; - writel(data, (void *)ringbuf_addr); + writel(data, ringbuf_addr); } static u32 mailbox_reg_read(struct mailbox_channel *mb_chann, u32 mbox_reg) { struct xdna_mailbox_res *mb_res = &mb_chann->mb->res; - u64 ringbuf_addr = mb_res->mbox_base + mbox_reg; + void __iomem *ringbuf_addr = mb_res->mbox_base + mbox_reg; - return readl((void *)ringbuf_addr); + return readl(ringbuf_addr); } static int mailbox_reg_read_non_zero(struct mailbox_channel *mb_chann, u32 mbox_reg, u32 *val) { struct xdna_mailbox_res *mb_res = &mb_chann->mb->res; - u64 ringbuf_addr = mb_res->mbox_base + mbox_reg; + void __iomem *ringbuf_addr = mb_res->mbox_base + mbox_reg; int ret, value; /* Poll till value is not zero */ - ret = readx_poll_timeout(readl, (void *)ringbuf_addr, value, + ret = readx_poll_timeout(readl, ringbuf_addr, value, value, 1 /* us */, 100); if (ret < 0) return ret; @@ -200,10 +200,10 @@ static void mailbox_release_msg(struct mailbox_channel *mb_chann, static int mailbox_send_msg(struct mailbox_channel *mb_chann, struct mailbox_msg *mb_msg) { + void __iomem *write_addr; u32 ringbuf_size; u32 head, tail; u32 start_addr; - u64 write_addr; u32 tmp_tail; head = mailbox_get_headptr(mb_chann, CHAN_RES_X2I); @@ -221,14 +221,14 @@ mailbox_send_msg(struct mailbox_channel *mb_chann, struct mailbox_msg *mb_msg) if (tail >= head && tmp_tail > ringbuf_size - sizeof(u32)) { write_addr = mb_chann->mb->res.ringbuf_base + start_addr + tail; - writel(TOMBSTONE, (void *)write_addr); + writel(TOMBSTONE, write_addr); /* tombstone is set. Write from the start of the ringbuf */ tail = 0; } write_addr = mb_chann->mb->res.ringbuf_base + start_addr + tail; - memcpy_toio((void *)write_addr, &mb_msg->pkg, mb_msg->pkg_size); + memcpy_toio(write_addr, &mb_msg->pkg, mb_msg->pkg_size); mailbox_set_tailptr(mb_chann, tail + mb_msg->pkg_size); trace_mbox_set_tail(MAILBOX_NAME, mb_chann->msix_irq, @@ -275,11 +275,11 @@ mailbox_get_resp(struct mailbox_channel *mb_chann, struct xdna_msg_header *heade static int mailbox_get_msg(struct mailbox_channel *mb_chann) { struct xdna_msg_header header; + void __iomem *read_addr; u32 msg_size, rest; u32 ringbuf_size; u32 head, tail; u32 start_addr; - u64 read_addr; int ret; if (mailbox_reg_read_non_zero(mb_chann, mb_chann->res[CHAN_RES_I2X].mb_tail_ptr_reg, &tail)) @@ -302,7 +302,7 @@ static int mailbox_get_msg(struct mailbox_channel *mb_chann) /* Peek size of the message or TOMBSTONE */ read_addr = mb_chann->mb->res.ringbuf_base + start_addr + head; - header.total_size = readl((void *)read_addr); + header.total_size = readl(read_addr); /* size is TOMBSTONE, set next read from 0 */ if (header.total_size == TOMBSTONE) { if (head < tail) { @@ -328,7 +328,7 @@ static int mailbox_get_msg(struct mailbox_channel *mb_chann) rest = sizeof(header) - sizeof(u32); read_addr += sizeof(u32); - memcpy_fromio((u32 *)&header + 1, (void *)read_addr, rest); + memcpy_fromio((u32 *)&header + 1, read_addr, rest); read_addr += rest; ret = mailbox_get_resp(mb_chann, &header, (u32 *)read_addr); diff --git a/drivers/accel/amdxdna/amdxdna_mailbox.h b/drivers/accel/amdxdna/amdxdna_mailbox.h index 6ab7f5424633..57954c303bdd 100644 --- a/drivers/accel/amdxdna/amdxdna_mailbox.h +++ b/drivers/accel/amdxdna/amdxdna_mailbox.h @@ -39,9 +39,9 @@ struct xdna_mailbox_msg { * @mbox_size: mailbox size */ struct xdna_mailbox_res { - u64 ringbuf_base; + void __iomem *ringbuf_base; size_t ringbuf_size; - u64 mbox_base; + void __iomem *mbox_base; size_t mbox_size; const char *name; }; From patchwork Thu Jan 2 21:22:40 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Lizhi Hou X-Patchwork-Id: 13924966 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id CE7FFE77198 for ; Thu, 2 Jan 2025 21:23:04 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id DDF0410E3F9; Thu, 2 Jan 2025 21:23:01 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=pass (1024-bit key; unprotected) header.d=amd.com header.i=@amd.com header.b="pYnkKKom"; dkim-atps=neutral Received: from NAM12-MW2-obe.outbound.protection.outlook.com (mail-mw2nam12on2063.outbound.protection.outlook.com [40.107.244.63]) by gabe.freedesktop.org (Postfix) with ESMTPS id 4041710E26D for ; Thu, 2 Jan 2025 21:22:59 +0000 (UTC) ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=dFRSRfbt4Olzz4tiEbHAiBundjpyIvgnv6xGntKc8jORaxaRoOgtXIZTVarc7uSKesm209n3Rx1HJYYuu2l0Y/L7PLTo1P+6qwlbdscgoTV90DpS9/FSGtHQtrmgHA6zCNisR0fL+wJAIcAiw2cJG3FQERDSvQ6jNcbUOoBa6AyWLVfYcZnUW3AdDd6gn6rSzTs5ir1g/SqYuW53qXWFMmz2w9fOyX7L/i+h4l2H+NtWSgjDjhBtcpYlgtl1hk+vSJ9dU0YJhmcW97GL3H+EPK5uoZTWX3G/XCbtJblXgjqCvd3dBKDqYBlkhKe3rnWOQcAy/T9Tqr7+dAuTRuK2og== 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=r9lD8hdcYumDkPwVtIQbDkc+w3yTNuVmfJ18iyAm5Io=; b=NfzUQi7WMvxhPD4IbzeZHo0SHqJySvIVBGxojyz4uDaol2fiiyBG7K7yCa2YoSwxkqQwBX398NLBTuJYl3+tjAs7kTfkl+qbWE6H0M/VvDtWqfdihDPx6CRTLsSpBFjZRaCjX2b8o7btKWfKnWDgt3AemdSKlTWGgjpOA09axvdssT4zKIQTM3vacNLHPNcevSere6Iq1YiiDeyBpWyxcni9psUDIGURRfJm29xIjMtZqeCRPyCRmcxt2WVp6jvd/slA/WY8nD1Ggaf6Akf2lG4rVRD9fifpkAM5atKkq6m+DcGMqwnZY/6/EtJseKKKA0yW7MDqZAL9U3zrOHqFJQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 165.204.84.17) smtp.rcpttodomain=kernel.org smtp.mailfrom=amd.com; dmarc=pass (p=quarantine sp=quarantine pct=100) action=none header.from=amd.com; dkim=none (message not signed); arc=none (0) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amd.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=r9lD8hdcYumDkPwVtIQbDkc+w3yTNuVmfJ18iyAm5Io=; b=pYnkKKomSeKMsOdjJxDwTzZYQQB3yFDJHAfv2SGHAUOdCZAn8TuXKLnapCOAe7LG5GrOzIAu3nUrKqEFiXddPiFub4Bm2VEvLb0sayfZaxlcKBDvomczFGbO1/yWUp6EW9gAdZ65oN4WTz6/wBJL1uHfTcb8rtb+JmeVIEQarew= Received: from SJ0PR03CA0389.namprd03.prod.outlook.com (2603:10b6:a03:3a1::34) by DM4PR12MB8499.namprd12.prod.outlook.com (2603:10b6:8:181::10) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.8314.12; Thu, 2 Jan 2025 21:22:53 +0000 Received: from SJ5PEPF000001F0.namprd05.prod.outlook.com (2603:10b6:a03:3a1:cafe::2e) by SJ0PR03CA0389.outlook.office365.com (2603:10b6:a03:3a1::34) with Microsoft SMTP Server (version=TLS1_3, cipher=TLS_AES_256_GCM_SHA384) id 15.20.8314.13 via Frontend Transport; Thu, 2 Jan 2025 21:22:52 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 165.204.84.17) smtp.mailfrom=amd.com; dkim=none (message not signed) header.d=none;dmarc=pass action=none header.from=amd.com; Received-SPF: Pass (protection.outlook.com: domain of amd.com designates 165.204.84.17 as permitted sender) receiver=protection.outlook.com; client-ip=165.204.84.17; helo=SATLEXMB03.amd.com; pr=C Received: from SATLEXMB03.amd.com (165.204.84.17) by SJ5PEPF000001F0.mail.protection.outlook.com (10.167.242.68) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.20.8314.11 via Frontend Transport; Thu, 2 Jan 2025 21:22:52 +0000 Received: from SATLEXMB03.amd.com (10.181.40.144) by SATLEXMB03.amd.com (10.181.40.144) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.39; Thu, 2 Jan 2025 15:22:51 -0600 Received: from xsjlizhih51.xilinx.com (10.180.168.240) by SATLEXMB03.amd.com (10.181.40.144) with Microsoft SMTP Server id 15.1.2507.39 via Frontend Transport; Thu, 2 Jan 2025 15:22:50 -0600 From: Lizhi Hou To: , , CC: Lizhi Hou , , , , , , , kernel test robot Subject: [PATCH V1 3/7] accel/amdxdna: Declare aie2_max_col as static Date: Thu, 2 Jan 2025 13:22:40 -0800 Message-ID: <20250102212244.1586340-3-lizhi.hou@amd.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20250102212244.1586340-1-lizhi.hou@amd.com> References: <20250102212244.1586340-1-lizhi.hou@amd.com> MIME-Version: 1.0 Received-SPF: None (SATLEXMB03.amd.com: lizhi.hou@amd.com does not designate permitted sender hosts) X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: SJ5PEPF000001F0:EE_|DM4PR12MB8499:EE_ X-MS-Office365-Filtering-Correlation-Id: 2b060ec1-68cf-4793-08a5-08dd2b739de4 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; ARA:13230040|376014|1800799024|36860700013|82310400026; X-Microsoft-Antispam-Message-Info: 1PHjOxJr7EcYNcyYR13cUZ5aAfmwRTe2W1Tbtj9xJGWzRsH7iZ9RrqQdQOssR/8fY3Bc8shKHzD72NNeydRCiPpbEGwzHk3jUPYjoQ8cG7tQajpXQo+/wPNcz8d1LNb6Th0iTJ3/CjmXjZIjqXJBtGMj5ZFuhAYDsYL9yg34U+BEskwDYk+LdX8kvdsNKJu9jKWVuLz7yoM7WjD8eVJpTOBTYVqu+efahnYN0wF+NWHmf0QoZyx8tDiU6LaqXQmojyYZoF0P1O5pZmM62FzMiEj+04dyCPTDhbWmKKy/TMojXnl1iX23whNNBJNAmA+2KD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xvY9qdVpInh7ID/uWkT+P6/PhtXdcWVFPls+2GpfupBaZaB6onYMESTJ0oYKLIBYCVNpU43Pg7Kd64qYQCayXb3oCk7VjBR0aGFnNOql0= X-Forefront-Antispam-Report: CIP:165.204.84.17; CTRY:US; LANG:en; SCL:1; SRV:; IPV:CAL; SFV:NSPM; H:SATLEXMB03.amd.com; PTR:InfoDomainNonexistent; CAT:NONE; SFS:(13230040)(376014)(1800799024)(36860700013)(82310400026); DIR:OUT; SFP:1101; X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 02 Jan 2025 21:22:52.5116 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 2b060ec1-68cf-4793-08a5-08dd2b739de4 X-MS-Exchange-CrossTenant-Id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=3dd8961f-e488-4e60-8e11-a82d994e183d; Ip=[165.204.84.17]; Helo=[SATLEXMB03.amd.com] X-MS-Exchange-CrossTenant-AuthSource: SJ5PEPF000001F0.namprd05.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM4PR12MB8499 X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" Fix the sparse warning: symbol 'aie2_max_col' was not declared. Should it be static? Fixes: c88d3325ae69 ("accel/amdxdna: Add hardware resource solver") Reported-by: kernel test robot Closes: https://lore.kernel.org/oe-kbuild-all/202412311028.x2UtcSHm-lkp@intel.com/ Signed-off-by: Lizhi Hou --- drivers/accel/amdxdna/aie2_pci.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/accel/amdxdna/aie2_pci.c b/drivers/accel/amdxdna/aie2_pci.c index 8b273bc7db44..5a058e565b01 100644 --- a/drivers/accel/amdxdna/aie2_pci.c +++ b/drivers/accel/amdxdna/aie2_pci.c @@ -25,7 +25,7 @@ #include "amdxdna_mailbox.h" #include "amdxdna_pci_drv.h" -int aie2_max_col = XRS_MAX_COL; +static int aie2_max_col = XRS_MAX_COL; module_param(aie2_max_col, uint, 0600); MODULE_PARM_DESC(aie2_max_col, "Maximum column could be used"); From patchwork Thu Jan 2 21:22:41 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Lizhi Hou X-Patchwork-Id: 13924965 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 32B93E77188 for ; Thu, 2 Jan 2025 21:23:03 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id C461710E26D; Thu, 2 Jan 2025 21:23:00 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=pass (1024-bit key; unprotected) header.d=amd.com header.i=@amd.com header.b="scIf6zcO"; dkim-atps=neutral Received: from NAM12-DM6-obe.outbound.protection.outlook.com (mail-dm6nam12on2074.outbound.protection.outlook.com [40.107.243.74]) by gabe.freedesktop.org (Postfix) with ESMTPS id EEF0110E26D for ; Thu, 2 Jan 2025 21:22:59 +0000 (UTC) ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=ozTb1UGyvuFJXMWWz0F8L4FKvX+JUYs+iVagiFQdRg+SAJrHVnw+5wjAKsN+3DkHc5D5ORmI8hAb37hsTCTP/OVkfXJj3AbD6lsIuIvmjLFESEcZzXSl1QYaWk9eKtUVk3hZxKZ97TEIpb6vNYpw54oABe4MI2F4waJIZ6PVnHgCMXLo3mWM0IGbKSuz3HSNb8dqbWZMFSQnBDItSjS84OllA42JNLgpwpc3F8GKt5YMflrksFYpSLONwLpoHgzT0H0T4rCwV/mtNAhXKE/CuoGMD53IhNCMF+bsurmIqF4oikR9Nt2ogNgyl6Lf7QphfJ8ZuNBb+CMSnrBKGzjiUw== 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=ryl8ldvXibSQ5n41Abv9b3QulLEvie++96yMpk9v/Fw=; b=VAciWDHGvvgFry/3QgSmUZbvMFz27VXS+AeSVoPnaMlM21yKhDPUh5Ip69JEor+pXMa0oB7zaXy09OtRPBgZW1eovSU+ppWXpQnOMwhdyx9Oe+8iByIjqadKfPnW3SvT5LNn7q2OvrT7yxrJxqOGnUpXI2KtHVF5nfumEtYfYk3i6ZO0dVxv4VZZ+5JNTog9wTQwgx52ummb0VXTRgmYNM3H9IwRPATgeKaj1a82k+zu4UmEX97FtzDsnn+drQrsxbudjcmt8jQqixwfIsAvvmdEq4w3oHPKknFQv6BSMtrHCFPdy5usPflk6dkHhc52+X9YlTIco7HeXcZKEgJmtw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 165.204.84.17) smtp.rcpttodomain=kernel.org smtp.mailfrom=amd.com; dmarc=pass (p=quarantine sp=quarantine pct=100) action=none header.from=amd.com; dkim=none (message not signed); arc=none (0) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amd.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=ryl8ldvXibSQ5n41Abv9b3QulLEvie++96yMpk9v/Fw=; b=scIf6zcOFgsyzkxtwQ6/yDwnGz/d4H+EEwjPaILsRKLVPkrIpU8cAzK113gDq2Bo438FMdxCt+bUBUS/n3Gd5ulHP50WUnGRxHhKybNzA+4aC+TaH+JmafbmV0DSAzgyJ96wSNPBjiVHIqAI1/yNQYfY0595Lxeh2UYdN0ph5ZE= Received: from SJ0PR03CA0371.namprd03.prod.outlook.com (2603:10b6:a03:3a1::16) by CY8PR12MB7268.namprd12.prod.outlook.com (2603:10b6:930:54::20) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.8314.12; Thu, 2 Jan 2025 21:22:53 +0000 Received: from SJ5PEPF000001F0.namprd05.prod.outlook.com (2603:10b6:a03:3a1:cafe::f2) by SJ0PR03CA0371.outlook.office365.com (2603:10b6:a03:3a1::16) with Microsoft SMTP Server (version=TLS1_3, cipher=TLS_AES_256_GCM_SHA384) id 15.20.8314.12 via Frontend Transport; Thu, 2 Jan 2025 21:22:53 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 165.204.84.17) smtp.mailfrom=amd.com; dkim=none (message not signed) header.d=none;dmarc=pass action=none header.from=amd.com; Received-SPF: Pass (protection.outlook.com: domain of amd.com designates 165.204.84.17 as permitted sender) receiver=protection.outlook.com; client-ip=165.204.84.17; helo=SATLEXMB03.amd.com; pr=C Received: from SATLEXMB03.amd.com (165.204.84.17) by SJ5PEPF000001F0.mail.protection.outlook.com (10.167.242.68) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.20.8314.11 via Frontend Transport; Thu, 2 Jan 2025 21:22:53 +0000 Received: from SATLEXMB06.amd.com (10.181.40.147) by SATLEXMB03.amd.com (10.181.40.144) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.39; Thu, 2 Jan 2025 15:22:52 -0600 Received: from SATLEXMB03.amd.com (10.181.40.144) by SATLEXMB06.amd.com (10.181.40.147) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.39; Thu, 2 Jan 2025 15:22:52 -0600 Received: from xsjlizhih51.xilinx.com (10.180.168.240) by SATLEXMB03.amd.com (10.181.40.144) with Microsoft SMTP Server id 15.1.2507.39 via Frontend Transport; Thu, 2 Jan 2025 15:22:51 -0600 From: Lizhi Hou To: , , CC: Lizhi Hou , , , , , , , kernel test robot Subject: [PATCH V1 4/7] accel/amdxdna: Use rcu_access_pointer for __rcu pointer Date: Thu, 2 Jan 2025 13:22:41 -0800 Message-ID: <20250102212244.1586340-4-lizhi.hou@amd.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20250102212244.1586340-1-lizhi.hou@amd.com> References: <20250102212244.1586340-1-lizhi.hou@amd.com> MIME-Version: 1.0 X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: SJ5PEPF000001F0:EE_|CY8PR12MB7268:EE_ X-MS-Office365-Filtering-Correlation-Id: 5a49c693-ef67-44cf-030b-08dd2b739e60 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; ARA:13230040|1800799024|376014|36860700013|82310400026; X-Microsoft-Antispam-Message-Info: Ln7QHgS3rj7bLUJjcfazq1GzVU+mfM5C5390JLp91WD6+1z+hYyqXbzqPFg/quERocRab4UEgiPB72dUTsZcIdc57/wCgFENWE1hIFUuZ9MizrqyBPahvOc204SmwLcxkH2MGDoUxLe42HtpJ8k3VuV1MpuvqAFPeLCQcSNf5iT40dE3IxKgH1/u/BnX75mkd+lLB7I7ULJ6Brzv00zL8pjtm6/R9TQM2c9IiccIXuOFV/SMllKc/pwerTXxnRDUc86wQYq6YQGG0rvfKqK/KgUjF3cFqlyNlswmRx25rJVJHLRhzhjtrkC0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7/FhhFXPyreqWPqWn5AeRsnL5aC3BDusRi1HWhRwptZYh0GRJj4ZMy93DtIteqR5RsBjdqIryf+7hAxb04rZYCWEzwemtbeycMLy8b0y9thGIla+CoNgG1xTlKSUdFyPPfFk= X-Forefront-Antispam-Report: CIP:165.204.84.17; CTRY:US; LANG:en; SCL:1; SRV:; IPV:CAL; SFV:NSPM; H:SATLEXMB03.amd.com; PTR:InfoDomainNonexistent; CAT:NONE; SFS:(13230040)(1800799024)(376014)(36860700013)(82310400026); DIR:OUT; SFP:1101; X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 02 Jan 2025 21:22:53.3241 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 5a49c693-ef67-44cf-030b-08dd2b739e60 X-MS-Exchange-CrossTenant-Id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=3dd8961f-e488-4e60-8e11-a82d994e183d; Ip=[165.204.84.17]; Helo=[SATLEXMB03.amd.com] X-MS-Exchange-CrossTenant-AuthSource: SJ5PEPF000001F0.namprd05.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: CY8PR12MB7268 X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" Use rcu_access_pointer for pid in struct drm_file. This fixes sparse warning. Fixes: be462c97b7df ("accel/amdxdna: Add hardware context") Reported-by: kernel test robot Closes: https://lore.kernel.org/oe-kbuild-all/202412311210.LfeHTzLw-lkp@intel.com/ Signed-off-by: Lizhi Hou --- drivers/accel/amdxdna/amdxdna_pci_drv.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/accel/amdxdna/amdxdna_pci_drv.c b/drivers/accel/amdxdna/amdxdna_pci_drv.c index 194e44fc243d..97d4a032171f 100644 --- a/drivers/accel/amdxdna/amdxdna_pci_drv.c +++ b/drivers/accel/amdxdna/amdxdna_pci_drv.c @@ -61,7 +61,7 @@ static int amdxdna_drm_open(struct drm_device *ddev, struct drm_file *filp) goto put_rpm; } - client->pid = pid_nr(filp->pid); + client->pid = pid_nr(rcu_access_pointer(filp->pid)); client->xdna = xdna; client->sva = iommu_sva_bind_device(xdna->ddev.dev, current->mm); From patchwork Thu Jan 2 21:22:42 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Lizhi Hou X-Patchwork-Id: 13924968 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 3050FE77198 for ; Thu, 2 Jan 2025 21:23:07 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id E074610E7B9; Thu, 2 Jan 2025 21:23:03 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=pass (1024-bit key; unprotected) header.d=amd.com header.i=@amd.com header.b="E0VGDdDT"; dkim-atps=neutral Received: from NAM11-CO1-obe.outbound.protection.outlook.com (mail-co1nam11on2067.outbound.protection.outlook.com [40.107.220.67]) by gabe.freedesktop.org (Postfix) with ESMTPS id 6D09110E26D for ; Thu, 2 Jan 2025 21:23:00 +0000 (UTC) ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=W+HcfbjM+FVmNvnYfIK7cfrPONXb0tA5291IVnTzotCtW6VQ4BnNda5OSvld3oKaLa5XT8+LHV1aqQc7LQhP3nCrdWeuBnDumPbe25vPbPzgCZctWMwNONpP9pMWbs8fuq+bbEg+ejbwjLrzQqlxLJu80QZW7DvlTa5Ro4rdAdOkW6lVfrusnb09wsBd15KXJWF2RR8H552IqiWBqHv+w6Q2UauVE38qhFfC2EEoICJ4cNLV//kmHQ+n238JMA4//xhACMh1dokcvbnoxJHf+lKXpbwiR5NSCfYhnWIlm6TF8RAd8on8xv5/0Nlq8P6eVMtzd7kIL9U9kdwnKcCkVw== 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=EKQpMgWDD5xFrvynctiEg3sGX7VEvARKP4lG6HAuzeo=; b=xaea7chL1bC1aCwNSC8w4TJutaoPSOhJuxjaH9w+2FKiuUhrwixWWUykSV6mte2VNRk/kq6NeeB3Lprtxaj3Oi0sKhZ1MAdNM8ZGt7O2Wg0QEBZuCdwJFplh7F+l1/Aba8/7zTtaTpuKMW6w5opXUCa8kKDXuhuvZUo7bVpULHY/qPhK6xmoEmpc3QSmZG/XhglyDGCrzVfNeu+j0Iv1jenoJnXsrHdeQELLvUG2mkghzTKOXHRJF3o+U0iHwt+qao1CvsHl7r9KFHPj3dp9tkTk3KtU7Mp15BlXIJ4/VjpirsqizTB+nw1c1W0Cs0Ojc/z3j6heeFyfWxJRc71A/Q== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 165.204.84.17) smtp.rcpttodomain=kernel.org smtp.mailfrom=amd.com; dmarc=pass (p=quarantine sp=quarantine pct=100) action=none header.from=amd.com; dkim=none (message not signed); arc=none (0) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amd.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=EKQpMgWDD5xFrvynctiEg3sGX7VEvARKP4lG6HAuzeo=; b=E0VGDdDT8J484fpdOFPSyS7wu8W8jFnBqwvJU/a9z3Qk90ebVDyaDYi9irNyOB0DYaIek22uIOQ+GGfR/wk78CLGhhfL5TctjdwAn6LfJGGYFpPSr5NV0ESolAzLfz3nkQytIUCv9NcLMXcF+1pdOYCDhkBDEuk7C9qxG60u4+s= Received: from CH2PR07CA0011.namprd07.prod.outlook.com (2603:10b6:610:20::24) by CY5PR12MB6576.namprd12.prod.outlook.com (2603:10b6:930:40::12) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.8314.14; Thu, 2 Jan 2025 21:22:54 +0000 Received: from CH1PEPF0000AD83.namprd04.prod.outlook.com (2603:10b6:610:20:cafe::37) by CH2PR07CA0011.outlook.office365.com (2603:10b6:610:20::24) with Microsoft SMTP Server (version=TLS1_3, cipher=TLS_AES_256_GCM_SHA384) id 15.20.8293.16 via Frontend Transport; Thu, 2 Jan 2025 21:22:54 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 165.204.84.17) smtp.mailfrom=amd.com; dkim=none (message not signed) header.d=none;dmarc=pass action=none header.from=amd.com; Received-SPF: Pass (protection.outlook.com: domain of amd.com designates 165.204.84.17 as permitted sender) receiver=protection.outlook.com; client-ip=165.204.84.17; helo=SATLEXMB04.amd.com; pr=C Received: from SATLEXMB04.amd.com (165.204.84.17) by CH1PEPF0000AD83.mail.protection.outlook.com (10.167.244.85) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.20.8314.11 via Frontend Transport; Thu, 2 Jan 2025 21:22:54 +0000 Received: from SATLEXMB06.amd.com (10.181.40.147) by SATLEXMB04.amd.com (10.181.40.145) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.39; Thu, 2 Jan 2025 15:22:53 -0600 Received: from SATLEXMB03.amd.com (10.181.40.144) by SATLEXMB06.amd.com (10.181.40.147) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.39; Thu, 2 Jan 2025 15:22:53 -0600 Received: from xsjlizhih51.xilinx.com (10.180.168.240) by SATLEXMB03.amd.com (10.181.40.144) with Microsoft SMTP Server id 15.1.2507.39 via Frontend Transport; Thu, 2 Jan 2025 15:22:52 -0600 From: Lizhi Hou To: , , CC: Lizhi Hou , , , , , , , kernel test robot Subject: [PATCH V1 5/7] accel/amdxdna: Declare force_cmdlist as static Date: Thu, 2 Jan 2025 13:22:42 -0800 Message-ID: <20250102212244.1586340-5-lizhi.hou@amd.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20250102212244.1586340-1-lizhi.hou@amd.com> References: <20250102212244.1586340-1-lizhi.hou@amd.com> MIME-Version: 1.0 X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: CH1PEPF0000AD83:EE_|CY5PR12MB6576:EE_ X-MS-Office365-Filtering-Correlation-Id: 672f8400-f829-42b0-97fd-08dd2b739ee0 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; ARA:13230040|82310400026|36860700013|376014|1800799024; X-Microsoft-Antispam-Message-Info: cNohM2jlGNn5BOC79gHRMjpKyT2WmsJzBsQEcXpOKRtHIM+aqQbqYa28/uQuHrfmtsxCC4OUsBhURBXWX+JhJC3Ol4JQSeLPacu5UGDwHydEvLjSIbkHi/ZXZfq36XQPLICv2qQ2RBdlzDW3oLqL41nBZRaQvDjDe0vIbMzkWcp7Dlb+vVeruUFSpd36gYJtHZNhyZ5KvMQc6EpRJaPB2e6nZYpZSrYJx3QvXJb0AHmmfJMxBa55a/b06sJMfV1ATE5MuTo5Ub4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mqcRGn74uEnnv/pkk089UbqPFU57ZPiDm/nGY+LMA087OtYLGOTL84Xmg90IxluF1v7Dkka1VbKA7YOSEZswBisseNGe0W4lXLBD5Hx7rx4BTUR8gfmYYB/uh20Ll3bqhfVITpz9hUbwdmqCzOJcmT6QIb6lA= X-Forefront-Antispam-Report: CIP:165.204.84.17; CTRY:US; LANG:en; SCL:1; SRV:; IPV:CAL; SFV:NSPM; H:SATLEXMB04.amd.com; PTR:InfoDomainNonexistent; CAT:NONE; SFS:(13230040)(82310400026)(36860700013)(376014)(1800799024); DIR:OUT; SFP:1101; X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 02 Jan 2025 21:22:54.2293 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 672f8400-f829-42b0-97fd-08dd2b739ee0 X-MS-Exchange-CrossTenant-Id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=3dd8961f-e488-4e60-8e11-a82d994e183d; Ip=[165.204.84.17]; Helo=[SATLEXMB04.amd.com] X-MS-Exchange-CrossTenant-AuthSource: CH1PEPF0000AD83.namprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: CY5PR12MB6576 X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" Fix sparse warning: symbol 'force_cmdlist' was not declared. Should it be static? Fixes: aac243092b70 ("accel/amdxdna: Add command execution") Reported-by: kernel test robot Closes: https://lore.kernel.org/oe-kbuild-all/202412311448.GKQj7uPZ-lkp@intel.com/ Signed-off-by: Lizhi Hou --- drivers/accel/amdxdna/aie2_ctx.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/accel/amdxdna/aie2_ctx.c b/drivers/accel/amdxdna/aie2_ctx.c index 9facf45818f9..5f43db02b240 100644 --- a/drivers/accel/amdxdna/aie2_ctx.c +++ b/drivers/accel/amdxdna/aie2_ctx.c @@ -22,7 +22,7 @@ #include "amdxdna_mailbox.h" #include "amdxdna_pci_drv.h" -bool force_cmdlist; +static bool force_cmdlist; module_param(force_cmdlist, bool, 0600); MODULE_PARM_DESC(force_cmdlist, "Force use command list (Default false)"); From patchwork Thu Jan 2 21:22:43 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Lizhi Hou X-Patchwork-Id: 13924971 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id AE33FE77188 for ; Thu, 2 Jan 2025 21:38:58 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 20A5510E338; Thu, 2 Jan 2025 21:38:58 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=pass (1024-bit key; unprotected) header.d=amd.com header.i=@amd.com header.b="c3XYyiQX"; dkim-atps=neutral Received: from NAM11-DM6-obe.outbound.protection.outlook.com (mail-dm6nam11on2061.outbound.protection.outlook.com [40.107.223.61]) by gabe.freedesktop.org (Postfix) with ESMTPS id 40A2D10E338 for ; Thu, 2 Jan 2025 21:38:57 +0000 (UTC) ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=MH9rdpUQuTWvUH54MjQoIpcJQXpg8Obxhyc0bflwSbtYkeQ751SJ9Hpj71Q26ER8l5obslLwO7BWc7cvPpEo9BJxf07oehEhZDtrpHB1WCZVh8KD39L5bLVCoO+aQEoio4lVgSEGXccSbUjGGAyHID9AvhJq9Uak+TQ6ADO1MakRspgHfiTpUaAHMRKZtoC1zTegfUWPA5vlEPkG5xLFXt1NW465mFprWTqj/ztRH7wofR9it/UpK0rIFcX30Bj0NmmnoHp7LgLgtHTgeg1GxMug/LvOHsQd1b2S7vAjAIjbrmFmTBZe4vG/Jw0/91MX3PRrT0DoKsg7HFWBb34nwA== 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=QVwSra8Folg7K8c3ULXt/OUwtXeNqEW8FEHXTLjUSus=; b=UAqJzVjxdWy0LXV0sOYhmdoVSvGgCEs/kC2PO3wafVQccZacREZf+o+rOh3C3ZRMF4EkMPZbJjKVFN8Z5K4r2O5WgnvQRkBRT6udgp7AFpXPAyaYF2GeyoOEsFq/9PQOVzV64XwUzAL4HQCkzrSMHta/sT9wkL8gYrF9fpnZPeUgJtCOnsVKFSDUfhIyLMnhs5RlUjWUxv4J+ojUunp4/c+IIJBUwb7RYIfWNljWLnNvXX1YOnOimiu8htU1gSmwBI7cAWhE2qzQglVYrmIjNmadNwchNn3/XM7sXz6ZxhmDLGSpIunxjcRlHpvu+MR3bWQ4NJKD91WktkABeDilCQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 165.204.84.17) smtp.rcpttodomain=kernel.org smtp.mailfrom=amd.com; dmarc=pass (p=quarantine sp=quarantine pct=100) action=none header.from=amd.com; dkim=none (message not signed); arc=none (0) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amd.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=QVwSra8Folg7K8c3ULXt/OUwtXeNqEW8FEHXTLjUSus=; b=c3XYyiQXnv5VrNoags+oG4HhDiJkIIHR9uFEzR7hk0PvrUbCYIA+Ciio8uRYnacV431cHRmh7dVm4klBay+n0K/9m2EJ0XHNBXcl2yysrw1RC2jS5y00ulm/39Du8eGg/nFyehJfhFRyVvLNk8UIbTDNAP1XMa6Fj0TJ8nIi6wk= Received: from SJ0PR03CA0362.namprd03.prod.outlook.com (2603:10b6:a03:3a1::7) by SN7PR12MB7787.namprd12.prod.outlook.com (2603:10b6:806:347::15) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.8314.13; Thu, 2 Jan 2025 21:22:55 +0000 Received: from SJ5PEPF000001F0.namprd05.prod.outlook.com (2603:10b6:a03:3a1:cafe::31) by SJ0PR03CA0362.outlook.office365.com (2603:10b6:a03:3a1::7) with Microsoft SMTP Server (version=TLS1_3, cipher=TLS_AES_256_GCM_SHA384) id 15.20.8314.12 via Frontend Transport; Thu, 2 Jan 2025 21:22:55 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 165.204.84.17) smtp.mailfrom=amd.com; dkim=none (message not signed) header.d=none;dmarc=pass action=none header.from=amd.com; Received-SPF: Pass (protection.outlook.com: domain of amd.com designates 165.204.84.17 as permitted sender) receiver=protection.outlook.com; client-ip=165.204.84.17; helo=SATLEXMB03.amd.com; pr=C Received: from SATLEXMB03.amd.com (165.204.84.17) by SJ5PEPF000001F0.mail.protection.outlook.com (10.167.242.68) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.20.8314.11 via Frontend Transport; Thu, 2 Jan 2025 21:22:55 +0000 Received: from SATLEXMB06.amd.com (10.181.40.147) by SATLEXMB03.amd.com (10.181.40.144) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.39; Thu, 2 Jan 2025 15:22:54 -0600 Received: from SATLEXMB03.amd.com (10.181.40.144) by SATLEXMB06.amd.com (10.181.40.147) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.39; Thu, 2 Jan 2025 15:22:54 -0600 Received: from xsjlizhih51.xilinx.com (10.180.168.240) by SATLEXMB03.amd.com (10.181.40.144) with Microsoft SMTP Server id 15.1.2507.39 via Frontend Transport; Thu, 2 Jan 2025 15:22:53 -0600 From: Lizhi Hou To: , , CC: Lizhi Hou , , , , , , , kernel test robot Subject: [PATCH V1 6/7] accel/amdxdna: Add __user to second parameter of aie2_query_status Date: Thu, 2 Jan 2025 13:22:43 -0800 Message-ID: <20250102212244.1586340-6-lizhi.hou@amd.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20250102212244.1586340-1-lizhi.hou@amd.com> References: <20250102212244.1586340-1-lizhi.hou@amd.com> MIME-Version: 1.0 X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: SJ5PEPF000001F0:EE_|SN7PR12MB7787:EE_ X-MS-Office365-Filtering-Correlation-Id: 201ff421-4f4a-4b7a-6a7d-08dd2b739fab X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; ARA:13230040|376014|1800799024|36860700013|82310400026; X-Microsoft-Antispam-Message-Info: 51Z69HkQByUByHV6YbQqfULCzdE5LLwdqQqTSu3qdF6TlOvCJlsVnqiB/5yrbucpyrfKQBQeWlwVw5d9qkX/8Qv5hOP4OJHZVOooflerXpzllVbGnXUbIBOLIvwX4F2ablPWkVQW1sC2K+HRegUVO7YdFMVCz0T4nOCekc1cdg+XgKMvFs//wy1tcA9CSI4hpR2qGwDMNCpxWH192D/ukNZqWIsuEgm22nWPrQP+Rs628scmoGc72tqnly9Ue7vsnYvvvZjXrQROa7j25SIKEOxIV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AjXbBDZEF0rgWY8twlfKdt8XYig5n8lyL92PpksjScyeK/syHhxvz1ftPRIfcY/P3XEjVxnSuwUisTchBe2KBpsBf63uplTvvaxYoPCm8JsgXvG99eYhjGGXwoHvPHcJ/4R2+5rJ1EA+Fpu2/3YJ3iZWk/toUs= X-Forefront-Antispam-Report: CIP:165.204.84.17; CTRY:US; LANG:en; SCL:1; SRV:; IPV:CAL; SFV:NSPM; H:SATLEXMB03.amd.com; PTR:InfoDomainNonexistent; CAT:NONE; SFS:(13230040)(376014)(1800799024)(36860700013)(82310400026); DIR:OUT; SFP:1101; X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 02 Jan 2025 21:22:55.4804 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 201ff421-4f4a-4b7a-6a7d-08dd2b739fab X-MS-Exchange-CrossTenant-Id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=3dd8961f-e488-4e60-8e11-a82d994e183d; Ip=[165.204.84.17]; Helo=[SATLEXMB03.amd.com] X-MS-Exchange-CrossTenant-AuthSource: SJ5PEPF000001F0.namprd05.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: SN7PR12MB7787 X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" The second parameter of aie2_query_status() is a userspace pointer. Declaring it as 'char __user *' to fix sparse warning. Fixes: 850d71f6bf4c ("accel/amdxdna: Add query functions") Reported-by: kernel test robot Closes: https://lore.kernel.org/oe-kbuild-all/202412311655.YBvq2wJb-lkp@intel.com/ Signed-off-by: Lizhi Hou --- drivers/accel/amdxdna/aie2_pci.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/accel/amdxdna/aie2_pci.h b/drivers/accel/amdxdna/aie2_pci.h index cc159cadff9f..f2d95531ddc2 100644 --- a/drivers/accel/amdxdna/aie2_pci.h +++ b/drivers/accel/amdxdna/aie2_pci.h @@ -269,7 +269,7 @@ int aie2_query_firmware_version(struct amdxdna_dev_hdl *ndev, int aie2_create_context(struct amdxdna_dev_hdl *ndev, struct amdxdna_hwctx *hwctx); int aie2_destroy_context(struct amdxdna_dev_hdl *ndev, struct amdxdna_hwctx *hwctx); int aie2_map_host_buf(struct amdxdna_dev_hdl *ndev, u32 context_id, u64 addr, u64 size); -int aie2_query_status(struct amdxdna_dev_hdl *ndev, char *buf, u32 size, u32 *cols_filled); +int aie2_query_status(struct amdxdna_dev_hdl *ndev, char __user *buf, u32 size, u32 *cols_filled); int aie2_register_asyn_event_msg(struct amdxdna_dev_hdl *ndev, dma_addr_t addr, u32 size, void *handle, int (*cb)(void*, const u32 *, size_t)); int aie2_config_cu(struct amdxdna_hwctx *hwctx); From patchwork Thu Jan 2 21:22:44 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Lizhi Hou X-Patchwork-Id: 13924969 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 148F3E77188 for ; Thu, 2 Jan 2025 21:23:08 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id E064310E7BB; Thu, 2 Jan 2025 21:23:04 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=pass (1024-bit key; unprotected) header.d=amd.com header.i=@amd.com header.b="DCP7Bfyf"; dkim-atps=neutral Received: from NAM02-DM3-obe.outbound.protection.outlook.com (mail-dm3nam02on2055.outbound.protection.outlook.com [40.107.95.55]) by gabe.freedesktop.org (Postfix) with ESMTPS id A1C0E10E7B9 for ; Thu, 2 Jan 2025 21:23:03 +0000 (UTC) ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=mQdAbd03PjITLRhgYrFF0nM/Sju+qcn604dmqGSyZ5F2RQct8BmNXuD4to1QAN/KkxEE+CT4SDPdH9FcsnqTfYOeFwKfpygEaLrmA4xGlZfJ7nB2g4agPHLh4jw/4KOQiZB/QNVS/njWYzFPKje+N1KbS8LAJzMZGHdkdWiszbHQqQ3qXH9fXmV80TygIdTpV2yv6lGhfYlbQb8BjN4p8Ce5AVYkZ8LVbdLFCX7u7ZsOmXKpcWhI/G+Ek2F8satAp+ZevCd/D8worMOkQ8XyKkm+0VSaV6HDQqNc1PMFXpBYafdYUzNIvhqlXtUXAX7v/Tg07GWm0s9MvBkaMErxlg== 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=oQ7KFCwr61/HuiVwLq3AjULOM4jTzNo9F0kUTtMsoGE=; b=xZIfg7lJcOW08scn6Q7hsxsd/p0WKNbso7DYHiw2wBvOpOZtrwsit8kn0BkLZqHEWblBqC/b5iaEWTcMdmXlo8H6JC17bHxLUbRAzFhFgDMTI4NjdKHG+HDt1EVD+epEjz/zx9hPGLCE1053HASkN0NeRUWB4qdxQ0z1cFH99bp97hqs6HLCGlHkhH8/8/CxZd37OGsMoxVOK3fm/vUqAmeg/26O0JfZDK0WzwYo1UJi7RcMpZP7XpBth1LFa1gEsUPmc0OFEHdT/MRphIBjr4B7xoVXZnMyPVRD6TdEJgzNERwkWZ6vVs1LSisVVpVpivsr7kcQUbOx3rsplDeyxQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 165.204.84.17) smtp.rcpttodomain=kernel.org smtp.mailfrom=amd.com; dmarc=pass (p=quarantine sp=quarantine pct=100) action=none header.from=amd.com; dkim=none (message not signed); arc=none (0) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amd.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=oQ7KFCwr61/HuiVwLq3AjULOM4jTzNo9F0kUTtMsoGE=; b=DCP7BfyfrM7rTC6RmfQDcFLv7jOFDabr1YGtdJp9G3px6E2IWu4H4e2/I/geANMVI1uzDvFonP9BiQVk/N9/wwR1yY5qcxa2Jx+jwZ7BJVR+dg2kie9y8WcPllv4y6Yql+9oNtYoTH8M2UCG9ZvC1H1w4qHkT01TZimzDlTHGtw= Received: from CH5PR05CA0004.namprd05.prod.outlook.com (2603:10b6:610:1f0::9) by MW6PR12MB8999.namprd12.prod.outlook.com (2603:10b6:303:247::8) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.8293.20; Thu, 2 Jan 2025 21:22:56 +0000 Received: from CH1PEPF0000AD7F.namprd04.prod.outlook.com (2603:10b6:610:1f0:cafe::62) by CH5PR05CA0004.outlook.office365.com (2603:10b6:610:1f0::9) with Microsoft SMTP Server (version=TLS1_3, cipher=TLS_AES_256_GCM_SHA384) id 15.20.8335.5 via Frontend Transport; Thu, 2 Jan 2025 21:22:56 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 165.204.84.17) smtp.mailfrom=amd.com; dkim=none (message not signed) header.d=none;dmarc=pass action=none header.from=amd.com; Received-SPF: Pass (protection.outlook.com: domain of amd.com designates 165.204.84.17 as permitted sender) receiver=protection.outlook.com; client-ip=165.204.84.17; helo=SATLEXMB04.amd.com; pr=C Received: from SATLEXMB04.amd.com (165.204.84.17) by CH1PEPF0000AD7F.mail.protection.outlook.com (10.167.244.88) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.20.8314.11 via Frontend Transport; Thu, 2 Jan 2025 21:22:56 +0000 Received: from SATLEXMB06.amd.com (10.181.40.147) by SATLEXMB04.amd.com (10.181.40.145) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.39; Thu, 2 Jan 2025 15:22:55 -0600 Received: from SATLEXMB03.amd.com (10.181.40.144) by SATLEXMB06.amd.com (10.181.40.147) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.39; Thu, 2 Jan 2025 15:22:55 -0600 Received: from xsjlizhih51.xilinx.com (10.180.168.240) by SATLEXMB03.amd.com (10.181.40.144) with Microsoft SMTP Server id 15.1.2507.39 via Frontend Transport; Thu, 2 Jan 2025 15:22:54 -0600 From: Lizhi Hou To: , , CC: Lizhi Hou , , , , , , , kernel test robot Subject: [PATCH V1 7/7] accel/amdxdna: Declare npu6_dev_priv as static Date: Thu, 2 Jan 2025 13:22:44 -0800 Message-ID: <20250102212244.1586340-7-lizhi.hou@amd.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20250102212244.1586340-1-lizhi.hou@amd.com> References: <20250102212244.1586340-1-lizhi.hou@amd.com> MIME-Version: 1.0 X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: CH1PEPF0000AD7F:EE_|MW6PR12MB8999:EE_ X-MS-Office365-Filtering-Correlation-Id: 0026a753-f32e-4db5-a6d3-08dd2b73a000 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; ARA:13230040|82310400026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xlsKDaZTIICDLcDBf1yOB2fJBOuyh8wreX6oxqEDkSDc+PLhJBLpq0IWWQbms6v4yiYOAfItnmkMHtXiiSmfq/4wJEhqsmBNbbkl6x62Tsu2w+DAgOQxURfRso/hAsdTOZwk3tDNlRk5MwsaQmVKAWPdNKHdEYYUxlT7VJCMHFNMbaX9iJ4/6EQlm5vrEFCq/WHK/HEWvvYmt9BkyacJwNFVw3drGXIJbrW8ysOFFv/TfkfXiGBmIEWOXWOETSePsIWn9wfHL6TcMzZsL9dWCqZmwYTYR5DZ1LY0vfzHat9/JmF98BIfl0xg2n9tfyKdq0hSMvXuJHpdOkKo4u5UIHlY4T/8+k48cbJYm/z5y6jMs7nUrbicMK4YaXGS8sPlcTLRtWjLC3ygc7HjEWaZ7fnLHw2Df9QVjQK7HV23uxu97l8jG3w0jzpY453KU0rhjtoMisvVylal/Xx5EPj2AiwbEvgu+3gVbubCx6Ka6JY= X-Forefront-Antispam-Report: CIP:165.204.84.17; CTRY:US; LANG:en; SCL:1; SRV:; IPV:CAL; SFV:NSPM; H:SATLEXMB04.amd.com; PTR:InfoDomainNonexistent; CAT:NONE; SFS:(13230040)(82310400026)(36860700013)(1800799024)(376014); DIR:OUT; SFP:1101; X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 02 Jan 2025 21:22:56.1327 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 0026a753-f32e-4db5-a6d3-08dd2b73a000 X-MS-Exchange-CrossTenant-Id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=3dd8961f-e488-4e60-8e11-a82d994e183d; Ip=[165.204.84.17]; Helo=[SATLEXMB04.amd.com] X-MS-Exchange-CrossTenant-AuthSource: CH1PEPF0000AD7F.namprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: MW6PR12MB8999 X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" Fix sparse warning: symbol 'npu6_dev_priv' was not declared. Should it be static? Fixes: 273b5176ac17 ("accel/amdxdna: Add RyzenAI-npu6 support") Reported-by: kernel test robot Closes: https://lore.kernel.org/oe-kbuild-all/202412311819.9mz11Uak-lkp@intel.com/ Signed-off-by: Lizhi Hou --- drivers/accel/amdxdna/npu6_regs.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/accel/amdxdna/npu6_regs.c b/drivers/accel/amdxdna/npu6_regs.c index f46c760cefc7..94a7005685a7 100644 --- a/drivers/accel/amdxdna/npu6_regs.c +++ b/drivers/accel/amdxdna/npu6_regs.c @@ -61,7 +61,7 @@ #define NPU6_SMU_BAR_BASE MMNPU_APERTURE4_BASE #define NPU6_SRAM_BAR_BASE MMNPU_APERTURE1_BASE -const struct amdxdna_dev_priv npu6_dev_priv = { +static const struct amdxdna_dev_priv npu6_dev_priv = { .fw_path = "amdnpu/17f0_10/npu.sbin", .protocol_major = 0x6, .protocol_minor = 12,