Re: Spinlocks: the saga

Arnaldo Carvalho de Melo (acme@conectiva.com.br)
Wed, 30 Jun 1999 16:25:10 -0300 (EST)


Ivan, take a look at the cyclom2x source code available from kernel
2.3.6+, it manages several logical channels, using spinlocks in a way
that, I think, is similar to your needs in the cyclades Y and Z cards. 8)

- Arnaldo

"A cada canto um grande conselheiro,
Que nos quer governar a cabana, e vinha,
Não sabem governar sua cozinha,
E podem governar o mundo inteiro"

Gregório de Matos (1633-1699)

On Wed, 30 Jun 1999, Linux Lists wrote:

> I'm thinking about the issues of the use of spinlocks in the Cyclades
> async driver. However, I have a very minimal idea on how spinlocks work.
> Before you ask: yes, I've read the Documentation/spinlocks.txt and the
> include/asm/spinlock.h files.
>
> The biggest issue is that we're talking about multiport serial cards,
> which means several devices under one card, one IRQ, and sometimes one
> chip (the CD1400 controls 4 ports simultaneously). Thus, the access
> control should be done in three levels:
>
> - one spinlock for regions that are accessed inside the interrupt handler;
> - one for regions that are specific to each port;
> - one for regions that are specific to each chip;
>
> Plus, these regions overlap, so how to decide which spinlock to use at
> that specific case?? Plus, how to synchronize the spinlock calls?? Plus,
> how to control the spinlock (if needed) from inside interrupt handlers??
>
> Well, I have tons of questions. As I know you're all busy, I'd like (if
> possible) some pointers about spinlocks (if possible, about spinlocks _in
> Linux_ ...). Books, URL's, src code, etc. ... anything is welcome. If you
> are willing to help with the code as well, you're welcome too ... ;)
>
> Can you guys help me ?!?!?
>
> Thanks in advance for your time.
>
> Regards,
> Ivan

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/