From owner-freebsd-ppc@FreeBSD.ORG Mon Feb 18 13:55:50 2013 Return-Path: Delivered-To: freebsd-ppc@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 0E5C2ACE for ; Mon, 18 Feb 2013 13:55:50 +0000 (UTC) (envelope-from bu7cher@yandex.ru) Received: from forward2h.mail.yandex.net (forward2h.mail.yandex.net [IPv6:2a02:6b8:0:f05::2]) by mx1.freebsd.org (Postfix) with ESMTP id B8761E4F for ; Mon, 18 Feb 2013 13:55:49 +0000 (UTC) Received: from smtp2h.mail.yandex.net (smtp2h.mail.yandex.net [84.201.187.145]) by forward2h.mail.yandex.net (Yandex) with ESMTP id E137E701673; Mon, 18 Feb 2013 17:55:43 +0400 (MSK) Received: from smtp2h.mail.yandex.net (localhost [127.0.0.1]) by smtp2h.mail.yandex.net (Yandex) with ESMTP id 982D61700289; Mon, 18 Feb 2013 17:55:43 +0400 (MSK) Received: from dhcp-218-28-wifi.yandex.net (dhcp-218-28-wifi.yandex.net [213.180.218.28]) by smtp2h.mail.yandex.net (nwsmtp/Yandex) with ESMTP id tgQisHNJ-thQ8aoPv; Mon, 18 Feb 2013 17:55:43 +0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yandex.ru; s=mail; t=1361195743; bh=wrZdYDHJeHzC6bfv5oGton2GuVgwhIh+6awnYRdWKR0=; h=Message-ID:Date:From:User-Agent:MIME-Version:To:CC:Subject: References:In-Reply-To:X-Enigmail-Version:Content-Type: Content-Transfer-Encoding; b=kgZK4DUsi5POEGKJFds6a9Rxs3FUczQgywDsuzoPTlXqc7yLJJA9sipT74a4u0d8v 6a8KFMCthqTSAvZKxmZzjC7meR8QMQJ4JW3Z2S7FAU37d3fsmsEiz/sh9BodQLbA+Y v0+/42Isclw5tKJnCQDSrvZVJAXsiaJvUsoZ/sro= Message-ID: <51223290.4070509@yandex.ru> Date: Mon, 18 Feb 2013 17:54:24 +0400 From: "Andrey V. Elsukov" User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:17.0) Gecko/17.0 Thunderbird/17.0 MIME-Version: 1.0 To: =?ISO-8859-1?Q?Muammer_Hamut=E7u?= Subject: Re: How to make APM disk which can be detected by Linux' GParted? References: <1360858013.53771.YahooMailNeo@web160704.mail.bf1.yahoo.com> <511D2E19.6020809@yandex.ru> <1361183920.93805.YahooMailNeo@web160706.mail.bf1.yahoo.com> In-Reply-To: <1361183920.93805.YahooMailNeo@web160706.mail.bf1.yahoo.com> X-Enigmail-Version: 1.4.6 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit Cc: "freebsd-ppc@freebsd.org" X-BeenThere: freebsd-ppc@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Porting FreeBSD to the PowerPC List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 18 Feb 2013 13:55:50 -0000 On 18.02.2013 14:38, Muammer Hamutçu wrote: > I have a clue on how to achieve a partition structure which GParted > can detect: http://d1302.hizliresim.com/16/f/k2fd8.jpg It seems your partition table has not been created with gpart(8). And probably this did the trick. As you can see, your APM metadata takes 14 sectors, but when you use gpart(8), by default it takes 18 sectors. > How could I remake such a partitioning, how is it done? Thanks. You can patch your geom_part_apm module: Index: /usr/src/sys/geom/part/g_part_apm.c =================================================================== --- /usr/src/sys/geom/part/g_part_apm.c (revision 241375) +++ /usr/src/sys/geom/part/g_part_apm.c (working copy) @@ -101,7 +101,7 @@ static struct g_part_scheme g_part_apm_scheme = { g_part_apm_methods, sizeof(struct g_part_apm_table), .gps_entrysz = sizeof(struct g_part_apm_entry), - .gps_minent = 16, + .gps_minent = 12, .gps_maxent = 4096, }; G_PART_SCHEME_DECLARE(g_part_apm); The you can do: # mdconfig -s 78140160 # gpart create -s apm md0 # gpart add -b 64 -t apple-boot -s 2001 md0 # gpart add -t freebsd-ufs -s 5859376 md0 # gpart add -t apple-ufs -s 1953126 md0 # gpart add -t freebsd-ufs -s 1171876 md0 # gpart add -t freebsd-ufs -s 1171876 md0 # gpart add -t freebsd-ufs -s 7812501 md0 # gpart add -t freebsd-ufs -s 1171876 md0 # gpart add -b 19144704 -t apple-boot -s 2048 md0 # gpart add -t apple-ufs -s 15624192 md0 # gpart add -t apple-ufs -s 1953792 md0 # gpart show md0 => 14 78140146 md0 APM (37G) 14 50 - free - (25k) 64 2001 1 apple-boot (1M) 2065 5859376 2 freebsd-ufs (2.8G) 5861441 1953126 3 apple-ufs (953M) 7814567 1171876 4 freebsd-ufs (572M) 8986443 1171876 5 freebsd-ufs (572M) 10158319 7812501 6 freebsd-ufs (3.7G) 17970820 1171876 7 freebsd-ufs (572M) 19142696 2008 - free - (1M) 19144704 2048 8 apple-boot (1.0M) 19146752 15624192 9 apple-ufs (7.5G) 34770944 1953792 10 apple-ufs (954M) 36724736 41415424 - free - (19G) :) -- WBR, Andrey V. Elsukov