aboutsummaryrefslogtreecommitdiff
path: root/arch/sh/drivers
AgeCommit message (Collapse)AuthorFilesLines
2009-03-17sh: dma: Make G2 DMA configurable.Paul Mundt2-1/+12
Follow the PVR2 DMAC change for G2 DMA. Signed-off-by: Paul Mundt <[email protected]>
2009-03-17sh: dma: Make PVR2 DMA configurable.Paul Mundt2-1/+15
With arch/sh/drivers/dma/ always being built, the Dreamcast DMA engines are being unconditionally built in, regardless of whether the DMA API is enabled or not. This is a regression from previous behaviour, but there is not much advantage in building them all in unconditionally regardless. Add a new config option to make it optional, and update the only user of it to reflect that. Signed-off-by: Paul Mundt <[email protected]>
2009-03-16sh: Move IRQ multi definition of DMAC to defconfigNobuhiro Iwamatsu2-12/+13
When SuperH CPU has IRQ multi of DMAC, SH_DMA_IRQ_MULTI becomes enable. The following CPU's are Multi IRQ of DMAC now. - SH775X and SH7091 - SH776X - SH7780 - SH7785 If SH_DMA_IRQ_MULTI becomes enable, dma-sh api driver is optimized for Multi IRQ. Signed-off-by: Nobuhiro Iwamatsu <[email protected]> Signed-off-by: Paul Mundt <[email protected]>
2009-03-16sh: Disable get_dma_error_irq for non-SH4 targets.Nobuhiro Iwamatsu1-0/+2
dma-sh's get_dma_error_irq() is only used by SH4, as the SH3 doesn't have the DMA Error interrupt. Disable it out for non-SH4 builds. Signed-off-by: Nobuhiro Iwamatsu <[email protected]> Signed-off-by: Paul Mundt <[email protected]>
2009-03-10sh: dma-sh updates for multi IRQ and new SH-4A CPUs.Nobuhiro Iwamatsu3-136/+119
This adds DMA support for newer SH-4A CPUs, particularly SH7763/64/80/85. This also enables multi IRQ support for platforms that have multiple vectors bound to the same IRQ source. Signed-off-by: Nobuhiro Iwamatsu <[email protected]> Signed-off-by: Yoshihiro Shimoda <[email protected]> Signed-off-by: Paul Mundt <[email protected]>
2009-03-10sh: pci-sh7780: fix pci memory address for fixed PMBYoshihiro Shimoda1-2/+2
Fix the problem that cannot work a PCI device when 32-bit physical address mode. Signed-off-by: Yoshihiro Shimoda <[email protected]> Signed-off-by: Paul Mundt <[email protected]>
2009-01-07PCI: sh: use generic INTx swizzle from PCI coreBjorn Helgaas1-16/+1
Use the generic pci_common_swizzle() instead of arch-specific code. Note that pci_common_swizzle() loops based on dev->bus->self, not dev->bus->parent as the sh simple_swizzle() did. I think they are equivalent for this purpose. Signed-off-by: Bjorn Helgaas <[email protected]> Signed-off-by: Jesse Barnes <[email protected]>
2009-01-07PCI: sh: use generic pci_swizzle_interrupt_pin()Bjorn Helgaas2-13/+3
Use the generic pci_swizzle_interrupt_pin() instead of arch-specific code. Acked-by: Paul Mundt <[email protected]> Signed-off-by: Bjorn Helgaas <[email protected]> Signed-off-by: Jesse Barnes <[email protected]>
2008-12-22sh: dma: Kill off ISA DMA wrapper.Paul Mundt2-107/+0
There are no more users for this code, and it has been deprecated for some time, so just kill it off. Signed-off-by: Paul Mundt <[email protected]>
2008-12-22sh: mach-sh03: Use __set_io_port_base(), kill off special ioport_map().Paul Mundt1-1/+2
This also fixes up a long-standing bug for this platform where the PIO base was set to a register offset, rather than the actual PIO offset itself. Signed-off-by: Paul Mundt <[email protected]>
2008-12-22sh: pci-sh7780: fix pci memory address maskYoshihiro Shimoda1-7/+5
Fix the problem that cannot work a PCI device when system memory size is 256Mbyte in 29bit address mode. Signed-off-by: Yoshihiro Shimoda <[email protected]> Signed-off-by: Paul Mundt <[email protected]>
2008-12-22sh: add SH DMAC burst mode constantSteve Glendinning1-0/+1
The SH7709 datasheet defines bit 5 as set for burst mode, clear for cycle-steal mode. Signed-off-by: Steve Glendinning <[email protected]> Signed-off-by: Paul Mundt <[email protected]>
2008-12-22sh: fix DMAOR register access on SH7709Steve Glendinning1-1/+2
sh7709 hardware manual says DMAOR is 16 bits long on this platform. Tested and working with a modified smsc911x ethernet driver (sh-dma support patch for this driver is coming soon). Signed-off-by: Steve Glendinning <[email protected]> Signed-off-by: Paul Mundt <[email protected]>
2008-10-20sh: Migrate common board headers to mach-common/.Paul Mundt5-5/+5
Signed-off-by: Paul Mundt <[email protected]>
2008-07-29sh: Move out the solution engine headers to arch/sh/include/mach-se/Paul Mundt1-1/+1
Signed-off-by: Paul Mundt <[email protected]>
2008-07-29sh: dma-sh: Fix up dreamcast dma.h mach path.Paul Mundt1-1/+1
Signed-off-by: Paul Mundt <[email protected]>
2008-07-29sh: migrate to arch/sh/include/Paul Mundt8-10/+10
This follows the sparc changes a439fe51a1f8eb087c22dd24d69cebae4a3addac. Most of the moving about was done with Sam's directions at: http://marc.info/?l=linux-sh&m=121724823706062&w=2 with subsequent hacking and fixups entirely my fault. Signed-off-by: Sam Ravnborg <[email protected]> Signed-off-by: Paul Mundt <[email protected]>
2008-07-28sh: Renesas R0P7785LC0011RL board supportYoshihiro Shimoda3-0/+113
This adds initial support for the Renesas R0P7785LC0011RL board. This patch supports 29bit address mode only. Signed-off-by: Yoshihiro Shimoda <[email protected]> Signed-off-by: Paul Mundt <[email protected]>
2008-07-28sh: make pcibios_max_latency staticAdrian Bunk1-1/+1
This patch makes the needlessly global pcibios_max_latency static. Signed-off-by: Adrian Bunk <[email protected]> Signed-off-by: Paul Mundt <[email protected]>
2008-07-28sh: make EARLY_PCI_OP's staticAdrian Bunk1-1/+1
This patch makes the needlessly global EARLY_PCI_OP's static. Signed-off-by: Adrian Bunk <[email protected]> Signed-off-by: Paul Mundt <[email protected]>
2008-07-28sh dreamcast: export board_pci_channelsAdrian Bunk1-0/+2
This patch fixes the following build error: <-- snip --> ... MODPOST 1837 modules ERROR: "board_pci_channels" [drivers/pcmcia/yenta_socket.ko] undefined! ... make[2]: *** [__modpost] Error 1 <-- snip --> I freely admit that it's a pathological configuration, but as long as it is allowed it should build. Reported-by: Adrian Bunk <[email protected]> Signed-off-by: Adrian Bunk <[email protected]> Signed-off-by: Paul Mundt <[email protected]>
2008-07-21sysdev: Pass the attribute to the low level sysdev show/store functionAndi Kleen1-4/+11
This allow to dynamically generate attributes and share show/store functions between attributes. Right now most attributes are generated by special macros and lots of duplicated code. With the attribute passed it's instead possible to attach some data to the attribute and then use that in shared low level functions to do different things. I need this for the dynamically generated bank attributes in the x86 machine check code, but it'll allow some further cleanups. I converted all users in tree to the new show/store prototype. It's a single huge patch to avoid unbisectable sections. Runtime tested: x86-32, x86-64 Compiled only: ia64, powerpc Not compile tested/only grep converted: sh, arm, avr32 Signed-off-by: Andi Kleen <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
2008-06-27PCI: remove unused arch pcibios_update_resource() functionsAdrian Bunk1-32/+0
Russell King did the following back in 2003: <-- snip --> [PCI] pci-9: Kill per-architecture pcibios_update_resource() Kill pcibios_update_resource(), replacing it with pci_update_resource(). pci_update_resource() uses pcibios_resource_to_bus() to convert a resource to a device BAR - the transformation should be exactly the same as the transformation used for the PCI bridges. pci_update_resource "knows" about 64-bit BARs, but doesn't attempt to set the high 32-bits to anything non-zero - currently no architecture attempts to do something different. If anyone cares, please fix; I'm going to reflect current behaviour for the time being. Ivan pointed out the following architectures need to examine their pcibios_update_resource() implementation - they should make sure that this new implementation does the right thing. #warning's have been added where appropriate. ia64 mips mips64 This cset also includes a fix for the problem reported by AKPM where 64-bit arch compilers complain about the resource mask being placed in a u32. <-- snip --> This patch removes the unused pcibios_update_resource() functions the kernel gained since, from FRV, m68k, mips & sh architectures. Signed-off-by: Adrian Bunk <[email protected]> Acked-by: David Howells <[email protected]> Acked-by: Greg Ungerer <[email protected]> Acked-by: Paul Mundt <[email protected]> Acked-by: Ralf Baechle <[email protected]> Signed-off-by: Jesse Barnes <[email protected]>
2008-05-21MODULE_LICENSE expects "GPL v2", not "GPLv2"Al Viro1-1/+1
... and we have few enough places using the latter to make it simpler to do search and replace... Signed-off-by: Al Viro <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2008-04-29iomap: fix 64 bits resources on 32 bitsBenjamin Herrenschmidt1-2/+2
Almost all implementations of pci_iomap() in the kernel, including the generic lib/iomap.c one, copies the content of a struct resource into unsigned long's which will break on 32 bits platforms with 64 bits resources. This fixes all definitions of pci_iomap() to use resource_size_t. I also "fixed" the 64bits arch for consistency. Signed-off-by: Benjamin Herrenschmidt <[email protected]> Cc: <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2008-04-20PCI: remove initial bios sort of PCI devices on x86Greg Kroah-Hartman1-2/+0
We currently keep 2 lists of PCI devices in the system, one in the driver core, and one all on its own. This second list is sorted at boot time, in "BIOS" order, to try to remain compatible with older kernels (2.2 and earlier days). There was also a "nosort" option to turn this sorting off, to remain compatible with even older kernel versions, but that just ends up being what we have been doing from 2.5 days... Unfortunately, the second list of devices is not really ever used to determine the probing order of PCI devices or drivers[1]. That is done using the driver core list instead. This change happened back in the early 2.5 days. Relying on BIOS ording for the binding of drivers to specific device names is problematic for many reasons, and userspace tools like udev exist to properly name devices in a persistant manner if that is needed, no reliance on the BIOS is needed. Matt Domsch and others at Dell noticed this back in 2006, and added a boot option to sort the PCI device lists (both of them) in a breadth-first manner to help remain compatible with the 2.4 order, if needed for any reason. This option is not going away, as some systems rely on them. This patch removes the sorting of the internal PCI device list in "BIOS" mode, as it's not needed at all anymore, and hasn't for many years. I've also removed the PCI flags for this from some other arches that for some reason defined them, but never used them. This should not change the ordering of any drivers or device probing. [1] The old-style pci_get_device and pci_find_device() still used this sorting order, but there are very few drivers that use these functions, as they are deprecated for use in this manner. If for some reason, a driver rely on the order and uses these functions, the breadth-first boot option will resolve any problem. Cc: Matt Domsch <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
2008-02-27arch/sh/drivers/dma/dma-sh.c: Correct use of ! and &Julia Lawall1-1/+1
In commit e6bafba5b4765a5a252f1b8d31cbf6d2459da337, a bug was fixed that involved converting !x & y to !(x & y). The code below shows the same pattern, and thus should perhaps be fixed in the same way. This is not tested and clearly changes the semantics, so it is only something to consider. The semantic patch that makes this change is as follows: (http://www.emn.fr/x-info/coccinelle/) // <smpl> @@ expression E1,E2; @@ ( !E1 & !E2 | - !E1 & E2 + !(E1 & E2) ) // </smpl> Signed-off-by: Julia Lawall <[email protected]> Signed-off-by: Paul Mundt <[email protected]>
2008-02-26sh: revert dreamcast pci changeMagnus Damm1-22/+22
Commit e036eaa681a17f71b64f6d9040fe605555623919 broke dreamcast pci, this patch fixes that by reverting the dreamcast specific bits. Signed-off-by: Magnus Damm <[email protected]> Acked-by: Adrian McMenamin <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Paul Mundt <[email protected]>
2008-02-26sh: heartbeat: ioremap is expected to succeedRoel Kluin1-1/+1
ioremap is expected to succeed Signed-off-by: Roel Kluin <[email protected]> Signed-off-by: Paul Mundt <[email protected]>
2008-02-14sh: fix pci io access for r2d boardsMagnus Damm1-1/+2
Use generic_io_base to point out the pci io window, and make sure the highest port address used is SH7751_PCI_IO_SIZE - 1. This patch fixes pci io port access for the r2d boards - CONFIG_8139TOO_PIO now works as expected. So does the alsa driver for CMI8738. Signed-off-by: Magnus Damm <[email protected]> Acked-by: Katsuya MATSUBARA <[email protected]> Signed-off-by: Paul Mundt <[email protected]>
2008-02-14sh: use ctrl_in/out for on chip pci accessMagnus Damm6-37/+37
This patch makes sure ctrl_inN/outN are used instead of inN/outN for on chip pci registers. Without this patch addresses may be adjusted using the value in generic_io_base. This patch makes it possible to set generic_io_base and have pci without reading and writing all over the place. Signed-off-by: Magnus Damm <[email protected]> Acked-by: Katsuya MATSUBARA <[email protected]> Signed-off-by: Paul Mundt <[email protected]>
2008-02-14sh: remove unneeded castStephen Rothwell1-1/+1
now that platform_device_register_simple() takes a "const chat *". Signed-off-by: Stephen Rothwell <[email protected]> Signed-off-by: Paul Mundt <[email protected]>
2008-02-01PCI: Kconfig help: don't refer to the PCI-HOWTOAdrian Bunk1-5/+0
A HOWTO that hasn't been updated for half a dozen years no longer "contains valuable information about which PCI hardware does work under Linux and which doesn't". Signed-off-by: Adrian Bunk <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
2008-01-28sh: update r7780rp interrupt codeMagnus Damm1-14/+2
This patch updates the board specific irq code for r7780rp. The new code is very similar to the other highlander implementations, with the exception that the r7780rp handles pci interrupts using IRL. To simplify the pci code and use the same interrupt numbers as r7780mp and r7785rp we hook in to the cpu specific pci vectors. The pci interrupts and the push switch all work well with and without this patch. CF and AX88796 are not ok though and the source of the problem is unknown at this point. The AX88796 does for not detect it's proper mac address (IPL gets it right) and the kernel hangs on CF access. As a workaround this patch removes the CF and the AX88796 from the platform datain case of r7780rp. Signed-off-by: Magnus Damm <[email protected]> Signed-off-by: Paul Mundt <[email protected]>
2008-01-28sh: use declared coherent memory for dreamcast pci ethernet adapterMagnus Damm3-72/+11
This patch makes the dreamcast use the recently added declared coherent memory functions to point out the memory window suitable for dma. Apart from cleaning up, this gives the dreamcast a proper memory allocator for pci dma memory. Signed-off-by: Magnus Damm <[email protected]> Signed-off-by: Paul Mundt <[email protected]>
2008-01-28sh: Add support for SDK7780 board.Nicholas Beck3-0/+133
Add support for Renesas Technology Europe SDK7780 board. Signed-off-by: Nicholas Beck <[email protected]> Signed-off-by: Paul Mundt <[email protected]>
2008-01-28sh: Kill off dead HS771RVoIP board support.Paul Mundt1-2/+0
Signed-off-by: Paul Mundt <[email protected]>
2008-01-28sh: Add support for SH7763 CPU subtype.Yoshihiro Shimoda4-1/+6
Signed-off-by: Yoshihiro Shimoda <[email protected]> Signed-off-by: Paul Mundt <[email protected]>
2008-01-28sh: Add support for SH7721 CPU subtype.Yoshihiro Shimoda2-1/+3
Signed-off-by: Yoshihiro Shimoda <[email protected]> Signed-off-by: Paul Mundt <[email protected]>
2008-01-28sh: Get the SH-5 PCI support building.Paul Mundt6-383/+270
Signed-off-by: Paul Mundt <[email protected]>
2008-01-28sh: Kill off the rest of arch/sh64/kernel/.Paul Mundt2-0/+643
Signed-off-by: Paul Mundt <[email protected]>
2008-01-24Driver core: change sysdev classes to use dynamic kobject namesKay Sievers1-1/+1
All kobjects require a dynamically allocated name now. We no longer need to keep track if the name is statically assigned, we can just unconditionally free() all kobject names on cleanup. Signed-off-by: Kay Sievers <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
2007-11-30sh: Support PCI IO access of SH7780 base boards.Nobuhiro Iwamatsu2-4/+4
The IO access of PCI is not supported in R7780RP and the MS7780SE board now. The support of the IO access mode of e100 and a lot of IDE chips becomes possible by fixing the code. Signed-off-by: Nobuhiro Iwamatsu <[email protected]> Signed-off-by: Paul Mundt <[email protected]>
2007-11-30sh: Fix PCI IO space base address of SH7780.Nobuhiro Iwamatsu1-1/+1
PCI IO space base address of SH7780 was wrong. Change from 0xFE400000 to 0xFE200000. Signed-off-by: Nobuhiro Iwamatsu <[email protected]> Signed-off-by: Paul Mundt <[email protected]>
2007-11-07sh: Kill off the remaining ST40 cruft.Paul Mundt3-625/+0
The ST40 stuff in-tree hasn't built for some time, and hasn't been updated for over 3 years. ST maintains their own out-of-tree changes and rebases occasionally, and that's ultimately where all of the ST40 users go anyways. In order for the ST40 code to be brought up to date most of the stuff removed in this changeset would have to be rewritten anyways, so there's very little benefit in keeping the remnants around either. Signed-off-by: Paul Mundt <[email protected]>
2007-10-30sh: ARRAY_SIZE() cleanupAlejandro Martinez Ruiz1-2/+2
I'm converting most array size calculations under arch/ to use the ARRAY_SIZE() macro. This is the (tiny) patch for sh. Signed-off-by: Alejandro Martinez Ruiz <[email protected]> Signed-off-by: Paul Mundt <[email protected]>
2007-10-17Remove dma_cache_(wback|inv|wback_inv) functionsRalf Baechle1-1/+1
dma_cache_(wback|inv|wback_inv) were the earliest attempt on a generalized cache managment API for I/O purposes. Originally it was basically the raw MIPS low level cache API exported to the entire world. The API has suffered from a lack of documentation, was not very widely used unlike it's more modern brothers and can easily be replaced by dma_cache_sync. So remove it rsp. turn the surviving bits back into an arch private API, as discussed on linux-arch. Signed-off-by: Ralf Baechle <[email protected]> Acked-by: Paul Mundt <[email protected]> Acked-by: Paul Mackerras <[email protected]> Acked-by: David S. Miller <[email protected]> Acked-by: Kyle McMartin <[email protected]> Acked-by: Haavard Skinnemoen <[email protected]> Cc: <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2007-09-24sh: Revert incorrect license string changes.Paul Mundt1-1/+1
These were right the first time. Either a thinko or building in the wrong tree. Revert this. Signed-off-by: Paul Mundt <[email protected]>
2007-09-21sh: dma: Fix up build for SH7709 support.Kristoffer Ericson1-0/+1
Trivial build fixes for SH7709. Signed-off-by: Kristoffer Ericson <[email protected]> Signed-off-by: Paul Mundt <[email protected]>
2007-09-21sh: remove sh7780 interrupt controller hack from pci codeMagnus Damm1-13/+0
This patch removes the sh778x specific pci code that pokes in the interrupt controller and overwrites things. The new and improved IRL code manages this in plat_irq_setup() and plat_irq_setup_pins() instead. Signed-off-by: Magnus Damm <[email protected]> Signed-off-by: Paul Mundt <[email protected]>