aboutsummaryrefslogtreecommitdiff
path: root/include/linux/serial_sci.h
AgeCommit message (Collapse)AuthorFilesLines
2014-03-17serial: sh-sci: Add more register documentationGeert Uytterhoeven1-35/+58
Signed-off-by: Geert Uytterhoeven <[email protected]> Acked-by: Simon Horman <[email protected]> Acked-by: Laurent Pinchart <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
2013-12-24serial: sh-sci: Remove platform data mapbase and irqs fieldsLaurent Pinchart1-26/+0
The fields are not used anymore by board files, remove them. Signed-off-by: Laurent Pinchart <[email protected]> Acked-by: Greg Kroah-Hartman <[email protected]> Signed-off-by: Simon Horman <[email protected]>
2013-12-24serial: sh-sci: Remove platform data scbrr_algo_id fieldLaurent Pinchart1-10/+0
The field isn't set by any board, remote it. Signed-off-by: Laurent Pinchart <[email protected]> Acked-by: Greg Kroah-Hartman <[email protected]> Signed-off-by: Simon Horman <[email protected]>
2013-12-24serial: sh-sci: Rework baud rate calculationLaurent Pinchart1-0/+2
Computing the baud rate register value requires knowledge of the hardware sampling rate. This information is currently encoded in a baud rate calculation algorithm ID passed through platform data. However, it can be derived from the port type directly in most cases. Compute the sampling rate internally in the driver if the baud rate calculation algorithm ID isn't specified, and allow platforms to override the sampling rate through platform data in special cases (this is only required for SCIFA ports on sh7723 and sh7724, the reason needs to be investigated). Signed-off-by: Laurent Pinchart <[email protected]> Acked-by: Greg Kroah-Hartman <[email protected]> Signed-off-by: Simon Horman <[email protected]>
2013-12-24serial: sh-sci: Remove unused GPIO request codeLaurent Pinchart1-12/+0
The driver requests at initialization time GPIOs passed through platform data. No platform makes use of this feature, remove it. Signed-off-by: Laurent Pinchart <[email protected]> Acked-by: Greg Kroah-Hartman <[email protected]> Signed-off-by: Simon Horman <[email protected]>
2013-12-24serial: sh-sci: Move overrun_bit and error_mask fields out of pdataLaurent Pinchart1-3/+0
None of the fields is ever set by board code, and both of them are set in the driver at probe time. Move them out of struct plat_sci_port to struct sci_port. Signed-off-by: Laurent Pinchart <[email protected]> Acked-by: Greg Kroah-Hartman <[email protected]> Signed-off-by: Simon Horman <[email protected]>
2013-12-24serial: sh-sci: Support resources passed through platform resourcesLaurent Pinchart1-4/+4
Memory and IRQ resources are currently passed to the driver through platform data. Support passing them through the standard platform resources mechanism instead. This deprecates platform data resources. Signed-off-by: Laurent Pinchart <[email protected]> Acked-by: Greg Kroah-Hartman <[email protected]> Signed-off-by: Simon Horman <[email protected]>
2013-12-24serial: sh-sci: Simplify baud rate calculation algorithmsLaurent Pinchart1-4/+4
Rewrite the baud rate register value calculations in easier to read forms. The computed value isn't modified. Signed-off-by: Laurent Pinchart <[email protected]> Acked-by: Greg Kroah-Hartman <[email protected]> Signed-off-by: Simon Horman <[email protected]>
2013-12-24serial: sh-sci: Remove baud rate calculation algorithm 5Laurent Pinchart1-1/+0
The algorithm isn't used, remove it. Signed-off-by: Laurent Pinchart <[email protected]> Acked-by: Greg Kroah-Hartman <[email protected]> Signed-off-by: Simon Horman <[email protected]>
2013-09-16Drop support for Renesas H8/300 (h8300) architectureGuenter Roeck1-1/+1
H8/300 has been dead for several years, and the kernel for it has not compiled for ages. Drop support for it. Cc: Yoshinori Sato <[email protected]> Acked-by: Greg Kroah-Hartman <[email protected]> Signed-off-by: Guenter Roeck <[email protected]>
2013-06-17serial: sh-sci: HSCIF supportUlrich Hecht1-3/+9
Adds support for "High Speed Serial Communications Interface with FIFO", essentially a SCIF with 128-byte FIFOs and more accurate baud rate generator. Signed-off-by: Ulrich Hecht <[email protected]> Acked-by: Paul Mundt <[email protected]> Acked-by: Greg Kroah-Hartman <[email protected]> Signed-off-by: Simon Horman <[email protected]>
2012-04-09serial: sh-sci: modify sci_break_ctl()Shimoda, Yoshihiro1-0/+2
SCIF modules which have SCSPTR can output the break signal. Now that we have a way of determining port features/capabilities, add trivial break control via SCSPTR support. Tested on sh7757lcr. Signed-off-by: Yoshihiro Shimoda <[email protected]> Reviewed-by: Simon Horman <[email protected]> Signed-off-by: Paul Mundt <[email protected]>
2011-12-02serial: sh-sci: Handle GPIO function requests.Paul Mundt1-0/+12
This adds initial support for requesting the various GPIO functions necessary for certain ports. This just plugs in dumb request/free logic, but serves as a building block for migrating off of the ->init_pins mess to a wholly gpiolib backed solution (primarily parts with external RTS/CTS pins, but will also allow us to clean up RXD pin testing). Signed-off-by: Paul Mundt <[email protected]>
2011-12-02serial: sh-sci: per-port modem control.Paul Mundt1-0/+10
The bulk of the ports do not support any sort of modem control, so blindly twiddling the MCE bit doesn't accomplish much. We now require ports to manually specify which line supports modem control signals. While at it, tidy up the RTS/CTSIO handling in SCSPTR parts so it's a bit more obvious what's going on (and without clobbering other configurations in the process). Signed-off-by: Paul Mundt <[email protected]>
2011-11-11Merge branches 'sh/pm-runtime' and 'common/clkfwk' into sh-fixes-for-linusPaul Mundt1-2/+0
2011-11-04serial: sh-sci: Fix up SH-2A SCIF support.Phil Edworthy1-0/+1
This fixes up support for SH-2(A) SCIFs by introducing a new regtype. As expected, it's close to the SH-4A SCIF with fifodata, but still different enough to warrant its own type. Fixes up a number of FIFO overflows and similar for both SH7203/SH7264. Signed-off-by: Phil Edworthy <[email protected]> Tested-by: Federico Fuga <[email protected]> Signed-off-by: Paul Mundt <[email protected]>
2011-09-19serial: sh-sci: don't filter on DMA device, use only channel IDGuennadi Liakhovetski1-2/+0
On some sh-mobile systems there are more than one DMA controllers, that can be used for serial ports. Specifying a DMA device in sh-sci platform data unnecessarily restricts the driver to only use one DMA controller. Signed-off-by: Guennadi Liakhovetski <[email protected]> [Fixed the trivial conflict in include/linux/serial_sci.h] Signed-off-by: Vinod Koul <[email protected]>
2011-06-28serial: sh-sci: Fix up pretty name printing for port IRQs.Paul Mundt1-0/+7
Presently these were all using the same static string with no regard to dev_name() and the like. This implements a bit of rework to name the IRQ dynamically, as it should have been doing all along anyways. Signed-off-by: Paul Mundt <[email protected]>
2011-06-14serial: sh-sci: Abstract register maps.Paul Mundt1-0/+36
This takes a bit of a sledgehammer to the horribly CPU subtype ifdef-ridden header and abstracts all of the different register layouts in to distinct types which in turn can be overriden on a per-port basis, or permitted to default to the map matching the port type at probe time. In the process this ultimately fixes up inumerable bugs with mismatches on various CPU types (particularly the legacy ones that were obviously broken years ago and no one noticed) and provides a more tightly coupled and consolidated platform for extending and implementing generic features. Signed-off-by: Paul Mundt <[email protected]>
2011-06-08serial: sh-sci: Consolidate RXD pin handling.Paul Mundt1-0/+2
Non-SCI parts do not have the special port reg necessary for cases where the RX and SCI pins are muxed and need to be manually polled, so these like always fall back on the normal FIFO processing paths. SH7760 is in a class in and of itself with regards to mapping its SIM card interface via the SCI port class despite not having any of the RXD lines wired up and so implicitly behaving more like a SCIF in this regard. Out of the other CPUs, some support the port check via the same block while others do it through an external SuperI/O, so it's not even possible to perform the check relative to the ioremapped cookie offset, so the separate read semantics are preserved here, too. Signed-off-by: Paul Mundt <[email protected]>
2011-06-08serial: sh-sci: Generalize overrun handling.Paul Mundt1-0/+30
This consolidates all of the broken out overrun handling and ensures that we have sensible defaults per-port type, in addition to making sure that overruns are flagged appropriately in the error mask for parts that haven't explicitly disabled support for it. Signed-off-by: Paul Mundt <[email protected]>
2011-01-19serial: sh-sci: Kill off some DMA ifdeffery.Paul Mundt1-4/+2
There's nothing worth hiding under the ifdef in the platform DMA definitions, and we certainly don't want board code adding this in to their platform data definitions, so we always expose the slave rx/tx and device pointer members instead. Signed-off-by: Paul Mundt <[email protected]>
2011-01-19serial: sh-sci: Provide a helper for muxed IRQs.Paul Mundt1-0/+8
All of the muxed IRQs presently populate the IRQ array verbosely, this simply provides a trivial helper to do it for them. Signed-off-by: Paul Mundt <[email protected]>
2011-01-19serial: sh-sci: Kill off unused membase kludge.Paul Mundt1-1/+0
All users of the platform port data specify a mapbase where the driver later derives the membase from. Now that UPF flags are taken in to account for generic ioremapping we can kill off the port-specific membase clobbering and simply use the generic paths. This derives from a time when sh64 was not capable of using the generic ioremap implementation and had employed early bolted DTLB mappings for port access, which is no longer an issue. Signed-off-by: Paul Mundt <[email protected]>
2011-01-19serial: sh-sci: Kill off unused clock string.Paul Mundt1-1/+0
Now that the clock string isn't used by the driver anymore, kill it off from the platform structure. Signed-off-by: Paul Mundt <[email protected]>
2011-01-13Merge branch 'master' of ↵Paul Mundt1-1/+11
master.kernel.org:/pub/scm/linux/kernel/git/torvalds/linux-2.6 into common/serial-rework Conflicts: arch/sh/kernel/cpu/sh2/setup-sh7619.c arch/sh/kernel/cpu/sh2a/setup-mxg.c arch/sh/kernel/cpu/sh2a/setup-sh7201.c arch/sh/kernel/cpu/sh2a/setup-sh7203.c arch/sh/kernel/cpu/sh2a/setup-sh7206.c arch/sh/kernel/cpu/sh3/setup-sh7705.c arch/sh/kernel/cpu/sh3/setup-sh770x.c arch/sh/kernel/cpu/sh3/setup-sh7710.c arch/sh/kernel/cpu/sh3/setup-sh7720.c arch/sh/kernel/cpu/sh4/setup-sh4-202.c arch/sh/kernel/cpu/sh4/setup-sh7750.c arch/sh/kernel/cpu/sh4/setup-sh7760.c arch/sh/kernel/cpu/sh4a/setup-sh7343.c arch/sh/kernel/cpu/sh4a/setup-sh7366.c arch/sh/kernel/cpu/sh4a/setup-sh7722.c arch/sh/kernel/cpu/sh4a/setup-sh7723.c arch/sh/kernel/cpu/sh4a/setup-sh7724.c arch/sh/kernel/cpu/sh4a/setup-sh7763.c arch/sh/kernel/cpu/sh4a/setup-sh7770.c arch/sh/kernel/cpu/sh4a/setup-sh7780.c arch/sh/kernel/cpu/sh4a/setup-sh7785.c arch/sh/kernel/cpu/sh4a/setup-sh7786.c arch/sh/kernel/cpu/sh4a/setup-shx3.c arch/sh/kernel/cpu/sh5/setup-sh5.c drivers/serial/sh-sci.c drivers/serial/sh-sci.h include/linux/serial_sci.h
2010-05-25serial: sh-sci: fix up serial DMA build.Paul Mundt1-3/+1
asm/dmaengine.h no longer exists, update for the shared linux/sh_dma.h header. Signed-off-by: Paul Mundt <[email protected]>
2010-03-23dmaengine: shdma: Remove sh_dmae_slave_chan_id enumMagnus Damm1-2/+2
This patch replaces the sh_dmae_slave_chan_id enum with an unsigned int. The purpose of this chainge is to make it possible to separate the slave id enums from the dmaengine header. The slave id enums varies with processor model, so in the future it makes sense to put these in the processor specific headers together with the pinmux enums. Signed-off-by: Magnus Damm <[email protected]> Signed-off-by: Paul Mundt <[email protected]>
2010-03-10serial: sh-sci: Fix build failure for non-sh architectures.Peter Huewe1-0/+4
This patch fixes a build failure for various arm based defconfigs [1][2][3] and maybe other architectures/configs. The build failure was introduced by the sh specific patch [4] "serial: sh-sci: Add DMA support" by Guennadi Liakhovetski Patch against linux-next of 20100309 References: [1] http://kisskb.ellerman.id.au/kisskb/buildresult/2248992/ [2] http://kisskb.ellerman.id.au/kisskb/buildresult/2248996/ [3] http://kisskb.ellerman.id.au/kisskb/buildresult/2248998/ [4] http://git.kernel.org/?p=linux/kernel/git/sfr/linux-next.git;a=commit;h=73a19e4c0301908ce6346715fd08a74308451f5a Signed-off-by: Peter Huewe <[email protected]> Signed-off-by: Paul Mundt <[email protected]>
2010-03-02serial: sh-sci: Add DMA support.Guennadi Liakhovetski1-0/+6
Support using DMA for sending and receiving data over SCI(F) interfaces of various SH SoCs. Signed-off-by: Guennadi Liakhovetski <[email protected]> Signed-off-by: Paul Mundt <[email protected]>
2009-06-24serial: sh-sci: Move SCBRR calculation algo in to platform data.Paul Mundt1-0/+9
This permits each port to select its own SCBRR calculation algorithm, rather than having it all ifdef'ed in the header. There are presently only 5 different variations that all parts fall under. Signed-off-by: Paul Mundt <[email protected]>
2009-06-24serial: sh-sci: Move SCSCR_INIT in to platform data.Paul Mundt1-0/+11
This moves all of the SCSCR_INIT definitions in to the platform data, for future consolidation. Signed-off-by: Paul Mundt <[email protected]>
2009-05-08sh-sci: improve clock framework supportMagnus Damm1-0/+1
Use enable/disable hooks for clock framework integration. Make sure we control the clock for the serial console as well. Signed-off-by: Magnus Damm <[email protected]> Signed-off-by: Paul Mundt <[email protected]>
2009-05-08sh-sci: remove early_sci_setup()Magnus Damm1-2/+0
Remove unused early_sci_setup() function from sh-sci. Signed-off-by: Magnus Damm <[email protected]> Signed-off-by: Paul Mundt <[email protected]>
2008-02-26serial: Move asm-sh/sci.h to linux/serial_sci.h.Paul Mundt1-0/+32
This header is needed on other architectures as well (namely h8300), which currently fails to build without this in place. Rather than duplicating the port definition completely there, just move this to a common location instead. This should get h8300 working again for 2.6.25, in addition to the changes already pushed by Sato-san in -rc2. Signed-off-by: Paul Mundt <[email protected]>