From owner-p4-projects@FreeBSD.ORG Sun Mar 17 23:08:54 2013 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id D7563D21; Sun, 17 Mar 2013 23:08:54 +0000 (UTC) Delivered-To: perforce@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 995CBD1E for ; Sun, 17 Mar 2013 23:08:54 +0000 (UTC) (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: from skunkworks.freebsd.org (skunkworks.freebsd.org [IPv6:2001:1900:2254:2068::682:0]) by mx1.freebsd.org (Postfix) with ESMTP id 892F9816 for ; Sun, 17 Mar 2013 23:08:54 +0000 (UTC) Received: from skunkworks.freebsd.org ([127.0.1.74]) by skunkworks.freebsd.org (8.14.6/8.14.6) with ESMTP id r2HN8s1E010266 for ; Sun, 17 Mar 2013 23:08:54 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Received: (from perforce@localhost) by skunkworks.freebsd.org (8.14.6/8.14.6/Submit) id r2HN8sot010263 for perforce@freebsd.org; Sun, 17 Mar 2013 23:08:54 GMT (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Date: Sun, 17 Mar 2013 23:08:54 GMT Message-Id: <201303172308.r2HN8sot010263@skunkworks.freebsd.org> X-Authentication-Warning: skunkworks.freebsd.org: perforce set sender to bb+lists.freebsd.perforce@cyrus.watson.org using -f From: Robert Watson Subject: PERFORCE change 222986 for review To: Perforce Change Reviews Precedence: bulk X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.14 List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 17 Mar 2013 23:08:55 -0000 http://p4web.freebsd.org/@@222986?ac=10 Change 222986 by rwatson@rwatson_cinnamon on 2013/03/17 23:08:18 Initialise global tesla state when running in the kernel. Affected files ... .. //depot/projects/ctsrd/tesla/src/sys/libtesla/store.c#4 edit Differences ... ==== //depot/projects/ctsrd/tesla/src/sys/libtesla/store.c#4 (text+ko) ==== @@ -46,6 +46,20 @@ static void tesla_class_acquire(tesla_class*); +#ifdef _KERNEL +static void +tesla_global_store_sysinit(__unused void *arg) +{ + uint32_t error; + + error = tesla_store_init(&global_store, TESLA_SCOPE_GLOBAL, + TESLA_MAX_CLASSES, TESLA_MAX_INSTANCES); + tesla_assert(error == TESLA_SUCCESS, ("tesla_store_init failed")); +} +SYSINIT(tesla_global_store, SI_SUB_TESLA, SI_ORDER_FIRST, + tesla_global_store_sysinit, NULL); +#endif + int32_t tesla_store_get(uint32_t context, uint32_t classes, uint32_t instances, tesla_store* *storep)