mm: optimize Kernel Samepage Merging(KSM)

idea is taken here -
https://github.com/poondog/joey-m7-GPE/commit/8710b0b7841ae8a765da53969df5e3fa115664d0