linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] input: bcm5974: Add support for MacBookAir3
@ 2010-11-09 16:38 Henrik Rydberg
  2010-11-11  8:39 ` Dmitry Torokhov
  0 siblings, 1 reply; 3+ messages in thread
From: Henrik Rydberg @ 2010-11-09 16:38 UTC (permalink / raw)
  To: Dmitry Torokhov
  Cc: Jiri Kosina, linux-input, linux-kernel, Edgar (gimli) Hucek,
	stable, Henrik Rydberg

From: Edgar (gimli) Hucek <gimli@dark-green.com>

This patch adds support for the MacBookAir3,1 and MacBookAir3,2
models.

[rydberg@euromail.se: touchpad range calibration]
Cc: stable@kernel.org
Signed-off-by: Edgar (gimli) Hucek <gimli@dark-green.com>
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
---
Hi Dmitry, Jiri,

This patch was seen on lkml last week, and has now been excercised by
a larger set of users. As usual, this patch should go before or
together with the HID changes, so as not to break basic support from
the non-MT HID driver.

Cheers,
Henrik

 drivers/input/mouse/bcm5974.c |   40 ++++++++++++++++++++++++++++++++++++++++
 1 files changed, 40 insertions(+), 0 deletions(-)

diff --git a/drivers/input/mouse/bcm5974.c b/drivers/input/mouse/bcm5974.c
index b952317..ee82851 100644
--- a/drivers/input/mouse/bcm5974.c
+++ b/drivers/input/mouse/bcm5974.c
@@ -55,6 +55,14 @@
 #define USB_DEVICE_ID_APPLE_WELLSPRING3_ANSI	0x0236
 #define USB_DEVICE_ID_APPLE_WELLSPRING3_ISO	0x0237
 #define USB_DEVICE_ID_APPLE_WELLSPRING3_JIS	0x0238
+/* MacbookAir3,2 (unibody), aka wellspring5 */
+#define USB_DEVICE_ID_APPLE_WELLSPRING4_ANSI	0x023f
+#define USB_DEVICE_ID_APPLE_WELLSPRING4_ISO	0x0240
+#define USB_DEVICE_ID_APPLE_WELLSPRING4_JIS	0x0241
+/* MacbookAir3,1 (unibody), aka wellspring4 */
+#define USB_DEVICE_ID_APPLE_WELLSPRING4A_ANSI	0x0242
+#define USB_DEVICE_ID_APPLE_WELLSPRING4A_ISO	0x0243
+#define USB_DEVICE_ID_APPLE_WELLSPRING4A_JIS	0x0244
 
 #define BCM5974_DEVICE(prod) {					\
 	.match_flags = (USB_DEVICE_ID_MATCH_DEVICE |		\
@@ -80,6 +88,14 @@ static const struct usb_device_id bcm5974_table[] = {
 	BCM5974_DEVICE(USB_DEVICE_ID_APPLE_WELLSPRING3_ANSI),
 	BCM5974_DEVICE(USB_DEVICE_ID_APPLE_WELLSPRING3_ISO),
 	BCM5974_DEVICE(USB_DEVICE_ID_APPLE_WELLSPRING3_JIS),
+	/* MacbookAir3,2 */
+	BCM5974_DEVICE(USB_DEVICE_ID_APPLE_WELLSPRING4_ANSI),
+	BCM5974_DEVICE(USB_DEVICE_ID_APPLE_WELLSPRING4_ISO),
+	BCM5974_DEVICE(USB_DEVICE_ID_APPLE_WELLSPRING4_JIS),
+	/* MacbookAir3,1 */
+	BCM5974_DEVICE(USB_DEVICE_ID_APPLE_WELLSPRING4A_ANSI),
+	BCM5974_DEVICE(USB_DEVICE_ID_APPLE_WELLSPRING4A_ISO),
+	BCM5974_DEVICE(USB_DEVICE_ID_APPLE_WELLSPRING4A_JIS),
 	/* Terminating entry */
 	{}
 };
@@ -234,6 +250,30 @@ static const struct bcm5974_config bcm5974_config_table[] = {
 		{ DIM_X, DIM_X / SN_COORD, -4460, 5166 },
 		{ DIM_Y, DIM_Y / SN_COORD, -75, 6700 }
 	},
+	{
+		USB_DEVICE_ID_APPLE_WELLSPRING4_ANSI,
+		USB_DEVICE_ID_APPLE_WELLSPRING4_ISO,
+		USB_DEVICE_ID_APPLE_WELLSPRING4_JIS,
+		HAS_INTEGRATED_BUTTON,
+		0x84, sizeof(struct bt_data),
+		0x81, TYPE2, FINGER_TYPE2, FINGER_TYPE2 + SIZEOF_ALL_FINGERS,
+		{ DIM_PRESSURE, DIM_PRESSURE / SN_PRESSURE, 0, 300 },
+		{ DIM_WIDTH, DIM_WIDTH / SN_WIDTH, 0, 2048 },
+		{ DIM_X, DIM_X / SN_COORD, -4620, 5140 },
+		{ DIM_Y, DIM_Y / SN_COORD, -150, 6600 }
+	},
+	{
+		USB_DEVICE_ID_APPLE_WELLSPRING4A_ANSI,
+		USB_DEVICE_ID_APPLE_WELLSPRING4A_ISO,
+		USB_DEVICE_ID_APPLE_WELLSPRING4A_JIS,
+		HAS_INTEGRATED_BUTTON,
+		0x84, sizeof(struct bt_data),
+		0x81, TYPE2, FINGER_TYPE2, FINGER_TYPE2 + SIZEOF_ALL_FINGERS,
+		{ DIM_PRESSURE, DIM_PRESSURE / SN_PRESSURE, 0, 300 },
+		{ DIM_WIDTH, DIM_WIDTH / SN_WIDTH, 0, 2048 },
+		{ DIM_X, DIM_X / SN_COORD, -4616, 5112 },
+		{ DIM_Y, DIM_Y / SN_COORD, -142, 5234 }
+	},
 	{}
 };
 
-- 
1.7.1


^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH] input: bcm5974: Add support for MacBookAir3
  2010-11-09 16:38 [PATCH] input: bcm5974: Add support for MacBookAir3 Henrik Rydberg
@ 2010-11-11  8:39 ` Dmitry Torokhov
  2010-11-15 13:18   ` Jiri Kosina
  0 siblings, 1 reply; 3+ messages in thread
From: Dmitry Torokhov @ 2010-11-11  8:39 UTC (permalink / raw)
  To: Henrik Rydberg
  Cc: Jiri Kosina, linux-input, linux-kernel, Edgar (gimli) Hucek, stable

On Tue, Nov 09, 2010 at 05:38:42PM +0100, Henrik Rydberg wrote:
> From: Edgar (gimli) Hucek <gimli@dark-green.com>
> 
> This patch adds support for the MacBookAir3,1 and MacBookAir3,2
> models.
> 
> [rydberg@euromail.se: touchpad range calibration]
> Cc: stable@kernel.org
> Signed-off-by: Edgar (gimli) Hucek <gimli@dark-green.com>
> Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
> ---
> Hi Dmitry, Jiri,
> 
> This patch was seen on lkml last week, and has now been excercised by
> a larger set of users. As usual, this patch should go before or
> together with the HID changes, so as not to break basic support from
> the non-MT HID driver.
> 

Jiri,

It looks like HID changes are more than simply adding USB device IDs so
it woudl make sense to merge through your tree,

Thanks.

> Cheers,
> Henrik
> 
>  drivers/input/mouse/bcm5974.c |   40 ++++++++++++++++++++++++++++++++++++++++
>  1 files changed, 40 insertions(+), 0 deletions(-)
> 
> diff --git a/drivers/input/mouse/bcm5974.c b/drivers/input/mouse/bcm5974.c
> index b952317..ee82851 100644
> --- a/drivers/input/mouse/bcm5974.c
> +++ b/drivers/input/mouse/bcm5974.c
> @@ -55,6 +55,14 @@
>  #define USB_DEVICE_ID_APPLE_WELLSPRING3_ANSI	0x0236
>  #define USB_DEVICE_ID_APPLE_WELLSPRING3_ISO	0x0237
>  #define USB_DEVICE_ID_APPLE_WELLSPRING3_JIS	0x0238
> +/* MacbookAir3,2 (unibody), aka wellspring5 */
> +#define USB_DEVICE_ID_APPLE_WELLSPRING4_ANSI	0x023f
> +#define USB_DEVICE_ID_APPLE_WELLSPRING4_ISO	0x0240
> +#define USB_DEVICE_ID_APPLE_WELLSPRING4_JIS	0x0241
> +/* MacbookAir3,1 (unibody), aka wellspring4 */
> +#define USB_DEVICE_ID_APPLE_WELLSPRING4A_ANSI	0x0242
> +#define USB_DEVICE_ID_APPLE_WELLSPRING4A_ISO	0x0243
> +#define USB_DEVICE_ID_APPLE_WELLSPRING4A_JIS	0x0244
>  
>  #define BCM5974_DEVICE(prod) {					\
>  	.match_flags = (USB_DEVICE_ID_MATCH_DEVICE |		\
> @@ -80,6 +88,14 @@ static const struct usb_device_id bcm5974_table[] = {
>  	BCM5974_DEVICE(USB_DEVICE_ID_APPLE_WELLSPRING3_ANSI),
>  	BCM5974_DEVICE(USB_DEVICE_ID_APPLE_WELLSPRING3_ISO),
>  	BCM5974_DEVICE(USB_DEVICE_ID_APPLE_WELLSPRING3_JIS),
> +	/* MacbookAir3,2 */
> +	BCM5974_DEVICE(USB_DEVICE_ID_APPLE_WELLSPRING4_ANSI),
> +	BCM5974_DEVICE(USB_DEVICE_ID_APPLE_WELLSPRING4_ISO),
> +	BCM5974_DEVICE(USB_DEVICE_ID_APPLE_WELLSPRING4_JIS),
> +	/* MacbookAir3,1 */
> +	BCM5974_DEVICE(USB_DEVICE_ID_APPLE_WELLSPRING4A_ANSI),
> +	BCM5974_DEVICE(USB_DEVICE_ID_APPLE_WELLSPRING4A_ISO),
> +	BCM5974_DEVICE(USB_DEVICE_ID_APPLE_WELLSPRING4A_JIS),
>  	/* Terminating entry */
>  	{}
>  };
> @@ -234,6 +250,30 @@ static const struct bcm5974_config bcm5974_config_table[] = {
>  		{ DIM_X, DIM_X / SN_COORD, -4460, 5166 },
>  		{ DIM_Y, DIM_Y / SN_COORD, -75, 6700 }
>  	},
> +	{
> +		USB_DEVICE_ID_APPLE_WELLSPRING4_ANSI,
> +		USB_DEVICE_ID_APPLE_WELLSPRING4_ISO,
> +		USB_DEVICE_ID_APPLE_WELLSPRING4_JIS,
> +		HAS_INTEGRATED_BUTTON,
> +		0x84, sizeof(struct bt_data),
> +		0x81, TYPE2, FINGER_TYPE2, FINGER_TYPE2 + SIZEOF_ALL_FINGERS,
> +		{ DIM_PRESSURE, DIM_PRESSURE / SN_PRESSURE, 0, 300 },
> +		{ DIM_WIDTH, DIM_WIDTH / SN_WIDTH, 0, 2048 },
> +		{ DIM_X, DIM_X / SN_COORD, -4620, 5140 },
> +		{ DIM_Y, DIM_Y / SN_COORD, -150, 6600 }
> +	},
> +	{
> +		USB_DEVICE_ID_APPLE_WELLSPRING4A_ANSI,
> +		USB_DEVICE_ID_APPLE_WELLSPRING4A_ISO,
> +		USB_DEVICE_ID_APPLE_WELLSPRING4A_JIS,
> +		HAS_INTEGRATED_BUTTON,
> +		0x84, sizeof(struct bt_data),
> +		0x81, TYPE2, FINGER_TYPE2, FINGER_TYPE2 + SIZEOF_ALL_FINGERS,
> +		{ DIM_PRESSURE, DIM_PRESSURE / SN_PRESSURE, 0, 300 },
> +		{ DIM_WIDTH, DIM_WIDTH / SN_WIDTH, 0, 2048 },
> +		{ DIM_X, DIM_X / SN_COORD, -4616, 5112 },
> +		{ DIM_Y, DIM_Y / SN_COORD, -142, 5234 }
> +	},
>  	{}
>  };
>  
> -- 
> 1.7.1
> 

-- 
Dmitry

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] input: bcm5974: Add support for MacBookAir3
  2010-11-11  8:39 ` Dmitry Torokhov
