
658 F.3d 854 (2011)
UNITED STATES of America, Appellee,
v.
Jason Todd GARREAU, Appellant.
No. 11-1008.
United States Court of Appeals, Eighth Circuit.
Submitted: June 16, 2011.
Filed: October 11, 2011.
*855 Edward Albright, AFPD, argued, Pierre, SD, Mark S. Falk, AFPD, on the brief, Rapid City, SD, for appellant.
Ted McBride, AUSA, argued, Pierre, SD, for appellee.
Before COLLOTON and BENTON, Circuit Judges, and KOPF,[1] District Judge.
COLLOTON, Circuit Judge.
Jason Todd Garreau entered a conditional guilty plea to possession of a stolen firearm after the district court denied a motion to suppress evidence. Garreau appeals the denial of the motion to suppress, and we affirm.

I.
On January 9, 2009, FBI Special Agent James Van Iten received a tip from a confidential informant that Garreau was traveling from Eagle Butte, South Dakota, to Pierre, South Dakota, with a stolen firearm in his vehicle. Van Iten passed the tip, along with a description of the vehicle that Garreau was driving, to Officer John Wollman of the Pierre police department. Wollman also learned from police dispatch that Garreau's driver's license was suspended and that he was subject to arrest on an outstanding state warrant. *856 Wollman relayed this information to other law enforcement officers in the area, including Trooper John Stahl of the South Dakota Highway Patrol. Shortly thereafter, Stahl saw the vehicle Garreau was driving, determined that it was traveling in excess of the posted speed limit, and signaled him to stop.
Stahl issued Garreau a warning citation for speeding and ran a computer check on Garreau's driver's license. The check confirmed that Garreau's license had been suspended. Stahl also confirmed by way of radio that Garreau was subject to arrest on an outstanding state warrant. Stahl arrested Garreau, searched his person, and placed him in the back of the patrol car.
Stahl asked Garreau whether there was anyone available to pick up the vehicle that Garreau had been driving. Garreau answered in the negative. According to Stahl, he then called for a tow truck to take the vehicle into protective custody, and performed an inventory search of the vehicle. He found the firearm in a plastic bag under a spare tire, which was in a compartment under the carpet on the floor of vehicle's trunk. Stahl inquired about the firearm's serial number over his radio, and confirmed that the gun was stolen.
A federal grand jury charged Garreau with possession of a stolen firearm, in violation of 18 U.S.C. § 922(j), and possession of a firearm by an unlawful user of a controlled substance, in violation of 18 U.S.C. § 922(g)(3). Garreau moved to suppress the firearm, on the ground that Stahl searched the vehicle in violation of the Fourth Amendment. He also sought, based on Miranda v. Arizona, 384 U.S. 436, 86 S.Ct. 1602, 16 L.Ed.2d 694 (1966), to suppress certain inculpatory statements he made at the scene of the stop, and to exclude inculpatory statements he made and a urine sample he gave at a jail following the arrest as fruits of an unlawful search. See Segura v. United States, 468 U.S. 796, 804, 104 S.Ct. 3380, 82 L.Ed.2d 599 (1984).
A magistrate judge recommended denial of Garreau's motion to suppress. The magistrate concluded that Stahl's search of the vehicle was a valid inventory search that complied with the Fourth Amendment. The magistrate also determined that Garreau's statements at the scene of the stop were obtained in violation of Miranda. But the government declared its intention to use those statements only to impeach Garreau's trial testimony, and the magistrate concluded that the statements were admissible for that limited purpose. Finally, the magistrate recommended that Garreau's statements at the jail and the urine sample should not be suppressed, because the search of the vehicle was not unlawful, and because the statements and the sample were not tainted by the Miranda violation.
The district court agreed with the magistrate's recommendation, except with respect to the search. The court concluded that the search was an unlawful search incident to arrest, not a valid inventory search, but the court did not suppress the firearm. Rather, the court ruled that the firearm was admissible under the inevitable discovery exception to the exclusionary rule because it would have been discovered during a later, lawful inventory search. Garreau thereafter entered a conditional guilty plea to possession of a stolen firearm and appealed the denial of the motion to suppress.

