Lantmännen har enats med Stockholms hamnar om tillstånd för att fortsätta driva spannmålsmottagning i Frihamnen – i minst tre år till.