Generalized Misner-Sharp Energy in f(R) Gravity