I have a Moto G 1st gen, never rooted or customized and the ear speaker went dead a few months after the lollipop upgrade (5.0.2). The volume bar did change but the ear speaker was silent. Strangely enough the loudspeaker was working perfectly as well as headsets.
I tried everything (factory reset, change to the old audio runtime) but no luck with the default firmware. I bough a new phone since the warranty had expired and I tried rooting/installing cyanogen 11 (based on kit kat) on moto g. I can confirm that the ear speaker works perfectly so obviously it is a software issue. I recommend downgrading to 4.4 before buying a new phone :'(. I am really disappointed with motorola, it seems the management decided to drop supporting their best selling product.