> +     tport = &state->port;
> +     if (!(tport->flags & ASYNC_INITIALIZED) && port->ops->poll_init) {
> +             mutex_lock(&tport->mutex);
> +             ret = port->ops->poll_init(port);
> +             /*
> +              * We don't set ASYNCB_INITIALIZED as we only initialized the
> +              * hw, e.g. state->xmit is still uninitialized.
> +              */
> +             mutex_unlock(&tport->mutex);
> +             if (ret)
> +                     return ret;
> +     }

What stops a parallel open or close changing ASYNC_INITIALIZED after you
test and before you lock ?

Alan

------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
_______________________________________________
Kgdb-bugreport mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/kgdb-bugreport

Reply via email to