I'd like to briefly consider the benefits for companies which spend money and time to contribute to Open Source. I'm a contributor to Drupal extensions, so I will speak in the context of Drupal extensions, but the ideas mentioned should also be applicable for other Open Source systems and products.
So let's get started and take a look at my benefit list.
1. To advertise your company
It's allowed and good practice to give credits to the company which sponsored the extension. A few examples...
- HybridAuth Social Login module
Each branch is sponsored by different company.
- Media module
Several sponsors are possible, some of them by time, some of them by money.
- Omega Kickstart theme
If you invest significant time you also get credited.
People see the link to your company site and go there, some of them will become your clients soon.
2. To be open
More openness meens more trust. People trust companies which are open and honest.
3. To allow your developers to be proud of their work and share their "success story"
Everybody wants to fulfill themselves and Open Source is a great area for that. Support your employees' ambitions by sharing some of your company's best practices or code and get total loyalty.
4. To improve your code
You know, there is not an ideal code. So give people a chance to use your extension and you will get an army of testers who are happy to leave their feedback and help to improve your code for free of charge.
5. To be a part of progress
Nowadays it's not so easy to find a system or site which only uses proprietary technologies. And I can say that almost all breakthrough ideas are built on top of Open Source technologies. So you are able to become a part of the ideas by contributing to their basis.
6. To be thankful
In Open Source you use great and powerful software for free, and sharing your code with others is a good way to repay. It's obviously not a complete list of benefits and you can easily add more in comments. My goal is just give you food for thought.