From f6c1b3e09ac7209ec1c6c43263abcc3a8c83da7c Mon Sep 17 00:00:00 2001 From: jakllsch Date: Sat, 27 Jun 2009 16:10:25 +0000 Subject: Some fixes for dm(4). - Limit accesses to the size of the volume. This fixes a KASSERT in physio_biodone(). - Change dm_table_size() to return the size of the volume in DEV_BSIZE units. It was reporting it in DEV_BSIZE^2 units. - Remove a bit of trailing whitespace. ok haad --- sys/dev/dm/dm_table.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'sys/dev/dm/dm_table.c') diff --git a/sys/dev/dm/dm_table.c b/sys/dev/dm/dm_table.c index a20897a367c..0f359335f68 100644 --- a/sys/dev/dm/dm_table.c +++ b/sys/dev/dm/dm_table.c @@ -1,4 +1,4 @@ -/* $NetBSD: dm_table.c,v 1.2 2008/12/19 15:24:03 haad Exp $ */ +/* $NetBSD: dm_table.c,v 1.3 2009/06/27 16:10:25 jakllsch Exp $ */ /* * Copyright (c) 2008 The NetBSD Foundation, Inc. @@ -206,7 +206,7 @@ dm_table_size(dm_table_head_t *head) dm_table_unbusy(head); - return length / DEV_BSIZE; + return length; } /* -- cgit