From mboxrd@z Thu Jan 1 00:00:00 1970 From: Takashi Iwai Subject: Re: [PATCH] ALSA: hda - Silence PM ops build warning Date: Thu, 29 Mar 2018 13:51:43 +0200 Message-ID: References: Mime-Version: 1.0 (generated by SEMI 1.14.6 - "Maruoka") Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: alsa-devel-bounces@alsa-project.org Sender: alsa-devel-bounces@alsa-project.org To: Lukas Wunner Cc: alsa-devel@alsa-project.org, dri-devel@lists.freedesktop.org, Arnd Bergmann List-Id: dri-devel@lists.freedesktop.org On Thu, 29 Mar 2018 13:46:26 +0200, Lukas Wunner wrote: > > The system sleep PM ops azx_suspend() and azx_resume() were previously > called by vga_switcheroo, but commit 07f4f97d7b4b ("vga_switcheroo: Use > device link for HDA controller") removed their invocation. > > Unfortunately the commit neglected to update the #ifdef surrounding the > two functions, so if CONFIG_PM_SLEEP is *not* enabled but all three of > CONFIG_PM, CONFIG_VGA_SWITCHEROO and CONFIG_SND_HDA_CODEC_HDMI *are* > enabled, the compiler now emits the following warning: > > sound/pci/hda/hda_intel.c:1024:12: warning: 'azx_resume' defined but not used [-Wunused-function] > static int azx_resume(struct device *dev) > ^~~~~~~~~~ > sound/pci/hda/hda_intel.c:989:12: warning: 'azx_suspend' defined but not used [-Wunused-function] > static int azx_suspend(struct device *dev) > ^~~~~~~~~~~ > > Silence by updating the #ifdef. Because the #ifdef block now uses the > same condition as the one immediately succeeding it, the two blocks can > be collapsed together, shaving off another two lines. > > Fixes: 07f4f97d7b4b ("vga_switcheroo: Use device link for HDA controller") > Cc: Takashi Iwai > Reported-by: Arnd Bergmann > Signed-off-by: Lukas Wunner Reviewed-by: Takashi Iwai Can this go through drm(-misc) tree as the original commit stays? thanks, Takashi