Skip to contentSkip to conversation

s3c24xx: iPAQ rx1950 series

PATCH Superseded Vasily Khoruzhick 1 participant 7 messages Jul 23, 2010 – Aug 18, 2010

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

v6 cover s3c24xx: iPAQ rx1950 series

This patch series adds more support for iPAQ rx1950 PDA to linux:
1. LEDs driver -- it controls blue, green and red LEDs on rx1950
2. Battery driver -- adds ability to monitor and charge battery. This driver is suitable for H1940 PDA aswell (just need to write some machine specific callbacks and get voltage LUTs)

v2: removed ac registration from s3c_adc_battery driver, use pda_power instead for ac support

v3: split LEDs patch to driver and machine parts, split battery patch into battery + LED trigger parts, now battery driver can skip gpio/callbacks usage (if there's no gpio pin to determine that battery is full or if charger is enabled automatically)

v4: add .blink_set callback to LEDs driver instead of using LED_HALF value for blinking, remove LED triggers from battery driver completely (for now)

v5: restore lut_acin usage in s3c_adc_battery driver, it was accidently removed during removing AC support from driver

v6: drop rx1950-specific LEDs driver, use leds-gpio instead, skip s3c-adc-battery patch, as it's already merged into battery-2.6 tree

#1 lore raw

PATCH v6 1/2 rx1950: add battery device

---
 arch/arm/mach-s3c2440/Kconfig       |    3 +
 arch/arm/mach-s3c2440/mach-rx1950.c |  160 +++++++++++++++++++++++++++++++++++
 2 files changed, 163 insertions(+), 0 deletions(-)
arch/arm/mach-s3c2440/Kconfig +3 -0
index cd8e7de..9b6b026 100644
@@ -198,6 +198,9 @@ config MACH_RX1950
 	select S3C_DEV_NAND
 	select S3C2410_IOTIMING if S3C2440_CPUFREQ
 	select S3C2440_XTAL_16934400
+	select S3C_ADC
+	select PDA_POWER
+	select BATTERY_S3C_ADC
 	help
 	   Say Y here if you're using HP iPAQ rx1950
 
arch/arm/mach-s3c2440/mach-rx1950.c +160 -0

180 lines not on this page · raw message

Signature · 1 line
1.7.1.1
#2 lore raw

PATCH v6 2/2 rx1950: add LEDs support

In reply to Vasily Khoruzhick
---
 arch/arm/mach-s3c2440/mach-rx1950.c |   33 +++++++++++++++++++++++++++++++++
 1 files changed, 33 insertions(+), 0 deletions(-)
arch/arm/mach-s3c2440/mach-rx1950.c +33 -0
index 1ccb1ae..8c24869 100644
@@ -28,6 +28,7 @@
 #include <linux/pwm_backlight.h>
 #include <linux/pwm.h>
 #include <linux/s3c_adc_battery.h>
+#include <linux/leds.h>
 
 #include <linux/mtd/mtd.h>
 #include <linux/mtd/partitions.h>
@@ -258,6 +259,37 @@ void rx1950_disable_charger(void)
 	gpio_direction_output(S3C2410_GPJ(3), 0);
 }
 
