p11 Update

code restructure