Refine some internal functions of PCD Driver.