* [PATCH] drm/amdgpu: return 0 by default in amdgpu_pm_load_smu_firmware
@ 2019-06-11 14:51 Alex Deucher
[not found] ` <20190611145103.621-1-alexander.deucher-5C7GfCeVMHo@public.gmane.org>
0 siblings, 1 reply; 4+ messages in thread
From: Alex Deucher @ 2019-06-11 14:51 UTC (permalink / raw)
To: amd-gfx-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW; +Cc: Alex Deucher
Fixes SI cards running on amdgpu.
Fixes: 1929059893022 ("drm/amd/amdgpu: add RLC firmware to support raven1 refresh")
Bug: https://bugs.freedesktop.org/show_bug.cgi?id=110883
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
---
drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c
index d8828a37e43a..653b2491fec8 100644
--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c
+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c
@@ -2700,7 +2700,7 @@ void amdgpu_pm_print_power_states(struct amdgpu_device *adev)
int amdgpu_pm_load_smu_firmware(struct amdgpu_device *adev, uint32_t *smu_version)
{
- int r = -EINVAL;
+ int r;
if (amdgpu_sriov_vf(adev))
return 0;
@@ -2713,7 +2713,7 @@ int amdgpu_pm_load_smu_firmware(struct amdgpu_device *adev, uint32_t *smu_versio
}
*smu_version = adev->pm.fw_version;
}
- return r;
+ return 0;
}
int amdgpu_pm_sysfs_init(struct amdgpu_device *adev)
--
2.20.1
_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx
^ permalink raw reply related [flat|nested] 4+ messages in thread[parent not found: <20190611145103.621-1-alexander.deucher-5C7GfCeVMHo@public.gmane.org>]
* RE: [PATCH] drm/amdgpu: return 0 by default in amdgpu_pm_load_smu_firmware [not found] ` <20190611145103.621-1-alexander.deucher-5C7GfCeVMHo@public.gmane.org> @ 2019-06-12 1:15 ` Quan, Evan 2019-06-13 10:32 ` Paul Menzel 1 sibling, 0 replies; 4+ messages in thread From: Quan, Evan @ 2019-06-12 1:15 UTC (permalink / raw) To: Alex Deucher, amd-gfx-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org Cc: Deucher, Alexander Reviewed-by: Evan Quan <evan.quan@amd.com> > -----Original Message----- > From: amd-gfx <amd-gfx-bounces@lists.freedesktop.org> On Behalf Of Alex > Deucher > Sent: Tuesday, June 11, 2019 10:51 PM > To: amd-gfx@lists.freedesktop.org > Cc: Deucher, Alexander <Alexander.Deucher@amd.com> > Subject: [PATCH] drm/amdgpu: return 0 by default in > amdgpu_pm_load_smu_firmware > > Fixes SI cards running on amdgpu. > > Fixes: 1929059893022 ("drm/amd/amdgpu: add RLC firmware to support > raven1 refresh") > Bug: https://bugs.freedesktop.org/show_bug.cgi?id=110883 > Signed-off-by: Alex Deucher <alexander.deucher@amd.com> > --- > drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > > diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c > b/drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c > index d8828a37e43a..653b2491fec8 100644 > --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c > +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c > @@ -2700,7 +2700,7 @@ void amdgpu_pm_print_power_states(struct > amdgpu_device *adev) > > int amdgpu_pm_load_smu_firmware(struct amdgpu_device *adev, > uint32_t *smu_version) { > - int r = -EINVAL; > + int r; > > if (amdgpu_sriov_vf(adev)) > return 0; > @@ -2713,7 +2713,7 @@ int amdgpu_pm_load_smu_firmware(struct > amdgpu_device *adev, uint32_t *smu_versio > } > *smu_version = adev->pm.fw_version; > } > - return r; > + return 0; > } > > int amdgpu_pm_sysfs_init(struct amdgpu_device *adev) > -- > 2.20.1 > > _______________________________________________ > amd-gfx mailing list > amd-gfx@lists.freedesktop.org > https://lists.freedesktop.org/mailman/listinfo/amd-gfx _______________________________________________ amd-gfx mailing list amd-gfx@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/amd-gfx ^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] drm/amdgpu: return 0 by default in amdgpu_pm_load_smu_firmware [not found] ` <20190611145103.621-1-alexander.deucher-5C7GfCeVMHo@public.gmane.org> 2019-06-12 1:15 ` Quan, Evan @ 2019-06-13 10:32 ` Paul Menzel [not found] ` <af8e0143-5d3c-b683-d877-60d7f6e2a6b9-KUpvgZVWgV9o1qOY/usvUg@public.gmane.org> 1 sibling, 1 reply; 4+ messages in thread From: Paul Menzel @ 2019-06-13 10:32 UTC (permalink / raw) To: Alex Deucher Cc: Alex Deucher, Sibren Vasse, amd-gfx-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW [-- Attachment #1.1: Type: text/plain, Size: 1441 bytes --] Dear Alex, On 06/11/19 16:51, Alex Deucher wrote: > Fixes SI cards running on amdgpu. Shouldn’t the caller be updated to check for the error code? Wouldn’t that be more explicit? else if (!strcmp(chip_name, "raven") && (amdgpu_pm_load_smu_firmware(adev, &smu_version) == 0) > Fixes: 1929059893022 ("drm/amd/amdgpu: add RLC firmware to support raven1 refresh") > Bug: https://bugs.freedesktop.org/show_bug.cgi?id=110883 > Signed-off-by: Alex Deucher <alexander.deucher-5C7GfCeVMHo@public.gmane.org> > --- > drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > > diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c > index d8828a37e43a..653b2491fec8 100644 > --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c > +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c > @@ -2700,7 +2700,7 @@ void amdgpu_pm_print_power_states(struct amdgpu_device *adev) > > int amdgpu_pm_load_smu_firmware(struct amdgpu_device *adev, uint32_t *smu_version) > { > - int r = -EINVAL; > + int r; > > if (amdgpu_sriov_vf(adev)) > return 0; > @@ -2713,7 +2713,7 @@ int amdgpu_pm_load_smu_firmware(struct amdgpu_device *adev, uint32_t *smu_versio > } > *smu_version = adev->pm.fw_version; > } > - return r; > + return 0; > } > > int amdgpu_pm_sysfs_init(struct amdgpu_device *adev) Kind regards, Paul [-- Attachment #1.2: S/MIME Cryptographic Signature --] [-- Type: application/pkcs7-signature, Size: 5174 bytes --] [-- Attachment #2: Type: text/plain, Size: 153 bytes --] _______________________________________________ amd-gfx mailing list amd-gfx@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/amd-gfx ^ permalink raw reply [flat|nested] 4+ messages in thread
[parent not found: <af8e0143-5d3c-b683-d877-60d7f6e2a6b9-KUpvgZVWgV9o1qOY/usvUg@public.gmane.org>]
* RE: [PATCH] drm/amdgpu: return 0 by default in amdgpu_pm_load_smu_firmware [not found] ` <af8e0143-5d3c-b683-d877-60d7f6e2a6b9-KUpvgZVWgV9o1qOY/usvUg@public.gmane.org> @ 2019-06-13 11:11 ` Huang, Ray 0 siblings, 0 replies; 4+ messages in thread From: Huang, Ray @ 2019-06-13 11:11 UTC (permalink / raw) To: Paul Menzel, Alex Deucher Cc: Deucher, Alexander, Liang, Prike, Sibren Vasse, amd-gfx-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org > -----Original Message----- > From: amd-gfx <amd-gfx-bounces@lists.freedesktop.org> On Behalf Of Paul > Menzel > Sent: Thursday, June 13, 2019 6:32 PM > To: Alex Deucher <alexdeucher@gmail.com> > Cc: Deucher, Alexander <Alexander.Deucher@amd.com>; Sibren Vasse > <freedesktop@sibrenvasse.nl>; amd-gfx@lists.freedesktop.org > Subject: Re: [PATCH] drm/amdgpu: return 0 by default in > amdgpu_pm_load_smu_firmware > > Dear Alex, > > > On 06/11/19 16:51, Alex Deucher wrote: > > Fixes SI cards running on amdgpu. > > Shouldn’t the caller be updated to check for the error code? > Wouldn’t that be more explicit? > > else if (!strcmp(chip_name, "raven") && > (amdgpu_pm_load_smu_firmware(adev, &smu_version) == 0) > Yes. Alex, this function will be called to get the SMC FW version from SBIOS. And make sure whether current ASIC is RV1 refresh kicker. Thanks, Ray > > Fixes: 1929059893022 ("drm/amd/amdgpu: add RLC firmware to support > > raven1 refresh") > > Bug: https://bugs.freedesktop.org/show_bug.cgi?id=110883 > > Signed-off-by: Alex Deucher <alexander.deucher@amd.com> > > --- > > drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c | 4 ++-- > > 1 file changed, 2 insertions(+), 2 deletions(-) > > > > diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c > > b/drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c > > index d8828a37e43a..653b2491fec8 100644 > > --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c > > +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c > > @@ -2700,7 +2700,7 @@ void amdgpu_pm_print_power_states(struct > > amdgpu_device *adev) > > > > int amdgpu_pm_load_smu_firmware(struct amdgpu_device *adev, > uint32_t > > *smu_version) { > > - int r = -EINVAL; > > + int r; > > > > if (amdgpu_sriov_vf(adev)) > > return 0; > > @@ -2713,7 +2713,7 @@ int amdgpu_pm_load_smu_firmware(struct > amdgpu_device *adev, uint32_t *smu_versio > > } > > *smu_version = adev->pm.fw_version; > > } > > - return r; > > + return 0; > > } > > > > int amdgpu_pm_sysfs_init(struct amdgpu_device *adev) > > > Kind regards, > > Paul _______________________________________________ amd-gfx mailing list amd-gfx@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/amd-gfx ^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2019-06-13 11:11 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-06-11 14:51 [PATCH] drm/amdgpu: return 0 by default in amdgpu_pm_load_smu_firmware Alex Deucher
[not found] ` <20190611145103.621-1-alexander.deucher-5C7GfCeVMHo@public.gmane.org>
2019-06-12 1:15 ` Quan, Evan
2019-06-13 10:32 ` Paul Menzel
[not found] ` <af8e0143-5d3c-b683-d877-60d7f6e2a6b9-KUpvgZVWgV9o1qOY/usvUg@public.gmane.org>
2019-06-13 11:11 ` Huang, Ray
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox