From patchwork Tue Mar 28 13:26:46 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: "Smith, Pieter" X-Patchwork-Id: 744255 X-Patchwork-Delegate: blogic@openwrt.org Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from arrakis.dune.hu (arrakis.dune.hu [78.24.191.176]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 3vssBM1P3Cz9s03 for ; Wed, 29 Mar 2017 00:27:05 +1100 (AEDT) Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (1024-bit key; unprotected) header.d=Philips.onmicrosoft.com header.i=@Philips.onmicrosoft.com header.b="qrgAYQnA"; dkim-atps=neutral Received: from arrakis.dune.hu (localhost [127.0.0.1]) by arrakis.dune.hu (Postfix) with ESMTP id 2DF01B913C2; Tue, 28 Mar 2017 15:26:59 +0200 (CEST) X-Spam-Checker-Version: SpamAssassin 3.4.1 (2015-04-28) on arrakis.dune.hu X-Spam-Level: X-Spam-Status: No, score=-1.5 required=5.0 tests=BAD_ENC_HEADER,BAYES_00, T_DKIM_INVALID autolearn=unavailable autolearn_force=no version=3.4.1 Received: from arrakis.dune.hu (localhost [127.0.0.1]) by arrakis.dune.hu (Postfix) with ESMTP; Tue, 28 Mar 2017 15:26:59 +0200 (CEST) Received: from arrakis.dune.hu (localhost [127.0.0.1]) by arrakis.dune.hu (Postfix) with ESMTP id B0FABB80CEB for ; Tue, 28 Mar 2017 15:26:57 +0200 (CEST) X-policyd-weight: NOT_IN_SBL_XBL_SPAMHAUS=-1.5 NOT_IN_SPAMCOP=-1.5 CL_IP_NE_HELO=1.5 (check from: .philips. - helo: .eur01-db5-obe.outbound.protection.outlook. - helo-domain: .outlook.) FROM_NOT_FAILED_HELO(DOMAIN)=3 REV_IP_EQ_HELO_DOMAIN=-1.25; rate: 0.25 Received: from EUR01-DB5-obe.outbound.protection.outlook.com (mail-db5eur01on0119.outbound.protection.outlook.com [104.47.2.119]) by arrakis.dune.hu (Postfix) with ESMTPS for ; Tue, 28 Mar 2017 15:26:55 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=Philips.onmicrosoft.com; s=selector1-philips-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=R0AWL7UFPn1eUppDPlFJ0cuBGx3J6rKhxRNFWm/bFpM=; b=qrgAYQnAx+5S9BYgASXHeaCHlRQlPttwWN3uWQwuV17HH8H3BWhG5c6vFNymBHXGBQIm+bMQvIx/tX3/XRB8nNzAmOubQ1rD00y2jMAxSWLoGCNocyzunFrdfn2BTbo5mUAHDhHYE7v4kebMm52Fydn32vEkaVztFRHSEUm2oUw= Received: from VI1P122CA0012.EURP122.PROD.OUTLOOK.COM (129.75.165.210) by HE1P122MB0058.EURP122.PROD.OUTLOOK.COM (129.75.140.217) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.991.14; Tue, 28 Mar 2017 13:26:53 +0000 Received: from AM1FFO11FD023.protection.gbl (2a01:111:f400:7e00::186) by VI1P122CA0012.outlook.office365.com (2603:10a6:820:33::18) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.991.14 via Frontend Transport; Tue, 28 Mar 2017 13:26:52 +0000 Authentication-Results: spf=neutral (sender IP is 40.103.22.84) smtp.mailfrom=philips.com; gmail.com; dkim=none (message not signed) header.d=none; gmail.com; dmarc=none action=none header.from=philips.com; Received-SPF: Neutral (protection.outlook.com: 40.103.22.84 is neither permitted nor denied by domain of philips.com) Received: from 011-smtp-out.Philips.com (40.103.22.84) by AM1FFO11FD023.mail.protection.outlook.com (10.174.64.212) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P384) id 15.1.977.7 via Frontend Transport; Tue, 28 Mar 2017 13:26:53 +0000 Received: from VI1PR9003MB0253.MGDPHG.emi.philips.com (129.75.99.86) by VI1PR9003MB0256.MGDPHG.emi.philips.com (129.75.99.89) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.991.14; Tue, 28 Mar 2017 13:26:47 +0000 Received: from VI1PR9003MB0253.MGDPHG.emi.philips.com ([129.75.99.86]) by VI1PR9003MB0253.MGDPHG.emi.philips.com ([129.75.99.86]) with mapi id 15.01.0991.020; Tue, 28 Mar 2017 13:26:46 +0000 From: "Smith, Pieter" To: =?iso-8859-2?Q?Rafa=B3_Mi=B3ecki?= , John Crispin Thread-Topic: Factory startup issues since mount_root / libfstools improvements in Chaos Calmer Thread-Index: AdKnxAvrFeWVfZd4SICGIqtw0QCajg== Date: Tue, 28 Mar 2017 13:26:46 +0000 Message-ID: <1b0f8ebd7c9748d099aea99949d7ffb8@VI1PR9003MB0253.MGDPHG.emi.philips.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [80.246.199.209] X-MS-Office365-Filtering-Correlation-Id: 99d92649-6db2-4e33-934e-08d475de1927 MIME-Version: 1.0 X-OrganizationHeadersPreserved: VI1PR9003MB0256.MGDPHG.emi.philips.com X-EOPAttributedMessage: 0 X-MS-Office365-Filtering-HT: Tenant X-Forefront-Antispam-Report: CIP:40.103.22.84; IPV:NLI; CTRY:US; EFV:NLI; SFV:NSPM; SFS:(10019020)(6009001)(39860400002)(39850400002)(39410400002)(39840400002)(39450400003)(2980300002)(199003)(55904004)(189002)(374574003)(85714005)(9170700003)(38730400002)(55016002)(8676002)(356003)(8746002)(8936002)(53546009)(4326008)(2900100001)(5660300001)(81166006)(81156014)(53936002)(24736003)(2906002)(47776003)(7736002)(5890100001)(305945005)(66066001)(39060400002)(575784001)(54356999)(86362001)(3846002)(6116002)(108616004)(102836003)(50986999)(189998001)(97736004)(7696004)(50466002)(105586002)(33646002)(106466001); DIR:OUT; SFP:1102; SCL:1; SRVR:HE1P122MB0058; H:011-smtp-out.Philips.com; FPR:; SPF:Neutral; MLV:ovrnspm; A:1; MX:1; PTR:InfoDomainNonexistent; LANG:en; X-Microsoft-Exchange-Diagnostics: 1; AM1FFO11FD023; 1:DVph3R3wjzoev0YRHS5q01F/M0f+LERxmDpK3X7Zz9qYLBa0icwBUqcUVvcm7bsrzZtJj+JR9kSieVze3ryp5deAgrI1HSQ2W4UoLIXgRJlrbBTUcpkQwHMq7N510wt1kQVgLlvXT+QmrPO29BLXl9FRtbW6IPCerfVgrYeU4q9IU4h6jzOlScU6ml/hCtAKxk3+6PcZAzZj/R0QN1AkWXBfM8ZVJ2V18cvmzKCQ4ORB3WvV+XmOWs1xMgN7dAyyszbLvBAAD1jOc/JyNPWR0fgyvvQxF12lD2voynJ1TdvcASXmHWsu8Nozt3h38FGcSALmA1XJg2h821OvveOAd4ASrocboARu+Xj1DULb0Ablt1qPteMThvJ+HlHnBFIJGAEpLBM0JhlH9J28hrNKYWpD82PprKxZHFRehZCe5YMXjiRa/KNYHzXJcBEyfY9Vsc45mshkV2REV3q8SuEqQDZ18RqfrqoQL7jrzENrhnJaFrPG1XUpfpBMkgBnp3OO6VX5E1293gY6B5k76PBAEg== X-CrossPremisesHeadersPromoted: AM1FFO11FD023.protection.gbl X-CrossPremisesHeadersFiltered: AM1FFO11FD023.protection.gbl X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(22001)(2017030254075); SRVR:HE1P122MB0058; X-Microsoft-Exchange-Diagnostics: 1; HE1P122MB0058; 3:yUKMr+gMalnmiwT7pZ1o06JKpt7UPYegjUc5CcJNljiHlVa1m8F5cmnfPS/KDk7rHfkrVjJIpWI2bmlATVTzrqjmZq8N5T2P36GymyGkwxAsZGo94wMr8a2qtcKVl3GuxivO0QwI5UH4nHy58lcJMieaUuKdf69k4RbLDglj76WKRfKb9ru2MSiFS+obhWUM8ruUumftu2lp71A4wzpnGi/JKzb6q8hE9FYP8RfRtMeGZYuFuzoM0Pi/Vwo4xXKVUN8Ftd+UDN/ZeoREq+ivQI5Mt+/cACgscfIpC51PW7VGroGje7xYydXXY2KcHh9Y6h7swAAo2k7FgboquFoLgha8x5p9j/skteH2JOiBk+EZoSLL6A3fJ6ybnl9aD3grf3v7rCG1ZS3+51blznsukg==; 25:Fz7pNASCs1OdzSMawgW4R3qA48TRQpnlA4kYxlGsL5AOXGPqMnsFRgRtDiB2B20Xz9PaGG8mpUTxbYrsmn4OpKVSSDo4s1bQ6ZeZUC4vvUcmXVqC92nWuQT/rn+YinxEdGZt8SUGHCJHvHjAECLrc2mdbMlI6R+jc6d/ik7/94/WG1mEOJBraucWn60e7eCxqIQbgpVx1NXuFSZmO6Os4XZs6pRoRVWTLTrkGsYIoP0mMaR1dyG+hj3tMoe0WcRrIaEVZpWb01BUR/9ktE4JI78jPFNwnJYagdSKygt1jlVuIg5tS0FoexDWzX6OVO01jswij6phfsdPAVwc1r0E/adzLQgv5u6Lk61pZmqLhjYq5HABgv5KOdKXjaLQQkPXmY6NeUMhv9xdBNJCQFcWtOr6we2KKWvtHf+1o0wNu/VU518Cm2OwfvOe7KZuUp9s28pofWb5WAKmBnXSnmODKA== X-Microsoft-Exchange-Diagnostics: 1; HE1P122MB0058; 31:0F5NyRK+PnwtWRFD0aGsEvjBEmRDvFYWCByS019oaqh3+irLa4khbNpftNZin79RYPU6mM6VzvFtfdzbr0x+/sBzfqHTezxwCyMOYW9uOPY1nWZwvASFex5zOZOw1LH/uLa4hZoQckNMpPHP4WldFud2mZQKzo0zZj8t/VfUz1MY4lYCEoOYOmGt+l8uHaPNxaVS0GG9BXjeJHrm8Oh/TU+VHcMsF/3ZgKd+92lkUdBk4obWsBJx9ricnBk2+odEQh8sKYkK75lhHEUkKyJKog==; 20:d/XYy82cajFs8Bg4dGCAjqTqyS5k6zrqyq6LUy9PIPvHaLdPjtl7wsfHsuwwAI8g/ELZ+eEcWgkJ8gNdb7G/BfVZeHq/znHni6DNUeYwvOGi6HRiDaZWRsCprk1mmzTts89sHCv7zBV5vAV7V4jqJiFkISqaJRHJvjPcb8SO7jOrbt1REy7xhF2dDC91MXznDI0qHFGggb2+/AfMt+Ox2HcmyvRS/Y53qn4x2STVu8h5QIREohVA+lPEa7xY1JNOpB7tmShDbksjngaDbxTFmg8rNoadwGNuLUM/V9PRSr+AFsgLL+RNkboeeE4NI/GPxQFScnuCdjBpbip/ALRG1SklMTtY9c0M2i9pJcXUc3uuzkkpff0+9YCZU+RT8sphXCR15zzcLn29DCDvP3loDWMLgh6sKxvstKGxwP6rovQ3+7kT6hv+OwhsX/GVcAdcVt+ACyxB7ro4izDnAzirMA2reTDqwWefmDV9jC9p1ROi4F2yFMv7s3hPb+82dLS5 X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:(260087099026482); X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(6040375)(2401047)(5005006)(8121501046)(13016025)(13018025)(3002001)(10201501046)(6055026)(6041248)(20161123562025)(20161123555025)(20161123564025)(20161123560025)(20161123558025)(6072148); SRVR:HE1P122MB0058; BCL:0; PCL:0; RULEID:; SRVR:HE1P122MB0058; X-Microsoft-Exchange-Diagnostics: 1; HE1P122MB0058; 4:W9J2APU0/+dp1jRpjXvzQtrNgDy0YmtP3qiptFMLM3gsFZo0Hb4X+lAVptT4exAQh/nEhgEUUgWDanEOukBXhlfapWvQyqQjQvpFg/0yQhm2OEACb9R1LJuce1JySSQrDW/ZEi9JlmYOyba/eq4Dc9tfjyzaKHqX6XCV/Gts3NeuWCiS57rr3vDefPVTTpo6poI7ieU3oCH5p3Nm5G9bh/zhLRXBx5K96K9ROlGEUmEYXtIQTJB8LMZdO4WLq/ye7KZMnC0jIf7W6klESh1fBQ3QQPDTNh524HVJeewmYkLw+nw23ucehAGVYop3LMzjUNFkmYWop8ZF+8aVX3kgipybA7mWW9Jcc7Dv+5xrPXtcwJcbLC4ONFDCq47Fn2f0ivnOMPsT8y3Sw8Nmf7aERW0wZ9dkyN26N1QUps3R4a3xBaUCxeMsFCc05S5fXF9tGoyq+UVC61BkDNpecRku3fdL3eFjN9fNCZEAjxCcRxnIZfxLnXWts3gMzCUlSctQi9qPDqjjZ6pEWNqYdAA1ejrlAQ0BPVDvmB9FE7RarFzWvB5soEL9/C0FSmdCfl49rmoCYx7w4Eoj/r3ru5tknenkVJGC2nYgl3O1XUCIV8D9vmRvdHH+mUQp5S+mNZuawybUVwyEi+TcmKZP36hsxd3OcUKLwRbUJ5utk38IFT6KsPnn83hssXEJF/CBPy4z X-Forefront-PRVS: 0260457E99 X-Microsoft-Exchange-Diagnostics: =?iso-8859-2?Q?1; HE1P122MB0058; 23:1AU4AZr5VAuZccz5hihMBW5sypwwTiTlhszahjx?= =?iso-8859-2?Q?eVDQXVKGfh6OsUBzoq9zDAzcwhzLD6aeLnOSAQ0FETGCVQCuCc4nHu/UiW?= =?iso-8859-2?Q?nNT62/G4wrBkp0N5Rvxlv13vTzvbmVm/RgUTmSiNLdokGVkcopktiQsa5s?= =?iso-8859-2?Q?Bp+bGfKIAdZUm8jEnKe/si9C28kmwRlDgY+gpDimNdIfCgIaT48jxmZGwc?= =?iso-8859-2?Q?ICgikrg4UVuK6+p7lKxtzvxW9dyfTVPGW3oD+Urs0xK5d6kzqatqozhzeS?= =?iso-8859-2?Q?IxtJal41446E2SyRa2W6w/WYCCNt9B6Gggsz47EktCPeG80TaCf8AW46jv?= =?iso-8859-2?Q?vcDOAVA7BhJeco48vKWGJyKa/141L1e0kPywtK78YbqdTH/6POoPz6eIc2?= =?iso-8859-2?Q?ZS5Ggp4T+xmWvTMnhpG/eYr4oYLjF7v08fuqgu2NuH7oa1BJbTPIoN9eI3?= =?iso-8859-2?Q?mTsc8zefKZNo9vTJH27xWV5l2s8DazsbiDaQx1GU5Qbrqc7dpFFPm569sL?= =?iso-8859-2?Q?bl2vvYDA6m/ziqROFGcIMTWgD3KvWlOk4o1SrW/Y1F/D6rNZlB/ayVuNQc?= =?iso-8859-2?Q?glmII6IwW9BO++XXEzNigTlS1I005yC3+7hT1lCI3KhURI+VWj/XYEkIXS?= =?iso-8859-2?Q?qwfhfBTGTKoynqKI6qb3XILOj5OolCcvdkHihJboI9Uw0TY5YEx4JWQba9?= =?iso-8859-2?Q?sizTRSk8IJOTEOYbpgdgtRtlyzZbyM9m+hdXGHBjCSyd7cBbjciOx3FAIe?= =?iso-8859-2?Q?VU3y8dPzCf/aHDvGiQYET1LZn8D76qaE2GCfVD7t5qZP+Q0DpXxzThQTE4?= =?iso-8859-2?Q?e/UxRbqt75yNo0vJ6O5yVXullH9pb8MI5OFRzc0MDKDo5hzvyOy80JOoLs?= =?iso-8859-2?Q?snXDf+TLscrroXhhBwhvL/xpeN38ICuehCBJNrcESokYLO0w/LVBpsJaWH?= =?iso-8859-2?Q?7cGONGkN6OJA0Vh3/0Jw3+siBFKxnL59nmw61ZQkys+13T8xjwyJuU1Rl+?= =?iso-8859-2?Q?KIR8pLTOiILnT4n3MzlKOowtaKEzLbn8eqiL1ReZan6R51Kfy1JRdcRgON?= =?iso-8859-2?Q?bOn5iYRHwwQ68c+scRaEq5ySphGNs1UYHyXYdPUKUVYmRxTUvn6c004cQX?= =?iso-8859-2?Q?GdPEFtc0L+tU/ftSGLKHuddkBgxaMse+O1/7uYkgJBOfsxsuzPP9II6tTR?= =?iso-8859-2?Q?bgXKj12c3bhhSwWKhb5GeZTxtIN292AVFVvm/EDJaWblCLvaPfWDnSoY6M?= =?iso-8859-2?Q?8n9mB1vmWNwRin+LzBSKghNWXCOfAvEI1WXwgZQ=3D=3D?= X-Microsoft-Exchange-Diagnostics: 1; HE1P122MB0058; 6:JuXcFh20n8PZWstrfmWE2gFJ4lBJ29oeXswDte5gyovrhT0yZWD531pYq8KOuWc/kWe1gcoc7rFJfDAjd+PD3fk1wfY2LNn+tTR2vw/48NqHcCo7EI6xmhWytY9Pl5kjof8ixWXpMR37B1e4tGw6QhBffiRP7VxtC/vW98yraGEkFw0N4ZtvrLWUSUQc6Z4FCD9hykDCckNhL7Pv9xKeHhYe0tfjymgHRSotOpSwgnhLCWMUtFsvY+GUIMSlM0W7tnppKFpGWWk/n86tPvQrjUiOhtt69njcXEgFPY7H3+KBsc5PvL05ec9WNRDt2LdBQMl58CPOY+e+rijkElx4MgXpTN+h0nFHXDXJWyferuK03IbtIoQGcbjPgSOv8Eb5ZGdmpHuvyO8nJ/J/OwbtO0QnsaiIGsYWE73IEpsO8bE=; 5:fS4wh5YWXry7DBG4r46+4f/3T0lmRuM6FS4MxVCIPePXUl47xsWtwcNy7LrEtrTSbq/we/e6qq2hj1ZltNdwql9zba1HfeuObJbiu/jeLakDJuwVfC0FJg+MuS57+pXASjbvjt6CLIb/6pSuSgT1rw==; 24:2mKHzYOKCUuX/d90RgJOJFDfHrEtNC0GzVRXbeXtESaPmS3en8T+nrOszQcBcwGjFVf42OrNTsOZxJdtNdsJt7KZWFot7yzOeEMN+6J5QEs= SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-Microsoft-Exchange-Diagnostics: 1; HE1P122MB0058; 7:OMionn+gtt3W/YJ4Wll7m/EjFX02wlF+oHWeum/fy8IWuPgYNZnebJdfX+Qg8Q/HStR3oiy4LGQlJQN3dlAUPj3RpfwdnSxshv2C9PUc8lmoX+NN95TqmTpbSyos8nNBdUWsaw2rMFlWWvpJ9H0OQpFDduwHsQPjyOTyoeUQ0eIQ+yzzhnk5ZB/6d0Di9Yhz6zV+GGYcRiTHhtasXnOQtoVnL3SY0teXWKpEduI/wYALmD6freOiqhsh3Yfte+An7qRJSdb614Uwmjs5q1sql+CH06vqBjpN5Q5KCKhnKCGUvo0JfEQXMkojszxCKyfGlQj93wBzqLA+QUTyEvJEtg== X-OriginatorOrg: philips.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 28 Mar 2017 13:26:53.0828 (UTC) X-MS-Exchange-CrossTenant-Id: 1a407a2d-7675-4d17-8692-b3ac285306e4 X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=1a407a2d-7675-4d17-8692-b3ac285306e4; Ip=[40.103.22.84]; Helo=[011-smtp-out.Philips.com] X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: HE1P122MB0058 X-MS-Exchange-CrossPremises-AuthAs: Internal X-MS-Exchange-CrossPremises-AuthMechanism: 04 X-MS-Exchange-CrossPremises-AuthSource: VI1PR9003MB0253.MGDPHG.emi.philips.com X-MS-Exchange-CrossPremises-SCL: 1 X-MS-Exchange-CrossPremises-messagesource: StoreDriver X-MS-Exchange-CrossPremises-BCC: X-MS-Exchange-CrossPremises-originalclientipaddress: 80.246.199.209 X-MS-Exchange-CrossPremises-disclaimer-hash: 7fd5309d68bb4378c576a4d2c2ad972d336f5eb0475879c2a0b14da1aac98972 X-MS-Exchange-CrossPremises-processed-by-journaling: Journal Agent X-MS-Exchange-CrossPremises-AVStamp-Service: 1.0 X-MS-Exchange-CrossPremises-Antispam-ScanContext: DIR:Originating; SFV:NSPM; SKIP:0; X-OrganizationHeadersPreserved: HE1P122MB0058.EURP122.PROD.OUTLOOK.COM Subject: [OpenWrt-Devel] Factory startup issues since mount_root / libfstools improvements in Chaos Calmer X-BeenThere: openwrt-devel@lists.openwrt.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: OpenWrt Development List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: "openwrt-devel@lists.openwrt.org" Errors-To: openwrt-devel-bounces@lists.openwrt.org Sender: "openwrt-devel" Hi RafaƂ and John, I need your help in confirming a bug that I suspect can be traced back to a patch you authored / merged. This is what I am observing: Commit ba01996534d15dc725a2dcc56a59fbfb24b58787 in git://git.openwrt.org/project/fstools.git seems to have broken startup for factory-flashed jffs2 OpenWRT systems, causing substantial slowdown in factory environments. When a factory-flashed jffs2 on ubi system starts up, the "rootfs_data" volume contains a deadcode marker. When this happens, mount_root temporarily mounts a tmpfs overlay, postponing the remounting of the jffs2 overlay until the done phase of the startup. The refactoring in ba019965 eliminated an unneeded call to volume_find() when done() calls jffs2_switch(). Unfortunately the refactoring did not take into account that volume_identify() has side-effects with the mtd driver implementation and a second call to volume_identify() on the same struct volume may render a different result. This is exactly what happens when the struct volume is passed to jffs2_switch() by done(). In done(), the volume was identified as FS_DEADCODE by the first call to volume_identify(). Passing the struct volume to jffs2_switch() then results in a second call to volume_identify() on the same struct volume. The second time around the volume is identified as FS_JFFS2 within jffs2_switch(), resulting in the wrong case being run in the switch. The entire rootfs ends up yanked out from under the OpenWRT userspace, resulting in everything failing in unexpected ways. Rebooting recovers userspace, but is quite expensive in factory environments. Before the Chaos Calmer release, jffs2_switch() was not stumbling over the volume_identify() side-effect, because it was retrieving a fresh struct volume with volume_find() before calling volume_identify(). Adjusting the jffs2_switch() prototype so that done() can forward the result of volume_identify() to jffs2_switch() functionally resolves the issue, but I am not sure if this is the best approach (See attached patch below). Will you please assist? Regards, Pieter Smith Sr. Software Designer From d0dcde51ec68497882b4d0138a019c049e699177 Mon Sep 17 00:00:00 2001 From: Pieter Smith Date: Mon, 27 Mar 2017 17:18:55 +0200 Subject: [PATCH] fix startup with empty "rootfs_data" UBI volume Commit ba019965 broke startup for a factory-flashed jffs2-on-ubi systems, causing substantial slowdown in factory environments. When a factory-flashed jffs2 on ubi system starts up, the "rootfs_data" volume contains a deadcode marker. When this happens, mount_root temporarily mounts a tmpfs overlay, postponing the remounting of the jffs2 overlay until the done phase of the startup. The refactoring in ba019965 eliminated an "unneeded" call to volume_find() when done() called jffs2_switch(). Unfortunately the refactoring did not take into account that volume_identify() has side-effects with the mtd driver implementation and a second call to volume_identify() on the same struct volume may render a different result. This is exactly what happens when the struct volume is passed to jffs2_switch() by done(). In done(), the volume was identified as FS_DEADCODE by the first call to volume_identify(). Passing the struct volume to jffs2_switch() then results in a second call to volume_identify() on the same struct volume. The second time around the volume is identified as FS_JFFS2 within jffs2_switch(), resulting in the wrong case being run in the switch. The entire rootfs ends up yanked out from under the OpenWRT userspace, resulting in everything failing in unexpected ways. This patch solves the issue by adjusting jffs2_switch() to also receive the result of the first volume_identify() call. Signed-off-by: --- libfstools/libfstools.h | 2 +- libfstools/overlay.c | 4 ++-- mount_root.c | 5 +++-- 3 files changed, 6 insertions(+), 5 deletions(-) -- 2.7.4 diff --git a/libfstools/libfstools.h b/libfstools/libfstools.h index 940c504..36ba5fb 100644 --- a/libfstools/libfstools.h +++ b/libfstools/libfstools.h @@ -51,7 +51,7 @@ extern char* find_mount(char *mp); extern char* find_mount_point(char *block, int mtd_only); extern int find_filesystem(char *fs); -extern int jffs2_switch(struct volume *v); +extern int jffs2_switch(struct volume *v, int ident); extern int handle_whiteout(const char *dir); extern void foreachdir(const char *dir, int (*cb)(const char*)); diff --git a/libfstools/overlay.c b/libfstools/overlay.c index 7a62c23..3972af1 100644 --- a/libfstools/overlay.c +++ b/libfstools/overlay.c @@ -193,7 +193,7 @@ handle_whiteout(const char *dir) } int -jffs2_switch(struct volume *v) +jffs2_switch(struct volume *v, int ident) { char *mp; char buf[32]; @@ -218,7 +218,7 @@ jffs2_switch(struct volume *v) system(buf); } -switch (volume_identify(v)) { +switch (ident) { case FS_NONE: ULOG_ERR("no jffs2 marker found\n"); /* fall through */ diff --git a/mount_root.c b/mount_root.c index 1335f2b..81089a2 100644 --- a/mount_root.c +++ b/mount_root.c @@ -100,10 +100,11 @@ done(int argc, char *argv[1]) if (!v) return -1; -switch (volume_identify(v)) { +int ident = volume_identify(v); +switch (ident) { case FS_NONE: case FS_DEADCODE: -return jffs2_switch(v); +return jffs2_switch(v, ident); case FS_JFFS2: case FS_UBIFS: