Modify

Opened 7 years ago

Last modified 4 years ago

#8271 assigned enhancement

[wrt350nv2] keytype for gpio-keys in kernel

Reported by: mrk Owned by: kaloz
Priority: normal Milestone: Chaos Calmer 15.05
Component: kernel Version: Trunk
Keywords: gpio-keys orion Cc: maddes

Description

At present the setup for orion/wrt350nv2 does not include a keytype.

With the enclosed patch for kernel 2.6.36 it is possible to use the buttons with kernel driver (kmod-input-gpio-keys).

It integrates the wps-button in hotplug-button / hotplug2 - system.

see also post #939

Patch can be included in: trunk/target/linux/orion/patches-2.6.36
Filename: 110-wrt350nv2-keytype.patch

--- a/arch/arm/mach-orion5x/wrt350n-v2-setup.c
+++ b/arch/arm/mach-orion5x/wrt350n-v2-setup.c
@@ -75,11 +75,13 @@ static struct gpio_keys_button wrt350n_v
 		.code		= KEY_RESTART,
 		.gpio		= 3,
 		.desc		= "Reset Button",
+                .type           = EV_KEY,
 		.active_low	= 1,
 	}, {
 		.code		= KEY_WPS_BUTTON,
 		.gpio		= 2,
 		.desc		= "WPS Button",
+                .type           = EV_KEY,
 		.active_low	= 1,
 	},
 };

Attachments (3)

110-wrt350nv2-button.patch (434 bytes) - added by mrk 7 years ago.
trunk_orion_wrt350nv2_2.6.36_gpio.patch (713 bytes) - added by maddes 7 years ago.
-p0 patch for trunk, gpio for WRT350Nv2 (orion) with current kernel
trunk_orion_wrt350nv2_2.6.32_gpio.patch (5.1 KB) - added by maddes 7 years ago.
-p0 patch for trunk, gpio for WRT350Nv2 (orion) with Backfire kernel 2.6.32

Download all attachments as: .zip

Change History (9)

Changed 7 years ago by mrk

comment:1 Changed 7 years ago by maddes

  • Cc maddes added
  • Keywords orion added
  • Owner changed from developers to kaloz
  • Status changed from new to assigned

comment:2 Changed 7 years ago by maddes

This should definitely go upstream.

comment:3 Changed 7 years ago by maddes

  • Milestone changed from Kamikaze to Backfire 10.03.1

comment:4 Changed 7 years ago by maddes

Works on 2.6.36/.37 and is good for trunk.

I would suggest to create a backport for Backfire with 2.6.32.

comment:5 Changed 7 years ago by maddes

Found some time to work on this:
First I fixed the format of the original file (tabs not spaces).
Second I backported into patch 090 for kernel 2.6.32 while also making it look like the 2.6.36 code.

Find attached two -p0 patch files, that add everything to trunk.

Changed 7 years ago by maddes

-p0 patch for trunk, gpio for WRT350Nv2 (orion) with current kernel

Changed 7 years ago by maddes

-p0 patch for trunk, gpio for WRT350Nv2 (orion) with Backfire kernel 2.6.32

comment:6 Changed 4 years ago by jow

  • Milestone changed from Backfire 10.03.2 to Chaos Calmer (trunk)

Milestone Backfire 10.03.2 deleted

Add Comment

Modify Ticket

Action
as assigned .
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.