DESC UML - SKAS: avoid leak of kernel memory by SKAS patch. EDESC Part 1: fix the kernel leak. init_new_context was called, and then __init_new_context; they both clear the LDT (by setting its size to 0) and alloc a new one; and since the LDT size has been cleared, alloc_ldt does not free() the LDT. It it exposed only if actually the UML process has an LDT to allocate, i.e. if the UML kernel thread had an LDT on the host when forking the init process. Part 2: avoid allocating a useless LDT for the init inside UML. Until now, when opening /proc/mm the SKAS patch copied the current LDT like on fork(). Since currently UML does not expect the userspace thread to inherit its own LDT, we can avoid this and save 4k for each child (useful when hosting lots of UML). And besides, that was waste memory. Actually UML never sets its one LDT, since it does not use TLS; it can just inherits it from his fathers, but it's useless.