Correlation of surface states with impurities