summaryrefslogtreecommitdiff
path: root/include/linux
diff options
context:
space:
mode:
authorAlexander Viro <viro@math.psu.edu>2002-09-29 23:22:56 -0700
committerLinus Torvalds <torvalds@penguin.transmeta.com>2002-09-29 23:22:56 -0700
commit2e26b412565b54685c270389bf8cf0423c013de4 (patch)
treeae307c10597290f19250da2d272a9fd786f3f592 /include/linux
parentdb5605b280c12f2df378a40fac7602d0e950c302 (diff)
[PATCH] alloc_disk/put_disk
Beginning of proper refcounting. New helpers introduced, several drivers switched to using them for dynamic allocation of gendisks. Once everything is switched (and that will be way easier than per-drive gendisks series) we will be able to add sane reference counts on gendisk, at which point we can safely put pointer to gendisk in struct block_device / struct request and we had pretty much won - from that point it's pretty straightforward crapectomy in drivers.
Diffstat (limited to 'include/linux')
-rw-r--r--include/linux/genhd.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/include/linux/genhd.h b/include/linux/genhd.h
index 7cca9efd336a..3c7d1c358f5b 100644
--- a/include/linux/genhd.h
+++ b/include/linux/genhd.h
@@ -262,6 +262,9 @@ char *disk_name (struct gendisk *hd, int part, char *buf);
extern int rescan_partitions(struct gendisk *disk, struct block_device *bdev);
extern void update_partition(struct gendisk *disk, int part);
+extern struct gendisk *alloc_disk(void);
+extern void put_disk(struct gendisk *disk);
+
/* will go away */
extern void blk_set_probe(int major, struct gendisk *(p)(int));