public inbox for linux-serial@vger.kernel.org
 help / color / mirror / Atom feed
From: Venkatraman S <svenkatr@ti.com>
To: Tony Lindgren <tony@atomide.com>,
	"G, Manjunath Kondaiah" <manjugk@ti.com>,
	"Raja, Govindraj" <govindraj.raja@ti.com>,
	Greg KH <greg@kroah.com>, "linux-serial@vger.kernel.org" <linux>
Subject: Re: [PATCH] serial: Add OMAP high-speed UART driver.
Date: Tue, 2 Mar 2010 19:16:12 +0530	[thread overview]
Message-ID: <618f0c911003020546mb7c8412o2bac4e86a081332b@mail.gmail.com> (raw)
In-Reply-To: <20100302065224.GL3389@atomide.com>

On Tue, Mar 2, 2010 at 12:22 PM, Tony Lindgren <tony@atomide.com> wrote:
> * G, Manjunath Kondaiah <manjugk@ti.com> [100301 22:24]:
>>
>>
>>
>> > > > > +     up->uart_dma.prev_rx_dma_pos =
>> > up->uart_dma.rx_buf_dma_phys;
>> > > > > +     if (cpu_is_omap44xx())
>> > > > > +             omap_writel(0, OMAP44XX_DMA4_BASE
>> > > > > +                     +
>> > OMAP_DMA4_CDAC(up->uart_dma.rx_dma_channel));
>> > > > > +     else
>> > > > > +             omap_writel(0, OMAP34XX_DMA4_BASE
>> > > > > +                     +
>> > OMAP_DMA4_CDAC(up->uart_dma.rx_dma_channel));
>> > > >
>> > > > NAK. Please don't use omap_read/write for for new code. And do not
>> > > > tinker with the omap hardware registers directly in the driver.
>> > > >
>> > > > This needs to be done properly in
>> > arch/arm/plat-omap/dma.c instead.
>> > >
>> > > Thanks for the suggestion.
>> > >
>> > > Currently, dma_read/dma_write are #define's in dma.c which
>> > cannot be
>> > > accessed outside dma.c. I don't see any API's in dma.c for
>> > setting required
>> > > value for this register?
>> >
>> > Hmm isn't this the same as omap_get_dma_dst_pos(int lch)? If you're
>> > trying do something that's not in dma.c, we can add a new function
>> > for it.
>>
>> The omap_get_dma_dst_pos(int lch) is for read operation in CDAC register.
>> But, We need to write required value into CDAC register. For this, I propose:
>>
>> omap_set_dma_dst_pos(int lch, int value) which does not exist in current dma
>> driver.
>
> OK, it that's needed.
>
> Tony
> --
CDAC is a shadow register used for monitoring the DMA channel.
 I think it would be a lot
simpler if omap_start_dma() always resets CDAC to 0, and the UART driver
just not set it explicitly.

Simple wrapper APIs doing get / set on individual DMA registers is as
difficult to understand
as omap_read / omap_write, IMHO.

Best regards,
Venkat.
--
To unsubscribe from this list: send the line "unsubscribe linux-serial" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

  reply	other threads:[~2010-03-02 13:46 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-03-01 14:43 [PATCH] serial: Add OMAP high-speed UART driver Govindraj.R
2010-03-01 18:13 ` Alan Cox
2010-03-01 18:46 ` Tony Lindgren
2010-03-02  5:51   ` G, Manjunath Kondaiah
2010-03-02  6:08     ` Tony Lindgren
2010-03-02  6:27       ` G, Manjunath Kondaiah
2010-03-02  6:52         ` Tony Lindgren
2010-03-02 13:46           ` Venkatraman S [this message]
2010-03-02 13:58             ` G, Manjunath Kondaiah
     [not found]             ` <E0D41E29EB0DAC4E9F3FF173962E9E94026ED96358@dbde02.ent.ti.com>
2010-03-02 14:04               ` Shilimkar, Santosh
     [not found]               ` <EAF47CD23C76F840A9E7FCE10091EFAB02C44C22F6@dbde02.ent.ti.com>
2010-03-02 15:03                 ` G, Manjunath Kondaiah
2010-03-02 15:13                   ` Shilimkar, Santosh
     [not found]                   ` <EAF47CD23C76F840A9E7FCE10091EFAB02C44C2348@dbde02.ent.ti.com>
2010-03-03  5:26                     ` G, Manjunath Kondaiah

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=618f0c911003020546mb7c8412o2bac4e86a081332b@mail.gmail.com \
    --to=svenkatr@ti.com \
    --cc=govindraj.raja@ti.com \
    --cc=greg@kroah.com \
    --cc=manjugk@ti.com \
    --cc=tony@atomide.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox