LVM2 ./WHATS_NEW lib/commands/toolcontext.c li ...
CVSROOT: /cvs/lvm2
Module name: LVM2
Changes by: agk at sourceware.org 2009-07-08 12:36:01
Modified files:
. : WHATS_NEW lib/commands : toolcontext.c lib/metadata : segtype.h
Log message:
Permit several segment types to be registered by a single shared object.
Patches:
http://sourceware.org/cgi-bin/cvsweb.cgi/LVM2/WHATS_NEW.diff?cvsroot=lvm2&r1=1.1166&r2=1.1167
http://sourceware.org/cgi-bin/cvsweb.cgi/LVM2/lib/commands/toolcontext.c.diff?cvsroot=lvm2&r1=1.76&r2=1.77
http://sourceware.org/cgi-bin/cvsweb.cgi/LVM2/lib/metadata/segtype.h.diff?cvsroot=lvm2&r1=1.23&r2=1.24
WHATS_NEW +1 -0
@@ -1,5 +1,6 @@ Version 2.02.49 - ================================ + Permit several segment types to be registered by a single shared object. Update the man pages to document size units uniformly. Allow commandline sizes to be specified in terms of bytes and sectors. Update 'md_chunk_alignment' to use stripe-width to align PV data area.
lib/commands/toolcontext.c +89 -27
150 lines not on this page · raw message
lib/metadata/segtype.h +8 -4
@@ -47,13 +47,13 @@#define segtype_is_virtual (segtype) ((segtype)->flags & SEG_VIRTUAL ? 1 : 0)struct segment_type { -struct dm_list list; -struct cmd_context *cmd; +struct dm_list list;/* Internal */ +struct cmd_context *cmd;/* lvm_register_segtype() sets this. */ uint32_t flags;struct segtype_handler *ops;const char *name; -void *library; -void *private; +void *library;/* lvm_register_segtype() sets this. */ +void *private;/* For the segtype handler to use. */ };struct segtype_handler {
@@ -93,6 +93,10 @@struct segment_type *get_segtype_from_string (struct cmd_context *cmd,const char *str); +struct segtype_library ; +int lvm_register_segtype (struct segtype_library *seglib, +struct segment_type *segtype); +struct segment_type *init_striped_segtype (struct cmd_context *cmd);struct segment_type *init_zero_segtype (struct cmd_context *cmd);struct segment_type *init_error_segtype (struct cmd_context *cmd);