From: Daniel Vetter Subject: Re: [PATCH] drm/i915: fix suspend/resume for GENs w/o runtime PM support Date: Tue, 26 Aug 2014 09:45:38 +0200 Message-ID: <20140826074538.GB15520@phenom.ffwll.local> References: <1408357206-19511-1-git-send-email-imre.deak@intel.com> <20140826074442.GA15520@phenom.ffwll.local> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Received: from mail-we0-f179.google.com (mail-we0-f179.google.com [74.125.82.179]) by gabe.freedesktop.org (Postfix) with ESMTP id 87D176E2DA for ; Tue, 26 Aug 2014 00:45:16 -0700 (PDT) Received: by mail-we0-f179.google.com with SMTP id u57so14246945wes.38 for ; Tue, 26 Aug 2014 00:45:15 -0700 (PDT) Content-Disposition: inline In-Reply-To: <20140826074442.GA15520@phenom.ffwll.local> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: intel-gfx-bounces@lists.freedesktop.org Sender: "Intel-gfx" To: Imre Deak Cc: intel-gfx@lists.freedesktop.org, Sagar Kamble List-Id: intel-gfx@lists.freedesktop.org On Tue, Aug 26, 2014 at 09:44:42AM +0200, Daniel Vetter wrote: > On Mon, Aug 18, 2014 at 01:20:06PM +0300, Imre Deak wrote: > > Before sharing common parts between the system and runtime s/r > > handlers we WARNed if the runtime s/r handlers were called on GENs that > > didn't support RPM. But this WARN is not correct if the same handler is > > called from the system s/r path, since that can happen on any platform. > > This also broke system s/r on old platforms. > > > > The issue was introduced in > > > > commit 016970beb05da6285c2f3ed2bee1c676cb75972e > > Author: Sagar Kamble > > Date: Wed Aug 13 23:07:06 2014 +0530 > > > > Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=82751 > > Signed-off-by: Imre Deak > > Adding boolean arguments to control warnings always feels a bit too much > like just shutting up the warnings. Can't we instead wrap the relevant > calls into HAS_RUNTIME_PM checks? Imo that would also lead to clearer code > by making the intention clear - with this you essentially have to git > blame to figure out why we sometimes disable the warning. Also the patch subject is a bit misleading - we only shut up a wrong warning, it's not a code fix. -Daniel -- Daniel Vetter Software Engineer, Intel Corporation +41 (0) 79 365 57 48 - http://blog.ffwll.ch