If a sailboat and a motorboat are both underway, when is the sailboat the give-way vessel?

If a sailboat and a motorboat are both underway, when is the sailboat the give-way vessel?