linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 00/02] staging: tidspbridge: 2.6.37-rcX fixes
@ 2010-11-11  1:50 Omar Ramirez Luna
  2010-11-11  1:50 ` [PATCH 01/02] omap: dsp: remove shm from normal memory Omar Ramirez Luna
                   ` (2 more replies)
  0 siblings, 3 replies; 5+ messages in thread
From: Omar Ramirez Luna @ 2010-11-11  1:50 UTC (permalink / raw)
  To: Greg Kroah-Hartman
  Cc: Tony Lindgren, Russell King, Felipe Contreras, Omar Ramirez Luna,
	Fernando Guzman Lugo, Rene Sapiens, linux-omap, linux-arm-kernel,
	linux-kernel, devel

Hi Greg,

Please consider the following patch set for tidspbridge driver in
staging tree, the following has been tested on an omap3430 based board
+ gst-dsp environment. Many thanks to Felipe Contreras for piling this up,
as I'm just propagating his patches.

First two patches:
1. omap: dsp: remove shm from normal memory
2. staging: tidspbridge: hardcode SCM macros while fix is upstreamed

Resolve a couple of build breaks due to adaptations for memblock
and SCM layer.

(2) Is meant as a temporary fix, until the patches to fix this
    (currently in review) are upstreamed. [1]

The rest of the series, is the revert of iommu migration changes. These
are needed because, without modifications made to iommu module, they do not
work; these modifications (on iommu code) didn't make it for the previous
merge window either.

I will avoid posting the reverts (unless required), they can be found
(along with the two patches of this series) at:

git://dev.omapzoom.org/pub/scm/tidspbridge/kernel-dspbridge.git 
	tidspbridge-2.6.37-rc1

Felipe Contreras (14):
  omap: dsp: remove shm from normal memory
  staging: tidspbridge: hardcode SCM macros while fix is upstreamed

  Revert "staging: tidspbridge - update Kconfig to select IOMMU module"
  Revert "staging: tidspbridge - remove dmm custom module"
  Revert "staging: tidspbridge - deprecate reserve/unreserve_memory
    funtions"
  Revert "staging: tidspbridge - remove reserved memory clean up"
  Revert "staging: tidspbridge: remove dw_dmmu_base from cfg_hostres
    struct"
  Revert "staging: tidspbridge - move all iommu related code to a new
    file"
  Revert "staging: tidspbridge - remove hw directory"
  Revert "staging: tidspbridge - fix mmufault support"
  Revert "staging: tidspbridge - remove custom mmu code from
    tiomap3430.c"
  Revert "staging: tidspbridge - rename bridge_brd_mem_map/unmap to a
    proper name"
  Revert "staging: tidspbridge - move shared memory iommu maps to
    tiomap3430.c"
  Revert "staging: tidspbridge: replace iommu custom for opensource
    implementation"

 arch/arm/plat-omap/devices.c                       |    4 +-
 drivers/staging/tidspbridge/Kconfig                |    1 -
 drivers/staging/tidspbridge/Makefile               |    7 +-
 drivers/staging/tidspbridge/core/_deh.h            |    5 +-
 drivers/staging/tidspbridge/core/_tiomap.h         |   19 +-
 drivers/staging/tidspbridge/core/dsp-mmu.c         |  317 ------
 drivers/staging/tidspbridge/core/io_sm.c           |  180 +++-
 drivers/staging/tidspbridge/core/tiomap3430.c      | 1083 ++++++++++++++++++--
 drivers/staging/tidspbridge/core/tiomap3430_pwr.c  |    4 +
 drivers/staging/tidspbridge/core/tiomap_io.c       |   17 +-
 drivers/staging/tidspbridge/core/ue_deh.c          |  115 ++-
 drivers/staging/tidspbridge/hw/EasiGlobal.h        |   41 +
 drivers/staging/tidspbridge/hw/MMUAccInt.h         |   76 ++
 drivers/staging/tidspbridge/hw/MMURegAcM.h         |  225 ++++
 drivers/staging/tidspbridge/hw/hw_defs.h           |   58 ++
 drivers/staging/tidspbridge/hw/hw_mmu.c            |  562 ++++++++++
 drivers/staging/tidspbridge/hw/hw_mmu.h            |  163 +++
 .../tidspbridge/include/dspbridge/cfgdefs.h        |    1 +
 .../staging/tidspbridge/include/dspbridge/dev.h    |   24 +
 .../staging/tidspbridge/include/dspbridge/dmm.h    |   75 ++
 .../staging/tidspbridge/include/dspbridge/drv.h    |   10 +
 .../tidspbridge/include/dspbridge/dsp-mmu.h        |   67 --
 .../tidspbridge/include/dspbridge/dspdefs.h        |   44 +
 .../tidspbridge/include/dspbridge/dspioctl.h       |    7 +
 .../staging/tidspbridge/include/dspbridge/proc.h   |   46 +
 drivers/staging/tidspbridge/pmgr/dev.c             |   63 ++-
 drivers/staging/tidspbridge/pmgr/dmm.c             |  533 ++++++++++
 drivers/staging/tidspbridge/pmgr/dspapi.c          |   34 +-
 drivers/staging/tidspbridge/rmgr/drv.c             |   15 +
 drivers/staging/tidspbridge/rmgr/drv_interface.c   |    2 +
 drivers/staging/tidspbridge/rmgr/node.c            |   48 +-
 drivers/staging/tidspbridge/rmgr/proc.c            |  197 ++++-
 32 files changed, 3471 insertions(+), 572 deletions(-)
 delete mode 100644 drivers/staging/tidspbridge/core/dsp-mmu.c
 create mode 100644 drivers/staging/tidspbridge/hw/EasiGlobal.h
 create mode 100644 drivers/staging/tidspbridge/hw/MMUAccInt.h
 create mode 100644 drivers/staging/tidspbridge/hw/MMURegAcM.h
 create mode 100644 drivers/staging/tidspbridge/hw/hw_defs.h
 create mode 100644 drivers/staging/tidspbridge/hw/hw_mmu.c
 create mode 100644 drivers/staging/tidspbridge/hw/hw_mmu.h
 create mode 100644 drivers/staging/tidspbridge/include/dspbridge/dmm.h
 delete mode 100644 drivers/staging/tidspbridge/include/dspbridge/dsp-mmu.h
 create mode 100644 drivers/staging/tidspbridge/pmgr/dmm.c


