From owner-freebsd-hackers@FreeBSD.ORG Sun Jul 7 11:45:33 2013 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 10D591FC for ; Sun, 7 Jul 2013 11:45:33 +0000 (UTC) (envelope-from mngesh1@yahoo.com) Received: from nm43.bullet.mail.ne1.yahoo.com (nm43.bullet.mail.ne1.yahoo.com [98.138.120.50]) by mx1.freebsd.org (Postfix) with ESMTP id A7D141100 for ; Sun, 7 Jul 2013 11:45:32 +0000 (UTC) Received: from [127.0.0.1] by nm43.bullet.mail.ne1.yahoo.com with NNFMP; 07 Jul 2013 11:45:26 -0000 Received: from [98.139.214.32] by tm15.bullet.mail.ne1.yahoo.com with NNFMP; 07 Jul 2013 11:41:43 -0000 Received: from [98.139.212.229] by tm15.bullet.mail.bf1.yahoo.com with NNFMP; 07 Jul 2013 11:41:43 -0000 Received: from [127.0.0.1] by omp1038.mail.bf1.yahoo.com with NNFMP; 07 Jul 2013 11:41:43 -0000 X-Yahoo-Newman-Property: ymail-4 X-Yahoo-Newman-Id: 463095.10658.bm@omp1038.mail.bf1.yahoo.com Received: (qmail 7420 invoked by uid 60001); 7 Jul 2013 11:41:43 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s1024; t=1373197303; bh=dFIqwPmRRVrAgW1ZIUZLqMGqtb+B61koimZpNNZnRXA=; h=X-YMail-OSG:Received:X-Rocket-MIMEInfo:X-Mailer:Message-ID:Date:From:Reply-To:Subject:To:MIME-Version:Content-Type; b=bzfcNUq17LEmKjPEsRELiFXnzKCcW6RC42HS4aqKn/+1fIsksxH9TrqXg5OfGy9Pi256wlBLlgtOo6YOd8hyi3SsqvC30Tqe1l9byLTbTR/taGaVZ84Eyeqd2usIvUD+TEtatpWsiCKD5tuhaUsgEp9v1ojBGlWrXpnnhQj+5+o= DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=s1024; d=yahoo.com; h=X-YMail-OSG:Received:X-Rocket-MIMEInfo:X-Mailer:Message-ID:Date:From:Reply-To:Subject:To:MIME-Version:Content-Type; b=FsMQH1zdqoS3ncaLU5CKXWIOHYpTpUIg7cThM6ngRyEMoGh2KBQChIzEoOSmDOg5KYx2ruJCvuTxjKt2970QhM1bez1nFhHDc0ozvcFjwWP5wNPbFQK7BId2EtYcNT8erMD1h9KNGWomMi4E5fq0BQ7m4IkxeCxFOmBl4wymSsc= ; X-YMail-OSG: wZZuB08VM1kh9czDlnotZzIosQUfo._j10SSukMweBjFirF ZX6CwJyG9pxeNNxAgQOquuenY0CFVdaH4C1GjQFOF3l.5Cmn8CbYBj8Uydxl iMgA7Kg2dfmp6N8.xCco7Oe3kEM2IPiJz82mi3ROsU1SlsFw5Do4tXRQhIza zXQWUA9VLAmqxQqUVqDdjgMJgTjcp8y.wFlN2KYdQXVy9kEQqXcsShBzTxIE qbqLm14J4r7T9TT5357qG1sn2YLWNEOKYxpJG1WNx5.aC0x9mXv4hH4W.N5U LL99yi4fh7M1_DXmHiroZ5lhYn6LPm51gebR1iPmChx3qqY_GWHoaFQlH5QG DM_Q2mbrTQLYj2x1qFf2fpbgD1.XZpE68oHEewpymcVieDHuo._RkO9X_Z4M E2U6Ox6Q_Qd.9aT0sjaKD.SUC24ZkAcSJNXxWXLW6nb_VnyBappeJlzJaBWy Ko.lo5BIHxOBJYq_yrKoh6Q0ZmZa8aB4KCFt0pVth7LUdKmzSRH.OK0gOKS1 F243qyEFd0jhel_G38mCh20wMGVIhhzMaVwYHMVCMxmv3FJTjyY2c7vbaGrL ZyRoNdZriUG25lwyjQjvGagm22s7V_Odwy7s8ZFr4Fvw- Received: from [180.215.1.137] by web160703.mail.bf1.yahoo.com via HTTP; Sun, 07 Jul 2013 04:41:43 PDT X-Rocket-MIMEInfo: 002.001, SGksCgpXaGF0IGlzIHRoZcKgbWVtbWFwwqBlcXVpdmFsZW50IG9mIExpbnV4IGluwqBGcmVlQlNEPwoKSW4gTGludXjCoG1lbW1hcMKgaXMgdXNlZCB0byByZXNlcnZlIGEgcG9ydGlvbiBvZiBwaHlzaWNhbCBtZW1vcnkuIFRoaXMgaXMgdXNlZCBhcyBhIGtlcm5lbCBib290IGFyZ3VtZW50LiBFLmcuOiBtZW1tYXA9MkckMUcgd2lsbCByZXNlcnZlIDFHQsKgbWVtb3J5IGFib3ZlIDJHQizCoMKgaW5jYXNlwqBJwqBoYXZlIDNHQsKgUkFNLiBUaGlzIDFHQsKgcmVzZXJ2ZWQgbWVtb3J5IGlzIG5vdCB2aXNpYmwBMAEBAQE- X-Mailer: YahooMailWebService/0.8.148.557 Message-ID: <1373197303.40304.YahooMailNeo@web160703.mail.bf1.yahoo.com> Date: Sun, 7 Jul 2013 04:41:43 -0700 (PDT) From: mangesh chitnis Subject: memmap in FreeBSD To: "freebsd-hackers@freebsd.org" MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: quoted-printable X-Content-Filtered-By: Mailman/MimeDel 2.1.14 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list Reply-To: mangesh chitnis List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 07 Jul 2013 11:45:33 -0000 Hi,=0A=0AWhat is the=A0memmap=A0equivalent of Linux in=A0FreeBSD?=0A=0AIn L= inux=A0memmap=A0is used to reserve a portion of physical memory. This is us= ed as a kernel boot argument. E.g.: memmap=3D2G$1G will reserve 1GB=A0memor= y above 2GB,=A0=A0incase=A0I=A0have 3GB=A0RAM. This 1GB=A0reserved memory i= s not visible to=A0the=A0OS, however this 1GB=A0can be used using ioremap.= =A0=0AHow can=A0I=A0reserve memory in=A0FreeBSD and later use it=A0i.e=A0me= mmap=A0and=A0ioremap=A0equivalent?=0A=0AI have tried using hw.physmem loade= r parameter.=0AI have 3 GB system memory and=A0I=A0have set=A0hw.physmem=3D= 2G.=A0=0A=0A=0Asysctl -a=A0shows:=0Ahw.physmem: 2.12G=0A=0Ahw.usermem: 1.9G= =0Ahw.realmem: 2.15G=0A=0Adevinfo -rv=A0shows:=0Aram0:=A0=0A=0A0x00-0x9f3ff= =A0=0A0x10000000-0xbfedffff=A0=0A0xbff00000-0xbfffffff=0A=0AHere, looks lik= e it is showing the full 3 GB mapping.=0ANow, how do=A0I=A0know which is th= at 1 GB available memory (In Linux, this memory is shown as reserved in /pr= oc/iomem under System RAM)=A0? Also, which function(similar to=A0ioremap) s= hould=A0I=A0call to map the physical address to virtual address?=0A=0A=0ATh= anks. From owner-freebsd-hackers@FreeBSD.ORG Sun Jul 7 11:45:47 2013 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 0A7742EF for ; Sun, 7 Jul 2013 11:45:47 +0000 (UTC) (envelope-from aryeh.friedman@gmail.com) Received: from mail-pd0-x235.google.com (mail-pd0-x235.google.com [IPv6:2607:f8b0:400e:c02::235]) by mx1.freebsd.org (Postfix) with ESMTP id E266E110D for ; Sun, 7 Jul 2013 11:45:46 +0000 (UTC) Received: by mail-pd0-f181.google.com with SMTP id 14so3222351pdj.12 for ; Sun, 07 Jul 2013 04:45:46 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:date:message-id:subject:from:to:content-type; bh=ismV/tJkUX0EPav8HreOl7EIay15veTSOBTw/GG6Fto=; b=skmb0Eo0FyTNeMTiCtvVQQcoX0+hFpleQ0O9MYXsprWHYKY4YlSDWXEipzvuJ4hnzm c/q6AbGclL0mVmbd4v50nIOVK/aAdxBqoXF3KY3RTesZ6HaOL1oPtdbqLO/x6e/6xNjt EYjA8rPwb114113KywD0axdsbolVlokbhf26QfskBXQTZbH8nGH5Zw2Q422lzxuuFEzK KijA/GHEB9+HKZ/3oggrSAAMu5XNNsFUxcL7qErP+AYJi8qAvNHAic3gNFqK/cMdOzpO zK87t9mZEXz84IT3snI45/RxP0dp6Zzqohuy/sGxxjnJ5bFhVeS+q5deEnMJlyd9zdR3 FnzA== MIME-Version: 1.0 X-Received: by 10.68.197.98 with SMTP id it2mr16669859pbc.200.1373197546682; Sun, 07 Jul 2013 04:45:46 -0700 (PDT) Received: by 10.68.80.231 with HTTP; Sun, 7 Jul 2013 04:45:46 -0700 (PDT) Date: Sun, 7 Jul 2013 07:45:46 -0400 Message-ID: Subject: writing a rc.d script From: Aryeh Friedman To: FreeBSD Mailing List Content-Type: text/plain; charset=ISO-8859-1 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 07 Jul 2013 11:45:47 -0000 I have a program I am making a port for that also requires a /usr/local/etc/rc.d script is there anywhere I can find documentation on how write one and/or a template file to follow?