Languages: BCP47 Subtags
The IETF defines language tags in its standard Tags for Identifying Languages (BCP47). Language tags consist of one or more subtags describing the languages, scripts, regions, and variants. For more information see also the Wikipedia entry on IETF language tags and the langtag.net site.
Note that the data shown in this table is not from OpenStreetMap, it just shows the building blocks that can be used to describe languages irrespective of whether they are actually used in OSM.