fix supporting p500