From a13db3692f9c898b19f6c79031b753d964f1f354 Mon Sep 17 00:00:00 2001 From: Kun Gui Date: Mon, 8 Jun 2009 07:59:04 +0000 Subject: 1. FAT doesn't support to store time information in its FileLastAccess field. The FileLastAccess only contains date information; 2. Replaced RFC 3066 with RFC 4646. (based on FatPkg commit 716b62054bf10b74949795a3df0d29eaca5a7486) [jordan.l.justen@intel.com: Use script to relicense to 2-clause BSD] Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Jordan Justen Acked-by: Mark Doran Acked-by: Laszlo Ersek --- FatPkg/EnhancedFatDxe/ComponentName.c | 8 ++++---- FatPkg/EnhancedFatDxe/DirectoryManage.c | 3 ++- 2 files changed, 6 insertions(+), 5 deletions(-) (limited to 'FatPkg') diff --git a/FatPkg/EnhancedFatDxe/ComponentName.c b/FatPkg/EnhancedFatDxe/ComponentName.c index ef06c8db11..e4a40be495 100644 --- a/FatPkg/EnhancedFatDxe/ComponentName.c +++ b/FatPkg/EnhancedFatDxe/ComponentName.c @@ -43,7 +43,7 @@ Abstract: languages specified in SupportedLanguages. The number of languages supported by a driver is up to the driver writer. Language is specified - in RFC 3066 or ISO 639-2 language code format. + in RFC 4646 or ISO 639-2 language code format. @param DriverName[out] A pointer to the Unicode string to return. This Unicode string is the name of the @@ -108,7 +108,7 @@ FatComponentNameGetDriverName ( languages specified in SupportedLanguages. The number of languages supported by a driver is up to the driver writer. Language is specified in - RFC 3066 or ISO 639-2 language code format. + RFC 4646 or ISO 639-2 language code format. @param ControllerName[out] A pointer to the Unicode string to return. This Unicode string is the name of the @@ -210,7 +210,7 @@ GLOBAL_REMOVE_IF_UNREFERENCED EFI_UNICODE_STRING_TABLE mFatControllerNameTable[] languages specified in SupportedLanguages. The number of languages supported by a driver is up to the driver writer. Language is specified - in RFC 3066 or ISO 639-2 language code format. + in RFC 4646 or ISO 639-2 language code format. @param DriverName[out] A pointer to the Unicode string to return. This Unicode string is the name of the @@ -283,7 +283,7 @@ FatComponentNameGetDriverName ( languages specified in SupportedLanguages. The number of languages supported by a driver is up to the driver writer. Language is specified in - RFC 3066 or ISO 639-2 language code format. + RFC 4646 or ISO 639-2 language code format. @param ControllerName[out] A pointer to the Unicode string to return. This Unicode string is the name of the diff --git a/FatPkg/EnhancedFatDxe/DirectoryManage.c b/FatPkg/EnhancedFatDxe/DirectoryManage.c index 9fdb7affe4..8d6d15467e 100644 --- a/FatPkg/EnhancedFatDxe/DirectoryManage.c +++ b/FatPkg/EnhancedFatDxe/DirectoryManage.c @@ -989,7 +989,8 @@ Returns: // We will append this entry to the end of directory // FatGetCurrentFatTime (&DirEnt->Entry.FileCreateTime); - FatGetCurrentFatTime (&DirEnt->Entry.FileModificationTime); + CopyMem (&DirEnt->Entry.FileModificationTime, &DirEnt->Entry.FileCreateTime, sizeof (FAT_DATE_TIME)); + CopyMem (&DirEnt->Entry.FileLastAccess, &DirEnt->Entry.FileCreateTime.Date, sizeof (FAT_DATE)); NewEndPos = ODir->CurrentEndPos + DirEnt->EntryCount; if (NewEndPos * sizeof (FAT_DIRECTORY_ENTRY) > OFile->FileSize) { if (NewEndPos >= (OFile->IsFixedRootDir ? OFile->Volume->RootEntries : FAT_MAX_DIRENTRY_COUNT)) { -- cgit v1.2.3