~ubuntu-branches/debian/stretch/lvm2/stretch

« back to all changes in this revision

Viewing changes to lib/activate/activate.h

  • Committer: Bazaar Package Importer
  • Author(s): Bastian Blank
  • Date: 2011-08-27 18:45:21 UTC
  • mfrom: (1.1.12 upstream)
  • Revision ID: james.westby@ubuntu.com-20110827184521-8lpc2gqp2ybhplzj
Tags: 2.02.86-1
* New upstream version.
* Remove leading article from short description.
* Update udev rules.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
/*
2
2
 * Copyright (C) 2001-2004 Sistina Software, Inc. All rights reserved.  
3
 
 * Copyright (C) 2004-2007 Red Hat, Inc. All rights reserved.
 
3
 * Copyright (C) 2004-2011 Red Hat, Inc. All rights reserved.
4
4
 *
5
5
 * This file is part of LVM2.
6
6
 *
30
30
        uint32_t read_ahead;
31
31
};
32
32
 
 
33
struct lv_activate_opts {
 
34
        int exclusive;
 
35
        int origin_only;
 
36
        int no_merging;
 
37
};
 
38
 
33
39
/* target attribute flags */
34
40
#define MIRROR_LOG_CLUSTERED    0x00000001U
35
41
 
56
62
/* int lv_suspend(struct cmd_context *cmd, const char *lvid_s); */
57
63
int lv_suspend_if_active(struct cmd_context *cmd, const char *lvid_s, unsigned origin_only);
58
64
int lv_resume(struct cmd_context *cmd, const char *lvid_s, unsigned origin_only);
59
 
int lv_resume_if_active(struct cmd_context *cmd, const char *lvid_s, unsigned origin_only);
 
65
int lv_resume_if_active(struct cmd_context *cmd, const char *lvid_s,
 
66
                        unsigned origin_only, unsigned exclusive);
60
67
int lv_activate(struct cmd_context *cmd, const char *lvid_s, int exclusive);
61
68
int lv_activate_with_filter(struct cmd_context *cmd, const char *lvid_s,
62
69
                            int exclusive);
84
91
 * Returns 1 if percent has been set, else 0.
85
92
 */
86
93
int lv_snapshot_percent(const struct logical_volume *lv, percent_t *percent);
87
 
int lv_mirror_percent(struct cmd_context *cmd, struct logical_volume *lv,
 
94
int lv_mirror_percent(struct cmd_context *cmd, const struct logical_volume *lv,
88
95
                      int wait, percent_t *percent, uint32_t *event_nr);
89
96
 
90
97
/*
94
101
int lvs_in_vg_opened(const struct volume_group *vg);
95
102
 
96
103
int lv_is_active(struct logical_volume *lv);
 
104
int lv_is_active_but_not_locally(struct logical_volume *lv);
97
105
int lv_is_active_exclusive_locally(struct logical_volume *lv);
98
106
int lv_is_active_exclusive_remotely(struct logical_volume *lv);
99
107
 
101
109
                       const char *layer, const char *target_type);
102
110
 
103
111
int monitor_dev_for_events(struct cmd_context *cmd, struct logical_volume *lv,
104
 
                           unsigned origin_only, int do_reg);
 
112
                           const struct lv_activate_opts *laopts, int do_reg);
105
113
 
106
114
#ifdef DMEVENTD
107
115
#  include "libdevmapper-event.h"