@ 2010-11-15 13:18   ` Jiri Kosina
  0 siblings, 0 replies; 3+ messages in thread
From: Jiri Kosina @ 2010-11-15 13:18 UTC (permalink / raw)
  To: Dmitry Torokhov
  Cc: Henrik Rydberg, linux-input, linux-kernel, Edgar (gimli) Hucek, stable

On Thu, 11 Nov 2010, Dmitry Torokhov wrote:

> On Tue, Nov 09, 2010 at 05:38:42PM +0100, Henrik Rydberg wrote:
> > From: Edgar (gimli) Hucek <gimli@dark-green.com>
> > 
> > This patch adds support for the MacBookAir3,1 and MacBookAir3,2
> > models.
> > 
> > [rydberg@euromail.se: touchpad range calibration]
> > Cc: stable@kernel.org
> > Signed-off-by: Edgar (gimli) Hucek <gimli@dark-green.com>
> > Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
> > ---
> > Hi Dmitry, Jiri,
> > 
> > This patch was seen on lkml last week, and has now been excercised by
> > a larger set of users. As usual, this patch should go before or
> > together with the HID changes, so as not to break basic support from
> > the non-MT HID driver.
> > 
> 
> Jiri,
> 
> It looks like HID changes are more than simply adding USB device IDs so
> it woudl make sense to merge through your tree,

Hi guys,

makes sense. I already have the HID bits in my tree, and will apply the 
bcm5974 part as well.

Thanks,

-- 
Jiri Kosina
SUSE Labs, Novell Inc.

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2010-11-15 13:18 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-11-09 16:38 [PATCH] input: bcm5974: Add support for MacBookAir3 Henrik Rydberg
2010-11-11  8:39 ` Dmitry Torokhov
2010-11-15 13:18   ` Jiri Kosina

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).