public inbox for linux-acpi@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] ACPI: PM: s2idle: Remove useless variable ‘obj_new’ in lpi_device_get_constraints_amd
@ 2021-01-06  1:23 Ye Bin
  2021-01-07 13:28 ` Rafael J. Wysocki
  0 siblings, 1 reply; 2+ messages in thread
From: Ye Bin @ 2021-01-06  1:23 UTC (permalink / raw)
  To: rjw, lenb, linux-acpi, linux-kernel; +Cc: Ye Bin

Fix warning:
drivers/acpi/x86/s2idle.c:138:25: warning: variable ‘obj_new’ set but
not used [-Wunused-but-set-variable]
      union acpi_object *obj_new;
                               ^~~~~~~
Reported-by: Hulk Robot <hulkci@huawei.com>
Signed-off-by: Ye Bin <yebin10@huawei.com>
---
 drivers/acpi/x86/s2idle.c | 2 --
 1 file changed, 2 deletions(-)

diff --git a/drivers/acpi/x86/s2idle.c b/drivers/acpi/x86/s2idle.c
index 25fea34b544c..e5fb17fd1020 100644
--- a/drivers/acpi/x86/s2idle.c
+++ b/drivers/acpi/x86/s2idle.c
@@ -135,12 +135,10 @@ static void lpi_device_get_constraints_amd(void)
 
 				for (k = 0; k < info_obj->package.count; ++k) {
 					union acpi_object *obj = &info_obj->package.elements[k];
-					union acpi_object *obj_new;
 
 					list = &lpi_constraints_table[lpi_constraints_table_size];
 					list->min_dstate = -1;
 
-					obj_new = &obj[k];
 					switch (k) {
 					case 0:
 						dev_info.enabled = obj->integer.value;
-- 
2.16.2.dirty


^ permalink raw reply related	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2021-01-07 13:31 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2021-01-06  1:23 [PATCH] ACPI: PM: s2idle: Remove useless variable ‘obj_new’ in lpi_device_get_constraints_amd Ye Bin
2021-01-07 13:28 ` Rafael J. Wysocki

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox