It depends on how big your puppy is, and how large the piece of earplug was that he ate - the biggest concern is that this could cause an obstruction in the intestines as it passes through. In a very small puppy like a Maltese or Toy Poodle, this would be a serious concern; in a larger puppy like a Labrador or Golden Retriever, it's less likely that this would happen.
You will need to monitor your puppy for the next few days for any signs of an obstruction, which would include repeated episodes of vomiting, not wanting to eat, acting lethargic, or not having bowel movements. If you see any of these symptoms, take your pup to the vet for an exam right away, as he may need emergency surgery to remove the earplug. As long as he is acting normal (eating, drinking, playing, no vomiting), there should be no need to worry.