^ permalink raw reply	[flat|nested] 5+ messages in thread

* [PATCH 01/02] omap: dsp: remove shm from normal memory
  2010-11-11  1:50 [PATCH 00/02] staging: tidspbridge: 2.6.37-rcX fixes Omar Ramirez Luna
@ 2010-11-11  1:50 ` Omar Ramirez Luna
  2010-12-02 21:32   ` Russell King - ARM Linux
  2010-11-11  1:50 ` [PATCH 02/02] staging: tidspbridge: hardcode SCM macros while fix is upstreamed Omar Ramirez Luna
  2010-11-11 13:17 ` [PATCH 00/02] staging: tidspbridge: 2.6.37-rcX fixes Greg KH
  2 siblings, 1 reply; 5+ messages in thread
From: Omar Ramirez Luna @ 2010-11-11  1:50 UTC (permalink / raw)
  To: Greg Kroah-Hartman
  Cc: Tony Lindgren, Russell King, Felipe Contreras, Omar Ramirez Luna,
	Fernando Guzman Lugo, Rene Sapiens, linux-omap, linux-arm-kernel,
	linux-kernel, devel

From: Felipe Contreras <felipe.contreras@gmail.com>

Also, don't be picky about the location, which incidentally fixes the
build since MEMBLOCK_REAL_LIMIT is gone on 2.6.37.

arch/arm/plat-omap/devices.c: In function 'omap_dsp_reserve_sdram_memblock':
arch/arm/plat-omap/devices.c:287: error: 'MEMBLOCK_REAL_LIMIT'
    undeclared (first use in this function)

Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
Acked-by: Tony Lindgren <tony@atomide.com>
Signed-off-by: Omar Ramirez Luna <omar.ramirez@ti.com>
---
 arch/arm/plat-omap/devices.c |    4 +++-
 1 files changed, 3 insertions(+), 1 deletions(-)

diff --git a/arch/arm/plat-omap/devices.c b/arch/arm/plat-omap/devices.c
index 6f42a18..fc81912 100644
--- a/arch/arm/plat-omap/devices.c
+++ b/arch/arm/plat-omap/devices.c
@@ -284,12 +284,14 @@ void __init omap_dsp_reserve_sdram_memblock(void)
 	if (!size)
 		return;
 
