[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <7a5b6015-2b04-ef31-1765-b00386238aa9@users.sourceforge.net>
Date: Wed, 9 Aug 2017 17:44:07 +0200
From: SF Markus Elfring <elfring@...rs.sourceforge.net>
To: linux-acpi@...r.kernel.org, Len Brown <lenb@...nel.org>,
"Rafael J. Wysocki" <rjw@...ysocki.net>,
Zhang Rui <rui.zhang@...el.com>
Cc: Hans de Goede <hdegoede@...hat.com>,
LKML <linux-kernel@...r.kernel.org>,
kernel-janitors@...r.kernel.org
Subject: [PATCH v2 7/9] ACPI-video: Delete an unnecessary initialisation in
three functions
From: Markus Elfring <elfring@...rs.sourceforge.net>
Date: Wed, 9 Aug 2017 15:55:35 +0200
Three local variables will be set to appropriate values a bit later.
Thus omit the explicit initialisation at the beginning of these functions.
Signed-off-by: Markus Elfring <elfring@...rs.sourceforge.net>
---
drivers/acpi/acpi_video.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/drivers/acpi/acpi_video.c b/drivers/acpi/acpi_video.c
index e279ed221961..a899faf6ff84 100644
--- a/drivers/acpi/acpi_video.c
+++ b/drivers/acpi/acpi_video.c
@@ -803,7 +803,7 @@ int acpi_video_get_levels(struct acpi_device *device,
union acpi_object *obj = NULL;
int i, max_level = 0, count = 0, level_ac_battery = 0;
union acpi_object *o;
- struct acpi_video_device_brightness *br = NULL;
+ struct acpi_video_device_brightness *br;
int result = 0;
u32 value;
@@ -921,7 +921,7 @@ acpi_video_init_brightness(struct acpi_video_device *device)
int i, max_level = 0;
unsigned long long level, level_old;
struct acpi_video_device_brightness *br = NULL;
- int result = -EINVAL;
+ int result;
result = acpi_video_get_levels(device->dev, &br, &max_level);
if (result)
@@ -1295,7 +1295,7 @@ static int acpi_video_device_enumerate(struct acpi_video_bus *video)
int i;
struct acpi_video_enumerated_device *active_list;
struct acpi_buffer buffer = { ACPI_ALLOCATE_BUFFER, NULL };
- union acpi_object *dod = NULL;
+ union acpi_object *dod;
union acpi_object *obj;
if (!video->cap._DOD)
--
2.13.4
Powered by blists - more mailing lists