added mutex protection for brick