2006-02-01 05:28:18

by Arjan van de Ven

[permalink] [raw]
Subject: Re: + update-mm-acx-driver-to-version-0331.patch added to -mm tree


> -struct wlandevice {
> +struct acx_device {
> + /* most frequent accesses first (dereferencing and cache line!) */
> +
> + /*** Locking ***/
> + struct semaphore sem;
> + spinlock_t lock;
> +#if defined(PARANOID_LOCKING) /* Lock debugging */
> + const char *last_sem;
> + const char *last_lock;
> + unsigned long sem_time;
> + unsigned long lock_time;
> +#endif
> +

any chance of turning this into a mutex instead?
(and you get some of the debugging for free instead that way)


2006-02-01 07:07:41

by Denis Vlasenko

[permalink] [raw]
Subject: Re: + update-mm-acx-driver-to-version-0331.patch added to -mm tree

On Wednesday 01 February 2006 07:28, Arjan van de Ven wrote:
>
> > -struct wlandevice {
> > +struct acx_device {
> > + /* most frequent accesses first (dereferencing and cache line!) */
> > +
> > + /*** Locking ***/
> > + struct semaphore sem;
> > + spinlock_t lock;
> > +#if defined(PARANOID_LOCKING) /* Lock debugging */
> > + const char *last_sem;
> > + const char *last_lock;
> > + unsigned long sem_time;
> > + unsigned long lock_time;
> > +#endif
> > +
>
> any chance of turning this into a mutex instead?
> (and you get some of the debugging for free instead that way)

(/me is reading Ingo's docs...)

Nice :)

Yes, we will do the conversion later. For now we want our driver
usable on vanilla 2.6.10.
--
vda