Added tern detach primitive, calls into dbug_detach.
Added tern detach primitive, calls into dbug_detach.

columbia/xtern,columbia/xtern,columbia/xtern,columbia/xtern,hemingcui/xtern_with_paxos,hemingcui/xtern_with_paxos,columbia/xtern,hemingcui/xtern_with_paxos,hemingcui/xtern_with_paxos,hemingcui/xtern_with_paxos,columbia/xtern