[sheepdog] [PATCH v4 15/18] collie/farm: implement farm

Liu Yuan namei.unix at gmail.com
Fri May 17 11:02:22 CEST 2013


On 05/17/2013 02:27 PM, Kai Zhang wrote:
> +/* this is used to track the last snapshot of each vdi*/
> +static struct vdi_entry last_snapshots = {
> +	.name = "",
> +	.vdi_size = 0,
> +	.vdi_id = 0,
> +	.snap_id = 0,
> +	.nr_copies = 0,
> +	.list = LIST_HEAD_INIT(last_snapshots.list)
> +
> +};

Use static LIST_HEAD(last_vdi_list) is sufficient. Then you can insert
vdi_entry onto this list.

Thanks,
Yuan




More information about the sheepdog mailing list