Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 10 May 2002 22:38:37 -0700 (PDT)
From:      Robert Watson <rwatson@FreeBSD.org>
To:        Perforce Change Reviews <perforce@freebsd.org>
Subject:   PERFORCE change 11152 for review
Message-ID:  <200205110538.g4B5cb601082@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help
http://people.freebsd.org/~peter/p4db/chv.cgi?CH=11152

Change 11152 by rwatson@rwatson_paprika on 2002/05/10 22:37:49

	Move printf() on module load outside of the region where the list
	lock is held.  Introduce a new printf on unload of a module.

Affected files ...

... //depot/projects/trustedbsd/mac/sys/kern/kern_mac.c#141 edit

Differences ...

==== //depot/projects/trustedbsd/mac/sys/kern/kern_mac.c#141 (text+ko) ====

@@ -564,13 +564,15 @@
 		mpc->mpc_field_off = -1;
 	mpc->mpc_runtime_flags |= MPC_RUNTIME_FLAG_REGISTERED;
 	LIST_INSERT_HEAD(&mac_policy_list, mpc, mpc_list);
-	printf("Security policy: %s (%s)\n", mpc->mpc_fullname, mpc->mpc_name);
 
 	/* Per-policy initialization. */
 	if (mpc->mpc_ops.mpo_init != NULL)
 		(*(mpc->mpc_ops.mpo_init))(mpc);
 	MAC_POLICY_LIST_UNLOCK();
 
+	printf("Security policy loaded: %s (%s)\n", mpc->mpc_fullname,
+	    mpc->mpc_name);
+
 	return (0);
 }
 
@@ -594,6 +596,9 @@
 	LIST_REMOVE(mpc, mpc_list);
 	MAC_POLICY_LIST_UNLOCK();
 
+	printf("Security policy unload: %s (%s)\n", mpc->mpc_fullname,
+	    mpc->mpc_name);
+
 	return (0);
 }
 

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe p4-projects" in the body of the message




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