Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932146AbcCKNbf (ORCPT ); Fri, 11 Mar 2016 08:31:35 -0500 Received: from helcar.hengli.com.au ([209.40.204.226]:49069 "EHLO helcar.hengli.com.au" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932067AbcCKNb0 (ORCPT ); Fri, 11 Mar 2016 08:31:26 -0500 Date: Fri, 11 Mar 2016 21:31:04 +0800 From: Herbert Xu To: Arnd Bergmann Cc: Matt Mackall , Kukjin Kim , Krzysztof Kozlowski , linux-arm-kernel@lists.infradead.org, Dmitry Torokhov , Daniel Thompson , linux-crypto@vger.kernel.org, linux-samsung-soc@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH 07/14] hw_random: exynos: use __maybe_unused to hide pm functions Message-ID: <20160311133104.GB24332@gondor.apana.org.au> References: <1456934350-1389172-1-git-send-email-arnd@arndb.de> <1456934350-1389172-8-git-send-email-arnd@arndb.de> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1456934350-1389172-8-git-send-email-arnd@arndb.de> User-Agent: Mutt/1.5.21 (2010-09-15) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 898 Lines: 20 On Wed, Mar 02, 2016 at 04:58:59PM +0100, Arnd Bergmann wrote: > The exynos random driver uses #ifdef to check for CONFIG_PM, but > then uses SIMPLE_DEV_PM_OPS, which leaves the references out when > CONFIG_PM_SLEEP is not defined, so we get a warning with > PM=y && PM_SLEEP=n: > > drivers/char/hw_random/exynos-rng.c:166:12: error: 'exynos_rng_suspend' defined but not used [-Werror=unused-function] > drivers/char/hw_random/exynos-rng.c:171:12: error: 'exynos_rng_resume' defined but not used [-Werror=unused-function] > > This removes the incorrect #ifdef and instead uses a __maybe_unused > annotation to let the compiler know it can silently drop > the function definition. > > Signed-off-by: Arnd Bergmann Applied. -- Email: Herbert Xu Home Page: http://gondor.apana.org.au/~herbert/ PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt