diff options
author | Artem Bityutskiy <Artem.Bityutskiy@nokia.com> | 2007-12-16 09:59:31 -0500 |
---|---|---|
committer | Artem Bityutskiy <Artem.Bityutskiy@nokia.com> | 2007-12-26 12:15:17 -0500 |
commit | 9f961b57568960a150cc9781c52824c9093a0514 (patch) | |
tree | 345d60347d63bdc9973a2447d84024776b73dd2f /drivers/mtd/ubi/ubi.h | |
parent | 16f557ecbf96dd13d13788a6f62d4d97ae73b1f9 (diff) |
UBI: add UBI control device
This patch is a preparation to make UBI devices dynamic. It
adds an UBI control device which has dynamically allocated
major number and registers itself as "ubi_ctrl". It does not
do anything so far. The idea is that this device will allow
to attach/detach MTD devices from userspace.
This is symilar to what the Linux device mapper has.
The next things to do are:
* Fix UBI, because it now assumes UBI devices cannot go away
* Implement control device ioctls which will attach/detach MTD
devices
Signed-off-by: Artem Bityutskiy <Artem.Bityutskiy@nokia.com>
Diffstat (limited to 'drivers/mtd/ubi/ubi.h')
-rw-r--r-- | drivers/mtd/ubi/ubi.h | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/mtd/ubi/ubi.h b/drivers/mtd/ubi/ubi.h index 994233d6e1e3..21c028366fd2 100644 --- a/drivers/mtd/ubi/ubi.h +++ b/drivers/mtd/ubi/ubi.h | |||
@@ -235,7 +235,7 @@ struct ubi_wl_entry; | |||
235 | 235 | ||
236 | /** | 236 | /** |
237 | * struct ubi_device - UBI device description structure | 237 | * struct ubi_device - UBI device description structure |
238 | * @dev: class device object to use the the Linux device model | 238 | * @dev: UBI device object to use the the Linux device model |
239 | * @cdev: character device object to create character device | 239 | * @cdev: character device object to create character device |
240 | * @ubi_num: UBI device number | 240 | * @ubi_num: UBI device number |
241 | * @ubi_name: UBI device name | 241 | * @ubi_name: UBI device name |
@@ -398,6 +398,7 @@ struct ubi_device { | |||
398 | 398 | ||
399 | extern struct kmem_cache *ubi_ltree_slab; | 399 | extern struct kmem_cache *ubi_ltree_slab; |
400 | extern struct kmem_cache *ubi_wl_entry_slab; | 400 | extern struct kmem_cache *ubi_wl_entry_slab; |
401 | extern struct file_operations ubi_ctrl_cdev_operations; | ||
401 | extern struct file_operations ubi_cdev_operations; | 402 | extern struct file_operations ubi_cdev_operations; |
402 | extern struct file_operations ubi_vol_cdev_operations; | 403 | extern struct file_operations ubi_vol_cdev_operations; |
403 | extern struct ubi_device *ubi_devices[]; | 404 | extern struct ubi_device *ubi_devices[]; |