summaryrefslogtreecommitdiffstats
path: root/drivers/mmc/au1xmmc.c
Commit message (Collapse)AuthorAgeFilesLines
* mmc: Allow host drivers to specify max block countPierre Ossman2007-02-041-0/+1
| | | | | | | | | | | | Many controllers have an upper limit on the number of blocks that can be transferred in one request. Allow the host drivers to specify this and make sure we avoid hitting this limit. Also change the max_sectors field to avoid confusion. This makes it map less directly to the block layer limits, but as they didn't apply directly on MMC cards anyway, this isn't a great loss. Signed-off-by: Pierre Ossman <drzeus@drzeus.cx>
* mmc: Allow host drivers to specify a max block sizePierre Ossman2007-02-041-0/+2
| | | | | | | Most controllers have an upper limit on the block size. Allow the host drivers to specify this and make sure we avoid hitting this limit. Signed-off-by: Pierre Ossman <drzeus@drzeus.cx>
* mmc: au1xmmc: return errors for unknown response typesManuel Lauss2007-02-041-0/+6
| | | | | | | au1xmmc: return error when encountering unhandled/unknown response type. Signed-off-by: Manuel Lauss <mano@roarinelk.homelinux.net> Signed-off-by: Pierre Ossman <drzeus@drzeus.cx>
* mmc: au1xmmc: implement proper ro switch detectionManuel Lauss2007-02-041-1/+3
| | | | | | | au1xmmc: implement proper R/O switch detection. Signed-off-by: Manuel Lauss <mano@roarinelk.homelinux.net> Signed-off-by: Pierre Ossman <drzeus@drzeus.cx>
* mmc: fix au1xmmc build errorYoichi Yuasa2006-12-051-1/+1
| | | | | | | | | | | | | | | | | | | | | | This patch has fixed the following build error abou au1xmmc. drivers/mmc/au1xmmc.c: In function `au1xmmc_poll_event': drivers/mmc/au1xmmc.c:835: warning: unused variable `status' drivers/mmc/au1xmmc.c: At top level: drivers/mmc/au1xmmc.c:878: error: parse error before "const" drivers/mmc/au1xmmc.c: In function `au1xmmc_probe': drivers/mmc/au1xmmc.c:909: error: `au1xmmc_ops' undeclared (first use in this function) drivers/mmc/au1xmmc.c:909: error: (Each undeclared identifier is reported only once drivers/mmc/au1xmmc.c:909: error: for each function it appears in.) drivers/mmc/au1xmmc.c: At top level: drivers/mmc/au1xmmc.c:659: warning: 'au1xmmc_request' defined but not used drivers/mmc/au1xmmc.c:719: warning: 'au1xmmc_set_ios' defined but not used make[2]: *** [drivers/mmc/au1xmmc.o] Error 1 make[1]: *** [drivers/mmc] Error 2 make: *** [drivers] Error 2 Signed-off-by: Yoichi Yuasa <yoichi_yuasa@tripeaks.co.jp> Signed-off-by: Pierre Ossman <drzeus@drzeus.cx>
* mmc: constify mmc_host_ops vectorsDavid Brownell2006-12-011-1/+1
| | | | | | | | Now that mmc_host_ops can be constified, update the various drivers to constify those method tables and shrink the writable data segment. Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Pierre Ossman <drzeus@drzeus.cx>
* IRQ: Maintain regs pointer globally rather than passing to IRQ handlersDavid Howells2006-10-051-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Maintain a per-CPU global "struct pt_regs *" variable which can be used instead of passing regs around manually through all ~1800 interrupt handlers in the Linux kernel. The regs pointer is used in few places, but it potentially costs both stack space and code to pass it around. On the FRV arch, removing the regs parameter from all the genirq function results in a 20% speed up of the IRQ exit path (ie: from leaving timer_interrupt() to leaving do_IRQ()). Where appropriate, an arch may override the generic storage facility and do something different with the variable. On FRV, for instance, the address is maintained in GR28 at all times inside the kernel as part of general exception handling. Having looked over the code, it appears that the parameter may be handed down through up to twenty or so layers of functions. Consider a USB character device attached to a USB hub, attached to a USB controller that posts its interrupts through a cascaded auxiliary interrupt controller. A character device driver may want to pass regs to the sysrq handler through the input layer which adds another few layers of parameter passing. I've build this code with allyesconfig for x86_64 and i386. I've runtested the main part of the code on FRV and i386, though I can't test most of the drivers. I've also done partial conversion for powerpc and MIPS - these at least compile with minimal configurations. This will affect all archs. Mostly the changes should be relatively easy. Take do_IRQ(), store the regs pointer at the beginning, saving the old one: struct pt_regs *old_regs = set_irq_regs(regs); And put the old one back at the end: set_irq_regs(old_regs); Don't pass regs through to generic_handle_irq() or __do_IRQ(). In timer_interrupt(), this sort of change will be necessary: - update_process_times(user_mode(regs)); - profile_tick(CPU_PROFILING, regs); + update_process_times(user_mode(get_irq_regs())); + profile_tick(CPU_PROFILING); I'd like to move update_process_times()'s use of get_irq_regs() into itself, except that i386, alone of the archs, uses something other than user_mode(). Some notes on the interrupt handling in the drivers: (*) input_dev() is now gone entirely. The regs pointer is no longer stored in the input_dev struct. (*) finish_unlinks() in drivers/usb/host/ohci-q.c needs checking. It does something different depending on whether it's been supplied with a regs pointer or not. (*) Various IRQ handler function pointers have been moved to type irq_handler_t. Signed-Off-By: David Howells <dhowells@redhat.com> (cherry picked from 1b16e7ac850969f38b375e511e3fa2f474a33867 commit)
* [PATCH] Alchemy: Delete unused pt_regs * argument from au1xxx_dbdma_chan_allocRalf Baechle2006-09-261-1/+1
| | | | | | | | | | | | The third argument of au1xxx_dbdma_chan_alloc's callback function is not used anywhere. Signed-off-by: Ralf Baechle <ralf@linux-mips.org> Cc: David Howells <dhowells@redhat.com> Cc: Russell King <rmk@arm.linux.org.uk> Cc: Alan Cox <alan@lxorguk.ukuu.org.uk> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
* [PATCH] irq-flags: misc drivers: Use the new IRQF_ constantsThomas Gleixner2006-07-021-1/+1
| | | | | | | | | Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Cc: Ingo Molnar <mingo@elte.hu> Cc: "David S. Miller" <davem@davemloft.net> Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
* Remove obsolete #include <linux/config.h>Jörn Engel2006-06-301-1/+0
| | | | | Signed-off-by: Jörn Engel <joern@wohnheim.fh-wedel.de> Signed-off-by: Adrian Bunk <bunk@stusta.de>
* [ARM] 3531/1: i.MX/MX1 SD/MMC ensure, that clock are stopped before new ↵Pavel Pisa2006-05-191-3/+3
| | | | | | | | | | | | | | command and cleanups Patch from Pavel Pisa There has been problems that for some paths that clock are not stopped during new command programming and initiation. Result is issuing of incorrect command to the card. Some other problems are cleaned too. Noisy report of known ERRATUM #4 has been suppressed. Signed-off-by: Pavel Pisa <pisa@cmp.felk.cvut.cz> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
* [MMC] Move set_ios debugging into mmc.cRussell King2006-05-041-4/+0
| | | | | | | | Rather than having every driver duplicate the set_ios debugging, provide a single version in mmc.c which can be expanded as we add additional functionality. Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
* [MMC] Pass -DDEBUG on compiler command line if MMC_DEBUG selectedRussell King2006-03-291-10/+9
| | | | | | | | | | Rather than each driver test MMC_DEBUG itself, and define DEBUG, pass it in via the makefile instead. Fix drivers to use pr_debug() where appropriate, and avoid defining a DEBUG() macro. Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
* [PATCH] Remove MODULE_PARMRusty Russell2006-03-251-1/+1
| | | | | | | | | | MODULE_PARM was actually breaking: recent gcc version optimize them out as unused. It's time to replace the last users, which are generally in the most unloved drivers anyway. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
* [MMC] au1xmmc: Fix a compilation warning ('status' is not used)Martin Michlmayr2006-03-041-1/+0
| | | | | | | | | | | | Fix a trivial compilation warning: CC drivers/mmc/au1xmmc.o drivers/mmc/au1xmmc.c: In function ‘au1xmmc_dma_callback’: drivers/mmc/au1xmmc.c:743: warning: unused variable ‘status’ Signed-off-by: Martin Michlmayr <tbm@cyrius.com> Acked-by: Martin Michlmayr <tbm@cyrius.com> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
* [MMC] au1xmmc: Fix linking error because mmc_rsp_type doesn't existMartin Michlmayr2006-03-041-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | drivers/mmc/au1xmmc.c doesn't compile because commit e92251762d02a46177d4105d1744041e3f8bc465 introduced a typo and passes the wrong argument to the mmc_resp_type macro. Error because of the typo: CC drivers/mmc/au1xmmc.o drivers/mmc/au1xmmc.c: In function ‘au1xmmc_send_command’: drivers/mmc/au1xmmc.c:197: warning: implicit declaration of function ‘mmc_rsp_type’ ... LD .tmp_vmlinux1 drivers/built-in.o: In function `au1xmmc_request':au1xmmc.c:(.text+0x89504): undefined reference to `mmc_rsp_type' :au1xmmc.c:(.text+0x8968c): undefined reference to `mmc_rsp_type' make: *** [.tmp_vmlinux1] Error 1 Error because of the wrong argument: CC drivers/mmc/au1xmmc.o drivers/mmc/au1xmmc.c: In function ‘au1xmmc_send_command’: drivers/mmc/au1xmmc.c:197: error: invalid type argument of ‘->’ Signed-off-by: Martin Michlmayr <tbm@cyrius.com> Acked-by: Jordan Crouse <jordan.crouse@amd.com> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
* [MMC] au1xmmc: Fix compilation error by using platform_driverMartin Michlmayr2006-03-041-10/+11
| | | | | | | | | | | | | | | drivers/mmc/au1xmmc.c currently doesn't compile; it needs to be converted to use platform_driver. I cannot test this change because of lack of hardware but I followed the drivers this one is based on, and the code is certainly not worse than before. drivers/mmc/au1xmmc.c: At top level: drivers/mmc/au1xmmc.c:1002: error: ‘platform_bus_type’ undeclared here (not in a function) make[2]: *** [drivers/mmc/au1xmmc.o] Error 1 Signed-off-by: Martin Michlmayr <tbm@cyrius.com> Acked-by: Jordan Crouse <jordan.crouse@amd.com> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
* [MMC] Add MMC command type flagsRussell King2006-02-021-29/+30
| | | | | | | Some hosts need to know the command type, so pass it via a set of flags in cmd->flags. Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
* Au1[12]00 mmc driver. Only tested on the Au1200 at this point thoughPete Popov2005-10-291-0/+1026
it should work on the Au1100 as well. Updated defconfig to include driver. Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
OpenPOWER on IntegriCloud