gma500: tidy up the opregion and lid code