tuncer: add a fun to close the port