From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from list by lists.gnu.org with archive (Exim 4.90_1) id 1j6XYr-0001QJ-26 for mharc-grub-devel@gnu.org; Tue, 25 Feb 2020 05:35:33 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:35296) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1j6XYk-0001BU-1c for grub-devel@gnu.org; Tue, 25 Feb 2020 05:35:29 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1j6XYf-0001QR-1R for grub-devel@gnu.org; Tue, 25 Feb 2020 05:35:25 -0500 Received: from m9a0013g.houston.softwaregrp.com ([15.124.64.91]:36773) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1j6XYe-0001K3-QL for grub-devel@gnu.org; Tue, 25 Feb 2020 05:35:20 -0500 Received: FROM m9a0013g.houston.softwaregrp.com (15.121.0.191) BY m9a0013g.houston.softwaregrp.com WITH ESMTP; Tue, 25 Feb 2020 10:34:39 +0000 Received: from M4W0334.microfocus.com (2002:f78:1192::f78:1192) by M9W0068.microfocus.com (2002:f79:bf::f79:bf) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.1591.10; Tue, 25 Feb 2020 10:33:24 +0000 Received: from NAM12-DM6-obe.outbound.protection.outlook.com (15.124.8.10) by M4W0334.microfocus.com (15.120.17.146) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.1591.10 via Frontend Transport; Tue, 25 Feb 2020 10:33:24 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=IymYcF1Lx7bHZHvvHzkRt4ZWtaCDXs0Dv0CoqP91FNzJl+Bb34YBarVzl1rl7JHQgkv4jdgKQoYVjf6OaVShkKxKjjPwuGzH8kNMtvFQSIAf4t+C843hSaQvlspBKoVSp58n40+eLVgNK1zUc0wgHsjAfPxaIsn+c6BC/0sSfN/Qxo1ZpeLk2zpYN4DmXVuDTVYQRE/qdEEkMs9l9unxgeLTl5bUZnasQvymULIV9Xrg6mKaopVOI+uV6hBoXyaNRLV8WaUEXO6bUa4dAP8GB7+zh+1KXmywHtKXLo/uu6cPJt12HO561qfzllHQ3ugKacqYiZLj5KZSFouWbBAnng== 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:X-MS-Exchange-SenderADCheck; bh=x3FN11d/2Xf7SY6FU5iev6Sad/rzIY345vOKYnSYhHI=; b=iolUCtlc6Q/mF3+OzcaQZb9XGL13j+WO06sKLTUPhGgXHBsTqPkuUYAz7agmF9Pb6AYZfvFsnzCsk49CBpV6848RDLUrOskZm5m+fZUBK1QdZ+1bwujb9VOEyKiplVrruCy8VoUJhxAD5FaQE1uXjGXTlFaEKDvv5ZddYIXF03mpSRC9IIZxYA9aTSnRWaxRJn0Hm/DpYQopYIjHGW/UZcn9Bn8Qvvl75KH0I/UUvc6pKpgSeLHe2nf6bywjZ8teCNd2KN8j6/2cQSF7nkM7v+g671DnETBRUzG9y0gpoP9QrghnEH0diZZwH7eYv+3n0V7dErZrVCfCidSh0SksHA== 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: spf=none (sender IP is ) smtp.mailfrom=MChang@suse.com; Received: from BY5PR18MB3188.namprd18.prod.outlook.com (2603:10b6:a03:1ac::18) by BY5PR18MB3122.namprd18.prod.outlook.com (2603:10b6:a03:1af::11) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.2750.22; Tue, 25 Feb 2020 10:33:23 +0000 Received: from BY5PR18MB3188.namprd18.prod.outlook.com ([fe80::28ac:20e6:d692:e83]) by BY5PR18MB3188.namprd18.prod.outlook.com ([fe80::28ac:20e6:d692:e83%5]) with mapi id 15.20.2750.021; Tue, 25 Feb 2020 10:33:23 +0000 Date: Tue, 25 Feb 2020 18:33:09 +0800 From: Michael Chang To: The development of GNU GRUB CC: Daniel Kiper , Matthew Ahrens , Brian Behlendorf , George Wilson , Sebastien Roy , , , Subject: Re: [PATCH] ZFS/other CoW FS save_env support Message-ID: <20200225103309.GA14273@mazu> References: <20200224110247.nxmpvzzsv66ggnqc@tomti.i.net-space.pl> Content-Type: text/plain; charset="us-ascii" Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.10.1 (2018-07-13) X-ClientProxiedBy: LO2P265CA0327.GBRP265.PROD.OUTLOOK.COM (2603:10a6:600:a4::27) To BY5PR18MB3188.namprd18.prod.outlook.com (2603:10b6:a03:1ac::18) MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 Received: from mazu (60.251.47.115) by LO2P265CA0327.GBRP265.PROD.OUTLOOK.COM (2603:10a6:600:a4::27) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.2750.18 via Frontend Transport; Tue, 25 Feb 2020 10:33:18 +0000 X-Originating-IP: [60.251.47.115] X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 463b9080-99d1-4868-d490-08d7b9de23c1 X-MS-TrafficTypeDiagnostic: BY5PR18MB3122: X-MS-Exchange-Transport-Forked: True X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:10000; X-Forefront-PRVS: 0324C2C0E2 X-Forefront-Antispam-Report: SFV:NSPM; SFS:(10019020)(4636009)(376002)(366004)(39860400002)(136003)(396003)(346002)(189003)(199004)(53546011)(66946007)(55236004)(16526019)(9576002)(186003)(66556008)(9686003)(55016002)(8936002)(33656002)(4326008)(81166006)(8676002)(81156014)(26005)(5660300002)(6916009)(956004)(1076003)(316002)(2906002)(52116002)(6496006)(66476007)(33716001)(966005)(54906003)(478600001)(86362001)(6666004); DIR:OUT; SFP:1102; SCL:1; SRVR:BY5PR18MB3122; H:BY5PR18MB3188.namprd18.prod.outlook.com; FPR:; SPF:None; LANG:en; PTR:InfoNoRecords; MX:1; A:1; Received-SPF: None (protection.outlook.com: suse.com does not designate permitted sender hosts) X-MS-Exchange-SenderADCheck: 1 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: /SVhJxV8kw3Yp3kFWrjraXhqhnv7N0oe4jogm46Ddjtjk2R9R65ULxq33MsBLGIv0dWy5HoY941em8J6P6EC8R4KQYrRYMJFuCyB0AHk3XTunFAVzv11Ju8Z3UdNQLJECy5dgbGwM4n+Yc419ABt8uI7c2wVsA/V+/RLbeIoqiRnbDhYBfIGbsbnbZNfjefq6JAXsDE6ivgusop8FYNNXd7dz2a1uF4N9PgKZK1/jNvk2R+BI/EC0z4whfn+xro4uA+wdvORo7CLKbVCuEyxz81eSyiyedJJ5AIJRpirqOWKRo8RTFFjwfFn7rDKVRwStYH/CnKtRDz24LUSuTZFjrZ5jyqWZoH4lwfXhWdb/WfUn12cu/dU8pJOVibWmLmFLar6NCcuzqgLmMuXRgR2tADgJwKSPA4G/YRMCOiB/Db4C62hLwFl9MeCH+4hd4GBh/34e57YSA8bsIFot3+m3rMMkSl8a9MlyXkYqCNAoj+0yzQzRT977cGOc7VuvRu+PJq8eSWtgvUInBwgM131Qw== X-MS-Exchange-AntiSpam-MessageData: RT0s271jQh7BSEoGuASMQpdwpFzeeGzqOyV21BIulXcWObG+SNWr0LiTkAZFGKEFj92DV+pZEEUGNE6y+nrNYnyePnY0HwkeMsZ+f3FDDAYr549jtAh8h6uxu5m5QWcIHHqpCFI3nEWsrcTHN3esOA== X-MS-Exchange-CrossTenant-Network-Message-Id: 463b9080-99d1-4868-d490-08d7b9de23c1 X-MS-Exchange-CrossTenant-OriginalArrivalTime: 25 Feb 2020 10:33:23.3136 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 856b813c-16e5-49a5-85ec-6f081e13b527 X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: ImApf0YDU6zCMlmiWzo/+d9mQWU+Zv48ZtzEUXlFW2sILYtxy6cT0DDbrBo2dq/t X-MS-Exchange-Transport-CrossTenantHeadersStamped: BY5PR18MB3122 X-OriginatorOrg: suse.com X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] [fuzzy] X-Received-From: 15.124.64.91 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: Tue, 25 Feb 2020 10:35:30 -0000 On Mon, Feb 24, 2020 at 10:30:36AM -0800, Paul Dagnelie wrote: > On Mon, Feb 24, 2020 at 3:03 AM Daniel Kiper wrote: > > > > > > Why "root" not "boot"? > That was a typo on my part; the code uses grub_guess_root_device to > find the devices backing the default grub directory, but in most > configurations, this should attempt to locate the boot filesystem > instead of the root. I was uncertain of a better way to consistently > determine the boot filesystem, and this portion of the code was copied > from another GRUB patch > (https://build.opensuse.org/package/view_file/openSUSE:Factory/grub2/grub2-grubenv-in-btrfs-header.patch?expand=1). I used to have the same confusion as well. But I tend to interpret that as "root device/filesystem for grub" and thus not from the viewpoint of a linux system. Essentially we have been using "root" as the name for the environment variable pointing to the grub device in which /boot resides and the concept just carried over from it to the description. So in my opinion it certainly not a typo but rather a common expression mentioned by the source code. Although it would become misleading at times when people have to take in with the linux system, I still prefer to keep it as it wasn't that much a mistake by itself. :) Thanks. Michael > > > > > Yes, please split the patch into smaller patches. Please do one logical > > change per patch. > > > > I quickly went through the patch and pointed things which I spotted at > > first sight. I will provide more comments when you split the patch into > > separate patches. > > > > Next time please CC following people too: javierm@redhat.com, > > maciej.pijanowski@3mdeb.com and piotr.krol@3mdeb.com. > Understood! I will post an updated version hopefully today or tomorrow. > > > > > I think that you can drop parenthesis here. And please use NULL instead of 0. > Will do. In general, this was one of my questions about writing new > code in this code base. There are several things where I decided to go > with consistency with surrounding code instead of what would commonly > be preferred in modern coding standards or by the style guide (see > also, the block comment style you mentioned further down). Is there a > preference in this codebase against consistency when other > considerations are also relevant? > > > > -- > Paul Dagnelie > > _______________________________________________ > Grub-devel mailing list > Grub-devel@gnu.org > https://lists.gnu.org/mailman/listinfo/grub-devel