From patchwork Wed Jun 25 01:54:36 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Zhao Qiang X-Patchwork-Id: 4415981 Return-Path: X-Original-To: patchwork-linux-spi@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork1.web.kernel.org (Postfix) with ESMTP id C9E1C9F1D6 for ; Wed, 25 Jun 2014 02:12:57 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 05F56201D5 for ; Wed, 25 Jun 2014 02:12:57 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 0B844201D3 for ; Wed, 25 Jun 2014 02:12:56 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752564AbaFYCMz (ORCPT ); Tue, 24 Jun 2014 22:12:55 -0400 Received: from mail-bn1blp0183.outbound.protection.outlook.com ([207.46.163.183]:3789 "EHLO na01-bn1-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1752271AbaFYCMz (ORCPT ); Tue, 24 Jun 2014 22:12:55 -0400 Received: from DM2PR03CA004.namprd03.prod.outlook.com (10.141.52.152) by DM2PR03MB352.namprd03.prod.outlook.com (10.141.54.24) with Microsoft SMTP Server (TLS) id 15.0.954.9; Wed, 25 Jun 2014 01:57:56 +0000 Received: from BN1AFFO11FD047.protection.gbl (2a01:111:f400:7c10::143) by DM2PR03CA004.outlook.office365.com (2a01:111:e400:2414::24) with Microsoft SMTP Server (TLS) id 15.0.959.24 via Frontend Transport; Wed, 25 Jun 2014 01:57:56 +0000 Received: from az84smr01.freescale.net (192.88.158.2) by BN1AFFO11FD047.mail.protection.outlook.com (10.58.53.62) with Microsoft SMTP Server (TLS) id 15.0.969.12 via Frontend Transport; Wed, 25 Jun 2014 01:57:55 +0000 Received: from titan.ap.freescale.net ([10.192.208.233]) by az84smr01.freescale.net (8.14.3/8.14.0) with ESMTP id s5P1vpPP010093; Tue, 24 Jun 2014 18:57:52 -0700 From: Zhao Qiang To: , , , CC: Zhao Qiang Subject: [PATCH] spi: include "int ret" with macro Date: Wed, 25 Jun 2014 09:54:36 +0800 Message-ID: <1403661276-16598-1-git-send-email-B45475@freescale.com> X-Mailer: git-send-email 1.8.5 X-EOPAttributedMessage: 0 X-Forefront-Antispam-Report: CIP:192.88.158.2; CTRY:US; IPV:CAL; IPV:NLI; EFV:NLI; SFV:NSPM; SFS:(6009001)(199002)(189002)(92726001)(2201001)(92566001)(50226001)(4396001)(95666004)(93916002)(74502001)(31966008)(46102001)(74662001)(79102001)(76482001)(104016002)(77982001)(83072002)(89996001)(85852003)(105606002)(107046001)(81542001)(87286001)(87936001)(97736001)(88136002)(99396002)(106466001)(81156004)(50986999)(62966002)(102836001)(26826002)(6806004)(44976005)(69596002)(19580405001)(83322001)(19580395003)(47776003)(20776003)(80022001)(81342001)(50466002)(36756003)(21056001)(64706001)(104166001)(77156001)(68736004)(85306003)(48376002)(84676001)(42262001); DIR:OUT; SFP:; SCL:1; SRVR:DM2PR03MB352; H:az84smr01.freescale.net; FPR:; MLV:ovrnspm; PTR:InfoDomainNonexistent; MX:1; LANG:en; MIME-Version: 1.0 X-Microsoft-Antispam: BL:0; ACTION:Default; RISK:Low; SCL:0; SPMLVL:NotSpam; PCL:0; RULEID: X-Forefront-PRVS: 02530BD3AA Received-SPF: Fail (: domain of freescale.com does not designate 192.88.158.2 as permitted sender) receiver=; client-ip=192.88.158.2; helo=az84smr01.freescale.net; Authentication-Results: spf=fail (sender IP is 192.88.158.2) smtp.mailfrom=qiang.zhao@freescale.com; X-OriginatorOrg: freescale.com Sender: linux-spi-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-spi@vger.kernel.org X-Spam-Status: No, score=-6.9 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, T_RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP ret is unused when CONFIG_FSL_SOC defined, so include it with "#ifndef CONFIG_FSL_SOC". Signed-off-by: Zhao Qiang --- drivers/spi/spi-fsl-lib.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/spi/spi-fsl-lib.c b/drivers/spi/spi-fsl-lib.c index e5d45fc..44aace1 100644 --- a/drivers/spi/spi-fsl-lib.c +++ b/drivers/spi/spi-fsl-lib.c @@ -198,8 +198,9 @@ int of_mpc8xxx_spi_probe(struct platform_device *ofdev) struct mpc8xxx_spi_probe_info *pinfo; struct fsl_spi_platform_data *pdata; const void *prop; +#ifndef CONFIG_FSL_SOC int ret = -ENOMEM; - +#endif pinfo = devm_kzalloc(&ofdev->dev, sizeof(*pinfo), GFP_KERNEL); if (!pinfo) return -ENOMEM;