From owner-svn-src-stable@FreeBSD.ORG Sun May 24 18:00:30 2015 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 5F83A896; Sun, 24 May 2015 18:00:30 +0000 (UTC) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 3CC641FB9; Sun, 24 May 2015 18:00:30 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.9/8.14.9) with ESMTP id t4OI0UJC036757; Sun, 24 May 2015 18:00:30 GMT (envelope-from ian@FreeBSD.org) Received: (from ian@localhost) by svn.freebsd.org (8.14.9/8.14.9/Submit) id t4OI0U5D036756; Sun, 24 May 2015 18:00:30 GMT (envelope-from ian@FreeBSD.org) Message-Id: <201505241800.t4OI0U5D036756@svn.freebsd.org> X-Authentication-Warning: svn.freebsd.org: ian set sender to ian@FreeBSD.org using -f From: Ian Lepore Date: Sun, 24 May 2015 18:00:30 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r283485 - stable/10/sys/dev/fdt X-SVN-Group: stable-10 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 24 May 2015 18:00:30 -0000 Author: ian Date: Sun May 24 18:00:29 2015 New Revision: 283485 URL: https://svnweb.freebsd.org/changeset/base/283485 Log: MFC r281371: Use OF_getencpropalloc() to handle endianess of the properties. Modified: stable/10/sys/dev/fdt/fdt_pinctrl.c Directory Properties: stable/10/ (props changed) Modified: stable/10/sys/dev/fdt/fdt_pinctrl.c ============================================================================== --- stable/10/sys/dev/fdt/fdt_pinctrl.c Sun May 24 18:00:14 2015 (r283484) +++ stable/10/sys/dev/fdt/fdt_pinctrl.c Sun May 24 18:00:29 2015 (r283485) @@ -46,7 +46,7 @@ fdt_pinctrl_configure(device_t client, u char name[16]; snprintf(name, sizeof(name), "pinctrl-%u", index); - nconfigs = OF_getprop_alloc(ofw_bus_get_node(client), name, + nconfigs = OF_getencprop_alloc(ofw_bus_get_node(client), name, sizeof(*configs), (void **)&configs); if (nconfigs < 0) return (ENOENT); @@ -122,12 +122,12 @@ pinctrl_configure_children(device_t pinc if (!fdt_is_enabled(node)) continue; pinctrl_configure_children(pinctrl, node); - nconfigs = OF_getencprop_alloc(node, "pinctrl-0", + nconfigs = OF_getencprop_alloc(node, "pinctrl-0", sizeof(*configs), (void **)&configs); if (nconfigs <= 0) continue; if (bootverbose) { - char name[32]; + char name[32]; OF_getprop(node, "name", &name, sizeof(name)); printf("Processing %d pin-config node(s) in pinctrl-0 for %s\n", nconfigs, name);