From: Lyude Paul <lyude@redhat.com>
To: Thierry Reding <thierry.reding@gmail.com>,
Ben Skeggs <bskeggs@redhat.com>
Cc: nouveau@lists.freedesktop.org, dri-devel@lists.freedesktop.org
Subject: Re: [PATCH] drm/nouveau: Make clock gate support conditional
Date: Wed, 07 Feb 2018 13:00:26 -0500 [thread overview]
Message-ID: <1518026426.3874.0.camel@redhat.com> (raw)
In-Reply-To: <20180207174027.24468-1-thierry.reding@gmail.com>
Reviewed-by: Lyude Paul <lyude@redhat.com>
On Wed, 2018-02-07 at 18:40 +0100, Thierry Reding wrote:
> From: Thierry Reding <treding@nvidia.com>
>
> The recently introduced clock gate support breaks on Tegra chips because
> no thermal support is enabled for those devices. Conditionalize the code
> on the existence of thermal support to fix this.
>
> Fixes: b138eca661cc ("drm/nouveau: Add support for basic clockgating on
> Kepler1")
> Cc: Martin Peres <martin.peres@free.fr>
> Cc: Lyude Paul <lyude@redhat.com>
> Signed-off-by: Thierry Reding <treding@nvidia.com>
> ---
> drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c | 6 +++---
> 1 file changed, 3 insertions(+), 3 deletions(-)
>
> diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c
> b/drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c
> index bf62303571b3..3695cde669f8 100644
> --- a/drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c
> +++ b/drivers/gpu/drm/nouveau/nvkm/subdev/therm/base.c
> @@ -301,7 +301,7 @@ nvkm_therm_attr_set(struct nvkm_therm *therm,
> void
> nvkm_therm_clkgate_enable(struct nvkm_therm *therm)
> {
> - if (!therm->func->clkgate_enable || !therm->clkgating_enabled)
> + if (!therm || !therm->func->clkgate_enable || !therm-
> >clkgating_enabled)
> return;
>
> nvkm_debug(&therm->subdev,
> @@ -312,7 +312,7 @@ nvkm_therm_clkgate_enable(struct nvkm_therm *therm)
> void
> nvkm_therm_clkgate_fini(struct nvkm_therm *therm, bool suspend)
> {
> - if (!therm->func->clkgate_fini || !therm->clkgating_enabled)
> + if (!therm || !therm->func->clkgate_fini || !therm-
> >clkgating_enabled)
> return;
>
> nvkm_debug(&therm->subdev,
> @@ -395,7 +395,7 @@ void
> nvkm_therm_clkgate_init(struct nvkm_therm *therm,
> const struct nvkm_therm_clkgate_pack *p)
> {
> - if (!therm->func->clkgate_init || !therm->clkgating_enabled)
> + if (!therm || !therm->func->clkgate_init || !therm-
> >clkgating_enabled)
> return;
>
> therm->func->clkgate_init(therm, p);
--
Cheers,
Lyude Paul
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel
prev parent reply other threads:[~2018-02-07 18:00 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-02-07 17:40 [PATCH] drm/nouveau: Make clock gate support conditional Thierry Reding
2018-02-07 18:00 ` Lyude Paul [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1518026426.3874.0.camel@redhat.com \
--to=lyude@redhat.com \
--cc=bskeggs@redhat.com \
--cc=dri-devel@lists.freedesktop.org \
--cc=nouveau@lists.freedesktop.org \
--cc=thierry.reding@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox