From owner-p4-projects@FreeBSD.ORG Thu Jul 5 17:18:11 2007 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 4084A16A4FE; Thu, 5 Jul 2007 17:18:11 +0000 (UTC) X-Original-To: perforce@FreeBSD.org Delivered-To: perforce@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id EACBB16A400 for ; Thu, 5 Jul 2007 17:18:10 +0000 (UTC) (envelope-from rpaulo@FreeBSD.org) Received: from repoman.freebsd.org (repoman.freebsd.org [69.147.83.41]) by mx1.freebsd.org (Postfix) with ESMTP id DB4EE13C46A for ; Thu, 5 Jul 2007 17:18:10 +0000 (UTC) (envelope-from rpaulo@FreeBSD.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.8/8.13.8) with ESMTP id l65HIAbu004016 for ; Thu, 5 Jul 2007 17:18:10 GMT (envelope-from rpaulo@FreeBSD.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.8/8.13.8/Submit) id l65HIAnq004013 for perforce@freebsd.org; Thu, 5 Jul 2007 17:18:10 GMT (envelope-from rpaulo@FreeBSD.org) Date: Thu, 5 Jul 2007 17:18:10 GMT Message-Id: <200707051718.l65HIAnq004013@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to rpaulo@FreeBSD.org using -f From: Rui Paulo To: Perforce Change Reviews Cc: Subject: PERFORCE change 122967 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 05 Jul 2007 17:18:12 -0000 http://perforce.freebsd.org/chv.cgi?CH=122967 Change 122967 by rpaulo@rpaulo_epsilon on 2007/07/05 17:17:50 Style cleanups. Affected files ... .. //depot/projects/soc2007/rpaulo-macbook/dev/backlight/backlight.c#8 edit Differences ... ==== //depot/projects/soc2007/rpaulo-macbook/dev/backlight/backlight.c#8 (text+ko) ==== @@ -23,7 +23,7 @@ * ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE * POSSIBILITY OF SUCH DAMAGE. * - * $P4: //depot/projects/soc2007/rpaulo-macbook/dev/backlight/backlight.c#7 $ + * $P4: //depot/projects/soc2007/rpaulo-macbook/dev/backlight/backlight.c#8 $ * */ @@ -123,7 +123,7 @@ if (vendor == backlight_models[i].bm_vendor && devid == backlight_models[i].bm_devid && !strncmp(model, backlight_models[i].bm_model, - strlen(model))) { + strlen(model))) { freeenv(model); return &backlight_models[i]; } @@ -177,10 +177,10 @@ sysctl_ctx_init(&sc->sc_sysctl_ctx); sc->sc_sysctl_tree = SYSCTL_ADD_NODE(&sc->sc_sysctl_ctx, - SYSCTL_STATIC_CHILDREN(_hw), - OID_AUTO, - device_get_name(dev), - CTLFLAG_RD, 0, ""); + SYSCTL_STATIC_CHILDREN(_hw), + OID_AUTO, + device_get_name(dev), + CTLFLAG_RD, 0, ""); SYSCTL_ADD_PROC(&sc->sc_sysctl_ctx, SYSCTL_CHILDREN(sc->sc_sysctl_tree), @@ -257,7 +257,7 @@ uint32_t newlevel; newlevel = (macbook_get_max(sc) << BACKLIGHT_MB_MAX_SHIFT) | - (value << BACKLIGHT_MB_CUR_SHIFT); + (value << BACKLIGHT_MB_CUR_SHIFT); bus_write_4(sc->sc_res, BACKLIGHT_MB_OFFSET, newlevel); @@ -273,14 +273,14 @@ rid = PCIR_BAR(0); sc->sc_res = bus_alloc_resource_any(dev, SYS_RES_MEMORY, &rid, - RF_ACTIVE); + RF_ACTIVE); if (sc->sc_res == NULL) return ENOMEM; max = macbook_get_max(sc); if (max > BACKLIGHT_MB_MAX) { device_printf(dev, "maximum brightness level out of range" - "(0x%x) - please send-pr\n", max); + "(0x%x) - please send-pr\n", max); return EINVAL; } @@ -336,7 +336,7 @@ curlevel = macbook_get_current(sc); level = (curlevel - BACKLIGHT_MB_MIN) * 100 / - (BACKLIGHT_MB_MAX - BACKLIGHT_MB_MIN); + (BACKLIGHT_MB_MAX - BACKLIGHT_MB_MIN); error = sysctl_handle_int(oidp, &level, 0, req); @@ -347,7 +347,7 @@ return EINVAL; curlevel = (level * (BACKLIGHT_MB_MAX - BACKLIGHT_MB_MIN) - / 100) + BACKLIGHT_MB_MIN; + / 100) + BACKLIGHT_MB_MIN; macbook_set_current(sc, curlevel); *(unsigned int *)oidp->oid_arg1 = level;