Iran and Iraq reach deal to release trapped energy payments