Reviewed-by: Eric Dong <[email protected]> Thanks, Eric
-----Original Message----- From: Carsey, Jaben Sent: Tuesday, August 12, 2014 5:09 AM To: [email protected]; Dong, Eric Cc: Carsey, Jaben Subject: RE: [edk2] ShellPkg add size cast to bit operations Revised. Thanks! I didn't even notice the spelling error; I only noticed it was spaced in wrong. > -----Original Message----- > From: Laszlo Ersek [mailto:[email protected]] > Sent: Monday, August 11, 2014 1:22 PM > To: [email protected]; Dong, Eric > Subject: Re: [edk2] ShellPkg add size cast to bit operations > > On 08/11/14 22:00, Carsey, Jaben wrote: > > > Index: Library/UefiShellDebug1CommandsLib/Pci.c > > > ========================================================== > ========= > > --- Library/UefiShellDebug1CommandsLib/Pci.c (revision 15753) > > +++ Library/UefiShellDebug1CommandsLib/Pci.c (working copy) > > @@ -1378,7 +1378,7 @@ > > Print strings that represent PCI device class, subclass and > > programmed > I/F. > > > > @param[in] ClassCodePtr Points to the memory which stores register > Class Code in PCI > > - configuation space. > > + configuation space. > > since the line is touched to fix the indentation, the typo in > "configu[r]ation" > might as well be fixed > > > @param[in] IncludePIF If the printed string should include the > programming I/F part > > **/ > > VOID > > @@ -1391,9 +1391,9 @@ > > PCI_CLASS_STRINGS ClassStrings; > > > > ClassCode = 0; > > - ClassCode |= ClassCodePtr[0]; > > - ClassCode |= (ClassCodePtr[1] << 8); > > - ClassCode |= (ClassCodePtr[2] << 16); > > + ClassCode |= (UINT23)ClassCodePtr[0]; ClassCode |= > > + (UINT23)(ClassCodePtr[1] << 8); ClassCode |= > > + (UINT23)(ClassCodePtr[2] << 16); > > > > // > > // Get name from class code > > Probable typos, UINT23 <-> UINT32. > > BTW I have no clue why the casts are necessary. (I guess MSVC was > yelling, for no good reason.) > > Laszlo > > > ---------------------------------------------------------------------- > -------- _______________________________________________ > edk2-devel mailing list > [email protected] > https://lists.sourceforge.net/lists/listinfo/edk2-devel ------------------------------------------------------------------------------ _______________________________________________ edk2-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/edk2-devel
