From patchwork Mon Oct 22 07:18:59 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Peter Crosthwaite X-Patchwork-Id: 193087 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.gnu.org (lists.gnu.org [208.118.235.17]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (Client did not present a certificate) by ozlabs.org (Postfix) with ESMTPS id 544B32C007A for ; Mon, 22 Oct 2012 18:19:31 +1100 (EST) Received: from localhost ([::1]:37747 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TQCIL-0002sr-By for incoming@patchwork.ozlabs.org; Mon, 22 Oct 2012 03:19:29 -0400 Received: from eggs.gnu.org ([208.118.235.92]:45863) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TQCI8-0002lw-FX for qemu-devel@nongnu.org; Mon, 22 Oct 2012 03:19:17 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TQCI7-0008T5-Ar for qemu-devel@nongnu.org; Mon, 22 Oct 2012 03:19:16 -0400 Received: from mail-da0-f45.google.com ([209.85.210.45]:36391) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TQCI7-0008T1-4w for qemu-devel@nongnu.org; Mon, 22 Oct 2012 03:19:15 -0400 Received: by mail-da0-f45.google.com with SMTP id n15so1183435dad.4 for ; Mon, 22 Oct 2012 00:19:14 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=sender:from:to:cc:subject:date:message-id:x-mailer:in-reply-to :references:in-reply-to:references:x-gm-message-state; bh=LIM5jxNO2tJ2ysf/395YkKmOdi7/rOt/+GJqx8q+xyU=; b=TWsHe6r1N5e5fa4iWhTVQD/x4pWsH3e4qW0sARwnJdvMvjKsus4d5H2XgPjzNvYcbZ B7/jtrxqHWCDLRnbpy8xdHdtOOcdZUGkcwp+Cy5w7bDa0bJ2c+B0MAVtlUj8VzOsh34n ml1H91vFAH166M6kwuucfOWRyAd6Dyy24ICdLrSmI/2bQsZuwCYZ31GEWxqrYc18VucN T15KXnJExUg8Lsr4kHejxR23oszqKVMJEF0gd9teh+MSB0pSpPBXAlHkzAvStY0dCT26 iOXHGEXyShxO7Aua6a8/pddd0al8gHDs7uQa9MarydVd1QOxOjFxfyinAC+GbIuDbLPk DeyQ== Received: by 10.68.213.33 with SMTP id np1mr27447666pbc.64.1350890354226; Mon, 22 Oct 2012 00:19:14 -0700 (PDT) Received: from localhost ([124.148.20.9]) by mx.google.com with ESMTPS id ho7sm5517404pbc.3.2012.10.22.00.19.11 (version=TLSv1/SSLv3 cipher=OTHER); Mon, 22 Oct 2012 00:19:13 -0700 (PDT) From: Peter Crosthwaite To: qemu-devel@nongnu.org Date: Mon, 22 Oct 2012 17:18:59 +1000 Message-Id: <14370857b5b24d5c838da770b0eacad46f36f73b.1350889929.git.peter.crosthwaite@xilinx.com> X-Mailer: git-send-email 1.7.0.4 In-Reply-To: References: In-Reply-To: References: X-Gm-Message-State: ALoCoQkOhLelxEoFEUtRquiiNEXsqBDAl9CeoaYdVTHiGRzYflb/xaqJss7sVcysqi2zMamtlSjG X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 209.85.210.45 Cc: vineshp@xilinx.com, peter.maydell@linaro.org, Peter Crosthwaite , john.williams@xilinx.com, pbonzini@redhat.com, edgar.iglesias@gmail.com Subject: [Qemu-devel] [PATCH v2 1/6] pflash_cfi0x: remove unused base field X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Sender: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org This field is completely unused. The base address should also be abstracted away from the device anyway. Removed. Signed-off-by: Peter Crosthwaite Reviewed-by: Peter Maydell --- hw/pflash_cfi01.c | 2 -- hw/pflash_cfi02.c | 4 +--- 2 files changed, 1 insertions(+), 5 deletions(-) diff --git a/hw/pflash_cfi01.c b/hw/pflash_cfi01.c index 3b437da..4f3f5f0 100644 --- a/hw/pflash_cfi01.c +++ b/hw/pflash_cfi01.c @@ -61,7 +61,6 @@ do { \ struct pflash_t { BlockDriverState *bs; - target_phys_addr_t base; target_phys_addr_t sector_len; target_phys_addr_t total_len; int width; @@ -594,7 +593,6 @@ pflash_t *pflash_cfi01_register(target_phys_addr_t base, } pfl->timer = qemu_new_timer_ns(vm_clock, pflash_timer, pfl); - pfl->base = base; pfl->sector_len = sector_len; pfl->total_len = total_len; pfl->width = width; diff --git a/hw/pflash_cfi02.c b/hw/pflash_cfi02.c index 39337ec..43fb3a4 100644 --- a/hw/pflash_cfi02.c +++ b/hw/pflash_cfi02.c @@ -56,7 +56,6 @@ do { \ struct pflash_t { BlockDriverState *bs; - target_phys_addr_t base; uint32_t sector_len; uint32_t chip_len; int mappings; @@ -602,7 +601,6 @@ pflash_t *pflash_cfi02_register(target_phys_addr_t base, name, size); vmstate_register_ram(&pfl->orig_mem, qdev); pfl->storage = memory_region_get_ram_ptr(&pfl->orig_mem); - pfl->base = base; pfl->chip_len = chip_len; pfl->mappings = nb_mappings; pfl->bs = bs; @@ -618,7 +616,7 @@ pflash_t *pflash_cfi02_register(target_phys_addr_t base, pflash_setup_mappings(pfl); pfl->rom_mode = 1; - memory_region_add_subregion(get_system_memory(), pfl->base, &pfl->mem); + memory_region_add_subregion(get_system_memory(), base, &pfl->mem); if (pfl->bs) { pfl->ro = bdrv_is_read_only(pfl->bs);