DEVFS - fix possible panic on devfs_release_ops
authorAlex Hornung <ahornung@gmail.com>
Tue, 18 Aug 2009 22:24:42 +0000 (23:24 +0100)
committerAlex Hornung <ahornung@gmail.com>
Wed, 19 Aug 2009 06:00:44 +0000 (07:00 +0100)
commit176de024db39b6b6296d3c52d83a9a696cbb8b9f
treeb988f77db7b63fe7f867b0e122a251c1aeef6785
parent607b0ed9996ff01a2081718e6a3f2b3d1b3e609c
DEVFS - fix possible panic on devfs_release_ops

* under certain conditions on unloading a module it could happen that
  the memory containing the dev_ops was released before devfs_release_
  ops could happen due to the asynchronous nature of destroy_dev.
  Fix this saving only a pointer to the ops and not using it to store
  anything but rather use a local tailq for reference counting the
  dev_ops.
sys/sys/devfs.h
sys/vfs/devfs/devfs_core.c