feat: (devfs) a new filesystem for device exposure.
[lunaix-os.git] / lunaix-os / kernel / fs / mount.c
index 7b83757e91b26740ac43426bbda421934a226750..486d6954152126b3ddad1e24fdd5a08c3bb00be7 100644 (file)
@@ -233,7 +233,7 @@ __DEFINE_LXSYSCALL4(int,
 
     // By our convention.
     // XXX could we do better?
-    struct device* device = (struct device*)dev->data;
+    struct device* device = (struct device*)dev->inode->data;
 
     if (!(dev->inode->itype & VFS_IFVOLDEV) || !device) {
         errno = ENOTDEV;