Sort a linked list using insertion sort.