Who made such an agreement?
Law enforcement is the perogative of the House. Immigration is the perogative of the Senate.
You will recall that in 2003 and 2004 all the Senate immigration bills were immigration related and had no enforcement. It was understood that the House, somewhere down the road, would deal with enforcement.
In 2005, as the debate heated up, the Borderbots wanted enforcement included in the bill. The first attempt(july 05) was Kyl Cornyn with Kyl using his committee chair as authority to write enforcement. That didn't please the House.
So, the House and Senate reached the agreement to each write their respective parts and merge the two. But it didn't work.