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: 1414391 Return-Path: X-Original-To: patchwork-linux-omap@patchwork.kernel.org Delivered-To: patchwork-process-083081@patchwork2.kernel.org Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by patchwork2.kernel.org (Postfix) with ESMTP id CE54BDFFCF for ; Thu, 6 Sep 2012 12:53:31 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755578Ab2IFMuu (ORCPT ); Thu, 6 Sep 2012 08:50:50 -0400 Received: from na3sys009aog125.obsmtp.com ([74.125.149.153]:38597 "EHLO na3sys009aog125.obsmtp.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755547Ab2IFMus (ORCPT ); Thu, 6 Sep 2012 08:50:48 -0400 Received: from mail-lb0-f174.google.com ([209.85.217.174]) (using TLSv1) by na3sys009aob125.postini.com ([74.125.148.12]) with SMTP ID DSNKUEicJ71BMU3Kdwwp4kNCQ2huSifpCy0a@postini.com; Thu, 06 Sep 2012 05:50:48 PDT Received: by lbbgj3 with SMTP id gj3so1101379lbb.19 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=WcqC2/aR1Q5NYIhWWwymYSOVFVOL/+VX1QTqo4ZElDcAy++zEyk88QnnHUjryU8HI5 qBVQBYZIMTy7Qu7wFeZaE4KT3CevpxYmWZhMXk9FGmtyIGswqocjrwXMol+UAqqy6Jd7 fHUtWel5rWhKLxcgtijB9Oc5LvrPVCKwZu707ULjyiQ5ryUGgbkM2HMJk3Ga7mwL1z1B S/3N+y4agdTLHJfuz69ZRuHE2xYCN56SOvvc0Rc5JTEInk7uEvsquoC+H/cIhL7Cqv5j rqbdcTbfWZbnXY38j03sSh+vcShqwv8d9b4TwH2jjgG+cUP8/UeIhq13e9Wa9R7UNcaJ zgdQ== 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 Cc: alan@linux.intel.com, Tony Lindgren , Kevin Hilman , Linux OMAP Mailing List , Linux ARM Kernel Mailing List , linux-serial@vger.kernel.org, Linux Kernel Mailing List , Santosh Shilimkar , Shubhrajyoti Datta , Sourav Poddar , Felipe Balbi , Ruchika Kharwar 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: ALoCoQntOOY4eUIa8Fr0jvUj/Eqcq6fffETM5MDHUlustl30f3Vvn/oveCiotRjvKHORgjyCsNUS Sender: linux-omap-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-omap@vger.kernel.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,