projects
/
powerpc.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Pull bugzilla-8066 into release branch
[powerpc.git]
/
fs
/
partitions
/
check.c
diff --git
a/fs/partitions/check.c
b/fs/partitions/check.c
index
ac32a2e
..
e46d237
100644
(file)
--- a/
fs/partitions/check.c
+++ b/
fs/partitions/check.c
@@
-180,7
+180,7
@@
check_partition(struct gendisk *hd, struct block_device *bdev)
}
if (res > 0)
return state;
}
if (res > 0)
return state;
- if (
!
err)
+ if (err)
/* The partition is unrecognized. So report I/O errors if there were any */
res = err;
if (!res)
/* The partition is unrecognized. So report I/O errors if there were any */
res = err;
if (!res)
@@
-358,8
+358,7
@@
void delete_partition(struct gendisk *disk, int part)
p->ios[0] = p->ios[1] = 0;
p->sectors[0] = p->sectors[1] = 0;
sysfs_remove_link(&p->kobj, "subsystem");
p->ios[0] = p->ios[1] = 0;
p->sectors[0] = p->sectors[1] = 0;
sysfs_remove_link(&p->kobj, "subsystem");
- if (p->holder_dir)
- kobject_unregister(p->holder_dir);
+ kobject_unregister(p->holder_dir);
kobject_uevent(&p->kobj, KOBJ_REMOVE);
kobject_del(&p->kobj);
kobject_put(&p->kobj);
kobject_uevent(&p->kobj, KOBJ_REMOVE);
kobject_del(&p->kobj);
kobject_put(&p->kobj);
@@
-603,10
+602,8
@@
void del_gendisk(struct gendisk *disk)
disk->stamp = 0;
kobject_uevent(&disk->kobj, KOBJ_REMOVE);
disk->stamp = 0;
kobject_uevent(&disk->kobj, KOBJ_REMOVE);
- if (disk->holder_dir)
- kobject_unregister(disk->holder_dir);
- if (disk->slave_dir)
- kobject_unregister(disk->slave_dir);
+ kobject_unregister(disk->holder_dir);
+ kobject_unregister(disk->slave_dir);
if (disk->driverfs_dev) {
char *disk_name = make_block_name(disk);
sysfs_remove_link(&disk->kobj, "device");
if (disk->driverfs_dev) {
char *disk_name = make_block_name(disk);
sysfs_remove_link(&disk->kobj, "device");