Message ID | 20230309160201.5163-80-tzimmermann@suse.de |
---|---|
State | New |
Headers |
Return-Path: <linux-kernel-owner@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:5915:0:0:0:0:0 with SMTP id v21csp388306wrd; Thu, 9 Mar 2023 08:32:47 -0800 (PST) X-Google-Smtp-Source: AK7set/cPNbV17fw+zIFh5i8cqdfCDUS+5uBoZHCF6G1cyYBGgY2J/Z1GSjItiODfPbqQm7xXdNj X-Received: by 2002:a92:1a43:0:b0:316:d9fa:f31b with SMTP id z3-20020a921a43000000b00316d9faf31bmr15426637ill.32.1678379567494; Thu, 09 Mar 2023 08:32:47 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1678379567; cv=none; d=google.com; s=arc-20160816; b=ExvwysimqhwxoVs7LrgwwhARhvjt3mEk12zC9+LlTLSXXblDeKPTuZsPafk/z6CbXz 0tQRpPAd8X6ENectDGrMxEtL8MvL2NVHY5wOriu8iXJ4YZDhj4aw2pNDyxKnKjF52uAz Ipkm5Jtf7AcCnhE+5oz2t4JWrQYmTDVnsFMBlMFtkhSFEWkP+XWPX5NA7IpIqoluGqOy o0elqqJvw9plk/vQiEWWl4H6VnN2tZzWo+n3ySCWZ7Irxpxop4SiCefQ+LVpqCn3HydZ iG1p1TUdDKn/qXKWyFn5obB/X66wDDl8D4BXera+cA9mIfr55lggyNL3KGcG9N0fyz2u TeYg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature:dkim-signature; bh=LTM3CGrNdrXHYDt3uvNdE9HVmQsT5bWUcDXgP42T3Vw=; b=X8UQZsIjc4dTJAbWiNYBt2NtiQZMx9NE7HcPLOfBo2pFKrq99LQ5SFwqA5ReuOdxGQ fn7TtWQzkkmtVwkUpIVCN5brZ3UhfugFpvUb41b63l+IgpZwxd7zsd26Rbx70ujxygsX 7ZzuOZXnscrIwuDuVxoxpwzbnD0UXSBskfzBl+e3d/JXgGTTiAtxA2cBLMVFdTtad6ni SLr90lD7aHS8YiySVTdLRr7UDVjOxjWjtbLI2pgWusEfmgHBZvGxsttJl5ZqtWkEBcRB T9y8I3PaDS2EOhRQ+FAck/Q3GNOx5ZITQ7eC04wE6A8CLduU6equJIywabyeUewuzsz+ pPeg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@suse.de header.s=susede2_rsa header.b=aEwptXQd; dkim=neutral (no key) header.i=@suse.de header.s=susede2_ed25519; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=suse.de Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id k7-20020a02ccc7000000b003c2b42c554asi17508553jaq.11.2023.03.09.08.32.32; Thu, 09 Mar 2023 08:32:47 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@suse.de header.s=susede2_rsa header.b=aEwptXQd; dkim=neutral (no key) header.i=@suse.de header.s=susede2_ed25519; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=suse.de Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232411AbjCIQKK (ORCPT <rfc822;carlos.wei.hk@gmail.com> + 99 others); Thu, 9 Mar 2023 11:10:10 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:47506 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231747AbjCIQCi (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Thu, 9 Mar 2023 11:02:38 -0500 Received: from smtp-out1.suse.de (smtp-out1.suse.de [IPv6:2001:67c:2178:6::1c]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id A94B7F7EC0; Thu, 9 Mar 2023 08:02:37 -0800 (PST) Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by smtp-out1.suse.de (Postfix) with ESMTPS id 624F322167; Thu, 9 Mar 2023 16:02:36 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_rsa; t=1678377756; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=LTM3CGrNdrXHYDt3uvNdE9HVmQsT5bWUcDXgP42T3Vw=; b=aEwptXQdCCH+AJ6u2L2xYdN2fF80ZjhX3VqQxgndG0KrIdZF76bRLH07xcfggmBfj+K8HX R5CIgQ3pkLkK+HaCIm8UbgRwSKMQvdAWI0xxPC625t6nY2jjWXS4XGhxRRGL0uRIdIp9C/ uFOSm+SYL+Nunq6xFZ5mX35ulJ/XGrg= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_ed25519; t=1678377756; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=LTM3CGrNdrXHYDt3uvNdE9HVmQsT5bWUcDXgP42T3Vw=; b=K7r4EOgkK1n3HkqGvnXwPSIxWAcooJM04yuU58O/ZH8Qm8g6hw+VEogus+YPrAqkcW3tFO e6Yk9g42vXUNnQCA== Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by imap2.suse-dmz.suse.de (Postfix) with ESMTPS id 0131613A73; Thu, 9 Mar 2023 16:02:35 +0000 (UTC) Received: from dovecot-director2.suse.de ([192.168.254.65]) by imap2.suse-dmz.suse.de with ESMTPSA id OBb0OhsDCmQHbgAAMHmgww (envelope-from <tzimmermann@suse.de>); Thu, 09 Mar 2023 16:02:35 +0000 From: Thomas Zimmermann <tzimmermann@suse.de> To: deller@gmx.de, geert+renesas@glider.be, timur@kernel.org, rdunlap@infradead.org, paulus@samba.org, benh@kernel.crashing.org, linux@armlinux.org.uk, pjones@redhat.com, adaplas@gmail.com, s.hauer@pengutronix.de, shawnguo@kernel.org, mbroemme@libmpq.org, thomas@winischhofer.net, James.Bottomley@HansenPartnership.com, sudipm.mukherjee@gmail.com, teddy.wang@siliconmotion.com, corbet@lwn.net Cc: linux-fbdev@vger.kernel.org, dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org, Thomas Zimmermann <tzimmermann@suse.de> Subject: [PATCH v2 079/101] fbdev/stifb: Constify option string Date: Thu, 9 Mar 2023 17:01:39 +0100 Message-Id: <20230309160201.5163-80-tzimmermann@suse.de> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20230309160201.5163-1-tzimmermann@suse.de> References: <20230309160201.5163-1-tzimmermann@suse.de> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-4.4 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_MED,SPF_HELO_NONE, SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: <linux-kernel.vger.kernel.org> X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1759908533236563749?= X-GMAIL-MSGID: =?utf-8?q?1759908533236563749?= |
Series |
fbdev: Fix memory leak in option parsing
|
|
Commit Message
Thomas Zimmermann
March 9, 2023, 4:01 p.m. UTC
Constify the internal option string that is passed around among
functions. The caller owns the memory and callees do not modify
its content. This change will later allow to constify the caller's
option string as well. No functional changes.
v2:
* say 'stifb' and fix typos in commit message
Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de>
---
drivers/video/fbdev/stifb.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/video/fbdev/stifb.c b/drivers/video/fbdev/stifb.c index a151377f5b45..304ce8fcb9f8 100644 --- a/drivers/video/fbdev/stifb.c +++ b/drivers/video/fbdev/stifb.c @@ -1392,7 +1392,7 @@ static int __init stifb_init_fb(struct sti_struct *sti, int bpp_pref) static int stifb_disabled __initdata; int __init -stifb_setup(char *options); +stifb_setup(const char *options); static int __init stifb_init(void) { @@ -1465,7 +1465,7 @@ stifb_cleanup(void) } int __init -stifb_setup(char *options) +stifb_setup(const char *options) { int i;