The basic Rolling ability was first introduced in Ocarina of Time. In most games, it can be performed by moving forward and pressing the action button, though Phantom Hourglass and Spirit Tracks require different techniques to Roll.
It is rarely used as an attack, but is instead an action that Link can use to "tackle" some objects, an action that was formerly done with the Pegasus Boots in A Link to the Past and Link's Awakening. In most of its appearances, it can also be used repeatedly to travel faster than walking. Although it does not seem to be intended as an attack, this technique has been known to cause some damage to the occasional enemy.
Ocarina of Time
The Wind Waker
Four Swords Adventures
The Minish Cap
Link can Roll in The Minish Cap by pressing the R Button, allowing him to move more quickly (though the Pegasus Boots are faster). In addition, a Sword Technique called the Roll Attack can be learned from Grayblade.
Link can roll by drawing a small circle at the edge of the Nintendo DS screen in Phantom Hourglass. If Link Rolls four times in a row in Phantom Hourglass, he will halt momentarily and become dizzy. Coincidentally, this also happens when he attempts to perform a Spin Attack four times consecutively.
Link can roll by tapping the edge of the Nintendo DS screen while running in Spirit Tracks.