Recently, task allocation in multi-agent systems has been investigated by many researchers. Some researchers suggested to have a central controller which has a global view about the environment to allocate tasks. Although centralized control brings convenience during task allocation processes, it also has some obvious weaknesses. Firstly, a central controller plays an important role in a multi-agent system, but task allocation procedures will break down if the central controller of a system cannot work properly. Secondly, centralized multi-agent architecture is not suitable for distributed working environments. In order to overcome some limitations caused by centralized control, some researchers proposed distributed task allocation protocols. They supposed that each agent has a limited local view about its direct linked neighbors, and can allocate tasks to its neighbors. However, only involving direct linked neighbors could limit resource origins, so that the task allocation efficiency will be greatly reduced. In this paper, we propose an efficient task allocation protocol for P2P multi-agent systems. This protocol allows not only neighboring agents but also indirect linked agents in the system to help with a task if needed. Through this way, agents can achieve more efficient and robust task allocations in loosely coupled distributed environments (e.g. P2P multi-agent systems). A set of experiments are presented in this paper to evaluate the efficiency and adaptability of the protocol. The experiment result shows that the protocol can work efficiently in different situations.