Message ID | 20201129020216.4865-5-xypron.glpk@gmx.de |
---|---|
State | Accepted, archived |
Commit | c5924118c03dc8db30d633de98afe6ad6eb7f277 |
Delegated to: | Tom Rini |
Headers | show
Return-Path: <u-boot-bounces@lists.denx.de> X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=lists.denx.de (client-ip=85.214.62.61; helo=phobos.denx.de; envelope-from=u-boot-bounces@lists.denx.de; receiver=<UNKNOWN>) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=gmx.de Authentication-Results: ozlabs.org; dkim=pass (1024-bit key; secure) header.d=gmx.net header.i=@gmx.net header.a=rsa-sha256 header.s=badeba3b8450 header.b=FY5r4aWI; dkim-atps=neutral Received: from phobos.denx.de (phobos.denx.de [85.214.62.61]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 4CkBV24YtWz9sSf for <incoming@patchwork.ozlabs.org>; Sun, 29 Nov 2020 13:03:22 +1100 (AEDT) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id AB38A82754; Sun, 29 Nov 2020 03:03:05 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=none (p=none dis=none) header.from=gmx.de Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (1024-bit key; secure) header.d=gmx.net header.i=@gmx.net header.b="FY5r4aWI"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 1323082785; Sun, 29 Nov 2020 03:02:49 +0100 (CET) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on phobos.denx.de X-Spam-Level: X-Spam-Status: No, score=-2.6 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,FREEMAIL_FROM,RCVD_IN_DNSWL_LOW,RCVD_IN_MSPIKE_H2, SPF_HELO_NONE autolearn=ham autolearn_force=no version=3.4.2 Received: from mout.gmx.net (mout.gmx.net [212.227.15.18]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) (No client certificate requested) by phobos.denx.de (Postfix) with ESMTPS id 31FB48273B for <u-boot@lists.denx.de>; Sun, 29 Nov 2020 03:02:42 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=none (p=none dis=none) header.from=gmx.de Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=xypron.glpk@gmx.de DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.net; s=badeba3b8450; t=1606615350; bh=Vp4TRE0IADRg9nH/Jn3Hi0APxhWPesZeZ7if3S8gGco=; h=X-UI-Sender-Class:From:To:Cc:Subject:Date:In-Reply-To:References; b=FY5r4aWIEcSjorR3AD7EhIG6mniQa0TRIoc94mHebLMBy5NO64h98z4gxxI+/4G2t 7WZvOB6b271QcTjH6dQHkHrCoWZOOTJiy+9QJOcFtDNOa9gbA8MGTxqzRM+bFvEGhS bTTgRNcrwES7/RTVuOyIAMyCjUg1qc5xJiX2Y7Is= X-UI-Sender-Class: 01bb95c1-4bf8-414a-932a-4f6e2808ef9c Received: from mcbin.fritz.box ([62.143.246.89]) by mail.gmx.com (mrgmx005 [212.227.17.184]) with ESMTPSA (Nemesis) id 1MAOJV-1ktPZt1vx5-00BwVq; Sun, 29 Nov 2020 03:02:30 +0100 From: Heinrich Schuchardt <xypron.glpk@gmx.de> To: Tom Rini <trini@konsulko.com> Cc: Simon Glass <sjg@chromium.org>, Christian Gmeiner <christian.gmeiner@gmail.com>, Jason Wessel <jason.wessel@windriver.com>, AKASHI Takahiro <takahiro.akashi@linaro.org>, Marek Szyprowski <m.szyprowski@samsung.com>, Bin Meng <bmeng.cn@gmail.com>, Reuben Dowle <reubendowle0@gmail.com>, Marcin Juszkiewicz <marcin@juszkiewicz.com.pl>, Thomas Hebb <tommyhebb@gmail.com>, Samer El-Haj-Mahmoud <Samer.El-Haj-Mahmoud@arm.com>, u-boot@lists.denx.de, Heinrich Schuchardt <xypron.glpk@gmx.de> Subject: [PATCH 04/18] fs: fat: correct first cluster for '..' Date: Sun, 29 Nov 2020 03:02:02 +0100 Message-Id: <20201129020216.4865-5-xypron.glpk@gmx.de> X-Mailer: git-send-email 2.29.2 In-Reply-To: <20201129020216.4865-1-xypron.glpk@gmx.de> References: <20201129020216.4865-1-xypron.glpk@gmx.de> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-Provags-ID: V03:K1:WQQ+vFL4BMfCyfCALhRkQG03EIOId+gmhOGWQ2dbERS+vf22qse d+MwmJBqjuiIOSEo6vH37cya686e5C3DvH/a0sJ0X5Z81Iuj/mNbR2cXF6sx7K8/z43cRAc 3mFSrMKesYqbRu4QAmYiw0iXGTZwRDGkEVNeXCbm8j8IWib4F05xeqC97wYOBS7KR3FEgn+ qAtPeUiPMcZ2lbzqZn+KQ== X-UI-Out-Filterresults: notjunk:1;V03:K0:abi9cBEo/8M=:nY4c++LLGhn1NrfGxz5hXF fuXsnyGNIuvEQD+ThvShpqoDujTf/B3vGLg8DxEU4wuZ9GCl34LPC/UMeIEUy/WMHhFy8nacR /8hzPr5kDlAnmvz3RXMVxX5eW6oaaNZfyGsLB0jxm61PtOemWjtt37Zr3PiADDQ/VFAcvATKF WO4Jd4yyMNYOLDhtLvimTjmcaV3WXXaHJG5XTcFcFQLajPV+AC57b1X9c0HXibip+ZCko7T5+ lg8KzpnIYq+8ZPR1utlknxW1oWCg8ugC58KIappAIl0AmJO+g6NVqeoytRnB9TBDX156WJ8E4 qaLNAZg/JlLnY1drA84OE6ugaoWdIUQJk2xG3IGQeek5Anp9m72Viv51Dtcu2P9/vABBNKaYA cepZdldlUN/CHcwoq9A8d1syrUvxkkaApaG/Xxnbq8q1bwvItivx3Rh2a2udmJ/2Y9pNAVW6Z xmo2wa7P9dEJCzSEgXmYiE9UQyBcBo5O4IDTs8H3B6iECFby0tcf+9e8MPknUUfJOlOv3NGUe Nc6R/CAqLHgoHHIuwLhJHB8KjS79WKiC2GvmQyMkLSAniZUypKM+gvNcX3An/amU+nQRm8wAS xrxeub9L44kjCIkHnyC7KkTJMvTz01QstLDWPYkhu2kdZU7nIERtDcYiUImatoc7gJewlPuFC 5HvDWlbEyTJsg4J1fWn1q953bj97gjyFVBI7fMixJwV18/mr1t+nYnmb/5s9Ki/YldpdpRbWS oKAZYfaHxHK33TYbbq7+pEKX6MtQZXDwdK0wBoMX21TrQLsDxjn0K+i9PitbldWviLW7mWgx9 Fyg9VRlLm+ewmZWx3dI0TiJzlhsi/9lf0W1pTg5VEazwxBZ9jHgWnZxEpNiY6071m+PmBTsnz 1Uq5I+SNv2xbuGwMa9ig== X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.34 Precedence: list List-Id: U-Boot discussion <u-boot.lists.denx.de> List-Unsubscribe: <https://lists.denx.de/options/u-boot>, <mailto:u-boot-request@lists.denx.de?subject=unsubscribe> List-Archive: <https://lists.denx.de/pipermail/u-boot/> List-Post: <mailto:u-boot@lists.denx.de> List-Help: <mailto:u-boot-request@lists.denx.de?subject=help> List-Subscribe: <https://lists.denx.de/listinfo/u-boot>, <mailto:u-boot-request@lists.denx.de?subject=subscribe> Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" <u-boot-bounces@lists.denx.de> X-Virus-Scanned: clamav-milter 0.102.3 at phobos.denx.de X-Virus-Status: Clean |
Series |
fs: fat: fix long name support
|
expand
|
diff --git a/fs/fat/fat_write.c b/fs/fat/fat_write.c index 7afc8388b2..4da342f9c9 100644 --- a/fs/fat/fat_write.c +++ b/fs/fat/fat_write.c @@ -1468,7 +1468,11 @@ int fat_mkdir(const char *new_dirname) memcpy(dotdent[1].name, ".. ", 8); memcpy(dotdent[1].ext, " ", 3); dotdent[1].attr = ATTR_DIR | ATTR_ARCH; - set_start_cluster(mydata, &dotdent[1], itr->start_clust); + + if (itr->is_root) + set_start_cluster(mydata, &dotdent[1], 0); + else + set_start_cluster(mydata, &dotdent[1], itr->start_clust); ret = set_contents(mydata, retdent, 0, (__u8 *)dotdent, bytesperclust, &actwrite);