Barnhart's homer leads Reds to 3-2 victory