From: Radim Krčmář Date: Tue, 27 May 2014 17:16:20 +0000 (+0200) Subject: hv: use correct order when freeing monitor_pages X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=a100d88df1e924e5c9678fabf054d1bae7ab74fb;p=GitHub%2Fexynos8895%2Fandroid_kernel_samsung_universal8895.git hv: use correct order when freeing monitor_pages We try to free two pages when only one has been allocated. Cleanup path is unlikely, so I haven't found any trace that would fit, but I hope that free_pages_prepare() does catch it. Cc: stable@vger.kernel.org Signed-off-by: Radim Krčmář Reviewed-by: Amos Kong Acked-by: Jason Wang Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/hv/connection.c b/drivers/hv/connection.c index 7f10c151632a..e84f4526eb36 100644 --- a/drivers/hv/connection.c +++ b/drivers/hv/connection.c @@ -224,8 +224,8 @@ cleanup: vmbus_connection.int_page = NULL; } - free_pages((unsigned long)vmbus_connection.monitor_pages[0], 1); - free_pages((unsigned long)vmbus_connection.monitor_pages[1], 1); + free_pages((unsigned long)vmbus_connection.monitor_pages[0], 0); + free_pages((unsigned long)vmbus_connection.monitor_pages[1], 0); vmbus_connection.monitor_pages[0] = NULL; vmbus_connection.monitor_pages[1] = NULL;