Closed subsets of root systems and regular subalgebras