Received: by 10.213.65.68 with SMTP id h4csp599296imn; Wed, 28 Mar 2018 09:14:12 -0700 (PDT) X-Google-Smtp-Source: AIpwx49U1NcXodduLRkMwlFGVAVMCz2GuYttiXbrHOXFqzmbFrUS1hB7JrH88odODRhvwta2l6B/ X-Received: by 2002:a17:902:2f03:: with SMTP id s3-v6mr4623398plb.274.1522253652396; Wed, 28 Mar 2018 09:14:12 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1522253652; cv=none; d=google.com; s=arc-20160816; b=fxppEFVDN5l40yP3EhX6EfPrFwxFOiR0y1ziGwhxger4zSAg+N+F6tYo/DOxcQJ4Me r7OL9xMV668nEL5auABNwVYlRpQAf9xaqpQ7QmB7SoRQel4ynTlfhD9B3Y7WZDw4Buf6 kKp/o+Ed9FkwEQ9YyWQIHQrl7NuE8eXFgVn3EH7KI38Y+W0FXhb8ng63LKPZaPSZlU2k kwWcMOesSRCzrQGmxp5LcXcBU9QCzaTUVr5HGcfnZfMoGOM2xwQ380eETne+OlMTsSPd ykqtgcCmat+cpGo5ffB8Fuw+sjij4jUPBnaDkIT6xVe2/WiIeQRT2Wf2cxvBhmTfL/Nv Si6g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:user-agent:references :in-reply-to:subject:cc:to:from:message-id:date :arc-authentication-results; bh=m9OFllsy1D6Af5X2XZ3gR+/Ya4JO6QYk7W6oHPlH0bE=; b=uTkj5q9lSMf0wS33fGP0uzvw/EIyUXeVHQpUWkeu7wA2KSUXjlPFa1OTV0gxJ2f2gF /X50LX5Q3uCF/nlT1Ieu12jqlTTlTqzOQZE13edvamPnAMNDKNlojqVgChDxGsbSS7kl NhLKiYGQeg4DvP0/v4V+Qg70oRfPQkmaGcwVm3hW8TGt9ctcZHxL/Dq9RGwKAOfh6t7M YqpnWIHyBO2j+Zo6Hdo3F6tgae9L9Nu1KflgvCtMlsvwITcVKOVnYhVERWu5/jxZfAMI H29U1FKBno/0l0uvke2hCgmHtey7yUfG03T5gDfKmZxrlp2QBdLe3wVuwGtZ+1y6iFcY VhzQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id f6si698039pgo.366.2018.03.28.09.13.27; Wed, 28 Mar 2018 09:14:12 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753002AbeC1QDs (ORCPT + 99 others); Wed, 28 Mar 2018 12:03:48 -0400 Received: from mx2.suse.de ([195.135.220.15]:57968 "EHLO mx2.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752479AbeC1QDr (ORCPT ); Wed, 28 Mar 2018 12:03:47 -0400 X-Virus-Scanned: by amavisd-new at test-mx.suse.de Received: from relay1.suse.de (charybdis-ext.suse.de [195.135.220.254]) by mx2.suse.de (Postfix) with ESMTP id 18EC8AF79; Wed, 28 Mar 2018 16:03:46 +0000 (UTC) Date: Wed, 28 Mar 2018 18:03:45 +0200 Message-ID: From: Takashi Iwai To: "Lukas Wunner" Cc: "Arnd Bergmann" , , "Vijendar Mukunda" , "Guneshwor Singh" , "Libin Yang" , "Jaroslav Kysela" , "Hans de Goede" , Subject: Re: [PATCH] ALSA: hda_intel: mark PM functions as __maybe_unused In-Reply-To: <20180328143150.GA17992@wunner.de> References: <20180328142020.3275989-1-arnd@arndb.de> <20180328143150.GA17992@wunner.de> User-Agent: Wanderlust/2.15.9 (Almost Unreal) SEMI/1.14.6 (Maruoka) FLIM/1.14.9 (=?UTF-8?B?R29qxY0=?=) APEL/10.8 Emacs/25.3 (x86_64-suse-linux-gnu) MULE/6.0 (HANACHIRUSATO) MIME-Version: 1.0 (generated by SEMI 1.14.6 - "Maruoka") Content-Type: text/plain; charset=US-ASCII Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, 28 Mar 2018 16:31:50 +0200, Lukas Wunner wrote: > > On Wed, Mar 28, 2018 at 04:19:29PM +0200, Arnd Bergmann wrote: > > Two callsites of azx_suspend/azx_resume were removed, leaving these > > functions only called from the optional SET_SYSTEM_SLEEP_PM_OPS() > > and causing a warning without CONFIG_PM_SLEEP: > > > > sound/pci/hda/hda_intel.c:1029:12: error: 'azx_resume' defined but not used [-Werror=unused-function] > > static int azx_resume(struct device *dev) > > ^~~~~~~~~~ > > sound/pci/hda/hda_intel.c:994:12: error: 'azx_suspend' defined but not used [-Werror=unused-function] > > static int azx_suspend(struct device *dev) > > ^~~~~~~~~~~ > > > > Keeping track of the correct #ifdef checks is hard, so this removes > > all the #ifdefs for power management in this file and instead uses > > __maybe_unused annotations that let the compiler do the job right > > by itself. > > Ugh, this isn't as hard as it may seem, just replace > > #if defined(CONFIG_PM_SLEEP) || defined(SUPPORT_VGA_SWITCHEROO) > > with > > #if defined(CONFIG_PM_SLEEP) > > That way it's just a simple one line change which is less intrusive. > > Care to respin like this? > > Thanks for the report, > > Lukas Also, note that the mentioned vga_switcheroo change is carried via drm-misc tree, so the fix should go to there, too. thanks, Takashi