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 DBFB2C433F5 for ; Thu, 17 Mar 2022 19:21:14 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 40C4A10E00E; Thu, 17 Mar 2022 19:21:14 +0000 (UTC) Received: from mx2.smtp.larsendata.com (mx2.smtp.larsendata.com [91.221.196.228]) by gabe.freedesktop.org (Postfix) with ESMTPS id EA42710E00E for ; Thu, 17 Mar 2022 19:21:12 +0000 (UTC) Received: from mail01.mxhotel.dk (mail01.mxhotel.dk [91.221.196.236]) by mx2.smtp.larsendata.com (Halon) with ESMTPS id 67a4b5b8-a627-11ec-9ac0-0050568cd888; Thu, 17 Mar 2022 19:21:11 +0000 (UTC) Received: from ravnborg.org (80-162-45-141-cable.dk.customer.tdc.net [80.162.45.141]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) (Authenticated sender: sam@ravnborg.org) by mail01.mxhotel.dk (Postfix) with ESMTPSA id 86B53194B05; Thu, 17 Mar 2022 20:21:10 +0100 (CET) Date: Thu, 17 Mar 2022 20:21:06 +0100 X-Report-Abuse-To: abuse@mxhotel.dk From: Sam Ravnborg To: Lu Wei Subject: Re: [PATCH,v2] drm/panel: Fix return value check in nt35950_probe() Message-ID: References: <20220317083707.237039-1-luwei32@huawei.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20220317083707.237039-1-luwei32@huawei.com> 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: , Cc: airlied@linux.ie, linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org, thierry.reding@gmail.com, angelogioacchino.delregno@somainline.org, marijn.suijten@somainline.org Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" On Thu, Mar 17, 2022 at 04:37:07PM +0800, Lu Wei wrote: > In function nt35950_probe(), mipi_dsi_device_register_full() is called > to create a MIPI DSI device. If it fails, a pointer encoded with an error > will be returned, so use IS_ERR() to check the return value. Besides, use > PTR_ERR to return the actual errno. > > Fixes: 623a3531e9cf ("drm/panel: Add driver for Novatek NT35950 DSI DriverIC panels") > Signed-off-by: Lu Wei Acked-by: Sam Ravnborg