Received: by 2002:a89:d88:0:b0:1fa:5c73:8e2d with SMTP id eb8csp1902846lqb; Mon, 27 May 2024 00:59:13 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCWcMlEhAJ1do5eR34QY7pUFWGRVUTSEUPDxYVCQdLr1cWNyUiDQMOwVPztdJBM+vxUXbL/dUwfRsybBGG3hR2WkwyCiuRq9jeXK8AnR/Q== X-Google-Smtp-Source: AGHT+IELZnsi+qkVE0Wdoa+/4QrvC3ENREZQno2V6pMNX9mwgk/EmzVU/rmJsGFE6i9qQ+qRxrZ3 X-Received: by 2002:a17:90a:6047:b0:2bd:fadd:75e3 with SMTP id 98e67ed59e1d1-2bf5f2080e3mr9324888a91.34.1716796752895; Mon, 27 May 2024 00:59:12 -0700 (PDT) Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [139.178.88.99]) by mx.google.com with ESMTPS id 98e67ed59e1d1-2bfc55e7241si1654360a91.72.2024.05.27.00.59.12 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 27 May 2024 00:59:12 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-190181-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) client-ip=139.178.88.99; Authentication-Results: mx.google.com; dkim=pass header.i=@amd.com header.s=selector1 header.b=POVn3K+I; arc=fail (signature failed); spf=pass (google.com: domain of linux-kernel+bounces-190181-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-190181-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=amd.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sv.mirrors.kernel.org (Postfix) with ESMTPS id 7D983281DAD for ; Mon, 27 May 2024 07:59:12 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 7B8BA5812F; Mon, 27 May 2024 07:58:24 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=amd.com header.i=@amd.com header.b="POVn3K+I" Received: from NAM02-BN1-obe.outbound.protection.outlook.com (mail-bn1nam02on2056.outbound.protection.outlook.com [40.107.212.56]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 7AF66C152; Mon, 27 May 2024 07:58:21 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=fail smtp.client-ip=40.107.212.56 ARC-Seal:i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1716796703; cv=fail; b=YPEJ8IbvFeduAKbjxJ9A2z8xEItuomZxYEE8Wg4VZhoGM9I68ayYBCkqq64ibj6jjA0zlx7O4CcBOTCXAk8fmKVhzUiiionZhkXlxHeim8IsqdVXbVOWHLitZVihRxKu6jY4o7hLuTe9lGgYt6g8pjw5uB7Iv40K421bkoQ50VQ= ARC-Message-Signature:i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1716796703; c=relaxed/simple; bh=cfcHaUwbOkOl5ivrLotL3biorO7l47P/Jv+mTX+lkTc=; h=Message-ID:Date:Subject:To:References:From:In-Reply-To: Content-Type:MIME-Version; b=GhhxhpRpq3PpDsMwPmMJYgcwuwJGXXgI+lfy6ImZLxuyhGD/0R3lQ16RbtWbFKEHoFF/OuQdSUl3nlRCyj8oFGXIIy5/DX/VfLdJOpK7cUGM2mvag2w7Gew4mhb2ECcecgy3LBYhqYBovctUrxUSO5OVI9DAJQoI9rCrNV+RsWA= ARC-Authentication-Results:i=2; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=amd.com; spf=fail smtp.mailfrom=amd.com; dkim=pass (1024-bit key) header.d=amd.com header.i=@amd.com header.b=POVn3K+I; arc=fail smtp.client-ip=40.107.212.56 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=amd.com Authentication-Results: smtp.subspace.kernel.org; spf=fail smtp.mailfrom=amd.com ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=KQG9GI//zXbh7RzY5b8UDZ/uIcOlki4AINTQy+XiRr6HDWglYS0Hta8n75Qv9u0WZvsfWkedFkOS5tDE/3J467rdvceDaJOraCpmVBYi7kLH3ywJk3gGv8N9wG6g20YtJ/AqqopeOVIGsmV/pM0rgBR4NDoeslfCeAVcrZOg4kW4Z/aUF4QnHBeDdy650A9xtyVRZm5LGvH8zUcngRExRvnv8aQU4sg3FZ1r0DHGACs6ZvAZahhrQHYnhUOsjbt7KfEuE1zEW8KuyXL1UKp+7oi7O+fthkynS4z5CZeUxAj6Dh/lF7KfBYU0nGgRtjkB5TgpGzgqDIDnxLr0pDEpKw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; 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=BdQJ5jI1YUEHqUaOSi/Nemr+JSx8g49Q5Z0tXSKF5wk=; b=DuYhbLGw+t62ErGHJsm3jOoWwTH4Thi2DFcVpCDeRbxODUtHBlJ4RbdrsL0xyn9LhcMovu0l4VZugTCG+XwcwZU7mGWgMSsAKxnA1bfcbYgZ+c5Sd1bNrcwAohUPsLlOQvbXub8pAuT6kOaffyzJpPJYH1bO9dj7kdl1wZAsPeylmIBjx3QbcvClGFSRpI8ftXNBX1oCTzDJ3595pDcE8XKT1/sk1ecyLTbmzsFp081VOXFqihWoYy87GKsfzYeTWF6BhI2nDZCqGyefJ5OrqA9gxjFgxi4Gu9X2sRNTw+2A6H/9f3xxqw7UD/C+QLYB1ukEgl2kP2voriLTHLXtrg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=amd.com; dmarc=pass action=none header.from=amd.com; dkim=pass header.d=amd.com; arc=none 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=BdQJ5jI1YUEHqUaOSi/Nemr+JSx8g49Q5Z0tXSKF5wk=; b=POVn3K+Iteir05ugplC5ujrWSvkwk2gAbrPoSIlly0ody7nra+yIWK3iFDjLAw8pJAKsSHWEBml4YkR6hJy48DgJtGK3Go16h0d/SJ8Q/ligdKwOQ8tnkk2dWjb8Y0ligUT/NYHCY2HZ5KiP44M723n6w9VqHH037A3kOkzts4Q= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=amd.com; Received: from PH7PR12MB5685.namprd12.prod.outlook.com (2603:10b6:510:13c::22) by SN7PR12MB7881.namprd12.prod.outlook.com (2603:10b6:806:34a::9) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7611.29; Mon, 27 May 2024 07:58:18 +0000 Received: from PH7PR12MB5685.namprd12.prod.outlook.com ([fe80::46fb:96f2:7667:7ca5]) by PH7PR12MB5685.namprd12.prod.outlook.com ([fe80::46fb:96f2:7667:7ca5%2]) with mapi id 15.20.7611.025; Mon, 27 May 2024 07:58:18 +0000 Message-ID: Date: Mon, 27 May 2024 09:58:11 +0200 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH] drm/radeon/r100: enhance error handling in r100_cp_init_microcode To: Zhouyi Zhou , alexander.deucher@amd.com, Xinhui.Pan@amd.com, airlied@gmail.com, daniel@ffwll.ch, chris@chrisdown.name, amd-gfx@lists.freedesktop.org, dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org, rcu@vger.kernel.org, lance@osuosl.org References: <20240527012018.351223-1-zhouzhouyi@gmail.com> Content-Language: en-US From: =?UTF-8?Q?Christian_K=C3=B6nig?= In-Reply-To: <20240527012018.351223-1-zhouzhouyi@gmail.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit X-ClientProxiedBy: FR0P281CA0100.DEUP281.PROD.OUTLOOK.COM (2603:10a6:d10:a9::6) To PH7PR12MB5685.namprd12.prod.outlook.com (2603:10b6:510:13c::22) Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: PH7PR12MB5685:EE_|SN7PR12MB7881:EE_ X-MS-Office365-Filtering-Correlation-Id: 3f5b676a-2782-48bd-3d45-08dc7e22c561 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0;ARA:13230031|376005|1800799015|366007|921011; X-Microsoft-Antispam-Message-Info: =?utf-8?B?U05YV3g5QVovN2JjWDlCb24yckozY2RMdnVJMWFGajNJQ1pKRytpSHN2ZTZh?= =?utf-8?B?MFdjbmVkUlpBYVErdHpUSC9oVWM2Vk5qMXArcU5uY3VJYWlvYlFneTYrZnlI?= =?utf-8?B?SStNQnhRTnBSZmN2MVArK0dUSDBsZXZSVEFJLzJBYmhOQng3UGhGVTIxckNi?= =?utf-8?B?ZVR0cExuaHVvdVpxNjRTa3hCdFlrczRQNTNLcjJVWjhMODluV3A0dWg5MGFX?= =?utf-8?B?UVpjbjk0cVErZWQxRjFXRTFhMkFPSnBZblhWTUZUMGg2cjhsbFJ5Y3h6WUxW?= =?utf-8?B?dzBiZzRmNHZrdUliQXdQcTdrQllIMCtnSmNzS0NMQ1VncElYOXBxSzJQOE1m?= =?utf-8?B?aExXaUM4dUZRNXhyWTBmUXA3Y1dhQ1VWSWJRVTRpVzV4UWloRHNoeGpUNjM5?= =?utf-8?B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GQmQvY0lm?= =?utf-8?B?RzZHQUVqWlJFd1dDa0FvV01aQjlyb1NadVVKUkdYZXkxampzTEZJckRmUHNF?= =?utf-8?B?d0N1djNDblJKVGRyeklWQkVzNFpvWjZKRzBJSDdpYzNTVkFYR0VPMXRvSU1U?= =?utf-8?B?cVNyNjNhdHZiOG5JOXlOR0RFYkhzRnNUTDd5cG15ckFoZ2orUHUxbFVyUzRU?= =?utf-8?B?YzN3OVNNdTBaSmlqMjZrOHBlQVloam52VDhCaFo5RWdlV3hpdkZiUTBvUDBX?= =?utf-8?B?QTVjbitOcklkVTBTZnViaDVoZUpjUXpBSElLbzM0K2Q1b3dQc1ozOUlnSU5I?= =?utf-8?B?SlgzQnh1NFZvR3BYemVpKy8zZkxmQ2pCZzQ2QjJHaTJBTmdpdDZhME10dmo5?= =?utf-8?B?SHFaN1lWaHRCRlVhVklZczdiQ2VUZlZEdjRsR2hpZ292SmgvdGF1VFlQdG9C?= =?utf-8?Q?1/dFYOLg4jfbwbRIVWk+xcxjN4OQIZ9wCHyiVhK?= X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:PH7PR12MB5685.namprd12.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230031)(376005)(1800799015)(366007)(921011);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?utf-8?B?bWw4a0d2OU56dytFbm9ZSU9IZUNFRGlxZjFRamVNdUV1SjF1LytEVkQrUVhW?= =?utf-8?B?dXl1dWo4OWJkWHlsOUVTRlNSbmV4UjU4UUY3QWxJcU5sNGhJZlk5SXZYYmJC?= =?utf-8?B?SW5qYmZnOUh0TjZVZzNnc25TZ25BRWdXbjhOTkVXTFczK2dRZE1TSFd5VUhE?= =?utf-8?B?c3UyQjM2Z0Y0cUZ1MjRYcEFQeUZKejFKbFhhNVdCdUFUbWl4Qy8xNFV4K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dPYTQ5cS9GM2ZYYXpicFh4a0pwM21HNkp4bXBXM05Z?= =?utf-8?B?aUNZNmp4WkVwcVlIWXFLa0d5Tngyb0dZeEZsckNyd2E3KzA5cDk2ejBGMFZn?= =?utf-8?Q?W+kzA6rUuCGzE0FlSa15O2CJJ?= X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-Network-Message-Id: 3f5b676a-2782-48bd-3d45-08dc7e22c561 X-MS-Exchange-CrossTenant-AuthSource: PH7PR12MB5685.namprd12.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 27 May 2024 07:58:18.6236 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: gbgG/lT87xVDKnbwVWtHauqsKUbPTGOqhOQbeh/luDaVK6QoYToY2EKoQ0OJGg6y X-MS-Exchange-Transport-CrossTenantHeadersStamped: SN7PR12MB7881 Am 27.05.24 um 03:20 schrieb Zhouyi Zhou: > In r100_cp_init_microcode, if rdev->family don't match any of > if statement, fw_name will be NULL, which will cause > gcc (11.4.0 powerpc64le-linux-gnu) complain: > > In function ‘r100_cp_init_microcode’, > inlined from ‘r100_cp_init’ at drivers/gpu/drm/radeon/r100.c:1136:7: > ./include/linux/printk.h:457:44: warning: ‘%s’ directive argument is null [-Wformat-overflow=] > 457 | #define printk(fmt, ...) printk_index_wrap(_printk, fmt, ##__VA_ARGS__) > > Above warning is emitted during the rcutorture test in > in PPC VM of Opensource Lab of Oregon State Univerisity. > > Enhance error handling in r100_cp_init_microcode, let r100_cp_init_microcode > return with -EINVAL when none of chip families is matched. > > Signed-off-by: Zhouyi Zhou > --- > drivers/gpu/drm/radeon/r100.c | 7 +++++++ > 1 file changed, 7 insertions(+) > > diff --git a/drivers/gpu/drm/radeon/r100.c b/drivers/gpu/drm/radeon/r100.c > index 0b1e19345f43..4f8a1bdd9365 100644 > --- a/drivers/gpu/drm/radeon/r100.c > +++ b/drivers/gpu/drm/radeon/r100.c > @@ -1055,6 +1055,11 @@ static int r100_cp_init_microcode(struct radeon_device *rdev) > (rdev->family == CHIP_RV570)) { > DRM_INFO("Loading R500 Microcode\n"); > fw_name = FIRMWARE_R520; > + } else { > + pr_err("radeon_cp: Failed to load firmware \"%d\"\n", > + rdev->family); > + err = -EINVAL; > + goto out; > } > > err = request_firmware(&rdev->me_fw, fw_name, rdev->dev); > @@ -1067,6 +1072,8 @@ static int r100_cp_init_microcode(struct radeon_device *rdev) > release_firmware(rdev->me_fw); > rdev->me_fw = NULL; > } > + > +out: That looks superfluous, just return -EINVAL directly in the else case above. Apart from that this is for ~15year old hardware. I'm a bit reluctant adding code for something that old even when this change here looks harmless. Is there a plan to complain about that in an automated checker? If yes then the change is probably justified, if no then I would rather not do it. Regards, Christian. > return err; > } >