summaryrefslogtreecommitdiff
path: root/firmware/target/arm/imx233
diff options
context:
space:
mode:
authorAmaury Pouly <amaury.pouly@gmail.com>2012-01-27 19:50:06 +0100
committerAmaury Pouly <amaury.pouly@gmail.com>2012-01-27 20:08:33 +0100
commit05ba5c19712250b27cc78e8316b93690fd948a03 (patch)
tree7ad562d73c01e231665f22ad8c04f62e1c72bb24 /firmware/target/arm/imx233
parentbf47e577aa7d5d6e64cb6b8a1f8869c62dc5d2f9 (diff)
imx233: update arbiter to get more debug information, update debug screen accordingly
Change-Id: Ia229e5303692712295f1dbd37a76f865a3eef4ea
Diffstat (limited to 'firmware/target/arm/imx233')
-rw-r--r--firmware/target/arm/imx233/debug-imx233.c6
-rw-r--r--firmware/target/arm/imx233/kernel-imx233.c5
-rw-r--r--firmware/target/arm/imx233/kernel-imx233.h1
3 files changed, 9 insertions, 3 deletions
diff --git a/firmware/target/arm/imx233/debug-imx233.c b/firmware/target/arm/imx233/debug-imx233.c
index 7db7ee97d7..a4c50bbaf7 100644
--- a/firmware/target/arm/imx233/debug-imx233.c
+++ b/firmware/target/arm/imx233/debug-imx233.c
@@ -378,14 +378,14 @@ bool dbg_hw_info_dcp(void)
info.gather_writes, info.otp_key_ready, info.ch0_merged);
lcd_putsf(0, 4, "ctx switching: %d caching: %d", info.context_switching,
info.context_caching);
- lcd_putsf(0, 5, "ch irq ien en rdy pri sem cmdptr");
+ lcd_putsf(0, 5, "ch irq ien en rdy pri sem cmdptr a");
int nr = HW_DCP_NUM_CHANNELS;
for(int i = 0; i < nr; i++)
{
- lcd_putsf(0, 6 + i, "%d %d %d %d %d %d %d 0x%08lx",
+ lcd_putsf(0, 6 + i, "%d %d %d %d %d %d %d 0x%08lx %d",
i, info.channel[i].irq, info.channel[i].irq_en, info.channel[i].enable,
info.channel[i].ready, info.channel[i].high_priority,
- info.channel[i].sema, info.channel[i].cmdptr);
+ info.channel[i].sema, info.channel[i].cmdptr, info.channel[i].acquired);
}
lcd_putsf(0, 6 + nr, "csc %d %d %d %d",
info.csc.irq, info.csc.irq_en, info.csc.enable, info.csc.priority);
diff --git a/firmware/target/arm/imx233/kernel-imx233.c b/firmware/target/arm/imx233/kernel-imx233.c
index b59d3ed63f..752db68149 100644
--- a/firmware/target/arm/imx233/kernel-imx233.c
+++ b/firmware/target/arm/imx233/kernel-imx233.c
@@ -71,6 +71,11 @@ int arbiter_acquire(struct channel_arbiter_t *a, int timeout)
return chan;
}
+bool arbiter_acquired(struct channel_arbiter_t *a, int channel)
+{
+ return !(a->free_bm & (1 << channel));
+}
+
void arbiter_release(struct channel_arbiter_t *a, int channel)
{
mutex_lock(&a->mutex);
diff --git a/firmware/target/arm/imx233/kernel-imx233.h b/firmware/target/arm/imx233/kernel-imx233.h
index 3c62c1597c..960f3f2431 100644
--- a/firmware/target/arm/imx233/kernel-imx233.h
+++ b/firmware/target/arm/imx233/kernel-imx233.h
@@ -41,5 +41,6 @@ void arbiter_reserve(struct channel_arbiter_t *a, unsigned channel);
/* return channel on success and OBJ_WAIT_TIMEOUT on failure */
int arbiter_acquire(struct channel_arbiter_t *a, int timeout);
void arbiter_release(struct channel_arbiter_t *a, int channel);
+bool arbiter_acquired(struct channel_arbiter_t *a, int channel);
#endif /* __KERNEL_IMX233__ */ \ No newline at end of file