public inbox for lvm2-cvs@sourceware.org
help / color / mirror / Atom feed
From: wysochanski@sourceware.org
To: lvm-devel@redhat.com, lvm2-cvs@sourceware.org
Subject: LVM2 ./WHATS_NEW lib/metadata/metadata-exporte ...
Date: Fri, 12 Oct 2007 14:08:00 -0000	[thread overview]
Message-ID: <20071012140810.3921.qmail@sourceware.org> (raw)

CVSROOT:	/cvs/lvm2
Module name:	LVM2
Changes by:	wysochanski@sourceware.org	2007-10-12 14:08:10

Modified files:
	.              : WHATS_NEW 
	lib/metadata   : metadata-exported.h metadata.c metadata.h 

Log message:
	Accessor functions for PV will not modify the given PV.
	So we can add 'const' to it.
	Patch by Jun'ichi Nomura <j-nomura@ce.jp.nec.com>

Patches:
http://sourceware.org/cgi-bin/cvsweb.cgi/LVM2/WHATS_NEW.diff?cvsroot=lvm2&r1=1.718&r2=1.719
http://sourceware.org/cgi-bin/cvsweb.cgi/LVM2/lib/metadata/metadata-exported.h.diff?cvsroot=lvm2&r1=1.18&r2=1.19
http://sourceware.org/cgi-bin/cvsweb.cgi/LVM2/lib/metadata/metadata.c.diff?cvsroot=lvm2&r1=1.136&r2=1.137
http://sourceware.org/cgi-bin/cvsweb.cgi/LVM2/lib/metadata/metadata.h.diff?cvsroot=lvm2&r1=1.171&r2=1.172

--- LVM2/WHATS_NEW	2007/10/10 11:31:21	1.718
+++ LVM2/WHATS_NEW	2007/10/12 14:08:10	1.719
@@ -1,5 +1,7 @@
 Version 2.02.29 -
 ==================================
+  Add const attributes to pv accessor functions.
+  Refactor vg_add_snapshot and lv_create_empty.
   Handle new sysfs subsystem/block/devices directory structure.
   Tests are run with LVM_SYSTEM_DIR pointing to private root and /dev dirs.
   Fix a bug in lvm_dump.sh checks for lvm/dmsetup binaries.
--- LVM2/lib/metadata/metadata-exported.h	2007/10/11 19:20:38	1.18
+++ LVM2/lib/metadata/metadata-exported.h	2007/10/12 14:08:10	1.19
@@ -468,15 +468,15 @@
 /*
 * Begin skeleton for external LVM library
 */
-struct device *pv_dev(pv_t *pv);
-const char *pv_vg_name(pv_t *pv);
-uint64_t pv_size(pv_t *pv);
-uint32_t pv_status(pv_t *pv);
-uint32_t pv_pe_size(pv_t *pv);
-uint64_t pv_pe_start(pv_t *pv);
-uint32_t pv_pe_count(pv_t *pv);
-uint32_t pv_pe_alloc_count(pv_t *pv);
+struct device *pv_dev(const pv_t *pv);
+const char *pv_vg_name(const pv_t *pv);
+uint64_t pv_size(const pv_t *pv);
+uint32_t pv_status(const pv_t *pv);
+uint32_t pv_pe_size(const pv_t *pv);
+uint64_t pv_pe_start(const pv_t *pv);
+uint32_t pv_pe_count(const pv_t *pv);
+uint32_t pv_pe_alloc_count(const pv_t *pv);
 
-uint32_t vg_status(vg_t *vg);
+uint32_t vg_status(const vg_t *vg);
 
 #endif
--- LVM2/lib/metadata/metadata.c	2007/09/17 16:02:46	1.136
+++ LVM2/lib/metadata/metadata.c	2007/10/12 14:08:10	1.137
@@ -1927,62 +1927,62 @@
 /*
  * Gets/Sets for external LVM library
  */
-struct id pv_id(pv_t *pv)
+struct id pv_id(const pv_t *pv)
 {
 	return pv_field(pv, id);
 }
 
-const struct format_type *pv_format_type(pv_t *pv)
+const struct format_type *pv_format_type(const pv_t *pv)
 {
 	return pv_field(pv, fmt);
 }
 
