summaryrefslogtreecommitdiff
path: root/include/linux
diff options
context:
space:
mode:
authorChristoph Hellwig <hch@lst.de>2003-04-17 19:20:20 -0700
committerJeff Garzik <jgarzik@redhat.com>2003-04-17 19:20:20 -0700
commitd9c7089886925f1b98f2ec0f164e10c6836d9598 (patch)
treecc05ea0e837f1c4a537f157a0ab4da8cfb088203 /include/linux
parent22e07d6617f45d21da61ec18e016fb775619a7a9 (diff)
[PATCH] devfs: cleanup partition handling interaction
Always pass around the pathnames for the devfs entries / directories instead of the devfs_handle_ts. Cleanes up the code massivly.
Diffstat (limited to 'include/linux')
-rw-r--r--include/linux/devfs_fs_kernel.h10
-rw-r--r--include/linux/genhd.h13
-rw-r--r--include/linux/ide.h2
3 files changed, 15 insertions, 10 deletions
diff --git a/include/linux/devfs_fs_kernel.h b/include/linux/devfs_fs_kernel.h
index d926d12e532d..edd3b594e01b 100644
--- a/include/linux/devfs_fs_kernel.h
+++ b/include/linux/devfs_fs_kernel.h
@@ -37,7 +37,9 @@ extern void devfs_unregister_tape(int num);
extern void devfs_create_partitions(struct gendisk *dev);
extern void devfs_create_cdrom(struct gendisk *dev);
extern void devfs_remove_partitions(struct gendisk *dev);
-extern void mount_devfs_fs (void);
+extern void devfs_remove_cdrom(struct gendisk *dev);
+extern void devfs_register_partition(struct gendisk *dev, int part);
+extern void mount_devfs_fs(void);
#else /* CONFIG_DEVFS_FS */
static inline devfs_handle_t devfs_register (devfs_handle_t dir,
const char *name,
@@ -85,6 +87,12 @@ static inline void devfs_create_cdrom(struct gendisk *dev)
static inline void devfs_remove_partitions(struct gendisk *dev)
{
}
+static inline void devfs_remove_cdrom(struct gendisk *dev)
+{
+}
+static inline void devfs_register_partition(struct gendisk *dev, int part)
+{
+}
static inline void mount_devfs_fs (void)
{
return;
diff --git a/include/linux/genhd.h b/include/linux/genhd.h
index e015f567e226..c2432bd349e5 100644
--- a/include/linux/genhd.h
+++ b/include/linux/genhd.h
@@ -55,12 +55,13 @@ struct partition {
} __attribute__((packed));
#ifdef __KERNEL__
-# include <linux/devfs_fs_kernel.h>
-
+#include <linux/devfs_fs_kernel.h> /* we don't need any devfs crap
+ here, but some of the implicitly
+ included headers. will clean
+ this mess up later. --hch */
struct hd_struct {
sector_t start_sect;
sector_t nr_sects;
- devfs_handle_t de; /* primary (master) devfs entry */
struct kobject kobj;
unsigned reads, read_sectors, writes, write_sectors;
int policy;
@@ -68,7 +69,6 @@ struct hd_struct {
#define GENHD_FL_REMOVABLE 1
#define GENHD_FL_DRIVERFS 2
-#define GENHD_FL_DEVFS 4
#define GENHD_FL_CD 8
#define GENHD_FL_UP 16
@@ -96,9 +96,8 @@ struct gendisk {
sector_t capacity;
int flags;
- int number; /* devfs crap */
- devfs_handle_t de; /* more of the same */
- devfs_handle_t disk_de; /* piled higher and deeper */
+ char devfs_name[64]; /* devfs crap */
+ int number; /* more of the same */
struct device *driverfs_dev;
struct kobject kobj;
diff --git a/include/linux/ide.h b/include/linux/ide.h
index 0a36483ba085..1e678d06373b 100644
--- a/include/linux/ide.h
+++ b/include/linux/ide.h
@@ -13,7 +13,6 @@
#include <linux/hdsmart.h>
#include <linux/blkdev.h>
#include <linux/proc_fs.h>
-#include <linux/devfs_fs_kernel.h>
#include <linux/interrupt.h>
#include <linux/bitops.h>
#include <linux/bio.h>
@@ -700,7 +699,6 @@ typedef struct ide_drive_s {
struct proc_dir_entry *proc; /* /proc/ide/ directory entry */
struct ide_settings_s *settings;/* /proc/ide/ drive settings */
char devfs_name[64]; /* devfs crap */
- devfs_handle_t de; /* will go away soon */
struct hwif_s *hwif; /* actually (ide_hwif_t *) */