The earliest lineages described the lineage from Bodhidharma into the 5th to 7th generation of patriarchs.
Eventually these descriptions of the lineage evolved into a continuous lineage from Śākyamuni Buddha to Bodhidharma.