II.
Garreau argues that the district court erred by relying on the inevitable discovery doctrine. He contends that the government relied in the district court exclusively on its position that Stahl conducted a valid inventory search and waived all other arguments in support of the firearm's *857 admissibility. Garreau also argues that even if there was no waiver, the district court erred by considering the inevitable discovery doctrine without giving him an opportunity to present relevant evidence and argument. And Garreau asserts that even if the district court properly raised inevitable discovery, it erred in its application of the doctrine. Garreau thus urges suppression of the firearm. He also contends that his statements and the urine sample must be suppressed as fruits of an unlawful search. We review the district court's factual findings for clear error, and its legal conclusions de novo. United States v. McIntyre, 646 F.3d 1107, 1110 (8th Cir.2011).
We may affirm a district court's judgment on any basis supported by the record, see United States v. Wells, 347 F.3d 280, 287 (8th Cir.2003), and we agree with the magistrate judge that Stahl's search of the vehicle was a valid inventory search under the Fourth Amendment. The inventory search exception to the Fourth Amendment's warrant requirement permits law enforcement to inventory the contents of a vehicle that is lawfully taken into custody, even without a warrant or probable cause to search. See United States v. Taylor, 636 F.3d 461, 464 (8th Cir.2011). An inventory generally serves three purposes: "the protection of the [vehicle] owner's property while it remains in police custody; the protection of the police against claims or disputes over lost or stolen property; and the protection of the police from potential danger." South Dakota v. Opperman, 428 U.S. 364, 369, 96 S.Ct. 3092, 49 L.Ed.2d 1000 (1976).
We conclude that Stahl's search of the vehicle was a lawful inventory search. An inventory search is reasonable and constitutional if it is conducted according to standardized police procedures. United States v. Hall, 497 F.3d 846, 851 (8th Cir.2007). At the hearing, the government entered into evidence a written policy maintained by the South Dakota Highway Patrol governing inventory searches. The policy provides that a trooper may not leave an arrestee's vehicle unattended and must have the vehicle towed to a place of safekeeping. The trooper also must "inventory the contents of all vehicles" that are "impounded or taken into protective custody." The inventory "should include all areas of the vehicle, trunk, glove compartment and luggage or other closed containers within the vehicle." The policy calls for the trooper to make "[s]uch inventory" on a certain form.
Stahl's search of the vehicle that Garreau had been driving substantially complied with the policy. No one was available after Garreau's arrest to take custody of the vehicle, so Stahl was required under the policy to have the vehicle towed to a place of safekeeping. Because Stahl was required to have the vehicle towed, he also was required to conduct an inventory search of the vehicle. Stahl found the firearm while searching "all areas of the. . . trunk," as required under the policy. And he listed all non-contraband property that he found in the vehicle on the form required by the policy.
We have some doubt about the district court's conclusion that Stahl deviated from the inventory policy by failing to list the stolen firearm on the inventory form. Stahl testified that he never lists contraband on inventory logs, and "established routine" is one permissible basis to regulate an inventory search. See Florida v. Wells, 495 U.S. 1, 4, 110 S.Ct. 1632, 109 L.Ed.2d 1 (1990). The relevant stated purposes of an inventory search under the policy are to protect the property of the vehicle's owner and to protect the highway patrol from claims of lost, damaged, or stolen property. Neither purpose seems to be furthered by listing contraband on an inventory log rather than an evidence log, *858 although it is true that the policy does not by its terms distinguish between contraband and other property. In any event, inventory searches need not be conducted in a "totally mechanical, `all or nothing' fashion." Wells, 495 U.S. at 4, 110 S.Ct. 1632. Stahl's alleged minor deviation from the policy was not sufficient to render the search unlawful. See United States v. Mayfield, 161 F.3d 1143, 1145 (8th Cir. 1998) (holding that inventory search was reasonable even though "the inventory list started at the scene was not completed as it should have been," and "the seized items were listed on an evidence form later.").
The district court also concluded that "substantial evidence" indicated that Stahl found the firearm during a search incident to arrest, rather than an inventory search. But we think the court's conclusion is premised on an incorrect reading of Stahl's report. The court stated that "Stahl's report documents two separate searches"a search of the vehicle conducted immediately after the arrest and an inventory search conducted after Stahl found the firearm. The text of Stahl's report, however, does not support this conclusion. In the paragraph concerning the search of the vehicle, the trooper wrote: "A search of the vehicle was conducted." He then wrote that while searching the vehicle, he discovered the firearm, checked its status over his radio, and determined that it was stolen. The report concludes that "[t]he search and inventory of the vehicle were completed and the vehicle was towed." Pl.'s Exh. 4, at 2 (emphasis added). The use of the definite article shows that the concluding sentence refers back to the same search described in the first sentence. The report thus reflects one search, not two, and it states that the search allowed Stahl to complete an inventory before the vehicle was towed.
Garreau stresses that Stahl conducted the search with an investigative motive, but the search was not unreasonable merely because Stahl stopped Garreau as part of an investigation of a stolen firearm. "The presence of an investigative motive does not invalidate an otherwise valid inventory search." United States v. Garner, 181 F.3d 988, 991 (8th Cir.1999). Officers performing a lawful inventory search "may keep their eyes open for potentially incriminating items that they might discover in the course of an inventory search, as long as their sole purpose is not to investigate a crime." United States v. Kennedy, 427 F.3d 1136, 1144 (8th Cir. 2005). Here, Garreau was lawfully arrested pursuant to a warrant, and the unavailability of another driver required an inventory of the vehicle.
We therefore affirm the district court's denial of Garreau's motion to suppress the firearm. Because Garreau sought to suppress his statements and the urine sample solely on the ground that they were fruits of an unlawful search, we affirm the denial of his motion with respect to that evidence as well.

* * *
The judgment of the district court is affirmed.
NOTES
[1]  The Honorable Richard G. Kopf, United States District Judge for the District of Nebraska, sitting by designation.
