Messages in this thread | | | Subject | Re: question on tty open and close | From | Marcel Holtmann <> | Date | Wed, 28 Mar 2007 16:54:41 +0200 |
| |
Hi Alan,
> > As long as the new behavior continues to call > > driver->close() if driver->open() succeeds > > then I see no problem. > > It breaks if any existing driver is doing no cleanup in ->open() when it > fails but relying upon ->close() being called. That is what needs > auditing first of all.
I know at least that the Bluetooth TTY emulation (RFCOMM) will break since I have a big fat warning in my code:
/* We don't leak this refcount. For reasons which are not entirely clear, the TTY layer will call our ->close() method even if the open fails. We decrease the refcount there, and decreasing it here too would cause breakage. */ dev = rfcomm_dev_get(id); if (!dev) return -ENODEV;
Regards
Marcel
- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
| |