Set locks for shared resources in generic driver's cifs helper

Closes-Bug: #1320768
Change-Id: Ic3a8658d2429dee7a8dec4154cc5ffb4a9e60190