Higher-Order Side Channel Security and Mask Refreshing: linear function?
Actually, it's any $\mathbb{F}_2$-linear function you want it to be.

That is, those two algorithms are generic ways, given a linear $g$ and a threshld (secret-shared) value $x$, to compute a threshold version of $x \times g(x)$ (where $\times$ is $GF(2^n)$ field multiplication).