aboutsummaryrefslogtreecommitdiff
path: root/Documentation
AgeCommit message (Collapse)Author
2008-08-01Merge branch 'reg-for-linus' of ↵Linus Torvalds
git://git.kernel.org/pub/scm/linux/kernel/git/lrg/voltage-2.6 * 'reg-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/lrg/voltage-2.6: regulator: TI bq24022 Li-Ion Charger driver regulator: maintainers - add maintainers for regulator framework. regulator: documentation - ABI regulator: documentation - machine regulator: documentation - regulator driver regulator: documentation - consumer interface regulator: documentation - overview regulator: core kbuild files regulator: regulator test harness regulator: add support for fixed regulators. regulator: regulator framework core regulator: fixed regulator interface regulator: machine driver interface regulator: regulator driver interface regulator: consumer device interface
2008-08-01Merge git://git.infradead.org/battery-2.6Linus Torvalds
* git://git.infradead.org/battery-2.6: power_supply: Sharp SL-6000 (tosa) batteries support power_supply: fix up CHARGE_COUNTER output to be more precise power_supply: add CHARGE_COUNTER property and olpc_battery support for it power_supply: bump EC version check that we refuse to run with in olpc_battery power_supply: cleanup of the OLPC battery driver power_supply: add eeprom dump file to olpc_battery's sysfs power_supply: Support serial number in olpc_battery
2008-07-30Merge branch 'merge' of ↵Linus Torvalds
git://git.kernel.org/pub/scm/linux/kernel/git/benh/powerpc * 'merge' of git://git.kernel.org/pub/scm/linux/kernel/git/benh/powerpc: powerpc/mm: Lockless get_user_pages_fast() for 64-bit (v3) powerpc: Don't use the wrong thread_struct for ptrace get/set VSX regs powerpc: Fix ptrace buffer size for VSX powerpc: Correctly hookup PTRACE_GET/SETVSRREGS for 32 bit processes ide/powermac: Fix use of uninitialized pointer on media-bay powerpc: Allow non-hcall return values for lparcfg writes ipmi/powerpc: Use linux/of_{device,platform}.h instead of asm powerpc/fsl: proliferate simple-bus compatibility to soc nodes Documentation: remove old sbc8260 board specific information cpm2: Rework baud rate generators configuration to support external clocks. powerpc: rtc_cmos_setup: assign interrupts only if there is i8259 PIC cpm_uart: Add generic clock API support to set baudrates cpm_uart: Modem control lines support powerpc: implement GPIO LIB API on CPM1 Freescale SoC. cpm2: Implement GPIO LIB API on CPM2 Freescale SoC. powerpc: Fix 8xx build failure powerpc: clean up the Book-E HW watchpoint support
2008-07-30regulator: documentation - ABILiam Girdwood
This adds documentation describing the sysfs ABI used by the regulator framework. Signed-off-by: Liam Girdwood <lg@opensource.wolfsonmicro.com>
2008-07-30regulator: documentation - machineLiam Girdwood
This adds documenation describing the regulator machine interface. Signed-off-by: Liam Girdwood <lg@opensource.wolfsonmicro.com>
2008-07-30regulator: documentation - regulator driverLiam Girdwood
This adds documentation describing the regulator driver interface. Signed-off-by: Liam Girdwood <lg@opensource.wolfsonmicro.com>
2008-07-30regulator: documentation - consumer interfaceLiam Girdwood
This adds documentation describing the consumer device interface. Signed-off-by: Liam Girdwood <lg@opensource.wolfsonmicro.com>
2008-07-30regulator: documentation - overviewLiam Girdwood
This adds overview documentation describing the regulator framework and nomenclature used in the interface specific documentation and code. Signed-off-by: Liam Girdwood <lg@opensource.wolfsonmicro.com>
2008-07-29Merge branch 'master' of ↵David S. Miller
git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless-2.6
2008-07-30Merge commit 'kumar/kumar-next'Benjamin Herrenschmidt
2008-07-30Merge branch 'master' of /home/cbou/linux-2.6Anton Vorontsov
Conflicts: drivers/power/Kconfig drivers/power/Makefile
2008-07-29rfkill: document rfkill_force_state as required (v2)Henrique de Moraes Holschuh
While the rfkill class does work with just get_state(), it doesn't work well on devices that are subject to external events that cause rfkill state changes. Document that rfkill_force_state() is required in those cases. Signed-off-by: Henrique de Moraes Holschuh <hmh@hmh.eng.br> Acked-by: Ivo van Doorn <IvDoorn@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2008-07-28Merge git://git.kernel.org/pub/scm/linux/kernel/git/rusty/linux-2.6-for-linusLinus Torvalds
* git://git.kernel.org/pub/scm/linux/kernel/git/rusty/linux-2.6-for-linus: lguest: turn Waker into a thread, not a process lguest: Enlarge virtio rings lguest: Use GSO/IFF_VNET_HDR extensions on tun/tap lguest: Remove 'network: no dma buffer!' warning lguest: Adaptive timeout lguest: Tell Guest net not to notify us on every packet xmit lguest: net block unneeded receive queue update notifications lguest: wrap last_avail accesses. lguest: use cpu capability accessors lguest: virtio-rng support lguest: Support assigning a MAC address lguest: Don't leak /dev/zero fd lguest: fix verbose printing of device features. lguest: fix switcher_page leak on unload lguest: Guest int3 fix lguest: set max_pfn_mapped, growl loudly at Yinghai Lu
2008-07-29lguest: turn Waker into a thread, not a processRusty Russell
lguest uses a Waker process to break it out of the kernel (ie. actually running the guest) when file descriptor needs attention. Changing this from a process to a thread somewhat simplifies things: it can directly access the fd_set of things to watch. More importantly, it means that the Waker can see Guest memory correctly, so /dev/vring file descriptors will work as anticipated (the alternative is to actually mmap MAP_SHARED, but you can't do that with /dev/zero). Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
2008-07-29lguest: Enlarge virtio ringsRusty Russell
With big packets, 128 entries is a little small. Guest -> Host 1GB TCP: Before: 8.43625 seconds xmit 95640 recv 198266 timeout 49771 usec 1252 After: 8.01099 seconds xmit 49200 recv 102263 timeout 26014 usec 2118 Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
2008-07-29lguest: Use GSO/IFF_VNET_HDR extensions on tun/tapRusty Russell
Guest -> Host 1GB TCP: Before 20.1974 seconds xmit 214510 recv 5 timeout 214491 usec 278 After 8.43625 seconds xmit 95640 recv 198266 timeout 49771 usec 1252 Host -> Guest 1GB TCP: Before: Seconds 9.98854 xmit 172166 recv 5344 timeout 172157 usec 251 After: Seconds 5.72803 xmit 244322 recv 9919 timeout 244302 usec 156 Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
2008-07-29lguest: Remove 'network: no dma buffer!' warningRusty Russell
This warning can happen a lot under load, and it should be warnx not warn anwyay. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
2008-07-29lguest: Adaptive timeoutRusty Russell
Since the correct timeout value varies, use a heuristic which adjusts the timeout depending on how many packets we've seen. This gives slightly worse results, but doesn't need tweaking when GSO is introduced. 500 usec 19.1887 xmit 561141 recv 1 timeout 559657 Dynamic (278) 20.1974 xmit 214510 recv 5 timeout 214491 usec 278 Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
2008-07-29lguest: Tell Guest net not to notify us on every packet xmitRusty Russell
virtio_ring has the ability to suppress notifications. This prevents a guest exit for every packet, but we need to set a timer on packet receipt to re-check if there were any remaining packets. Here are the times for 1G TCP Guest->Host with different timeout settings (it matters because the TCP window doesn't grow big enough to fill the entire buffer): Timeout value Seconds Xmit/Recv/Timeout None (before) 25.3784 xmit 7750233 recv 1 2500 usec 62.5119 xmit 207020 recv 2 timeout 207020 1000 usec 34.5379 xmit 207003 recv 2 timeout 207003 750 usec 29.2305 xmit 207002 recv 1 timeout 207002 500 usec 19.1887 xmit 561141 recv 1 timeout 559657 250 usec 20.0465 xmit 214128 recv 2 timeout 214110 100 usec 19.2583 xmit 561621 recv 1 timeout 560153 (Note that these values are sensitive to the GSO patches which come later, and probably other traffic-related variables, so take with a large grain of salt). Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
2008-07-29lguest: net block unneeded receive queue update notificationsRusty Russell
Number of exits transmitting 10GB Guest->Host before: network xmit 7858610 recv 118136 After: network xmit 7750233 recv 1 Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
2008-07-29lguest: wrap last_avail accesses.Rusty Russell
To simplify the transition to when we publish indices in the ring (and make shuffling my patch queue easier), wrap them in a lg_last_avail() macro. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
2008-07-29lguest: virtio-rng supportRusty Russell
This is a simple patch to add support for the virtio "hardware random generator" to lguest. It gets about 1.2 MB/sec reading from /dev/hwrng in the guest. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
2008-07-29lguest: Support assigning a MAC addressMark McLoughlin
If you've got a nice DHCP configuration which maps MAC addresses to specific IP addresses, then you're going to want to start your guest with one of those MAC addresses. Also, in Fedora, we have persistent network interface naming based on the MAC address, so with randomly assigned addresses you're soon going to hit eth13. Who knows what will happen then! Allow assigning a MAC address to the network interface with e.g. --tunnet=bridge:eth0:00:FF:95:6B:DA:3D or: --tunnet=192.168.121.1:00:FF:95:6B:DA:3D which is pretty unintelligable, but ... (includes Rusty's minor rework) Signed-off-by: Mark McLoughlin <markmc@redhat.com> Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
2008-07-29lguest: Don't leak /dev/zero fdMark McLoughlin
Signed-off-by: Mark McLoughlin <markmc@redhat.com> Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
2008-07-29lguest: fix verbose printing of device features.Rusty Russell
%02x is more appropriate for bytes than %08x. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
2008-07-28kdump: update kdump documentation as kexec-tools-resting has been renamed ↵Simon Horman
kexec-tools Signed-off-by: Simon Horman <horms@verge.net.au> Acked-by: Vivek Goyal <vgoyal@redhat.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-07-28Documentation: remove old sbc8260 board specific informationPaul Gortmaker
This file contains 8 yr. old board specific information that was for the now gone ppc implementation, and it pre-dates widespread u-boot support. Any of the technical details of the board memory map would be more appropriately captured in a dts if I revive it as powerpc anyway. Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com> Acked-by: Jason Wessel <jason.wessel@windriver.com> Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
2008-07-28Merge git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/v4l-dvbLinus Torvalds
* git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/v4l-dvb: (98 commits) V4L/DVB (8549): mxl5007: Fix an error at include file V4L/DVB (8548): pwc: Fix compilation V4L/DVB (8546): add tuner-3036 and dpc7146 drivers to feature-removal-schedule.txt V4L/DVB (8546): saa7146: fix read from uninitialized memory V4L/DVB (8544): gspca: probe/open race. V4L/DVB (8543): em28xx: Rename #define for Compro VideoMate ForYou/Stereo V4L/DVB (8542): em28xx: AMD ATI TV Wonder HD 600 entry at cards struct is duplicated V4L/DVB (8541): em28xx: HVR-950 entry is duplicated. V4L/DVB (8540): em28xx-cards: Add Compro VideoMate ForYou/Stereo model V4L/DVB (8539): em28xx-cards: New supported IDs for analog models V4L/DVB (8538): em28xx-cards: Add GrabBeeX+ USB2800 model V4L/DVB (8534): remove select's of FW_LOADER V4L/DVB (8522): videodev2: Fix merge conflict V4L/DVB (8532): mxl5007t: remove excessive locks V4L/DVB (8531): mxl5007t: move i2c gate handling outside of mutex protected code blocks V4L/DVB (8530): au0828: add support for new revision of HVR950Q V4L/DVB (8529): mxl5007t: enable _init and _sleep power management functionality V4L/DVB (8528): add support for MaxLinear MxL5007T silicon tuner V4L/DVB (8526): saa7146: fix VIDIOC_ENUM_FMT V4L/DVB (8525): fix a few assorted spelling mistakes. ...
2008-07-28SubmittingPatches: add git pull & diffstat format infoRandy Dunlap
Add git pull command info and diffstat summary info so that we don't have to search email archives for it repeatedly. Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-07-28cpm_uart: Modem control lines supportLaurent Pinchart
This patch replaces the get_mctrl/set_mctrl stubs with modem control line read/write access through the GPIO lib. Available modem control lines are described in the device tree using GPIO bindings. The driver expect a GPIO pin for each of the CTS, RTS, DCD, DSR, DTR and RI signals. Unused control lines can be left out. Signed-off-by: Laurent Pinchart <laurentp@cse-semaphore.com> Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
2008-07-28i2c: Documentation: upgrading clients HOWTOBen Dooks
Add a document describing how i2c clients on Linux 2.6 can be moved from the old to the new driver model. Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2008-07-27Merge ../linux-2.6Mauro Carvalho Chehab
2008-07-27Merge master.kernel.org:/home/rmk/linux-2.6-armLinus Torvalds
* master.kernel.org:/home/rmk/linux-2.6-arm: [ARM] Fix shared mmap when more than two maps of the same file exist [ARM] fix VIPT/VIVT macro optimisations, add comments [ARM] 5179/1: Replace obsolete IRQT_* and __IRQT_* values with IRQ_TYPE_* [ARM] update defconfig for eseries. [ARM] PXA: squash warning in pxafb [ARM] pxa: PXA25x UDC - Fix warning during build [ARM] fix nwflash.c: 6ee8928d94841aa764aeaf645ad16daff811dc26 [ARM] fix IOP32x, IOP33x, MXC and Samsung builds [ARM] pci: provide dummy pci_get_legacy_ide_irq() [ARM] fix fls() for 64-bit arguments [ARM] fix mode for board-yl-9200.c [ARM] 5176/1: arm/Makefile: fix: ARM946T -> ARM946E
2008-07-27V4L/DVB (8546): add tuner-3036 and dpc7146 drivers to ↵Hans Verkuil
feature-removal-schedule.txt Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2008-07-27Merge ../linux-2.6Mauro Carvalho Chehab
2008-07-27V4L/DVB (8541): em28xx: HVR-950 entry is duplicated.Mauro Carvalho Chehab
Thanks to "Devin Heitmueller" <devin.heitmueller@gmail.com> for pointing this issue. Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2008-07-27V4L/DVB (8540): em28xx-cards: Add Compro VideoMate ForYou/Stereo modelVitaly Wool
Added Compro VideoMate ForYou/Stereo model (analog only) Signed-off-by: Vitaly Wool <vital@embeddedalley.com> [dougsland@gmail.com: Solved conflicts with v4l-dvb devel tree] Signed-off-by: Douglas Schilling Landgraf <dougsland@gmail.com> [mchehab@infradead.org: Need to fix some merge conflicts] Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2008-07-27V4L/DVB (8539): em28xx-cards: New supported IDs for analog modelsDouglas Schilling Landgraf
- New supported IDs for analog models (Based on Markus Rechberger <mrechberger@gmail.com> version of em28xx driver) - Validation field for new em28xx boards. Signed-off-by: Douglas Schilling Landgraf <dougsland@gmail.com> [mchehab@infradead.org: Need to fix some merge conflicts] Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2008-07-27V4L/DVB (8538): em28xx-cards: Add GrabBeeX+ USB2800 modelAron Szabo
Added GrabBeeX+ USB2800 model (analog only) [mchehab@infradead.org: Need to fix some merge conflicts] Signed-off-by: Aron Szabo <aron@aron.ws> Signed-off-by: Douglas Schilling Landgraf <dougsland@gmail.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2008-07-27Merge git://git.kernel.org/pub/scm/linux/kernel/git/sam/kbuild-nextLinus Torvalds
* git://git.kernel.org/pub/scm/linux/kernel/git/sam/kbuild-next: (25 commits) setlocalversion: do not describe if there is nothing to describe kconfig: fix typos: "Suport" -> "Support" kconfig: make defconfig is no longer chatty kconfig: make oldconfig is now less chatty kconfig: speed up all*config + randconfig kconfig: set all new symbols automatically kconfig: add diffconfig utility kbuild: remove Module.markers during mrproper kbuild: sparse needs CF not CHECKFLAGS kernel-doc: handle/strip __init vmlinux.lds: move __attribute__((__cold__)) functions back into final .text section init: fix URL of "The GNU Accounting Utilities" kbuild: add arch/$ARCH/include to search path kbuild: asm symlink support for arch/$ARCH/include kbuild: support arch/$ARCH/include for tags, cscope kbuild: prepare headers_* for arch/$ARCH/include kbuild: install all headers when arch is changed kbuild: make clean removes *.o.* as well kbuild: optimize headers_* targets kbuild: only one call for include/ in make headers_* ...
2008-07-27Merge branch 'for-linus' of ↵Linus Torvalds
git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound-2.6 * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound-2.6: ALSA: Allow to force model to intel-mac-v3 in snd_hda_intel (sigmatel). ALSA: cs4232: fix crash during chip PNP detection ALSA: hda - Add automatic model setting for the Acer Aspire 5920G laptop ALSA: make snd_ac97_add_vmaster() static ALSA: sound/pci/azt3328.h: no variables for enums ALSA: soc - wm9712 mono mixer ALSA: hda - Add support of ASUS Eeepc P90* ALSA: opti9xx: no isapnp param for !CONFIG_PNP ALSA: opti93x - Fix NULL dereference ALSA: hda - Added support for Asus V1Sn ALSA: ASoC: Factor PGA DAPM handling into main ALSA: ASoC: Refactor DAPM event handler ALSA: ALSA: ens1370: communicate PCI device to AC97 ALSA: ens1370: SRC stands for Sample Rate Converter ALSA: hda - Align BDL position adjustment parameter ALSA: Au1xpsc: psc not disabled when TX is idle ALSA: add TriTech 28023 AC97 codec ID and Wolfson 9701 name.
2008-07-27Merge ../linux-2.6Mauro Carvalho Chehab
2008-07-27V4L/DVB (8530): au0828: add support for new revision of HVR950QMichael Krufky
Signed-off-by: Michael Krufky <mkrufky@linuxtv.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
2008-07-27[ARM] 5179/1: Replace obsolete IRQT_* and __IRQT_* values with IRQ_TYPE_*Dmitry Baryshkov
IRQT_* and __IRQT_* were obsoleted long ago by patch [3692/1]. Remove them completely. Sed script for the reference: s/__IRQT_RISEDGE/IRQ_TYPE_EDGE_RISING/g s/__IRQT_FALEDGE/IRQ_TYPE_EDGE_FALLING/g s/__IRQT_LOWLVL/IRQ_TYPE_LEVEL_LOW/g s/__IRQT_HIGHLVL/IRQ_TYPE_LEVEL_HIGH/g s/IRQT_RISING/IRQ_TYPE_EDGE_RISING/g s/IRQT_FALLING/IRQ_TYPE_EDGE_FALLING/g s/IRQT_BOTHEDGE/IRQ_TYPE_EDGE_BOTH/g s/IRQT_LOW/IRQ_TYPE_LEVEL_LOW/g s/IRQT_HIGH/IRQ_TYPE_LEVEL_HIGH/g s/IRQT_PROBE/IRQ_TYPE_PROBE/g s/IRQT_NOEDGE/IRQ_TYPE_NONE/g Signed-off-by: Dmitry Baryshkov <dbaryshkov@gmail.com> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-27ALSA: Allow to force model to intel-mac-v3 in snd_hda_intel (sigmatel).Nicolas Boichat
Currently, even if you pass model=intel-mac-v3 as a module parameter to snd_hda_intel, the function patch_stac922x (patch_sigmatel.c) will still try to auto-detect the model type. This is a problem on my MacBook Pro 1st generation, which needs intel-mac-v3, but sometimes incorrectly reports 0x00000100 as subsystem id, which causes the switch in patch_stac922x to select intel-mac-v4. To fix this, I added a new model called intel-mac-auto, so in case no module parameter is passed, and an Intel Mac board is detected, the model will be automatically detected, while no detection will be done if the model is forced to intel-mac-v3. This problem has been around for quite a while, and I used to fix it by moving the case statement for 0x00000100 in patch_stac922x so that intel-mac-v3 is chosen. Another way to fix the problem would be to check if a module parameter was set directly in patch_stac922x, using something like this: if (spec->board_config == STAC_INTEL_MAC_V3 && !codec->bus->modelname) { But I think it is less elegant (if you prefer that way, I can prepare a patch). Signed-off-by: Nicolas Boichat <nicolas@boichat.ch> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2008-07-27Add mISDN driverKarsten Keil
mISDN is a new modular ISDN driver, in the long term it should replace the old I4L driver architecture for passiv ISDN cards. Signed-off-by: Karsten Keil <kkeil@suse.de>
2008-07-26Documentation cleanup: trivial misspelling, punctuation, and grammar ↵Matt LaPlante
corrections. Cc: Randy Dunlap <randy.dunlap@oracle.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-07-26omfs: add filesystem documentationBob Copeland
These patches add the Optimized MPEG Filesystem, a proprietary filesystem used by the embedded devices Rio Karma and ReplayTV, which are no longer manufactured. This filesystem module enables people to access files on these devices. This patch: OMFS is a proprietary filesystem created for the ReplayTV and also used by the Rio Karma. It uses hash tables with unordered, unbounded lists in each bucket for directories, extents for data blocks, 64-bit addressing for blocks, with up to 8K blocks (only 2K of a given block is ever used for metadata, so the FS still works with 4K pages). Document the filesystem usage and structures. Signed-off-by: Bob Copeland <me@bobcopeland.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-07-26relay: add buffer-only channels; useful for early loggingEduard - Gabriel Munteanu
Allows one to create and use a channel with no associated files. Files can be initialized later. This is useful in scenarios such as logging in early code, before VFS is up. Therefore, such channels can be created and used as soon as kmem_cache_init() completed. This is needed by kmemtrace to do tracing in early kernel code. [kosaki.motohiro@jp.fujitsu.com: build fix] Signed-off-by: Eduard - Gabriel Munteanu <eduard.munteanu@linux360.ro> Cc: Tom Zanussi <tzanussi@gmail.com> Signed-off-by: KOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-07-26dma-mapping: add the device argument to dma_mapping_error()FUJITA Tomonori
Add per-device dma_mapping_ops support for CONFIG_X86_64 as POWER architecture does: This enables us to cleanly fix the Calgary IOMMU issue that some devices are not behind the IOMMU (http://lkml.org/lkml/2008/5/8/423). I think that per-device dma_mapping_ops support would be also helpful for KVM people to support PCI passthrough but Andi thinks that this makes it difficult to support the PCI passthrough (see the above thread). So I CC'ed this to KVM camp. Comments are appreciated. A pointer to dma_mapping_ops to struct dev_archdata is added. If the pointer is non NULL, DMA operations in asm/dma-mapping.h use it. If it's NULL, the system-wide dma_ops pointer is used as before. If it's useful for KVM people, I plan to implement a mechanism to register a hook called when a new pci (or dma capable) device is created (it works with hot plugging). It enables IOMMUs to set up an appropriate dma_mapping_ops per device. The major obstacle is that dma_mapping_error doesn't take a pointer to the device unlike other DMA operations. So x86 can't have dma_mapping_ops per device. Note all the POWER IOMMUs use the same dma_mapping_error function so this is not a problem for POWER but x86 IOMMUs use different dma_mapping_error functions. The first patch adds the device argument to dma_mapping_error. The patch is trivial but large since it touches lots of drivers and dma-mapping.h in all the architecture. This patch: dma_mapping_error() doesn't take a pointer to the device unlike other DMA operations. So we can't have dma_mapping_ops per device. Note that POWER already has dma_mapping_ops per device but all the POWER IOMMUs use the same dma_mapping_error function. x86 IOMMUs use device argument. [akpm@linux-foundation.org: fix sge] [akpm@linux-foundation.org: fix svc_rdma] [akpm@linux-foundation.org: build fix] [akpm@linux-foundation.org: fix bnx2x] [akpm@linux-foundation.org: fix s2io] [akpm@linux-foundation.org: fix pasemi_mac] [akpm@linux-foundation.org: fix sdhci] [akpm@linux-foundation.org: build fix] [akpm@linux-foundation.org: fix sparc] [akpm@linux-foundation.org: fix ibmvscsi] Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp> Cc: Muli Ben-Yehuda <muli@il.ibm.com> Cc: Andi Kleen <andi@firstfloor.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Ingo Molnar <mingo@elte.hu> Cc: Avi Kivity <avi@qumranet.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>