From patchwork Sun May 5 20:29:46 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Borislav Petkov X-Patchwork-Id: 2521311 Return-Path: X-Original-To: patchwork-linux-arm@patchwork.kernel.org Delivered-To: patchwork-process-083081@patchwork2.kernel.org Received: from casper.infradead.org (casper.infradead.org [85.118.1.10]) by patchwork2.kernel.org (Postfix) with ESMTP id C3C9DDF2A2 for ; Sun, 5 May 2013 20:27:38 +0000 (UTC) Received: from merlin.infradead.org ([2001:4978:20e::2]) by casper.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1UZ5Wq-00039b-5h; Sun, 05 May 2013 20:27:28 +0000 Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1UZ5We-000369-Da; Sun, 05 May 2013 20:27:16 +0000 Received: from mail.skyhub.de ([2a01:4f8:120:8448::d00d]) by merlin.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1UZ5Wb-00035A-Ls for linux-arm-kernel@lists.infradead.org; Sun, 05 May 2013 20:27:15 +0000 X-Virus-Scanned: Nedap ESD1 at mail.skyhub.de DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=alien8.de; s=alien8; t=1367785609; bh=JSTumwr1RBu9uyT6bT4kCyy9UBZjw5KpL5WtYrfn8Ko=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:In-Reply-To; b=Y15trqSrYnlsDZOE3mug2Cuu8f1aFEkn216Md3 CLkYwBBpf4bZjDjv01DDIpO6ftCn9nZEGyevGD9QJjdLE1ufj3DbKKoGrnE7IpPZnbG EK0wdo70tn84rpVDb7QVMLU9PW9fTPP6nRwS9Ma/TV0z1Ld/wApALB7TpJFmXvFEWE= Received: from mail.skyhub.de ([127.0.0.1]) by localhost (door.skyhub.de [127.0.0.1]) (amavisd-new, port 10026) with ESMTP id OHyKBa1hkhAO; Sun, 5 May 2013 22:26:49 +0200 (CEST) Received: from liondog.tnic (p54B46F5C.dip0.t-ipconnect.de [84.180.111.92]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mail.skyhub.de (SuperMail on ZX Spectrum 128k) with ESMTPSA id 1153B1D9DF7; Sun, 5 May 2013 22:26:48 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=alien8.de; s=alien8; t=1367785609; bh=JSTumwr1RBu9uyT6bT4kCyy9UBZjw5KpL5WtYrfn8Ko=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:In-Reply-To; b=Y15trqSrYnlsDZOE3mug2Cuu8f1aFEkn216Md3 CLkYwBBpf4bZjDjv01DDIpO6ftCn9nZEGyevGD9QJjdLE1ufj3DbKKoGrnE7IpPZnbG EK0wdo70tn84rpVDb7QVMLU9PW9fTPP6nRwS9Ma/TV0z1Ld/wApALB7TpJFmXvFEWE= Received: by liondog.tnic (Postfix, from userid 1000) id C5FBE1000A2; Sun, 5 May 2013 22:29:46 +0200 (CEST) Date: Sun, 5 May 2013 22:29:46 +0200 From: Borislav Petkov To: Arnd Bergmann Subject: Re: [PATCH, RFC 11/22] iwlegacy: il_pm_ops is only provided for PM_SLEEP Message-ID: <20130505202946.GB12757@pd.tnic> References: <1367507786-505303-1-git-send-email-arnd@arndb.de> <1367507786-505303-12-git-send-email-arnd@arndb.de> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <1367507786-505303-12-git-send-email-arnd@arndb.de> User-Agent: Mutt/1.5.21 (2010-09-15) X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20130505_162714_236120_CCB6DFA1 X-CRM114-Status: GOOD ( 16.78 ) X-Spam-Score: -2.0 (--) X-Spam-Report: SpamAssassin version 3.3.2 on merlin.infradead.org summary: Content analysis details: (-2.0 points) pts rule name description ---- ---------------------- -------------------------------------------------- -0.0 SPF_PASS SPF: sender matches SPF record -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] -0.1 DKIM_VALID_AU Message has a valid DKIM or DK signature from author's domain 0.1 DKIM_SIGNED Message has a DKIM or DK signature, not necessarily valid -0.1 DKIM_VALID Message has at least one valid DKIM or DK signature Cc: Johannes Berg , linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, "John W. Linville" X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org On Thu, May 02, 2013 at 05:16:15PM +0200, Arnd Bergmann wrote: > This makes sure the conditionals for the declaration match the > definition, so we provide the alternative > > #else > #define IL_LEGACY_PM_OPS NULL > #endif > > in the correct cases. > > drivers/built-in.o:(.data+0x57974): undefined reference to `il_pm_ops' Yep, I see this too here. > > Cc: Johannes Berg > Cc: John W. Linville > Signed-off-by: Arnd Bergmann > --- > drivers/net/wireless/iwlegacy/common.h | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/drivers/net/wireless/iwlegacy/common.h b/drivers/net/wireless/iwlegacy/common.h > index f8246f2..734f1b4 100644 > --- a/drivers/net/wireless/iwlegacy/common.h > +++ b/drivers/net/wireless/iwlegacy/common.h > @@ -1832,7 +1832,7 @@ u32 il_usecs_to_beacons(struct il_priv *il, u32 usec, u32 beacon_interval); > __le32 il_add_beacon_time(struct il_priv *il, u32 base, u32 addon, > u32 beacon_interval); > > -#ifdef CONFIG_PM > +#ifdef CONFIG_PM_SLEEP > extern const struct dev_pm_ops il_pm_ops; > > #define IL_LEGACY_PM_OPS (&il_pm_ops) Btw, you might want to adjust the macro comments for consistency too, like so. Alternatively, you could simply remove them since they only clutter two-liner and one can see what it encloses. --- -- diff --git a/drivers/net/wireless/iwlegacy/common.h b/drivers/net/wireless/iwlegacy/common.h index f8246f2d88f9..4caaf52986a4 100644 --- a/drivers/net/wireless/iwlegacy/common.h +++ b/drivers/net/wireless/iwlegacy/common.h @@ -1832,16 +1832,16 @@ u32 il_usecs_to_beacons(struct il_priv *il, u32 usec, u32 beacon_interval); __le32 il_add_beacon_time(struct il_priv *il, u32 base, u32 addon, u32 beacon_interval); -#ifdef CONFIG_PM +#ifdef CONFIG_PM_SLEEP extern const struct dev_pm_ops il_pm_ops; #define IL_LEGACY_PM_OPS (&il_pm_ops) -#else /* !CONFIG_PM */ +#else /* !CONFIG_PM_SLEEP */ #define IL_LEGACY_PM_OPS NULL -#endif /* !CONFIG_PM */ +#endif /* !CONFIG_PM_SLEEP */ /***************************************************** * Error Handling Debugging