Patrol officers who want to check a motorist's vehicle for drugs at the time of a traffic stop will now have a more difficult time doing so.

The U.S. Supreme Court ruled on Tuesday that law enforcement officers cannot hold a person at the scene of a traffic stop to wait for a K-9 unit to arrive with a drug-sniffing dog. In a 6-3 decision, the Court ruled that prolonging a traffic stop without reasonable suspicion is a violation of a person's Fourth Amendment rights against unreasonable seizure.

The ruling stems from a 2012 traffic stop in which a Nebraska man, Dennys Rodriguez, was stopped by an officer after he veered onto the shoulder of a roadway. The officer wrote Rodriguez a warning, according to Slate, but also asked if he could walk his K-9 around Rodriguez's SUV.

Rodriguez refused, but the officer called for backup and, eight minutes later, conducted the search anyway. The dog, on his second pass of the vehicle, alerted to drugs and the officers found a bag of methamphetamine.

The majority of the court stated that the extra eight minutes that Rodriguez was held after the officer wrote him a warning on the traffic violation was a violation of Rodriguez's constitutional rights.

"We hold that a police stop exceeding the time needed to handle the matter for which the stop was made violates the Constitution's shield against unreasonable seizures," Justice Ruth Bader Ginsburg wrote on behalf of the court.

Justices Clarence Thomas, Samuel Alito and Anthony Kennedy disagreed with the ruling. They argued that officers can reasonably detain a person to investigate for other possible violations of the law.

See the Supreme Court's entire ruling below.