To create an Norwegian primary patronym, the suffix -sen/-son/-søn (= 'son') or -datter/dotter (= 'daughter') is added to the father's name.
Sometimes the genitive form of the father's name is used before adding the suffix. You will find the genitive forms of Norwegian names in the grammar tables on the respective name pages. In Norwegian, usually just the suffix -s is added directly to the name.
During the time when hereditary surnames were introduced, Norway was a part of Denmark. So the Danish influence was strong, and the Danes brought also many German surnames to Norway. See also Danish Surnames.
When hereditary surnames became mandatory in 1923, many Norwegians who had not taken another surname before, decided to "freeze" their primary patronyms so they became secondary, hereditary patronyms instead and could function as a surname.
Very typical for Norway are farm names. They had functioned as a kind of address before but were now "frozen", which means that they became hereditary surnames and would not be changed if the person moved to another farm or into a town.