From patchwork Wed Jul 13 14:54:56 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jonathan Cameron X-Patchwork-Id: 972472 Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) by demeter1.kernel.org (8.14.4/8.14.4) with ESMTP id p6DEvPXN011644 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO) for ; Wed, 13 Jul 2011 14:57:46 GMT Received: from canuck.infradead.org ([2001:4978:20e::1]) by merlin.infradead.org with esmtps (Exim 4.76 #1 (Red Hat Linux)) id 1Qh0rk-0003Yc-AW; Wed, 13 Jul 2011 14:56:44 +0000 Received: from localhost ([127.0.0.1] helo=canuck.infradead.org) by canuck.infradead.org with esmtp (Exim 4.76 #1 (Red Hat Linux)) id 1Qh0rK-0004Pr-9H; Wed, 13 Jul 2011 14:56:18 +0000 Received: from ppsw-52.csi.cam.ac.uk ([131.111.8.152]) by canuck.infradead.org with esmtp (Exim 4.76 #1 (Red Hat Linux)) id 1Qh0qB-00049Q-B9; Wed, 13 Jul 2011 14:55:14 +0000 X-Cam-AntiVirus: no malware found X-Cam-SpamDetails: not scanned X-Cam-ScannerInfo: http://www.cam.ac.uk/cs/email/scanner/ Received: from arcturus.eng.cam.ac.uk ([129.169.154.73]:53499 helo=localhost.eng.cam.ac.uk) by ppsw-52.csi.cam.ac.uk (smtp.hermes.cam.ac.uk [131.111.8.159]:465) with esmtpsa (LOGIN:jic23) (TLSv1:DHE-RSA-AES256-SHA:256) id 1Qh0q4-0003wM-Dk (Exim 4.72) (return-path ); Wed, 13 Jul 2011 15:55:00 +0100 From: Jonathan Cameron To: greg@kroah.com, linux-pcmcia@lists.infradead.org Subject: [PATCH 1/3] drivers:pcmcia:soc_common: make socket_init and socket_suspend optional Date: Wed, 13 Jul 2011 15:54:56 +0100 Message-Id: <1310568898-9201-2-git-send-email-jic23@cam.ac.uk> X-Mailer: git-send-email 1.7.3.4 In-Reply-To: <1310568898-9201-1-git-send-email-jic23@cam.ac.uk> References: <1310568898-9201-1-git-send-email-jic23@cam.ac.uk> X-CRM114-Version: 20090807-BlameThorstenAndJenny ( TRE 0.7.6 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20110713_105507_568735_FEB188E5 X-CRM114-Status: GOOD ( 12.52 ) X-Spam-Score: -2.3 (--) X-Spam-Report: SpamAssassin version 3.3.1 on canuck.infradead.org summary: Content analysis details: (-2.3 points) pts rule name description ---- ---------------------- -------------------------------------------------- -2.3 RCVD_IN_DNSWL_MED RBL: Sender listed at http://www.dnswl.org/, medium trust [131.111.8.152 listed in list.dnswl.org] -0.0 T_RP_MATCHES_RCVD Envelope sender domain matches handover relay domain Cc: eric.y.miao@gmail.com, Jonathan Cameron , linux-arm-kernel@lists.infradead.org X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.12 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 X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.6 (demeter1.kernel.org [140.211.167.41]); Wed, 13 Jul 2011 14:57:46 +0000 (UTC) 10 boards define these empty, probably indicating not everyone has a use for them. Signed-off-by: Jonathan Cameron --- drivers/pcmcia/soc_common.c | 7 ++++--- 1 files changed, 4 insertions(+), 3 deletions(-) diff --git a/drivers/pcmcia/soc_common.c b/drivers/pcmcia/soc_common.c index 768f957..a0a9c2a 100644 --- a/drivers/pcmcia/soc_common.c +++ b/drivers/pcmcia/soc_common.c @@ -186,8 +186,8 @@ static int soc_common_pcmcia_sock_init(struct pcmcia_socket *sock) struct soc_pcmcia_socket *skt = to_soc_pcmcia_socket(sock); debug(skt, 2, "initializing socket\n"); - - skt->ops->socket_init(skt); + if (skt->ops->socket_init) + skt->ops->socket_init(skt); return 0; } @@ -207,7 +207,8 @@ static int soc_common_pcmcia_suspend(struct pcmcia_socket *sock) debug(skt, 2, "suspending socket\n"); - skt->ops->socket_suspend(skt); + if (skt->ops->socket_suspend) + skt->ops->socket_suspend(skt); return 0; }