aboutsummaryrefslogtreecommitdiffstats
path: root/target/linux/ar71xx/files/drivers
diff options
context:
space:
mode:
authorGabor Juhos <juhosg@openwrt.org>2012-03-19 15:57:01 +0000
committerGabor Juhos <juhosg@openwrt.org>2012-03-19 15:57:01 +0000
commitdbf4111ad7058fb43a7ad8f216fa32721a3147d2 (patch)
tree994573e5d2c2b509f056191b7a2cc16e522597ee /target/linux/ar71xx/files/drivers
parentc0a33c12b0805710338626e59f129afceee7996e (diff)
downloadupstream-dbf4111ad7058fb43a7ad8f216fa32721a3147d2.tar.gz
upstream-dbf4111ad7058fb43a7ad8f216fa32721a3147d2.tar.bz2
upstream-dbf4111ad7058fb43a7ad8f216fa32721a3147d2.zip
ar71xx: add latch_change field to rb750_led_platform_data
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@31023 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'target/linux/ar71xx/files/drivers')
-rw-r--r--target/linux/ar71xx/files/drivers/leds/leds-rb750.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/target/linux/ar71xx/files/drivers/leds/leds-rb750.c b/target/linux/ar71xx/files/drivers/leds/leds-rb750.c
index 40469444fe..483e4fc967 100644
--- a/target/linux/ar71xx/files/drivers/leds/leds-rb750.c
+++ b/target/linux/ar71xx/files/drivers/leds/leds-rb750.c
@@ -23,6 +23,7 @@ struct rb750_led_dev {
struct led_classdev cdev;
u32 mask;
int active_low;
+ void (*latch_change)(u32 clear, u32 set);
};
struct rb750_led_drvdata {
@@ -46,9 +47,9 @@ static void rb750_led_brightness_set(struct led_classdev *led_cdev,
level ^= rbled->active_low;
if (level)
- rb750_latch_change(0, rbled->mask);
+ rbled->latch_change(0, rbled->mask);
else
- rb750_latch_change(rbled->mask, 0);
+ rbled->latch_change(rbled->mask, 0);
}
static int __devinit rb750_led_probe(struct platform_device *pdev)
@@ -82,6 +83,7 @@ static int __devinit rb750_led_probe(struct platform_device *pdev)
rbled->mask = led_data->mask;
rbled->active_low = !!led_data->active_low;
+ rbled->latch_change = pdata->latch_change;
ret = led_classdev_register(&pdev->dev, &rbled->cdev);
if (ret)