From patchwork Wed Nov 10 09:45:19 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tomi Valkeinen X-Patchwork-Id: 313462 X-Patchwork-Delegate: tomi.valkeinen@nokia.com Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter1.kernel.org (8.14.4/8.14.3) with ESMTP id oAA9hoKV021810 for ; Wed, 10 Nov 2010 09:43:53 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754901Ab0KJJnt (ORCPT ); Wed, 10 Nov 2010 04:43:49 -0500 Received: from smtp.nokia.com ([147.243.128.24]:30916 "EHLO mgw-da01.nokia.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753940Ab0KJJnq (ORCPT ); Wed, 10 Nov 2010 04:43:46 -0500 Received: from nokia.com (localhost [127.0.0.1]) by mgw-da01.nokia.com (Switch-3.4.3/Switch-3.4.3) with ESMTP id oAA9hiCx016491; Wed, 10 Nov 2010 11:43:44 +0200 Received: from tubuntu.research.nokia.com ([esdhcp03624.research.nokia.com [172.21.36.24]]) by mgw-da01.nokia.com with RELAY id oAA9hXjr015676 ; Wed, 10 Nov 2010 11:43:39 +0200 From: Tomi Valkeinen To: linux-omap@vger.kernel.org, linux-fbdev@vger.kernel.org Cc: Tomi Valkeinen Subject: [PATCH 2/3] OMAP: VRAM: Fix boot-time memory allocation Date: Wed, 10 Nov 2010 11:45:19 +0200 Message-Id: <1289382320-17412-2-git-send-email-tomi.valkeinen@nokia.com> X-Mailer: git-send-email 1.7.1 In-Reply-To: <1289382320-17412-1-git-send-email-tomi.valkeinen@nokia.com> References: <1289382320-17412-1-git-send-email-tomi.valkeinen@nokia.com> X-Nokia-AV: Clean Sender: linux-omap-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-omap@vger.kernel.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.3 (demeter1.kernel.org [140.211.167.41]); Wed, 10 Nov 2010 09:43:53 +0000 (UTC) diff --git a/drivers/video/omap2/vram.c b/drivers/video/omap2/vram.c index bb5ee06..2fd7e52 100644 --- a/drivers/video/omap2/vram.c +++ b/drivers/video/omap2/vram.c @@ -576,9 +576,12 @@ void __init omap_vram_reserve_sdram_memblock(void) return; } } else { - paddr = memblock_alloc_base(size, PAGE_SIZE, MEMBLOCK_REAL_LIMIT); + paddr = memblock_alloc(size, PAGE_SIZE); } + memblock_free(paddr, size); + memblock_remove(paddr, size); + omap_vram_add_region(paddr, size); pr_info("Reserving %u bytes SDRAM for VRAM\n", size);