waiting for read and write operation