Quantization of integrable systems and a 2d/4d duality