Reg. kernel crash while using pixcir touchscreen driver

5 messages, 2 authors, 2012-05-24 · open the first message on its own page

Reg. kernel crash while using pixcir touchscreen driver

From: Sachin Kamat <hidden>
Date: 2012-05-24 05:50:03

Hi,

I encountered a kernel crash while integrating Pixcir touchscreen
driver with one of our hardware. The log is attached at the end of the
mail (inline).

The following ISR code:

while (!tsdata->exiting) {
        pixcir_ts_poscheck(tsdata);

        if (tsdata->chip->attb_read_val())
              break;

        msleep(20);
}

seems to run until the if condition is false. However, when it exits
the loop (when the condition becomes true), it crashes saying "exiting
task "irq/438-pixcir_" (1011) is an active IRQ thread".

I have 2 questions here:
1. Do we need such a loop and the if condition. In my case it worked
with the isr just doing
pixcir_ts_poscheck(tsdata);

2. What exactly is expected by attb_read_val() function.

Any pointers would be helpful.

*****
Unable to handle kernel paging request at virtual address e7fddef0
pgd = cf9e4000
[e7fddef0] *pgd=00000000
Internal error: Oops: 80000005 [#1] PREEMPT SMP ARM
Modules linked in:
CPU: 1    Not tainted  (3.4.0-rc3-00050-g718e84c-dirty #24)
PC is at 0xe7fddef0
LR is at pixcir_ts_isr+0x7c/0x210
pc : [<e7fddef0>]    lr : [<c01aaa68>]    psr: 60000013
sp : cef83f50  ip : 00000000  fp : 00000001
r10: cf8ce780  r9 : 00000001  r8 : 00000000
r7 : 00000000  r6 : 00000000  r5 : 00000000  r4 : 000000fc
r3 : e7fddef0  r2 : cef83f48  r1 : 60000013  r0 : 00000000
Flags: nZCv  IRQs on  FIQs on  Mode SVC_32  ISA ARM  Segment kernel
Control: 10c5387d  Table: 4f9e404a  DAC: 00000015
Process irq/438-pixcir_ (pid: 1011, stack limit = 0xcef822f0)
Stack: (0xcef83f50 to 0xcef84000)
3f40:                                     cef83f8c 00000256 c0367f80 56000180
3f60: 0000fc02 00000000 00000001 cef82000 cebdc720 00000001 cebdc700 c0380a40
3f80: c0380a94 c038c670 00000000 c00636e8 c0367f80 c03672c0 00000001 cf833dfc
3fa0: cebdc700 c00635ec 00000013 00000000 00000000 00000000 00000000 c0038bd4
3fc0: 00000000 cebdc700 00000000 00000000 00000000 dead4ead ffffffff ffffffff
3fe0: cef83fe0 cef83fe0 cf833dfc c0038b50 c000f02c c000f02c 00002468 00000000
[<c01aaa68>] (pixcir_ts_isr+0x7c/0x210) from [<c00636e8>]
(irq_thread+0xfc/0x14c)
[<c00636e8>] (irq_thread+0xfc/0x14c) from [<c0038bd4>] (kthread+0x84/0x90)
[<c0038bd4>] (kthread+0x84/0x90) from [<c000f02c>] (kernel_thread_exit+0x0/0x8)
Code: bad PC value
---[ end trace cbb10841fae7b402 ]---
exiting task "irq/438-pixcir_" (1011) is an active IRQ thread (irq 438)


-- 
Regards,
Sachin

Re: Reg. kernel crash while using pixcir touchscreen driver

From: Dmitry Torokhov <dmitry.torokhov@gmail.com>
Date: 2012-05-24 07:47:10

Hi Sachin,

On Thu, May 24, 2012 at 11:20:01AM +0530, Sachin Kamat wrote:
Hi,

I encountered a kernel crash while integrating Pixcir touchscreen
driver with one of our hardware. The log is attached at the end of the
mail (inline).

The following ISR code:

while (!tsdata->exiting) {
        pixcir_ts_poscheck(tsdata);

        if (tsdata->chip->attb_read_val())
              break;

        msleep(20);
}

seems to run until the if condition is false. However, when it exits
the loop (when the condition becomes true), it crashes saying "exiting
task "irq/438-pixcir_" (1011) is an active IRQ thread".
It actually crashes earlier, in pixcir_ts_isr() itself. The message is
coming from do_exit() when ISR thread dies. Did you porvide
attb_read_val implementation?
I have 2 questions here:
1. Do we need such a loop and the if condition. In my case it worked
with the isr just doing
pixcir_ts_poscheck(tsdata);

2. What exactly is expected by attb_read_val() function.
I believe it is supposed to indicate if touch is detected so we can keep
polling.

Thanks.

-- 
Dmitry

Re: Reg. kernel crash while using pixcir touchscreen driver

From: Sachin Kamat <hidden>
Date: 2012-05-24 08:11:28

Hi Dmitry,

Thank you for your reply.


On 24/05/2012, Dmitry Torokhov [off-list ref] wrote:
Hi Sachin,

On Thu, May 24, 2012 at 11:20:01AM +0530, Sachin Kamat wrote:
quoted
Hi,

I encountered a kernel crash while integrating Pixcir touchscreen
driver with one of our hardware. The log is attached at the end of the
mail (inline).

The following ISR code:

while (!tsdata->exiting) {
        pixcir_ts_poscheck(tsdata);

        if (tsdata->chip->attb_read_val())
              break;

        msleep(20);
}

seems to run until the if condition is false. However, when it exits
the loop (when the condition becomes true), it crashes saying "exiting
task "irq/438-pixcir_" (1011) is an active IRQ thread".
It actually crashes earlier, in pixcir_ts_isr() itself. The message is
coming from do_exit() when ISR thread dies. Did you porvide
attb_read_val implementation?
Yes, i did provide the implementation for it.
In fact even a simplest implementation where I return a positive
integer (for testing) results in the above crash.
quoted
I have 2 questions here:
1. Do we need such a loop and the if condition. In my case it worked
with the isr just doing
pixcir_ts_poscheck(tsdata);

2. What exactly is expected by attb_read_val() function.
I believe it is supposed to indicate if touch is detected so we can keep
polling.

Thanks.

--
Dmitry

-- 
With warm regards,
Sachin

Re: Reg. kernel crash while using pixcir touchscreen driver

From: Dmitry Torokhov <dmitry.torokhov@gmail.com>
Date: 2012-05-24 08:22:08

On Thu, May 24, 2012 at 01:41:27PM +0530, Sachin Kamat wrote:
Hi Dmitry,

Thank you for your reply.


On 24/05/2012, Dmitry Torokhov [off-list ref] wrote:
quoted
Hi Sachin,

On Thu, May 24, 2012 at 11:20:01AM +0530, Sachin Kamat wrote:
quoted
Hi,

I encountered a kernel crash while integrating Pixcir touchscreen
driver with one of our hardware. The log is attached at the end of the
mail (inline).

The following ISR code:

while (!tsdata->exiting) {
        pixcir_ts_poscheck(tsdata);

        if (tsdata->chip->attb_read_val())
              break;

        msleep(20);
}

seems to run until the if condition is false. However, when it exits
the loop (when the condition becomes true), it crashes saying "exiting
task "irq/438-pixcir_" (1011) is an active IRQ thread".
It actually crashes earlier, in pixcir_ts_isr() itself. The message is
coming from do_exit() when ISR thread dies. Did you porvide
attb_read_val implementation?
Yes, i did provide the implementation for it.
In fact even a simplest implementation where I return a positive
integer (for testing) results in the above crash.
Hmm, this is wierd... are you sure you do not discard platform data
after binding to the touchscreen?

-- 
Dmitry

Re: Reg. kernel crash while using pixcir touchscreen driver

From: Sachin Kamat <hidden>
Date: 2012-05-24 10:05:53

On 24/05/2012, Dmitry Torokhov [off-list ref] wrote:
On Thu, May 24, 2012 at 01:41:27PM +0530, Sachin Kamat wrote:
quoted
Hi Dmitry,

Thank you for your reply.


On 24/05/2012, Dmitry Torokhov [off-list ref] wrote:
quoted
Hi Sachin,

On Thu, May 24, 2012 at 11:20:01AM +0530, Sachin Kamat wrote:
quoted
Hi,

I encountered a kernel crash while integrating Pixcir touchscreen
driver with one of our hardware. The log is attached at the end of the
mail (inline).

The following ISR code:

while (!tsdata->exiting) {
        pixcir_ts_poscheck(tsdata);

        if (tsdata->chip->attb_read_val())
              break;

        msleep(20);
}

seems to run until the if condition is false. However, when it exits
the loop (when the condition becomes true), it crashes saying "exiting
task "irq/438-pixcir_" (1011) is an active IRQ thread".
It actually crashes earlier, in pixcir_ts_isr() itself. The message is
coming from do_exit() when ISR thread dies. Did you porvide
attb_read_val implementation?
Yes, i did provide the implementation for it.
In fact even a simplest implementation where I return a positive
integer (for testing) results in the above crash.
Hmm, this is wierd... are you sure you do not discard platform data
after binding to the touchscreen?
Yes, you are right. The platform data was getting freed after the binding.
It now works fine. Thanks for your help.
--
Dmitry

-- 
With warm regards,
Sachin
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help