From: laurent.pinchart@ideasonboard.com (Laurent Pinchart)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH v6 1/3] serial: sh-sci: Add OF support
Date: Mon, 11 Mar 2013 23:32:31 +0100 [thread overview]
Message-ID: <1689352.QAdqes1IG8@avalon> (raw)
In-Reply-To: <CABYn4sz_5vEzXba0Y7iXKBbGhfGwY2cd8fn30mUQ0GQcbGTG+w@mail.gmail.com>
Hi Bastian,
On Thursday 07 March 2013 11:26:29 Bastian Hecht wrote:
> Hi Laurent,
>
> >> +- renesas,scscr : Should contain a bitfield used by the Serial Control
> >> Register.
> >> + b7 = SCSCR_TIE
> >> + b6 = SCSCR_RIE
> >> + b5 = SCSCR_TE
> >> + b4 = SCSCR_RE
> >> + b3 = SCSCR_REIE
> >> + b2 = SCSCR_TOIE
> >> + b1 = SCSCR_CKE1
> >> + b0 = SCSCR_CKE0
> >
> > What is that for exactly ?
>
> What I can see from 3 different datasheets (sh7372, sh73a0, r8a7740)
> the first 2 bits differ in meaning.
>
> On r8a7740 it depends: In asynchronous mode the first 2 bits CKE0/1
> define whether you want to use an external clock to drive the baud
> generator or if you want to use the internal SUB clock. If you use the
> SUB clock you can further define if you want to use a subscaled SUB
> clock in the SCSMR register. In synchronous mode you must rely on the
> internal clock for the baud generator and can select if the SCK pin is
> used as clock input or output.
What about adding an optional source clock property to the bindings, that
would contain the phandle of the source clock ? If the property is absent then
the internal clock would be used.
How is subscaling used in practice ?
> On sh73a0 and sh7372 it's used to control the output clock SCK (set it
> to high impedance or actually output a clock when in sychronous mode)
Maybe we could add a synchronous mode property to the DT bindings and use it
to infer the bit values.
> Bit 2 and 3 don't exist in my datasheets.
>
> The other bits define under which conditions you receive interrupts
> (send FIFO empty, receive FIFO full) and which bits you need to start
> transfers (one bit to start sending, one receiving). The bits 8 to 31
> are used to set up DMA transfers and various interrupt events like
> error status and finish transfers. I haven't included them as they are
> not used in the driver.
If they're not used maybe we can drop them :-)
--
Regards,
Laurent Pinchart
next prev parent reply other threads:[~2013-03-11 22:32 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-03-06 11:30 [PATCH v6 1/3] serial: sh-sci: Add OF support Bastian Hecht
2013-03-06 11:30 ` [PATCH v6 2/3] ARM: mach-shmobile: r8a7740: Add DT names to clock list Bastian Hecht
2013-03-06 11:30 ` [PATCH v6 3/3] ARM: mach-shmobile: r8a7740: Setup the serial devices using DT Bastian Hecht
2013-03-06 12:10 ` [PATCH v6 1/3] serial: sh-sci: Add OF support Laurent Pinchart
2013-03-06 12:25 ` Laurent Pinchart
2013-03-06 15:29 ` Paul Mundt
2013-03-06 16:33 ` Bastian Hecht
2013-03-07 5:51 ` Arnd Bergmann
2013-03-07 10:26 ` Bastian Hecht
2013-03-11 22:32 ` Laurent Pinchart [this message]
2013-03-12 8:20 ` Paul Mundt
2013-03-12 13:24 ` Laurent Pinchart
2013-03-19 15:10 ` Bastian Hecht
2013-03-27 10:17 ` Laurent Pinchart
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=1689352.QAdqes1IG8@avalon \
--to=laurent.pinchart@ideasonboard.com \
--cc=linux-arm-kernel@lists.infradead.org \
/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;
as well as URLs for NNTP newsgroup(s).