corrected errors in tbb and kernel