mirror of
git://sourceware.org/git/lvm2.git
synced 2024-12-21 13:34:40 +03:00
Some const fixups for previous checkins
This commit is contained in:
parent
0b0c2117af
commit
bf4f5b21a4
@ -1803,7 +1803,7 @@ struct list *build_parallel_areas_from_lv(struct cmd_context *cmd,
|
||||
}
|
||||
|
||||
int lv_remove_single(struct cmd_context *cmd, struct logical_volume *lv,
|
||||
force_t force)
|
||||
const force_t force)
|
||||
{
|
||||
struct volume_group *vg;
|
||||
struct lvinfo info;
|
||||
|
@ -330,7 +330,7 @@ int pv_analyze(struct cmd_context *cmd, const char *pv_name,
|
||||
uint64_t label_sector);
|
||||
|
||||
/* FIXME: move internal to library */
|
||||
uint32_t pv_list_extents_free(struct list *pvh);
|
||||
uint32_t pv_list_extents_free(const struct list *pvh);
|
||||
|
||||
struct volume_group *vg_create(struct cmd_context *cmd, const char *name,
|
||||
uint32_t extent_size, uint32_t max_pv,
|
||||
|
@ -218,8 +218,8 @@ void merge_pv_segments(struct pv_segment *peg1, struct pv_segment *peg2)
|
||||
* Calculate the overlap, in extents, between a struct pv_segment and
|
||||
* a struct pe_range.
|
||||
*/
|
||||
static uint32_t _overlap_pe(struct pv_segment *pvseg,
|
||||
struct pe_range *per)
|
||||
static uint32_t _overlap_pe(const struct pv_segment *pvseg,
|
||||
const struct pe_range *per)
|
||||
{
|
||||
uint32_t start;
|
||||
uint32_t end;
|
||||
@ -235,7 +235,7 @@ static uint32_t _overlap_pe(struct pv_segment *pvseg,
|
||||
/*
|
||||
* Returns: number of free PEs in a struct pv_list
|
||||
*/
|
||||
uint32_t pv_list_extents_free(struct list *pvh)
|
||||
uint32_t pv_list_extents_free(const struct list *pvh)
|
||||
{
|
||||
struct pv_list *pvl;
|
||||
struct pe_range *per;
|
||||
@ -443,7 +443,7 @@ int pv_resize(struct physical_volume *pv,
|
||||
int pv_resize_single(struct cmd_context *cmd,
|
||||
struct volume_group *vg,
|
||||
struct physical_volume *pv,
|
||||
uint64_t new_size)
|
||||
const uint64_t new_size)
|
||||
{
|
||||
struct pv_list *pvl;
|
||||
int consistent = 1;
|
||||
|
@ -244,8 +244,8 @@ static int _read_stripe_params(struct lvcreate_params *lp,
|
||||
* Generic mirror parameter checks.
|
||||
* FIXME: Should eventually be moved into lvm library.
|
||||
*/
|
||||
static int _validate_mirror_params(struct cmd_context *cmd,
|
||||
struct lvcreate_params *lp)
|
||||
static int _validate_mirror_params(const struct cmd_context *cmd,
|
||||
const struct lvcreate_params *lp)
|
||||
{
|
||||
int pagesize = lvm_getpagesize();
|
||||
|
||||
|
@ -47,7 +47,7 @@ struct lvresize_params {
|
||||
};
|
||||
|
||||
static int validate_stripesize(struct cmd_context *cmd,
|
||||
struct volume_group *vg,
|
||||
const struct volume_group *vg,
|
||||
struct lvresize_params *lp)
|
||||
{
|
||||
if (arg_sign_value(cmd, stripesize_ARG, 0) == SIGN_MINUS) {
|
||||
@ -87,9 +87,9 @@ static int validate_stripesize(struct cmd_context *cmd,
|
||||
}
|
||||
|
||||
static int confirm_resizefs_reduce(struct cmd_context *cmd,
|
||||
struct volume_group *vg,
|
||||
struct logical_volume *lv,
|
||||
struct lvresize_params *lp)
|
||||
const struct volume_group *vg,
|
||||
const struct logical_volume *lv,
|
||||
const struct lvresize_params *lp)
|
||||
{
|
||||
struct lvinfo info;
|
||||
|
||||
@ -131,8 +131,9 @@ static int confirm_resizefs_reduce(struct cmd_context *cmd,
|
||||
return 1;
|
||||
}
|
||||
|
||||
static int do_resizefs_reduce(struct cmd_context *cmd, struct volume_group *vg,
|
||||
struct lvresize_params *lp)
|
||||
static int do_resizefs_reduce(const struct cmd_context *cmd,
|
||||
const struct volume_group *vg,
|
||||
const struct lvresize_params *lp)
|
||||
{
|
||||
char lv_path[PATH_MAX];
|
||||
char size_buf[SIZE_BUF];
|
||||
|
Loading…
Reference in New Issue
Block a user