Here, from Wikitravel, is some sage advice on a ritual that even I did not realize was so complicated until I read this passage:
"When invited to a meal in a private home it is considered polite for a guest to ask if they can bring anything for the meal, such a dessert, a side dish, or for an outdoor barbecue, something useful like ice or plastic cups or plates. The host will usually refuse except among very close friends, but it is nonetheless considered good manners to bring along a small gift for the host. A bottle of wine, box of candies or fresh cut flowers are most common. Gifts of cash, prepared ready-to-serve foods, or very personal items (e.g. toiletries) are not appropriate."