Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/netbsd-1-5]: src/regress/sys/kern/extent Pull up revisions 1.6-1.7 (requ...



details:   https://anonhg.NetBSD.org/src/rev/39c4c222cf92
branches:  netbsd-1-5
changeset: 492764:39c4c222cf92
user:      he <he%NetBSD.org@localhost>
date:      Wed Feb 13 22:05:29 2002 +0000

description:
Pull up revisions 1.6-1.7 (requested by bouyer):
  Add two tests to match recent pull-ups:
   o extent_alloc_subregion() should not allocate region past the
     end of subregion
   o Do not allocate a region over an already allocated one when
     boundary is non-null

diffstat:

 regress/sys/kern/extent/tests |  22 +++++++++++++++++++++-
 1 files changed, 21 insertions(+), 1 deletions(-)

diffs (33 lines):

diff -r b63de9e7a909 -r 39c4c222cf92 regress/sys/kern/extent/tests
--- a/regress/sys/kern/extent/tests     Wed Feb 13 21:57:51 2002 +0000
+++ b/regress/sys/kern/extent/tests     Wed Feb 13 22:05:29 2002 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: tests,v 1.2.2.3 2000/07/03 22:55:04 thorpej Exp $
+# $NetBSD: tests,v 1.2.2.4 2002/02/13 22:05:29 he Exp $
 
 #fill up an extent, should coalesce into one allocation
 extent test1 0 0x4f
@@ -52,3 +52,23 @@
 alloc_subregion 0 11 7
 alloc_subregion 0 11 4
 print
+
+#don't allocate a region pasts the end of subregion (i.e., the second
+#alloc_subregion should fail).  subr_extent.c prior to rev. 1.43 allocates
+#region starts from 0x10.
+extent test8 0 0x4f EX_NOCOALESCE
+alloc_region 0x30 0x10
+alloc_subregion 0 0xf 0x10
+alloc_subregion 0 0xf 0x10
+print
+
+#When allocating a region with a boundary constraint, check that we properly
+#detect overlaps once the candidate region has been aligned.
+#subr_extent.c prior 1.45 could corrupt the extent map in this situation
+extent test9 0 0x4f
+boundary 0
+alloc_subregion 0 0x10 4
+alloc_subregion 0xd 0x20 2
+boundary 8
+alloc_subregion 0 0x4f 8
+print



Home | Main Index | Thread Index | Old Index