merge from kbc_sam_jb_v1 (manually)