ARM: OMAP4: Add put/get sync clocks in setwakeenable

Need to add the clock calls to the setwakeupenable GPIO functions
as on 4430 when going to idle the IRQ enable register is trying to
be accessed with clocks off causing a kernel panic.

Change-Id: Ia01ea21ff8674a4f48263addfc3bcc7b8475f17c
Signed-off-by: Dan Murphy <dmurphy@ti.com>
GPIO: OMAP2+: On suspend don't wakeup on non-wakeupable interrupts.

While in suspend, device should only be woken-up from those gpio
pins, who has explicitly marked itself has wakeup capable through
enable_irq_wake() functions from respective drivers.

In current implementation, it address the issue where interrupts
were lost when system had entered deeper c-state. So in CpuIdle
path all the pins with interrupts enabled where marked has wakeup
capable to get the system out of deeper c-states.
With this approach, it is observed that lots of spurious
interrupts are waking system from suspend, even though they not
suppose wake the device.

So based on, whether prepare idle is called from CpuIdle or
suspend mark gpio wakeup capable.

Change-Id: Ib3f9be6e56c0656f4b8736861740ed0b4394384f
Signed-off-by: Ambresh K <ambresh@ti.com>
Signed-off-by: Hema Kalliguddi <hemahk@ti.com>
drivers: hwspinlock: use mutex instead of spinlock

We cannot call functions which sleep when we hold a
software spinlock. To avoid the warnings, we use a
mutex instead. The mutex is initialized when we
register the hwspinlock.

Change-Id: Ifa331eb431552b29e1e6aafbb5a3469018909e9c
Signed-off-by: Christina Warren <cawarren@ti.com>
Signed-off-by: Ohad Ben-Cohen <ohad@wizery.com>
OMAP4: Avoid clearing i2c2 irq on A9 when HWSPINLOCK is enabled

This patch is related to this commit:
7dd92cb9a8b9c6bb0f4b03afd26ea50ec90cfb73

On Blaze and Blaze Tablet, the i2c-2 bus is shared by A9 and Ducati.
We want A9 to be able to access the i2c-2 bus when it needs it.
This patch will prevent the i2c-2 irq from being cleared on A9 when
Ducati requests the i2c-2 resource, since hwspinlock is being used to
arbitrate the use of the i2c-2 bus.

Change-Id: Iddb667f77e17d9799a9caa62d9f2a0a0043f1768
Signed-off-by: Christina Warren <cawarren@ti.com>
[Blaze] BMP085 Pressure:Port BMP085 k39 driver to k3.0

Port BMP085 k39 driver to k3.0

Change-Id: If8173267a795523fb219caa40732ab379a903f20
Signed-off-by: Arthur Philpott <arthur.philpott@ti.com>