diff options
Diffstat (limited to 'drivers/md/dm-core.h')
-rw-r--r-- | drivers/md/dm-core.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/drivers/md/dm-core.h b/drivers/md/dm-core.h index 8ef780a6baae..6c6bd24774f2 100644 --- a/drivers/md/dm-core.h +++ b/drivers/md/dm-core.h @@ -226,6 +226,13 @@ struct dm_table { #endif }; +static inline struct dm_target *dm_table_get_target(struct dm_table *t, + unsigned int index) +{ + BUG_ON(index >= t->num_targets); + return t->targets + index; +} + /* * One of these is allocated per clone bio. */ |