ARM: Tegra: Roth/Macallan: Remove wakeup_key callback
Matt Wagner [Thu, 14 Feb 2013 23:49:08 +0000 (15:49 -0800)]
We now handle this in the wakeup code.  Support is no longer needed here.

Bug 1220330

Change-Id: I0ad1ed928413da19089519b62dbc53f59e9f9718
Signed-off-by: Matt Wagner <mwagner@nvidia.com>
Reviewed-on: http://git-master/r/200942
Reviewed-by: Bharat Nihalani <bnihalani@nvidia.com>

arch/arm/mach-tegra/board-macallan-kbc.c
arch/arm/mach-tegra/board-roth-kbc.c

index 35cdb70..71202d1 100644 (file)
@@ -56,26 +56,9 @@ static struct gpio_keys_button macallan_e1545_keys[] = {
        [5] = GPIO_KEY(KEY_MENU, PR0, 0), /* Todo : CAMS */
 };
 
-static int macallan_wakeup_key(void)
-{
-       int wakeup_key;
-       u64 status = readl(IO_ADDRESS(TEGRA_PMC_BASE) + PMC_WAKE_STATUS)
-               | (u64)readl(IO_ADDRESS(TEGRA_PMC_BASE)
-               + PMC_WAKE2_STATUS) << 32;
-       if (status & ((u64)1 << TEGRA_WAKE_GPIO_PQ0))
-               wakeup_key = KEY_POWER;
-       else if (status & ((u64)1 << TEGRA_WAKE_GPIO_PS0))
-               wakeup_key = SW_LID;
-       else
-               wakeup_key = KEY_RESERVED;
-
-       return wakeup_key;
-}
-
 static struct gpio_keys_platform_data macallan_e1545_keys_pdata = {
        .buttons        = macallan_e1545_keys,
        .nbuttons       = ARRAY_SIZE(macallan_e1545_keys),
-       .wakeup_key     = macallan_wakeup_key
 };
 
 static struct platform_device macallan_e1545_keys_device = {
index d709cb5..bbc4535 100644 (file)
@@ -2,7 +2,7 @@
  * arch/arm/mach-tegra/board-roth-kbc.c
  * Keys configuration for Nvidia tegra3 roth platform.
  *
- * Copyright (C) 2012 NVIDIA, Inc.
+ * Copyright (C) 2012-2013 NVIDIA, Inc.
  *
  * This program is free software; you can redistribute it and/or modify
  * it under the terms of the GNU General Public License version 2 as
@@ -71,31 +71,13 @@ static struct gpio_keys_button roth_p2454_keys[] = {
                .desc = "Hall Effect Sensor",
                .active_low = 1,
                .wakeup = 1,
-               .debounce_interval = 100,
+               .debounce_interval = 0,
        },
 };
 
-static int roth_wakeup_key(void)
-{
-       int wakeup_key;
-       u64 status = readl(IO_ADDRESS(TEGRA_PMC_BASE) + PMC_WAKE_STATUS)
-               | (u64)readl(IO_ADDRESS(TEGRA_PMC_BASE)
-               + PMC_WAKE2_STATUS) << 32;
-
-       if (status & ((u64)1 << TEGRA_WAKE_GPIO_PQ0))
-               wakeup_key = KEY_POWER;
-       else if (status & ((u64)1 << TEGRA_WAKE_GPIO_PS0))
-               wakeup_key = SW_LID;
-       else
-               wakeup_key = KEY_RESERVED;
-
-       return wakeup_key;
-}
-
 static struct gpio_keys_platform_data roth_p2454_keys_pdata = {
        .buttons        = roth_p2454_keys,
        .nbuttons       = ARRAY_SIZE(roth_p2454_keys),
-       .wakeup_key     = roth_wakeup_key,
 };
 
 static struct platform_device roth_p2454_keys_device = {