From patchwork Wed Nov 30 21:39:11 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Rasmus Villemoes X-Patchwork-Id: 9454991 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id A4E9360585 for ; Wed, 30 Nov 2016 21:41:07 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 97EBF28492 for ; Wed, 30 Nov 2016 21:41:07 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 8CC60284A1; Wed, 30 Nov 2016 21:41:07 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.8 required=2.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_HI,T_DKIM_INVALID autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 21579223A4 for ; Wed, 30 Nov 2016 21:41:06 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1758997AbcK3VkS (ORCPT ); Wed, 30 Nov 2016 16:40:18 -0500 Received: from mail-wm0-f51.google.com ([74.125.82.51]:36240 "EHLO mail-wm0-f51.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755130AbcK3Vjg (ORCPT ); Wed, 30 Nov 2016 16:39:36 -0500 Received: by mail-wm0-f51.google.com with SMTP id g23so281217010wme.1 for ; Wed, 30 Nov 2016 13:39:35 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=rasmusvillemoes.dk; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=VcdVfSHpxCpnkGcXEUh2CMynfvZRWdMVxYHo4EGDs3I=; b=fJtgzKkHFcb3HV+AkWmrtqZyS2P34lKQSruh+CGebtPAl2AY12X/hSiBhuMLctjdW1 bLc1T0xhA5KriVdVEdPFypOAWipeF6mR8hs70iWMsoJzATzAcXShKET6i+XMSC37VN/7 wc3viGR/hOQDbehYDq619A7ARt+sLRulrSFU8= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=VcdVfSHpxCpnkGcXEUh2CMynfvZRWdMVxYHo4EGDs3I=; b=K66tkKtR0Wwz3mjwr2m+Va7GxunUsLz8uruKZyaElJa5qqU1/EfPUdMyjH8U0uYr/+ wb7bNljTCwhi9eYGfkMzR81X26BlvsBTURU9gRz6EiK8qxfughuZOU0zz7O3ipuspiBE HBuftX6Zw8/rscx2HtmzR21lU8jN9xn3vAylvH0njWSZC/sR9BuhmoVa6cKCHlobPyIG xjN53lFaP4Evh644d5w8KJVCbghB1ZHCkgvmIzSzdkkEjrP4V72Lyw81pppcPwsjaRPB WGqFbx5ZxuTnwopJmUE9DkBBxqN6Em97Ided5Sq1k3rlcz/l2eJStA7hAsW65h+FjVUy mJVw== X-Gm-Message-State: AKaTC025HQK+B1KsS4a310AbO2J02cPpBAlvKvS39nLbKm2y3hka6aVDfxLeqjzcGPLs/A== X-Received: by 10.28.212.131 with SMTP id l125mr28647642wmg.117.1480541974852; Wed, 30 Nov 2016 13:39:34 -0800 (PST) Received: from lvps87-230-87-209.dedicated.hosteurope.de (wildmoose.dk. [87.230.87.209]) by smtp.gmail.com with ESMTPSA id di9sm74904113wjc.37.2016.11.30.13.39.34 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Wed, 30 Nov 2016 13:39:34 -0800 (PST) From: Rasmus Villemoes To: Malcolm Priestley , Mauro Carvalho Chehab Cc: Rasmus Villemoes , linux-media@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 3/4] [media] lmedm04: make some string arrays static Date: Wed, 30 Nov 2016 22:39:11 +0100 Message-Id: <1480541953-27256-3-git-send-email-linux@rasmusvillemoes.dk> X-Mailer: git-send-email 2.1.4 In-Reply-To: <1480541953-27256-1-git-send-email-linux@rasmusvillemoes.dk> References: <1480541953-27256-1-git-send-email-linux@rasmusvillemoes.dk> Sender: linux-media-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP It takes more .text to initialize these on the stack than they occupy in .rodata, so just make them static const. Signed-off-by: Rasmus Villemoes --- drivers/media/usb/dvb-usb-v2/lmedm04.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/drivers/media/usb/dvb-usb-v2/lmedm04.c b/drivers/media/usb/dvb-usb-v2/lmedm04.c index cd463f09ebc7..bf5bc36a6ed9 100644 --- a/drivers/media/usb/dvb-usb-v2/lmedm04.c +++ b/drivers/media/usb/dvb-usb-v2/lmedm04.c @@ -1002,8 +1002,9 @@ static int lme_name(struct dvb_usb_adapter *adap) struct dvb_usb_device *d = adap_to_d(adap); struct lme2510_state *st = adap_to_priv(adap); const char *desc = d->name; - char *fe_name[] = {"", " LG TDQY-P001F", " SHARP:BS2F7HZ7395", - " SHARP:BS2F7HZ0194", " RS2000"}; + static const char * const fe_name[] = { + "", " LG TDQY-P001F", " SHARP:BS2F7HZ7395", + " SHARP:BS2F7HZ0194", " RS2000"}; char *name = adap->fe[0]->ops.info.name; strlcpy(name, desc, 128); @@ -1124,7 +1125,7 @@ static int dm04_lme2510_tuner(struct dvb_usb_adapter *adap) { struct dvb_usb_device *d = adap_to_d(adap); struct lme2510_state *st = adap_to_priv(adap); - char *tun_msg[] = {"", "TDA8263", "IX2505V", "DVB_PLL_OPERA", "RS2000"}; + static const char * const tun_msg[] = {"", "TDA8263", "IX2505V", "DVB_PLL_OPERA", "RS2000"}; int ret = 0; switch (st->tuner_config) {