From patchwork Thu Sep 6 12:45:32 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Felipe Balbi X-Patchwork-Id: 1414761 Return-Path: X-Original-To: patchwork-linux-arm@patchwork.kernel.org Delivered-To: patchwork-process-083081@patchwork2.kernel.org Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) by patchwork2.kernel.org (Postfix) with ESMTP id 7A4C8DFFCF for ; Thu, 6 Sep 2012 13:02:26 +0000 (UTC) Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.76 #1 (Red Hat Linux)) id 1T9be8-0007mD-4U; Thu, 06 Sep 2012 12:57:27 +0000 Received: from na3sys009aog129.obsmtp.com ([74.125.149.142]) by merlin.infradead.org with smtps (Exim 4.76 #1 (Red Hat Linux)) id 1T9bXk-0002pd-QO for linux-arm-kernel@lists.infradead.org; Thu, 06 Sep 2012 12:50:50 +0000 Received: from mail-lb0-f177.google.com ([209.85.217.177]) (using TLSv1) by na3sys009aob129.postini.com ([74.125.148.12]) with SMTP ID DSNKUEicJ71BMU3Kdwwp4kNCQ2huSifpCy0a@postini.com; Thu, 06 Sep 2012 05:50:48 PDT Received: by lbbgf7 with SMTP id gf7so1091878lbb.36 for ; Thu, 06 Sep 2012 05:50:46 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=from:to:cc:subject:date:message-id:x-mailer:in-reply-to:references :x-gm-message-state; bh=K91AFmsiPl2w1k4q0D4jGsqYYlo+jjYhiH6f9LjLmxE=; b=MkR4/v2FWlTfdKIB7NohjXMKEWhQDrBij0jzOy5NZwBPUS36+m1ClgRAJsye105VyI gSXMOyMPTv7A/RFCQM5Z6EGTdXERBOXcD19C3yh6fC2vKLI/F6ZVz3mW1LAS/fwGrBns M7wteeZcrXsqYA5WtMLrH6YriHIxhMfDImUMLFfU7+8NAOTZFiricLg5q4Rz7akUaMnY jzsNUcMinMRWu3DmZzRFhY67nQzeQ9UatAdHThOQUZzEh9mD6TP78lQtGlTWn2bMn6WY pD2cX34thKH9mtE5w3ELuUXtDcU3l9LmxOnDHAlzumFON7oTpl7PFGHiSSFrIGl0QD0i 5oew== Received: by 10.152.104.77 with SMTP id gc13mr1845373lab.31.1346935846020; Thu, 06 Sep 2012 05:50:46 -0700 (PDT) Received: from localhost (cs78217178.pp.htv.fi. [62.78.217.178]) by mx.google.com with ESMTPS id o7sm566665lbg.4.2012.09.06.05.50.44 (version=TLSv1/SSLv3 cipher=OTHER); Thu, 06 Sep 2012 05:50:45 -0700 (PDT) From: Felipe Balbi To: Greg KH Subject: [PATCH v4 13/21] serial: omap: optimization with section annotations Date: Thu, 6 Sep 2012 15:45:32 +0300 Message-Id: <1346935540-1792-14-git-send-email-balbi@ti.com> X-Mailer: git-send-email 1.7.12.rc3 In-Reply-To: <1346935540-1792-1-git-send-email-balbi@ti.com> References: <20120906122948.GC29202@arwen.pp.htv.fi> <1346935540-1792-1-git-send-email-balbi@ti.com> X-Gm-Message-State: ALoCoQnFHU0LGOWdgk/ujgnD0risCvpWIlJa14KR9KVOgCwvZ5mNCLcxsqTAHtq4+/8rgkMiT91U X-Spam-Note: CRM114 invocation failed X-Spam-Score: -4.2 (----) X-Spam-Report: SpamAssassin version 3.3.2 on merlin.infradead.org summary: Content analysis details: (-4.2 points) pts rule name description ---- ---------------------- -------------------------------------------------- -2.3 RCVD_IN_DNSWL_MED RBL: Sender listed at http://www.dnswl.org/, medium trust [74.125.149.142 listed in list.dnswl.org] -0.0 SPF_PASS SPF: sender matches SPF record -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] Cc: Kevin Hilman , Tony Lindgren , Linux Kernel Mailing List , Felipe Balbi , Santosh Shilimkar , linux-serial@vger.kernel.org, Ruchika Kharwar , Sourav Poddar , Linux OMAP Mailing List , Shubhrajyoti Datta , Linux ARM Kernel Mailing List , alan@linux.intel.com X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: linux-arm-kernel-bounces@lists.infradead.org Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org Two functions: omap_serial_fill_features_erratas() and of_get_uart_port_info() are only called from probe(). Marking them as __devinit gives us another oportunity to free some code after .init.text is done. Tested-by: Shubhrajyoti D Signed-off-by: Ruchika Kharwar Signed-off-by: Felipe Balbi --- drivers/tty/serial/omap-serial.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/drivers/tty/serial/omap-serial.c b/drivers/tty/serial/omap-serial.c index f5dcb5a..9068260 100644 --- a/drivers/tty/serial/omap-serial.c +++ b/drivers/tty/serial/omap-serial.c @@ -1168,7 +1168,7 @@ static int serial_omap_resume(struct device *dev) } #endif -static void omap_serial_fill_features_erratas(struct uart_omap_port *up) +static void __devinit omap_serial_fill_features_erratas(struct uart_omap_port *up) { u32 mvr, scheme; u16 revision, major, minor; @@ -1221,7 +1221,7 @@ static void omap_serial_fill_features_erratas(struct uart_omap_port *up) } } -static struct omap_uart_port_info *of_get_uart_port_info(struct device *dev) +static __devinit struct omap_uart_port_info *of_get_uart_port_info(struct device *dev) { struct omap_uart_port_info *omap_up_info; @@ -1234,7 +1234,7 @@ static struct omap_uart_port_info *of_get_uart_port_info(struct device *dev) return omap_up_info; } -static int serial_omap_probe(struct platform_device *pdev) +static int __devinit serial_omap_probe(struct platform_device *pdev) { struct uart_omap_port *up; struct resource *mem, *irq; @@ -1364,7 +1364,7 @@ err_port_line: return ret; } -static int serial_omap_remove(struct platform_device *dev) +static int __devexit serial_omap_remove(struct platform_device *dev) { struct uart_omap_port *up = platform_get_drvdata(dev); @@ -1508,7 +1508,7 @@ MODULE_DEVICE_TABLE(of, omap_serial_of_match); static struct platform_driver serial_omap_driver = { .probe = serial_omap_probe, - .remove = serial_omap_remove, + .remove = __devexit_p(serial_omap_remove), .driver = { .name = DRIVER_NAME, .pm = &serial_omap_dev_pm_ops,