From mboxrd@z Thu Jan 1 00:00:00 1970 From: =?ISO-8859-1?Q?Christian_K=F6nig?= Subject: Re: [PATCH] drm/radeon: use variable UVD clocks Date: Fri, 21 Feb 2014 18:01:00 +0100 Message-ID: <5307864C.1000201@vodafone.de> References: <1393000475-27169-1-git-send-email-alexander.deucher@amd.com> Mime-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1"; Format="flowed" Content-Transfer-Encoding: quoted-printable Return-path: Received: from pegasos-out.vodafone.de (pegasos-out.vodafone.de [80.84.1.38]) by gabe.freedesktop.org (Postfix) with SMTP id 683DDFA453 for ; Fri, 21 Feb 2014 09:01:16 -0800 (PST) Received: from localhost (localhost.localdomain [127.0.0.1]) by pegasos-out.vodafone.de (Rohrpostix1 Daemon) with ESMTP id 3A43F260052 for ; Fri, 21 Feb 2014 18:01:14 +0100 (CET) Received: from pegasos-out.vodafone.de ([127.0.0.1]) by localhost (rohrpostix1.prod.vfnet.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id ueP+KX1RSjiL for ; Fri, 21 Feb 2014 18:01:08 +0100 (CET) In-Reply-To: <1393000475-27169-1-git-send-email-alexander.deucher@amd.com> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: dri-devel-bounces@lists.freedesktop.org Errors-To: dri-devel-bounces@lists.freedesktop.org To: Alex Deucher , dri-devel@lists.freedesktop.org Cc: Alex Deucher List-Id: dri-devel@lists.freedesktop.org Am 21.02.2014 17:34, schrieb Alex Deucher: > Now that Christian fixed the performance problems with > the feedback buffer in mesa, we can enable variable UVD > clocks. There are multiple UVD power states associated > with different types and numbers of streams. This uses > the appropriate state based on that information rather > than always using the fastest UVD clocks which saves some > power. One possible downside is that this may adversely > affect decode benchmarks since these power states target > specific playback requirements rather than maximum > performance. If that becomes an issue, we can add a > sysfs attribute to force the max UVD state. > > Signed-off-by: Alex Deucher Reviewed-by: Christian K=F6nig Additional to that we should also count the number of frames per second = submitted to choose a power state, but that's not so urgent right now. Do you want to pull that in through drm-fixes or should I apply it to = the drm-next-3.15 tree? For me it sounds more like drm-next. Christian. > --- > drivers/gpu/drm/radeon/radeon_pm.c | 3 --- > drivers/gpu/drm/radeon/radeon_uvd.c | 3 +-- > 2 files changed, 1 insertion(+), 5 deletions(-) > > diff --git a/drivers/gpu/drm/radeon/radeon_pm.c b/drivers/gpu/drm/radeon/= radeon_pm.c > index 6f20bb0..2cb2fb8 100644 > --- a/drivers/gpu/drm/radeon/radeon_pm.c > +++ b/drivers/gpu/drm/radeon/radeon_pm.c > @@ -956,8 +956,6 @@ void radeon_dpm_enable_uvd(struct radeon_device *rdev= , bool enable) > if (enable) { > mutex_lock(&rdev->pm.mutex); > rdev->pm.dpm.uvd_active =3D true; > - /* disable this for now */ > -#if 0 > if ((rdev->pm.dpm.sd =3D=3D 1) && (rdev->pm.dpm.hd =3D=3D 0)) > dpm_state =3D POWER_STATE_TYPE_INTERNAL_UVD_SD; > else if ((rdev->pm.dpm.sd =3D=3D 2) && (rdev->pm.dpm.hd =3D=3D 0)) > @@ -967,7 +965,6 @@ void radeon_dpm_enable_uvd(struct radeon_device *rdev= , bool enable) > else if ((rdev->pm.dpm.sd =3D=3D 0) && (rdev->pm.dpm.hd =3D=3D 2)) > dpm_state =3D POWER_STATE_TYPE_INTERNAL_UVD_HD2; > else > -#endif > dpm_state =3D POWER_STATE_TYPE_INTERNAL_UVD; > rdev->pm.dpm.state =3D dpm_state; > mutex_unlock(&rdev->pm.mutex); > diff --git a/drivers/gpu/drm/radeon/radeon_uvd.c b/drivers/gpu/drm/radeon= /radeon_uvd.c > index 6781fee..ceb7b28 100644 > --- a/drivers/gpu/drm/radeon/radeon_uvd.c > +++ b/drivers/gpu/drm/radeon/radeon_uvd.c > @@ -805,8 +805,7 @@ void radeon_uvd_note_usage(struct radeon_device *rdev) > (rdev->pm.dpm.hd !=3D hd)) { > rdev->pm.dpm.sd =3D sd; > rdev->pm.dpm.hd =3D hd; > - /* disable this for now */ > - /*streams_changed =3D true;*/ > + streams_changed =3D true; > } > } > =