update funtion remap_addr