删除设备文件的回调
当设备文件从系统中删除时,linux和solaris设备驱动程序中是否有回调函数会被调用?例如,如果卷管理器删除卷,它会删除该设备的块和字符设备接口。 linux和solaris中是否有像open,close,策略调用这样的回调,当块/字符设备删除完成时会被调用?
Is there in any call back in linux and solaris device driver which will be called when the device file is removed from the system? Example if a volume is deleted by the volume manager, it deletes the block and char device interface for that device. Is there any callback in linux and solaris like open,close,strategy call which will be called when the deletion of block/char device is done?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
设备文件与任何其他文件非常相似,因此您应该能够使用 inotify 来观看对于它们的出现和/或消失。
Device files are much the same as any other file, so you should be able to use inotify to watch for them appearing and/or disappearing.