In a telephone call, the Prime Minister underlined Britain's belief that the checks imposed by Spain in the latest diplomatic spat between the two countries over Gibraltar were "politically motivated and disproportionate" - and therefore contrary to the EU right of free movement.
He said Britain was now actively considering legal action and had begun collating evidence on the "sporadic nature of the measures" which would prove they are illegitimate.
He urged Mr Barroso to despatch a planned EU monitoring team to the border as a matter of urgency.
"The Prime Minister emphasised that the Commission has a responsibility to do this as part of its role overseeing the application of union law," a No 10 spokesman said.
"President Barroso responded that the European Commission are closely monitoring the situation and that, following a thorough legal assessment, they would not hesitate to take any measures necessary to uphold EU law."
The row erupted after the Gibraltarians constructed an artificial reef, which they said was necessary to protect local fish stocks. The Spanish said it was designed to disrupt their fishing fleet.
It also emerged last night that Spanish Twitter trolls have made death threats against the chief minister of Gibraltar and his family during the row over border controls. Fabian Picardo said he had been abused via the social network because of his criticism of the Spanish government's actions.