Asian markets mostly gain as trade woes give way to earnings hopes