Move types/topology.h to topology/

- Make the types forward-declarable, and use that in a few headers.
- Adapt files that were including the file directly.
- Move functions that operate on these structs from typedefs.[ch] to
  topology/ as well, and make callers of those functions include
  topology.h.

typedefs.h still brings this header with it.  That will be cleaned up
separately in parts.

Change-Id: Iff50b854c335d10b97fd79c65d21791e5ae432a1