Merge tag 'uninit-macro-v5.9-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git...
[linux-2.6-microblaze.git] / drivers / md / dm-table.c
index 89d7cda..5c4cb0d 100644 (file)
@@ -64,8 +64,6 @@ struct dm_table {
        void *event_context;
 
        struct dm_md_mempools *mempools;
-
-       struct list_head target_callbacks;
 };
 
 /*
@@ -190,7 +188,6 @@ int dm_table_create(struct dm_table **result, fmode_t mode,
                return -ENOMEM;
 
        INIT_LIST_HEAD(&t->devices);
-       INIT_LIST_HEAD(&t->target_callbacks);
 
        if (!num_targets)
                num_targets = KEYS_PER_NODE;
@@ -361,7 +358,7 @@ static int device_area_is_invalid(struct dm_target *ti, struct dm_dev *dev,
  * This upgrades the mode on an already open dm_dev, being
  * careful to leave things as they were if we fail to reopen the
  * device and not to touch the existing bdev field in case
- * it is accessed concurrently inside dm_table_any_congested().
+ * it is accessed concurrently.
  */
 static int upgrade_mode(struct dm_dev_internal *dd, fmode_t new_mode,
                        struct mapped_device *md)
@@ -2052,38 +2049,6 @@ int dm_table_resume_targets(struct dm_table *t)
        return 0;
 }
 
-void dm_table_add_target_callbacks(struct dm_table *t, struct dm_target_callbacks *cb)
-{
-       list_add(&cb->list, &t->target_callbacks);
-}
-EXPORT_SYMBOL_GPL(dm_table_add_target_callbacks);
-
-int dm_table_any_congested(struct dm_table *t, int bdi_bits)
-{
-       struct dm_dev_internal *dd;
-       struct list_head *devices = dm_table_get_devices(t);
-       struct dm_target_callbacks *cb;
-       int r = 0;
-
-       list_for_each_entry(dd, devices, list) {
-               struct request_queue *q = bdev_get_queue(dd->dm_dev->bdev);
-               char b[BDEVNAME_SIZE];
-
-               if (likely(q))
-                       r |= bdi_congested(q->backing_dev_info, bdi_bits);
-               else
-                       DMWARN_LIMIT("%s: any_congested: nonexistent device %s",
-                                    dm_device_name(t->md),
-                                    bdevname(dd->dm_dev->bdev, b));
-       }
-
-       list_for_each_entry(cb, &t->target_callbacks, list)
-               if (cb->congested_fn)
-                       r |= cb->congested_fn(cb, bdi_bits);
-
-       return r;
-}
-
 struct mapped_device *dm_table_get_md(struct dm_table *t)
 {
        return t->md;