Received: from mail-ew0-f223.google.com ([209.85.219.223]) by bombadil.infradead.org with esmtp (Exim 4.69 #1 (Red Hat Linux)) id 1NMkgJ-0006lF-V0 for linux-mtd@lists.infradead.org; Mon, 21 Dec 2009 16:00:27 +0000 Received: by ewy23 with SMTP id 23so4508462ewy.4 for ; Mon, 21 Dec 2009 08:00:21 -0800 (PST) MIME-Version: 1.0 In-Reply-To: <4B18F4B7.9050709@nokia.com> References: <4B18F4B7.9050709@nokia.com> Date: Mon, 21 Dec 2009 11:00:21 -0500 Message-ID: Subject: Re: how to properly calculate max-leb-cnt and vol_size for ubifs From: twebb To: Adrian Hunter Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Cc: "linux-mtd@lists.infradead.org" List-Id: Linux MTD discussion mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , >> >> I'm using ubifs for the first time and am confused about how to >> calculate two parameters: >> >> "max-leb-cnt" for mkfs.ubifs >> "vol_size" for ubinize cfg file >> >> How should "max-leb-cnt" be calculated? =A0In the examples, how is "-c >> 2047" determined? =A0Should the max-leb-cnt calculation somehow include >> the overhead calculated per the ubifs documentation page? =A0Should the >> reserved PEBs (1% default for NAND flash) be somehow taken into >> account? >> >> How should "vol_size" be calculated? =A0Is it simply max-leb-cnt * >> LEB_size? =A0Should overhead somehow be included in this calculation >> also? > > Have you read: > > http://linux-mtd.infradead.org/faq/ubifs.html#L_max_leb_cnt > > http://linux-mtd.infradead.org/faq/ubi.html#L_ubi_mkimg > > http://linux-mtd.infradead.org/doc/ubi.html#L_autoresize > > I have, and I'm still pretty confused. I just posted some additional questions I'm hoping perhaps you or someone else may be able to help with. Thanks, twebb