From: Harald Welte Subject: [PATCH 08/14] viafb: Remove MMIO from private structure Date: Sat, 23 May 2009 17:41:30 +0800 Message-ID: <1243071696-9334-8-git-send-email-HaraldWelte@viatech.com> References: <1243071696-9334-1-git-send-email-HaraldWelte@viatech.com> <1243071696-9334-2-git-send-email-HaraldWelte@viatech.com> <1243071696-9334-3-git-send-email-HaraldWelte@viatech.com> <1243071696-9334-4-git-send-email-HaraldWelte@viatech.com> <1243071696-9334-5-git-send-email-HaraldWelte@viatech.com> <1243071696-9334-6-git-send-email-HaraldWelte@viatech.com> <1243071696-9334-7-git-send-email-HaraldWelte@viatech.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Received: from sfi-mx-1.v28.ch3.sourceforge.com ([172.29.28.121] helo=mx.sourceforge.net) by 335xhf1.ch3.sourceforge.com with esmtp (Exim 4.69) (envelope-from ) id 1M7nsE-0007xk-7f for linux-fbdev-devel@lists.sourceforge.net; Sat, 23 May 2009 09:50:38 +0000 Received: from ganesha.gnumonks.org ([213.95.27.120]) by 29vjzd1.ch3.sourceforge.com with esmtps (TLSv1:AES256-SHA:256) (Exim 4.69) id 1M7ns6-0007ts-Qp for linux-fbdev-devel@lists.sourceforge.net; Sat, 23 May 2009 09:50:38 +0000 In-Reply-To: <1243071696-9334-7-git-send-email-HaraldWelte@viatech.com> List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: linux-fbdev-devel-bounces@lists.sourceforge.net To: linux-fbdev-devel@lists.sourceforge.net Cc: Andrew Morton , Harald Welte From: Harald Welte Rather than using our own private structure members for MMIO base and length, we use the fb_info->fix ones. Signed-off-by: Harald Welte Acked-by: Krzysztof Helt --- drivers/video/via/viafbdev.c | 11 ++++------- drivers/video/via/viafbdev.h | 2 -- 2 files changed, 4 insertions(+), 9 deletions(-) diff --git a/drivers/video/via/viafbdev.c b/drivers/video/via/viafbdev.c index 3c4651c..a8bfc0a 100644 --- a/drivers/video/via/viafbdev.c +++ b/drivers/video/via/viafbdev.c @@ -122,9 +122,6 @@ static void viafb_setup_fixinfo(struct fb_fix_screeninfo *fix, strcpy(fix->id, viafb_name); fix->smem_len = viaparinfo->fbmem_free; - fix->mmio_start = viaparinfo->mmio_base; - fix->mmio_len = viaparinfo->mmio_len; - fix->type = FB_TYPE_PACKED_PIXELS; fix->type_aux = 0; @@ -2175,10 +2172,10 @@ static int __devinit via_pci_probe(struct pci_dev *pdev, goto out_delete_i2c; } - viaparinfo->mmio_base = pci_resource_start(pdev, 1); - viaparinfo->mmio_len = pci_resource_len(pdev, 1); - viaparinfo->io_virt = ioremap_nocache(viaparinfo->mmio_base, - viaparinfo->mmio_len); + viafbinfo->fix.mmio_start = pci_resource_start(pdev, 1); + viafbinfo->fix.mmio_len = pci_resource_len(pdev, 1); + viaparinfo->io_virt = ioremap_nocache(viafbinfo->fix.mmio_start, + viafbinfo->fix.mmio_len); if (!viaparinfo->io_virt) { printk(KERN_ERR "ioremap of MMIO failed\n"); rc = -EIO; diff --git a/drivers/video/via/viafbdev.h b/drivers/video/via/viafbdev.h index ed4129e..0c1d734 100644 --- a/drivers/video/via/viafbdev.h +++ b/drivers/video/via/viafbdev.h @@ -47,8 +47,6 @@ struct viafb_par { void __iomem *io_virt; /*iospace virtual memory address */ unsigned int io; /*io space address */ - unsigned long mmio_base; /*mmio base address */ - unsigned long mmio_len; /*mmio base length */ u32 fbmem_free; /* Free FB memory */ u32 fbmem_used; /* Use FB memory size */ u32 cursor_start; /* Cursor Start Address */ -- 1.6.2.4 ------------------------------------------------------------------------------ Register Now for Creativity and Technology (CaT), June 3rd, NYC. CaT is a gathering of tech-side developers & brand creativity professionals. Meet the minds behind Google Creative Lab, Visual Complexity, Processing, & iPhoneDevCamp asthey present alongside digital heavyweights like Barbarian Group, R/GA, & Big Spaceship. http://www.creativitycat.com