From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from list by lists.gnu.org with archive (Exim 4.90_1) id 1mOck3-0002GO-UZ for mharc-grub-devel@gnu.org; Fri, 10 Sep 2021 05:22:39 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:53338) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mOck1-0002Fq-5v for grub-devel@gnu.org; Fri, 10 Sep 2021 05:22:38 -0400 Received: from de-smtp-delivery-102.mimecast.com ([194.104.111.102]:56527) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mOcjx-0004VH-UW for grub-devel@gnu.org; Fri, 10 Sep 2021 05:22:35 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.com; s=mimecast20200619; t=1631265750; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=Q4O7/UG+aXpFNet59Bl2Oq98iIe6K1h9jrMrAWG4OAI=; b=T8unqUgFAzIFeBHpiafqSolZargAqMVqtGsQpxrBTkDxUbzYGF8MGycQ0an6HfvMdEYH96 6cgz4www8EKohzzUtUHBE6EahbCfZeKK4ILtIkyVS6nu4aOsxeA8d8ZMyi4LtwszpHQGw6 AyNWKjDQFC2g8v2MadjC/dZfQz62rCI= Received: from EUR04-DB3-obe.outbound.protection.outlook.com (mail-db3eur04lp2052.outbound.protection.outlook.com [104.47.12.52]) (Using TLS) by relay.mimecast.com with ESMTP id de-mta-28-hnN55AudP0qLt4Mwfkr4lw-1; Fri, 10 Sep 2021 11:22:28 +0200 X-MC-Unique: hnN55AudP0qLt4Mwfkr4lw-1 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=Kklx/Nsc5HnE0hEordc/Zx1/z1OH7+hIQBJmY7pJ0fDbqVpZD0c7vRa+7EOPnmWg5R9HnHkEBUAfTbKX2FP4a4H3OY/jYEZ4SCz9kqb9A7R/iRuDUN/y8ozsSHMcVWTInTwctmlyCaL5/eCgIfpfvCoaW5naDJK+jMzYtNYqJySybdOeYWTopEbSK1b8OUAw76kL4tX+JnU3qDir58oHsjZlY3/6bxSlY77AfZ/7JVxnvakznzWEsOIM078g4amU0xFNrsuSTf5F8xSB3YuJCCBKNsXEUJhZEPIuWur3H/1khObKVmW5mfczXPZXl+ueSTnhbMj9pJiFNjUeUuaM6g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=Q4O7/UG+aXpFNet59Bl2Oq98iIe6K1h9jrMrAWG4OAI=; b=FxD+ALCxj3+bGBcVqaFRcqDfsGjjdPTYJ/vv+a5k97DMpMja6fmdtEKH/+mUwFNkSLaT8LIOFIC/7e7nW6sA2NbKeFYbwle8Lc/AbpOgbsYuQwu+aN2wij9d4EXDVOkfdTLQ6J8Pus36YaBR9AgtXxMzcznHvkaiQq+WXbHVCJEdNDr9jDSKR70yVOKWeCnpwRMwkU8hPfqBGz9yEmHGMQb8Dn6tbt97EajrCRkEZgXXEfosutlb0Lqh9m2+sn48MUmZQsK4/789krRFYu296YY0PQgl3LUYR+xD6NmrRz5uzo3g16Pvq+BkJFUPD6yhc7bByA6rzT8oulZP3ZzZOg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=suse.com; dmarc=pass action=none header.from=suse.com; dkim=pass header.d=suse.com; arc=none Authentication-Results: gnu.org; dkim=none (message not signed) header.d=none;gnu.org; dmarc=none action=none header.from=suse.com; Received: from PAXPR04MB8653.eurprd04.prod.outlook.com (2603:10a6:102:21c::24) by PAXPR04MB8443.eurprd04.prod.outlook.com (2603:10a6:102:1da::23) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4500.16; Fri, 10 Sep 2021 09:22:28 +0000 Received: from PAXPR04MB8653.eurprd04.prod.outlook.com ([fe80::a18f:ae05:55f4:5ce1]) by PAXPR04MB8653.eurprd04.prod.outlook.com ([fe80::a18f:ae05:55f4:5ce1%6]) with mapi id 15.20.4500.016; Fri, 10 Sep 2021 09:22:27 +0000 Date: Fri, 10 Sep 2021 17:22:22 +0800 From: Michael Chang To: The development of GNU GRUB Subject: Re: [PATCH] i386-pc: build btrfs zstd support into separate module Message-ID: <20210910092222.GA11439@mazu> References: <20210831071228.8282-1-mchang@suse.com> <20210901163822.5vq766pc2wdjveef@tomti.i.net-space.pl> <20210902054830.GA9354@mazu> <20210902121252.fa3heoxb6afza7tq@tomti.i.net-space.pl> <20210903012139.GA6661@mazu> <20210908193752.u4pkfbkommbjkazq@tomti.i.net-space.pl> Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20210908193752.u4pkfbkommbjkazq@tomti.i.net-space.pl> User-Agent: Mutt/1.10.1 (2018-07-13) X-ClientProxiedBy: HK2PR03CA0046.apcprd03.prod.outlook.com (2603:1096:202:17::16) To PAXPR04MB8653.eurprd04.prod.outlook.com (2603:10a6:102:21c::24) MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 Received: from localhost (2001:b011:30d0:3945:6600:6aff:fe77:a7be) by HK2PR03CA0046.apcprd03.prod.outlook.com (2603:1096:202:17::16) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4523.9 via Frontend Transport; Fri, 10 Sep 2021 09:22:27 +0000 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: d5b4130d-acaf-4f01-e3c3-08d9743c81e9 X-MS-TrafficTypeDiagnostic: PAXPR04MB8443: X-MS-Exchange-Transport-Forked: True X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:9508; X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: u2v9wt1qUt6HVaHmcR7KhbpNogmV2SkUdMgaG8szGZn1YQsbQJwxr/k52nYigjimt4DpQicrpfwnqXEICtKbeeH3K/K055cP/Xro7ZFnzxwYUbG13cIidcI+s7D6MRKBBJo2CNkPsZHsJZzhZqIuKYTdnVuN8wRZ56ML239My7rY9xjrm38qeEeUtylw7fhecxGLf4KyCZb0+DyhO5femkYh+D6kkEVwEU5nuRN9TEZIUo2QPTQftRD7UQ4MYMlbZwnBvpMVxxDVZXZNvpDK9/fzYtLuwAyR/fhuPRz5gwJ2XW/gYGGZAj1jL8X9bYvEyJKsNWEKH9sUKIOJp5CV9OCSORXtSO2Ybcrobq4AtoRwSfj9q1O3eGAY7/sKIHQvMSEuDG0fb3v+UHx1BqVsYAYSZgcDRneEIZbO7f0d4SWNg0jkXpM2tcQ/TJsrbno5KajILdHtujlAi3Mi34Zl0IOkahzTlDzI+ffkBvNeWW8sttChf2o+Luw/YJRboQtB+LXZnDIzmYWig8tGA6QbDDfOs+Cyc/d4O3QUADhe5KvnBgnkwb8JqOJCf1hIm/5mHm4oAiCyOgva99bGkEJxmdXkOl8JjakcvmYsvInqnelLvt09U9nPcbzAjWI6P9PPITwhzARlqQpUnBntKcQ5QW+adjokuEUlKHKiVj3t6cYOhCvJe0GUirFtLc8YigiN4akTzKOLic8bqgSQ2ZPyJ7sQqBz9jWIx2IIVuMuDsF4= X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:PAXPR04MB8653.eurprd04.prod.outlook.com; PTR:; CAT:NONE; SFS:(7916004)(366004)(9686003)(966005)(8676002)(2906002)(66476007)(33656002)(66946007)(66556008)(83380400001)(33716001)(316002)(6666004)(86362001)(5660300002)(38100700002)(186003)(6916009)(8936002)(1076003)(508600001)(6486002)(6496006); DIR:OUT; SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?us-ascii?Q?CLbzsvi9X+z0L881O9y1INghheGge/eI4LEFBJAv8m3/0KjTS+RuaX6cTp7/?= =?us-ascii?Q?aBSN4QjsnWx2NpfF+RMwTUd/5xcv9rtH9kA7rv8olfyV9ODZ2pQr5fReknXV?= =?us-ascii?Q?/dv6LvEMXFpN45suuyIb4yeZqEB3fDWch/lujEhEzAafLrKqWgfxSTjyAwkM?= =?us-ascii?Q?KXu+oEpOmYQ2CAldOB0VDeAsJDH04zNGs10x9FpUlsMbuZDfofpeBXo5SZJm?= =?us-ascii?Q?J42EI5MqTq9v9CMNKShjXQYbBHlcmdo1ig8zndy+u0yCkP00YwPFn2mKniNZ?= =?us-ascii?Q?EDr0fNCFawLdzGsvQnLg255cywFdSxcMM6sX9mzU4W1L6GB+4VGZwEdj/rAs?= =?us-ascii?Q?HBBAIjeJtNcMkFDb/jkE/frOSuBLLdCVfuCmF/Hv4IIMhr0UFaA6+EqBAX1O?= =?us-ascii?Q?xCPHB3sLa3s38qpq2pCK8XdXKk3v67o4CSKsqHJ4C2ZlBxEYoH7cev8G//uO?= =?us-ascii?Q?69JdtMSrQpnUbDWyywO9Jz5sKF8c5lOcQHWF2jOarXGQ3NqKSH4Lu2etaLjb?= =?us-ascii?Q?sYqZk8jFgHH3murv9dVzKzDG0BF+x2AcZVkhYQwLUcJwSlStKJm7e9T/7myJ?= =?us-ascii?Q?OJHVF9AAcE0qJXOUJJilouzCcz8LkATgzYLXeapAQnS6lWV5CHY4Vlu0tDoZ?= =?us-ascii?Q?GhVlwhcq417p8GLEII2FTebQW+CIvlgHUNlT9oLDW2J+WmwODh1013M3PN2O?= =?us-ascii?Q?Zbp5zGX91zwsxCEdHOgiMtGUKRc30Q3P+Azj1tc9eOJUK5rRVLf2p1UUj64c?= =?us-ascii?Q?hRcusehWTsyFfoUhqPs5xGVlCsc4c0HWZHwwLFbH7MbkJfBt/K35aAbsfJRc?= =?us-ascii?Q?UUCy2JpFLuRhcmE1Tkh3CyVuZ1UUwXe51N2teOp/T6bZjriXBn40lA+Dmzsh?= =?us-ascii?Q?O59jQQpIcskeo502x48wMywGgq+34r6GNyPl01OrJxsykdI2oy/K6OgnhDB1?= =?us-ascii?Q?PGzLKahrgrlzJYSOny3M2hiGRsn0CUbw/yKet6XtHLrokdbuhYTx7cXtU5mi?= =?us-ascii?Q?tnGcb3hZCoa3O2sCLeqUqvg9PU5kZKmsTi3Ao+PrlUifsWdbEiqxoNBptxmX?= =?us-ascii?Q?Vw/NlriBDE/+/5QLjyxglb6JMNWUxHXWnSGVSJ87IZRJOuq9SxVvtmr1UyJU?= =?us-ascii?Q?+dXqMV+3L//FuZHs7de4EbvaotQCOsFd0mEmJaqrby0zYS9yNuTLxFRdii8u?= =?us-ascii?Q?NRXaF6X+Igcg4l3sUxCupRuc0ITBYfbCLm+fuxaBzkckELf96DSCA47oc/jZ?= =?us-ascii?Q?Ez8N5nSieQhPdSbJMcOHEufcv3k24gwVUDNxyrhSvO5ZR8r9r0XE65OX5MMa?= =?us-ascii?Q?HfxbV+cGTTZsOKR8VLX9XHNmg6bw0ED2JhKgIPdjELgtOr8CQ/p9W77/kA2l?= =?us-ascii?Q?Oo+XTYWkPS+PwLuBwuIm9auXarVB?= X-OriginatorOrg: suse.com X-MS-Exchange-CrossTenant-Network-Message-Id: d5b4130d-acaf-4f01-e3c3-08d9743c81e9 X-MS-Exchange-CrossTenant-AuthSource: PAXPR04MB8653.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 10 Sep 2021 09:22:27.7976 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: f7a17af6-1c5c-4a36-aa8b-f5be247aa4ba X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: W6EWAhELZM52NkkaBIfpYA02TZsvw6IGRt7P+UM0qqbZpFAl0vDl2Zl1BSdbKc6a X-MS-Exchange-Transport-CrossTenantHeadersStamped: PAXPR04MB8443 Received-SPF: pass client-ip=194.104.111.102; envelope-from=mchang@suse.com; helo=de-smtp-delivery-102.mimecast.com X-Spam_score_int: -27 X-Spam_score: -2.8 X-Spam_bar: -- X-Spam_report: (-2.8 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, MSGID_FROM_MTA_HEADER=0.001, RCVD_IN_DNSWL_LOW=-0.7, RCVD_IN_MSPIKE_H2=-0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: grub-devel@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: The development of GNU GRUB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 10 Sep 2021 09:22:38 -0000 On Wed, Sep 08, 2021 at 09:37:52PM +0200, Daniel Kiper wrote: > On Fri, Sep 03, 2021 at 09:21:39AM +0800, Michael Chang via Grub-devel wrote: > > On Thu, Sep 02, 2021 at 02:12:52PM +0200, Daniel Kiper wrote: > > > On Thu, Sep 02, 2021 at 01:48:30PM +0800, Michael Chang via Grub-devel wrote: > > > > On Wed, Sep 01, 2021 at 06:38:22PM +0200, Daniel Kiper wrote: > > > > > On Tue, Aug 31, 2021 at 03:12:28PM +0800, Michael Chang via Grub-devel wrote: [snip] > > just that I can't resist to fix problem from our users who opted to use > > "btrfs partition" which differs to "short mbr gap" with a lot more user > > base and sensible usecases. > > > > FWIW we want to address this problem, because mbr gap is adjustable via > > re-partitioning but btrfs bootloader area is not. > > Huh! The "btrfs partition" sounds like not resizable MBR gap! I am not > happy with it just at the beginning. Anyway, could you explain your use > case in more details including example commands and why core.img seems > landing in the "btrfs partition". I am especially curious about the > latter because I think the "btrfs partition" and things like that was > designed for something else, e.g., storing grubenv data. And why this > solution is i386 specific? Installing to btrfs partition is not something exotic to grub, it is actually a supported usecase by grub for a long time. Also zfs has similar design, see: c7ba4f698 Support BtrFS embedding. ba102053c Support ZFS embedding. To make it happen, you just have to point the btrfs device to grub-install and it will setup and embed image there. That worked quite nicely until the zstd support came into play. On current git head, the command fails with core.img is too large. # ./grub-install -d ./grub-core /dev/vda2 Installing for i386-pc platform. ./grub-install: warning: your core.img is unusually large. It won't fit in the embedding area. ./grub-install: error: filesystem `btrfs' doesn't support blocklists. With this patch, the embedding still works but warns the user zstd is disabled, also instructing them to use MBR if they need the zstd feature to work. # ./grub-install -d ./grub-core /dev/vda2 Installing for i386-pc platform. ./grub-install: warning: btrfs zstd compression is disabled, please change install device to disk. Installation finished. No error reported. It is very i386-pc centric, as it is often used by legacy mbr boot code with which active partition is chainloaded. Some people still thinks this is the right thing to do and feels more comfortable this way to manage their multiple distrubution booting, compared with os-prober. Thanks, Michael > > Daniel > > _______________________________________________ > Grub-devel mailing list > Grub-devel@gnu.org > https://lists.gnu.org/mailman/listinfo/grub-devel