Trapping in high-k dielectrics