X-Recipient: archive-cygwin AT delorie DOT com DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 3F5123858C5E DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cygwin.com; s=default; t=1712050163; bh=3ufnirE5JRgPpwJfwZdRuek/qlvFNWHlD0/TCk/tH+4=; h=Subject:To:References:Date:In-Reply-To:List-Id:List-Unsubscribe: List-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To:Cc: From; b=qy47SaTSppWekoQ9Ce5/qTmB4BEGvJc18ND14/CsGW/+LxFvRkYzUKKZpvWomnt3r w2yS5QE1fNxfHeos+8US3N7CROiRHRMdih1ZrJgQn/CYNlJ/02mnudTLIQCqQPSVf0 HUNTsqDYre7RXwwxa0eg3bX60fWtmypkXl6wbE38= X-Original-To: cygwin AT cygwin DOT com Delivered-To: cygwin AT cygwin DOT com DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 8C9633858CDB ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 8C9633858CDB ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1712050083; cv=none; b=oM5oWeUG3IvY8MiNh/LVMMQXsgK/ITWR+TnKIVyE+emu5Jw1F5WmYrRwpgkI6FWRmiEj3mpIXEt5F9IbU7pyYSdrau/QMsvrg4p/Xf7RHSYuHk66DO+5xOLxt3qb1kOzefkkY7XcFfw+toIYbqEN+EgkdIuRZm4STTTJsmNMfUE= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1712050083; c=relaxed/simple; bh=cv69h6jVXKz376cvi0FjUHPhLVpeTCBsp4hGMcSnNeA=; h=Subject:To:From:Message-ID:Date:MIME-Version; b=pWG5BXL4YwWvVAM9UE7UUUBSguFiDxK4i+n/I3XhoA/yym5UveZJ8rjwITVbLApcFXDK99NSLntXz/OJtmpMRz3wQd1uMk6q20VDaHlPpF+HYqnJg7bArlh/gLZXha3+5XW0JW/PrSKSkyhBmGGkt2rJPtIC/26RrU/QgkJGwFA= ARC-Authentication-Results: i=1; server2.sourceware.org Subject: Re: util-linux-2.39.3-1: libblkid returns invalid physical_sector_size To: cygwin AT cygwin DOT com References: <0fb74540-3878-206d-b623-15437fe79b01 AT t-online DOT de> <72594c25-f142-42f0-b4cd-e2650e8044db AT maxrnd DOT com> Message-ID: <6ee32dd4-ce8a-ff79-9245-ced85f4d336e@t-online.de> Date: Tue, 2 Apr 2024 11:27:55 +0200 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:91.0) Gecko/20100101 SeaMonkey/2.53.16 MIME-Version: 1.0 In-Reply-To: <72594c25-f142-42f0-b4cd-e2650e8044db@maxrnd.com> X-TOI-EXPURGATEID: 150726::1712050077-037FD89A-721E1AA0/0/0 CLEAN NORMAL X-TOI-MSGID: fe2d6887-8bf2-4ee1-bf7d-f9d20bbd65ae X-Spam-Status: No, score=-4.2 required=5.0 tests=BAYES_00, FREEMAIL_FROM, KAM_DMARC_STATUS, NICE_REPLY_A, RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H3, RCVD_IN_MSPIKE_WL, SPF_HELO_NONE, SPF_PASS, TXREP autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org X-BeenThere: cygwin AT cygwin DOT com X-Mailman-Version: 2.1.30 Precedence: list List-Id: General Cygwin discussions and problem reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , From: Christian Franke via Cygwin Reply-To: cygwin AT cygwin DOT com Cc: Christian Franke Content-Type: text/plain; charset="utf-8"; Format="flowed" Errors-To: cygwin-bounces+archive-cygwin=delorie DOT com AT cygwin DOT com Sender: "Cygwin" Content-Transfer-Encoding: 8bit X-MIME-Autoconverted: from base64 to 8bit by delorie.com id 4329TPNb1768104 Hi Mark, Mark Geisert via Cygwin wrote: > Hi Christian, > > On 3/31/2024 1:11 AM, Christian Franke via Cygwin wrote: >> Testcase: >> >> # cygcheck -f /sbin/fdisk.exe >> util-linux-2.39.3-1 >> >> # /sbin/fdisk.exe -l /dev/sdd >> Disk /dev/sdd: 465.76 GiB, 500107862016 bytes, 976773168 sectors >> Units: sectors of 1 * 512 = 512 bytes >> Sector size (logical/physical): 512 bytes / 34359738880 bytes >> I/O size (minimum/optimal): 34359738880 bytes / 34359738880 bytes > [...valuable investigation and patch suggestion elided...] > > Your suggested patch looks fine to me.  I have added it to the patch > deck for a new util-linux 2.39.3-2, which has just been uploaded.  The > patch allows fdisk.exe to report the three correct values in my > limited testing. > Thanks for the report and the patch! You're welcome. BTW, according to the Linux kernel sources, BLKPBSZGET etc return 'unsigned int' and not 'unsigned long' since first appearance in 2.6.32-rc3 (2009?): https://elixir.bootlin.com/linux/v2.6.32-rc3/source/block/ioctl.c#L276 https://elixir.bootlin.com/linux/v2.6.32-rc3/source/block/compat_ioctl.c#L743 https://elixir.bootlin.com/linux/v6.8.2/source/block/ioctl.c#L533 So I don't understand why the mentioned code would be correct for Linux. -- Problem reports: https://cygwin.com/problems.html FAQ: https://cygwin.com/faq/ Documentation: https://cygwin.com/docs.html Unsubscribe info: https://cygwin.com/ml/#unsubscribe-simple