Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 12 Apr 2009 19:50:46 +0000 (UTC)
From:      Alexander Kabaev <kan@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-7@freebsd.org
Subject:   svn commit: r190975 - in stable/7/sys: . contrib/pf dev/ath/ath_hal dev/cxgb dev/dcons
Message-ID:  <200904121950.n3CJok7e037356@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: kan
Date: Sun Apr 12 19:50:46 2009
New Revision: 190975
URL: http://svn.freebsd.org/changeset/base/190975

Log:
  MFC change 190756:
  Fix logic in MOD_LOAD handler to call dcons_attach after all successful
  dcons_drv_init invocations. Testing return value for 0 does not work for
  cases where dcons_drv_init was called already as part of low level
  onsole initialization.
  
  Approved by:	re(kib)

Modified:
  stable/7/sys/   (props changed)
  stable/7/sys/contrib/pf/   (props changed)
  stable/7/sys/dev/ath/ath_hal/   (props changed)
  stable/7/sys/dev/cxgb/   (props changed)
  stable/7/sys/dev/dcons/dcons_os.c

Modified: stable/7/sys/dev/dcons/dcons_os.c
==============================================================================
--- stable/7/sys/dev/dcons/dcons_os.c	Sun Apr 12 19:42:25 2009	(r190974)
+++ stable/7/sys/dev/dcons/dcons_os.c	Sun Apr 12 19:50:46 2009	(r190975)
@@ -683,8 +683,9 @@ dcons_modevent(module_t mode, int type, 
 	case MOD_LOAD:
 		ret = dcons_drv_init(1);
 #if __FreeBSD_version >= 500000
-		if (ret == 0) {
+		if (ret != -1)
 			dcons_attach();
+		if (ret == 0) {
 			dcons_cnprobe(&dcons_consdev);
 			dcons_cninit(&dcons_consdev);
 			cnadd(&dcons_consdev);



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200904121950.n3CJok7e037356>