From owner-freebsd-hackers Wed May 31 1:44:37 2000 Delivered-To: freebsd-hackers@freebsd.org Received: from mailserv.waikato.ac.nz (mailserv.waikato.ac.nz [130.217.66.61]) by hub.freebsd.org (Postfix) with ESMTP id 931BB37B50E for ; Wed, 31 May 2000 01:44:27 -0700 (PDT) (envelope-from mjl12@waikato.ac.nz) Received: from stu_ex3.waikato.ac.nz (stu-ex3.waikato.ac.nz [130.217.70.30]) by mailserv.waikato.ac.nz (8.9.3/8.9.0) with ESMTP id UAA11814 for ; Wed, 31 May 2000 20:46:31 +1200 Received: by stu-ex3.waikato.ac.nz with Internet Mail Service (5.5.2650.21) id ; Wed, 31 May 2000 20:43:50 +1200 Message-ID: <45E87454FFC2D211AD9800508B650094BA4D67@stu-ex1.waikato.ac.nz> From: "MATTHEW JOHN,LUCKIE" To: "'freebsd-hackers@freebsd.org'" Subject: sysctl_proc Date: Wed, 31 May 2000 20:44:24 +1200 MIME-Version: 1.0 X-Mailer: Internet Mail Service (5.5.2650.21) Content-Type: text/plain Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG Hi there I am wanting to create an icmp packet in the kernel for the purposes of timestamping it as accurately as i can (in kernel space). At the moment, I am creating a packet and sending it out through a raw socket. I am not sure if i can catch this packet easily in the kernel, and i thought that perhaps a sysctl might be what i want. is this what a SYSCTL_PROC can do for me? basically, i want to pass in an IP address, and a packet ID that the user wants to identify the packet with. In the sysctl, i create the mbuf with the packet i want to send and then send it, all from within the kernel. If it is, what is the difference between a ptr and a hander when creating the SYSCTL_PROC? The handler is the function itself that i want to call, but i cannot see the point of the arg parameter. I am looking at the netinet/in_pcb.c source code. A sample SYSCTL_PROC definition would be handy to me. Thanks in advance Matthew Luckie To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message