From b2a114652940ccf7e9668ad447ca78bf16a31139 Mon Sep 17 00:00:00 2001 From: Jonathan Brassow Date: Thu, 2 Apr 2009 19:55:30 +0100 Subject: dm exception store: separate type from instance Introduce struct dm_exception_store_type. Signed-off-by: Jonathan Brassow Signed-off-by: Alasdair G Kergon --- drivers/md/dm-snap-persistent.c | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) (limited to 'drivers/md/dm-snap-persistent.c') diff --git a/drivers/md/dm-snap-persistent.c b/drivers/md/dm-snap-persistent.c index 936b34e0959..0bbbe3b7431 100644 --- a/drivers/md/dm-snap-persistent.c +++ b/drivers/md/dm-snap-persistent.c @@ -683,12 +683,13 @@ int dm_create_persistent(struct dm_exception_store *store) return -ENOMEM; } - store->destroy = persistent_destroy; - store->read_metadata = persistent_read_metadata; - store->prepare_exception = persistent_prepare_exception; - store->commit_exception = persistent_commit_exception; - store->drop_snapshot = persistent_drop_snapshot; - store->fraction_full = persistent_fraction_full; + store->type.dtr = persistent_destroy; + store->type.read_metadata = persistent_read_metadata; + store->type.prepare_exception = persistent_prepare_exception; + store->type.commit_exception = persistent_commit_exception; + store->type.drop_snapshot = persistent_drop_snapshot; + store->type.fraction_full = persistent_fraction_full; + store->context = ps; return 0; -- cgit v1.2.3