From owner-freebsd-current@FreeBSD.ORG Mon Nov 25 14:48:25 2013 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id C9F64C87 for ; Mon, 25 Nov 2013 14:48:25 +0000 (UTC) Received: from mail-oa0-x22c.google.com (mail-oa0-x22c.google.com [IPv6:2607:f8b0:4003:c02::22c]) (using TLSv1 with cipher ECDHE-RSA-RC4-SHA (128/128 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 96ED12EDE for ; Mon, 25 Nov 2013 14:48:25 +0000 (UTC) Received: by mail-oa0-f44.google.com with SMTP id m1so4438917oag.31 for ; Mon, 25 Nov 2013 06:48:24 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:date:message-id:subject :from:to:cc:content-type; bh=4LLxAk/WIBuHKrpoj44uUxELPrpCdHCT7/W7Pmm8qkc=; b=qO4gfd+TQzPdk7EbOBItNK/+4XoAPBmHFab7TJnMGnpcHmxh5cTGmAyOv02qJXkj35 RMiwM2uN9lLHfw2AifbRpZM6MjR0blb7/6x2FouVCxFYAuaEzSlvvo/VU0ntdRsH1BQT Dxof5vOXnDDzJbtFd44VwTEHjdiid38fey2lnatCf/aIqXHtU1Dwg1OtG6DxfEdoB4V/ epuLDBBYRZZN7prc6rLuwLKWWLBj6+zq9Ip23MXvhc5Lkm4I4zg0ToqxGno6piw4I/6S lH94hxLVypn+Nd5583LPs3HvsbogNbzO/BCeI9eJNMBfD9GXQ/lr2bKje9v4+SdD3lTa 94/A== MIME-Version: 1.0 X-Received: by 10.60.50.168 with SMTP id d8mr228152oeo.77.1385390904832; Mon, 25 Nov 2013 06:48:24 -0800 (PST) Sender: mdf356@gmail.com Received: by 10.182.110.195 with HTTP; Mon, 25 Nov 2013 06:48:24 -0800 (PST) In-Reply-To: References: Date: Mon, 25 Nov 2013 06:48:24 -0800 X-Google-Sender-Auth: bvMBkAJxGtHJ1yli3VaOWaMDcPY Message-ID: Subject: Re: sysctl add macros From: Matthew Fleming To: Venkata Duvvuru Content-Type: text/plain; charset=ISO-8859-1 X-Content-Filtered-By: Mailman/MimeDel 2.1.16 Cc: "freebsd-current@freebsd.org" X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.16 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 25 Nov 2013 14:48:25 -0000 On Mon, Nov 25, 2013 at 3:35 AM, Venkata Duvvuru < VenkatKumar.Duvvuru@emulex.com> wrote: > Hi, > I'm unable to figure out how to add an unsigned short or an unsigned char > values to a sysctl node. > SYSCTL_ADD_INT, SYSCTL_ADD_UINT, etc., are present but to add a char or a > short values I couldn't find any macros. > > Could you please let me know how to add them? > FreeBSD does not have any sysctl handlers for 1 or 2 byte values. FreeBSD code that wants to do this has used int or u_int instead of a smaller type. Cheers, matthew