Add kernel#sub_{new,get,add}_config and Refactoring code