From: Scott Wood <scottwood@freescale.com>
To: Laurent Pinchart <laurentp@cse-semaphore.com>
Cc: linuxppc-dev@ozlabs.org
Subject: Re: [RFC] Using two baud rate generators with the cpm_uart driver
Date: Tue, 15 Apr 2008 10:34:42 -0500 [thread overview]
Message-ID: <4804CB12.1000308@freescale.com> (raw)
In-Reply-To: <200804151532.27057.laurentp@cse-semaphore.com>
Laurent Pinchart wrote:
> thanks to a bad hardware design decision, I'm faced with a software issue with
> the cpm_uart driver.
>
> My hardware uses either SCC4 or SMC2 (production-time option) as an RS485 port
> with an external transceiver. The transceiver's data direction is controlled
> by external logic that monitors the SCC4/SMC2 TxD signal.
>
> The external logic needs an input clock at the baud rate frequency on the
> MPC8248 BRG5 output pin (although I could modify it to accept an input clock
> at 16x the baud rate frequency). This means the cpm_uart driver has to setup
> two baud rate generators instead of one.
>
> The ppc architecture was easy to hack as it used a fs_uart_platform_info
> structure in which I added a set_brg function pointer provided by platform
> code. This isn't possible with the powerpc architecture anymore.
>
> Is there a clean way to fix this issue ? Kicking the hardware designer won't
> help :-)
Maybe not, but it'd be satisfying. :-)
The clean solution would be to have an abstracted clock API, similar to
phylib, where the caller doesn't know details about BRGs and such.
Maybe the linux/clk.h API would be suitable; I haven't looked at it in
detail.
-Scott
next prev parent reply other threads:[~2008-04-15 15:34 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-04-15 13:32 [RFC] Using two baud rate generators with the cpm_uart driver Laurent Pinchart
2008-04-15 15:34 ` Scott Wood [this message]
2008-04-15 15:54 ` Laurent Pinchart
2008-04-15 15:59 ` Scott Wood
2008-04-15 16:03 ` 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=4804CB12.1000308@freescale.com \
--to=scottwood@freescale.com \
--cc=laurentp@cse-semaphore.com \
--cc=linuxppc-dev@ozlabs.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.