Spanish king asks socialists to form new government