I'm not aware that Galileo ever stopped being a devout Catholic.

What specifically is wrong with the two roles I listed?

To wit,
1) Religion has served and continues to serve as inspiration for many people to delve into science.

2) Religion could possibly generate ideas. I don't know how that might work, but I do know that creativity is not all that well understood. New ideas can come from many places - dreams for example, or in some cases from the other end of the organism. Of course, as I said, science is more than just new ideas. One must then be able to articulate one's ideas in the form of a general theory that produces testable hypotheses.

What you stated is your opinion, and that's fine, but you haven't given me a reason why there is anything inherent in the definition or practice of science that says that religion can't play a part in the two ways I have enumerated. (It could be there are others, but I can't think of them at the moment.)

Religion can have these roles because any philosophy can fill these roles. Those are not defining factors in science.