Received: by 2002:a05:6a10:206:0:0:0:0 with SMTP id 6csp1694759pxj; Sun, 9 May 2021 02:14:08 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzvaH0Ad3qIrP48hPNf8aIBM/b7zmc88IFCrcV0ReaRd2yFHbP5KxSgtdWm/qzCwNK5YZx1 X-Received: by 2002:a05:6e02:dd0:: with SMTP id l16mr14176340ilj.26.1620551648294; Sun, 09 May 2021 02:14:08 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1620551648; cv=none; d=google.com; s=arc-20160816; b=02BxkLauGRgNRSvqFmDJSFemUkxjuXGN5KiLQBEnom0AxMZFLSbRYKJSRvXA0UmthI WebxiXE37EDwa8qCIUb4LYVsGvZlsEEqdjFWfxSgvbe8Yy249CHIOurEhigoSAfzVJCF GzCTn7tIoDb/qx9b0EPmX6j3hw/g9BkbdjmYuVLQ8hDw/6nps+JotvB45prn7Nnn5HcF id6VH/9/12krtJMEHlM4CkI5Ggk3u2VOXx6Ubgyatn1FZQQuB2adwGkthbOBqRXJCzzE DX9JWisGn45DSz8mocmLiAWnzYhkMHPVNxUP3AywRQq0TEZ4RC2W55iHUtKxClywxxer Fafg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=z+P3cMDBfi8hzbAn2lWuz8BNrd8UIu6c08JOoMtOFPA=; b=pTxCEUCZRrfks7hEikUeu6vDadbdy6fBOAwn2ig2PAow8kCoy/rFz250S0urJGtnxp Anw2VXuilSRKn1DDk5FLG1nv9vp/evdHEQOHHjrmLUiDOFya9XX1myk4e8S/CKJqdX7X iEcWErZQv6CLE5FwNcpcpeUJETc+n6kg8RBHcb7JDS+rYsGB61QL5ESDT/0f9MJ4BBEG UYi3H/d+7Ru7Htjue5TnQ0slfIuECxjvvwH+NtxiZmbI+qUSLVKQgn22GfSNRdNgHHaW XFphqeImDcOs5a9JmopnKUZNtmxJQL3hpZUiHzz2mJN0m93ibLCTDzCo5mWskpPV1l9C 6Baw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=M2+C0pA1; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id n6si13178012jal.41.2021.05.09.02.13.55; Sun, 09 May 2021 02:14:08 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=M2+C0pA1; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229675AbhEIJMQ (ORCPT + 99 others); Sun, 9 May 2021 05:12:16 -0400 Received: from mail.kernel.org ([198.145.29.99]:37498 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229596AbhEIJMP (ORCPT ); Sun, 9 May 2021 05:12:15 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id 951C06140B; Sun, 9 May 2021 09:11:10 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1620551472; bh=4WEVhLSVp2dKbLOmxraeBWdH+1tEbp0pxIaZ2+hE7gI=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=M2+C0pA1EXBspa8UlnFMm9PT3dx5nP5aJ1ThNRXY+FHNVRZDb1dHErShAy6lqFh57 BrUESGLEHge/J4sLCcAIgtbbYOJrayu69L0q6PuzPRHANZnaaN8EaO4H6sz+2FwIZ+ xxntpPWUJ6KTtHtmCdoSNUKFVwBSLhCDD4xTS7CZGTglZZPs+kpb7/zxwgbvH5Zg2w JduA7kWTxKrUYoisigCYiX6XMnCyDvvV8V54yVD4hRZ4ww30i/CE9sMJ5uh3olpUZd dpWR6z9r3p2GYQby3vxNmEvZie7roeCXG5s4/aVb2sQg6MaC9JVOcxq/ZptHEP5F69 1yo2uPWLkW/zQ== From: Mike Rapoport To: Stafford Horne Cc: Jonas Bonn , Stefan Kristiansson , Mike Rapoport , Mike Rapoport , openrisc@lists.librecores.org, linux-kernel@vger.kernel.org, kernel test robot Subject: [PATCH 1/2] openrisc: mm/init.c: remove unused memblock_region variable in map_ram() Date: Sun, 9 May 2021 12:11:02 +0300 Message-Id: <20210509091103.7985-2-rppt@kernel.org> X-Mailer: git-send-email 2.28.0 In-Reply-To: <20210509091103.7985-1-rppt@kernel.org> References: <20210509091103.7985-1-rppt@kernel.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Mike Rapoport Kernel test robot reports: cppcheck possible warnings: (new ones prefixed by >>, may not real problems) >> arch/openrisc/mm/init.c:125:10: warning: Uninitialized variable: region [uninitvar] region->base, region->base + region->size); ^ Replace usage of memblock_region fields with 'start' and 'end' variables that are initialized in for_each_mem_range() and remove the declaration of region. Fixes: b10d6bca8720 ("arch, drivers: replace for_each_membock() with for_each_mem_range()") Reported-by: kernel test robot Signed-off-by: Mike Rapoport --- arch/openrisc/mm/init.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/arch/openrisc/mm/init.c b/arch/openrisc/mm/init.c index bf9b2310fc93..f3fa02b8838a 100644 --- a/arch/openrisc/mm/init.c +++ b/arch/openrisc/mm/init.c @@ -75,7 +75,6 @@ static void __init map_ram(void) /* These mark extents of read-only kernel pages... * ...from vmlinux.lds.S */ - struct memblock_region *region; v = PAGE_OFFSET; @@ -121,7 +120,7 @@ static void __init map_ram(void) } printk(KERN_INFO "%s: Memory: 0x%x-0x%x\n", __func__, - region->base, region->base + region->size); + start, end); } } -- 2.28.0