Drake and Tory Lanez ended their beef with an old fashion phone call a week before a picture of them together was seen for the first time ever.

Sources connected to the rappers tell TMZ … Drizzy and Tory ended their years-long beef after mutual friends got in their ears about the pettiness. The feud dates back to 2015 when Tory called out Drake for referring to their hometown, Toronto, as simply “The 6.”

Toronto’s area code is 416. So, yeah … totally petty.

We’re told the phone call was placed by one of Tory’s pals to one of Drake’s — the intermediaries then put both rappers on the horn. That ultimately led to the NYC meeting where they took the peace summit Instagram shot.

Both guys, we’re told, decided it was best to squash the mess out of mutual love for “the 6” Toronto.