MARTINSVILLE, Va. -- Denny Hamlin won the pole position Friday for the NASCAR race at Martinsville Speedway.

Hamlin led the way as 18 drivers broke Jimmie Johnson's track qualifying record with a speed of 99.595 mph. Johnson, the points leader who set the mark in April, and Kyle Busch tied for second at 99.344 mph, with Johnson getting the second spot Sunday based on the owner points tiebreaker.

Matt Kenseth, a teammate of Hamlin and Busch who trails Johnson by just four points in the championship battle with four races left, will start fourth, meaning the five-time series champion and Hendrick Motorsports star will be surrounded by teammates from Joe Gibbs Racing at the green flag on Sunday.

The pole is the 17th of Hamlin's career and his career-best fifth this season.