Source-Changes-HG archive

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

[src/trunk]: src/sys/kern in mapply(), call config_match() instead duplicatin...



details:   https://anonhg.NetBSD.org/src/rev/2ea913906262
branches:  trunk
changeset: 583925:2ea913906262
user:      drochner <drochner%NetBSD.org@localhost>
date:      Mon Aug 29 19:13:48 2005 +0000

description:
in mapply(), call config_match() instead duplicating its code

diffstat:

 sys/kern/subr_autoconf.c |  14 +++-----------
 1 files changed, 3 insertions(+), 11 deletions(-)

diffs (35 lines):

diff -r 4ded762a7002 -r 2ea913906262 sys/kern/subr_autoconf.c
--- a/sys/kern/subr_autoconf.c  Mon Aug 29 19:11:33 2005 +0000
+++ b/sys/kern/subr_autoconf.c  Mon Aug 29 19:13:48 2005 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: subr_autoconf.c,v 1.99 2005/08/26 14:20:40 drochner Exp $ */
+/* $NetBSD: subr_autoconf.c,v 1.100 2005/08/29 19:13:48 drochner Exp $ */
 
 /*
  * Copyright (c) 1996, 2000 Christopher G. Demetriou
@@ -77,7 +77,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: subr_autoconf.c,v 1.99 2005/08/26 14:20:40 drochner Exp $");
+__KERNEL_RCSID(0, "$NetBSD: subr_autoconf.c,v 1.100 2005/08/29 19:13:48 drochner Exp $");
 
 #include "opt_ddb.h"
 
@@ -442,15 +442,7 @@
        if (m->fn != NULL) {
                pri = (*m->fn)(m->parent, cf, m->locs, m->aux);
        } else {
-               struct cfattach *ca;
-
-               ca = config_cfattach_lookup(cf->cf_name, cf->cf_atname);
-               if (ca == NULL) {
-                       /* No attachment for this entry, oh well. */
-                       return;
-               }
-               KASSERT(ca->ca_match != NULL);
-               pri = (*ca->ca_match)(m->parent, cf, m->aux);
+               pri = config_match(m->parent, cf, m->aux);
        }
        if (pri > m->pri) {
                m->match = cf;



Home | Main Index | Thread Index | Old Index