cluster/afr: Fix locking issues in entry self-heal

Original reporter of the bug & designer of the solution:
        Pranith Kumar K <pkarampu@redhat.com>

Change-Id: I9ed89aa92e4cd0f8049f5f6c7a3701e52989ae5e
BUG: 1128721
Signed-off-by: Krutika Dhananjay <kdhananj@redhat.com>
Reviewed-on: http://review.gluster.org/8837
Tested-by: Gluster Build System <jenkins@build.gluster.com>
Reviewed-by: Pranith Kumar Karampuri <pkarampu@redhat.com>
Tested-by: Pranith Kumar Karampuri <pkarampu@redhat.com>