1
0
mirror of git://sourceware.org/git/lvm2.git synced 2025-01-03 05:18:29 +03:00
lvm2/lib/activate/ll-activate.h
Joe Thornber 6d52fb460b o Split activate.c into a high level (remaining in activate.c) and low level (ll-activate.[hc]) API.
o  Creation of a device from an lv now lives in activate-lv.c
2002-02-11 15:48:34 +00:00

62 lines
1.3 KiB
C

/*
* Copyright (C) 2002 Sistina Software (UK) Limited.
*
* This file is released under the LGPL.
*/
#ifndef _LVM_LL_ACTIVATE_H
#define _LVM_LL_ACTIVATE_H
#include "metadata.h"
#include <libdevmapper.h>
/*
* Prepares a new dm_task.
*/
struct dm_task *setup_dm_task(const char *name, int task);
/*
* Query functions. 'name' is the device node name in the
* device-mapper dir.
*/
int device_info(const char *name, struct dm_info *info);
int device_active(const char *name);
int device_suspended(const char *name);
int device_open_count(const char *name);
/*
* Functions to manipulate an already active device.
*/
int device_deactivate(const char *name);
int device_suspend(const char *name);
int device_resume(const char *name);
/*
* Creates a device with a mapping table as specified by the lv.
*/
int device_create_lv(const char *name, struct logical_volume *lv, int minor);
int device_reload_lv(const char *name, struct logical_volume *lv);
/*
* Layers the origin device above an already active 'real'
* device.
*/
int device_create_origin(struct logical_volume *lv,
const char *real, int minor);
/*
* Creates a snapshot device for a given origin and exception
* storage area.
*/
int device_create_snapshot(struct logical_volume *lv,
const char *origin, const char *cow_device,
int minor);
#endif