They can operate these as 'split duties', rules of which vary by each operator.
We need a minimum of 3 hours, maximum of 10 hours, and you can extend the max FDP by half of your total rest time.
Some suitable accommodation must be provided for a rest of 6 hours or more.
This means that, for instance, the following could be possible:
London - Berlin, arrive at hotel 10pm, Berlin - London, hotel pickup 4am.
Your max FDP is 2 sectors reporting at your original check in time, extended by half the rest period i.e. 3 hours more.