Module Name: src Committed By: pooka Date: Sat May 16 13:59:00 UTC 2015
Modified Files: src/sys/rump/dev/lib/libdisk: Makefile Added Files: src/sys/rump/dev/lib/libdisk: disk_component.c Log Message: Satisfy yet another non-modular driver still requiring a manual init call. To generate a diff of this commit: cvs rdiff -u -r1.7 -r1.8 src/sys/rump/dev/lib/libdisk/Makefile cvs rdiff -u -r0 -r1.1 src/sys/rump/dev/lib/libdisk/disk_component.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
Modified files: Index: src/sys/rump/dev/lib/libdisk/Makefile diff -u src/sys/rump/dev/lib/libdisk/Makefile:1.7 src/sys/rump/dev/lib/libdisk/Makefile:1.8 --- src/sys/rump/dev/lib/libdisk/Makefile:1.7 Tue Feb 16 20:42:44 2010 +++ src/sys/rump/dev/lib/libdisk/Makefile Sat May 16 13:59:00 2015 @@ -1,17 +1,18 @@ -# $NetBSD: Makefile,v 1.7 2010/02/16 20:42:44 pooka Exp $ +# $NetBSD: Makefile,v 1.8 2015/05/16 13:59:00 pooka Exp $ # .PATH: ${.CURDIR}/../../../../kern \ ${.CURDIR}/../../../../dev ${.CURDIR}/../../../../dev/dkwedge LIB= rumpdev_disk +SRCS= disk_component.c # # We use subr_disk_mbr on all platforms. The current structure of # code allows us to pick only one readdisklabel() routine. While # this is not the native one for all platforms, it's probably the # most common one in an image floating on the internetto. -SRCS= subr_disk_mbr.c +SRCS+= subr_disk_mbr.c # sys/kern SRCS+= subr_disk.c subr_disk_open.c Added files: Index: src/sys/rump/dev/lib/libdisk/disk_component.c diff -u /dev/null src/sys/rump/dev/lib/libdisk/disk_component.c:1.1 --- /dev/null Sat May 16 13:59:00 2015 +++ src/sys/rump/dev/lib/libdisk/disk_component.c Sat May 16 13:59:00 2015 @@ -0,0 +1,43 @@ +/* $NetBSD: disk_component.c,v 1.1 2015/05/16 13:59:00 pooka Exp $ */ + +/* + * Copyright (c) 2009 Antti Kantee. All Rights Reserved. + * + * 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. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``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. + */ + +#include <sys/cdefs.h> +__KERNEL_RCSID(0, "$NetBSD: disk_component.c,v 1.1 2015/05/16 13:59:00 pooka Exp $"); + +#include <sys/param.h> +#include <sys/conf.h> +#include <sys/device.h> +#include <sys/disk.h> + +#include "rump_private.h" +#include "rump_dev_private.h" + +RUMP_COMPONENT(RUMP_COMPONENT_DEV) +{ + + dkwedge_init(); +}