diff options
Diffstat (limited to 'drivers/md')
-rw-r--r-- | drivers/md/bitmap.c | 8 | ||||
-rw-r--r-- | drivers/md/dm-raid1.c | 9 | ||||
-rw-r--r-- | drivers/md/dm-table.c | 4 | ||||
-rw-r--r-- | drivers/md/md.c | 3 |
4 files changed, 9 insertions, 15 deletions
diff --git a/drivers/md/bitmap.c b/drivers/md/bitmap.c index a0585fb6da94..7aeceedcf7d4 100644 --- a/drivers/md/bitmap.c +++ b/drivers/md/bitmap.c | |||
@@ -206,16 +206,10 @@ static void bitmap_checkfree(struct bitmap *bitmap, unsigned long page) | |||
206 | /* copy the pathname of a file to a buffer */ | 206 | /* copy the pathname of a file to a buffer */ |
207 | char *file_path(struct file *file, char *buf, int count) | 207 | char *file_path(struct file *file, char *buf, int count) |
208 | { | 208 | { |
209 | struct dentry *d; | ||
210 | struct vfsmount *v; | ||
211 | |||
212 | if (!buf) | 209 | if (!buf) |
213 | return NULL; | 210 | return NULL; |
214 | 211 | ||
215 | d = file->f_path.dentry; | 212 | buf = d_path(&file->f_path, buf, count); |
216 | v = file->f_path.mnt; | ||
217 | |||
218 | buf = d_path(d, v, buf, count); | ||
219 | 213 | ||
220 | return IS_ERR(buf) ? NULL : buf; | 214 | return IS_ERR(buf) ? NULL : buf; |
221 | } | 215 | } |
diff --git a/drivers/md/dm-raid1.c b/drivers/md/dm-raid1.c index edc057f5cdcc..51605870f898 100644 --- a/drivers/md/dm-raid1.c +++ b/drivers/md/dm-raid1.c | |||
@@ -124,7 +124,7 @@ enum dm_raid1_error { | |||
124 | struct mirror { | 124 | struct mirror { |
125 | struct mirror_set *ms; | 125 | struct mirror_set *ms; |
126 | atomic_t error_count; | 126 | atomic_t error_count; |
127 | uint32_t error_type; | 127 | unsigned long error_type; |
128 | struct dm_dev *dev; | 128 | struct dm_dev *dev; |
129 | sector_t offset; | 129 | sector_t offset; |
130 | }; | 130 | }; |
@@ -1695,14 +1695,15 @@ static int mirror_end_io(struct dm_target *ti, struct bio *bio, | |||
1695 | * information for a retry or there was no other | 1695 | * information for a retry or there was no other |
1696 | * mirror in-sync. | 1696 | * mirror in-sync. |
1697 | */ | 1697 | */ |
1698 | DMERR_LIMIT("Mirror read failed from %s.", | 1698 | DMERR_LIMIT("Mirror read failed."); |
1699 | m->dev->name); | ||
1700 | return -EIO; | 1699 | return -EIO; |
1701 | } | 1700 | } |
1701 | |||
1702 | m = read_record->m; | ||
1703 | |||
1702 | DMERR("Mirror read failed from %s. Trying alternative device.", | 1704 | DMERR("Mirror read failed from %s. Trying alternative device.", |
1703 | m->dev->name); | 1705 | m->dev->name); |
1704 | 1706 | ||
1705 | m = read_record->m; | ||
1706 | fail_mirror(m, DM_RAID1_READ_ERROR); | 1707 | fail_mirror(m, DM_RAID1_READ_ERROR); |
1707 | 1708 | ||
1708 | /* | 1709 | /* |
diff --git a/drivers/md/dm-table.c b/drivers/md/dm-table.c index f16062982383..e75b1437b58b 100644 --- a/drivers/md/dm-table.c +++ b/drivers/md/dm-table.c | |||
@@ -361,7 +361,7 @@ static int lookup_device(const char *path, dev_t *dev) | |||
361 | if ((r = path_lookup(path, LOOKUP_FOLLOW, &nd))) | 361 | if ((r = path_lookup(path, LOOKUP_FOLLOW, &nd))) |
362 | return r; | 362 | return r; |
363 | 363 | ||
364 | inode = nd.dentry->d_inode; | 364 | inode = nd.path.dentry->d_inode; |
365 | if (!inode) { | 365 | if (!inode) { |
366 | r = -ENOENT; | 366 | r = -ENOENT; |
367 | goto out; | 367 | goto out; |
@@ -375,7 +375,7 @@ static int lookup_device(const char *path, dev_t *dev) | |||
375 | *dev = inode->i_rdev; | 375 | *dev = inode->i_rdev; |
376 | 376 | ||
377 | out: | 377 | out: |
378 | path_release(&nd); | 378 | path_put(&nd.path); |
379 | return r; | 379 | return r; |
380 | } | 380 | } |
381 | 381 | ||
diff --git a/drivers/md/md.c b/drivers/md/md.c index 5fc326d3970e..7da6ec244e15 100644 --- a/drivers/md/md.c +++ b/drivers/md/md.c | |||
@@ -5197,8 +5197,7 @@ static int md_seq_show(struct seq_file *seq, void *v) | |||
5197 | chunk_kb ? "KB" : "B"); | 5197 | chunk_kb ? "KB" : "B"); |
5198 | if (bitmap->file) { | 5198 | if (bitmap->file) { |
5199 | seq_printf(seq, ", file: "); | 5199 | seq_printf(seq, ", file: "); |
5200 | seq_path(seq, bitmap->file->f_path.mnt, | 5200 | seq_path(seq, &bitmap->file->f_path, " \t\n"); |
5201 | bitmap->file->f_path.dentry," \t\n"); | ||
5202 | } | 5201 | } |
5203 | 5202 | ||
5204 | seq_printf(seq, "\n"); | 5203 | seq_printf(seq, "\n"); |