Date: Fri, 11 Feb 2011 10:02:58 +0100 From: Alexander Leidinger <Alexander@Leidinger.net> To: geom@freebsd.org Cc: kibab@freebsd.org Subject: Re: CFR: FEATURE macros for GEOM classes (with patch) Message-ID: <20110211100258.18243dlaaz0iulog@webmail.leidinger.net> In-Reply-To: <20110211100047.14771t9tnmafolog@webmail.leidinger.net> References: <20110211100047.14771t9tnmafolog@webmail.leidinger.net>
next in thread | previous in thread | raw e-mail | index | archive | help
This message is in MIME format. --=_30palfo2nku8 Content-Type: text/plain; charset=UTF-8; DelSp="Yes"; format="flowed" Content-Disposition: inline Content-Transfer-Encoding: 7bit Quoting Alexander Leidinger <Alexander@Leidinger.net> (from Fri, 11 Feb 2011 10:00:47 +0100): > Can someone please review if the patch is OK (bikesheds about the > description part need to contain corresponding patches for NOTES, > else we will not take the arguments into account)? It helps to attach the patch... Bye, Alexander. -- The great nations have always acted like gangsters and the small nations like prostitutes. -- Stanley Kubrick http://www.Leidinger.net Alexander @ Leidinger.net: PGP ID = B0063FE7 http://www.FreeBSD.org netchild @ FreeBSD.org : PGP ID = 72077137 --=_30palfo2nku8 Content-Type: text/x-patch; charset=UTF-8; name="features_geom.diff" Content-Disposition: attachment; filename="features_geom.diff" Content-Transfer-Encoding: 7bit Index: geom/label/g_label.c =================================================================== --- geom/label/g_label.c (Revision 218482) +++ geom/label/g_label.c (Arbeitskopie) @@ -36,10 +36,12 @@ #include <sys/bio.h> #include <sys/malloc.h> #include <sys/libkern.h> +#include <sys/sysctl.h> #include <geom/geom.h> #include <geom/geom_slice.h> #include <geom/label/g_label.h> +FEATURE(geom_label, "GEOM labeling support"); SYSCTL_DECL(_kern_geom); SYSCTL_NODE(_kern_geom, OID_AUTO, label, CTLFLAG_RW, 0, "GEOM_LABEL stuff"); Index: geom/gate/g_gate.c =================================================================== --- geom/gate/g_gate.c (Revision 218482) +++ geom/gate/g_gate.c (Arbeitskopie) @@ -53,6 +53,8 @@ #include <geom/geom.h> #include <geom/gate/g_gate.h> +FEATURE(geom_gate, "GEOM Gate module"); + static MALLOC_DEFINE(M_GATE, "gg_data", "GEOM Gate Data"); SYSCTL_DECL(_kern_geom); Index: geom/uzip/g_uzip.c =================================================================== --- geom/uzip/g_uzip.c (Revision 218482) +++ geom/uzip/g_uzip.c (Arbeitskopie) @@ -36,10 +36,13 @@ #include <sys/mutex.h> #include <sys/malloc.h> #include <sys/systm.h> +#include <sys/sysctl.h> #include <geom/geom.h> #include <net/zlib.h> +FEATURE(geom_uzip, "GEOM uzip read-only compressed disks support"); + #undef GEOM_UZIP_DEBUG #ifdef GEOM_UZIP_DEBUG #define DPRINTF(a) printf a Index: geom/geom_sunlabel.c =================================================================== --- geom/geom_sunlabel.c (Revision 218482) +++ geom/geom_sunlabel.c (Arbeitskopie) @@ -39,6 +39,7 @@ #include <sys/param.h> #include <sys/endian.h> #include <sys/systm.h> +#include <sys/sysctl.h> #include <sys/kernel.h> #include <sys/conf.h> #include <sys/bio.h> @@ -51,6 +52,8 @@ #include <geom/geom_slice.h> #include <machine/endian.h> +FEATURE(geom_sunlabel, "GEOM Sun/Solaris partitioning support"); + #define SUNLABEL_CLASS_NAME "SUN" struct g_sunlabel_softc { Index: geom/geom_bsd.c =================================================================== --- geom/geom_bsd.c (Revision 218482) +++ geom/geom_bsd.c (Arbeitskopie) @@ -45,6 +45,7 @@ #include <sys/param.h> #include <sys/endian.h> #include <sys/systm.h> +#include <sys/sysctl.h> #include <sys/kernel.h> #include <sys/fcntl.h> #include <sys/conf.h> @@ -60,6 +61,8 @@ #include <geom/geom.h> #include <geom/geom_slice.h> +FEATURE(geom_bsd, "GEOM BSD disklabels support"); + #define BSD_CLASS_NAME "BSD" #define ALPHA_LABEL_OFFSET 64 Index: geom/cache/g_cache.c =================================================================== --- geom/cache/g_cache.c (Revision 218482) +++ geom/cache/g_cache.c (Arbeitskopie) @@ -42,6 +42,8 @@ #include <geom/geom.h> #include <geom/cache/g_cache.h> +FEATURE(geom_cache, "GEOM cache module"); + static MALLOC_DEFINE(M_GCACHE, "gcache_data", "GEOM_CACHE Data"); SYSCTL_DECL(_kern_geom); Index: geom/mirror/g_mirror.c =================================================================== --- geom/mirror/g_mirror.c (Revision 218482) +++ geom/mirror/g_mirror.c (Arbeitskopie) @@ -45,6 +45,7 @@ #include <sys/sched.h> #include <geom/mirror/g_mirror.h> +FEATURE(geom_mirror, "GEOM mirroring support"); static MALLOC_DEFINE(M_MIRROR, "mirror_data", "GEOM_MIRROR Data"); Index: geom/geom_fox.c =================================================================== --- geom/geom_fox.c (Revision 218482) +++ geom/geom_fox.c (Arbeitskopie) @@ -37,6 +37,7 @@ #include <sys/param.h> #include <sys/systm.h> +#include <sys/sysctl.h> #include <sys/kernel.h> #include <sys/conf.h> #include <sys/bio.h> @@ -52,6 +53,8 @@ #define FOX_CLASS_NAME "FOX" #define FOX_MAGIC "GEOM::FOX" +FEATURE(geom_fox, "GEOM FOX redundant path mitigation support"); + struct g_fox_softc { off_t mediasize; u_int sectorsize; Index: geom/geom_vol_ffs.c =================================================================== --- geom/geom_vol_ffs.c (Revision 218482) +++ geom/geom_vol_ffs.c (Arbeitskopie) @@ -30,6 +30,7 @@ #include <sys/param.h> #include <sys/errno.h> #include <sys/systm.h> +#include <sys/sysctl.h> #include <sys/kernel.h> #include <sys/malloc.h> #include <sys/bio.h> @@ -42,6 +43,8 @@ #include <geom/geom.h> #include <geom/geom_slice.h> +FEATURE(geom_vol, "GEOM support for volume names from UFS superblock"); + #define VOL_FFS_CLASS_NAME "VOL_FFS" static int superblocks[] = SBLOCKSEARCH; Index: geom/bde/g_bde.c =================================================================== --- geom/bde/g_bde.c (Revision 218482) +++ geom/bde/g_bde.c (Arbeitskopie) @@ -41,6 +41,7 @@ #include <sys/systm.h> #include <sys/kernel.h> #include <sys/kthread.h> +#include <sys/sysctl.h> #include <crypto/rijndael/rijndael-api-fst.h> #include <crypto/sha2/sha2.h> @@ -48,6 +49,8 @@ #include <geom/bde/g_bde.h> #define BDE_CLASS_NAME "BDE" +FEATURE(geom_bde, "GEOM-based Disk Encryption"); + static void g_bde_start(struct bio *bp) { Index: geom/raid3/g_raid3.c =================================================================== --- geom/raid3/g_raid3.c (Revision 218482) +++ geom/raid3/g_raid3.c (Arbeitskopie) @@ -45,6 +45,7 @@ #include <sys/sched.h> #include <geom/raid3/g_raid3.h> +FEATURE(geom_raid3, "GEOM RAID-3 functionality"); static MALLOC_DEFINE(M_RAID3, "raid3_data", "GEOM_RAID3 Data"); Index: geom/shsec/g_shsec.c =================================================================== --- geom/shsec/g_shsec.c (Revision 218482) +++ geom/shsec/g_shsec.c (Arbeitskopie) @@ -40,6 +40,7 @@ #include <geom/geom.h> #include <geom/shsec/g_shsec.h> +FEATURE(geom_shsec, "GEOM shared secret device support"); static MALLOC_DEFINE(M_SHSEC, "shsec_data", "GEOM_SHSEC Data"); Index: geom/part/g_part_pc98.c =================================================================== --- geom/part/g_part_pc98.c (Revision 218482) +++ geom/part/g_part_pc98.c (Arbeitskopie) @@ -40,11 +40,14 @@ #include <sys/queue.h> #include <sys/sbuf.h> #include <sys/systm.h> +#include <sys/sysctl.h> #include <geom/geom.h> #include <geom/part/g_part.h> #include "g_part_if.h" +FEATURE(geom_part_pc98, "GEOM partitioning class for PC-9800 disk partitions"); + #define SECSIZE 512 struct g_part_pc98_table { Index: geom/part/g_part_vtoc8.c =================================================================== --- geom/part/g_part_vtoc8.c (Revision 218482) +++ geom/part/g_part_vtoc8.c (Arbeitskopie) @@ -39,12 +39,15 @@ #include <sys/queue.h> #include <sys/sbuf.h> #include <sys/systm.h> +#include <sys/sysctl.h> #include <sys/vtoc.h> #include <geom/geom.h> #include <geom/part/g_part.h> #include "g_part_if.h" +FEATURE(geom_part_vtoc8, "GEOM partitioning class for SMI VTOC8 disk labels"); + struct g_part_vtoc8_table { struct g_part_table base; struct vtoc8 vtoc; Index: geom/part/g_part_bsd.c =================================================================== --- geom/part/g_part_bsd.c (Revision 218482) +++ geom/part/g_part_bsd.c (Arbeitskopie) @@ -40,11 +40,14 @@ #include <sys/queue.h> #include <sys/sbuf.h> #include <sys/systm.h> +#include <sys/sysctl.h> #include <geom/geom.h> #include <geom/part/g_part.h> #include "g_part_if.h" +FEATURE(geom_part_bsd, "GEOM partitioning class for BSD disklabels"); + struct g_part_bsd_table { struct g_part_table base; u_char *bbarea; Index: geom/part/g_part_ebr.c =================================================================== --- geom/part/g_part_ebr.c (Revision 218482) +++ geom/part/g_part_ebr.c (Arbeitskopie) @@ -42,11 +42,19 @@ #include <sys/queue.h> #include <sys/sbuf.h> #include <sys/systm.h> +#include <sys/sysctl.h> #include <geom/geom.h> #include <geom/part/g_part.h> #include "g_part_if.h" +FEATURE(geom_part_ebr, + "GEOM partitioning class for extended boot records support"); +#if defined(GEOM_PART_EBR_COMPAT) +FEATURE(geom_part_ebr_compat, + "GEOM EBR partitioning class: backward-compatible partition names"); +#endif + #define EBRSIZE 512 struct g_part_ebr_table { Index: geom/part/g_part_gpt.c =================================================================== --- geom/part/g_part_gpt.c (Revision 218482) +++ geom/part/g_part_gpt.c (Arbeitskopie) @@ -41,12 +41,15 @@ #include <sys/queue.h> #include <sys/sbuf.h> #include <sys/systm.h> +#include <sys/sysctl.h> #include <sys/uuid.h> #include <geom/geom.h> #include <geom/part/g_part.h> #include "g_part_if.h" +FEATURE(geom_part_gpt, "GEOM partitioning class for GPT partitions support"); + CTASSERT(offsetof(struct gpt_hdr, padding) == 92); CTASSERT(sizeof(struct gpt_ent) == 128); Index: geom/part/g_part_apm.c =================================================================== --- geom/part/g_part_apm.c (Revision 218482) +++ geom/part/g_part_apm.c (Arbeitskopie) @@ -41,11 +41,14 @@ #include <sys/queue.h> #include <sys/sbuf.h> #include <sys/systm.h> +#include <sys/sysctl.h> #include <geom/geom.h> #include <geom/part/g_part.h> #include "g_part_if.h" +FEATURE(geom_part_apm, "GEOM partitioning class for Apple-style partitions"); + struct g_part_apm_table { struct g_part_table base; struct apm_ddr ddr; Index: geom/part/g_part_mbr.c =================================================================== --- geom/part/g_part_mbr.c (Revision 218482) +++ geom/part/g_part_mbr.c (Arbeitskopie) @@ -40,11 +40,14 @@ #include <sys/queue.h> #include <sys/sbuf.h> #include <sys/systm.h> +#include <sys/sysctl.h> #include <geom/geom.h> #include <geom/part/g_part.h> #include "g_part_if.h" +FEATURE(geom_part_mbr, "GEOM partitioning class for MBR support"); + #define MBRSIZE 512 struct g_part_mbr_table { Index: geom/stripe/g_stripe.c =================================================================== --- geom/stripe/g_stripe.c (Revision 218482) +++ geom/stripe/g_stripe.c (Arbeitskopie) @@ -40,6 +40,7 @@ #include <geom/geom.h> #include <geom/stripe/g_stripe.h> +FEATURE(geom_stripe, "GEOM striping support"); static MALLOC_DEFINE(M_STRIPE, "stripe_data", "GEOM_STRIPE Data"); Index: geom/concat/g_concat.c =================================================================== --- geom/concat/g_concat.c (Revision 218482) +++ geom/concat/g_concat.c (Arbeitskopie) @@ -39,6 +39,7 @@ #include <geom/geom.h> #include <geom/concat/g_concat.h> +FEATURE(geom_concat, "GEOM concatenation support"); static MALLOC_DEFINE(M_CONCAT, "concat_data", "GEOM_CONCAT Data"); Index: geom/multipath/g_multipath.c =================================================================== --- geom/multipath/g_multipath.c (Revision 218482) +++ geom/multipath/g_multipath.c (Arbeitskopie) @@ -44,6 +44,7 @@ #include <geom/geom.h> #include <geom/multipath/g_multipath.h> +FEATURE(geom_multipath, "GEOM multipath support"); SYSCTL_DECL(_kern_geom); SYSCTL_NODE(_kern_geom, OID_AUTO, multipath, CTLFLAG_RW, 0, Index: geom/virstor/g_virstor.c =================================================================== --- geom/virstor/g_virstor.c (Revision 218482) +++ geom/virstor/g_virstor.c (Arbeitskopie) @@ -52,6 +52,8 @@ #include <geom/virstor/g_virstor.h> #include <geom/virstor/g_virstor_md.h> +FEATURE(g_virstor, "GEOM virtual storage support"); + /* Declare malloc(9) label */ static MALLOC_DEFINE(M_GVIRSTOR, "gvirstor", "GEOM_VIRSTOR Data"); Index: geom/geom_mbr.c =================================================================== --- geom/geom_mbr.c (Revision 218482) +++ geom/geom_mbr.c (Arbeitskopie) @@ -37,6 +37,7 @@ #include <sys/errno.h> #include <sys/endian.h> #include <sys/systm.h> +#include <sys/sysctl.h> #include <sys/kernel.h> #include <sys/fcntl.h> #include <sys/malloc.h> @@ -50,6 +51,8 @@ #include <geom/geom.h> #include <geom/geom_slice.h> +FEATURE(geom_mbr, "GEOM DOS/MBR partitioning support"); + #define MBR_CLASS_NAME "MBR" #define MBREXT_CLASS_NAME "MBREXT" Index: geom/eli/g_eli.c =================================================================== --- geom/eli/g_eli.c (Revision 218482) +++ geom/eli/g_eli.c (Arbeitskopie) @@ -51,6 +51,7 @@ #include <geom/eli/g_eli.h> #include <geom/eli/pkcs5v2.h> +FEATURE(geom_eli, "GEOM crypto module"); MALLOC_DEFINE(M_ELI, "eli data", "GEOM_ELI Data"); Index: geom/journal/g_journal.c =================================================================== --- geom/journal/g_journal.c (Revision 218482) +++ geom/journal/g_journal.c (Arbeitskopie) @@ -55,6 +55,7 @@ #include <geom/journal/g_journal.h> +FEATURE(geom_journal, "GEOM journaling support"); /* * On-disk journal format: Index: geom/geom_pc98.c =================================================================== --- geom/geom_pc98.c (Revision 218482) +++ geom/geom_pc98.c (Arbeitskopie) @@ -36,6 +36,7 @@ #include <sys/param.h> #include <sys/endian.h> #include <sys/systm.h> +#include <sys/sysctl.h> #include <sys/kernel.h> #include <sys/fcntl.h> #include <sys/malloc.h> @@ -47,6 +48,8 @@ #include <geom/geom.h> #include <geom/geom_slice.h> +FEATURE(geom_pc98, "GEOM NEC PC9800 partitioning support"); + #define PC98_CLASS_NAME "PC98" struct g_pc98_softc { Index: geom/linux_lvm/g_linux_lvm.c =================================================================== --- geom/linux_lvm/g_linux_lvm.c (Revision 218482) +++ geom/linux_lvm/g_linux_lvm.c (Arbeitskopie) @@ -42,6 +42,8 @@ #include <geom/linux_lvm/g_linux_lvm.h> +FEATURE(geom_linux_lvm, "GEOM Linux LVM partitioning support"); + /* Declare malloc(9) label */ static MALLOC_DEFINE(M_GLLVM, "gllvm", "GEOM_LINUX_LVM Data"); --=_30palfo2nku8--
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20110211100258.18243dlaaz0iulog>