They later retained power under the Nayakas of Madurai.