Singer-songwriter Ed Sheeran has reached an agreement to end a copyright claim over his song 'Photograph'.