From nobody Tue Feb 10 23:13:48 2026 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) (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 3E6C71C7014 for ; Wed, 2 Apr 2025 16:26:22 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=170.10.129.124 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1743611184; cv=none; b=P9yUR470diaQwQuwKfN3yjaowil4F7Ui3ccTL/dP/RHfioUajQBtu8eQByeSq8WkSOgbKA/rCzGfiRw2PZqKavMfnbCEFXriDn7QD+PbQH8drxtzyVmPT+8TO9NwYni4SX2Or6ju6gwJPS71E4l5x40SAAsD3qTJRIYjeBA0SAI= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1743611184; c=relaxed/simple; bh=4NECJWEGNcCzkUexn1VzkV2SkLcEjReKiF0klndVbl8=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=kGiBfbHVS2McRqVZwUeRObbSQy1jx2svdWlupElPy3YC7q5R+d3C0uESdq1y2ThzqH91/ju0jv+AMuLaIzhawlwwEgpI7OklB2Q8BJxrDwRL3A3R6uTGuj6r4OC1NMvhaijX2pEuk+chtq4TtHzktSzRi9ZQIZu00xAHJEjSlOk= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=redhat.com; spf=pass smtp.mailfrom=redhat.com; dkim=pass (1024-bit key) header.d=redhat.com header.i=@redhat.com header.b=NfaKw64A; arc=none smtp.client-ip=170.10.129.124 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=redhat.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=redhat.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=redhat.com header.i=@redhat.com header.b="NfaKw64A" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1743611182; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=lkk6+P8kz4b/Qa31/Ssl4swVSnk002BGAZpApGFTvXM=; b=NfaKw64AUCR0Jh9W7qF5HtSQQr3opoSOjXLpAeSPZJ3b7juYmOMoRAl5ayewojFxTerpoU 10wU1O5SxOfIr6cT8w++Eo0b1KomL/IBFlCY2Y1ip+8baYrf0qjRGLNDsX5+kKjNkBZpJI x5oKbsr8ceY/cgNDJxVjwp5xazp0Sco= Received: from mx-prod-mc-08.mail-002.prod.us-west-2.aws.redhat.com (ec2-35-165-154-97.us-west-2.compute.amazonaws.com [35.165.154.97]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-441-Dr0IbInTN0qayJUWiB7LhA-1; Wed, 02 Apr 2025 12:26:19 -0400 X-MC-Unique: Dr0IbInTN0qayJUWiB7LhA-1 X-Mimecast-MFC-AGG-ID: Dr0IbInTN0qayJUWiB7LhA_1743611176 Received: from mx-prod-int-05.mail-002.prod.us-west-2.aws.redhat.com (mx-prod-int-05.mail-002.prod.us-west-2.aws.redhat.com [10.30.177.17]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mx-prod-mc-08.mail-002.prod.us-west-2.aws.redhat.com (Postfix) with ESMTPS id 62B8C1801A00; Wed, 2 Apr 2025 16:26:16 +0000 (UTC) Received: from asrivats-na.rmtustx.csb (unknown [10.2.16.30]) by mx-prod-int-05.mail-002.prod.us-west-2.aws.redhat.com (Postfix) with ESMTP id 7296C195609D; Wed, 2 Apr 2025 16:26:12 +0000 (UTC) From: Anusha Srivatsa Date: Wed, 02 Apr 2025 11:23:48 -0400 Subject: [PATCH 10/30] panel/ilitek-ili9881c: Use refcounted allocation in place of devm_kzalloc() Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Message-Id: <20250402-b4-drm_panel_mass_convert_part2-v1-10-903b70999ea6@redhat.com> References: <20250402-b4-drm_panel_mass_convert_part2-v1-0-903b70999ea6@redhat.com> In-Reply-To: <20250402-b4-drm_panel_mass_convert_part2-v1-0-903b70999ea6@redhat.com> To: Neil Armstrong , Jessica Zhang , Maarten Lankhorst , Maxime Ripard , Thomas Zimmermann , David Airlie , Simona Vetter , Icenowy Zheng , Jagan Teki , Ondrej Jirman , Javier Martinez Canillas , Michael Trimarchi , Michael Walle , Jagan Teki , =?utf-8?q?Guido_G=C3=BCnther?= , Purism Kernel Team , Linus Walleij , Jianhua Lu , Stefan Mavrodiev Cc: dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org, Anusha Srivatsa X-Developer-Signature: v=1; a=ed25519-sha256; t=1743607440; l=1306; i=asrivats@redhat.com; s=20250122; h=from:subject:message-id; bh=4NECJWEGNcCzkUexn1VzkV2SkLcEjReKiF0klndVbl8=; b=p+sd4NMCJM/MyUF25c/ggqMXE3ykI0Vz9CJApZGMFozILEr0KZqA9bHVXk7Ivbl+glk5BqoNK IVmAUzAf3MSDi3OQMPt5Ep8IvFMY9sUXqNvCcoKXIUN+SVlVPyoQIQ+ X-Developer-Key: i=asrivats@redhat.com; a=ed25519; pk=brnIHkBsUZEhyW6Zyn0U92AeIZ1psws/q8VFbIkf1AU= X-Scanned-By: MIMEDefang 3.0 on 10.30.177.17 Move to using the new API devm_drm_panel_alloc() to allocate the panel. Signed-off-by: Anusha Srivatsa --- drivers/gpu/drm/panel/panel-ilitek-ili9881c.c | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/drivers/gpu/drm/panel/panel-ilitek-ili9881c.c b/drivers/gpu/dr= m/panel/panel-ilitek-ili9881c.c index 28cd7560e5db1d5734b10babdb4e4e553c6e07d0..aa4192def09353afa40c1981d0b= 105064fe95b02 100644 --- a/drivers/gpu/drm/panel/panel-ilitek-ili9881c.c +++ b/drivers/gpu/drm/panel/panel-ilitek-ili9881c.c @@ -1506,16 +1506,15 @@ static int ili9881c_dsi_probe(struct mipi_dsi_devic= e *dsi) struct ili9881c *ctx; int ret; =20 - ctx =3D devm_kzalloc(&dsi->dev, sizeof(*ctx), GFP_KERNEL); - if (!ctx) - return -ENOMEM; + ctx =3D devm_drm_panel_alloc(&dsi->dev, struct ili9881c, panel, &ili9881c= _funcs, + DRM_MODE_CONNECTOR_DSI); + if (IS_ERR(ctx)) + return PTR_ERR(ctx); + mipi_dsi_set_drvdata(dsi, ctx); ctx->dsi =3D dsi; ctx->desc =3D of_device_get_match_data(&dsi->dev); =20 - drm_panel_init(&ctx->panel, &dsi->dev, &ili9881c_funcs, - DRM_MODE_CONNECTOR_DSI); - ctx->power =3D devm_regulator_get(&dsi->dev, "power"); if (IS_ERR(ctx->power)) return dev_err_probe(&dsi->dev, PTR_ERR(ctx->power), --=20 2.48.1