Total internal reflection ellipsometry of periodic structures with ferromagnetic coating