-	paddr = __memblock_alloc_base(size, SZ_1M, MEMBLOCK_REAL_LIMIT);
+	paddr = memblock_alloc(size, SZ_1M);
 	if (!paddr) {
 		pr_err("%s: failed to reserve %x bytes\n",
 				__func__, size);
 		return;
 	}
+	memblock_free(paddr, size);
+	memblock_remove(paddr, size);
 
 	omap_dsp_phys_mempool_base = paddr;
 }
-- 
1.7.1


^ permalink raw reply related	[flat|nested] 5+ messages in thread

* [PATCH 02/02] staging: tidspbridge: hardcode SCM macros while fix is upstreamed
  2010-11-11  1:50 [PATCH 00/02] staging: tidspbridge: 2.6.37-rcX fixes Omar Ramirez Luna
  2010-11-11  1:50 ` [PATCH 01/02] omap: dsp: remove shm from normal memory Omar Ramirez Luna
@ 2010-11-11  1:50 ` Omar Ramirez Luna
  2010-11-11 13:17 ` [PATCH 00/02] staging: tidspbridge: 2.6.37-rcX fixes Greg KH
  2 siblings, 0 replies; 5+ messages in thread
From: Omar Ramirez Luna @ 2010-11-11  1:50 UTC (permalink / raw)
  To: Greg Kroah-Hartman
  Cc: Tony Lindgren, Russell King, Felipe Contreras, Omar Ramirez Luna,
	Fernando Guzman Lugo, Rene Sapiens, linux-omap, linux-arm-kernel,
	linux-kernel, devel

From: Felipe Contreras <felipe.contreras@gmail.com>

On 2.6.37-rc1, omap platform internals for SCM have changed,
so the build is broken again.

drivers/staging/tidspbridge/core/tiomap3430.c:26:
    fatal error: plat/control.h: No such file or directory

This is a totally ugly layer violation, but needed until
omap_ctrl_set_dsp_boot*() are provided.

Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
Signed-off-by: Omar Ramirez Luna <omar.ramirez@ti.com>
---
 drivers/staging/tidspbridge/core/tiomap3430.c |   14 +++++++++++++-
 1 files changed, 13 insertions(+), 1 deletions(-)

diff --git a/drivers/staging/tidspbridge/core/tiomap3430.c b/drivers/staging/tidspbridge/core/tiomap3430.c
index f22bc12..d302e30 100644
--- a/drivers/staging/tidspbridge/core/tiomap3430.c
+++ b/drivers/staging/tidspbridge/core/tiomap3430.c
@@ -23,7 +23,6 @@
 #include <dspbridge/host_os.h>
 #include <linux/mm.h>
 #include <linux/mmzone.h>
-#include <plat/control.h>
 
 /*  ----------------------------------- DSP/BIOS Bridge */
 #include <dspbridge/dbdefs.h>
@@ -68,6 +67,19 @@
 #define OMAP3_IVA2_BOOTADDR_MASK 0xFFFFFC00
 #define PAGES_II_LVL_TABLE   512
 
+/*
+ * This is a totally ugly layer violation, but needed until
+ * omap_ctrl_set_dsp_boot*() are provided.
+ */
+#define OMAP3_IVA2_BOOTMOD_IDLE 1
+#define OMAP2_CONTROL_GENERAL 0x270
+#define OMAP343X_CONTROL_IVA2_BOOTADDR (OMAP2_CONTROL_GENERAL + 0x0190)
+#define OMAP343X_CONTROL_IVA2_BOOTMOD (OMAP2_CONTROL_GENERAL + 0x0194)
+
+#define OMAP343X_CTRL_REGADDR(reg) \
+	OMAP2_L4_IO_ADDRESS(OMAP343X_CTRL_BASE + (reg))
+
+
 /* Forward Declarations: */
 static int bridge_brd_monitor(struct bridge_dev_context *dev_ctxt);
 static int bridge_brd_read(struct bridge_dev_context *dev_ctxt,
-- 
1.7.1


^ permalink raw reply related	[flat|nested] 5+ messages in thread

* Re: [PATCH 00/02] staging: tidspbridge: 2.6.37-rcX fixes
  2010-11-11  1:50 [PATCH 00/02] staging: tidspbridge: 2.6.37-rcX fixes Omar Ramirez Luna
  2010-11-11  1:50 ` [PATCH 01/02] omap: dsp: remove shm from normal memory Omar Ramirez Luna
  2010-11-11  1:50 ` [PATCH 02/02] staging: tidspbridge: hardcode SCM macros while fix is upstreamed Omar Ramirez Luna
@ 2010-11-11 13:17 ` Greg KH
  2 siblings, 0 replies; 5+ messages in thread
