Hi,
I am setting up IPMI for an ATCA board with a pigeon point MMC on it. This
requires the serial driver. I have downloaded the 2.6.18 serial patches and
applied them. There seems to be a problem with some
mutex_lock(&state->mutex) code in the layered driver interface added to
serial_core.c
In particular in the uart_register_ldrv() function there are two places
where the mutex's don't jive
a) a mutex_lock(&state->mutex) is done when a lock of this mutex is still in
effect from two layers up (mutex locked in uart_add_one_port() that calls
uart_configure_port() that calls uart_register_ldrv().
b) the call to uart_ldrv_open() assumes that the state->mutex is unlocked -
but again it has been locked two layers up in uart_add_one_port().
I went back and checked that my 2.6.18 serial_core.c is valid - certainly
appears to be. I did notice that between 2.6.16 and
2.6.17locking/unlocking state->mutex was added to uart_add_one_port().
Taking the
lock/unlock out at this level does remove the contention but doesn't seem
advisable.
Problem a) can be fixed easily as the lock/unlock isn't needed locally in
uart_register_ldrv() when it is already locked. Problem b) isn't as easy to
resolve. I noticed that elsewhere a unlock is done before a call to
uart_ldrv_open(). My current solution is to also wrap the call of
uart_ldrv_open() in uart_register_ldrv() with unlock/lock.
Has the issue been resolved elsewhere already? I browsed the CVS repository
and didn't see any updates.
Thanks
David Jenkins
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Openipmi-developer mailing list
Openipmi-developer@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/openipmi-developer