From: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
To: Richard Purdie <rpurdie@rpsys.net>,
Jacek Anaszewski <jacek.anaszewski@gmail.com>,
Pavel Machek <pavel@ucw.cz>,
linux-leds@vger.kernel.org
Cc: Andy Shevchenko <andriy.shevchenko@linux.intel.com>,
Tony Makkiel <tony.makkiel@daqri.com>
Subject: [PATCH v1] leds: lp3952: Remove ACPI support for lp3952
Date: Tue, 21 Mar 2017 21:33:15 +0200 [thread overview]
Message-ID: <20170321193315.33238-1-andriy.shevchenko@linux.intel.com> (raw)
In ACPI world any ID should be carefully chosen and registered
officially. The discussion as I read it gets to wilful assignment an ID
for non-existing real DSDT example.
Rafael already told [2] how this device would be enumerated using
compatible string.
Based on above, remove non-official ACPI IDs and enumeration from the
driver.
[1] https://e2e.ti.com/support/power_management/led_driver/f/192/t/524926
[2] http://article.gmane.org/gmane.linux.acpi.devel/85252
Cc: Tony Makkiel <tony.makkiel@daqri.com>
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
---
drivers/leds/leds-lp3952.c | 17 +++--------------
1 file changed, 3 insertions(+), 14 deletions(-)
diff --git a/drivers/leds/leds-lp3952.c b/drivers/leds/leds-lp3952.c
index 4847e89883a7..4c320f22ab84 100644
--- a/drivers/leds/leds-lp3952.c
+++ b/drivers/leds/leds-lp3952.c
@@ -10,7 +10,6 @@
*
*/
-#include <linux/acpi.h>
#include <linux/delay.h>
#include <linux/gpio.h>
#include <linux/i2c.h>
@@ -122,9 +121,9 @@ static int lp3952_register_led_classdev(struct lp3952_led_array *priv)
};
for (i = 0; i < LP3952_LED_ALL; i++) {
- acpi_ret = lp3952_get_label(&priv->client->dev, led_name_hdl[i],
- priv->leds[i].name);
- if (acpi_ret)
+ ret = lp3952_get_label(&priv->client->dev, led_name_hdl[i],
+ priv->leds[i].name);
+ if (ret)
continue;
priv->leds[i].cdev.name = priv->leds[i].name;
@@ -276,19 +275,9 @@ static const struct i2c_device_id lp3952_id[] = {
};
MODULE_DEVICE_TABLE(i2c, lp3952_id);
-#ifdef CONFIG_ACPI
-static const struct acpi_device_id lp3952_acpi_match[] = {
- {"TXNW3952", 0},
- {}
-};
-
-MODULE_DEVICE_TABLE(acpi, lp3952_acpi_match);
-#endif
-
static struct i2c_driver lp3952_i2c_driver = {
.driver = {
.name = LP3952_NAME,
- .acpi_match_table = ACPI_PTR(lp3952_acpi_match),
},
.probe = lp3952_probe,
.remove = lp3952_remove,
--
2.11.0
next reply other threads:[~2017-03-21 19:33 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-03-21 19:33 Andy Shevchenko [this message]
2017-03-21 20:17 ` [PATCH v1] leds: lp3952: Remove ACPI support for lp3952 Pavel Machek
2017-03-22 13:15 ` Andy Shevchenko
[not found] ` <LO1P123MB0674648ED2956816983DC0C8C33C0@LO1P123MB0674.GBRP123.PROD.OUTLOOK.COM>
2017-03-22 14:20 ` Andy Shevchenko
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=20170321193315.33238-1-andriy.shevchenko@linux.intel.com \
--to=andriy.shevchenko@linux.intel.com \
--cc=jacek.anaszewski@gmail.com \
--cc=linux-leds@vger.kernel.org \
--cc=pavel@ucw.cz \
--cc=rpurdie@rpsys.net \
--cc=tony.makkiel@daqri.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;
as well as URLs for NNTP newsgroup(s).