Samsung has struggled in China against upstarts like Oppo, Vivo and Huawei.