I have read the source code. The lockForUpdate method is part of the Illuminate\Database\Query\Builder class, and will return an instance of that class.
Therefore, you can use that method with a relationship and a model class, and the followings are gonna work:
Something::where(...)
->lockForUpdate()
->get();
$user->something()
->lockForUpdate()
->get();
$user->something()
->where(...)
->lockForUpdate()
->get();
firstOrCreate or any other updating methods cannot be used, because those records are locked. Plus, firstOrCreate method does not belong to the Illuminate\Database\Query\Builder class.