From: Greg KH @ 2010-11-11 13:17 UTC (permalink / raw)
  To: Omar Ramirez Luna
  Cc: Greg Kroah-Hartman, devel, Russell King, Tony Lindgren,
	Felipe Contreras, linux-kernel, Fernando Guzman Lugo, linux-omap,
	Rene Sapiens, linux-arm-kernel

On Wed, Nov 10, 2010 at 07:50:23PM -0600, Omar Ramirez Luna wrote:
> Hi Greg,
> 
> Please consider the following patch set for tidspbridge driver in
> staging tree, the following has been tested on an omap3430 based board
> + gst-dsp environment. Many thanks to Felipe Contreras for piling this up,
> as I'm just propagating his patches.
> 
> First two patches:
> 1. omap: dsp: remove shm from normal memory
> 2. staging: tidspbridge: hardcode SCM macros while fix is upstreamed
> 
> Resolve a couple of build breaks due to adaptations for memblock
> and SCM layer.
> 
> (2) Is meant as a temporary fix, until the patches to fix this
>     (currently in review) are upstreamed. [1]
> 
> The rest of the series, is the revert of iommu migration changes. These
> are needed because, without modifications made to iommu module, they do not
> work; these modifications (on iommu code) didn't make it for the previous
> merge window either.
> 
> I will avoid posting the reverts (unless required), they can be found
> (along with the two patches of this series) at:
> 
> git://dev.omapzoom.org/pub/scm/tidspbridge/kernel-dspbridge.git 
> 	tidspbridge-2.6.37-rc1

I've pulled from this tree and pushed it out to the staging-linus branch
to get sent to Linus before .37 is released.

thanks,

greg k-h

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH 01/02] omap: dsp: remove shm from normal memory
  2010-11-11  1:50 ` [PATCH 01/02] omap: dsp: remove shm from normal memory Omar Ramirez Luna
@ 2010-12-02 21:32   ` Russell King - ARM Linux
  0 siblings, 0 replies; 5+ messages in thread
From: Russell King - ARM Linux @ 2010-12-02 21:32 UTC (permalink / raw)
  To: Omar Ramirez Luna
  Cc: Greg Kroah-Hartman, Tony Lindgren, Felipe Contreras,
	Fernando Guzman Lugo, Rene Sapiens, linux-omap, linux-arm-kernel,
	linux-kernel, devel

On Wed, Nov 10, 2010 at 07:50:24PM -0600, Omar Ramirez Luna wrote:
> From: Felipe Contreras <felipe.contreras@gmail.com>
> 
> Also, don't be picky about the location, which incidentally fixes the
> build since MEMBLOCK_REAL_LIMIT is gone on 2.6.37.

That comment is wrong.  memblock_alloc() is still as picky as the
original.

phys_addr_t __init memblock_alloc(phys_addr_t size, phys_addr_t align)
{
        return memblock_alloc_base(size, align, MEMBLOCK_ALLOC_ACCESSIBLE);
}

        /* Pump up max_addr */
        if (end == MEMBLOCK_ALLOC_ACCESSIBLE)
                end = memblock.current_limit;

and current_limit is initialized to what was MEMBLOCK_REAL_LIMIT.  So,
memblock_alloc() will always allocate from lowmem.

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2010-12-02 21:32 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-11-11  1:50 [PATCH 00/02] staging: tidspbridge: 2.6.37-rcX fixes Omar Ramirez Luna
2010-11-11  1:50 ` [PATCH 01/02] omap: dsp: remove shm from normal memory Omar Ramirez Luna
2010-12-02 21:32   ` Russell King - ARM Linux
2010-11-11  1:50 ` [PATCH 02/02] staging: tidspbridge: hardcode SCM macros while fix is upstreamed Omar Ramirez Luna
2010-11-11 13:17 ` [PATCH 00/02] staging: tidspbridge: 2.6.37-rcX fixes Greg KH

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).