Homecoming is the first film of a joint partnership between Sony and Marvel Studios, and Downey Jr.'s casting shows that Marvel is keenly interested in keeping their universes intricately linked going forward. Having one of their key actors involved in the new film should also negate some fears that this was a one and done type of agreement between the two studios. Since he wasn't under contract for this, Marvel had to negotiate a hefty deal to ultimately make it happen.
In Captain America: Civil War, Tony seems to form a more mentor-like role for Spidey, and that dynamic will be picked up again in Spider-Man's solo outings. The film has already cast its Aunt May with actress Marisa Tomei and includes Zendaya and Tony Revolori in unnamed roles.