Current-Users archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: pcic kthread creation timing



On Fri, Jul 18, 2008 at 01:22:22AM +0900, KIYOHARA Takashi wrote:
> current pcic at isa calls:
>   pcic_isa_attach()
>     +- pcic_attach_sockets()
>     |    +- pcic_attach_sockets()
>     |         +- pcic_attach_socket()
>     |         +- config_pending_incr()
>     |         +- kthread_create(pcic_event_thread)
>     +- config_interrupts(pcic_isa_config_interrupts)
>   :
>   (new thread)
>     pcic_event_thread()
>       +- (check for card presence)
>       +- config_pending_decr()                        <-- Oops!
>       +- tsleep()
>   :
>   pcic_isa_config_interrupts()
>     +- isa_intr_establish()
>     +- pcic_attach_sockets_finish()
>          +- pcic_attach_socket_finish()
>               +- (socket reset)
>   :
>   Mount the root file system.  (But not found yet!!)
> 
>   :
>   :
>   Maybe occur the interrupt of card detect.
> 
> 
> I was misunderstanding it a little.  I think this problem is to have
> called config_pending_decr() before establish interrupt (and reset
> socket).
> 
> Then, I propose that pcic_attach_socket_finish() call kthread_create().

Hello, Kiyohara-san!

Thanks for the clarification a bit more explanation... I think that is
the right way to fix this, yes.

Sorry for adding confusion in my original response... I mis-understood what
you were prosing (and hadn't looked at the differences between the SA-11xx
PCIC code and the generic i82365 code, which didn't help ;)).

Thanks for looking at this,
--rafal

-- 
  Time is an illusion; lunchtime, doubly so.     |/\/\|           Rafal Boni
                   -- Ford Prefect               |\/\/|      
rafal%pobox.com@localhost


Home | Main Index | Thread Index | Old Index