diff options
Diffstat (limited to 'tools/regression/geom/Test/T015')
-rw-r--r-- | tools/regression/geom/Test/T015/Makefile | 2 | ||||
-rw-r--r-- | tools/regression/geom/Test/T015/ref.conf | 121 | ||||
-rw-r--r-- | tools/regression/geom/Test/T015/testprg.c | 67 |
3 files changed, 190 insertions, 0 deletions
diff --git a/tools/regression/geom/Test/T015/Makefile b/tools/regression/geom/Test/T015/Makefile new file mode 100644 index 0000000..18fd955 --- /dev/null +++ b/tools/regression/geom/Test/T015/Makefile @@ -0,0 +1,2 @@ +# $FreeBSD$ +.include <bsd.prog.mk> diff --git a/tools/regression/geom/Test/T015/ref.conf b/tools/regression/geom/Test/T015/ref.conf new file mode 100644 index 0000000..5775799 --- /dev/null +++ b/tools/regression/geom/Test/T015/ref.conf @@ -0,0 +1,121 @@ +<mesh> + <FreeBSD>$FreeBSD$</FreeBSD> + <class id="0x8087020"> + <name>DEV-class</name> + <geom id="0x80bb680"> + <class ref="0x8087020"/> + <name>da0p2</name> + <rank>3</rank> + <consumer id="0x80bc640"> + <geom ref="0x80bb680"/> + <provider ref="0x80bb500"/> + <mode>r0w0e0</mode> + </consumer> + </geom> + <geom id="0x80bb600"> + <class ref="0x8087020"/> + <name>da0p1</name> + <rank>3</rank> + <consumer id="0x80bc600"> + <geom ref="0x80bb600"/> + <provider ref="0x80bb480"/> + <mode>r0w0e0</mode> + </consumer> + </geom> + <geom id="0x80bb580"> + <class ref="0x8087020"/> + <name>da0p0</name> + <rank>3</rank> + <consumer id="0x80bc500"> + <geom ref="0x80bb580"/> + <provider ref="0x80bb400"/> + <mode>r0w0e0</mode> + </consumer> + </geom> + <geom id="0x80bb280"> + <class ref="0x8087020"/> + <name>da0</name> + <rank>2</rank> + <consumer id="0x80bc540"> + <geom ref="0x80bb280"/> + <provider ref="0x80bb200"/> + <mode>r0w0e0</mode> + </consumer> + </geom> + </class> + <class id="0x8087040"> + <name>APPLE</name> + <geom id="0x80bb300"> + <class ref="0x8087040"/> + <name>da0</name> + <rank>2</rank> + <config> + <frontstuff>8192</frontstuff> + </config> + <consumer id="0x80bc5c0"> + <geom ref="0x80bb300"/> + <provider ref="0x80bb200"/> + <mode>r0w0e0</mode> + <config> + </config> + </consumer> + <provider id="0x80bb500"> + <geom ref="0x80bb300"/> + <mode>r0w0e0</mode> + <name>da0p2</name> + <mediasize>16384</mediasize> + <sectorsize>512</sectorsize> + <config> + <index>2</index> + <length>16384</length> + <seclength>32</seclength> + <offset>32768</offset> + <secoffset>64</secoffset> + </config> + </provider> + <provider id="0x80bb480"> + <geom ref="0x80bb300"/> + <mode>r0w0e0</mode> + <name>da0p1</name> + <mediasize>32256</mediasize> + <sectorsize>512</sectorsize> + <config> + <index>1</index> + <length>32256</length> + <seclength>63</seclength> + <offset>512</offset> + <secoffset>1</secoffset> + </config> + </provider> + <provider id="0x80bb400"> + <geom ref="0x80bb300"/> + <mode>r0w0e0</mode> + <name>da0p0</name> + <mediasize>366481408</mediasize> + <sectorsize>512</sectorsize> + <config> + <index>0</index> + <length>366481408</length> + <seclength>715784</seclength> + <offset>49152</offset> + <secoffset>96</secoffset> + </config> + </provider> + </geom> + </class> + <class id="0x8087000"> + <name>SIMDISK-class</name> + <geom id="0x80bb180"> + <class ref="0x8087000"/> + <name>da0</name> + <rank>1</rank> + <provider id="0x80bb200"> + <geom ref="0x80bb180"/> + <mode>r0w0e0</mode> + <name>da0</name> + <mediasize>366530560</mediasize> + <sectorsize>512</sectorsize> + </provider> + </geom> + </class> +</mesh> diff --git a/tools/regression/geom/Test/T015/testprg.c b/tools/regression/geom/Test/T015/testprg.c new file mode 100644 index 0000000..cd7f4b8 --- /dev/null +++ b/tools/regression/geom/Test/T015/testprg.c @@ -0,0 +1,67 @@ +/*- + * Copyright (c) 2002 Poul-Henning Kamp + * Copyright (c) 2002 Networks Associates Technology, Inc. + * All rights reserved. + * + * This software was developed for the FreeBSD Project by Poul-Henning Kamp + * and NAI Labs, the Security Research Division of Network Associates, Inc. + * under DARPA/SPAWAR contract N66001-01-C-8035 ("CBOSS"), as part of the + * DARPA CHATS research program. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The names of the authors may not be used to endorse or promote + * products derived from this software without specific prior written + * permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE + * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS + * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + * + * $FreeBSD$ + */ + + +#include <stdio.h> +#include <unistd.h> +#include <string.h> +#include <stdlib.h> +#include <signal.h> +#include <err.h> +#include <sys/errno.h> +#include <sys/time.h> +#include <sys/sbuf.h> +#include <geom/geom.h> + +void * +thread_sim(void *ptr __unused) +{ + + rattle(); + g_simdisk_init(); + g_apple_init(); + g_dev_init(NULL); + rattle(); + + + g_simdisk_xml_load("da0", "../../Data/disk.apple.xml"); + rattle(); + conff("1"); + printf("Done\n"); + done(); + return (0); +} |