Received: from list by lists.gnu.org with archive (Exim 4.90_1) id 1nH3rg-0001Tk-KV for mharc-grub-devel@gnu.org; Mon, 07 Feb 2022 08:15:32 -0500 Received: from eggs.gnu.org ([209.51.188.92]:40476) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nH3rd-0001Q7-LA for grub-devel@gnu.org; Mon, 07 Feb 2022 08:15:30 -0500 Received: from jpoiret.xyz ([206.189.101.64]:40040) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nH3ra-00019N-2n for grub-devel@gnu.org; Mon, 07 Feb 2022 08:15:29 -0500 Received: from authenticated-user (jpoiret.xyz [206.189.101.64]) by jpoiret.xyz (Postfix) with ESMTPA id 153A51851F1; Mon, 7 Feb 2022 13:15:07 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=jpoiret.xyz; s=dkim; t=1644239709; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=qJ30mWDFp26Mpmo/Iq0ZxFVVFwE1fw7aEguxsxH3jcU=; b=ltFnSmLaOe07DfbgeQM3HQJ7cG9Amy2zSmrIAoacsUh/Dre55PYTEHQX+8QtYzlHtJc/Kv XTEsg0K3OYwyAKKwhLpkQPnepIzFBIrMlezjZ/w/Uzr8fGJxceC4eLHTEJCxnQPZn27emV SYwsgwQ1yGcedQwAEAd6SQqgHQ7qrgz85uBURCVn95pbfyhryi+z8abIWnSpBRWKnlM3EF C6R2TGX/cnBLemJ8KBK7ZGRM/khJO591P95lLnOEB4yZVdIVj8dSPTQPSi1qOSUwFd+hkz DLc2/6xY9yFsql1iEFKRIyDIuj4i+sBcq+gIog6R7MM75EJ6V0h1tfbfSAG5hg== From: Josselin Poiret To: Fabian Vogt , The development of GNU GRUB , Patrick Steinhardt Cc: Michael Chang , Josselin Poiret via Grub-devel , Pierre-Louis Bonicoli Subject: Re: [PATCH 3/4] luks2: set up dummy sector size during scan In-Reply-To: <2946843.ILLGAiG1oY@linux-e202.suse.de> References: <43151052.QDiU1Cuimh@linux-e202.suse.de> <8735mkbj26.fsf@jpoiret.xyz> <2946843.ILLGAiG1oY@linux-e202.suse.de> Date: Mon, 07 Feb 2022 14:15:07 +0100 Message-ID: <877da6rf6s.fsf@jpoiret.xyz> MIME-Version: 1.0 Content-Type: text/plain Authentication-Results: jpoiret.xyz; auth=pass smtp.auth=jpoiret@jpoiret.xyz smtp.mailfrom=dev@jpoiret.xyz X-Spamd-Bar: / Received-SPF: pass client-ip=206.189.101.64; envelope-from=dev@jpoiret.xyz; helo=jpoiret.xyz X-Spam_score_int: 2 X-Spam_score: 0.2 X-Spam_bar: / X-Spam_report: (0.2 / 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, FROM_SUSPICIOUS_NTLD=0.498, PDS_OTHER_BAD_TLD=1.769, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=no autolearn_force=no X-Spam_action: no action X-BeenThere: grub-devel@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: The development of GNU GRUB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 07 Feb 2022 13:15:31 -0000 Hi Fabian, Fabian Vogt writes: > Did you have a look at my approach? That effectively does the same, but using a > single ioctl instead of anything complex with DM directly. I agree that it's sufficient for sector_size, but we still need the cryptodisk algorithm so that grub-install will know which crypto modules to include. libdm is actually a helper library around dm-specific ioctls, since they are apparently annoying to use, so in the end we're still using the same interface :) As for the 4 patches, since the actual sector_size is available to us, I think using 512 in all cases or adding a specific 0 sector_size is something we should avoid. Best, -- Josselin Poiret