When the OMAP I2C controller is operated in master mode, setting the
STP bit in the CON register instructs the controller to generate an I2C
stop condition only after the programmed number of bytes has been sent
on the I2C bus. The current code in QEMU ends the I2C transfer without
first sending the pending data instead.
Fix the above issue, and let the I2C transfer be ended in
omap_i2c_fifo_run(), after the count of bytes to send has reached zero.
Signed-off-by: Francesco Lavra <francescolavra.fl(a)gmail.com>
---
Without this patch, the controller driver in Linux is unable to send
data on the I2C bus, and when the controller triggers an IRQ after
having started an I2C transfer, the XRDY flag in the STAT register
remains always asserted, leading to an endless loop which eventually
results in a kernel oops.
hw/i2c/omap_i2c.c | 4 ----
1 files changed, 0 insertions(+), 4 deletions(-)
diff --git a/hw/i2c/omap_i2c.c b/hw/i2c/omap_i2c.c
index cfaac07..17d4037 100644
--- a/hw/i2c/omap_i2c.c
+++ b/hw/i2c/omap_i2c.c
@@ -521,10 +521,6 @@ static void omap_i2c_write(void *opaque, hwaddr addr,
omap_i2c_fifo_run(s);
}
omap_i2c_interrupts_update(s);
- } else if (value & 2) { /* STP, but not STT */
- i2c_end_transfer(s->bus);
- s->control &= ~0x0602; /* MST | TRX | STP */
- s->count_cur = s->count;
}
}
break;
--
1.7.5.4
Last week
* Wrote up notes on gcc cross-compiler building (WIP:
https://wiki.linaro.org/WorkingGroups/ToolChain/BuildingGNUToolchains)
* started looking at gcc test suite
This week
* produce at least one fix for a gcc testsuite test problem
* book LCU13
* with luck, receive new laptop
== Progress ==
* 2013-08 4.8 release:
- Reviewed merge requests sent by Yvan.
A few instabilities in x86/x86_64: re-spawned jobs came back clean.
Unexpected improvements in a9: actually the reference had
unexpected regression; re-spawned reference job came back clean.
- prepared another series of backports; had to dig history to find
missing dependencies.
== Plan ==
* 2013.08 4.8 release:
- merge approved backports
- merge fsf-4.8 branch
* 2013.08 4.7 release:
- merge fsf-4.7 branch
* Resume work on aarch64 frame layout.
* Resume work on disabling peeling.
== Progress ==
* Generated arm syscall xml file for gdb and made few code changes in
arm-linux-tdep for catch syscall support on arm TCWG-182.
* Ran reverse debugging test suites on arm with arm/thumb and mix mode.
== Plan ==
* Short week due to EID holidays
* Try to Complete code changes and perform testing on arm/x86 for gdb
catch syscall support for arm TCWG-182.
== Progress ==
* Libssp support for AArch64 TCWG 23:
Basic support is enabled by default when frame is made to grow downwards.
Wrote machine descriptions for stack_protect_set and
stack_protect_test to override this default behavior.
Testing the patch internally.
Plan is to emit instructions as RTL instead of template and see
which approach is better.
* Look at builtin return address behavior in the absence of frame pointer:
For X86_64 usage if __builtin_return_address(n) n>0 and
-fomit-frame-pointer results in undefined behavior.
Discussed with Marcus and Andrew (mail chain) and decided not to
touch __builtin_return_address(n) where n>0.
Decided to leave it as return 0 for frame number other than current frame.
* TCWG-20 gprof support patches.
Re-implemented gprof patches without builtin_return_address usage
for frame number n >0.
The "mcount" in glibc needs two arguments. The "mcount" routine
will be emitted by GCC with an argument to previous frame return
address.
And in the glibc "mcount" routine will be modified to use
builtin_return_address(0) for the second argument.
http://gcc.gnu.org/ml/gcc-patches/2013-08/msg00148.html
Waiting for comments.
Matt suggested to try and return a label address inside the function
while generating mcount. But profiling code is expanded before any
local labels are generated.
Also need to research more on this approach. So stopped and decided
to use simpler approach.
== Plan ==
* Continue Libssp support for AArch64 TCWG-23
* Update review comments and upstream gprof patches
==issues==
* LTO/PGO work stopped now since libssp support priority is more
Misc
------
09-August Public holiday in India.
== Progress ==
* Worked on integrating Cbuildv2 with Jenkins, an automated build
system used by the LAVA team.
- Uses cbuildv2 to fetch, configure, build, and install a C
toolchain
cross or native build.
* Wrote a script to convert DejaGnu sum files into Junit format, which
can be imported into Jenkins for viewing. Initial test is online at:
https://ci.linaro.org/jenkins/view/toolchain/job/junit-parsing/.
A work
in progress, and Jenkins is a bit limited in the allowed test
results.
* Did expense reports for Connect - Cauldron trip.
== Plans ==
* Refactor how cbuildv2 dependencies for packages are handled so
they work more than one level deep.
* Have cbuildv2 build C++ after eglibc.
* More Jenkins integration.
* Work on wiki pages.
- rob -
== Progress ==
- Addressed VRP based zero/sign extension elimination review comments
- Make check passes but spec2k gcc fails in results comparison;
investigating it
- Started again with spec2k comparison for ARM to see potential
optimization opportunities
- Installed libacovea in Chromebook with some tweaks to study affects
of optimization options
== Plan ==
- post the VRP based zero/sign extension elimination patch
- continue with pec2k comparison for ARM
== Misc ==
- Was on holiday until 29th (4 day week)
== Issues ==
* None
== Progress ==
* Validate and release Linaro toolchain binaries 2013.07.
* Commit the fix for pr57637.
* Revise patch and test case for lp1189445.
* Separate conditional compare changes to small patches and test.
* Send out the patch of "Reassociate X == CST1 || X == CST2 if
popcount (CST2 - CST1) == 1 into ((X - CST1) & ~(CST2 - CST1)) == 0"
for internal review.
* R/M toolchain internal release work.
== Plan ==
* Send out the conditional compare patches for review.
== Planned leaves ==
* Aug 19-20.
== Progress ==
* Divmod 64
- Got generic lowering working, with an ugly hack
- Working on custom lowering with new node types
* Testing the SLP vectorizer on O3 and O2
- Found some regressions, need to investigate
- It's going to be on by default on O3 from now on
* SLP vectorizer introduced by default on O3
- Lots of failures in ARM test-suite due to illegal vector types
- Fixed on patch r187658
== Issues ==
Had a bit of a problem with my tooth, had to stay away for a while... put
me away from working on divmod properly... :(
== Plan ==
HOLIDAYS!!!
Progress:
* v7 mach-virt upstreaming:
** implemented architected timer support for TCG, sent patches
** nearly finished cleanup of mach-virt including adding virtio support
** ran into an odd bug where putting RAM not at address zero results in
the kernel not booting -- need to debug
** once that is fixed should just need to do final testing and send patches
Plans:
* look at OVS' v2 a8-kvm-support patches
-- PMM