On 12 April 2011 20:10, Adrian Chadd <adr...@freebsd.org> wrote: > Author: adrian > Date: Tue Apr 12 08:10:25 2011 > New Revision: 220559 > URL: http://svn.freebsd.org/changeset/base/220559 > > Log: > Introduce geom_map, a GEOM provider designed for use by > embedded flash stores. > > Some devices - notably those with uboot - don't have an > explicit partition table (eg like Redboot's FIS.) > geom_map thus provides an easy way to export the hard-coded > flash layout as geom providers for use by filesystems and > other tools. > > It also includes a "search" function which allows for > dynamic creation of partition layouts where the device only > has a single hard-coded partition. For example, if > there is a "kernel+rootfs" partition, a single image can > be created which appends the rootfs after the kernel with > an appropriate search string. geom_map can be told to > search for said search string and create a partition > beginning after it. > > Submitted by: Aleksandr Rybalko <r...@dlink.ua> > > Added: > head/sys/geom/geom_map.c (contents, props changed) > Modified: > head/sys/conf/files > > Added: head/sys/geom/geom_map.c > ============================================================================== > --- /dev/null 00:00:00 1970 (empty, because file is newly added) > +++ head/sys/geom/geom_map.c Tue Apr 12 08:10:25 2011 (r220559) > @@ -0,0 +1,356 @@ > + > +#define MAP_CLASS_NAME "MAP" > + > +struct map_desc { > + uint8_t name [16]; /* null-terminated name */ > + uint32_t offset; /* offset in flash */ > + uint32_t addr; /* address in memory */ > + uint32_t size; /* image size in bytes */ > + uint32_t entry; /* offset in image for entry point */ > + uint32_t dsize; /* data size in bytes */ > +};
It could at some point be used on larger storage, perhaps get rid of the 4G limit now? Andrew _______________________________________________ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"