From: Abraham Arce
Enable Runtime PM functionality in OMAP4 driver based on the following
assumptions
- Runtime PM selected by ARCH_OMAP2PLUS_TYPICAL && ARCH_OMAP2PLUS,
which is the default OMAP2+ defconfig including OMAP4
- Runtime PM APIs handles Clock Framework APIs
- Do not do the keypadco
From: Abraham Arce
Enable Runtime PM functionality in OMAP4 driver based on the following
assumptions
A minimal pm runtime get/put approach is implemented in probe/remove calls
respectively.
- Keyboard controller in wakeup domain so it is always on and
power impact may be minimal
- In OMAP4
omap 4430sdp board support for the GPIO keys.
The proximity sensor is connected to GPIO and is registered as a
GPIO key.
- Making the default state of the sensor off at bootup
- The init is called before platform_add_devices
Signed-off-by: Shubhrajyoti D
---
arch/arm/mach-omap2/board-4430sdp.c
omap 4430sdp board support for the proximity sensor via GPIO keys.
The proximity sensor is connected to GPIO and is registered as a
GPIO key.
- Making the default state of the sensor off at bootup
- The init is called before platform_add_devices
Signed-off-by: Shubhrajyoti D
---
arch/arm/mach
This patch intends to make the i2cdetect more readable.
Signed-off-by: Shubhrajyoti D
---
drivers/i2c/busses/i2c-omap.c |2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/drivers/i2c/busses/i2c-omap.c b/drivers/i2c/busses/i2c-omap.c
index 7674efb..3a97d2c 100644
--- a
The board file changes for the digital compass hmc5843.
The interface to the device is i2c.
Signed-off-by: Shubhrajyoti D
---
arch/arm/mach-omap2/board-4430sdp.c |8 +++-
1 files changed, 7 insertions(+), 1 deletions(-)
diff --git a/arch/arm/mach-omap2/board-4430sdp.c
b/arch/arm/mach
Board support for the GPIO keys.
The proximity sensor is connected to GPIO and is registered as a
GPIO key.
Signed-off-by: Shubhrajyoti D
---
arch/arm/mach-omap2/board-4430sdp.c | 56 +++
1 files changed, 56 insertions(+), 0 deletions(-)
diff --git a/arch/arm
Signed-off-by: Shubhrajyoti D
---
arch/arm/mach-omap2/board-4430sdp.c | 64 +++
1 files changed, 64 insertions(+), 0 deletions(-)
diff --git a/arch/arm/mach-omap2/board-4430sdp.c
b/arch/arm/mach-omap2/board-4430sdp.c
index 9447644..699620d 100644
--- a/arch
omap 4430sdp board support for the GPIO keys.
The proximity sensor is connected to GPIO and is registered as a
GPIO key.
Signed-off-by: Shubhrajyoti D
---
arch/arm/mach-omap2/board-4430sdp.c | 64 +++
1 files changed, 64 insertions(+), 0 deletions(-)
diff
omap 4430sdp board support for the GPIO keys.
The proximity sensor is connected to GPIO and is registered as a
GPIO key.
Signed-off-by: Shubhrajyoti D
---
arch/arm/mach-omap2/board-4430sdp.c | 64 +++
1 files changed, 64 insertions(+), 0 deletions(-)
diff
omap 4430sdp board support for the GPIO keys.
The proximity sensor is connected to GPIO and is registered as a
GPIO key.
- Making the default state of the sensor off at bootup
Signed-off-by: Shubhrajyoti D
---
arch/arm/mach-omap2/board-4430sdp.c | 61 +++
1
.
- Reset is removed from omap_i2c_init, which was called
not only during probe, but also after time out and error handling.
omap_i2c_reset is added in those places to effect the reset.
Signed-off-by: Shubhrajyoti D
---
drivers/i2c/busses/i2c-omap.c | 38
mit;h=a2ab04192ba25e60f95ba1ff3af5601a2d7b5bd1
Signed-off-by: Vikram Pandita
Signed-off-by: Jon Hunter
Signed-off-by: Shubhrajyoti D
---
drivers/i2c/busses/i2c-omap.c | 33 ++---
1 files changed, 30 insertions(+), 3 deletions(-)
diff --git a/drivers/i2c/busses/i2c-oma
Remove the definition of SYSS_RESETDONE_MASK and use the
one in omap_hwmod.h.
Also fixes the warning
CC drivers/i2c/busses/i2c-omap.o
drivers/i2c/busses/i2c-omap.c:163: warning: "SYSS_RESETDONE_MASK" redefined
Signed-off-by: Shubhrajyoti D
---
drivers/i2c/busses/i2c-omap.c |
The various devm_* functions allocate memory that is released when a driver
detaches. This patch uses devm_kzalloc, devm_request_and_ioremap for data
that is allocated in the probe function of a platform device and is only
freed in the remove function.
Signed-off-by: Shubhrajyoti D
---
drivers
From: Felipe Balbi
trivial patch to aid readability. No functional
changes.
Signed-off-by: Felipe Balbi
Signed-off-by: Shubhrajyoti D
---
drivers/i2c/busses/i2c-omap.c |5 +
1 files changed, 5 insertions(+), 0 deletions(-)
diff --git a/drivers/i2c/busses/i2c-omap.c b/drivers/i2c
I2C: OMAP: simplify omap_i2c_ack_stat()
Jon Hunter (1):
I2C: OMAP: Correct I2C revision for OMAP3
Shubhrajyoti D (7):
I2C: OMAP: I2C register restore only if context is lost
I2C: OMAP: Remove the definition of SYSS_RESETDONE_MASK
I2C: OMAP: Remove reset at init
I2C: OMAP: Op
Currently i2c register restore is done always.
Adding conditional restore.
The i2c register restore is done only if the context is lost
or in case of error to be on the safe side.
Cc: Kevin Hilman
Signed-off-by: Shubhrajyoti D
---
arch/arm/plat-omap/i2c.c |3 +++
drivers/i2c
Changes from his patch
- Update OMAP_I2C_REV_ON_3430 also to reflect that it is same as 3530
Signed-off-by: Jon Hunter
Signed-off-by: Shubhrajyoti D
---
drivers/i2c/busses/i2c-omap.c | 10 +-
1 files changed, 5 insertions(+), 5 deletions(-)
diff --git a/drivers/i2c/busses/i2c-omap.c b
From: Felipe Balbi
stat & BIT(1) is the same as BIT(1), so let's
simplify things a bit by removing "stat &" from
all omap_i2c_ack_stat() calls.
Signed-off-by: Felipe Balbi
Reviewed-by : Santosh Shilimkar
Signed-off-by: Shubhrajyoti D
---
drivers/i2c/b
From: Felipe Balbi
trivial patch, no functional changes.
Signed-off-by: Felipe Balbi
Reviewed-by : Santosh Shilimkar
Signed-off-by: Shubhrajyoti D
---
drivers/i2c/busses/i2c-omap.c | 63 -
1 files changed, 31 insertions(+), 32 deletions(-)
diff
Use SET_RUNTIME_PM_OPS macro to set runtime functions.
Acked-by: Felipe Balbi
Signed-off-by: Shubhrajyoti D
---
drivers/i2c/busses/i2c-omap.c |8 +---
1 files changed, 5 insertions(+), 3 deletions(-)
diff --git a/drivers/i2c/busses/i2c-omap.c b/drivers/i2c/busses/i2c-omap.c
index
From: Felipe Balbi
trivial patch, no functional changes
Signed-off-by: Felipe Balbi
Reviewed-by : Santosh Shilimkar
Signed-off-by: Shubhrajyoti D
---
drivers/i2c/busses/i2c-omap.c |6 ++
1 files changed, 2 insertions(+), 4 deletions(-)
diff --git a/drivers/i2c/busses/i2c-omap.c b
The omap_i2c_remove function may not be needed after
device exit so the memory could be freed.
Signed-off-by: Shubhrajyoti D
---
drivers/i2c/busses/i2c-omap.c |5 ++---
1 files changed, 2 insertions(+), 3 deletions(-)
diff --git a/drivers/i2c/busses/i2c-omap.c b/drivers/i2c/busses/i2c
Use INIT_COMPLETION instead of init_completion in transfer.
Signed-off-by: Shubhrajyoti D
---
drivers/i2c/busses/i2c-omap.c |3 ++-
1 files changed, 2 insertions(+), 1 deletions(-)
diff --git a/drivers/i2c/busses/i2c-omap.c b/drivers/i2c/busses/i2c-omap.c
index 6f8e7d9..e24eb1f 100644
Use INIT_COMPLETION instead of init_completion in transfer.
Signed-off-by: Shubhrajyoti D
---
drivers/i2c/busses/i2c-omap.c |3 ++-
1 files changed, 2 insertions(+), 1 deletions(-)
diff --git a/drivers/i2c/busses/i2c-omap.c b/drivers/i2c/busses/i2c-omap.c
index ccb2fc4..2a50094 100644
Remove the definition of SYSS_RESETDONE_MASK and use the
one in omap_hwmod.h.
Also fixes the warning
CC drivers/i2c/busses/i2c-omap.o
drivers/i2c/busses/i2c-omap.c:163: warning: "SYSS_RESETDONE_MASK" redefined
Signed-off-by: Shubhrajyoti D
---
drivers/i2c/busses/i2c-omap.c |
Use SET_RUNTIME_PM_OPS macro to set runtime functions.
Acked-by: Felipe Balbi
Signed-off-by: Shubhrajyoti D
---
drivers/i2c/busses/i2c-omap.c |8 +---
1 files changed, 5 insertions(+), 3 deletions(-)
diff --git a/drivers/i2c/busses/i2c-omap.c b/drivers/i2c/busses/i2c-omap.c
index
Changes from his patch
- Update OMAP_I2C_REV_ON_3430 also to reflect that it is same as 3530
Signed-off-by: Jon Hunter
Signed-off-by: Shubhrajyoti D
---
drivers/i2c/busses/i2c-omap.c | 10 +-
1 files changed, 5 insertions(+), 5 deletions(-)
diff --git a/drivers/i2c/busses/i2c-omap.c b
The various devm_* functions allocate memory that is released when a driver
detaches. This patch uses devm_kzalloc, devm_request_and_ioremap for data
that is allocated in the probe function of a platform device and is only
freed in the remove function.
Signed-off-by: Shubhrajyoti D
---
drivers
are available in the git repository at:
git://gitorious.org/linus-tree/linus-tree.git for_next/i2c_minimal_cleanup
Jon Hunter (1):
I2C: OMAP: Correct I2C revision for OMAP3
Shubhrajyoti D (6):
I2C: OMAP: I2C register restore only if context is lost
I2C: OMAP: Optimise the remove code
I2C:
Currently i2c register restore is done always.
Adding conditional restore.
The i2c register restore is done only if the context is lost
or in case of error to be on the safe side.
Cc: Kevin Hilman
Signed-off-by: Shubhrajyoti D
---
arch/arm/plat-omap/i2c.c |3 +++
drivers/i2c
The omap_i2c_remove function may not be needed after
device exit so the memory could be freed.
Signed-off-by: Shubhrajyoti D
---
drivers/i2c/busses/i2c-omap.c |5 ++---
1 files changed, 2 insertions(+), 3 deletions(-)
diff --git a/drivers/i2c/busses/i2c-omap.c b/drivers/i2c/busses/i2c
mit;h=a2ab04192ba25e60f95ba1ff3af5601a2d7b5bd1
Signed-off-by: Vikram Pandita
Signed-off-by: Jon Hunter
Signed-off-by: Shubhrajyoti D
---
drivers/i2c/busses/i2c-omap.c | 31 ---
1 files changed, 28 insertions(+), 3 deletions(-)
diff --git a/drivers/i2c/busses/i2c-oma
Use SET_RUNTIME_PM_OPS macro to set runtime functions.
Acked-by: Felipe Balbi
Signed-off-by: Shubhrajyoti D
---
drivers/i2c/busses/i2c-omap.c |8 +---
1 files changed, 5 insertions(+), 3 deletions(-)
diff --git a/drivers/i2c/busses/i2c-omap.c b/drivers/i2c/busses/i2c-omap.c
index
x-i2c/msg07748.html
This series mainly is the cleanups rebased on
i2c-embedded/for-next branch.
Jon Hunter (1):
I2C: OMAP: Correct I2C revision for OMAP3
Shubhrajyoti D (5):
I2C: OMAP: I2C register restore only if context is lost
I2C: OMAP: Optimise the remove code
I2C: OMAP: Use SET_RUNTIME_P
mit;h=a2ab04192ba25e60f95ba1ff3af5601a2d7b5bd1
Signed-off-by: Vikram Pandita
Signed-off-by: Jon Hunter
Signed-off-by: Shubhrajyoti D
---
drivers/i2c/busses/i2c-omap.c | 31 ---
1 files changed, 28 insertions(+), 3 deletions(-)
diff --git a/drivers/i2c/busses/i2c-oma
Changes from his patch
- Update OMAP_I2C_REV_ON_3430 also to reflect that it is same as 3530
Signed-off-by: Jon Hunter
Signed-off-by: Shubhrajyoti D
---
drivers/i2c/busses/i2c-omap.c | 10 +-
1 files changed, 5 insertions(+), 5 deletions(-)
diff --git a/drivers/i2c/busses/i2c-omap.c b
Currently i2c register restore is done always.
Adding conditional restore.
The i2c register restore is done only if the context is lost
or in case of error to be on the safe side.
Cc: Kevin Hilman
Signed-off-by: Shubhrajyoti D
---
arch/arm/plat-omap/i2c.c |3 +++
drivers/i2c
Remove the definition of SYSS_RESETDONE_MASK and use the
one in omap_hwmod.h.
Also fixes the warning
CC drivers/i2c/busses/i2c-omap.o
drivers/i2c/busses/i2c-omap.c:163: warning: "SYSS_RESETDONE_MASK" redefined
Signed-off-by: Shubhrajyoti D
---
drivers/i2c/busses/i2c-omap.c |
The omap_i2c_remove function may not be needed after
device exit so the memory could be freed.
Signed-off-by: Shubhrajyoti D
---
drivers/i2c/busses/i2c-omap.c |5 ++---
1 files changed, 2 insertions(+), 3 deletions(-)
diff --git a/drivers/i2c/busses/i2c-omap.c b/drivers/i2c/busses/i2c
Use INIT_COMPLETION instead of init_completion in transfer.
Signed-off-by: Shubhrajyoti D
---
drivers/i2c/busses/i2c-omap.c |3 ++-
1 files changed, 2 insertions(+), 1 deletions(-)
diff --git a/drivers/i2c/busses/i2c-omap.c b/drivers/i2c/busses/i2c-omap.c
index c771c28..f1109f4 100644
mit;h=a2ab04192ba25e60f95ba1ff3af5601a2d7b5bd1
Signed-off-by: Vikram Pandita
Signed-off-by: Jon Hunter
Signed-off-by: Shubhrajyoti D
---
drivers/i2c/busses/i2c-omap.c | 30 +++---
1 files changed, 27 insertions(+), 3 deletions(-)
diff --git a/drivers/i2c/busses/i2c-oma
e git repository at:
git://gitorious.org/linus-tree/linus-tree.git for_next/omap/minimal_cleanup
Jon Hunter (1):
i2c: omap: Correct I2C revision for OMAP3
Shubhrajyoti D (4):
i2c: omap: Optimise the remove code
i2c: omap: Use SET_RUNTIME_PM_OPS
i2c: omap: Do not initialise the completion ever
The omap_i2c_remove function may not be needed after
device exit so the memory could be freed.
Signed-off-by: Shubhrajyoti D
---
drivers/i2c/busses/i2c-omap.c |5 ++---
1 files changed, 2 insertions(+), 3 deletions(-)
diff --git a/drivers/i2c/busses/i2c-omap.c b/drivers/i2c/busses/i2c
Changes from his patch
- Update OMAP_I2C_REV_ON_3430 also to reflect that it is same as 3530
Reviewed-by: Felipe Balbi
Signed-off-by: Jon Hunter
Signed-off-by: Shubhrajyoti D
---
- Add Felipe's Reviewed by tag
drivers/i2c/busses/i2c-omap.c | 10 +-
1 files changed, 5 insertions(
Use INIT_COMPLETION instead of init_completion in transfer.
Reviewed-by: Felipe Balbi
Signed-off-by: Shubhrajyoti D
---
- Add Felipe's reviewed-by tag
drivers/i2c/busses/i2c-omap.c |3 ++-
1 files changed, 2 insertions(+), 1 deletions(-)
diff --git a/drivers/i2c/busses/i2c-oma
Use SET_RUNTIME_PM_OPS macro to set runtime functions.
Acked-by: Felipe Balbi
Signed-off-by: Shubhrajyoti D
---
drivers/i2c/busses/i2c-omap.c |8 +---
1 files changed, 5 insertions(+), 3 deletions(-)
diff --git a/drivers/i2c/busses/i2c-omap.c b/drivers/i2c/busses/i2c-omap.c
index
Remove the definition of SYSS_RESETDONE_MASK and use the
one in omap_hwmod.h.
Reviewed-by: Felipe Balbi
Signed-off-by: Shubhrajyoti D
---
- Add Felipe's reviewed by tag
drivers/i2c/busses/i2c-omap.c |4 +---
1 files changed, 1 insertions(+), 3 deletions(-)
diff --git a/drivers/i2c/b
.
While at it also fix a missing pm_runtime_disable in the probe error
path.
Cc: Kevin Hilman
Signed-off-by: Shubhrajyoti D
---
drivers/i2c/busses/i2c-omap.c |7 +++
1 files changed, 3 insertions(+), 4 deletions(-)
diff --git a/drivers/i2c/busses/i2c-omap.c b/drivers/i2c/busses/i2c
-off-by: Felipe Balbi
Reviewed-by : Santosh Shilimkar
Signed-off-by: Shubhrajyoti D
---
drivers/i2c/busses/i2c-omap.c |6 ++
1 files changed, 2 insertions(+), 4 deletions(-)
diff --git a/drivers/i2c/busses/i2c-omap.c b/drivers/i2c/busses/i2c-omap.c
index 7ad4efd..1df2bc9 100644
--- a
From: Felipe Balbi
According to flow diagrams on OMAP TRMs,
we should ACK the IRQ as they happen.
Signed-off-by: Felipe Balbi
Signed-off-by: Shubhrajyoti D
---
drivers/i2c/busses/i2c-omap.c | 28
1 files changed, 16 insertions(+), 12 deletions(-)
diff --git a
From: Felipe Balbi
we can ack stat and complete the command from
the errata handling itself.
Signed-off-by: Felipe Balbi
Signed-off-by: Shubhrajyoti D
---
drivers/i2c/busses/i2c-omap.c | 16 +---
1 files changed, 13 insertions(+), 3 deletions(-)
diff --git a/drivers/i2c/busses
From: Felipe Balbi
instead of having multiple return points, use
a goto statement to make that clearer.
Signed-off-by: Felipe Balbi
Signed-off-by: Shubhrajyoti D
---
drivers/i2c/busses/i2c-omap.c | 20
1 files changed, 8 insertions(+), 12 deletions(-)
diff --git a
issues because those IRQs never fire
simultaneously and one will only after after we have handled the
previous, that's because the same FIFO is used anyway and we won't shift
data into FIFO until we tell the IP "hey, I'm done with the FIFO, you
can shift more data"
Signed
break;
}
aaa;
Hence no functional changes.
Signed-off-by: Felipe Balbi
Reviewed-by : Santosh Shilimkar
Signed-off-by: Shubhrajyoti D
---
- Changelogs updated.
drivers/i2c/busses/i2c-omap.c | 63 -
1 files changed, 31 insertions(+), 32 deleti
From: Felipe Balbi
that way we can ignore TX IRQs while in receiver
mode and ignore RX IRQs while in transmitter mode.
Signed-off-by: Felipe Balbi
Signed-off-by: Shubhrajyoti D
---
drivers/i2c/busses/i2c-omap.c |9 +
1 files changed, 9 insertions(+), 0 deletions(-)
diff --git a
From: Felipe Balbi
that's a nice helper from drivers core which
will give us the exact IRQ number, instead
of a pointer to an IRQ resource.
Signed-off-by: Felipe Balbi
Signed-off-by: Shubhrajyoti D
---
drivers/i2c/busses/i2c-omap.c | 12 +++-
1 files changed, 7 insertions(
From: Felipe Balbi
otherwise we could get our IRQ line disabled due
to many spurious IRQs.
Signed-off-by: Felipe Balbi
Signed-off-by: Shubhrajyoti D
---
drivers/i2c/busses/i2c-omap.c |2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/drivers/i2c/busses/i2c-omap.c b
From: Felipe Balbi
this will make sure that we execute at least once.
No functional changes otherwise.
Signed-off-by: Felipe Balbi
Signed-off-by: Shubhrajyoti D
---
drivers/i2c/busses/i2c-omap.c | 20 ++--
1 files changed, 14 insertions(+), 6 deletions(-)
diff --git a
From: Felipe Balbi
trivial patch to aid readability. No functional
changes.
Signed-off-by: Felipe Balbi
Signed-off-by: Shubhrajyoti D
---
drivers/i2c/busses/i2c-omap.c |5 +
1 files changed, 5 insertions(+), 0 deletions(-)
diff --git a/drivers/i2c/busses/i2c-omap.c b/drivers/i2c
From: Felipe Balbi
re-factor the common parts to a separate function,
so that code is easier to read and understand.
No functional changes.
Signed-off-by: Felipe Balbi
Signed-off-by: Shubhrajyoti D
---
drivers/i2c/busses/i2c-omap.c | 204
1 files
From: Felipe Balbi
that helps deleting some boiler plate code
and lets driver-core manage our resources
for us.
Signed-off-by: Felipe Balbi
Signed-off-by: Shubhrajyoti D
---
drivers/i2c/busses/i2c-omap.c | 40 +++-
1 files changed, 11 insertions(+), 29
From: Felipe Balbi
omap_i2c_dev is allocated with kzalloc(),
so we need not initialize b_hw to zero.
Signed-off-by: Felipe Balbi
Signed-off-by: Shubhrajyoti D
---
drivers/i2c/busses/i2c-omap.c |4 +---
1 files changed, 1 insertions(+), 3 deletions(-)
diff --git a/drivers/i2c/busses/i2c
Balbi
Signed-off-by: Shubhrajyoti D
---
drivers/i2c/busses/i2c-omap.c | 43
1 files changed, 30 insertions(+), 13 deletions(-)
diff --git a/drivers/i2c/busses/i2c-omap.c b/drivers/i2c/busses/i2c-omap.c
index 45bd731..870452d 100644
--- a/drivers/i2c/b
check for dev->buf_len as we always know
the amount of data to be transmitted.
Signed-off-by: Felipe Balbi
Signed-off-by: Shubhrajyoti D
---
drivers/i2c/busses/i2c-omap.c | 83 +
1 files changed, 51 insertions(+), 32 deletions(-)
diff --git a/dri
I have dropped a few patches from the series and also
tested every single patch on my pandaboard.
There's still lots of work to be done on the i2c-omap.c
driver but it's now easier to read, IMO.
Changes since v1:
- removed tabification on patch 6/17
- removed dev_err() which was int
avoid an unncessary register
read since dev->fifo_len will always contain the
correct amount of data to be transferred.
Signed-off-by: Felipe Balbi
Signed-off-by: Shubhrajyoti D
---
drivers/i2c/busses/i2c-omap.c | 126 ++--
1 files changed, 94 insertion
transferred in case of
i2c-omap.
Felipe Balbi (1):
i2c: omap: implement handling for 'actual' bytes transferred
Shubhrajyoti D (2):
i2c: add 'actual' field to struct i2c_msg
i2c: inititalise the actual transferred to zero
drivers/i2c/busses/i2c-omap.c |5 +
dr
In i2c_smbus_xfer_emulated initialise the actual bytes
to zero.
Signed-off-by: Shubhrajyoti D
---
drivers/i2c/i2c-core.c |4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/i2c/i2c-core.c b/drivers/i2c/i2c-core.c
index a6ad32b..fa7f799 100644
--- a/drivers/i2c
In case of a NACK, it's wise to tell our clients
drivers about how many bytes were actually transferred.
Support this by adding an extra field to the struct
i2c_msg which gets incremented the amount of bytes
actually transferred.
Signed-off-by: Shubhrajyoti D
Signed-off-by: Felipe
From: Felipe Balbi
this is important in cases where client driver
wants to know how many bytes were actually
transferred.
Signed-off-by: Felipe Balbi
Signed-off-by: Shubhrajyoti D
---
drivers/i2c/busses/i2c-omap.c |5 +
1 files changed, 5 insertions(+), 0 deletions(-)
diff --git a
Remove the redundant read of the status register.
Signed-off-by: Shubhrajyoti D
---
v4:Patch addition(fixes a review comment)
drivers/i2c/busses/i2c-omap.c |2 --
1 files changed, 0 insertions(+), 2 deletions(-)
diff --git a/drivers/i2c/busses/i2c-omap.c b/drivers/i2c/busses/i2c-omap.c
From: Felipe Balbi
we can ack stat and complete the command from
the errata handling itself.
Signed-off-by: Felipe Balbi
Signed-off-by: Shubhrajyoti D
---
drivers/i2c/busses/i2c-omap.c | 16 +---
1 files changed, 13 insertions(+), 3 deletions(-)
diff --git a/drivers/i2c/busses
From: Felipe Balbi
According to flow diagrams on OMAP TRMs,
we should ACK the IRQ as they happen.
Signed-off-by: Felipe Balbi
Signed-off-by: Shubhrajyoti D
---
drivers/i2c/busses/i2c-omap.c | 28
1 files changed, 16 insertions(+), 12 deletions(-)
diff --git a
-off-by: Felipe Balbi
Reviewed-by : Santosh Shilimkar
Signed-off-by: Shubhrajyoti D
---
drivers/i2c/busses/i2c-omap.c |6 ++
1 files changed, 2 insertions(+), 4 deletions(-)
diff --git a/drivers/i2c/busses/i2c-omap.c b/drivers/i2c/busses/i2c-omap.c
index 0946be5..440e41f 100644
--- a
elipe Balbi
[Avoid flagging the XUDF]
Signed-off-by: Shubhrajyoti D
---
drivers/i2c/busses/i2c-omap.c | 43
1 files changed, 30 insertions(+), 13 deletions(-)
diff --git a/drivers/i2c/busses/i2c-omap.c b/drivers/i2c/busses/i2c-omap.c
index 5c2460d..17
f-by: Felipe Balbi
Reviewed-by : Santosh Shilimkar
[Added the explaination from the discurssion to the commit logs]
Signed-off-by: Shubhrajyoti D
---
drivers/i2c/busses/i2c-omap.c | 19 ++-
1 files changed, 10 insertions(+), 9 deletions(-)
diff --git a/drivers/i2c/busses/i2c-o
From: Felipe Balbi
trivial patch to aid readability. No functional
changes.
Signed-off-by: Felipe Balbi
Signed-off-by: Shubhrajyoti D
---
drivers/i2c/busses/i2c-omap.c |5 +
1 files changed, 5 insertions(+), 0 deletions(-)
diff --git a/drivers/i2c/busses/i2c-omap.c b/drivers/i2c
r flag
i2c: omap: simplify errata check
i2c: omap: always return IRQ_HANDLED
i2c: omap: simplify IRQ exit path
i2c: omap: resize fifos before each message
i2c: omap: get rid of the "complete" label
Shubhrajyoti D (1):
i2c: omap: remove redundant status read
drivers/
From: Felipe Balbi
omap_i2c_dev is allocated with kzalloc(),
so we need not initialize b_hw to zero.
Signed-off-by: Felipe Balbi
Signed-off-by: Shubhrajyoti D
---
drivers/i2c/busses/i2c-omap.c |4 +---
1 files changed, 1 insertions(+), 3 deletions(-)
diff --git a/drivers/i2c/busses/i2c
break;
}
aaa;
Hence no functional changes.
Signed-off-by: Felipe Balbi
Reviewed-by : Santosh Shilimkar
Signed-off-by: Shubhrajyoti D
---
drivers/i2c/busses/i2c-omap.c | 63 -
1 files changed, 31 insertions(+), 32 deletions(-)
diff --git a
From: Felipe Balbi
otherwise we could get our IRQ line disabled due
to many spurious IRQs.
Signed-off-by: Felipe Balbi
Signed-off-by: Shubhrajyoti D
---
drivers/i2c/busses/i2c-omap.c |2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/drivers/i2c/busses/i2c-omap.c b
check for dev->buf_len as we always know
the amount of data to be transmitted.
Signed-off-by: Felipe Balbi
Signed-off-by: Shubhrajyoti D
---
drivers/i2c/busses/i2c-omap.c | 83 +
1 files changed, 51 insertions(+), 32 deletions(-)
diff --git a/dri
From: Felipe Balbi
instead of having multiple return points, use
a goto statement to make that clearer.
Signed-off-by: Felipe Balbi
Signed-off-by: Shubhrajyoti D
---
drivers/i2c/busses/i2c-omap.c | 20
1 files changed, 8 insertions(+), 12 deletions(-)
diff --git a
From: Felipe Balbi
that's a nice helper from drivers core which
will give us the exact IRQ number, instead
of a pointer to an IRQ resource.
Signed-off-by: Felipe Balbi
Signed-off-by: Shubhrajyoti D
---
drivers/i2c/busses/i2c-omap.c | 12 +++-
1 files changed, 7 insertions(
From: Felipe Balbi
that way we can ignore TX IRQs while in receiver
mode and ignore RX IRQs while in transmitter mode.
Signed-off-by: Felipe Balbi
[Trivial formatting changes]
Signed-off-by: Shubhrajyoti D
---
drivers/i2c/busses/i2c-omap.c |8
1 files changed, 8 insertions(+), 0
avoid an unncessary register
read since dev->fifo_len will always contain the
correct amount of data to be transferred.
Signed-off-by: Felipe Balbi
Signed-off-by: Shubhrajyoti D
---
v4: use dev->buf_len as it is in sync with the remaining
bytes avoids a reg read thereby.
drivers/i2c/busses
From: Felipe Balbi
this will make sure that we execute at least once.
No functional changes otherwise.
Signed-off-by: Felipe Balbi
Signed-off-by: Shubhrajyoti D
---
drivers/i2c/busses/i2c-omap.c | 20 ++--
1 files changed, 14 insertions(+), 6 deletions(-)
diff --git a
From: Felipe Balbi
that helps deleting some boiler plate code
and lets driver-core manage our resources
for us.
Signed-off-by: Felipe Balbi
Signed-off-by: Shubhrajyoti D
---
drivers/i2c/busses/i2c-omap.c | 41 -
1 files changed, 12 insertions(+), 29
From: Felipe Balbi
re-factor the common parts to a separate function,
so that code is easier to read and understand.
No functional changes.
Signed-off-by: Felipe Balbi
Signed-off-by: Shubhrajyoti D
---
drivers/i2c/busses/i2c-omap.c | 204
1 files
)
[2.175140] [] (kthread+0x90/0x9c) from []
(kernel_thread_exit+0x0/0x8)
[2.183898] ---[ end trace d1830ce6e44292f2 ]---
Fix the warn by changing the unmap parameter to the one used while doing
dma_map.
Reported-by: Russell King
Signed-off-by: Shubhrajyoti D
---
drivers/spi/spi-omap2-mcspi.c
From: Felipe Balbi
omap_i2c_dev is allocated with kzalloc(),
so we need not initialize b_hw to zero.
Signed-off-by: Felipe Balbi
Signed-off-by: Shubhrajyoti D
---
drivers/i2c/busses/i2c-omap.c |4 +---
1 files changed, 1 insertions(+), 3 deletions(-)
diff --git a/drivers/i2c/busses/i2c
From: Felipe Balbi
re-factor the common parts to a separate function,
so that code is easier to read and understand.
No functional changes.
Signed-off-by: Felipe Balbi
Signed-off-by: Shubhrajyoti D
---
drivers/i2c/busses/i2c-omap.c | 204
1 files
f-by: Felipe Balbi
Reviewed-by : Santosh Shilimkar
[Added the explaination from the discurssion to the commit logs]
Signed-off-by: Shubhrajyoti D
---
drivers/i2c/busses/i2c-omap.c | 19 ++-
1 files changed, 10 insertions(+), 9 deletions(-)
diff --git a/drivers/i2c/busses/i2c-o
From: Felipe Balbi
otherwise we could get our IRQ line disabled due
to many spurious IRQs.
Signed-off-by: Felipe Balbi
Signed-off-by: Shubhrajyoti D
---
drivers/i2c/busses/i2c-omap.c |2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/drivers/i2c/busses/i2c-omap.c b
-off-by: Felipe Balbi
Reviewed-by : Santosh Shilimkar
Signed-off-by: Shubhrajyoti D
---
drivers/i2c/busses/i2c-omap.c |6 ++
1 files changed, 2 insertions(+), 4 deletions(-)
diff --git a/drivers/i2c/busses/i2c-omap.c b/drivers/i2c/busses/i2c-omap.c
index 788c16c..520f3ea 100644
--- a
From: Felipe Balbi
that way we can ignore TX IRQs while in receiver
mode and ignore RX IRQs while in transmitter mode.
Signed-off-by: Felipe Balbi
[Trivial formatting changes]
Signed-off-by: Shubhrajyoti D
---
drivers/i2c/busses/i2c-omap.c |8
1 files changed, 8 insertions(+), 0
From: Felipe Balbi
According to flow diagrams on OMAP TRMs,
we should ACK the IRQ as they happen.
Signed-off-by: Felipe Balbi
[ack the stat OMAP_I2C_STAT_AL in case of arbitration lost]
Signed-off-by: Shubhrajyoti D
---
v5 - ack the OMAP_I2C_STAT_AL.
drivers/i2c/busses/i2c-omap.c | 28
data.
Signed-off-by: Felipe Balbi
[Avoid flagging the XUDF]
Signed-off-by: Shubhrajyoti D
---
drivers/i2c/busses/i2c-omap.c | 43
1 files changed, 30 insertions(+), 13 deletions(-)
diff --git a/drivers/i2c/busses/i2c-omap.c b/drivers/i2c/busses/i2c-omap.c
1 - 100 of 598 matches
Mail list logo