[PATCH 01/17] ap: Fix iteration over ap->rates