Re: [PATCH 1/2] DSPBRIDGE: cleanup for PROC_FlushMemory/PROC_InvalidateMemory

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



From: ext Felipe Contreras <felipe.contreras@xxxxxxxxx>
Subject: Re: [PATCH 1/2] DSPBRIDGE: cleanup for PROC_FlushMemory/PROC_InvalidateMemory
Date: Wed, 22 Jul 2009 15:52:47 +0200

> On Wed, Jul 22, 2009 at 11:22 AM, Hiroshi DOYU<Hiroshi.DOYU@xxxxxxxxx> wrote:
> > Both functions are almost same structure except its flag passed to
> > MEM_FlushCache().
> >
> > Signed-off-by: Hiroshi DOYU <Hiroshi.DOYU@xxxxxxxxx>
> > ---
> >  drivers/dsp/bridge/rmgr/proc.c |   82 ++++++++++++++++++---------------------
> >  1 files changed, 38 insertions(+), 44 deletions(-)
> 
> > +       enum DSP_FLUSHTYPE mtype = PROC_WRITEBACK_INVALIDATE_MEM;
> > +
> > +       return proc_memory_sync(hProcessor, pMpuAddr, ulSize, ulFlags, mtype);
> > +}
> 
> What's wrong with sending the type directly?
> return proc_memory_sync(hProcessor, pMpuAddr, ulSize, ulFlags,
> PROC_WRITEBACK_INVALIDATE_MEM);

Just I took the readability rather than a wrapping line because of 80 columns.

> 
> > +       enum DSP_FLUSHTYPE mtype = PROC_INVALIDATE_MEM;
> > +
> > +       return proc_memory_sync(hProcessor, pMpuAddr, ulSize, 0, mtype);
> >  }
> 
> ditto
> 
> And while we are at it, why only PROC_WRITEBACK_INVALIDATE_MEM and
> PROC_INVALIDATE_MEM? How shall user-space issue a call for
> PROC_WRITEBACK_MEM?

Comparing the performance benefit with that may not be a bad idea.

> 
> -- 
> Felipe Contreras
--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Arm (vger)]     [ARM Kernel]     [ARM MSM]     [Linux Tegra]     [Linux WPAN Networking]     [Linux Wireless Networking]     [Maemo Users]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite Trails]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux