Charging series connected batteries independently
I think the second case is fine. Each charge controller will see only its own battery, and charge it normally.
A few important caveats: the two controllers, solar panels etc must be completely isolated from each other, they must receive similar amounts of sun, and they must from time to time manage to fully charge the batteries, so they get equally full.

The two are not exactly equivalent.

Your second circuit has an error - the middle wire actually carries both 2 A in for the first controller, and 2 A out for the second, so the net current on that wire is zero. But not all the time, and depending on the chargers, and so on. It had better be a thick wire, you don't want the voltage drop from one charger's current affecting the voltage reading of the other charger...

Why not just connect your two solar cells in series, and use a 24 V charge controller?