public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
* [U-Boot] [PATCH] fat: reset VFAT short alias checksum on first match
@ 2012-01-02 16:54 Sergei Shtylyov
  2012-01-05 15:03 ` Wolfgang Denk
  0 siblings, 1 reply; 2+ messages in thread
From: Sergei Shtylyov @ 2012-01-02 16:54 UTC (permalink / raw)
  To: u-boot

The VFAT short alias checksum read from a long file name is only overwritten
when another long file name appears in a directory list. Until then it renders
short file names invisible that have the same checksum. Reset the checksum on
first match.

Signed-off-by: Sergei Shtylyov <sshtylyov@ru.mvista.com>
Signed-off-by: Martin Mueller <martin.mueller5@de.bosch.com>

---
 fs/fat/fat.c |    2 ++
 1 file changed, 2 insertions(+)

Index: u-boot/fs/fat/fat.c
===================================================================
--- u-boot.orig/fs/fat/fat.c
+++ u-boot/fs/fat/fat.c
@@ -633,6 +633,7 @@ static dir_entry *get_dentfromdir (fsdat
 			}
 #ifdef CONFIG_SUPPORT_VFAT
 			if (dols && mkcksum(dentptr->name) == prevcksum) {
+				prevcksum = 0xffff;
 				dentptr++;
 				continue;
 			}
@@ -963,6 +964,7 @@ do_fat_read (const char *filename, void 
 #ifdef CONFIG_SUPPORT_VFAT
 			else if (dols == LS_ROOT &&
 				 mkcksum(dentptr->name) == prevcksum) {
+				prevcksum = 0xffff;
 				dentptr++;
 				continue;
 			}

^ permalink raw reply	[flat|nested] 2+ messages in thread

* [U-Boot] [PATCH] fat: reset VFAT short alias checksum on first match
  2012-01-02 16:54 [U-Boot] [PATCH] fat: reset VFAT short alias checksum on first match Sergei Shtylyov
@ 2012-01-05 15:03 ` Wolfgang Denk
  0 siblings, 0 replies; 2+ messages in thread
From: Wolfgang Denk @ 2012-01-05 15:03 UTC (permalink / raw)
  To: u-boot

Dear Sergei Shtylyov,

In message <201201021954.29410.sshtylyov@ru.mvista.com> you wrote:
> The VFAT short alias checksum read from a long file name is only overwritten
> when another long file name appears in a directory list. Until then it renders
> short file names invisible that have the same checksum. Reset the checksum on
> first match.
> 
> Signed-off-by: Sergei Shtylyov <sshtylyov@ru.mvista.com>
> Signed-off-by: Martin Mueller <martin.mueller5@de.bosch.com>
> 
> ---
>  fs/fat/fat.c |    2 ++
>  1 file changed, 2 insertions(+)

Applied, thanks.

Best regards,

Wolfgang Denk

-- 
DENX Software Engineering GmbH,     MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
Landing: a controlled mid-air collision with a planet.

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2012-01-05 15:03 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-01-02 16:54 [U-Boot] [PATCH] fat: reset VFAT short alias checksum on first match Sergei Shtylyov
2012-01-05 15:03 ` Wolfgang Denk

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox