From patchwork Tue Jun 25 10:10:30 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Manikandan Muralidharan X-Patchwork-Id: 13710816 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 36ACBC2BBCA for ; Tue, 25 Jun 2024 10:10:56 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 497E810E40C; Tue, 25 Jun 2024 10:10:55 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=pass (2048-bit key; unprotected) header.d=microchip.com header.i=@microchip.com header.b="tR/oyxsL"; dkim-atps=neutral Received: from esa.microchip.iphmx.com (esa.microchip.iphmx.com [68.232.153.233]) by gabe.freedesktop.org (Postfix) with ESMTPS id 4086D10E40C for ; Tue, 25 Jun 2024 10:10:54 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=microchip.com; i=@microchip.com; q=dns/txt; s=mchp; t=1719310253; x=1750846253; h=from:to:cc:subject:date:message-id:mime-version: content-transfer-encoding; bh=MSWdBc8PKBdJ0A0i1o2EiwRYZcdlsnekjW41CeUrTk4=; b=tR/oyxsLMOvBo7rhHhErsyQxG4LxRGncqOMqVoFKJP3yrFN4kHFbd2UO HqaQmsLwrEFrdQb1A4BLQvjhprkrwI3T0OYbOiy7Wi6g+bVCyTqkGUNx5 wMo5DX7YUAhE/xitVlDLqaLd/oZBgBdoafEyeOzCJ4HpWBSTa+GB3cnjY B7Xx+slrevfHSWvjYLO/SEbB5j7+ojKvMI2+qw0iQIcAO4xReMmVW+Jnu sOKNIHpJAx5u6gQmBF5823KB/SDue7dYhvDqY5SRe1cKLg0X9XNWntckP Qv5nAif83lqkktI5Q19G+ry1yApgx0YuPpLvbuQup+iAaBpmKL8LrSPc6 w==; X-CSE-ConnectionGUID: iHJbrbJ5Qxy40j7Wq5Z2LA== X-CSE-MsgGUID: 6D9jdcc8SOWoH738OpHbtQ== X-IronPort-AV: E=Sophos;i="6.08,263,1712646000"; d="scan'208";a="31005830" X-Amp-Result: SKIPPED(no attachment in message) Received: from unknown (HELO email.microchip.com) ([170.129.1.10]) by esa1.microchip.iphmx.com with ESMTP/TLS/ECDHE-RSA-AES128-GCM-SHA256; 25 Jun 2024 03:10:53 -0700 Received: from chn-vm-ex01.mchp-main.com (10.10.85.143) by chn-vm-ex01.mchp-main.com (10.10.85.143) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.35; Tue, 25 Jun 2024 03:10:30 -0700 Received: from che-lt-i67131.microchip.com (10.10.85.11) by chn-vm-ex01.mchp-main.com (10.10.85.143) with Microsoft SMTP Server id 15.1.2507.35 via Frontend Transport; Tue, 25 Jun 2024 03:10:25 -0700 From: Manikandan Muralidharan To: , , , , , , , , , , , , CC: Subject: [PATCH] drm: atmel-hlcdc: fix static checker warning by initializing the local variable Date: Tue, 25 Jun 2024 15:40:30 +0530 Message-ID: <20240625101030.373965-1-manikandan.m@microchip.com> X-Mailer: git-send-email 2.25.1 MIME-Version: 1.0 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" Initialize the local variable used to store the status of LCDC Channel status register of each layer to fix the static checker warning reported by smatch Fixes: aa71584b323a ("drm: atmel-hlcdc: add driver ops to differentiate HLCDC and XLCDC IP") Signed-off-by: Manikandan Muralidharan --- drivers/gpu/drm/atmel-hlcdc/atmel_hlcdc_plane.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/atmel-hlcdc/atmel_hlcdc_plane.c b/drivers/gpu/drm/atmel-hlcdc/atmel_hlcdc_plane.c index 4a7ba0918eca..4150c4d0b4f2 100644 --- a/drivers/gpu/drm/atmel-hlcdc/atmel_hlcdc_plane.c +++ b/drivers/gpu/drm/atmel-hlcdc/atmel_hlcdc_plane.c @@ -559,7 +559,7 @@ static void atmel_hlcdc_plane_update_buffers(struct atmel_hlcdc_plane *plane, const struct atmel_hlcdc_layer_desc *desc = plane->layer.desc; struct atmel_hlcdc_dc *dc = plane->base.dev->dev_private; struct drm_framebuffer *fb = state->base.fb; - u32 sr; + u32 sr = 0; int i; if (!dc->desc->is_xlcdc)