From owner-svn-src-head@freebsd.org Tue Dec 13 07:58:31 2016 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id CF111C755A6; Tue, 13 Dec 2016 07:58:31 +0000 (UTC) (envelope-from ed@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::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 9DC4B1E60; Tue, 13 Dec 2016 07:58:31 +0000 (UTC) (envelope-from ed@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id uBD7wUZJ097673; Tue, 13 Dec 2016 07:58:30 GMT (envelope-from ed@FreeBSD.org) Received: (from ed@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id uBD7wUNN097672; Tue, 13 Dec 2016 07:58:30 GMT (envelope-from ed@FreeBSD.org) Message-Id: <201612130758.uBD7wUNN097672@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ed set sender to ed@FreeBSD.org using -f From: Ed Schouten Date: Tue, 13 Dec 2016 07:58:30 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r310014 - head/sys/compat/linuxkpi/common/include/linux X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 13 Dec 2016 07:58:31 -0000 Author: ed Date: Tue Dec 13 07:58:30 2016 New Revision: 310014 URL: https://svnweb.freebsd.org/changeset/base/310014 Log: Remove the only user of sysctl_add_oid(). My plan is to change this function's prototype at some point in the future to add a new label argument, which can be used to export all of sysctl as metrics that can be scraped by Prometheus. Switch over this caller to use the macro wrapper counterpart. Modified: head/sys/compat/linuxkpi/common/include/linux/sysfs.h Modified: head/sys/compat/linuxkpi/common/include/linux/sysfs.h ============================================================================== --- head/sys/compat/linuxkpi/common/include/linux/sysfs.h Tue Dec 13 06:54:13 2016 (r310013) +++ head/sys/compat/linuxkpi/common/include/linux/sysfs.h Tue Dec 13 07:58:30 2016 (r310014) @@ -126,7 +126,7 @@ static inline int sysfs_create_file(struct kobject *kobj, const struct attribute *attr) { - sysctl_add_oid(NULL, SYSCTL_CHILDREN(kobj->oidp), OID_AUTO, + SYSCTL_ADD_OID(NULL, SYSCTL_CHILDREN(kobj->oidp), OID_AUTO, attr->name, CTLTYPE_STRING|CTLFLAG_RW|CTLFLAG_MPSAFE, kobj, (uintptr_t)attr, sysctl_handle_attr, "A", ""); @@ -158,7 +158,7 @@ sysfs_create_group(struct kobject *kobj, oidp = SYSCTL_ADD_NODE(NULL, SYSCTL_CHILDREN(kobj->oidp), OID_AUTO, grp->name, CTLFLAG_RD|CTLFLAG_MPSAFE, NULL, grp->name); for (attr = grp->attrs; *attr != NULL; attr++) { - sysctl_add_oid(NULL, SYSCTL_CHILDREN(oidp), OID_AUTO, + SYSCTL_ADD_OID(NULL, SYSCTL_CHILDREN(oidp), OID_AUTO, (*attr)->name, CTLTYPE_STRING|CTLFLAG_RW|CTLFLAG_MPSAFE, kobj, (uintptr_t)*attr, sysctl_handle_attr, "A", ""); }