Philippe Houdoin <philippe.houdoin@xxxxxxxxx> wrote: > > Nice catch! This seems to be a USB specific error handling, though > > - if > > a file descriptor is actually disconnected, it returns > > B_FILE_ERROR. > How a device driver file descriptor could be ever disconnected? > Someone calling close() on it? No, someone can actually disconnect it using the new and private vfs_disconnect_vnode() function, for example via devfs_unpublish_device(). > > Maybe the ethernet device driver should return B_DEVICE_NOT_FOUND > > in > > this case as well? > Or maybe there is fewer errors that we can accomodate without > considering it's hopeless to continue accessing the device. Beside > B_OK and B_INTERRUPTED, I guess pretty much error returned marks the > death of any hope it would work again fine anytime soon. Probably :-) There is also B_TIMED_OUT, B_BUSY, ..., though. Either way is walking on a fine line. Bye, Axel.