-struct id pv_vgid(pv_t *pv)
+struct id pv_vgid(const pv_t *pv)
 {
 	return pv_field(pv, vgid);
 }
 
-struct device *pv_dev(pv_t *pv)
+struct device *pv_dev(const pv_t *pv)
 {
 	return pv_field(pv, dev);
 }
 
-const char *pv_vg_name(pv_t *pv)
+const char *pv_vg_name(const pv_t *pv)
 {
 	return pv_field(pv, vg_name);
 }
 
-uint64_t pv_size(pv_t *pv)
+uint64_t pv_size(const pv_t *pv)
 {
 	return pv_field(pv, size);
 }
 
-uint32_t pv_status(pv_t *pv)
+uint32_t pv_status(const pv_t *pv)
 {
 	return pv_field(pv, status);
 }
 
-uint32_t pv_pe_size(pv_t *pv)
+uint32_t pv_pe_size(const pv_t *pv)
 {
 	return pv_field(pv, pe_size);
 }
 
-uint64_t pv_pe_start(pv_t *pv)
+uint64_t pv_pe_start(const pv_t *pv)
 {
 	return pv_field(pv, pe_start);
 }
 
-uint32_t pv_pe_count(pv_t *pv)
+uint32_t pv_pe_count(const pv_t *pv)
 {
 	return pv_field(pv, pe_count);
 }
 
-uint32_t pv_pe_alloc_count(pv_t *pv)
+uint32_t pv_pe_alloc_count(const pv_t *pv)
 {
 	return pv_field(pv, pe_alloc_count);
 }
 
-uint32_t vg_status(vg_t *vg)
+uint32_t vg_status(const vg_t *vg)
 {
 	return vg->status;
 }
--- LVM2/lib/metadata/metadata.h	2007/08/20 20:55:26	1.171
+++ LVM2/lib/metadata/metadata.h	2007/10/12 14:08:10	1.172
@@ -304,9 +304,9 @@
 /*
  * Begin skeleton for external LVM library
  */
-struct id pv_id(pv_t *pv);
-const struct format_type *pv_format_type(pv_t *pv);
-struct id pv_vgid(pv_t *pv);
+struct id pv_id(const pv_t *pv);
+const struct format_type *pv_format_type(const pv_t *pv);
+struct id pv_vgid(const pv_t *pv);
 
 pv_t *pv_by_path(struct cmd_context *cmd, const char *pv_name);
 int add_pv_to_vg(struct volume_group *vg, const char *pv_name,


             reply	other threads:[~2007-10-12 14:08 UTC|newest]

Thread overview: 31+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-10-12 14:08 wysochanski [this message]
  -- strict thread matches above, loose matches on Subject: below --
2011-12-01  0:09 jbrassow
2011-10-28 20:12 zkabelac
2011-10-07 14:56 jbrassow
2011-09-14  9:57 zkabelac
2011-09-07  8:34 zkabelac
2011-08-18 19:43 jbrassow
2011-08-18 19:34 jbrassow
2011-03-11 14:56 prajnoha
2011-03-02 20:00 mbroz
2011-02-25 14:02 prajnoha
2010-05-21 14:07 zkabelac
2010-05-21 12:55 zkabelac
2010-05-21 12:52 zkabelac
2010-05-14 15:19 jbrassow
2010-03-16 15:30 agk
2010-03-16 14:37 agk
2009-07-14  2:19 wysochanski
2009-06-05 20:00 mbroz
2009-06-01 14:43 mbroz
2009-02-03 16:19 wysochanski
2008-04-23 14:33 wysochanski
2008-02-13 20:01 meyering
2008-01-18 22:02 agk
2008-01-16 18:15 agk
2008-01-07 20:42 mbroz
2007-11-15  2:20 agk
2007-09-20 21:39 wysochanski
2007-08-30 20:30 wysochanski
2007-08-21 17:38 wysochanski
2007-07-23 17:27 wysochanski

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20071012140810.3921.qmail@sourceware.org \
    --to=wysochanski@sourceware.org \
    --cc=lvm-devel@redhat.com \
    --cc=lvm2-cvs@sourceware.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).