This should be root cause. edk2\MdePkg\Library\BaseLib\String.c line 554 to implement InternalCharToUpper() with EFIAPI. CHAR16 EFIAPI InternalCharToUpper ( IN CHAR16 Char )
edk2\ShellPkg\Library\UefiShellLevel2CommandsLib\UefiShellLevel2CommandsLib.c line 271 declares it without EFIAPI. So, they don't match each other. CHAR16 InternalCharToUpper ( IN CONST CHAR16 Char ); Thanks Liming > -----Original Message----- > From: Palmer, Thomas [mailto:thomas.pal...@hpe.com] > Sent: Thursday, December 15, 2016 6:09 AM > To: Laszlo Ersek <ler...@redhat.com>; Bruce Cran <br...@cran.org.uk>; > edk2-devel (edk2-devel@lists.01.org) <edk2-de...@ml01.01.org> > Cc: Wu, Hao A <hao.a...@intel.com>; Ni, Ruiyu <ruiyu...@intel.com>; Gao, > Liming <liming....@intel.com> > Subject: RE: [edk2] OVMF: cross-filesystem copy broken? ("The source and > destination are the same") > > Laszlo, et al~ > > I recently encountered a "cp" failure on OVMF whereby cp always thought > my source and destination file paths were equivalent. Turns out that > StrniCmp function was broken b/c the InternalCharToUpper declaration in > UefiShellLevel2CommandsLib.c was missing the EFIAPI token. Once I added > EFIAPI back, my cp command worked. > > I'm on vacation so I can't write up a formal patch right now. Give it a try > and > if it works please write up a patch, else I'll get back to it when I get back. > > > Regards, > > Thomas Palmer > > "I have only made this letter longer because I have not had the time to make > it shorter" - Blaise Pascal > > > -----Original Message----- > From: edk2-devel [mailto:edk2-devel-boun...@lists.01.org] On Behalf Of > Laszlo Ersek > Sent: Thursday, November 17, 2016 10:07 AM > To: Bruce Cran <br...@cran.org.uk>; edk2-devel (edk2-devel@lists.01.org) > <edk2-de...@ml01.01.org> > Cc: Wu, Hao A <hao.a...@intel.com>; Ni, Ruiyu <ruiyu...@intel.com>; Gao, > Liming <liming....@intel.com> > Subject: Re: [edk2] OVMF: cross-filesystem copy broken? ("The source and > destination are the same") > > On 11/17/16 16:24, Bruce Cran wrote: > > On 11/17/2016 2:35 AM, Laszlo Ersek wrote: > > > >> There's a patch on the list for said BZ: > >> [edk2] [PATCH v2] API PathRemoveLastItem not handle root paths > >> properly > >> > >> so if the BZ is indeed what you're encountering, then the patch > >> should fix it for you. Can you please test it and report back in that > >> thread? > > > > Unfortunately the patch doesn't fix the problem I'm seeing. > > > > Thanks for trying it. > > Unfortunately, I can't find the time to dig into this now. And, I think it's > likely > related to ShellPkg anyway. Can you please help by filing a BZ for ShellPkg, > and/or bisecting the issue (assuming you remember the same command > working at some point)? > > ... I observe that the least recent commit that affected "Cp.c" with any > potential to break it like this could be > > commit fbd2dfadfe6fb16ab7b49fca3764e05e65d97b8a > Author: Qiu Shumin <shumin....@intel.com> > Date: Fri Oct 23 02:03:20 2015 +0000 > > ShellPkg: Follow spec to remove the last '\' char in return name of > GetCurDir(). > > but that commit is more than a year old now... So I'm not sure. Could be one > of the underlying helper functions. Time to pull out GDB and single step the > code? :) > > Thanks! > Laszlo > _______________________________________________ > edk2-devel mailing list > edk2-devel@lists.01.org > https://lists.01.org/mailman/listinfo/edk2-devel _______________________________________________ edk2-devel mailing list edk2-devel@lists.01.org https://lists.01.org/mailman/listinfo/edk2-devel