serial/pty:Don't assert EBUSY when pty unregister driver
Signed-off-by: fangzhenwei <fangzhenwei@xiaomi.com>
This commit is contained in:
parent
88e871b13e
commit
84b88205ab
@ -220,7 +220,7 @@ static int ptmx_open(FAR struct file *filep)
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
ret = unregister_driver(devname);
|
ret = unregister_driver(devname);
|
||||||
DEBUGASSERT(ret >= 0); /* unregister_driver() should never fail */
|
DEBUGASSERT(ret >= 0 || ret == -EBUSY); /* unregister_driver() should never fail */
|
||||||
|
|
||||||
nxsem_post(&g_ptmx.px_exclsem);
|
nxsem_post(&g_ptmx.px_exclsem);
|
||||||
return OK;
|
return OK;
|
||||||
|
Loading…
Reference in New Issue
Block a user