Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753836AbbLDTam (ORCPT ); Fri, 4 Dec 2015 14:30:42 -0500 Received: from mail-lb0-f176.google.com ([209.85.217.176]:33533 "EHLO mail-lb0-f176.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751861AbbLDTal (ORCPT ); Fri, 4 Dec 2015 14:30:41 -0500 From: Alexander Kuleshov To: Andrew Morton Cc: Tony Luck , Tang Chen , Pekka Enberg , Wei Yang , linux-mm@kvack.org, linux-kernel@vger.kernel.org, Alexander Kuleshov Subject: [PATCH] mm/memblock: remove rgnbase and rgnsize variables Date: Sat, 5 Dec 2015 01:28:06 +0600 Message-Id: <1449257286-28089-1-git-send-email-kuleshovmail@gmail.com> X-Mailer: git-send-email 2.6.2.485.g1bc8fea Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1212 Lines: 39 This patch removes rgnbase and rgnsize variables from the memblock_overlaps_region() function. We use these variables only for passing to the memblock_addrs_overlap() function and that's all. Let's remove them. Signed-off-by: Alexander Kuleshov --- mm/memblock.c | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/mm/memblock.c b/mm/memblock.c index d300f13..9a45e21 100644 --- a/mm/memblock.c +++ b/mm/memblock.c @@ -96,13 +96,10 @@ bool __init_memblock memblock_overlaps_region(struct memblock_type *type, { unsigned long i; - for (i = 0; i < type->cnt; i++) { - phys_addr_t rgnbase = type->regions[i].base; - phys_addr_t rgnsize = type->regions[i].size; - if (memblock_addrs_overlap(base, size, rgnbase, rgnsize)) + for (i = 0; i < type->cnt; i++) + if (memblock_addrs_overlap(base, size, type->regions[i].base, + type->regions[i].size)) break; - } - return i < type->cnt; } -- 2.5.0 -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/