The subject of what makes good music is as problematic as the same question posed of any art form. Inherently subjective, there are nonetheless a few qualities which we might point to as indications of why one musician or band is better than another.
Emotion: good music, in my opinion, evokes emotion. It does so by its nature. It makes you feel exhilarated, crestfallen, pensive, joyous. The addition of clever and profound lyrics serves to add poetry to an already potent mix. The right song can motivate you to dance even when your blisters have blisters; it can drag that last ounce of energy out of you and make you spend it all in one last whirl. There is nothing like the perfect song coming on the radio at the right time, making that road trip sing along ecstatic. The end of the night slow dance is beautiful and honest. Well, honest in its own way.
The connection to memory is also important. Songs evoke nostalgia, they bring us back to times and places we'd forgotten. They make us feel young, or old. This in and of itself may not be a key to whether the music is good, but being tied to a memory of a person or a time can make a song powerful, and that power can certainly be good.
Now, I don't like to think of myself as a music snob, and certainly I am not well-educated enough to put on airs of any sort. However, I think it is reasonable to assert that when a song is written for the primary purpose of making money, it loses something. The artist who wrote it, if indeed it was an artist and not a businessman in one sense, ceases to be focused on the creation of art for its own sake, and more on the marketability of the end product. Does this automatically produce bad music? No. But it tends more toward a product than a work of art.
Now, some might argue that the popularity of mass-marketed music proves it is just as good as music made for its own sake. I would argue against this using the following points. Firstly, popularity does not necessarily indicate good art. I know this seems contradictory, since it is possible to define 'good' art as that which is enjoyed by the greatest number of people; the only thing I can say is that I believe good art stands the test of time. If the popular music of today is remembered well in fifty years, and I'm talking beyond album sales and chart numbers here, then perhaps it can be judged an artistic success in one sense.
The second point is that the charts, and popular music, is self-created. People with money pay for their artists and the music they have invested in to be promoted. The songs get played on the radio, and so they are in the charts. To a large extent, money makes popular music, rather than the music itself.
That said, if it were completely terrible, would the music last? Perhaps not. My final point in this regard is that much popular music relies on an understanding of a human enjoyment of basic rhythms and formulae. Check out the Axis of Awesome's Four Chords video to see what I mean (http://www.youtube.com/watch?v=5pidokakU4I). This may be 'catchy' music, but it is hardly original.
So, does originality matter? After all, Shakespeare took older stories and reworked them in majestic ways, and he is, in my opinion, the greatest artist of all time. Perhaps the genius is in making your own stamp, in how you add beauty and pieces of yourself to the work. Call it subjectivity, but I am just not sure that Maroon 5 fall into the category of musical geniuses. (That being said, I can listen to some of their music, so maybe I am a big hypocrite.)
The last thing which springs to mind is skill. Compare the skill of Jimi Hendrix with that of Will.I.am. How does the mastery of the guitar on songs like Purple Haze and All Along the Watchtower (I know it's a cover - still brilliant) compare with the inane rhymes of My Humps or Let's Get it Started? I leave you to your own conclusions.
Because of subjectivity, we can never really say that one song is better than another, even if it is more skilful, more passionate, more original, more about the music than the selling or the image. But we can say that money often distorts art into something else, something worse. And we can still, in our own minds, love good music and hate Justin Bieber.