The Las Vegas Raiders have agreed on a contract with free agent quarterback Marcus Mariota to provide an experienced backup behind starter Derek Carr.

A person familiar with the deal said Monday the Raiders reached the deal with the former No. 2 overall pick in the 2015 draft. The person spoke on condition of anonymity because the deal can’t be signed until the start of the league year on Wednesday.

The Raiders were one of the teams rumored to be in the running for Tom Brady if he decides to leave New England as a free agent. They ended up with Mariota, for now, to give coach Jon Gruden a proven backup who could also challenge Carr for the starting role.