move codec to kernel.