diff options
author | Linus Torvalds <torvalds@g5.osdl.org> | 2006-06-29 14:19:21 -0700 |
---|---|---|
committer | Linus Torvalds <torvalds@g5.osdl.org> | 2006-06-29 14:19:21 -0700 |
commit | 602cada851b28c5792339786efe872fbdc1f5d41 (patch) | |
tree | 233d474b74d6038b5bb54a07ad91dd1bb10b0218 /fs/devfs/util.c | |
parent | 82991c6f2c361acc17279b8124d9bf1878973435 (diff) | |
parent | fee68d1cc0d9bd863e51c16cdcd707737b16bb38 (diff) |
Merge git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/devfs-2.6
* git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/devfs-2.6: (22 commits)
[PATCH] devfs: Remove it from the feature_removal.txt file
[PATCH] devfs: Last little devfs cleanups throughout the kernel tree.
[PATCH] devfs: Rename TTY_DRIVER_NO_DEVFS to TTY_DRIVER_DYNAMIC_DEV
[PATCH] devfs: Remove the tty_driver devfs_name field as it's no longer needed
[PATCH] devfs: Remove the line_driver devfs_name field as it's no longer needed
[PATCH] devfs: Remove the videodevice devfs_name field as it's no longer needed
[PATCH] devfs: Remove the gendisk devfs_name field as it's no longer needed
[PATCH] devfs: Remove the miscdevice devfs_name field as it's no longer needed
[PATCH] devfs: Remove the devfs_fs_kernel.h file from the tree
[PATCH] devfs: Remove devfs_remove() function from the kernel tree
[PATCH] devfs: Remove devfs_mk_cdev() function from the kernel tree
[PATCH] devfs: Remove devfs_mk_bdev() function from the kernel tree
[PATCH] devfs: Remove devfs_mk_symlink() function from the kernel tree
[PATCH] devfs: Remove devfs_mk_dir() function from the kernel tree
[PATCH] devfs: Remove devfs_*_tape() functions from the kernel tree
[PATCH] devfs: Remove devfs support from the sound subsystem
[PATCH] devfs: Remove devfs support from the ide subsystem.
[PATCH] devfs: Remove devfs support from the serial subsystem
[PATCH] devfs: Remove devfs from the init code
[PATCH] devfs: Remove devfs from the partition code
...
Diffstat (limited to 'fs/devfs/util.c')
-rw-r--r-- | fs/devfs/util.c | 97 |
1 files changed, 0 insertions, 97 deletions
diff --git a/fs/devfs/util.c b/fs/devfs/util.c deleted file mode 100644 index db06d388c9a..00000000000 --- a/fs/devfs/util.c +++ /dev/null @@ -1,97 +0,0 @@ -/* devfs (Device FileSystem) utilities. - - Copyright (C) 1999-2002 Richard Gooch - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Library General Public - License as published by the Free Software Foundation; either - version 2 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Library General Public License for more details. - - You should have received a copy of the GNU Library General Public - License along with this library; if not, write to the Free - Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. - - Richard Gooch may be reached by email at rgooch@atnf.csiro.au - The postal address is: - Richard Gooch, c/o ATNF, P. O. Box 76, Epping, N.S.W., 2121, Australia. - - ChangeLog - - 19991031 Richard Gooch <rgooch@atnf.csiro.au> - Created. - 19991103 Richard Gooch <rgooch@atnf.csiro.au> - Created <_devfs_convert_name> and supported SCSI and IDE CD-ROMs - 20000203 Richard Gooch <rgooch@atnf.csiro.au> - Changed operations pointer type to void *. - 20000621 Richard Gooch <rgooch@atnf.csiro.au> - Changed interface to <devfs_register_series>. - 20000622 Richard Gooch <rgooch@atnf.csiro.au> - Took account of interface change to <devfs_mk_symlink>. - Took account of interface change to <devfs_mk_dir>. - 20010519 Richard Gooch <rgooch@atnf.csiro.au> - Documentation cleanup. - 20010709 Richard Gooch <rgooch@atnf.csiro.au> - Created <devfs_*alloc_major> and <devfs_*alloc_devnum>. - 20010710 Richard Gooch <rgooch@atnf.csiro.au> - Created <devfs_*alloc_unique_number>. - 20010730 Richard Gooch <rgooch@atnf.csiro.au> - Documentation typo fix. - 20010806 Richard Gooch <rgooch@atnf.csiro.au> - Made <block_semaphore> and <char_semaphore> private. - 20010813 Richard Gooch <rgooch@atnf.csiro.au> - Fixed bug in <devfs_alloc_unique_number>: limited to 128 numbers - 20010818 Richard Gooch <rgooch@atnf.csiro.au> - Updated major masks up to Linus' "no new majors" proclamation. - Block: were 126 now 122 free, char: were 26 now 19 free. - 20020324 Richard Gooch <rgooch@atnf.csiro.au> - Fixed bug in <devfs_alloc_unique_number>: was clearing beyond - bitfield. - 20020326 Richard Gooch <rgooch@atnf.csiro.au> - Fixed bitfield data type for <devfs_*alloc_devnum>. - Made major bitfield type and initialiser 64 bit safe. - 20020413 Richard Gooch <rgooch@atnf.csiro.au> - Fixed shift warning on 64 bit machines. - 20020428 Richard Gooch <rgooch@atnf.csiro.au> - Copied and used macro for error messages from fs/devfs/base.c - 20021013 Richard Gooch <rgooch@atnf.csiro.au> - Documentation fix. - 20030101 Adam J. Richter <adam@yggdrasil.com> - Eliminate DEVFS_SPECIAL_{CHR,BLK}. Use mode_t instead. - 20030106 Christoph Hellwig <hch@infradead.org> - Rewrite devfs_{,de}alloc_devnum to look like C code. -*/ -#include <linux/module.h> -#include <linux/init.h> -#include <linux/devfs_fs_kernel.h> -#include <linux/slab.h> -#include <linux/vmalloc.h> -#include <linux/genhd.h> -#include <linux/bitops.h> - -int devfs_register_tape(const char *name) -{ - char tname[32], dest[64]; - static unsigned int tape_counter; - unsigned int n = tape_counter++; - - sprintf(dest, "../%s", name); - sprintf(tname, "tapes/tape%u", n); - devfs_mk_symlink(tname, dest); - - return n; -} - -EXPORT_SYMBOL(devfs_register_tape); - -void devfs_unregister_tape(int num) -{ - if (num >= 0) - devfs_remove("tapes/tape%u", num); -} - -EXPORT_SYMBOL(devfs_unregister_tape); |