added kernel cleanup