MdeModulePkg/Core: fix bits operation error on a boundary condition