NEW YORK − Jeremy Lin scored 28 points and made a career-high 14 assists as the New York Knicks beat the Dallas Mavericks 104-97 on Sunday for Linsanity to reign once more in the NBA.

The Knicks ended the Mavericks’ six-game winning streak and recorded their eighth victory in nine games since Lin became the starter and an international sensation. J.R. Smith scored 15 points in his Knicks debut, and Steve Novak had all of his 14 in the final period for New York.

Playing for the seventh straight game without the injured Carmelo Anthony, the Knicks got a huge lift from Smith, just signed Friday after returning from China. Smith hit three of the Knicks’ 12 3-pointers.

Dirk Nowitzki scored a season-high 34 points for the Mavericks, who had been playing championship-level defense but became the latest team who couldn’t stop Lin.

In a game of wild momentum swings, the Knicks reeled off 17 straight points in the first quarter, fell behind by 12 in the third, then pulled it out to beat the Mavericks for only the third time in the last 20 meetings.