I have a maximization problem for f(x,y) s.t. p_{1}x+p_{2}y=g

I cannot remember how to set up the Lagrange for this.

Is it:

1.) f(x,y) +n(p_{1}x+p_{2}-g)

or

2.) f(x,y)+n(p_{1}x+p_{2}-g)+mx+my

If it is the latter, can someone explain to my why it is the latter? (I'm thinking product rule but I'm quite confused.)