From mboxrd@z Thu Jan 1 00:00:00 1970 Return-path: Received: from mout.kundenserver.de ([212.227.17.24]) by metis.ext.pengutronix.de with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1kS0Wx-0005Ck-Og for DistroKit@pengutronix.de; Mon, 12 Oct 2020 18:18:37 +0200 Received: from [192.168.1.155] ([77.2.5.48]) by mrelayeu.kundenserver.de (mreue109 [212.227.15.183]) with ESMTPSA (Nemesis) id 1Mgek6-1jyCYA2ree-00h92s for ; Mon, 12 Oct 2020 18:18:34 +0200 From: "Enrico Weigelt, metux IT consult" Message-ID: Date: Mon, 12 Oct 2020 18:18:33 +0200 MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="------------20ECF13263B765FF450B1BE5" Content-Language: tl Subject: [DistroKit] patch for genimage-12: fix -ENOTTY error List-Id: DistroKit Mailinglist List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: distrokit-bounces@pengutronix.de Sender: "DistroKit" To: DistroKit@pengutronix.de This is a multi-part message in MIME format. --------------20ECF13263B765FF450B1BE5 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 8bit Hi folks, Under some circumstances, FS_IOC_FIEMAP ioctl maybe return -ENOTTY (possibly on multiarch setup - 32bit userland on 64bit kernel). This is case isn't exctly an error, instead another variant of operation not supported. Therefore treat it the same like EOPNOTSUPP. See attachment. --mtx -- --- Hinweis: unverschlüsselte E-Mails können leicht abgehört und manipuliert werden ! Für eine vertrauliche Kommunikation senden Sie bitte ihren GPG/PGP-Schlüssel zu. --- Enrico Weigelt, metux IT consult Free software and Linux embedded engineering info@metux.net -- +49-151-27565287 --------------20ECF13263B765FF450B1BE5 Content-Type: text/x-patch; charset=UTF-8; name="0001-fix-enotty.patch" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="0001-fix-enotty.patch" diff -ruN genimage-13.1/util.c genimage-13/util.c --- genimage-13.orig/util.c 2020-10-07 22:54:05.448271228 +0200 +++ genimage-13/util.c 2020-05-08 09:32:35.201970284 +0200 @@ -387,7 +387,7 @@ free(fiemap); /* If failure is due to no filesystem support, return a single extent */ - if (ret == -EOPNOTSUPP) + if ((ret == -EOPNOTSUPP) || (ret == -ENOTTY)) return whole_file_exent(size, extents, extent_count); image_error(image, "fiemap %s: %d %s\n", filename, errno, strerror(errno)); --------------20ECF13263B765FF450B1BE5 Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ DistroKit mailing list DistroKit@pengutronix.de --------------20ECF13263B765FF450B1BE5--