Just some L2 related additions, cleanups and refactorings. It still isn't working yet though.