+static struct gpio_led rx1950_leds_desc[] = {
+	{
+		.name				= "Green",
+		.default_trigger	= "main-battery-charging-or-full",
+		.gpio				= S3C2410_GPA(6),
+	},
+	{
+		.name				= "Red",
+		.default_trigger	= "main-battery-full",
+		.gpio				= S3C2410_GPA(7),
+	},
+	{
+		.name				= "Blue",
+		.default_trigger	= "rx1950-acx-mem",
+		.gpio				= S3C2410_GPA(11),
+	},
+};
+
+static struct gpio_led_platform_data rx1950_leds_pdata = {
+	.num_leds	= ARRAY_SIZE(rx1950_leds_desc),
+	.leds		= rx1950_leds_desc,
+};
+
+static struct platform_device rx1950_leds = {
+	.name	= "leds-gpio",
+	.id		= -1,
+	.dev	= {
+				.platform_data = &rx1950_leds_pdata,
+	},
+};
+
 static struct s3c_adc_bat_pdata rx1950_bat_cfg = {
 	.init = rx1950_bat_init,
 	.exit = rx1950_bat_exit,
@@ -662,6 +694,7 @@ static struct platform_device *rx1950_devices[] __initdata = {
 	&rx1950_device_gpiokeys,
 	&power_supply,
 	&rx1950_battery,
+	&rx1950_leds,
 };
 
 static struct clk *rx1950_clocks[] __initdata = {
Signature · 1 line
1.7.1.1
#3 lore raw

v6 cover s3c24xx: iPAQ rx1950 series

In reply to Vasily Khoruzhick

? ????????? ?? 23 ???? 2010 20:17:50 ????? Vasily Khoruzhick ???????:

Quoted 1 line

This patch series adds more support for iPAQ rx1950 PDA to linux:

Hi, Ben

Please, if it's possible, review this patch series this week. I want this series to be ready for 2.6.36, but next week I'm going on vacation and will be offline from 2 aug till 18 aug.

s3c-adc-battery patch from v5 was merged into battery-2.6 tree and so it's skipped in v6 series, so send comments for battery driver for v5 3/4 patch.

Regards
Vasily
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 198 bytes
Desc: This is a digitally signed message part.
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20100726/0b588fa9/attachment-0001.sig>

#4 lore raw

v6 cover s3c24xx: iPAQ rx1950 series

? ????????? ?? 26 ???? 2010 10:46:17 ????? Vasily Khoruzhick ???????:

Quoted 11 lines

Hi, Ben

Please, if it's possible, review this patch series this week. I want this series to be ready for 2.6.36, but next week I'm going on vacation and will be offline from 2 aug till 18 aug.

s3c-adc-battery patch from v5 was merged into battery-2.6 tree and so it's skipped in v6 series, so send comments for battery driver for v5 3/4 patch.

Regards
Vasily

Hi, Ben

Is there anything wrong with this series? I got no comments from you on this series for a long time.

Regards
Vasily
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 198 bytes
Desc: This is a digitally signed message part.
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20100818/646c5982/attachment.sig>

#5 lore raw

v6 cover s3c24xx: iPAQ rx1950 series

In reply to Vasily Khoruzhick

? ????????? ?? 23 ???? 2010 20:17:50 ????? Vasily Khoruzhick ???????:

Quoted 19 lines

This patch series adds more support for iPAQ rx1950 PDA to linux:
1. LEDs driver -- it controls blue, green and red LEDs on rx1950
2. Battery driver -- adds ability to monitor and charge battery. This driver is suitable for H1940 PDA aswell (just need to write some machine specific callbacks and get voltage LUTs)

v2: removed ac registration from s3c_adc_battery driver, use pda_power instead for ac support

v3: split LEDs patch to driver and machine parts, split battery patch into battery + LED trigger parts, now battery driver can skip gpio/callbacks usage (if there's no gpio pin to determine that battery is full or if charger is enabled automatically)

v4: add .blink_set callback to LEDs driver instead of using LED_HALF value for blinking, remove LED triggers from battery driver completely (for now)

Quoted 7 lines

v5: restore lut_acin usage in s3c_adc_battery driver, it was accidently removed during removing AC support from driver

v6: drop rx1950-specific LEDs driver, use leds-gpio instead, skip s3c-adc-battery patch, as it's already merged into battery-2.6 tree

Ping
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 198 bytes
Desc: This is a digitally signed message part.
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20100728/4c75bf60/attachment.sig>

#6 lore raw

v6 cover s3c24xx: iPAQ rx1950 series

? ????????? ?? 28 ???? 2010 12:17:21 ????? Vasily Khoruzhick ???????:

Quoted 24 lines

? ????????? ?? 23 ???? 2010 20:17:50 ????? Vasily Khoruzhick ???????:

Quoted 23 lines

This patch series adds more support for iPAQ rx1950 PDA to linux:
1. LEDs driver -- it controls blue, green and red LEDs on rx1950
2. Battery driver -- adds ability to monitor and charge battery. This driver is suitable for H1940 PDA aswell (just need to write some machine specific callbacks and get voltage LUTs)

v2: removed ac registration from s3c_adc_battery driver, use pda_power instead for ac support

v3: split LEDs patch to driver and machine parts, split battery patch into battery + LED trigger parts, now battery driver can skip gpio/callbacks usage (if there's no gpio pin to determine that battery is full or if charger is enabled automatically)

v4: add .blink_set callback to LEDs driver instead of using LED_HALF value for blinking, remove LED triggers from battery driver completely (for now)

v5: restore lut_acin usage in s3c_adc_battery driver, it was accidently removed during removing AC support from driver

Quoted 5 lines
Quoted 3 lines

v6: drop rx1950-specific LEDs driver, use leds-gpio instead, skip s3c-adc-battery patch, as it's already merged into battery-2.6 tree

Ping

And last ping, as I'm leaving on vacation on 2nd August :)

Regards
Vasily
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 198 bytes
Desc: This is a digitally signed message part.
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20100730/94da45ba/attachment.sig>