From mboxrd@z Thu Jan 1 00:00:00 1970 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 EE90CC531FA for ; Fri, 24 Jul 2026 15:09:15 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 0A47010F40B; Fri, 24 Jul 2026 15:09:15 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=fail reason="signature verification failed" (1024-bit key; unprotected) header.d=arm.com header.i=@arm.com header.b="dX/HIUYA"; dkim-atps=neutral Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by gabe.freedesktop.org (Postfix) with ESMTP id B613D10F40B for ; Fri, 24 Jul 2026 15:09:13 +0000 (UTC) Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 467CA1477; Fri, 24 Jul 2026 08:09:08 -0700 (PDT) Received: from [10.1.25.28] (e122027.cambridge.arm.com [10.1.25.28]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 228F83F59E; Fri, 24 Jul 2026 08:09:08 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=arm.com; s=foss; t=1784905752; bh=LJj0wIf6UV/V4kejtTOZwHLYUh1lYpv+ZBzBE2b4hXA=; h=Date:Subject:To:References:From:In-Reply-To:From; b=dX/HIUYAAFQjuuwWBciRHXbXL2bie+x7ueubE5ZdQzZrkuvlJweWw2IS0k6zsPWYW fMYPHshdpiKT/7PYudkdfUPmVK3QHMAKO6jSzUz1bBWHuHVZZk9pUzhBQL04PjNB23 uSXEhZQ1bywq2QJpXLNEjKu9O8xyPSbts6QouNvc= Message-ID: <64cdc80f-f8a0-482a-9207-059a5f45ca68@arm.com> Date: Fri, 24 Jul 2026 16:08:46 +0100 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH] drm/panthor: return PTR_ERR() from devm_drm_dev_alloc() To: Osama Abdelkader , Boris Brezillon , Liviu Dudau , Maarten Lankhorst , Maxime Ripard , Thomas Zimmermann , David Airlie , Simona Vetter , Grant Likely , dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org References: <20260716140337.10679-1-osama.abdelkader@gmail.com> From: Steven Price Content-Language: en-GB In-Reply-To: <20260716140337.10679-1-osama.abdelkader@gmail.com> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit 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" On 16/07/2026 15:03, Osama Abdelkader wrote: > devm_drm_dev_alloc() returns an ERR_PTR() on failure, but panthor_probe() > always converts that failure to -ENOMEM. Preserve the actual error code > returned by the DRM core instead. > > Fixes: 4bdca1150792 ("drm/panthor: Add the driver frontend block") > Signed-off-by: Osama Abdelkader Reviewed-by: Steven Price I'll apply this to drm-misc-next. Thanks, Steve > --- > drivers/gpu/drm/panthor/panthor_drv.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/drivers/gpu/drm/panthor/panthor_drv.c b/drivers/gpu/drm/panthor/panthor_drv.c > index 487eedb72ac5..847db031e165 100644 > --- a/drivers/gpu/drm/panthor/panthor_drv.c > +++ b/drivers/gpu/drm/panthor/panthor_drv.c > @@ -1824,7 +1824,7 @@ static int panthor_probe(struct platform_device *pdev) > ptdev = devm_drm_dev_alloc(&pdev->dev, &panthor_drm_driver, > struct panthor_device, base); > if (IS_ERR(ptdev)) > - return -ENOMEM; > + return PTR_ERR(ptdev); > > platform_set_drvdata(pdev, ptdev); >