Skip to content

Commit

Permalink
Driver core: remove subsys_put()
Browse files Browse the repository at this point in the history
There are no more subsystems, it's a kset now so remove the function and
the only two users, which are in the driver core.


Signed-off-by: Greg Kroah-Hartman <[email protected]>
  • Loading branch information
gregkh committed Oct 12, 2007
1 parent 27f20e5 commit 6e9d930
Show file tree
Hide file tree
Showing 4 changed files with 3 additions and 8 deletions.
2 changes: 1 addition & 1 deletion drivers/base/bus.c
Original file line number Diff line number Diff line change
Expand Up @@ -734,7 +734,7 @@ struct bus_type *get_bus(struct bus_type *bus)

void put_bus(struct bus_type * bus)
{
subsys_put(&bus->subsys);
kset_put(&bus->subsys);
}


Expand Down
2 changes: 1 addition & 1 deletion drivers/base/class.c
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ static struct class *class_get(struct class *cls)
static void class_put(struct class * cls)
{
if (cls)
subsys_put(&cls->subsys);
kset_put(&cls->subsys);
}


Expand Down
5 changes: 0 additions & 5 deletions include/linux/kobject.h
Original file line number Diff line number Diff line change
Expand Up @@ -238,11 +238,6 @@ static inline struct kset *subsys_get(struct kset *s)
return NULL;
}

static inline void subsys_put(struct kset *s)
{
kset_put(s);
}

struct subsys_attribute {
struct attribute attr;
ssize_t (*show)(struct kset *, char *);
Expand Down
2 changes: 1 addition & 1 deletion lib/kobject.c
Original file line number Diff line number Diff line change
Expand Up @@ -681,7 +681,7 @@ int subsys_create_file(struct kset *s, struct subsys_attribute *a)

if (subsys_get(s)) {
error = sysfs_create_file(&s->kobj, &a->attr);
subsys_put(s);
kset_put(s);
}
return error;
}
Expand Down

0 comments on commit 6e9d930

Please sign in to comment.