Thx Paul, i will add 1k external pullups and see how that goes.
Also (just a side note) but i am pretty sure you already tried it, did you try writing the pin configuration "manually" ? a while back when i was working on ppm sampling code, i noticed that PORT_PCR_MUX() wasn't doing what it was supposed to (or it was just some underlying error i made), but i think its worth looking into if you haven't already tried that.