change code structure

Signed-off-by: yuanhuan <yuanhuan@tcl.com>