cns3xxx: fix gpio access and add gpio IRQ support