GIT 1cb92bbde588c065e24db31fe28f7ba7b47dfa2c git+ssh://master.kernel.org/pub/scm/linux/kernel/git/sfr/linux-next.git commit 1cb92bbde588c065e24db31fe28f7ba7b47dfa2c Author: Stephen Rothwell Date: Thu Sep 4 19:19:21 2008 +1000 Add linux-next specific files for 20080904 Signed-off-by: Stephen Rothwell commit 2501b7fbce39bbb207c4625b22f6069158f6ea8f Author: Stephen Rothwell Date: Tue Sep 2 14:18:47 2008 +1000 powerpc: make sure all kernel test is before _etext This makes core_kernel_text() (and therefore kernel_text_address()) return the correct result. Currently all the __devinit routines (at least) will not be considered to be kernel text. This is just a quick fix for 2.6.27 - hopefully we will be able to fix this better in 2.6.28. Signed-off-by: Stephen Rothwell commit 83d3bf139e6bc6e3def633401452d73993888024 Author: Stephen Rothwell Date: Mon Sep 1 18:56:52 2008 +1000 sparc: qlogicpti fallout from sbus removal Signed-off-by: Stephen Rothwell commit 58caab2963b5bac08e1e38994df7746dab1458d1 Author: Arjan van de Ven Date: Tue Aug 26 09:01:06 2008 -0700 debug: add notifier chain debugging during some development we suspected a case where we left something in a notifier chain that was from a module that was unloaded already... and that sort of thing is rather hard to track down. This patch adds a very simple sanity check (which isn't all that expensive) to make sure the notifier we're about to call is actually from either the kernel itself of from a still-loaded module, avoiding a hard-to-chase-down crash. Signed-off-by: Arjan van de Ven Acked-by: Tony Luck commit 201c2cdc0138dc5bef9bc5fce3dba385d3b28e9e Author: Stephen Rothwell Date: Thu Sep 4 17:52:58 2008 +1000 Revert "debug: add notifier chain debugging" This reverts commit 16f9b13de93c8bfdac16b4d15577af2c132358ef. commit 81fa1e78512e0994358c28db6038872a03f98df4 Author: Stephen Rothwell Date: Mon Aug 25 20:28:31 2008 +1000 ftrace: protect the definition of ftrace_release Signed-off-by: Stephen Rothwell commit 27c382e94672b42c8fe00a9421e67e13c301071a Author: Stephen Rothwell Date: Mon Aug 25 21:16:14 2008 +1000 revert BUILD_BUG_ON change Signed-off-by: Stephen Rothwell commit 0f6dc77dd57b6cbefbb7c036bd76452dcb0e55e6 Author: Stephen Rothwell Date: Thu Sep 4 17:44:51 2008 +1000 Revert "Merge branch 'quilt/ttydev'" This reverts commit 9ece80214deb25f39a5015c160f53191817cd990. Conflicts: kernel/fork.c commit 9b90dc7bc3079376567fc501e2e84751fa4040fd Author: Stephen Rothwell Date: Wed Aug 27 14:45:37 2008 +1000 rr: build fix for remove CONFIG_KMOD from net Signed-off-by: Stephen Rothwell commit 373a99012d69770d315e8e192e8443a6d0290552 Author: Stephen Rothwell Date: Mon Aug 25 14:49:42 2008 +1000 HID: fix for warn() removal Signed-off-by: Stephen Rothwell commit c4089f592bfc41c0898298881b7bfb762943628d Author: Steven Rostedt Date: Wed Aug 27 13:02:01 2008 -0400 ftrace: remove warning of old objcopy and local functions The warning messages about old objcopy and local functions spam the user quite drastically. Remove the warning until we can find a nicer way of tell the user to upgrade their objcopy. Signed-off-by: Steven Rostedt commit 636b0311ed5e53de7a84bec7c90612fb3e270ecc Author: Stephen Rothwell Date: Thu Sep 4 10:50:50 2008 +1000 Revert "Blacklist DMAR on Intel G31/G33 chipsets" This reverts commit 1bc3029e516e62baa14318888985075f3f3a9f7e. commit d5efbf66f55351e87355c24015e07d9b3a049ed9 Author: Mikulas Patocka Date: Thu Sep 4 09:40:21 2008 +1000 dm-exception-store-use-chunk_t-for_areas Change uint32_t into chunk_t to remove 32-bit limitation on the number of chunks on systems with 64-bit sector numbers. Signed-off-by: Mikulas Patocka Signed-off-by: Alasdair G Kergon commit 65c40d01a11a91bc9b70c15e91d71729d02a6909 Author: Mikulas Patocka Date: Thu Sep 4 09:40:21 2008 +1000 dm-exception-store-introduce-area_location-function Move this logic to a function, because it will be reused later. Signed-off-by: Mikulas Patocka Signed-off-by: Alasdair G Kergon commit 9cc1a8b9c8dbb4f0b8054ccc487f1005d937456d Author: Jonathan Brassow Date: Thu Sep 4 09:40:21 2008 +1000 dm-raid1-kcopyd-should-stop-on-error-if-errors-handled dm-raid1 is setting the 'DM_KCOPYD_IGNORE_ERROR' flag unconditionally when assigning kcopyd work. kcopyd is responsible for copying an assigned section of disk to one or more other disks. The 'DM_KCOPYD_IGNORE_ERROR' flag affects kcopyd in the following way: When not set: kcopyd will immediately stop the copy operation when an error is encountered. When set: kcopyd will try to proceed regardless of errors and try to continue copying any remaining amount. Since dm-raid1 tracks regions of the address space that are (or are not) in sync and it now has the ability to handle these errors, we can safely enable this optimization. This optimization is conditional on whether mirror error handling has been enabled. Signed-off-by: Jonathan Brassow Signed-off-by: Alasdair G Kergon commit 83354f66558cffb3d77d21a81b96e09a0df904f6 Author: Kiyoshi Ueda Date: Thu Sep 4 09:40:20 2008 +1000 dm-mpath-remove-is_active-from-struct-dm_path This patch moves 'is_active' from struct dm_path to struct pgpath as it does not need exporting. Signed-off-by: Kiyoshi Ueda Signed-off-by: Jun'ichi Nomura Signed-off-by: Alasdair G Kergon commit 0fa1eba8755f8f75ba953fdf4d186a94217aa597 Author: Benjamin Marzinski Date: Thu Sep 4 09:40:20 2008 +1000 dm-mpath-use-more-error-codes This patch allows path errors from the multipath ctr function to propagate up to userspace as errno values from the ioctl() call. This is in response to https://www.redhat.com/archives/dm-devel/2008-May/msg00000.html and https://bugzilla.redhat.com/show_bug.cgi?id=444421 The patch only lets through the errors that it needs to in order to get the path errors from parse_path(). Signed-off-by: Benjamin Marzinski Signed-off-by: Alasdair G Kergon commit de79317ef660067fa2dbc1844cb16b8eaa8fd2dd Author: Greg Kroah-Hartman Date: Tue Apr 9 12:14:34 2002 -0700 USB: driver for gotemp device NOT FOR MAINLINE! This is for the driver tutorial I give. It will not be included in the mainline kernel tree ever. Use the ldusb driver that is already there instead for this device. This is only a teaching tool. commit 9c20630d5d41df97c9447c8f95e5379ba3192a83 Author: Greg Kroah-Hartman Date: Wed Aug 20 16:56:34 2008 -0700 USB: remove use of err() in drivers/usb/serial err() is going away, so switch to dev_err() or printk() if it's really needed. Signed-off-by: Greg Kroah-Hartman commit bb7a79c2d49aa8d2cca258c6a013f06bb9d697f3 Author: Greg Kroah-Hartman Date: Mon Aug 18 13:21:04 2008 -0700 USB: remove info() macro from usb.h USB should not be having it's own printk macros, so remove info() and use the system-wide standard of dev_info() wherever possible. In the few places that will not work out, use a basic printk(). Signed-off-by: Greg Kroah-Hartman commit 9e134d972bca51b3718a7a04041f11c766b98db7 Author: Greg Kroah-Hartman Date: Thu Aug 14 09:37:34 2008 -0700 USB: remove warn() macro from usb.h USB should not be having it's own printk macros, so remove warn() and use the system-wide standard of dev_warn() wherever possible. In the few places that will not work out, use a basic printk(). Signed-off-by: Greg Kroah-Hartman commit 8dd9da42f58949ebdec5ad6d14c416223e4609ed Author: Denis Joseph Barrow Date: Wed Aug 20 17:04:52 2008 +0200 HSO: put linefeeds on printk's in hso.c Just putting linefeeds on dev_warn & dev_err Signed-off-by: Denis Joseph Barrow Signed-off-by: Greg Kroah-Hartman commit a460e386c2c5932887b2158e08a04581b6a0b448 Author: Denis Joseph Barrow Date: Wed Aug 20 16:34:01 2008 +0200 HSO: fix hso_serial_close refcounting The hso: fix refcounting on the ttyHSx devices signed off by Olivier Blin was better than what was there but not completely correct. The kref_put has to be moved below the mutex_unlock otherwise the memory used by the mutex could be freed before it is used. Signed-off-by: Denis Joseph Barrow Cc: Olivier Blin Signed-off-by: Greg Kroah-Hartman commit e7e36273ea67c2e9c78da0281b45769e0ffb3fe2 Author: Will Newton Date: Tue Aug 12 15:39:17 2008 +0100 fsl_usb2_udc: Fix oops on probe failure. In some circumstances when fsl_udc_probe fails udc_controller is freed but the pointer remains non-NULL. fsl_udc_remove will then try and teardown the partly initialized and freed controller structure resulting in an oops. This patch ensures udc_controller is either NULL or fully initialized after fsl_udc_probe. Signed-off-by: Will Newton Acked-by: Li Yang Signed-off-by: Greg Kroah-Hartman commit 8340e10e45caaf82a5bbb6458ae9743f0d1ce8b5 Author: Will Newton Date: Tue Aug 12 15:39:16 2008 +0100 fsl_usb2_udc: Add a wmb before priming endpoint. Add a wmb to fsl_queue_td before priming the endpoint. This ensures that the modifications to the QH are seen by the hardware. Added comment as suggested by Felipe Balbi. Signed-off-by: Will Newton Acked-by: Li Yang Signed-off-by: Greg Kroah-Hartman commit ce6733542ff0688308f8301ec1dc7de58768fe67 Author: Will Newton Date: Tue Aug 12 15:39:15 2008 +0100 fsl_usb2_udc: Make fsl_queue_td return type void. fsl_queue_td always returns 0. Make it void and remove checks for non-zero return in callers. Signed-off-by: Will Newton Acked-by: Li Yang Signed-off-by: Greg Kroah-Hartman commit 6826be94eb08c691dbd6c80b513b572e6031abb7 Author: Will Newton Date: Tue Aug 12 15:39:14 2008 +0100 fsl_usb2_udc: Uninline udc_reset_ep_queue. Uninline udc_reset_ep_queue and remove it's unused return value. Signed-off-by: Will Newton Acked-by: Li Yang Signed-off-by: Greg Kroah-Hartman commit fad5f0dd1c118d2fe6a8439626a1ce7519b494f6 Author: Will Newton Date: Tue Aug 12 15:39:13 2008 +0100 fsl_usb2_udc: Rename the arguments of the fsl_writel macro. Rename the arguments of the fsl_writel macro to match their use. Remove a couple of unnecessary prototypes. Signed-off-by: Will Newton Acked-by: Li Yang Signed-off-by: Greg Kroah-Hartman commit 08655b8ffc0120cee7b4abcd8f556a22f8fc17ee Author: Will Newton Date: Tue Aug 12 15:39:12 2008 +0100 fsl_usb2_udc: Initialize spinlock earlier. Move spinlock initialization earlier so we can turn shared irq handler debugging on safely. Signed-off-by: Will Newton Acked-by: Li Yang Signed-off-by: Greg Kroah-Hartman commit f3b64a3ead8e3a537bd54cb356530ef9068912bd Author: Will Newton Date: Tue Aug 12 15:39:11 2008 +0100 fsl_usb2_udc: Clean up whitespace in /proc debugging output. Missing spaces were causing the /proc debugging output to be rather unreadable. Signed-off-by: Will Newton Acked-by: Li Yang Signed-off-by: Greg Kroah-Hartman commit a50cf6395848bcb0dd50a082be51d035727a51cb Author: Will Newton Date: Tue Aug 12 15:39:10 2008 +0100 fsl_usb2_udc: Clean up whitespace in errors and warnings. VDBG always outputs a trailing \n. Signed-off-by: Will Newton Acked-by: Li Yang Signed-off-by: Greg Kroah-Hartman commit ae59a6097b0a13582d40c4269e1f2ee9b68d226b Author: Will Newton Date: Tue Aug 12 15:39:09 2008 +0100 fsl_usb2_udc: Fix some sparse warnings and remove redundant code. Fix some sparse "integer used as NULL pointer" warnings. Remove some unnecessary volatiles and static initialization. Remove some unused struct members and reorder to improve packing. Remove a few unneeded includes. Signed-off-by: Will Newton Acked-by: Li Yang Signed-off-by: Greg Kroah-Hartman commit dadccd00a65d39b9056d97d84b65672a1d3cbc9d Author: Will Newton Date: Tue Aug 12 15:39:08 2008 +0100 fsl_usb2_udc: Remove check for udc == NULL in dr_controller_setup. Remove check for udc == NULL in dr_controller_setup. All callers of this function have already dereferenced udc at some point. Signed-off-by: Will Newton Acked-by: Li Yang Signed-off-by: Greg Kroah-Hartman commit b635ebb2bdb4c8df9a3f44149fbe378989b2e860 Author: Will Newton Date: Tue Aug 12 15:39:07 2008 +0100 fsl_usb2_udc: Make dr_ep_setup function static. Make dr_ep_setup function static as it's never used outside this file. Signed-off-by: Will Newton Acked-by: Li Yang Signed-off-by: Greg Kroah-Hartman commit 2a85bb73e381beab6712434179d7205a367aab6d Author: David Brownell Date: Mon Aug 18 17:45:25 2008 -0700 usb gadget: defer obex enumeration Some USB peripheral controller drivers support software control over the data pullup. Use those controls to prevent the OBEX function from enumerating until the userspace server has opened the /dev/ttyGS* node it will use to implement protocol chitchat with the USB host. Signed-off-by: David Brownell Signed-off-by: Greg Kroah-Hartman commit 62f5c7ae5c1130bd2873651a8c539964e3e30643 Author: Felipe Balbi Date: Mon Aug 18 17:39:30 2008 -0700 usb gadget: cdc obex glue The following patch introduces a new f_obex.c function driver. It allows userspace obex servers to use usb as transport layer for their messages. [ dbrownell@users.sourceforge.net: various fixes and cleanups ] Signed-off-by: Felipe Balbi Signed-off-by: David Brownell Signed-off-by: Greg Kroah-Hartman commit 43b6a1a728586f1517e17e22b6eafedd9d7096a9 Author: David Brownell Date: Mon Aug 18 17:38:22 2008 -0700 usb gadget: function activation/deactivation Add a new mechanism to the composite gadget framework, letting functions deactivate (and reactivate) themselves. Think of it as a refcounted wrapper for the software pullup control. A key example of why to use this mechanism involves functions that require a userspace daemon. Those functions shuld use this new mechanism to prevent the gadget from enumerating until those daemons are activated. Without this mechanism, hosts would see devices that malfunction until the relevant daemons start. Signed-off-by: David Brownell Signed-off-by: Greg Kroah-Hartman commit 90db96aa3a63047c66049220c10227e1cd9f8ec4 Author: Alan Stern Date: Thu Aug 14 15:49:11 2008 -0400 USB: gadget: net2280: implement set_wedge This patch (as1132) implements the set_wedge() method for net2280. This method is necessary for strict USBCV compliance in g_file_storage. Signed-off-by: Alan Stern CC: David Brownell Signed-off-by: Greg Kroah-Hartman commit e2931c6f2c2ee10a7b1b0684053d4feb901d4b7d Author: Alan Stern Date: Thu Aug 14 15:48:30 2008 -0400 USB: gadget: dummy_hcd: implement set_wedge This patch (as1131) implements the set_wedge() method for dummy_hcd. This method is necessary for strict USBCV compliance in g_file_storage. Signed-off-by: Alan Stern Signed-off-by: Greg Kroah-Hartman commit a2886e68289be97ecef6a239eb0ce825f682f371 Author: David Brownell Date: Thu Aug 14 17:04:48 2008 -0700 usb: gadget Kconfig cleanup This reorders the list of USB peripheral controller drivers so it's more common for the initial (default) value to be relevant: put the SOC integrated silicon up front, discrete stuff last. Alphabetize. Signed-off-by: David Brownell Signed-off-by: Greg Kroah-Hartman commit d07a17b6661dab20db4a68a6fc35ff77d1e8eb26 Author: Marc Zyngier Date: Mon Aug 18 13:08:42 2008 +0200 USB: Let some USB host controllers get IRQ flags from resource [This version fixes a thinko in the r8a66597 driver] This patch let a few discrete USB host controllers drivers (isp116x-hcd, r8a66597-hcd and sl811-hcd) obtain IRQ flags from their IORESOURCE_IRQ resource if configured as such, much like it's been done for the smc91x driver. It spares people writing support for specific boards the burden to configure the interrupt controller independantly, and keeps all IRQ related information in a single resource. HCD that are integrally part of a SoC have been left aside, as there is probably no "wiring" options... Tested on an Xscale PXA-255 based platform with isp116x-hcd. Signed-off-by: Marc Zyngier Cc: David Brownell Signed-off-by: Greg Kroah-Hartman commit b056f62d7d5da7823a79ae90855dcf46c50b66ac Author: Pete Zaitcev Date: Mon Aug 4 17:15:40 2008 -0600 ub: remove sg_stat Remove forgotten code related to sg_stat[]. Signed-off-by: Pete Zaitcev Signed-off-by: Greg Kroah-Hartman commit a1e127a20754903eb4379d492de7c918355a364b Author: Oliver Neukum Date: Tue Jul 29 16:18:47 2008 +0200 USB: extend poisoning to anchors this extends the poisoning concept to anchors. This way poisoning will work with fire and forget drivers. Signed-off-by: Oliver Neukum Signed-off-by: Greg Kroah-Hartman commit 6611b01c7809a78711f00976b178f964a9be7ec9 Author: Oliver Neukum Date: Tue Jul 29 15:26:15 2008 +0200 USB: kill URBs permanently looking at usb_kill_urb() it seems to me that it is unnecessarily lenient. In the use case of disconnect() you never want to use the URB again (for the same device) But leaving urb->reject elevated will make it easier to avoid races between read/write and disconnect. Signed-off-by: Oliver Neukum Signed-off-by: Greg Kroah-Hartman commit 02dba340fa82796f30da3f29eebcc3d49d816b72 Author: Julia Lawall Date: Wed Jul 16 18:00:42 2008 +0200 drivers/usb/class/usblp.c: adjust error handling code In this code, it is possible to tell statically whether usblp will be NULL in the error handling code. Oliver Neukum suggested to make a goto to the final return rather than return directly. The semantic match that finds this problem is as follows: (http://www.emn.fr/x-info/coccinelle/) // @@ identifier f,err,l,l1; type T; expression x,E; statement S; @@ x = NULL ... when != goto l1; * x = f(...) ... when != x err = E; goto l; ... * if (x != NULL) S return err; // Signed-off-by: Julia Lawall Cc: Pete Zaitcev Signed-off-by: Greg Kroah-Hartman commit 961b49bafa56f4eaf3856db75c237b909ef2beb1 Author: Dave Hansen Date: Thu Mar 16 17:30:16 2006 -0800 warn when statically-allocated kobjects are used One of the top ten sysfs problems is that users use statically allocated kobjects. This patch reminds them that this is a naughty thing. One _really_ nice thing this patch does, is us the kallsyms mechanism to print out exactly which symbol is being complained about: The kobject at, or inside 'statickobj.2'@(0xc040d020) is not dynamically allocated. This patch replaces the previous implementation's use of a _sdata symbol in favor of using kallsyms_lookup(). If a kobject's address is a resolvable symbol, then it isn't dynamically allocated. The one exception to this is init symbols. The patch also checks to see whether __init memory has been freed and if it has will allow kobjects in those sections. Signed-off-by: Dave Hansen Signed-off-by: Greg Kroah-Hartman commit 6bd19e6049c8c1f45ab52956c133d87b6d1aabd6 Author: Greg Kroah-Hartman Date: Sun Jan 27 10:29:20 2008 -0800 NET: convert the phy_device file to use bus_find_device_by_name The driver core now has this helper function, so might as well use it instead of forcing the phy code to roll their own version. Signed-off-by: Greg Kroah-Hartman commit 0cdc52f78ed1b70c3aee9908f910e9bee44cdb5c Author: Greg Kroah-Hartman Date: Tue Aug 26 11:00:57 2008 -0500 Driver core: add bus_sort_breadthfirst() function The PCI core wants to reorder the devices in the bus list. So move this functionality out of the pci core and into the driver core so that anyone else can also do this if needed. This also lets us change how struct device is attached to drivers in the future without messing with the PCI core. Cc: Jesse Barnes Signed-off-by: Greg Kroah-Hartman commit 4bdd010d01262706408a25d5667fcf660c2acead Author: Tejun Heo Date: Mon Aug 25 11:06:58 2008 +0200 driver-core: use klist for class device list and implement iterator Iterating over entries using callback usually isn't too fun especially when the entry being iterated over can't be manipulated freely. This patch converts class->p->class_devices to klist and implements class device iterator so that the users can freely build their own control structure. The users are also free to call back into class code without worrying about locking. class_for_each_device() and class_find_device() are converted to use the new iterators, so their users don't have to worry about locking anymore either. Note: This depends on klist-dont-iterate-over-deleted-entries patch because class_intf->add/remove_dev() depends on proper synchronization with device removal. Signed-off-by: Tejun Heo Cc: Jens Axboe Signed-off-by: Greg Kroah-Hartman commit 7b2fe89335c53749aabf1e27657ec0f7b63aa7f3 Author: Tejun Heo Date: Mon Aug 25 17:31:03 2008 +0200 klist: don't iterate over deleted entries A klist entry is kept on the list till all its current iterations are finished; however, a new iteration after deletion also iterates over deleted entries as long as their reference count stays above zero. This causes problems for cases where there are users which iterate over the list while synchronized against list manipulations and natuarally expect already deleted entries to not show up during iteration. This patch implements dead flag which gets set on deletion so that iteration can skip already deleted entries. The dead flag piggy backs on the lowest bit of knode->n_klist and only visible to klist implementation proper. While at it, drop klist_iter->i_head as it's redundant and doesn't offer anything in semantics or performance wise as klist_iter->i_klist is dereferenced on every iteration anyway. Signed-off-by: Tejun Heo Cc: Alan Stern Cc: Jens Axboe Signed-off-by: Greg Kroah-Hartman commit e04ba370700ff5763f9cabca6333127fce460858 Author: Eric W. Biederman Date: Thu Jul 3 18:13:05 2008 -0700 sysfs: sysfs_chmod_file handle multiple superblocks Teach sysfs_chmod_file how to handle multiple sysfs superblocks. Since we only have one inode per sd the only thing we have to deal with is multiple dentries for sending fs notifications. This might dup the inode notifications oh well. Signed-off-by: Eric W. Biederman Acked-by: Tejun Heo Signed-off-by: Greg Kroah-Hartman commit 7c74992bc5f7f413947da99e5eb6c450eb7710b2 Author: Eric W. Biederman Date: Thu Jul 3 18:11:40 2008 -0700 sysfs: Introduce sysfs_sd_setattr and fix sysfs_chmod Currently sysfs_chmod calls sys_setattr which in turn calls inode_change_ok which checks to see if it is ok for the current user space process to change tha attributes. Since sysfs_chmod_file has only kernel mode clients denying them permission if user space is the problem is completely inappropriate. Therefore factor out sysfs_sd_setattr which does not call inode_change_ok and modify sysfs_chmod_file to call it. In addition setting victim_sd->s_mode explicitly in sysfs_chmod_file is redundant so remove that as well. Thanks to Tejun Heo , and Daniel Lezcano for working on this and spotting this case. Signed-off-by: Eric W. Biederman Acked-by: Tejun Heo Signed-off-by: Greg Kroah-Hartman commit 598b856f0561d8c50e83c186e0286d40eeebc6ad Author: Eric W. Biederman Date: Thu Jul 3 18:10:05 2008 -0700 sysfs: Rename Support multiple superblocks This patch modifies the sysfs_rename_dir and sysfs_move_dir routines to support multiple sysfs dentry tries rooted in different sysfs superblocks. Signed-off-by: Eric W. Biederman Signed-off-by: Benjamin Thery Signed-off-by: Daniel Lezcano Acked-by: Tejun Heo Signed-off-by: Greg Kroah-Hartman commit 22e807595b6dce4b1bbce1de59ab0d6c32048c21 Author: Eric W. Biederman Date: Thu Jul 3 18:09:04 2008 -0700 sysfs: Implement __sysfs_get_dentry This function is similar but much simpler to sysfs_get_dentry returns a sysfs dentry if one curently exists. Signed-off-by: Eric W. Biederman Signed-off-by: Benjamin Thery Signed-off-by: Daniel Lezcano Acked-by: Tejun Heo Signed-off-by: Greg Kroah-Hartman commit bc57302ba67f56ac9e6f19778c8ec99efdeeb037 Author: Eric W. Biederman Date: Thu Jul 3 18:08:02 2008 -0700 sysfs: sysfs_get_dentry add a sb parameter In preparation for multiple mounts of sysfs add a superblock parameter to sysfs_get_dentry. Signed-off-by: Eric W. Biederman Signed-off-by: Benjamin Thery Signed-off-by: Daniel Lezcano Acked-by: Tejun Heo Signed-off-by: Greg Kroah-Hartman commit 9f003649d9eec37e16cff261d205c368524fdd6e Author: Eric W. Biederman Date: Thu Jul 3 18:07:04 2008 -0700 sysfs: Support for preventing unmounts. To support mounting multiple instances of sysfs occassionally I need to walk through all of the currently present sysfs super blocks. To allow this iteration this patch adds sysfs_grab_supers and sysfs_release_supers. While a piece of code is in a section surrounded by these no more sysfs super blocks will be either created or destroyed. So the fundamentals. - The data in sysfs fundamentally changes behind the back of the VFS and we need to keep the VFS in sync. Essentially this is the distributed filesystem problem. - In particular for sysfs_rename and sysfs_move_dir we need to support finding the dcache entries and calling d_move. So that the dcache does not get into an inconsistent state. Timeouts and invalidates like NFS uses are to be avoided if at all possible. - Coming through the vfs we are guaranteed that the filesystem will not be unmounted while we have a reference on a dentry, and with multiple mounts we do not get that guarantee. Therefore to get that guarantee for all of the superblocks we need the blunt instrument. - Since mount/unmount are rare blocking them is no big deal. I believe any distributed filesystem that is together enough to tell us about renames (so we can update the dcache) instead of doing the NFS timeout will need the ability to block mount/unmount while it is executing d_move. Currently sysfs does not need to block mounts only because we perform an internal mount and then never unmount sysfs. Signed-off-by: Eric W. Biederman Signed-off-by: Benjamin Thery Signed-off-by: Daniel Lezcano Acked-by: Tejun Heo Signed-off-by: Greg Kroah-Hartman commit 2e9516f00d036f87538bdc855f0ab68023160f4b Author: Eric W. Biederman Date: Thu Jul 3 18:05:28 2008 -0700 kobject: Cleanup kobject_rename and !CONFIG_SYSFS It finally dawned on me what the clean fix to sysfs_rename_dir calling kobject_set_name is. Move the work into kobject_rename where it belongs. The callers serialize us anyway so this is safe. Signed-off-by: Eric W. Biederman Acked-by: Tejun Heo Signed-off-by: Greg Kroah-Hartman commit 075cae495187c9aa0d06337fa9d237ab03839e9c Author: Eric W. Biederman Date: Thu May 8 14:41:00 2008 -0700 kobject: Fix kobject_rename and !CONFIG_SYSFS When looking at kobject_rename I found two bugs with that exist when sysfs support is disabled in the kernel. kobject_rename does not change the name on the kobject when sysfs support is not compiled in. kobject_rename without locking attempts to check the validity of a rename operation, which the kobject layer simply does not have the infrastructure to do. This patch documents the previously unstated requirement of kobject_rename that is the responsibility of the caller to provide mutual exclusion and to be certain that the new_name for the kobject is valid. This patch modifies sysfs_rename_dir in !CONFIG_SYSFS case to call kobject_set_name to actually change the kobject_name. This patch removes the bogus and misleading check in kobject_rename that attempts to see if a rename is valid. The check is bogus because we do not have the proper locking. The check is misleading because it looks like we can and do perform checking at the kobject level that we don't. Changelog: v3: Documentation typo fixes v2: Added a declaration of kboject_set_name to sysfs.h so the code actually compiles with !CONFIG_SYSFS. Unscrambling the header dependencies so everything looks beautiful is a project for another day. Signed-off-by: Eric W. Biederman Signed-off-by: Greg Kroah-Hartman commit c4276ccc99788c9a1ef4427240eebb9d43a4a1b1 Author: Adrian Bunk Date: Tue Aug 12 15:43:59 2008 -0400 drivers/firmware/iscsi_ibft.c: make 3 functions static This patch makes the following needlessly global functions static: - ibft_attr_show_initiator() - ibft_attr_show_nic() - ibft_attr_show_target() Signed-off-by: Adrian Bunk Signed-off-by: Konrad Rzeszutek Signed-off-by: Greg Kroah-Hartman commit f60cd682551f98e41d78091fc6a1fb8afa055502 Author: Neil Brown Date: Wed Jul 16 08:58:04 2008 +1000 sysfs: Support sysfs_notify from atomic context with new sysfs_notify_dirent Support sysfs_notify from atomic context with new sysfs_notify_dirent sysfs_notify currently takes sysfs_mutex. This means that it cannot be called in atomic context. sysfs_mutex is sometimes held over a malloc (sysfs_rename_dir) so it can block on low memory. In md I want to be able to notify on a sysfs attribute from atomic context, and I don't want to block on low memory because I could be in the writeout path for freeing memory. So: - export the "sysfs_dirent" structure along with sysfs_get, sysfs_put and sysfs_get_dirent so I can get the sysfs_dirent that I want to notify on and hold it in an md structure. - split sysfs_notify_dirent out of sysfs_notify so the sysfs_dirent can be notified on with no blocking (just a spinlock). Signed-off-by: Neil Brown Acked-by: Tejun Heo Signed-off-by: Greg Kroah-Hartman commit 8567db6e22ea0cf77c95acc0a49d345a660ae59a Author: Adrian Bunk Date: Mon Jul 21 22:33:36 2008 +0300 driver core: make struct platform_pm_ops static This patch makes the needlessly global struct platform_pm_ops static. Signed-off-by: Adrian Bunk Signed-off-by: Greg Kroah-Hartman commit 4f4475d4a3e4b206f51ed434edf4864db22f64cc Author: Jason Baron Date: Tue Aug 12 16:46:19 2008 -0400 driver core: basic infrastructure for per-module dynamic debug messages Base infrastructure to enable per-module debug messages. I've introduced CONFIG_DYNAMIC_PRINTK_DEBUG, which when enabled centralizes control of debugging statements on a per-module basis in one /proc file, currently, /dynamic_printk/modules. When, CONFIG_DYNAMIC_PRINTK_DEBUG, is not set, debugging statements can still be enabled as before, often by defining 'DEBUG' for the proper compilation unit. Thus, this patch set has no affect when CONFIG_DYNAMIC_PRINTK_DEBUG is not set. The infrastructure currently ties into all pr_debug() and dev_dbg() calls. That is, if CONFIG_DYNAMIC_PRINTK_DEBUG is set, all pr_debug() and dev_dbg() calls can be dynamically enabled/disabled on a per-module basis. Future plans include extending this functionality to subsystems, that define their own debug levels and flags. Usage: Dynamic debugging is controlled by the debugfs file, /dynamic_printk/modules. This file contains a list of the modules that can be enabled. The format of the file is as follows: . . . : Name of the module in which the debug call resides : whether the messages are enabled or not For example: snd_hda_intel enabled=0 fixup enabled=1 driver enabled=0 Enable a module: $echo "set enabled=1 " > dynamic_printk/modules Disable a module: $echo "set enabled=0 " > dynamic_printk/modules Enable all modules: $echo "set enabled=1 all" > dynamic_printk/modules Disable all modules: $echo "set enabled=0 all" > dynamic_printk/modules Finally, passing "dynamic_printk" at the command line enables debugging for all modules. This mode can be turned off via the above disable command. [gkh: minor cleanups and tweaks to make the build work quietly] Signed-off-by: Jason Baron Signed-off-by: Greg Kroah-Hartman commit 6941e0c4af8ffff47a17449b966b3c0fb9365479 Author: David Brownell Date: Mon Aug 18 17:45:07 2008 -0700 usb gadget: link fixes for network gadget Change how the Ethernet/RNDIS gadget driver builds: don't use separate compilation, since it works poorly when key parts are library code (with init sections etc). Instead be as close as we can to "gcc --combine ...". This is a bit more complicated than most of the others because it had to resolve a few symbol collisions. Signed-off-by: David Brownell Signed-off-by: Greg Kroah-Hartman commit ded08dbf23b882475a9d587930938fb47e2e098b Author: David Brownell Date: Mon Aug 18 17:43:56 2008 -0700 usb gadget: link fixes for cdc composite gadget Change how the CDC Composite gadget driver builds: don't use separate compilation, since it works poorly when key parts are library code (with init sections etc). Instead be as close as we can to "gcc --combine ...". Signed-off-by: David Brownell Signed-off-by: Greg Kroah-Hartman commit 603b2ba0a19fa3734cc14a99f487a3137344174f Author: David Brownell Date: Mon Aug 18 17:43:25 2008 -0700 usb gadget: link fixes for storage gadget Change how the file storage gadget driver builds: don't use separate compilation, since it works poorly when key parts are library code (with init sections etc). Instead be as close as we can to "gcc --combine ...". Signed-off-by: David Brownell Signed-off-by: Greg Kroah-Hartman commit a41ddedda3d4fceea3298fd87e9cea771556b3f2 Author: David Brownell Date: Mon Aug 18 17:42:49 2008 -0700 usb gadget: link fixes for printer gadget Change how the printer gadget driver builds: don't use separate compilation, since it works poorly when key parts are library code (with init sections etc). Instead be as close as we can to "gcc --combine ...". Signed-off-by: David Brownell Signed-off-by: Greg Kroah-Hartman commit 9ea3e6275d0ca227feb17ffd3cc7d85a8abfe5ae Author: David Brownell Date: Mon Aug 18 17:42:04 2008 -0700 usb gadget: link fixes for MIDI gadget Change how the MIDI gadget driver builds: don't use separate compilation, since it works poorly when key parts are library code (with init sections etc). Instead be as close as we can to "gcc --combine ...". Signed-off-by: David Brownell Signed-off-by: Greg Kroah-Hartman commit 74f8cdba578847f0c63b3edce85af77c639f8e4a Author: David Brownell Date: Mon Aug 18 17:41:31 2008 -0700 usb gadget: link fixes for gadget zero Change how the Gadget Zero driver builds: don't use separate compilation, since it works poorly when key parts are library code (with init sections etc). Instead be as close as we can to "gcc --combine ...". Signed-off-by: David Brownell Signed-off-by: Greg Kroah-Hartman commit fe73f7f8458959ece6db48f82e9d262ecb4f4b5c Author: David Brownell Date: Mon Aug 18 17:41:02 2008 -0700 usb gadget: link fixes for serial gadget Change how the serial gadget driver builds: don't use separate compilation, since it works poorly when key parts are library code (with init sections etc). Instead be as close as we can to "gcc --combine ...". Signed-off-by: David Brownell Signed-off-by: Greg Kroah-Hartman commit 211997eee62ac9a18e1702625f73f6d343f8a9e1 Author: Greg Kroah-Hartman Date: Mon Jul 21 20:03:34 2008 -0700 device create: remove device_create_drvdata Now that the tree is cleaned up, device_create_drvdata can be safely removed. Signed-off-by: Greg Kroah-Hartman commit e0239ecba3b0ad2ca90a5595eae7a78003f836d0 Author: Greg Kroah-Hartman Date: Mon Jul 21 20:03:34 2008 -0700 device create: ide: convert device_create_drvdata to device_create Now that device_create() has been audited, rename things back to the original call to be sane. Cc: Bartlomiej Zolnierkiewicz Signed-off-by: Greg Kroah-Hartman commit 044c1bae15b62ceee8afd7c55f8dced94607b0f2 Author: Greg Kroah-Hartman Date: Mon Jul 21 20:03:34 2008 -0700 device create: video: convert device_create_drvdata to device_create Now that device_create() has been audited, rename things back to the original call to be sane. Signed-off-by: Greg Kroah-Hartman commit 8a456014310c4bc6ec8b3cff38a924b17aff0556 Author: Greg Kroah-Hartman Date: Mon Jul 21 20:03:34 2008 -0700 device create: usb: convert device_create_drvdata to device_create Now that device_create() has been audited, rename things back to the original call to be sane. Signed-off-by: Greg Kroah-Hartman commit e957c6af46f54f9d794be9d347d8cced07652d41 Author: Greg Kroah-Hartman Date: Mon Jul 21 20:03:34 2008 -0700 device create: sound: convert device_create_drvdata to device_create Now that device_create() has been audited, rename things back to the original call to be sane. Cc: Jaroslav Kysela Signed-off-by: Greg Kroah-Hartman commit 4fbd40c11b4aa0cdef5240b328803e6410a0b469 Author: Greg Kroah-Hartman Date: Mon Jul 21 20:03:34 2008 -0700 device create: scsi: convert device_create_drvdata to device_create Now that device_create() has been audited, rename things back to the original call to be sane. Cc: James E.J. Bottomley Signed-off-by: Greg Kroah-Hartman commit 2f989fec2bb7995b41691f189b217282df6aad88 Author: Greg Kroah-Hartman Date: Mon Jul 21 20:03:34 2008 -0700 device create: s390: convert device_create_drvdata to device_create Now that device_create() has been audited, rename things back to the original call to be sane. Cc: Martin Schwidefsky Cc: Heiko Carstens Signed-off-by: Greg Kroah-Hartman commit b2a4fca98e754dbb317b63842b87b02abb6d6976 Author: Greg Kroah-Hartman Date: Mon Jul 21 20:03:34 2008 -0700 device create: net: convert device_create_drvdata to device_create Now that device_create() has been audited, rename things back to the original call to be sane. Cc: Jeff Garzik Signed-off-by: Greg Kroah-Hartman commit 8919d741a860d2852a73408015c6757282fec3ed Author: Greg Kroah-Hartman Date: Mon Jul 21 20:03:34 2008 -0700 device create: misc: convert device_create_drvdata to device_create Now that device_create() has been audited, rename things back to the original call to be sane. Signed-off-by: Greg Kroah-Hartman commit db29517f2785cca3e3294803554aab4db984631b Author: Greg Kroah-Hartman Date: Mon Jul 21 20:03:34 2008 -0700 device create: infiniband: convert device_create_drvdata to device_create Now that device_create() has been audited, rename things back to the original call to be sane. Cc: Roland Dreier Cc: Sean Hefty Cc: Hal Rosenstock Signed-off-by: Greg Kroah-Hartman commit 6c749926e31592e1ff7bf81c6270982180a5cd83 Author: Greg Kroah-Hartman Date: Mon Jul 21 20:03:34 2008 -0700 device create: ieee1394: convert device_create_drvdata to device_create Now that device_create() has been audited, rename things back to the original call to be sane. Cc: Ben Collins Acked-by: Stefan Richter Signed-off-by: Greg Kroah-Hartman commit 2f580b8298ef8a3d30f126630b3d53a80cc81ec1 Author: Greg Kroah-Hartman Date: Mon Jul 21 20:03:34 2008 -0700 device create: char: convert device_create_drvdata to device_create Now that device_create() has been audited, rename things back to the original call to be sane. Signed-off-by: Greg Kroah-Hartman commit df248e05a961ad5bd75b9f9c0ebabbcc3b3e5728 Author: Greg Kroah-Hartman Date: Mon Jul 21 20:03:34 2008 -0700 device create: block: convert device_create_drvdata to device_create Now that device_create() has been audited, rename things back to the original call to be sane. Signed-off-by: Greg Kroah-Hartman commit c2dd20a20c1976f9d0a84c79ae5f88fb33e796ee Author: Andrew Morton Date: Fri Aug 24 16:11:54 2007 -0700 sysfs: crash debugging Print the name of the last-accessed sysfs file when we oops, to help track down oopses which occur in sysfs store/read handlers. Because these oopses tend to not leave any trace of the offending code in the stack traces. Cc: Kay Sievers Cc: Mathieu Desnoyers Signed-off-by: Andrew Morton Signed-off-by: Greg Kroah-Hartman commit 3006e9d3fad23385b8fb5ba024d3e5d64b8a195a Author: Geert Uytterhoeven Date: Thu Sep 4 09:39:57 2008 +1000 m68k: needs Several multi-bus subsystems: | include/linux/ssb/ssb.h: In function 'ssb_dma_mapping_error': | include/linux/ssb/ssb.h:430: error: implicit declaration of function 'pci_dma_mapping_error' | include/linux/ssb/ssb.h: In function 'ssb_dma_map_single': | include/linux/ssb/ssb.h:444: error: implicit declaration of function 'pci_map_single' | include/linux/ssb/ssb.h: In function 'ssb_dma_unmap_single': | include/linux/ssb/ssb.h:458: error: implicit declaration of function 'pci_unmap_single' | include/linux/ssb/ssb.h: In function 'ssb_dma_sync_single_for_cpu': | include/linux/ssb/ssb.h:475: error: implicit declaration of function 'pci_dma_sync_single_for_cpu' | include/linux/ssb/ssb.h: In function 'ssb_dma_sync_single_for_device': | include/linux/ssb/ssb.h:493: error: implicit declaration of function 'pci_dma_sync_single_for_device' or legacy drivers: | drivers/net/hp100.c: In function 'pdl_map_data': | drivers/net/hp100.c:291: error: implicit declaration of function 'pci_map_single' | drivers/net/hp100.c: In function 'hp100_probe1': | drivers/net/hp100.c:707: error: implicit declaration of function 'pci_alloc_consistent' | drivers/net/hp100.c:782: error: implicit declaration of function 'pci_free_consistent' | drivers/net/hp100.c: In function 'hp100_clean_txring': | drivers/net/hp100.c:1614: error: implicit declaration of function 'pci_unmap_single' and | drivers/scsi/aic7xxx_old.c: In function 'aic7xxx_allocate_scb': | drivers/scsi/aic7xxx_old.c:2573: error: implicit declaration of function 'pci_alloc_consistent' | drivers/scsi/aic7xxx_old.c: In function 'aic7xxx_done': | drivers/scsi/aic7xxx_old.c:2697: error: implicit declaration of function 'pci_unmap_single' | drivers/scsi/aic7xxx_old.c: In function 'aic7xxx_handle_seqint': | drivers/scsi/aic7xxx_old.c:4275: error: implicit declaration of function 'pci_map_single' | drivers/scsi/aic7xxx_old.c: In function 'aic7xxx_free': | drivers/scsi/aic7xxx_old.c:8460: error: implicit declaration of function 'pci_free_consistent' rely on PCI DMA operations to be always available. Add #include to to make them happy. Signed-off-by: Geert Uytterhoeven commit 29f41bc5bbdda0e3a2694bcd7b97d1ac090ae969 Author: Geert Uytterhoeven Date: Thu Sep 4 09:39:57 2008 +1000 m68k: Add missing dma_sync_single_range_for_{cpu,device}() | include/linux/ssb/ssb.h: In function 'ssb_dma_sync_single_range_for_cpu': | include/linux/ssb/ssb.h:517: error: implicit declaration of function 'dma_sync_single_range_for_cpu' | include/linux/ssb/ssb.h: In function 'ssb_dma_sync_single_range_for_device': | include/linux/ssb/ssb.h:538: error: implicit declaration of function 'dma_sync_single_range_for_device' Add the missing dma_sync_single_range_for_{cpu,device}(), and remove the `inline' for the non-static function dma_sync_single_for_device(). Signed-off-by: Geert Uytterhoeven commit 765ed97d4d5d6fa5de6ab16342fb1e19a7b466a1 Author: Geert Uytterhoeven Date: Thu Sep 4 09:39:57 2008 +1000 m68k: Define rtc_lock on Atari The nvram and rtc-cmos drivers use the spinlock rtc_lock to protect against concurrent accesses to the CMOS memory. As m68k doesn't support SMP or preempt yet, the spinlock calls tend to get optimized away, but not for all configurations, causing in some rare cases: | ERROR: "rtc_lock" [drivers/rtc/rtc-cmos.ko] undefined! | ERROR: "rtc_lock" [drivers/char/nvram.ko] undefined! Add the spinlock to the Atari core code to avoid this. Signed-off-by: Geert Uytterhoeven commit 9eb8c08e08e6350eea0c4900ab073a35dba5ea19 Author: Geert Uytterhoeven Date: Thu Sep 4 09:39:57 2008 +1000 m68k: Remove unused atari_kbd_translate() If CONFIG_VT=n, I get: | arch/m68k/atari/built-in.o: In function `atari_kbd_translate': | arch/m68k/atari/atakeyb.c:640: undefined reference to `shift_state' Just remove atari_kbd_translate(), as it's unused. Signed-off-by: Geert Uytterhoeven commit fedd2609b1b7b5bdba4ac5b7b1462e0518b2fb27 Author: Geert Uytterhoeven Date: Thu Sep 4 09:39:56 2008 +1000 m68k: Modular Amiga keyboard needs key_maps | ERROR: "key_maps" [drivers/input/keyboard/amikbd.ko] undefined! Export key_maps in the Amiga core code, as its defined in an autogenerated file (drivers/char/defkeymap.c) Signed-off-by: Geert Uytterhoeven commit 835920ab362970126b89ef128b63ca41bb253b21 Author: Geert Uytterhoeven Date: Thu Sep 4 09:39:56 2008 +1000 m68k: Disable Amiga serial console support if modular If CONFIG_AMIGA_BUILTIN_SERIAL=m, I get the following warnings: | drivers/char/amiserial.c: At top level: | drivers/char/amiserial.c:2138: warning: data definition has no type or storage class | drivers/char/amiserial.c:2138: warning: type defaults to 'int' in declaration of 'console_initcall' | drivers/char/amiserial.c:2138: warning: parameter names (without types) in function declaration | drivers/char/amiserial.c:2134: warning: 'amiserial_console_init' defined but not used Apparently console_initcall() is not defined in the modular case. Disable serial console support if the driver is modular. Signed-off-by: Geert Uytterhoeven commit 2d5c6414f5668833b760d282aced64bb7ff86105 Author: Geert Uytterhoeven Date: Thu Sep 4 09:39:56 2008 +1000 m68k: Reverse platform MMU logic so Sun 3 is last Currently Sun 3 support is the first platform option, as the Sun 3 MMU is incompatible with standard Motorola MMUs. However, this means that `allmodconfig' enables support for Sun 3, and thus disables support for all other platforms. Reverse the logic and move Sun 3 last, so `allmodconfig' enables all platforms except for Sun 3, increasing compile-coverage. Signed-off-by: Geert Uytterhoeven commit 81de14a10e0553c67f5b11d3a604fc65817f1921 Author: Roman Zippel Date: Thu Sep 4 09:39:56 2008 +1000 m68k: Add NOTES to init data so it's discarded at boot Add .note.gnu.build-id to init data so it's discarded at boot. [Andreas Schwab] Use NOTES macro Signed-off-by: Roman Zippel Signed-off-by: Geert Uytterhoeven commit defde9b28c41deb7bcc42d67fb31f607895ada32 Author: Roman Zippel Date: Thu Sep 4 09:39:55 2008 +1000 m68k: Put .bss at the end of the data section Put .bss at the end of the data section Signed-off-by: Roman Zippel Signed-off-by: Geert Uytterhoeven commit 22f7566ba831ea20f98adc3434d18aabb48e5e56 Author: Geert Uytterhoeven Date: Thu Sep 4 09:39:55 2008 +1000 m68k: Use new printk() extension %pS to print symbols This changes the oops and backtrace code to use the new `%pS' printk() extension to print out symbols rather than manually calling print_symbol. Signed-off-by: Geert Uytterhoeven commit 5eb937e081681f4386a6a94579de9ab54621d32c Author: Adrian Bunk Date: Thu Sep 4 09:39:55 2008 +1000 m68k: use bcd2bin/bin2bcd This patch changes m68k to use the new bcd2bin/bin2bcd functions instead of the obsolete BCD_TO_BIN/BIN_TO_BCD/BCD2BIN/BIN2BCD macros. It also remove local bcd2bin/bin2bcd implementations in favor of the global ones. Signed-off-by: Adrian Bunk Signed-off-by: Geert Uytterhoeven commit 03e77dd38aafeb51a08c3146f7abe7d8e76a4c3e Author: Geert Uytterhoeven Date: Thu Sep 4 09:39:55 2008 +1000 m68k: Update defconfigs for 2.6.27-rc4 Signed-off-by: Geert Uytterhoeven commit 05e42f727f1314b8d67f7595e4cb51714a40ee59 Author: Greg Kroah-Hartman Date: Tue Aug 26 16:22:06 2008 -0700 USB: add USB test and measurement class driver This driver was originaly written by Stefan Kopp, but massively reworked by Greg for submission. Thanks to Felipe Balbi for lots of work in cleaning up this driver. Thanks to Oliver Neukum for reviewing previous versions and pointing out problems. Cc: Stefan Kopp Cc: Marcel Janssen Cc: Felipe Balbi Cc: Oliver Neukum Signed-off-by: Greg Kroah-Hartman commit b26c6f45994e1faaf0920a3d487a80a546e907bd Author: Harrison Metzger Date: Thu Aug 14 11:29:32 2008 -0500 USB: Added driver for a Delcom USB 7-segment LED Display Added basic support for a Delcom USB 7-segment LED Display Signed-off by: Harrison Metzger Signed-off-by: Greg Kroah-Hartman commit 8d4618795bb3c42f49e8e461c5a32b684444fb9e Author: David Brownell Date: Tue Aug 26 23:35:04 2008 -0700 USB: fix EHCI periodic transfers As noted by Stefan Neis , we had a recent regression with EHCI periodic transfers, in some (seemingly not all that common) cases. The root cause was that the schedule activation was only loosely coupled to the addition or removal of transfers, so two different execution contexts could both think they had to deactivate (or conversely activate) the schedule. So this fix tightens that coupling, managing it more like a refcount. Signed-off-by: David Brownell Signed-off-by: Greg Kroah-Hartman commit 61f9700204e5a742bbb9ad1f3251f154f1c596fd Author: Felipe Balbi Date: Sat Aug 30 19:42:02 2008 +0300 usb: musb: fix include path headers were moved, fixing. Signed-off-by: Felipe Balbi Signed-off-by: Greg Kroah-Hartman commit 0e10f6700d7f0b34de7f1a4a297c5a1c8d0bba8f Author: Filip Joelsson Date: Sun Aug 31 08:22:16 2008 +0200 USB: Fixing Nokia 3310c in storage mode I had trouble connecting my cell phone as a storage device - so I added it to the unusual_devs.h list. I had trouble with the bcdDeviceMin and Max values - so after some experimenting I made it pretty inclusive. From: Filip Joelsson Signed-off-by: Greg Kroah-Hartman commit c77ebeac03f683eed5503c8a23e8c09a3222a0bb Author: David Brownell Date: Sun Aug 31 18:04:27 2008 -0700 usb gadget: fix omap_udc DMA regression This resolves another regression caused by the "use omap_read/write instead of __REG" patch: the hardware address used for DMA to/from the UDC became wrong. Bug noted by Russell King. Reported-by: Russell King Signed-off-by: David Brownell Acked-by: Russell King Signed-off-by: Greg Kroah-Hartman commit 5dea87bcc633631b47390c8ddb4ae0bfaa8a69d7 Author: Oliver Neukum Date: Tue Sep 2 10:52:08 2008 +0200 USB: update of Documentation/usb/anchors.txt The extended anchor API is documented Signed-off-by: Oliver Neukum Signed-off-by: Greg Kroah-Hartman commit 9cbfff1e22d28cdb207a69dce0446ece79541e3c Author: Geoff Levand Date: Fri Aug 22 14:13:00 2008 -0700 USB: fix hcd interrupt disabling Commit de85422b94ddb23c021126815ea49414047c13dc, 'USB: fix interrupt disabling for HCDs with shared interrupt handlers' changed usb_add_hcd() to strip IRQF_DISABLED from irqflags prior to calling request_irq() with the justification that such a removal was necessary for shared interrupts to work properly. Unfortunately, the change in that commit unconditionally removes the IRQF_DISABLED flag, causing problems on platforms that don't use a shared interrupt but require IRQF_DISABLED. This change adds a check for IRQF_SHARED prior to removing the IRQF_DISABLED flag. Fixes the PS3 system startup hang reported with recent Fedora and OpenSUSE kernels. Note that this problem is hidden when CONFIG_LOCKDEP=y (ps3_defconfig), as local_irq_enable_in_hardirq() is defined as a null statement for that config. CC: stable Signed-off-by: Geoff Levand Cc: Alan Stern Cc: Stefan Becker Signed-off-by: Greg Kroah-Hartman commit d695daec1ed41293ea194a711effbf1825951baf Author: Tony Murray Date: Fri Aug 22 17:30:44 2008 -0500 USB: Correct Sierra Wireless USB EVDO Modem Device ID I was trying to figure out why my device wasn't supported by the drivers/usb/serial/sierra.c driver, while looking throught the device IDs I spotted what I believe to be a typo in the device IDs. Please apply the following patch If you look down further, there is another HP wireless broadband card, which has a vendor ID of 03f0, like my device. Below is my "lsusb -v -d 03f0:1b1d". Bus 001 Device 005: ID 03f0:1b1d Hewlett-Packard Device Descriptor: bLength 18 bDescriptorType 1 bcdUSB 1.10 bDeviceClass 0 (Defined at Interface level) bDeviceSubClass 0 bDeviceProtocol 0 bMaxPacketSize0 64 idVendor 0x03f0 Hewlett-Packard idProduct 0x1b1d bcdDevice 0.01 iManufacturer 1 HP iProduct 2 HP ev2200 1xEV-DO Broadband Wireless Module iSerial 0 bNumConfigurations 1 Configuration Descriptor: bLength 9 bDescriptorType 2 wTotalLength 67 bNumInterfaces 1 bConfigurationValue 1 iConfiguration 0 bmAttributes 0xe0 Self Powered Remote Wakeup MaxPower 0mA Interface Descriptor: bLength 9 bDescriptorType 4 bInterfaceNumber 0 bAlternateSetting 0 bNumEndpoints 7 bInterfaceClass 255 Vendor Specific Class bInterfaceSubClass 255 Vendor Specific Subclass bInterfaceProtocol 255 Vendor Specific Protocol iInterface 3 Data Interface Endpoint Descriptor: bLength 7 bDescriptorType 5 bEndpointAddress 0x81 EP 1 IN bmAttributes 3 Transfer Type Interrupt Synch Type None Usage Type Data wMaxPacketSize 0x0010 1x 16 bytes bInterval 128 Endpoint Descriptor: bLength 7 bDescriptorType 5 bEndpointAddress 0x82 EP 2 IN bmAttributes 2 Transfer Type Bulk Synch Type None Usage Type Data wMaxPacketSize 0x0040 1x 64 bytes bInterval 0 Endpoint Descriptor: bLength 7 bDescriptorType 5 bEndpointAddress 0x02 EP 2 OUT bmAttributes 2 Transfer Type Bulk Synch Type None Usage Type Data wMaxPacketSize 0x0040 1x 64 bytes bInterval 0 Endpoint Descriptor: bLength 7 bDescriptorType 5 bEndpointAddress 0x84 EP 4 IN bmAttributes 2 Transfer Type Bulk Synch Type None Usage Type Data wMaxPacketSize 0x0040 1x 64 bytes bInterval 0 Endpoint Descriptor: bLength 7 bDescriptorType 5 bEndpointAddress 0x04 EP 4 OUT bmAttributes 2 Transfer Type Bulk Synch Type None Usage Type Data wMaxPacketSize 0x0040 1x 64 bytes bInterval 0 Endpoint Descriptor: bLength 7 bDescriptorType 5 bEndpointAddress 0x85 EP 5 IN bmAttributes 2 Transfer Type Bulk Synch Type None Usage Type Data wMaxPacketSize 0x0040 1x 64 bytes bInterval 0 Endpoint Descriptor: bLength 7 bDescriptorType 5 bEndpointAddress 0x05 EP 5 OUT bmAttributes 2 Transfer Type Bulk Synch Type None Usage Type Data wMaxPacketSize 0x0040 1x 64 bytes bInterval 0 Device Status: 0x0000 (Bus Powered) From: Tony Murray Cc: Kevin Lloyd Signed-off-by: Greg Kroah-Hartman commit a141e189085901cafed4cb371745fbb57d338655 Author: Richard Nauber Date: Tue Aug 26 23:34:11 2008 +0200 USB: Fix the Nokia 6300 storage-mode. This patch fixes that behavior: ... Aug 26 22:39:23 rnauber sd 2:0:0:0: [sda] Sense Key : 0x0 [current] Aug 26 22:39:23 rnauber sd 2:0:0:0: [sda] ASC=0x0 ASCQ=0x0 Aug 26 22:39:23 rnauber sd 2:0:0:0: [sda] Sense Key : 0x0 [current] Aug 26 22:39:23 rnauber sd 2:0:0:0: [sda] ASC=0x0 ASCQ=0x0 Aug 26 22:39:23 rnauber sd 2:0:0:0: [sda] Sense Key : 0x0 [current] Aug 26 22:39:23 rnauber sd 2:0:0:0: [sda] ASC=0x0 ASCQ=0x0 Aug 26 22:39:23 rnauber sd 2:0:0:0: [sda] Sense Key : 0x0 [current] ... cat /proc/bus/usb/devices ... T: Bus=04 Lev=01 Prnt=01 Port=00 Cnt=01 Dev#= 3 Spd=12 MxCh= 0 D: Ver= 2.00 Cls=00(>ifc ) Sub=00 Prot=00 MxPS=64 #Cfgs= 1 P: Vendor=0421 ProdID=04fa Rev= 6.01 S: Manufacturer=Nokia S: Product=Nokia 6300 S: SerialNumber=35XXXXXXXX C:* #Ifs= 1 Cfg#= 1 Atr=c0 MxPwr=100mA I:* If#= 0 Alt= 0 #EPs= 2 Cls=08(stor.) Sub=06 Prot=50 Driver=usb-storage E: Ad=81(I) Atr=02(Bulk) MxPS= 64 Ivl=0ms E: Ad=01(O) Atr=02(Bulk) MxPS= 64 Ivl=0ms ... From: Richard Nauber Signed-off-by: Greg Kroah-Hartman commit 4fa2e0f9882e38286b40648d5159ac5c7f53d55a Author: David Brownell Date: Tue Aug 26 14:43:46 2008 -0700 USB: ehci: fix some ehci hangs and crashes I noticed that the "Refactor "if (handshake()) state = HC_STATE_HALT" patch from earlier this year perpetuated a potential problem: it can mark the controller as halted when it's still running (but not acting as, perhaps wrongly, expected). That caused some hangs and crashes, rather than more polite failure modes of a truly halted controller. This patch forces a true halt, and emits a (previously missing) diagnostic. Signed-off-by: David Brownell Signed-off-by: Greg Kroah-Hartman commit ebe621776d4d30fa06cbb9db5841a175da0b725e Author: Kevin Lloyd Date: Mon Aug 25 19:20:40 2008 -0700 USB Serial: Sierra: Device addition & version rev This patch adds devices to the sierra driver and rev's the driver version. Signed-off-by: Kevin Lloyd Signed-off-by: Greg Kroah-Hartman commit 5cdb3c7fa6a50cacd4e00223b36b8a243528f6ac Author: Kevin Lloyd Date: Tue Aug 26 18:30:45 2008 -0700 USB Storage: Sierra: Non-configurable TRU-Install This patch alters the Sierra Mass Storage patch so that it is non-configurable. Signed-off-by: Kevin Lloyd Signed-off-by: Greg Kroah-Hartman commit 1aa0365f275f7df6bb1e0b6667ed2b54199fe21d Author: Robert Reif Date: Wed Sep 3 16:29:42 2008 -0700 sparc32: add init memory poisoning This patch adds init memory poisoning. It looks like totalram_pages was not updated properly in free_initrd_mem so I fixed that as well. Signed-off-by: Robert Reif Signed-off-by: David S. Miller commit 94d5b5432b96efa69840b397853cf2cb81ab4fab Author: David S. Miller Date: Wed Sep 3 16:19:46 2008 -0700 sparc: Remove asm/rtc.h No more users. Signed-off-by: David S. Miller commit 08b7ad279ada5771e1b700f5d3b3432fc5be94ab Author: Russell King Date: Wed Sep 3 23:59:23 2008 +0100 [ARM] omap: fix build error in ohci-omap.c drivers/usb/host/ohci-omap.c: In function 'ohci_omap_init': drivers/usb/host/ohci-omap.c:228: error: 'start_hnp' undeclared (first use in this function) Signed-off-by: Russell King commit f6e30ffcf3749fd3bdf267156bd0f56eba68f2f8 Author: David S. Miller Date: Wed Sep 3 15:57:04 2008 -0700 sparc32: Kill asm/mostek.h. No longer used. Signed-off-by: David S. Miller commit 81c4fdb1d64a44ffc17c5c64b32a1be4fc85dd55 Author: David S. Miller Date: Wed Sep 3 15:56:27 2008 -0700 sparc32: Kill remaining asm/mostek.h inclusions. No longer needed. Signed-off-by: David S. Miller commit eed795bf1fd2a012beddd6017fd7baf8ddf43ca1 Author: David S. Miller Date: Wed Sep 3 15:55:32 2008 -0700 sparc: Kill sbus mostek RTC driver. No longer used. Signed-off-by: David S. Miller commit c4cbe6f96ebf8eb03884c31504d36dccd2ef1062 Author: David S. Miller Date: Wed Sep 3 15:52:38 2008 -0700 sparc32: use RTC subsystem Use rtc subsystem for sparc32 architecture. Actually, only one driver is needed: m48t59 as it supports the most common clocks on sparc32 machines: m48t08 and m48t02. [ Add proper RTC layer calls to set_rtc_mmss() -DaveM ] Signed-off-by: Krzysztof Helt Signed-off-by: David S. Miller commit ba4ac0bcca594145c9252417c1a4f6b14e362db9 Author: Russell King Date: Wed Sep 3 23:46:18 2008 +0100 [ARM] omap: fix virtual vs physical address space confusions mcbsp is confused as to what takes a physical or virtual address. Fix the six instances where it gets it wrong. Signed-off-by: Russell King commit 64151ad5b3a03e236390d6d5160805ee4f4e7c67 Author: Krzysztof Helt Date: Wed Sep 3 15:41:57 2008 -0700 rtc-m48t59: allow externally mapped ioaddr Add support for externally mapped ioaddr. This is required on sparc32 as the ioaddr must be mapped with of_ioremap(). Signed-off-by: Krzysztof Helt Signed-off-by: David S. Miller commit 94fe7424a4c21940b4569200faaf0a0a5efd2924 Author: Krzysztof Helt Date: Wed Sep 3 15:12:34 2008 -0700 rtc-m48t59: add support for M48T02 and M48T59 chips Add support for two compatible RTC: - M48T08 which does not have alarm part, - M48T08 which does not have alarm part and has only 2KB of NVRAM These types covers all Mostek's RTC used in Sun UltraSparc workstations. Tested on Sun Ultra60 with M48T59 RTC. Signed-off-by: Krzysztof Helt Signed-off-by: Alessandro Zummo Signed-off-by: Andrew Morton Signed-off-by: David S. Miller commit 3ca60f6e637cee8c735a7448fd912fe1a6e42fc1 Author: Krzysztof Helt Date: Wed Sep 3 15:10:14 2008 -0700 rtc-m48t59: reduce structure m48t59_private Remove element size from the structure m48t59_private as it is used as local variable for storing temporary value. Signed-off-by: Krzysztof Helt Signed-off-by: Alessandro Zummo Signed-off-by: Andrew Morton Signed-off-by: David S. Miller commit a505f4ff49ff05ca9030069fab7de229dae7c819 Author: Ilpo Järvinen Date: Tue Aug 19 10:36:01 2008 +0300 s2io: reindented misleading for loop Signed-off-by: Ilpo Järvinen Signed-off-by: Jeff Garzik commit 45021ae4986c9eefe3ccc3b858517202f4b4f3ee Author: Huang Weiyi Date: Sun Aug 17 07:51:20 2008 +0800 [netdrvr] removed unused #include The drivers below do not use LINUX_VERSION_CODE nor KERNEL_VERSION. drivers/net/myri10ge/myri10ge.c drivers/net/netxen/netxen_nic_ethtool.c drivers/net/tokenring/lanstreamer.c This patch removes the said #include . Signed-off-by: Huang Weiyi Signed-off-by: Jeff Garzik commit 1c460afaa550eda5df011168bdda7441a7788c3a Author: Kevin Lo Date: Wed Aug 27 11:35:13 2008 +0800 8139too: use netdev_alloc_skb This patch uses netdev_alloc_skb. This sets skb->dev and allows arch specific allocation. Also cleanup the alignment code. Signed-off-by: Kevin Lo Signed-off-by: Jeff Garzik commit a52be1cbc262bb23cce9d856975c74626d26ec8c Author: Kevin Lo Date: Wed Aug 27 11:35:15 2008 +0800 8139cp: use netdev_alloc_skb This patch uses netdev_alloc_skb. This sets skb->dev and allows arch specific allocation. Also cleanup the alignment code. Signed-off-by: Kevin Lo Signed-off-by: Jeff Garzik commit b26b555a7b4decf765ade265fa9da3bd6ff3e9e0 Author: Kevin Lo Date: Wed Aug 27 11:35:09 2008 +0800 via-rhine: changed to use netdev_alloc_skb() from dev_alloc_skb Use netdev_alloc_skb. This sets skb->dev and allows arch specific allocation. Also cleanup the alignment code. Signed-off-by: Kevin Lo Signed-off-by: Jeff Garzik commit c844d483004df596b0bd6e68a3be8e0cd85536ce Author: Stephen Hemminger Date: Wed Aug 27 20:48:23 2008 -0700 sky2: display product info on boot. Change bootup messages to print more information. This is to help users who may have old buggy EEPROM image. Signed-off-by: Stephen Hemminger Signed-off-by: Jeff Garzik commit 1413235c14301c4bd27aabf408e4336719b6f505 Author: Stephen Hemminger Date: Wed Aug 27 20:46:26 2008 -0700 sky2: EEPROM read/write bug fixes Cleanup and harden the routines accessing the EEPROM. 1. Prevent spin forever waiting for the TWSI bus 2. Fix write eeprom to write full words rather than only 16 bits Luckly the vendor doesn't provide EEPROM in Linux format so it must never have been used. 3. Don't allow partial eeprom writes, not needed, not safe. These are non-urgent bug fixes. Signed-off-by: Stephen Hemminger Signed-off-by: Jeff Garzik commit 184d346e3e62738ad6c0ad085e8eefb1ecbf901d Author: Hongjie Yang Date: Wed Sep 3 16:16:09 2008 +0200 [S390] dcssblk: add >2G DCSSs support and stacked contiguous DCSSs support. The DCSS block device driver is modified to add >2G DCSSs support and allow a DCSS block device to map to a set of contiguous DCSSs. The extmem code is also modified to use new Diagnose x'64' subcodes for >2G DCSSs. Signed-off-by: Hongjie Yang Signed-off-by: Martin Schwidefsky commit 09ca972d957256df62d9edeffbb66e5eff67460a Author: Martin Schwidefsky Date: Wed Sep 3 16:16:08 2008 +0200 [S390] ptrace changes * System call parameter and result access functions * Add tracehook calls * Split syscall_trace into two functions do_syscall_trace_enter and do_syscall_trace_exit Signed-off-by: Martin Schwidefsky commit 7d453be24e1a728f7a352954ca70113276357de1 Author: Christoph Hellwig Date: Wed Sep 3 16:16:07 2008 +0200 [S390] s390: use sys_pause for 31bit pause entry point sys32_pause is a useless copy of the generic sys_pause. (and it's certainly not there for old sparc32 binaries..) Signed-off-by: Christoph Hellwig Signed-off-by: Martin Schwidefsky commit 2aed9d66162a273802147e3c8d43a88c04a29d58 Author: Klaus-Dieter Wacker Date: Wed Sep 3 16:16:06 2008 +0200 [S390] qdio enhanced SIGA (iqdio) support. Add support for z10 HiperSockets multiwrite SBALs on output queues. This is used on LPAR with EDDP enabled devices. Signed-off-by: Klaus-Dieter Wacker commit 9b6ce8595a831a62ec8a449259dd150e3fa64720 Author: Peter Oberparleiter Date: Wed Sep 3 16:16:05 2008 +0200 [S390] cio: introduce purge function for /proc/cio_ignore Allow users to remove blacklisted ccw devices by using the /proc/cio_ignore interface: echo purge > /proc/cio_ignore will remove all devices which are offline and blacklisted. Signed-off-by: Peter Oberparleiter Signed-off-by: Martin Schwidefsky commit 459d831b531f58240b8db1ec4218d3f519db4872 Author: Peter Oberparleiter Date: Wed Sep 3 16:16:04 2008 +0200 [S390] cio: move device unregistration to dedicated work queue Use dedicated slow path work queue when unregistering a device due to a user action. This ensures serialialization of other register/ unregister requests. Signed-off-by: Peter Oberparleiter Signed-off-by: Martin Schwidefsky commit 0e73fbe6a02936a07aafacf489f7179d0ea70414 Author: Peter Oberparleiter Date: Wed Sep 3 16:16:03 2008 +0200 [S390] cio: allow offline processing for disconnected devices When disconnected ccw devices are removed, the device has to be set offline, otherwise there will be side effects including a reference count imbalance. This patch modifies ccw_device_offline to work for devices in disconnecte/not operational state. ccw_device_offline is called by cio for devices which are online during device removal. Signed-off-by: Peter Oberparleiter Signed-off-by: Martin Schwidefsky commit ae2d2feb09c424bc8c9fe9bb5f829607897df6db Author: Cornelia Huck Date: Wed Sep 3 16:14:12 2008 +0200 [S390] cio: Correct cleanup on error. Fix cleanup on error in chp_new() and init_channel_subsystem() (must not call kfree() on structures that had been registered). Signed-off-by: Cornelia Huck Signed-off-by: Martin Schwidefsky commit 3be1adfb912867e244729c3826b457ee76b8f737 Author: Alexander Duyck Date: Sat Aug 30 00:29:10 2008 -0700 ixgbe: change config srrctl to only program one register per VMDq/RSS id This change makes it so only one srrctl register is programmed per VMDq id, and if VMDq is not enabled it is one register per RSS queue. Currently this function is working correctly for the multiqueue RSS and single queue cases, but if any advances features such as VMDq or DCB would have been enabled this function would have caused issues as it was not correct. Signed-off-by: Alexander Duyck Signed-off-by: Jeff Kirsher Signed-off-by: Jeff Garzik commit 1a32bcfb5706d06a49904383b02f7c1d24172b96 Author: Alexander Duyck Date: Tue Aug 26 04:25:11 2008 -0700 igb: clean up a stray fake netdev code left in rx path Remove code that was in place to support fake netdev Signed-off-by: Alexander Duyck Signed-off-by: Jeff Kirsher Signed-off-by: Jeff Garzik commit fc7d345d11e815705fd0c9badc2ee82cb7ca5a84 Author: Alexander Duyck Date: Tue Aug 26 04:25:08 2008 -0700 igb: remove unneeded cleaned variable in clean_tx_irq path The cleaned variable can be replaced by the count of packets cleaned during the tx interrupt routine so it can be removed. Signed-off-by: Alexander Duyck Signed-off-by: Jeff Kirsher Signed-off-by: Jeff Garzik commit 4662e82b2cb41c60826e50474dd86dd5c6372b0c Author: Bruce Allan Date: Tue Aug 26 18:37:06 2008 -0700 e1000e: add support for new 82574L part This new part has the same feature set as previous parts with the addition of MSI-X support. Signed-off-by: Bruce Allan Signed-off-by: Jeff Kirsher Signed-off-by: Jeff Garzik commit f4187b56e1f8a05dd110875d5094b21b51ebd79b Author: Bruce Allan Date: Tue Aug 26 18:36:50 2008 -0700 e1000e: add support for 82567LM-3 and 82567LF-3 (ICH10D) parts Add support for new LOM devices on the latest generation ICHx platforms. Signed-off-by: Bruce Allan Signed-off-by: Jeff Kirsher Signed-off-by: Jeff Garzik commit 2f15f9d60190a62bc8ac50fa84fea31fc0b00ecf Author: Bruce Allan Date: Tue Aug 26 18:36:36 2008 -0700 e1000e: add support for the 82567LM-4 device Enable PCI device ID for a new combination of MAC and PHY already supported in the driver. Signed-off-by: Bruce Allan Signed-off-by: Jeff Kirsher Signed-off-by: Jeff Garzik commit 4eeae6fd3f6a7f4cee0e75cf8b0d30b265339ae8 Author: PJ Waskiewicz Date: Tue Aug 26 04:27:30 2008 -0700 ixgbe: use different context for tso and offload Change TSO offloads to use a different context than VLAN insertion and Tx checksumming. Hardware has separate registers internally for storing these so use them. Signed-off-by: Peter P Waskiewicz Jr Signed-off-by: Jesse Brandeburg Signed-off-by: Jeff Kirsher Signed-off-by: Jeff Garzik commit cc41ac7c0011703460dd4d4674bb7cbf73bb883d Author: Jesse Brandeburg Date: Tue Aug 26 04:27:27 2008 -0700 ixgbe: fix dca hints going to wrong processor hardware was configured incorrectly which led all hints to be sent to queue[0]'s DCA configuration. Signed-off-by: Jesse Brandeburg Signed-off-by: Jeff Kirsher Signed-off-by: Jeff Garzik commit e9990a9cd76a14905a8bf2348444ff775b24a92f Author: Jesse Brandeburg Date: Tue Aug 26 04:27:24 2008 -0700 ixgbe: fix bug where lro settings are per ring Signed-off-by: Jesse Brandeburg Signed-off-by: Jeff Kirsher Signed-off-by: Jeff Garzik commit 96b0e0f63b03153f7f2915f584083b4191b1932d Author: Jesse Brandeburg Date: Tue Aug 26 04:27:21 2008 -0700 ixgbe: update dca to new interface, fix CONFIG_DCA_MODULE DCA related fixes ================= - ixgbe was not compiling and using DCA correctly if dca was a module - DCA interface changed with new kernel - ixgbe was not correctly configured to indicate DCA hints to the correct CPU. Signed-off-by: Jesse Brandeburg Signed-off-by: Jeff Kirsher Signed-off-by: Jeff Garzik commit 22f32b7a5ad34f23eb18f0e089522f1652ae8abc Author: Jesse Brandeburg Date: Tue Aug 26 04:27:18 2008 -0700 ixgbe: should not use HW_CSUM, should use IP* flags as mentioned by Herbert, our hardware supports IP offloads, not full checksum offloads for any protocol in existence (even though the hardware just provides generic csum support over any range of bytes) Signed-off-by: Jesse Brandeburg Signed-off-by: Jeff Kirsher Signed-off-by: Jeff Garzik commit 7c6e0a436d971641d37cebcb12e8cc0c4419b5d4 Author: Jesse Brandeburg Date: Tue Aug 26 04:27:16 2008 -0700 ixgbe: Lock RSS seed, move rx_buf_len to the rx_ring This locks the seed down so loading/unloading the driver will present predictable hashing from RSS. Also move the rx_buf_len out of the adapter struct, and into the Rx ring struct. Signed-off-by: Jesse Brandeburg Signed-off-by: Peter P Waskiewicz Jr Signed-off-by: Jeff Kirsher Signed-off-by: Jeff Garzik commit e01c31a5f7eb4f8a147cf6205f0f2ef11146068d Author: Jesse Brandeburg Date: Tue Aug 26 04:27:13 2008 -0700 ixgbe: Implement Tx Head Writeback Enable Tx Head Writeback in the hardware. This helps performance by removing adapter writebacks to descriptors on transmit completion. Signed-off-by: Jesse Brandeburg Signed-off-by: Peter P Waskiewicz Jr Signed-off-by: Jeff Kirsher Signed-off-by: Jeff Garzik commit 2b9ade935cd2be6db26f5445656950bc3da7055d Author: Jesse Brandeburg Date: Tue Aug 26 04:27:10 2008 -0700 ixgbe: disable flow control by default Since the adapter cannot tell what the remote end's flow control capability is through auto-neg, we must turn off flow control by default. Signed-off-by: Jesse Brandeburg Signed-off-by: Jeff Kirsher Signed-off-by: Jeff Garzik commit 3a581073e0f9f3966ac95a89cd04a0a6b948dc77 Author: Jesse Brandeburg Date: Tue Aug 26 04:27:08 2008 -0700 ixgbe: Cleanup references to Tx and Rx rings to becommon across the driver Cleanup all the different references to the Tx ring and Rx ring structures and make them common across the driver. Signed-off-by: Jesse Brandeburg Signed-off-by: Peter P Waskiewicz Jr Signed-off-by: Jeff Kirsher Signed-off-by: Jeff Garzik commit 036c9b097034b4ea82974f7c98d10ec7fbf81902 Author: Jesse Brandeburg Date: Tue Aug 26 04:27:05 2008 -0700 ixgbe: do not update stats twice each receive Signed-off-by: Jesse Brandeburg Signed-off-by: Jeff Kirsher Signed-off-by: Jeff Garzik commit 2c5645cf65dc6dce15dac47a7cdfabb85224fede Author: Christopher Leech Date: Tue Aug 26 04:27:02 2008 -0700 ixgbe: Implement HAVE_SET_RX_MODE Implement HAVE_SET_RX_MODE in the driver for MC and UC lists. Signed-off-by: Christopher Leech Signed-off-by: Peter P Waskiewicz Jr Signed-off-by: Jeff Kirsher Signed-off-by: Jeff Garzik commit 9da09bb1b806a85a0bc4fb5426fb3022f56aad19 Author: Jesse Brandeburg Date: Tue Aug 26 04:26:59 2008 -0700 ixgbe: add little endian annotations for sparse Signed-off-by: Jesse Brandeburg Signed-off-by: Jeff Kirsher Signed-off-by: Jeff Garzik commit 712744bebef1e47623244004a2770d0438b5b3f7 Author: Jesse Brandeburg Date: Tue Aug 26 04:26:56 2008 -0700 ixgbe: fix rx csum return status misinterpretation the driver was misinterpreting rx_csum return value in the descriptor so occassionally we would indicate an rx_csum error in our stats when there was none. This would have no effect on traffic because we would just hand the packet to the stack anyway without the offload flag set, but would increase CPU for those packets that needed a recompute. Signed-off-by: Jesse Brandeburg Signed-off-by: Jeff Kirsher Signed-off-by: Jeff Garzik commit fa928c0caa9cb1ebc2fb6717b2f7bb73dd4f487c Author: roel kluin Date: Sat Aug 30 22:48:24 2008 +0200 ibm_newemac: MAL[12]_IER_EVENTS definition: 2x *_OTE -> *_DE MAL[12]_IER_EVENTS definitions have MAL_IER_OTE twice but lack MAL_IER_DE Signed-off-by: Roel Kluin Signed-off-by: Jeff Garzik commit 8dcc61ac32e8c2170c10ea7f2ccc473d28fcbbc5 Author: Randy Dunlap Date: Tue Sep 2 13:03:44 2008 -0700 hp-plus: fix link objects Fix hp-plus Makefile object file: drivers/built-in.o: In function `hpp_open': hp-plus.c:(.text+0xaf445): undefined reference to `ei_interrupt' hp-plus.c:(.text+0xaf4ac): undefined reference to `ei_open' drivers/built-in.o: In function `hpp_close': hp-plus.c:(.text+0xaf59d): undefined reference to `ei_close' drivers/built-in.o: In function `hpp_probe1': hp-plus.c:(.init.text+0x7314): undefined reference to `ei_poll' drivers/built-in.o: In function `hp_plus_probe': (.init.text+0x7407): undefined reference to `__alloc_ei_netdev' make[1]: *** [.tmp_vmlinux1] Error 1 Signed-off-by: Randy Dunlap Signed-off-by: Jeff Garzik commit f14c4e4e3651b76ae09082fa66cda37e10ac2b43 Author: Brian Haley Date: Tue Sep 2 10:08:08 2008 -0400 bonding: change some __constant_htons() to htons() Resending since I didn't see any responses from the first try. Change __constant_htons() to htons() in the bonding driver, it should only be used for initializers. -Brian Signed-off-by: Brian Haley Signed-off-by: Jeff Garzik commit a816f75ac5caa79b08325e35317f964f03841d52 Author: Ben Hutchings Date: Mon Sep 1 12:49:12 2008 +0100 sfc: Rework efx_set_multicast_hash() When !port_enabled, defer the write to reconfigure_mac_wrapper. Whilst here, simplify the logic now that efx_start_port() always calls efx_reconfigure_port(). From: Steve Hodgson Signed-off-by: Ben Hutchings Signed-off-by: Jeff Garzik commit 3c78708fe83d0fff994683e396e28ef259b7497b Author: Ben Hutchings Date: Mon Sep 1 12:49:08 2008 +0100 sfc: Remove the STATE_RESETTING flag This was originally a kludge to fix broken locking, which has since been fixed properly. Signed-off-by: Ben Hutchings Signed-off-by: Jeff Garzik commit 8c8661e4cefdd1ddbfe7d5120f046694555d9e5c Author: Ben Hutchings Date: Mon Sep 1 12:49:02 2008 +0100 sfc: Extend self-tests Include PMA/PMD in loopback self-tests as intended. Add NVRAM checksum validation and include it in self-tests. Add register self-tests. Run PHY self-tests where available. Signed-off-by: Ben Hutchings Signed-off-by: Jeff Garzik commit a515089c963b045f65c495cee1d344d8cb75e1d1 Author: Ben Hutchings Date: Mon Sep 1 12:48:55 2008 +0100 sfc: Rework the bitfield header so that we can identify fields by bit number This will support register self-tests. From: Steve Hodgson Signed-off-by: Ben Hutchings Signed-off-by: Jeff Garzik commit 2467ca46b6bb7672ed59fc74ac6780bf10bcd742 Author: Ben Hutchings Date: Mon Sep 1 12:48:50 2008 +0100 sfc: Cleanup reset code Move more code from efx_reset() into efx_reset_down() and efx_reset_up(). Stop propagating MAC/PHY setting failures from efx_reset_down() and efx_reset_up() as these should not be fatal. Signed-off-by: Ben Hutchings Signed-off-by: Jeff Garzik commit bc3c90a2b70652b87cde8de65275d6f41d0f24c3 Author: Ben Hutchings Date: Mon Sep 1 12:48:46 2008 +0100 sfc: Remove some unreachable error paths Some functions return an error code which is always 0. Change their return types to void and simplify their callers accordingly. Signed-off-by: Ben Hutchings Signed-off-by: Jeff Garzik commit c1e5fcc980b7b2185b29e4f9f0d8266806ada9eb Author: Ben Hutchings Date: Mon Sep 1 12:48:41 2008 +0100 sfc: Remove remnants of multi-port abstraction for MAC registers Signed-off-by: Ben Hutchings Signed-off-by: Jeff Garzik commit 01aad7b6ffcc07544e7bdf472fbde4e6eb36a610 Author: Ben Hutchings Date: Mon Sep 1 12:48:36 2008 +0100 sfc: Remove efx_nic_dummy_op_int() as redundant with efx_port_dummy_op_int() Update comment on the dummy operation implementations. Line up the board operation initialisers. Signed-off-by: Ben Hutchings Signed-off-by: Jeff Garzik commit 740847dab16b1a410a0f833df2bf21c8ed8265f3 Author: Ben Hutchings Date: Mon Sep 1 12:48:23 2008 +0100 sfc: Enable TSO for 802.1q VLAN devices Signed-off-by: Ben Hutchings Signed-off-by: Jeff Garzik commit dacccc741164edf95fb13dbf5eedb96fb94f7290 Author: Steve Hodgson Date: Mon Sep 1 12:48:20 2008 +0100 sfc: Do not call netif_{stop,wake}_queue() before register_netdev Signed-off-by: Ben Hutchings Signed-off-by: Jeff Garzik commit f8b87c17017f2ce1890fb9a7f85fb0fbf5643e37 Author: Ben Hutchings Date: Mon Sep 1 12:48:17 2008 +0100 sfc: Make PHY flash mode a device attribute, not a module parameter This allows updating PHY firmware for one interface without removing all other interfaces handled by the driver. Replace tx_disabled flags and 10Xpress status enumeration with flags in enum efx_phy_mode. Prevent an interface from being brought up while in PHY flash mode. Signed-off-by: Ben Hutchings Signed-off-by: Jeff Garzik commit 3594e131b23665b728b4c98daaf0b61b1d4aaa7a Author: Ben Hutchings Date: Mon Sep 1 12:48:12 2008 +0100 sfc: Implement get_sset_count, replacing get_stats_count and self_test_count Signed-off-by: Ben Hutchings Signed-off-by: Jeff Garzik commit 42cbe2d73c9bc2574f86d63c2b57da93e3b3060d Author: Ben Hutchings Date: Mon Sep 1 12:48:08 2008 +0100 sfc: Cleanup RX event processing Make efx_process_channel() and falcon_process_eventq() return the number of packets received rather than updating the quota, consistent with new NAPI. Since channels and RX queues are mapped one-to-one, remove return value from falcon_handle_rx_event() and add a warning for events with the wrong RX queue number. Signed-off-by: Ben Hutchings Signed-off-by: Jeff Garzik commit d3074025345ae27fbb076a92425f28b40b6fa4c0 Author: Ben Hutchings Date: Mon Sep 1 12:48:03 2008 +0100 sfc: Remove efx_channel::evqnum field It is redundant with efx_channel::channel. Signed-off-by: Ben Hutchings Signed-off-by: Jeff Garzik commit a2589027ff0011077cdaf761be3a9a4ba40b5118 Author: Ben Hutchings Date: Mon Sep 1 12:47:57 2008 +0100 sfc: Make efx_for_each_channel_rx_queue() more efficient Currently each channel can have at most one RX queue, so go straight to that one. Signed-off-by: Ben Hutchings Signed-off-by: Jeff Garzik commit 955f0a744bf2d2192cb49b2eccffbc02a4adc401 Author: Ben Hutchings Date: Mon Sep 1 12:47:52 2008 +0100 sfc: Remove initialisation of RX_FILTER_CTL_REG.NUM_KER We have long since given up doing RSS on Falcon A1 and therefore we would always write the default value of 0. Signed-off-by: Ben Hutchings Signed-off-by: Jeff Garzik commit 8831da7b6c4b15c0be0ba849be4aea5eed3999c6 Author: Ben Hutchings Date: Mon Sep 1 12:47:48 2008 +0100 sfc: Cleanup RX queue information Rename efx_nic::rss_queues to the more obvious n_rx_queues Remove efx_rx_queue::used and other stuff that's redundant with it. Signed-off-by: Ben Hutchings Signed-off-by: Jeff Garzik commit 64ee3120f73b9e904d97ba66386b1e8e93b81385 Author: Ben Hutchings Date: Mon Sep 1 12:47:38 2008 +0100 sfc: Remove efx_channel::has_interrupt efx_channel::has_interrupt is redundant with efx_channel::used_flags. Remove efx_test_eventq() because it is now obviously unreachable. Signed-off-by: Ben Hutchings Signed-off-by: Jeff Garzik commit 46123d043d4bab23aa0d22f33972ee52cfac7f68 Author: Ben Hutchings Date: Mon Sep 1 12:47:33 2008 +0100 sfc: Move CPU counting for RSS into a separate function, efx_wanted_rx_queues() Signed-off-by: Ben Hutchings Signed-off-by: Jeff Garzik commit 4a5b504d0c582db80813b70359b616ea30e91743 Author: Ben Hutchings Date: Mon Sep 1 12:47:16 2008 +0100 sfc: Export boot configuration in EEPROM through ethtool Extend the SPI device setup code to support this. Signed-off-by: Ben Hutchings Signed-off-by: Jeff Garzik commit 4d566063a799231b99d9a21128634ea78b89ab72 Author: Ben Hutchings Date: Mon Sep 1 12:47:12 2008 +0100 sfc: Removed forced inlining of long functions gcc will automatically inline static functions with only one caller, and may inline other functions depending on the kernel configuration and size of the intermediate code. Signed-off-by: Ben Hutchings Signed-off-by: Jeff Garzik commit 23d9e60b1ddc67ffedd77161ecff4895708088a4 Author: Ben Hutchings Date: Mon Sep 1 12:47:02 2008 +0100 sfc: Cleaned up struct tso_state fields Squashed nested structures. Renamed remaining_len to out_len, ifc.len to in_len, header_length to header_len. Moved ipv4_id into the group of output variables where it belongs. Signed-off-by: Ben Hutchings Signed-off-by: Jeff Garzik commit 28506563e22a3ec7cf86e5acd853af8e68fe148b Author: Ben Hutchings Date: Mon Sep 1 12:46:54 2008 +0100 sfc: Set net_device::vlan_features appropriately Signed-off-by: Ben Hutchings Signed-off-by: Jeff Garzik commit dc8cfa55da8c21e0b3290c29677a9d05c0a3e595 Author: Ben Hutchings Date: Mon Sep 1 12:46:50 2008 +0100 sfc: Use explicit bool for boolean variables, parameters and return values Replace (cond ? 1 : 0) with cond or !!cond as appropriate, and (cond ? 0 : 1) with !cond. Remove some redundant boolean temporaries. Rename one field that looks like a flag but isn't. Signed-off-by: Ben Hutchings Signed-off-by: Jeff Garzik commit cc12dac2e512c2b6185ed91899e09e9910630315 Author: Ben Hutchings Date: Mon Sep 1 12:46:43 2008 +0100 sfc: Reduce the size of struct efx_tx_buffer Remove unmap_addr since it can be calculated from dma_addr, len and unmap_len. This saves 4-16 bytes. Signed-off-by: Ben Hutchings Signed-off-by: Jeff Garzik commit ecbd95c17c221913cc3c5776051b2fa8b3b97316 Author: Ben Hutchings Date: Mon Sep 1 12:46:40 2008 +0100 sfc: Use pci_map_single() to map the skb header when doing TSO Signed-off-by: Ben Hutchings Signed-off-by: Jeff Garzik commit 5988b63a53e120a9db4439d4512f4c1b17e7170e Author: Ben Hutchings Date: Mon Sep 1 12:46:36 2008 +0100 sfc: Don't leak PCI DMA maps in the TSO code when the queue fills up Signed-off-by: Ben Hutchings Signed-off-by: Jeff Garzik commit b9aafb0e91a079ff9438ce3c532ea46d4cd2f0fc Author: Ben Hutchings Date: Mon Sep 1 12:46:33 2008 +0100 sfc: Speed up loopback self-test Add efx_poll_loopback() function to test for successful completion of test. Change efx_test_loopback() to end the test after 1 ms if efx_poll_loopback() indicates success, and otherwise to wait for 100 ms as before. While we're here, rename efx_{rx,tx}_loopback() to efx_{begin,end}_loopback() which more accurately reflect their purpose. Signed-off-by: Ben Hutchings Signed-off-by: Jeff Garzik commit f8ea0b6743f00180ee3260d82f383a02a4dd9a78 Author: Ben Hutchings Date: Mon Sep 1 12:46:28 2008 +0100 sfc: Self-test reporting cleanup Removed log messages that are redundant with calling functions. Fixed bitwise or-ing of return codes. Signed-off-by: Ben Hutchings Signed-off-by: Jeff Garzik commit e9713e6f4eb55a73c39a72fb8067fd053cdf8e95 Author: Ben Hutchings Date: Mon Sep 1 12:46:25 2008 +0100 sfc: Reduce log level for XGXS lane status This was making noise during 10Xpress self-test. Signed-off-by: Ben Hutchings Signed-off-by: Jeff Garzik commit c84a6f18a957204138330283461dba033cc9ed52 Author: Ben Hutchings Date: Mon Sep 1 12:46:21 2008 +0100 sfc: Reverse the XOFF/XON pause frame control fifo thresholds These were clearly bogus. From: Steve Hodgson Signed-off-by: Ben Hutchings Signed-off-by: Jeff Garzik commit f90748f009966caa2d004d84ce4b585b5cffb3e8 Author: Ben Hutchings Date: Mon Sep 1 12:46:16 2008 +0100 sfc: Remove inclusion of workarounds.h from efx.c efx.c does not use hardware workarounds. Signed-off-by: Ben Hutchings Signed-off-by: Jeff Garzik commit c264361d31bec0a444e0c4ffd40479e66eef6c15 Author: Ben Hutchings Date: Mon Sep 1 12:46:10 2008 +0100 sfc: XMAC statistics fix-ups Exclude assumed size of RX control frames from rx_bad_bytes. Exclude assumed size of TX control frames from tx_good_bytes for consistency with rx_good_bytes. Signed-off-by: Ben Hutchings Signed-off-by: Jeff Garzik commit 5b39fe307b58fc6d71265eeed809ab799a2e2ec9 Author: Ben Hutchings Date: Mon Sep 1 12:46:03 2008 +0100 sfc: Remove mistaken hardware workaround We believed that some valid SNAP frames were being marked as invalid. In fact this is not the case and no workaround is needed. Signed-off-by: Ben Hutchings Signed-off-by: Jeff Garzik commit 11f34e691d6b3501606a9eaf5379ec718d2fabeb Author: Ben Hutchings Date: Mon Sep 1 12:45:48 2008 +0100 sfc: Reduce delays in SFE4001 initialisation Currently the board initialisation includes 2 delays of 1 second each. Usually it is unnecessary to wait that long, so check before doing so. Correct some of the comments and log messages while we're here. Signed-off-by: Ben Hutchings Signed-off-by: Jeff Garzik commit a0c2c19093bb326ecce4231e558f92e1e7985e37 Author: Ben Hutchings Date: Mon Sep 1 12:45:08 2008 +0100 sfc: Avoid mangling error codes in efx_test_loopback() efx_test_loopback() used "|" to combine the results of the RX and TX phases. If both phases fail with different error codes, this results in a bogus error code. Signed-off-by: Ben Hutchings Signed-off-by: Jeff Garzik commit 60ac10658c2e234cf7bc27e0930e324c6c6fcf61 Author: Ben Hutchings Date: Mon Sep 1 12:44:59 2008 +0100 sfc: Use separate hardware TX queues to select checksum generation Checksum generation is an attribute of our hardware TX queues, not TX descriptors. We previously used a single queue and turned checksum generation on or off as requested through ethtool. However, this can result in regenerating checksums in raw packets that should not be modified. We now create 2 hardware TX queues with checksum generation on or off. They are presented to the net core as one queue since it does not know how to select between them. The self-test verifies that a bad checksum is unaltered on the queue with checksum generation off. Signed-off-by: Ben Hutchings Signed-off-by: Jeff Garzik commit 26c086771a8ad0a1a72699674fa712fe6aeacb02 Author: Steve Hodgson Date: Mon Sep 1 12:44:48 2008 +0100 sfc: Remove unused field efx_channel::reset_work Signed-off-by: Ben Hutchings Signed-off-by: Jeff Garzik commit 18c2fc0478d5eff08d78bf28635004ec9a9b3946 Author: Ben Hutchings Date: Mon Sep 1 12:43:39 2008 +0100 sfc: Change first parameter type of {set,clear}_bit_le() to unsigned This means the compiler doesn't need to use real division instructions. Signed-off-by: Ben Hutchings Signed-off-by: Jeff Garzik commit 767e468c06fc0e88f95881c1056437688b37c7c6 Author: Ben Hutchings Date: Mon Sep 1 12:43:14 2008 +0100 sfc: Replace net_dev->priv with netdev_priv(net_dev) Use of the net_device::priv field is deprecated. Signed-off-by: Ben Hutchings Signed-off-by: Jeff Garzik commit f72f87666264c9d4880166bcc69cb5c4cf210449 Author: Harvey Harrison Date: Tue Sep 2 18:05:43 2008 +0200 HID: make compat functions static Done to avoid sparse warnings about undeclared functions. Signed-off-by: Harvey Harrison Signed-off-by: Jiri Kosina commit 6da917c00e972e9b7c3d60009a5d7775edf6acea Author: Sergey Belyashov Date: Tue Sep 2 17:31:16 2008 +0200 HID: Autocentering support for Logitech MOMO Racing Wheel Current kernel has no support for autocentering for Logitech wheels. By default autocentering enabled in wheel and constant effect does not work properly. Using USB sniffer I found command which change autocentering settings: 0xFE, 0x0D, 0x0R, 0x0L, 0x80, 0x00, 0x00, where R - clockwise force, L - counter-clockwise (0x0-0xF, 0xC = 100%). Signed-off-by: Sergey Belyashov Signed-off-by: Jiri Kosina commit 6b59827c746e54141a6c3d294af70b84e2061832 Author: Alex Chiang Date: Wed Aug 27 13:36:18 2008 +0200 HID: fix grammo in HID_COMPAT Kconfig help text The Kconfig option for HID_COMPAT should read "lose", not "loose". Signed-off-by: Alex Chiang Signed-off-by: Jiri Kosina commit f8cf14c82c05ad40227f19134fe0826d0515f55a Author: Jiri Kosina Date: Wed Aug 27 11:21:42 2008 +0200 HID: add support for Super Dual Box Pro USB PS2/PS2 adapter This seems to be the very same device, as already supported Smartjoy dual Plus, but with slightly different vendor ID. Let's support this one too. Reported-by: David Ashley Signed-off-by: Jiri Kosina commit 73b04d6af6b0b901573d4a257cfeb048ade401c4 Author: Richard Hughes Date: Wed Aug 27 11:19:37 2008 +0200 HID: remove ignore quirk for MGE UPS devices This patch reverts the change made four years ago here: http://www.vg.kernel.org/pub/linux/kernel/people/gregkh/usb/2.4/usb-hid-2.4.25-pre7.patch UPS's made by MGE can be used with usbhid just fine, and by removing the ignore quirk allows them to be used with HAL so they just work when plugged in, without needing to be manually configured. With the ignore quirk in place a user would have to configure NUT before the UPS could be used, as NUT uses it's own internal USB matching framework to match against the USB devices, do low level control messages on the device and then parse the HID tables all in userspace. This is not needed, as allowing the device to be claimed as a usbhid device allows it to be used like any other USB UPS device. The devices correctly advertise the power device page which can be queried for the device state. I assume the quirk was changed so that people using < libusb 0.1.8 could still use NUT's internal HID code to manage the UPS. libusb 0.1.8 was released quite some time ago: 2004-02-11. This patch does not break NUT as in drivers/libusb.c the device is force unbound from the kernel driver using usb_detach_kernel_driver_np () where it can be controlled like normal. [jkosina@suse.cz: adapt to the new hidbus code] Signed-off-by: Richard Hughes Signed-off-by: Jiri Kosina commit 86a5d78f0dd3b2d2c24601a6ceab75afc367f9be Author: Jiri Kosina Date: Wed Aug 20 19:13:52 2008 +0200 HID: introduce list for hiddev creation forcing Introduce a list of devices for which there is need to force a creation of the hiddev interface, but still they are operated by generic driver (i.e. certain UPS). Signed-off-by: Jiri Kosina commit 691110113eef7733ef66a002816c74b887849fb6 Author: Jiri Slaby Date: Fri Jul 4 23:06:45 2008 +0200 HID: move logitech FF processing Merge the logitech force feedback processing directly into logitech driver from the usbhid core. Signed-off-by: Jiri Slaby Signed-off-by: Jiri Kosina commit f0f914bad291ec73320201b6731a38848536145d Author: Jiri Slaby Date: Fri Jun 27 20:41:02 2008 +0200 HID: move reset leds quirk Move the handling of the leds resetting from the core to the dell and logitech drivers. Signed-off-by: Jiri Slaby Signed-off-by: Jiri Kosina commit 0f0832ac19c158575f91de247d6c448e82bb9567 Author: Jiri Slaby Date: Fri Jun 27 00:04:24 2008 +0200 HID: move connect quirks Move connecting from usbhid to the hid layer and fix also hidp in that manner. This removes all the ignore/force hidinput/hiddev connecting quirks. Signed-off-by: Jiri Slaby Signed-off-by: Jiri Kosina commit e980e0ca3d22620439d4fd9c6de5b907faf49c67 Author: Jiri Slaby Date: Thu Jun 26 22:25:33 2008 +0200 HID: move dell quirks Signed-off-by: Jiri Slaby Signed-off-by: Jiri Kosina commit 74361fb73e2a5a9ebace355e1e36b8b4e743f198 Author: Jiri Slaby Date: Wed Jun 25 23:47:04 2008 +0200 HID: move sony quirks Signed-off-by: Jiri Slaby Signed-off-by: Jiri Kosina commit 33c9af57f02025ed0cd796625744a67e5b755ff6 Author: Jiri Slaby Date: Wed Jun 25 23:03:55 2008 +0200 HID: remove rdesc quirk support Remove support for both dynamic and static report descriptor quirks. There is no longer rdesc code which it would support, so it's useless. Signed-off-by: Jiri Slaby Signed-off-by: Jiri Kosina commit 764293b188ff6bfe699771b87c3d4492d4cebe21 Author: Jiri Slaby Date: Thu Jul 31 11:09:37 2008 +0200 HID: remove hid-input-quirks Remove the file since these is no user now. Signed-off-by: Jiri Slaby Signed-off-by: Jiri Kosina commit e268e7ac54b13ebb67813ad010ab80858b3c1abe Author: Jiri Slaby Date: Wed Jun 25 22:31:48 2008 +0200 HID: move samsung quirks Signed-off-by: Jiri Slaby Signed-off-by: Jiri Kosina commit f35cf21f52726856f7a91919b3ee0be8d5d26d29 Author: Jiri Slaby Date: Thu Jul 24 23:35:13 2008 +0200 HID: move gyration quirks Signed-off-by: Jiri Slaby Signed-off-by: Jiri Kosina commit b08dbdafdc1b7204bc65575014b686dde73053b1 Author: Jiri Slaby Date: Wed Jun 25 00:07:50 2008 +0200 HID: move monterey quirks Signed-off-by: Jiri Slaby Signed-off-by: Jiri Kosina commit 42a2a80cc14bd810a36be3b12fb56c4489c5ebfa Author: Jiri Slaby Date: Tue Jun 24 23:46:21 2008 +0200 HID: move petalynx quirks Signed-off-by: Jiri Slaby Signed-off-by: Jiri Kosina commit 26436655be8ac4e7fa833e105fe04f9f6bf2db29 Author: Jiri Slaby Date: Tue Jun 24 23:24:57 2008 +0200 HID: move belkin quirks Signed-off-by: Jiri Slaby Signed-off-by: Jiri Kosina commit d0183dc54140fd1de5b7b0aeb8a89053d1be4240 Author: Jiri Slaby Date: Tue Jun 24 22:48:52 2008 +0200 HID: move chicony quirks Signed-off-by: Jiri Slaby Signed-off-by: Jiri Kosina commit 051846dda9c90e84abf20ef1a285237840a85d77 Author: Jiri Slaby Date: Tue Jun 24 21:11:21 2008 +0200 HID: move ezkey quirks Signed-off-by: Jiri Slaby Signed-off-by: Jiri Kosina commit 2623b83c1dfdaeb5ee0cceb31c2ce0d5dd0b147a Author: Jiri Slaby Date: Tue Jun 24 20:42:25 2008 +0200 HID: move cherry quirks Signed-off-by: Jiri Slaby Signed-off-by: Jiri Kosina commit 17dcc82779fc3bbac532ca5b1d8540680f02577b Author: Jiri Slaby Date: Mon Jun 23 23:31:09 2008 +0200 HID: move a4tech quirks Signed-off-by: Jiri Slaby Signed-off-by: Jiri Kosina commit a01c41a016ff16f7a7ce5605b2b309eedd43fd32 Author: Jiri Slaby Date: Mon Jun 23 22:54:08 2008 +0200 HID: move cypress quirks Signed-off-by: Jiri Slaby Signed-off-by: Jiri Kosina commit 6a7dcbfedd3b20b0840d377fac09c55fbed54da3 Author: Jiri Slaby Date: Mon Jun 23 21:56:07 2008 +0200 HID: move sunplus quirks Signed-off-by: Jiri Slaby Signed-off-by: Jiri Kosina commit 23ab30b123edce971a1db46a73d869d1c74f64c0 Author: Jiri Slaby Date: Fri Jun 20 21:26:11 2008 +0200 HID: move microsoft quirks Move them from the core code to a separate driver. Signed-off-by: Jiri Slaby Signed-off-by: Jiri Kosina commit 73509b82436d20837349796df311d0554deecc4b Author: Jiri Slaby Date: Wed Jun 18 23:55:41 2008 +0200 HID: indent switches/cases Bring switch and cases into coding style and save thus some indentation to make the code tighter. Signed-off-by: Jiri Slaby Signed-off-by: Jiri Kosina commit 73d27c0570af782859fb77f77df3b820519eefbe Author: Jiri Slaby Date: Fri May 16 11:49:22 2008 +0200 HID: add compat support Add compat option to hid code to allow loading of all modules on systems which don't allow autoloading because of old userspace. Signed-off-by: Jiri Slaby Signed-off-by: Jiri Kosina [default y fixup] Signed-off-by: Jiri Kosina commit a61c5b2f615337b5029e573d4bbbd985bd9af7a4 Author: Jiri Slaby Date: Wed Jun 18 23:36:49 2008 +0200 HID: move apple quirks Move them from the core code to a separate driver. Signed-off-by: Jiri Slaby Signed-off-by: Jiri Kosina commit 3d871488a6c2423d5e979bd6aa102d9156c96b2a Author: Jiri Slaby Date: Fri May 16 11:49:20 2008 +0200 HID: move ignore quirks Move ignore quirks from usbhid-quirks into hid-core code. Also don't output warning when ENODEV is error code in usbhid and try ordinal input in hidp when that error is returned. Signed-off-by: Jiri Slaby Signed-off-by: Jiri Kosina commit c93e29e40d96dfedcf0de097c0a11c3712d3bc26 Author: Jiri Slaby Date: Fri May 16 11:49:19 2008 +0200 HID: move logitech quirks Move them from the core and input code to a separate driver. Signed-off-by: Jiri Slaby Signed-off-by: Jiri Kosina commit b219a51cffb2cea07d3ac1959a993fbd97cb4e1b Author: Jiri Slaby Date: Fri May 16 11:49:18 2008 +0200 HID: move usage input mapping to hid.h This mapping are currently used on 2 placces and will be needed by more quirk drivers, so move them to hid.h to allow them to use it. Signed-off-by: Jiri Slaby Signed-off-by: Jiri Kosina commit 7b5a86b75705442b86c2723d1eadab50ccdd338e Author: Jiri Slaby Date: Wed Jun 4 11:02:56 2008 +0200 HID: move ids into separate file Move ids from hid-quirks.c into separate file, since it will be needed in more than one place. Signed-off-by: Jiri Slaby Signed-off-by: Jiri Kosina commit 4dfd56b0ea81537d51e6fe2ad9140456bb0ca615 Author: Jiri Slaby Date: Fri May 16 11:49:16 2008 +0200 HID: hid, make parsing event driven Next step for complete hid bus, this patch includes: - call parser either from probe or from hid-core if there is no probe. - add ll_driver structure and centralize some stuff there (open, close...) - split and merge usb_hid_configure and hid_probe into several functions to allow hooks/fixes between them Signed-off-by: Jiri Slaby Signed-off-by: Jiri Kosina commit 8292d5e0a80eb1ddc1ca59154df5a20233286861 Author: Jiri Slaby Date: Fri May 16 11:49:15 2008 +0200 HID: make a bus from hid code Make a bus from hid core. This is the first step for converting all the quirks and separate almost-drivers into real drivers attached to this bus. It's implemented to change behaviour in very tiny manner, so that no driver needs to be changed this time. Also add generic drivers for both usb and bt into usbhid or hidp respectively which will bind all non-blacklisted device. Those blacklisted will be either grabbed by special drivers or by nobody if they are broken at the very rude base. Signed-off-by: Jiri Slaby Signed-off-by: Jiri Kosina commit 8c7e2ca031f4bbc46f5f4920fb27728e8b388257 Author: Jiri Slaby Date: Mon May 19 15:50:01 2008 +0200 modpost: add support for hid Generate aliases for hid device modules to support autoloading. Signed-off-by: Jiri Slaby Signed-off-by: Jiri Kosina commit 7c7cbadf7341a0792879c67d6e3020f040d6cd7f Author: Artem Bityutskiy Date: Wed Sep 3 14:16:42 2008 +0300 UBIFS: amend f_fsid David Woodhouse suggested to be consistent with other FSes and xor the beginning and the end of the UUID. Signed-off-by: Artem Bityutskiy commit c3614df7f7f778b955934fdccf1907b4edd6dd81 Author: Nikolaus Voss Date: Wed Sep 3 12:50:32 2008 +0200 Add kernel support for oprofile callgraphs on AVR32 This patch adds backtracing capability to oprofile profiling in kernel and user mode on AVR32. This is done by going through the frames on the stack and adding oprofile traces for all return addresses. The code being profiled has to be compiled with frame pointers to make this work. Signed-off-by: Nikolaus Voss Signed-off-by: Haavard Skinnemoen commit 888d0514c648fa4f4d1a28cc643bbce010dd6bb7 Author: Cliff Cai Date: Wed Sep 3 10:54:36 2008 +0200 ALSA: add dummy function to support shared mmap in nommu Blackfin arch Cc: Mike Frysinger Signed-off-by: Cliff Cai Signed-off-by: Bryan Wu Signed-off-by: Takashi Iwai commit 69114a47af524badc73de8fc86959941a03f0600 Author: Russell King Date: Wed Sep 3 10:15:26 2008 +0100 [ARM] omap: fix gpio.c build error arch/arm/plat-omap/gpio.c: In function '_omap_gpio_init': arch/arm/plat-omap/gpio.c:1492: error: 'omap_mpuio_device' undeclared (first use in this function) Signed-off-by: Russell King commit 5280267c1dddb8d413595b87dc406624bb497946 Author: David S. Miller Date: Wed Sep 3 02:04:41 2008 -0700 sparc: Fix handling of LANCE and ESP parent nodes in of_device.c The device nodes that sit above 'esp' and 'le' on SBUS lack a 'ranges' property, but we should pass the translation up to the parent node so that the SBUS level ranges get applied. Based upon a bug report from Robert Reif. Signed-off-by: David S. Miller commit e02c58904900ccacc1fbe0c9423786e0e2e223c1 Author: David Woodhouse Date: Mon Sep 1 14:12:51 2008 +0100 S390: Update comments about why we don't use Signed-off-by: David Woodhouse commit 5fc7c732f0ab706eadb86a5a835f5626c9ff157e Author: David Woodhouse Date: Mon Sep 1 14:12:19 2008 +0100 SPARC: Use Signed-off-by: David Woodhouse commit 82c7bce9971a4f3bb6135e23e5883dba336d2155 Author: David Woodhouse Date: Mon Sep 1 14:11:47 2008 +0100 PowerPC: Use Signed-off-by: David Woodhouse commit 02b3fafb7977c16b16644940b370b57088d5c0ea Author: David Woodhouse Date: Mon Sep 1 14:11:27 2008 +0100 PARISC: Use Signed-off-by: David Woodhouse commit ca3d5aeed76dc0568687244a27a18ccc59d9d088 Author: David Woodhouse Date: Mon Sep 1 14:10:44 2008 +0100 x86_64: Use Signed-off-by: David Woodhouse commit 61139761e4b86a388ce1242fb050b2c8515b9ca1 Author: David Woodhouse Date: Mon Sep 1 14:10:03 2008 +0100 IA64: Use Signed-off-by: David Woodhouse commit 7ce48495ef51b8d8e97069166352dfe791e3f769 Author: David Woodhouse Date: Mon Sep 1 14:09:15 2008 +0100 ARM: Use Signed-off-by: David Woodhouse commit 2082ce79797827c5208b84220fa832fba71d0c55 Author: David Woodhouse Date: Mon Sep 1 14:07:11 2008 +0100 Make suitable for 64-bit platforms. At the moment, 64-bit platforms (other than Alpha) are all redefining things for themselves instead of using . As is ARM, since it has special requirements w.r.t. padding. Make more generic, and they can use it directly. Signed-off-by: David Woodhouse commit 57e4f5f945ea921393de152f9d6a68c332fcf300 Author: David Woodhouse Date: Wed Sep 3 09:49:20 2008 +0100 Define and use PCI_DEVICE_ID_MARVELL_88ALP01_CCIC for CAFÉ camera driver Also, stop looking at the NAND controller (0x4100) and checking the device class. For a while during development, all three functions on the chip had the same ID. We made them fix that fairly promptly, and we can forget about it now. Signed-off-by: David Woodhouse commit d4d7309593cb7fff10a3aa4bd9aa386fffbc9e29 Author: David Woodhouse Date: Wed Sep 3 09:47:17 2008 +0100 [MTD] [NAND] Define and use PCI_DEVICE_ID_MARVELL_88ALP01_NAND for CAFÉ Signed-off-by: David Woodhouse commit 11b95ebdf640df6686c25451b42e5fee75ce7b33 Author: David Woodhouse Date: Wed Sep 3 09:45:57 2008 +0100 Use PCI_DEVICE_ID_88ALP01 for CAFÉ chip, rather than PCI_DEVICE_ID_CAFE. Probably better to use the official designation. Signed-off-by: David Woodhouse commit 1bc3029e516e62baa14318888985075f3f3a9f7e Author: David Woodhouse Date: Wed Sep 3 09:53:52 2008 +0100 Blacklist DMAR on Intel G31/G33 chipsets Some BIOSes (the Intel DG33BU, for example) wrongly claim to have DMAR when they don't. Avoid the resulting crashes when it doesn't work as expected. Signed-off-by: David Woodhouse commit daea0386055056880bf555dc295dcb2f22f1ed4c Author: FUJITA Tomonori Date: Tue Sep 2 16:20:20 2008 +0900 sg: set dxferp to NULL for READ with the older SG interface With the older SG interface, we don't know a user-space address to trasfer data when executing a SCSI command. So we can't pass a user-space address to blk_rq_map_user. This patch fixes sg to pass a NULL user-space address to blk_rq_map_user so that it just sets up a request and bios with page frames propely without data transfer. Signed-off-by: FUJITA Tomonori Signed-off-by: Jens Axboe commit 106e768664adee9f8c4bf4c8c2a4d4daf66f4674 Author: FUJITA Tomonori Date: Tue Sep 2 16:20:19 2008 +0900 block: make blk_rq_map_user take a NULL user-space buffer This patch changes blk_rq_map_user to accept a NULL user-space buffer with a READ command if rq_map_data is not NULL. Thus a caller can pass page frames to lk_rq_map_user to just set up a request and bios with page frames propely. bio_uncopy_user (called via blk_rq_unmap_user) doesn't copy data to user space with such request. Signed-off-by: FUJITA Tomonori Signed-off-by: Jens Axboe commit d46811410fae03bacf23f1e8f74d4b64eb6594b5 Author: Jens Axboe Date: Tue Sep 2 09:25:21 2008 +0200 block: update comment on end_request() It refers to functions that no longer exist after the IO completion changes. Signed-off-by: Jens Axboe commit f378dd86374db21841c38057c398e149cf635c34 Author: Jens Axboe Date: Mon Sep 1 13:45:58 2008 +0200 block: only readd queue timeout timer if more requests are pending Signed-off-by: Jens Axboe commit c29752edead02f7d19373d9ea682320b73f2f0b2 Author: Tejun Heo Date: Mon Sep 1 13:44:35 2008 +0200 init: DEBUG_BLOCK_EXT_DEVT requires explicit root= param DEBUG_BLOCK_EXT_DEVT shuffles SCSI and IDE device numbers and root device number set using rdev become meaningless. Root devices should be explicitly specified using textual names. Warn about it if root can't be found and DEBUG_BLOCK_EXT_DEVT is enabled. Also, add warning to the help text. Signed-off-by: Tejun Heo Cc: Bartlomiej Zolnierkiewicz Signed-off-by: Jens Axboe commit 42864f170c402f5d9834abe0233f0af421603db6 Author: Jens Axboe Date: Fri Aug 29 13:39:21 2008 +0200 block: add IO completion race check in the timeout handler Since we only delete the timer when we free the request, it's possibly to end up in a situation where the timer fires and finds the request expired just because someone hasn't freed it yet, while IO completion has indeed run on the request. So check for residual data in the request before calling the timeout handler. Signed-off-by: Jens Axboe commit f82372151d7b24b91eeb3f1f4b2b7c86cc18074f Author: Jens Axboe Date: Fri Aug 29 13:30:37 2008 +0200 block: fix problem with request merging and timeout deletion In case of request merging, we fail freeing the request because we fail detaching the timeout timer. The timer isn't added at this time. So use ->deadline to determine whether the timer has been added or not. Get rid of __blk_complete_request(), we kill the timer on freeing the request. Signed-off-by: Jens Axboe commit de12c985922165d4380fad83f47025b6344c2cc0 Author: Tejun Heo Date: Fri Aug 29 11:41:51 2008 +0200 block: don't test for partition size in bdget_disk() and blk_lookup_devt() bdget_disk() and blk_lookup_devt() never cared whether the specified partition (or disk) is zero sized or not. I got confused while converting those not to depend on consecutive minor numbers in commit 5a6411b1178baf534aa9138052864dfa89d3eada and later when dev0 was added it broke callers which expected to get valid return for zero sized disk devices. So, they never needed nr_sects checks in the first place. Kill them. This problem was spotted and debugged by Bartlmoiej Zolnierkiewicz. Signed-off-by: Tejun Heo Cc: Bartlomiej Zolnierkiewicz Signed-off-by: Jens Axboe commit 638156bd6647702979ca4da93b32082b694d3710 Author: Mike Anderson Date: Fri Aug 29 09:36:09 2008 +0200 dm: Call blk_abort_queue on failed paths Signed-off-by: Mike Anderson Signed-off-by: Jens Axboe commit 8a1bd6c863a2a7ca4d7560dbc2f47b9e5740d6d7 Author: Mike Anderson Date: Fri Aug 29 09:35:40 2008 +0200 block: Add interface to abort queued requests Signed-off-by: Mike Anderson Signed-off-by: Jens Axboe commit f202dbc68cba797963cc449736bf78e9076e3793 Author: Jens Axboe Date: Fri Aug 29 09:34:21 2008 +0200 block: unify request timeout handling Right now SCSI and others do their own command timeout handling. Move those bits to the block layer. Signed-off-by: Mike Anderson Signed-off-by: Jens Axboe commit e2cde0d67fbc35cef4c7e4fc8c7dee29498c9681 Author: Jens Axboe Date: Fri Aug 29 09:06:29 2008 +0200 Change default value of CONFIG_DEBUG_BLOCK_EXT_DEVT to 'n' It's a debug option that you would explicitly enable to test this feature, we should default it to 'n' to prevent accidental surprises for now. Signed-off-by: Jens Axboe commit a237b1012ebae3acfa3c79a885a27d4dc33b011f Author: Harvey Harrison Date: Thu Aug 28 09:27:42 2008 +0200 block: kmalloc args reversed, small function definition fixes Noticed by sparse: block/blk-softirq.c:156:12: warning: symbol 'blk_softirq_init' was not declared. Should it be static? block/genhd.c:583:28: warning: function 'bdget_disk' with external linkage has definition block/genhd.c:659:17: warning: incorrect type in argument 1 (different base types) block/genhd.c:659:17: expected unsigned int [unsigned] [usertype] size block/genhd.c:659:17: got restricted gfp_t block/genhd.c:659:29: warning: incorrect type in argument 2 (different base types) block/genhd.c:659:29: expected restricted gfp_t [usertype] flags block/genhd.c:659:29: got unsigned int block: kmalloc args reversed Signed-off-by: Harvey Harrison Signed-off-by: Jens Axboe commit 949d88988e0ddec148266b577fd7b8af39506c2a Author: FUJITA Tomonori Date: Thu Aug 28 15:05:59 2008 +0900 sg: use blk_rq_aligned helper function Signed-off-by: FUJITA Tomonori Cc: Douglas Gilbert Cc: Jens Axboe Signed-off-by: Jens Axboe commit 9eae2b6ff238e4b922443057666aaf8cbf5aca0c Author: FUJITA Tomonori Date: Thu Aug 28 15:05:58 2008 +0900 block: add blk_rq_aligned helper function This adds blk_rq_aligned helper function to see if alignment and padding requirement is satisfied for DMA transfer. This also converts blk_rq_map_kern and __blk_rq_map_user to use the helper function. Signed-off-by: FUJITA Tomonori Cc: Jens Axboe Signed-off-by: Jens Axboe commit c68e8e6a9e67e37ced4ca01744738a7042985de2 Author: FUJITA Tomonori Date: Thu Aug 28 15:05:57 2008 +0900 bio: convert bio_copy_kern to use bio_copy_user bio_copy_kern and bio_copy_user are very similar. This converts bio_copy_kern to use bio_copy_user. Signed-off-by: FUJITA Tomonori Cc: Jens Axboe Signed-off-by: Jens Axboe commit 7f949580034c84eacd39ef522b5f5df08365c4c3 Author: FUJITA Tomonori Date: Fri Aug 29 12:32:18 2008 +0200 sg: convert the indirect IO path to use the block layer This patch converts the indirect IO path (including mmap IO and old struct sg_header) to use the block layer functions (blk_get_request, blk_execute_rq_nowait, blk_rq_map_user, etc) instead of scsi_execute_async(). [Jens: fixed compile error with SCSI logging enabled] Signed-off-by: FUJITA Tomonori Signed-off-by: Douglas Gilbert Cc: Mike Christie Cc: James Bottomley Signed-off-by: Jens Axboe commit ad2f2794723760aeaa51724880844b9a4b959269 Author: FUJITA Tomonori Date: Thu Aug 28 16:17:08 2008 +0900 sg: convert the direct IO path to use the block layer This patch converts the direct IO path (SG_FLAG_DIRECT_IO) to use the block layer functions (blk_get_request, blk_execute_rq_nowait, blk_rq_map_user, etc) instead of scsi_execute_async(). Signed-off-by: FUJITA Tomonori Signed-off-by: Douglas Gilbert Cc: Mike Christie Cc: James Bottomley Signed-off-by: Jens Axboe commit 769579306a77597d213848ea79b5c27be170b171 Author: FUJITA Tomonori Date: Thu Aug 28 16:17:07 2008 +0900 sg: convert the non-data path to use the block layer This patch converts the non data path to use the block layer functions (blk_get_request, blk_execute_rq_nowait, etc) instead of uses scsi_execute_async(). Signed-off-by: FUJITA Tomonori Signed-off-by: Douglas Gilbert Cc: Mike Christie Cc: James Bottomley Signed-off-by: Jens Axboe commit 05ada5d7803c2ed73eb0431774cef719af230d0b Author: FUJITA Tomonori Date: Thu Aug 28 16:17:06 2008 +0900 block: introduce struct rq_map_data to use reserved pages This patch introduces struct rq_map_data to enable bio_copy_use_iov() use reserved pages. Currently, bio_copy_user_iov allocates bounce pages but drivers/scsi/sg.c wants to allocate pages by itself and use them. struct rq_map_data can be used to pass allocated pages to bio_copy_user_iov. The current users of bio_copy_user_iov simply passes NULL (they don't want to use pre-allocated pages). Signed-off-by: FUJITA Tomonori Cc: Jens Axboe Cc: Douglas Gilbert Cc: Mike Christie Cc: James Bottomley Signed-off-by: Jens Axboe commit ff2e6a6d9dc4fd8711c571d9bcffcc15b1e4cf64 Author: FUJITA Tomonori Date: Thu Aug 28 16:17:05 2008 +0900 block: add gfp_mask argument to blk_rq_map_user and blk_rq_map_user_iov Currently, blk_rq_map_user and blk_rq_map_user_iov always do GFP_KERNEL allocation. This adds gfp_mask argument to blk_rq_map_user and blk_rq_map_user_iov so sg can use it (sg always does GFP_ATOMIC allocation). Signed-off-by: FUJITA Tomonori Signed-off-by: Douglas Gilbert Cc: Mike Christie Cc: James Bottomley Signed-off-by: Jens Axboe commit e6cb12accfbb964c3a2ff6ae2f93634209931ec7 Author: Aaron Carroll Date: Tue Aug 26 15:52:36 2008 +0200 cfq-iosched: fix queue depth detection CFQ's detection of queueing devices assumes a non-queuing device and detects if the queue depth reaches a certain threshold. Under some workloads (e.g. synchronous reads), CFQ effectively forces a unit queue depth, thus defeating the detection logic. This leads to poor performance on queuing hardware, since the idle window remains enabled. This patch inverts the sense of the logic: assume a queuing-capable device, and detect if the depth does not exceed the threshold. Signed-off-by: Aaron Carroll Signed-off-by: Jens Axboe commit d68b1f827e34dad3db6e42d2584301aa74b2c23b Author: Jens Axboe Date: Tue Aug 26 13:34:34 2008 +0200 block: don't use bio_has_data() in the completion path We should just check for rq->bio, as that is really the information we are looking for. Even if the bio attached doesn't carry data, we still need to do IO post processing on it. Signed-off-by: Jens Axboe commit 3d6da1b4c722d19376afffe3d2c124ed5e9d0014 Author: Jens Axboe Date: Tue Aug 26 10:25:02 2008 +0200 block: inherit CPU completion on bio->rq and rq->rq merges Somewhat incomplete, as we do allow merges of requests and bios that have different completion CPUs given. This is done on the assumption that a larger IO is still more beneficial than CPU locality. Signed-off-by: Jens Axboe commit 98f7bc7018d2e405ca393592c71477b3e5045c1b Author: Jens Axboe Date: Tue Aug 26 10:17:34 2008 +0200 block: add support for IO CPU affinity This patch adds support for controlling the IO completion CPU of either all requests on a queue, or on a per-request basis. We export a sysfs variable (rq_affinity) which, if set, migrates completions of requests to the CPU that originally submitted it. A bio helper (bio_set_completion_cpu()) is also added, so that queuers can ask for completion on that specific CPU. In testing, this has been show to cut the system time by as much as 20-40% on synthetic workloads where CPU affinity is desired. This requires a little help from the architecture, so it'll only work as designed for archs that are using the new generic smp helper infrastructure. Signed-off-by: Jens Axboe commit bb8ae8ae69007411e4ed104d7409f9b25f1ca1d5 Author: Jens Axboe Date: Mon Jul 28 13:08:45 2008 +0200 block: make kblockd_schedule_work() take the queue as parameter Preparatory patch for checking queuing affinity. Signed-off-by: Jens Axboe commit 9414f8b6550273d7b2bc40ff935eac63714641d7 Author: Jens Axboe Date: Mon Jul 28 13:06:00 2008 +0200 block: split softirq handling into blk-softirq.c Signed-off-by: Jens Axboe commit ada624b91764cca7a182f47a0005aedc256e95da Author: Jens Axboe Date: Tue Aug 26 09:15:47 2008 +0200 block: use linux/uaccess.h in elevator.c instead of asm variant Signed-off-by: Jens Axboe commit ddaf16102095a20deae822bf9a644e0148e54dc6 Author: Tejun Heo Date: Mon Aug 25 19:56:17 2008 +0900 block: allow disk to have extended device number Now that disk and partition handlings are mostly unified, it's easy to allow disk to have extended device number. This patch makes add_disk() use extended device number if disk->minors is zero. Both sd and ide-disk are updated to use this. * sd_format_disk_name() is implemented which can generically determine the drive name. This removes disk number restriction stemming from limited device names. * If sd index goes over SD_MAX_DISKS (which can be increased now BTW), sd simply doesn't initialize minors letting block layer choose extended device number. * If CONFIG_DEBUG_EXT_DEVT is set, both sd and ide-disk always set minors to 0 and use extended device numbers. Signed-off-by: Tejun Heo Signed-off-by: Jens Axboe commit 5f3324dc7d523a02a1a3af47f1b001001162a32f Author: Tejun Heo Date: Mon Aug 25 19:56:16 2008 +0900 block: replace @ext_minors with GENHD_FL_EXT_DEVT With previous changes, it's meaningless to limit the number of partitions. Replace @ext_minors with GENHD_FL_EXT_DEVT such that setting the flag allows the disk to have maximum number of allowed partitions (only limited by the number of entries in parsed_partitions as determined by MAX_PART constant). This kills not-too-pretty alloc_disk_ext[_node]() functions and makes @minors parameter to alloc_disk[_node]() unnecessary. The parameter is left alone to avoid disturbing the users. Signed-off-by: Tejun Heo Signed-off-by: Jens Axboe commit 72948d1038a7f84a134dcc27cb69833ad2a102cb Author: Tejun Heo Date: Mon Aug 25 19:56:15 2008 +0900 block: make partition array dynamic disk->__part used to be statically allocated to the maximum possible number of partitions. This patch makes partition array allocation dynamic. The added overhead is minimal as only real change is one memory dereference changed to RCU one. This saves both a bit of memory and cpu cycles iterating through unoccupied slots and makes increasing partition limit easier. Signed-off-by: Tejun Heo Signed-off-by: Jens Axboe commit 7b894014da61a7f9021f98e105bdae05d2f478bf Author: Tejun Heo Date: Mon Aug 25 19:56:14 2008 +0900 block: move stats from disk to part0 Move stats related fields - stamp, in_flight, dkstats - from disk to part0 and unify stat handling such that... * part_stat_*() now updates part0 together if the specified partition is not part0. ie. part_stat_*() are now essentially all_stat_*(). * {disk|all}_stat_*() are gone. * part_round_stats() is updated similary. It handles part0 stats automatically and disk_round_stats() is killed. * part_{inc|dec}_in_fligh() is implemented which automatically updates part0 stats for parts other than part0. * disk_map_sector_rcu() is updated to return part0 if no part matches. Combined with the above changes, this makes NULL special case handling in callers unnecessary. * Separate stats show code paths for disk are collapsed into part stats show code paths. * Rename disk_stat_lock/unlock() to part_stat_lock/unlock() While at it, reposition stat handling macros a bit and add missing parentheses around macro parameters. Signed-off-by: Tejun Heo Signed-off-by: Jens Axboe commit 9726570f4b4eea80ba02b9f9de6e6d2fee6c9f60 Author: Tejun Heo Date: Mon Aug 25 19:56:13 2008 +0900 block: kill GENHD_FL_FAIL and use part0->make_it_fail GENHD_FL_FAIL for disk is what make_it_fail is for parts. Kill it and use part0->make_it_fail. Sysfs node handling is unified too. Signed-off-by: Tejun Heo Signed-off-by: Jens Axboe commit 81340e34a37099fc47d3e5c91a93cbdaac945c3f Author: Tejun Heo Date: Mon Aug 25 19:56:12 2008 +0900 block: always set bdev->bd_part Till now, bdev->bd_part is set only if the bdev was for parts other than part0. This patch makes bdev->bd_part always set so that code paths don't have to differenciate common handling. Signed-off-by: Tejun Heo Signed-off-by: Jens Axboe commit 77232ad1c3220ec8c00070d90bd45ff5724d5e06 Author: Tejun Heo Date: Mon Aug 25 19:56:11 2008 +0900 block: move holder_dir from disk to part0 Move disk->holder_dir to part0->holder_dir. Kill now mostly superflous bdev_get_holder(). While at it, kill superflous kobject_get/put() around holder_dir, slave_dir and cmd_filter creation and collapse disk_sysfs_add_subdirs() into register_disk(). These serve no purpose but obfuscating the code. Signed-off-by: Tejun Heo Signed-off-by: Jens Axboe commit ab5c9a2416d6c2f4d4d32ffbe9df35a28cf4f202 Author: Tejun Heo Date: Mon Aug 25 19:56:10 2008 +0900 block: move policy from disk to part0 Move disk->policy to part0->policy. Implement and use get_disk_ro(). Signed-off-by: Tejun Heo Signed-off-by: Jens Axboe commit 9662f1202c7aead82f3ace242a95e559e227022a Author: Tejun Heo Date: Mon Aug 25 19:56:09 2008 +0900 block: unify sysfs size node handling Now that capacity and __dev are moved to part0, part0 and others can share the same method. Signed-off-by: Tejun Heo Signed-off-by: Jens Axboe commit 7c86105c2aadd6866cd2f2a3abe339589fabf9a4 Author: Tejun Heo Date: Fri Aug 29 09:01:47 2008 +0200 block: move __dev from disk to part0 Move disk->__dev to part0->__dev. This simplifies bdget_disk() and lookup_devt() and allows common sysfs attributes to be unified. part_to_disk() is updated to handle part0 -> disk. Updated to include a fix from Bartlomiej Zolnierkiewicz , he writes: "part0 is a "special" partition and doesn't need to have capacity set - this fixes regression caused by "block: move __dev from disk to part0" commit." Signed-off-by: Tejun Heo Signed-off-by: Jens Axboe commit aa5a51d2b82a2a092bea85171672535cab4c94e4 Author: Tejun Heo Date: Mon Aug 25 19:56:07 2008 +0900 block: move capacity from disk to part0 Move disk->capacity to part0->nr_sects and convert all users who directly accessed the field to use {get|set}_capacity(). This is done early to allow the __dev field to be moved. Signed-off-by: Tejun Heo Signed-off-by: Jens Axboe commit 9d66e3daaee45e431c59d2753983d3be86779e02 Author: Tejun Heo Date: Wed Sep 3 09:06:42 2008 +0200 block: introduce partition 0 genhd and partition code handled disk and partitions separately. All information about the whole disk was in struct genhd and partitions in struct hd_struct. However, the whole disk (part0) and other partitions have a lot in common and the data structures end up having good number of common fields and thus separate code paths doing the same thing. Also, the partition array was indexed by partno - 1 which gets pretty confusing at times. This patch introduces partition 0 and makes the partition array indexed by partno. Following patches will unify the handling of disk and parts piece-by-piece. This patch also implements disk_partitionable() which tests whether a disk is partitionable. With coming dynamic partition array change, the most common usage of disk_max_parts() will be testing whether a disk is partitionable and the number of max partitions will become much less important. Signed-off-by: Tejun Heo Signed-off-by: Jens Axboe commit 45433bbb118e8acbed3ddf5fa3eb42cd839e762e Author: Tejun Heo Date: Mon Aug 25 19:56:05 2008 +0900 block: implement and use {disk|part}_to_dev() Implement {disk|part}_to_dev() and use them to access generic device instead of directly dereferencing {disk|part}->dev. To make sure no user is left behind, rename generic devices fields to __dev. This is in preparation of unifying partition 0 handling with other partitions. Signed-off-by: Tejun Heo Signed-off-by: Jens Axboe commit 623a2a14336a556a9ceb24bde3389f9d9d36a02f Author: Tejun Heo Date: Mon Aug 25 19:47:25 2008 +0900 block: implement CONFIG_DEBUG_BLOCK_EXT_DEVT Extended devt introduces non-contiguos device numbers. This patch implements a debug option which forces most devt allocations to be from the extended area and spreads them out. This is enabled by default if DEBUG_KERNEL is set and achieves... 1. Detects code paths in kernel or userland which expect predetermined consecutive device numbers. 2. When something goes wrong, avoid corruption as adding to the minor of earlier partition won't lead to the wrong but valid device. Signed-off-by: Tejun Heo Signed-off-by: Jens Axboe commit 309ac0db1df1c19c2eeec12b2340e5a14f9202aa Author: Tejun Heo Date: Mon Aug 25 19:47:24 2008 +0900 sd/ide-disk: apply extended minors to sd and ide Update sd and ide-disk such that they can take advantage of extended minors. ide-disk already has 64 minors per device and currently doesn't use extended minors although after this patch it can be turned on by simply tweaking constants. sd only had 16 minors per device causing problems on certain peculiar configurations. This patch lifts the restriction and enables it to use upto 64 minors. Signed-off-by: Tejun Heo Signed-off-by: Jens Axboe commit c9f1a6666686d2f6f775b4f476be613c7bd23fef Author: Tejun Heo Date: Mon Aug 25 19:47:23 2008 +0900 block: adjust formatting for large minors and add ext_range sysfs attr With extended minors and the soon-to-follow debug feature, large minor numbers for block devices will be common. This patch does the followings to make printouts pretty. * Adapt print formats such that large minors don't break the formatting. * For extended MAJ:MIN, %02x%02x for MAJ:MIN used in printk_all_partitions() doesn't cut it anymore. Update it such that %03x:%05x is used if either MAJ or MIN doesn't fit in %02x. * Implement ext_range sysfs attribute which shows total minors the device can use including both conventional minor space and the extended one. Signed-off-by: Tejun Heo Signed-off-by: Jens Axboe commit 6dff278b631ab4327da210e9aafb1500fe069d8e Author: Tejun Heo Date: Mon Aug 25 19:47:22 2008 +0900 block: implement extended dev numbers Implement extended device numbers. A block driver can tell block layer that it wants to use extended device numbers. After the usual minor space is used up, block layer automatically allocates devt's from EXT_BLOCK_MAJOR. Currently only one major number is allocated for this but as the allocation is strictly on-demand, ~1mil minor space under it should suffice unless the system actually has more than ~1mil partitions and if that ever happens adding more majors to the extended devt area is easy. Due to internal implementation issues, the first partition can't be allocated on the extended area. In other words, genhd->minors should at least be 1. This limitation will be lifted by later changes. Signed-off-by: Tejun Heo Signed-off-by: Jens Axboe commit 49a50329274a1a78ee3044af9d065ea628536fe1 Author: Tejun Heo Date: Mon Aug 25 19:47:21 2008 +0900 block: fix diskstats access There are two variants of stat functions - ones prefixed with double underbars which don't care about preemption and ones without which disable preemption before manipulating per-cpu counters. It's unclear whether the underbarred ones assume that preemtion is disabled on entry as some callers don't do that. This patch unifies diskstats access by implementing disk_stat_lock() and disk_stat_unlock() which take care of both RCU (for partition access) and preemption (for per-cpu counter access). diskstats access should always be enclosed between the two functions. As such, there's no need for the versions which disables preemption. They're removed and double underbars ones are renamed to drop the underbars. As an extra argument is added, there's no danger of using the old version unconverted. disk_stat_lock() uses get_cpu() and returns the cpu index and all diskstat functions which access per-cpu counters now has @cpu argument to help RT. This change adds RCU or preemption operations at some places but also collapses several preemption ops into one at others. Overall, the performance difference should be negligible as all involved ops are very lightweight per-cpu ones. Signed-off-by: Tejun Heo Cc: Peter Zijlstra Signed-off-by: Jens Axboe commit 9d8ef0cdfdd31852e4e89fb1eb85ef6a812ef955 Author: Tejun Heo Date: Wed Sep 3 09:03:02 2008 +0200 block: fix disk->part[] dereferencing race disk->part[] is protected by its matching bdev's lock. However, non-critical accesses like collecting stats and printing out sysfs and proc information used to be performed without any locking. As partitions can come and go dynamically, partitions can go away underneath those non-critical accesses. As some of those accesses are writes, this theoretically can lead to silent corruption. This patch fixes the race by using RCU for the partition array and dev reference counter to hold partitions. * Rename disk->part[] to disk->__part[] to make sure no one outside genhd layer proper accesses it directly. * Use RCU for disk->__part[] dereferencing. * Implement disk_{get|put}_part() which can be used to get and put partitions from gendisk respectively. * Iterators are implemented to help iterate through all partitions safely. * Functions which require RCU readlock are marked with _rcu suffix. * Use disk_put_part() in __blkdev_put() instead of directly putting the contained kobject. Signed-off-by: Tejun Heo Signed-off-by: Jens Axboe commit 93d8bfaf8c014e82200ee2b6138429b6af062b41 Author: Tejun Heo Date: Wed Sep 3 09:01:48 2008 +0200 block: don't depend on consecutive minor space * Implement disk_devt() and part_devt() and use them to directly access devt instead of computing it from ->major and ->first_minor. Note that all references to ->major and ->first_minor outside of block layer is used to determine devt of the disk (the part0) and as ->major and ->first_minor will continue to represent devt for the disk, converting these users aren't strictly necessary. However, convert them for consistency. * Implement disk_max_parts() to avoid directly deferencing genhd->minors. * Update bdget_disk() such that it doesn't assume consecutive minor space. * Move devt computation from register_disk() to add_disk() and make it the only one (all other usages use the initially determined value). These changes clean up the code and will help disk->part dereference fix and extended block device numbers. Signed-off-by: Tejun Heo Signed-off-by: Jens Axboe commit 8e9b676717996538d07bfa07808b04cb9bf1dc52 Author: Tejun Heo Date: Wed Sep 3 09:01:09 2008 +0200 block: make variable and argument names more consistent In hd_struct, @partno is used to denote partition number and a number of other places use @part to denote hd_struct. Functions use @part and @index instead. This causes confusion and makes it difficult to use consistent variable names for hd_struct. Always use @partno if a variable represents partition number. Also, print out functions use @f or @part for seq_file argument. Use @seqf uniformly instead. Signed-off-by: Tejun Heo Signed-off-by: Jens Axboe commit 54b32c771ee825bb013bb3690cc580aa92c390cf Author: Tejun Heo Date: Mon Aug 25 19:47:17 2008 +0900 block: misc updates This patch makes the following misc updates in preparation for disk->part dereference fix and extended block devt support. * implment part_to_disk() * fix comment about gendisk->part indexing * rename get_part() to disk_map_sector() * don't use n which is always zero while printing disk information in diskstats_show() Signed-off-by: Tejun Heo Signed-off-by: Jens Axboe commit 73cc4aa9038fac443e2416fc119830f52ff011fe Author: Tejun Heo Date: Mon Aug 25 19:30:16 2008 +0900 block: update add_partition() error handling d805dda4 tried to fix error case handling in add_partition() but had a few problems. * disk->part[] entry is set early and left dangling if operation fails. * Once device initialized, the last put_device() is responsible for freeing all the resources. The failure path freed part_stats and p regardless of put_device() causing double free. * holders subdir holds reference to the disk device, so failure path should remove it to release resources properly which was missing. This patch fixes the above problems and while at it move partition slot busy check into add_partition() for completeness and inlines holders subdirectory creation. Using separate function for it just obfuscates the code. Signed-off-by: Tejun Heo Cc: Abdel Benamrouche Signed-off-by: Jens Axboe commit fb729540a5a6e027d07f02165314a15d260f08af Author: Tejun Heo Date: Mon Aug 25 19:30:15 2008 +0900 block: allow deleting zero length partition delete_partition() was noop for zero length partition. As the addition code allows creating zero lenght partition and deletion is assumed to always succeed, this causes memory leak for zero length partitions. Allow zero length partitions to end their meaningless lives. While at it, allow deleting zero lenght partition via BLKPG_DEL_PARTITION ioctl too. Signed-off-by: Tejun Heo Signed-off-by: Jens Axboe commit b952b32acedb8f3b578ff8241b4f543cb39bd8a1 Author: Tejun Heo Date: Wed Sep 3 08:57:12 2008 +0200 block: use class_dev_iterator instead of class_for_each_device() Recent block_class iteration updates 5c6f35c5..27f3025 converted all class device iteration to class_for_each_device() and class_find_device(), which are correct but pain in the ass to use. This pach converts them to newly introduced class_dev_iterator so that they can use more natural control structures instead of separate callbacks and struct to pass parameters to them. This results in smaller and easier code. This patch also restores the original behavior of not printing header in /proc/partitions if there's no partition to print. This is trivial but still user-visible behavior. Signed-off-by: Tejun Heo Cc: Greg Kroah-Hartman Signed-off-by: Jens Axboe commit 1f25ca4e9095264f3c3916233589a4f9aead5152 Author: Tejun Heo Date: Wed Sep 3 08:53:37 2008 +0200 block: don't grab block_class_lock unnecessarily block_class_lock protects major_names array and bdev_map and doesn't have anything to do with block class devices. Don't grab them while iterating over block class devices. Signed-off-by: Tejun Heo Signed-off-by: Jens Axboe commit b2dd5ee027e3c261debc28cf4392d69c7c6eaa07 Author: Tejun Heo Date: Mon Aug 25 19:30:12 2008 +0900 block: fix partition info printouts Recent block_class iteration updates 5c6f35c5..27f3025 broke partition info printouts. * printk_all_partitions(): Partition print out stops when it meets a partition hole. Partition printing inner loop should continue instead of exiting on empty partition slot. * /proc/partitions and /proc/diskstats: If all information can't be read in single read(), the information is truncated. This is because find_start() doesn't actually update the counter containing the initial seek. It runs to the end and ends up always reporting EOF on the second read. This patch fixes both problems. Signed-off-by: Tejun Heo Cc: Greg Kroah-Hartman Signed-off-by: Jens Axboe commit 9e0c5442d2b6a81afdcdc2991a7a89af21536a44 Author: Tejun Heo Date: Mon Aug 25 19:50:19 2008 +0200 driver-core: use klist for class device list and implement iterator Iterating over entries using callback usually isn't too fun especially when the entry being iterated over can't be manipulated freely. This patch converts class->p->class_devices to klist and implements class device iterator so that the users can freely build their own control structure. The users are also free to call back into class code without worrying about locking. class_for_each_device() and class_find_device() are converted to use the new iterators, so their users don't have to worry about locking anymore either. Note: This depends on klist-dont-iterate-over-deleted-entries patch because class_intf->add/remove_dev() depends on proper synchronization with device removal. Signed-off-by: Tejun Heo Cc: Greg Kroah-Hartman Cc: Jens Axboe Signed-off-by: Jens Axboe commit 999403cca93bae0c64c7013066bc79935590eb8b Author: Tejun Heo Date: Mon Aug 25 19:50:16 2008 +0200 klist: don't iterate over deleted entries A klist entry is kept on the list till all its current iterations are finished; however, a new iteration after deletion also iterates over deleted entries as long as their reference count stays above zero. This causes problems for cases where there are users which iterate over the list while synchronized against list manipulations and natuarally expect already deleted entries to not show up during iteration. This patch implements dead flag which gets set on deletion so that iteration can skip already deleted entries. The dead flag piggy backs on the lowest bit of knode->n_klist and only visible to klist implementation proper. While at it, drop klist_iter->i_head as it's redundant and doesn't offer anything in semantics or performance wise as klist_iter->i_klist is dereferenced on every iteration anyway. Signed-off-by: Tejun Heo Cc: Greg Kroah-Hartman Cc: Alan Stern Cc: Jens Axboe Signed-off-by: Jens Axboe commit f3c1cec10a2420794f7899427c59d2552dcf25db Author: Randy Dunlap Date: Tue Aug 19 20:13:11 2008 +0200 Add some block/ source files to the kernel-api docbook. Fix kernel-doc notation in them as needed. Fix changed function parameter names. Fix typos/spellos. In comments, change REQ_SPECIAL to REQ_TYPE_SPECIAL and REQ_BLOCK_PC to REQ_TYPE_BLOCK_PC. Signed-off-by: Randy Dunlap Signed-off-by: Jens Axboe commit cb3e8b05746ae9063b95078ec17e27a2f75d8e61 Author: Jens Axboe Date: Fri Aug 15 10:56:11 2008 +0200 block: make bi_phys_segments an unsigned int instead of short raid5 can overflow with more than 255 stripes, and we can increase it to an int for free on both 32 and 64-bit archs due to the padding. Signed-off-by: Jens Axboe commit b7f803f2a267dfee07fb0a0535f2cf11b60aa73a Author: Jens Axboe Date: Fri Aug 15 10:41:18 2008 +0200 block: raid fixups for removal of bi_hw_segments Signed-off-by: Jens Axboe commit b207d0a22c4542704a4b22d78a3d07a4dc9e217b Author: Mikulas Patocka Date: Fri Aug 15 10:20:02 2008 +0200 drop vmerge accounting Remove hw_segments field from struct bio and struct request. Without virtual merge accounting they have no purpose. Signed-off-by: Mikulas Patocka Signed-off-by: Jens Axboe commit 77d9861ff6fca3355417d7b0f44ea665c933ebfb Author: Mikulas Patocka Date: Fri Aug 15 10:15:19 2008 +0200 block: drop virtual merging accounting Remove virtual merge accounting. Signed-off-by: Mikulas Patocka Signed-off-by: Jens Axboe commit 79be7f7db21b0872e5135c544b67842bb913464a Author: Aaron Carroll Date: Thu Aug 14 18:17:15 2008 +1000 block: update documentation for deadline fifo_batch tunable Update the description of fifo_batch to match the current implementation, and include a description of how to tune it. Signed-off-by: Aaron Carroll Signed-off-by: Jens Axboe commit 155a090688fa7d91af211b47fc21f09ad9fa4a72 Author: Aaron Carroll Date: Thu Aug 14 18:17:14 2008 +1000 deadline-iosched: non-functional fixes * convert goto to simpler while loop; * use rq_end_sector() instead of computing manually; * fix false comments; * remove spurious whitespace; * convert rq_rb_root macro to an inline function. Signed-off-by: Aaron Carroll Signed-off-by: Jens Axboe commit a5cbff671e714bf4f7b80b84044868f195cd9346 Author: Aaron Carroll Date: Thu Aug 14 18:17:13 2008 +1000 deadline-iosched: allow non-sequential batching Deadline currently only batches sector-contiguous requests, so except for a few circumstances (e.g. requests in a single direction), it is essentially first come first served. This is bad for throughput, so change it to CSCAN, which means requests in a batch do not need to be sequential and are issued in increasing sector order. Signed-off-by: Aaron Carroll Signed-off-by: Jens Axboe commit d6ffc0a3f78dd4143730c8bd2835f4721137d171 Author: Fernando Luis Vázquez Cao Date: Thu Aug 14 09:59:13 2008 +0200 virtio_blk: use a wrapper function to access io context information of IO requests struct request has an ioprio member but it is never updated because currently bios do not hold io context information. The implication of this is that virtio_blk ends up passing useless information to the backend driver. That said, some IO schedulers such as CFQ do store io context information in struct request, but use private members for that, which means that that information cannot be directly accessed in a IO scheduler-independent way. This patch adds a function to obtain the ioprio of a request. We should avoid accessing ioprio directly and use this function instead, so that its users do not have to care about future changes in block layer structures or what the currently active IO controller is. This patch does not introduce any functional changes but paves the way for future clean-ups and enhancements. Signed-off-by: Fernando Luis Vazquez Cao Acked-by: Rusty Russell Signed-off-by: Jens Axboe commit 0c9aa9abfe5c218b2b99f37534600c7d4ca07f7d Author: David Woodhouse Date: Wed Aug 13 12:35:09 2008 +0100 Kill REQ_TYPE_FLUSH It was only used by ps3disk, and it should probably have been REQ_TYPE_LINUX_BLOCK + REQ_LB_OP_FLUSH. Signed-off-by: David Woodhouse Signed-off-by: Jens Axboe commit 5f51235ff13e1429c5e1eefef339bac5b8d41cf6 Author: David Woodhouse Date: Sat Aug 9 16:42:20 2008 +0100 Allow elevators to sort/merge discard requests But blkdev_issue_discard() still emits requests which are interpreted as soft barriers, because naïve callers might otherwise issue subsequent writes to those same sectors, which might cross on the queue (if they're reallocated quickly enough). Callers still _can_ issue non-barrier discard requests, but they have to take care of queue ordering for themselves. Signed-off-by: David Woodhouse Signed-off-by: Jens Axboe commit 7c6759ad58c3aeaf68e66c0c146c16f1b3283bde Author: David Woodhouse Date: Mon Aug 11 15:58:42 2008 +0100 Add BLKDISCARD ioctl to allow userspace to discard sectors We may well want mkfs tools to use this to mark the whole device as unwanted before they format it, for example. The ioctl takes a pair of uint64_ts, which are start offset and length in _bytes_. Although at the moment it might make sense for them both to be in 512-byte sectors, I don't want to limit the ABI to that. Signed-off-by: David Woodhouse Signed-off-by: Jens Axboe commit cd60c4c2c4b2660312c23287a90221b490b54d76 Author: OGAWA Hirofumi Date: Mon Aug 11 17:07:08 2008 +0100 Use WRITE_BARRIER in blkdev_issue_flush(), not (1< Signed-off-by: David Woodhouse Signed-off-by: Jens Axboe commit 634b9ee0feb169241bc09bc8217238038e3320fb Author: David Woodhouse Date: Sun Aug 10 12:33:00 2008 +0100 blktrace: simplify flags handling in __blk_add_trace Let the compiler see what's going on, and it can all get a lot simpler. On PPC64 this reduces the size of the code calculating these bits by about 60%. On x86_64 it's less of a win -- only 40%. Signed-off-by: David Woodhouse Signed-off-by: Jens Axboe commit 1d9a052f7ec068d1a8c10802325b28382f38cc55 Author: David Woodhouse Date: Sun Aug 10 11:21:57 2008 +0100 blktrace: support discard requests Signed-off-by: David Woodhouse Signed-off-by: Jens Axboe commit f9f8af2000a3b2d32644b750170a3eea105a59c2 Author: David Woodhouse Date: Tue Aug 5 18:08:56 2008 +0100 Support 'discard sectors' operation. We can benefit from knowing that the file system no longer cares about the contents of certain sectors, by throwing them away immediately and then never having to garbage collect them, and using the extra free space to make our operations more efficient. Do so. Signed-off-by: David Woodhouse Signed-off-by: Jens Axboe commit 048304bf854e3d06c42c8511231bb2932e7f7029 Author: David Woodhouse Date: Tue Aug 5 18:08:25 2008 +0100 Support 'discard sectors' operation in translation layer support core Signed-off-by: David Woodhouse Signed-off-by: Jens Axboe commit 492e7b42e3ca38bcf538b45b171c83d1b19fcc13 Author: David Woodhouse Date: Tue Aug 5 18:05:46 2008 +0100 Let the block device know when sectors can be discarded [hirofumi@mail.parknet.co.jp: discard _after_ checking for corrupt chains] Signed-off-by: David Woodhouse Acked-by: OGAWA Hirofumi Signed-off-by: Jens Axboe commit d3707af841b9d92ae21573f931eeb08dd18b383a Author: David Woodhouse Date: Tue Aug 5 18:01:53 2008 +0100 Add 'discard' request handling Some block devices benefit from a hint that they can forget the contents of certain sectors. Add basic support for this to the block core, along with a 'blkdev_issue_discard()' helper function which issues such requests. The caller doesn't get to provide an end_io functio, since blkdev_issue_discard() will automatically split the request up into multiple bios if appropriate. Neither does the function wait for completion -- it's expected that callers won't care about when, or even _if_, the request completes. It's only a hint to the device anyway. By definition, the file system doesn't _care_ about these sectors any more. [With feedback from OGAWA Hirofumi and Jens Axboe Signed-off-by: Jens Axboe commit 59b3162baad9733a7b731cab11a0094b193fd22e Author: David Woodhouse Date: Sat Aug 9 16:22:17 2008 +0100 Fix up comments about matching flags between bio and rq Signed-off-by: David Woodhouse Signed-off-by: Jens Axboe commit 170f381ca5f4a6e56f264165580be2a6c5e60e23 Author: Jens Axboe Date: Thu Aug 14 13:12:15 2008 +0200 highmem: use bio_has_data() in the bounce path Signed-off-by: Jens Axboe commit 977a17b0d0b363f00c42ac3557baf86ac8cf5daa Author: Jens Axboe Date: Fri Aug 8 11:06:45 2008 +0200 block: use bio_has_data() in the IO completion path Signed-off-by: Jens Axboe commit dca67448beea1c38629f35456e7655af028cef0c Author: Jens Axboe Date: Fri Aug 8 11:04:44 2008 +0200 block: use bio_has_data() to check for data carrying bio Signed-off-by: Jens Axboe commit f48918105c4d63459c8de6199338bfa0f942a320 Author: Jens Axboe Date: Fri Aug 8 11:17:12 2008 +0200 block: add bio_has_data() to detect whether a bio carries data or not Signed-off-by: Jens Axboe commit 02157078d45a047c0f3391f0f2a36a5286a41cbd Author: xiphmont@xiph.org Date: Fri Aug 22 11:12:21 2008 +0200 SG_IO block filter whitelist missing MMC SET READ AHEAD command I have another request for the block filter SG_IO command whitelist, specifically the MMC streaming command set SET READ AHEAD command. The command applies only to MMC CDROM/DVDROM drives with the streaming optional feature set. The command is useful to cdparanoia in that it allows explicit cache control side effects that are, on many drives, cdparanoia's most efficient way to flush/disable the media cache on cdrom drives. I am aware of no reason why it should not be accessible from usespace. Also note that the command is already fully accessible through the SCSI-native version of the SG_IO ioctl as well as the traditional SG interface. The command is only being refused on block devices. That means that on a typical stock distro, the command is available through /dev/sg* but not /dev/scd* although both are typically available and accessible. Filtering the command is not providing any protection, only a confusing inconsistency. Signed-off-by: Jens Axboe commit cca5e3226e9479b6732b3a088bbe1f43046d5fd9 Author: Tao Ma Date: Wed Sep 3 01:57:14 2008 +0800 [PATCH 1/1] ocfs2: Fix a bug in direct IO read. ocfs2 will become read-only if we try to read the bytes which pass the end of i_size. This can be easily reproduced by following steps: 1. mkfs a ocfs2 volume with bs=4k cs=4k and nosparse. 2. create a small file(say less than 100 bytes) and we will create the file which is allocated 1 cluster. 3. read 8196 bytes from the kernel using O_DIRECT which exceeds the limit. 4. The ocfs2 volume becomes read-only and dmesg shows: OCFS2: ERROR (device sda13): ocfs2_direct_IO_get_blocks: Inode 66010 has a hole at block 1 File system is now read-only due to the potential of on-disk corruption. Please run fsck.ocfs2 once the file system is unmounted. So suppress the ERROR message. Signed-off-by: Tao Ma Signed-off-by: Mark Fasheh commit 3742ec68333b2eb80dc249fb589bea5ad3b18ea3 Author: Tao Ma Date: Fri Aug 29 09:00:19 2008 +0800 [PATCH] ocfs2: Resolve deadlock in ocfs2_xattr_free_block. In ocfs2_xattr_free_block, we take a cluster lock on xb_alloc_inode while we have a transaction open. This will deadlock the downconvert thread, so fix it. We can clean up how xattr blocks are removed while here - this patch also moves the mechanism of releasing xattr block (including both value, xattr tree and xattr block) into this function. Signed-off-by: Tao Ma Signed-off-by: Mark Fasheh commit 43be70a0c6d7cc847babbe3a79714734aa157c7f Author: Tao Ma Date: Mon Sep 1 08:45:18 2008 +0800 [PATCH] ocfs2: bug-fix for journal extend in xattr. In ocfs2_extend_trans, when we can't extend the current transaction, it will commit current transaction and restart a new one. So if the previous credits we have allocated aren't used(the block isn't dirtied before our extend), we will not have enough credits for any future operation(it will cause jbd complain and bug out). So check this and re-extend it. Signed-off-by: Tao Ma Signed-off-by: Mark Fasheh commit 2c10b32bf57db7ec6d4cca4c4aa3d86bacb01c8a Author: Thomas Graf Date: Tue Sep 2 17:30:27 2008 -0700 netlink: Remove compat API for nested attributes Removes all _nested_compat() functions from the API. The prio qdisc no longer requires them and netem has its own format anyway. Their existance is only confusing. Resend: Also remove the wrapper macro. Signed-off-by: Thomas Graf Signed-off-by: David S. Miller commit 4afb41f45b45283cc88105e0dc9d91db1d7468ac Author: Alan Cox Date: Wed Sep 3 10:12:29 2008 +1000 tty-kref-hso Checking tty == NULL doesn't help us unless we have a clear semantic for the locking of the tty object in the driver. Use the tty kref objects so that we can take references to the tty in the USB event handling paths. commit ba02fa659a7cb571d81d0e64270bd920e1c72f53 Author: Alan Cox Date: Wed Sep 3 10:12:28 2008 +1000 tty-tidy-n-tty Remove/fix some bogus NULL checks, comment some locking etc commit 1bb709fda3fa1be24b5bcbc9f2d1b3e60f4a80bf Author: Alan Cox Date: Wed Sep 3 10:12:27 2008 +1000 tty-denull Many tty drivers contain 'can't happen' checks against NULL pointers passed in by the tty layer. These have never been possible to occur. Even more importantly if they ever do occur we want to know as it would be a serious bug. commit 9a0d0558d0a658d7a6f19dbcaf769a296e7cb4c7 Author: Alan Cox Date: Wed Sep 3 10:12:27 2008 +1000 tty-gigaset-move Stephen's fixes reminded me that gigaset is still rather broken commit 069a7598b82f3d5bcbac1afbfd00b05d4bd02afa Author: Alan Cox Date: Wed Sep 3 10:12:27 2008 +1000 tty-ipw-wtf This came in via another tree and unfortunately is rather broken on the tty side. Comment the apparent locking problems for someone who knows the driver to look at. Fix the termios and other ioctl handling. The driver was calling the wrong methods for what it wanted to do but the right ones existed so its a simple fix up. commit 4748d984c03c4db073f4bb0d0d23ee64354b9394 Author: Stephen Rothwell Date: Wed Sep 3 10:12:27 2008 +1000 tty-move-canon-isdn Hi Alan, Today's linux-next build (x86_64 allmodconfig) failed like this: /drivers/char/tty_ioctl.c: In function 'change_termios': drivers/isdn/capi/capi.c:1234: error: implicit declaration of function 'n_tty_ioctl' drivers/isdn/gigaset/ser-gigaset.c: In function 'gigaset_tty_ioctl': drivers/isdn/gigaset/ser-gigaset.c:648: error: implicit declaration of function 'n_tty_ioctl' Introduced by commit 686b5e4aea05a80e370dc931b7f4a8d03c80da54 ("tty-move-canon-specials"). I added the following patch (which may not be correct). -- Cheers, Stephen Rothwell sfr@canb.auug.org.au http://www.canb.auug.org.au/~sfr/ Signed-off-by: Stephen Rothwell Signed-off-by: Alan Cox commit 32c4e70094198c93cda7b5d2b56cd4e6313d0db5 Author: Alan Cox Date: Wed Sep 3 10:12:27 2008 +1000 tty-move-canon-specials Move the set up on ldisc change into the ldisc Move the INQ/OUTQ cases into the driver not in shared ioctl code where it gives bogus answers for other ldisc values commit f7cc83eb4d28ef90e72d083f8cea9261a22b0352 Author: Alan Cox Date: Wed Sep 3 10:12:26 2008 +1000 tty-real-termios This moves us towards sanity and should mean our termios locking is now complete and comprehensive. commit 9092a3c5c07d6d82af38ef1465d991f275c56bc1 Author: Alan Cox Date: Wed Sep 3 10:12:26 2008 +1000 tty-pty-compare-winsize We always use the real tty one for stuff so the pty one should not be compared. As we propogate window changes to both it doesn't currently matter but will when we tidy up the pty termios logic a bit more commit 0acd3acf11e851ade77f3b411ac4e389592b9105 Author: Alan Cox Date: Wed Sep 3 10:12:26 2008 +1000 tty-simplify-allocation Copy the simplification from the pty unix98 special case to the generic one. This allows us to kill off driver->termios_locked entirely which is nice. We have to whack bits of the cris driver as it meddles in places it shouldn't providing its own arrays that were never used anyway. commit c041ccd71354aefc8e018e86a0133aa525b3a4de Author: Alan Cox Date: Wed Sep 3 10:12:26 2008 +1000 pty-simplify-allocation We need both termios and termios_locked so allocate them as one commit f80951ea06df3a4b25d7808ccaa14981e8a271f0 Author: Alan Cox Date: Wed Sep 3 10:12:25 2008 +1000 pty-fix-fail-crash The updating and moving around of the pty code added a bug where both the helper and caller free the main tty struct (the pty driver must free the o_tty pair itself however). commit caf29b6f12a17b85d6f175a9a64512f461c299fd Author: Alan Cox Date: Wed Sep 3 10:12:25 2008 +1000 pty-clean We've done the heavy lifting now its time to mop up a bit commit 4b29215eac5e91bfc31b8d8ef63cae7d3294a176 Author: Alan Cox Date: Wed Sep 3 10:12:25 2008 +1000 tty-simplify-devpts-pty-kill Simplify devpts_pty_kill From: Sukadev Bhattiprolu When creating a new pty, save the pty's inode in the tty->driver_data. Use this inode in pty_kill() to identify the devpts instance. Since we now have the inode for the pty, we can skip get_node() lookup and remove the unused get_node(). TODO: - check if the mutex_lock is needed in pty_kill(). commit cc5a2f09f3765618f0a7aff5a6d4abf8a86b151e Author: Alan Cox Date: Wed Sep 3 10:12:25 2008 +1000 tty-simplify-devpts-new Simplify devpts_pty_new() From: Sukadev Bhattiprolu devpts_pty_new() is called when setting up a new pty and would not will not have an existing dentry or inode for the pty. So don't bother looking for an existing dentry - just create a new one. commit 38ddb8ecb0fa4893fa3d3d3234cce42040ae61b3 Author: Alan Cox Date: Wed Sep 3 10:12:25 2008 +1000 tty-simplify-devpts-get-tty Simplify devpts_get_tty() From: Sukadev Bhattiprolu As pointed out by H. Peter Anvin, since the inode for the pty is known, we don't need to look it up. commit bed7782e4150047d14bc0d310f2f69f263e74700 Author: Alan Cox Date: Wed Sep 3 10:12:24 2008 +1000 tty-devpts-instance Add an instance parameter devpts interfaces From: Sukadev Bhattiprolu Pass-in 'inode' or 'tty' parameter to devpts interfaces. With multiple devpts instances, these parameters will be used in subsequent patches to identify the instance of devpts mounted. The parameters also help simplify devpts implementation. Changelog[v3]: - minor changes due to merge with ttydev updates - rename parameters to emphasize they are ptmx or pts inodes - pass-in tty_struct * to devpts_pty_kill() (this will help cleanup the get_node() call in a subsequent patch) Signed-off-by: Alan Cox commit 6a7e3fde9aa1b4b4e2155a796fd60ac88e5551c4 Author: Sukadev Bhattiprolu Date: Wed Sep 3 10:12:24 2008 +1000 Move tty lookup/reopen to caller Move tty_driver_lookup_tty() and tty_reopen() from tty_init_dev() into tty_open() (one of the two callers of tty_init_dev()). These calls are not really required in ptmx_open(), the other caller, since ptmx_open() would be setting up a new tty. Changelog[v2]: - remove the lookup and reopen calls from ptmx_open - merge with recent changes to ttydev tree Signed-off-by: Alan Cox commit ac309639f1f576ac573132d2b2c36c19293180e0 Author: Alan Cox Date: Wed Sep 3 10:12:24 2008 +1000 tty-extract-pty-init The majority of the remaining init_dev code is pty special cases. We refactor this code into the driver->install method. commit 4aee6ff89f0e1bc9e2a4da28a87f42db83ad9740 Author: Alan Cox Date: Wed Sep 3 10:12:24 2008 +1000 tty-finish-initdev Original suggestion and proposal from Sukadev Bhattiprolu. Signed-off-by: Alan Cox commit 563999a5264462ceecae5aabf8806488a24067cd Author: Alan Cox Date: Wed Sep 3 10:12:23 2008 +1000 tty-add-remove-ops We have the lookup operation abstracted which is nice for pty cleanup but we really want to abstract the add/remove entries as well so that we can pull the pty code out of the tty core and create a clear defined interface for the tty driver table. commit edbe6bf397dd519d6664ad999da578970bf5336e Author: Alan Cox Date: Wed Sep 3 10:12:23 2008 +1000 tty-driver-kref commit 8cb90416274a56de602addb83915412d7748ef39 Author: Alan Cox Date: Wed Sep 3 10:12:23 2008 +1000 tty-init-dev-clean Fix up the naming, style and extract some bits of code into the driver specific code commit 60c635294bd1827ac2d63bb36330066a0370d26a Author: Sukadev Bhattiprolu Date: Wed Sep 3 10:12:23 2008 +1000 tty-init-dev-rework Move the 'find-tty' and 'fast-track-open' parts of init_dev() to separate functions. Signed-off-by: Sukadev Bhattiprolu Signed-off-by: Alan Cox commit af1859458606f79dd5411f790798cae3fce16b97 Author: Alan Cox Date: Wed Sep 3 10:12:22 2008 +1000 tty-add-termiox We need a way to describe the various additional modes and flow control features that random weird hardware shows up and software such as wine wants to emulate as Windows supports them. TCGETX/TCSETX and the termiox ioctl are a SYS5 extension that we might as well adopt. This patches adds the structures and the basic ioctl interfaces when the TCGETX etc defines are added for an architecture. Drivers wishing to use this stuff need to add new methods. Signed-off-by: Alan Cox commit 4d7c5b301d8dd5708787f427a240dcf2470de8b6 Author: Alan Cox Date: Wed Sep 3 10:12:22 2008 +1000 tty-move-special-cases Carry on pushing code out of tty_io when it belongs to other drivers. I'm not 100% happy with some of this and it will be worth revisiting some of the exports later when the restructuring work is done. commit e453513b51a69afce8b6c7c80e1babd2e8b14ac8 Author: Alan Cox Date: Wed Sep 3 10:12:22 2008 +1000 tty-fix-shutdown Right now there are various drivers that try to use tty->count to know when they get the final close. Aristeau Rozanski showed while debugging the vt sysfs race that this isn't entirely safe. Instead of driver side tricks to work around this introduce a shutdown which is called when the tty is being destructed. This also means that the shutdown method is tied into the refcounting. Use this to rework the console close/sysfs logic. Remove lots of special case code from the tty core code. The pty code can now have a shutdown() method that replaces the special case hackery in the tree free up paths. Signed-off-by: Alan Cox commit f2469c260cfa94b71af1c1ef02c018349dc183d8 Author: Alan Cox Date: Wed Sep 3 10:12:22 2008 +1000 vt-remove-bogus-lockdrop For hysterical raisins the vt layer drops and retakes locks in the write method. This is a left over from the days when user/kernel data was passed directly to the tty not pre-buffered. Signed-off-by: Alan Cox commit 948c07af399a5cee2f4089474377d084ed14f0af Author: \"Will Newton\ Date: Wed Sep 3 10:12:21 2008 +1000 8250-remove-a-few-inlines-of-dubious-value Remove some inlines from various functions that are called once, are too big to inline, or are called only from slow path code. This saves around 300 bytes of code for me. Signed-off-by: Will Newton Signed-off-by: Andrew Morton Signed-off-by: Alan Cox commit 790c4dc86a037ec06ccf624cf7949ee5dc697a7f Author: Jiri Slaby Date: Wed Sep 3 10:12:21 2008 +1000 char-sx-fix-io-unmapping board->base is increased for CF cards after mapping. Use board->base2 for unmapping the region, since it holds the original/correct address. Signed-off-by: Jiri Slaby Signed-off-by: Andrew Morton Signed-off-by: Alan Cox commit d3bfce87587ae1e7639fbe3fbdc039771618698f Author: Jiri Slaby Date: Wed Sep 3 10:12:21 2008 +1000 char-cyclades-remove-bogus-iomap readl/writel are not expected to accept iomap return value. Replace bogus mapping by standard ioremap. Signed-off-by: Jiri Slaby Signed-off-by: Andrew Morton Signed-off-by: Alan Cox commit 528e5140c30fad5432b1739ab417998fdd109567 Author: Alan Cox Date: Wed Sep 3 10:12:21 2008 +1000 tty-fix-pty The open path for ptmx slaves is via the ptmx device. Opening them any other way is not allowed. Vegard Nossum found that previously this was not the case and mknod foo c 128 42; cat foo would produce nasty diagnostics commit 6f6d85ec054b2a0408b135bee59d4efc78f447ec Author: Alan Cox Date: Wed Sep 3 10:12:20 2008 +1000 tty-tiocrs485 JP Tosoni observed: "About a RS485 ioctl: could you consider the attached files which are already in the Linux kernel (in include/asm-cris). They define a TIOCSERSETRS485 (ioctl.h), and the data structure (rs485.h) with allows to specify timings. Sounds just like what we want ?" and he's right: sort of. Rework the structure to use flag bits and make the time delay a fixed sized field so we don't get 32/64bit problems. Add the ioctls to x86 so that people know what to add to their platform of choice. Signed-off-by: Alan Cox commit 27f7ec89ca60557f746fb795d0c02500ecf965bb Author: Alan Cox Date: Wed Sep 3 10:12:20 2008 +1000 tty-current-fix-abusers Various people outside the tty layer still stick their noses in behind the scenes. We need to make sure they also obey the locking and referencing rules. commit f0860817871ba86e9c6349bae3f62e12c39bb430 Author: Alan Cox Date: Wed Sep 3 10:12:19 2008 +1000 tty-current-locking Currently it is sometimes locked by the tty mutex and sometimes by the sighand lock. The latter is in fact correct and now we can hand back referenced objects we can fix this up without problems around sleeping functions. commit 1843ca7f78a4c91bedafd51fe18cc978dd40e94b Author: Alan Cox Date: Wed Sep 3 10:12:19 2008 +1000 tty-fix-vhangup We now have the infrastructure to sort this out but rather than teaching the syscall tty lock rules we move the hard work into a tty helper commit 3a629d128975a1c8907d17775110f53879878980 Author: Alan Cox Date: Wed Sep 3 10:12:19 2008 +1000 tty-kref-mxser commit 6eef3c3e823f8fbee118990fce0af80487ef7238 Author: Alan Cox Date: Wed Sep 3 10:12:19 2008 +1000 tty-kref-stallion Use tty_port_init and krefs in the stallion drivers to protect us from devices going away underneath us. As with the other drives some rearranging is done to pass the tty structure down properly on the user side. commit a23d31fbaa93cc9d734d1db4a6a990258e2d86cb Author: Alan Cox Date: Wed Sep 3 10:12:18 2008 +1000 tty-misc-kref Rather than blindly keep taking krefs we reorder the code in a few places to pass the tty down to the right place (which is important as from the user side it is not the case that tty == port->tty in all situations). For the irq and related paths use the krefs to stop the tty being freed under us. Signed-off-by: Alan Cox commit b889f6af9276d7705cfcf5bac51a3e28fb583e5d Author: Alan Cox Date: Wed Sep 3 10:12:18 2008 +1000 tty-usbserial-kref Use kref in the USB serial drivers so that we don't free tty structures from under the URB receive handlers as has historically been the case if you were unlucky. This also gives us a framework for general tty drivers to use tty_port objects and refcount. Contains two err->dev_err changes merged together to fix clashes in the -next tree. Signed-off-by: Alan Cox commit 36777dc51180e1fcbf481de30af7d15b3bb1ae38 Author: Alan Cox Date: Wed Sep 3 10:12:18 2008 +1000 tty-move-write This is pure tty code so put it in the tty layer where it can be with the locking relevant material it uses Signed-off-by: Alan Cox commit b689ad2b010f09626a6158e1213a075a1aa9f299 Author: Alan Cox Date: Wed Sep 3 10:12:18 2008 +1000 tty-kref-get-current-tty We now return a kref covered tty reference. That ensures the tty structure doesn't go away when you have a return from get_current_tty. This is not enough to protect you from most of the resources being freed behind your back - yet. Signed-off-by: Alan Cox commit 3faad8764e04ec0fc70b11e23aa8c2c660d6f4be Author: Alan Cox Date: Wed Sep 3 10:12:17 2008 +1000 tty-kref-modcount The tty layer keeps driver module counts that are used so the driver knows when it can be unloaded. For obvious reasons we want to tie that to the refcounting properly. At this point the driver side itself isn't refcounted nicely but we can do that later and kref the drivers. Signed-off-by: Alan Cox commit 8af5ac9ca5d42ff5307f0db45199113f7d08f61a Author: Alan Cox Date: Wed Sep 3 10:12:17 2008 +1000 tty-kref Introduce a kref to the tty structure and use it to protect the tty->signal tty references. For now we don't introduce it for anything else. Signed-off-by: Alan Cox commit 958dd669f1d6445e0ad6a66774bf97e62037fd58 Author: Alan Cox Date: Wed Sep 3 10:12:17 2008 +1000 tty-ldisc-for-pps Add a new line discipline for "pulse per second" devices connected to a serial port. Signed-off-by: Rodolfo Giometti Signed-off-by: Alan Cox commit a322d12aeb78e09ddcd4b5dfa73eae4635283f1e Author: Alan Cox Date: Wed Sep 3 10:12:17 2008 +1000 tty-split-port Not much in it yet but this will grow a lot Signed-off-by: Alan Cox commit fa164fd39c0cf7ff814cd3bfbfb4e5c38ac9b246 Author: Alan Cox Date: Wed Sep 3 10:12:16 2008 +1000 tty-split-buffering The two are basically independent chunks of code so lets split them up for readability and sanity. It also makes the API boundaries much clearer. Signed-off-by: Alan Cox commit 7395810070db4fdc5478fcf5e921560a9cb21119 Author: Alan Cox Date: Wed Sep 3 10:12:16 2008 +1000 tty-fixup-uml Signed-off-by: Alan Cox commit c1c19b833c6b84a1c5e1ff3aa7b240f8f7d64007 Author: Alan Cox Date: Wed Sep 3 10:12:16 2008 +1000 tty-move-tioclinux Right now we have ifdefs and hooks in the core ioctl handler for TIOCLINUX and then test if its a console. This is brain dead. Instead call the tioclinux helper from the relevant driver ioctl methods. Signed-off-by: Alan Cox commit ca809457a8eb3db81ce41420d151286893cc9030 Author: Alan Cox Date: Wed Sep 3 10:12:16 2008 +1000 blackfin-fix-uart-map Blackfin Serial Driver: Fix bug - request UART2/3 peripheral mapped interrupts in PIO mode From: Sonic Zhang Signed-off-by: Sonic Zhang Signed-off-by: Bryan Wu Signed-off-by: Alan Cox commit 44f4a6534a96aea789c425b62dc04898b325dee7 Author: Alan Cox Date: Wed Sep 3 10:12:16 2008 +1000 blackfin-fix-ircp-bug Blackfin Serial Driver: Fix bug - ircp fails on sir over Blackfin UART From: Graf Yang We now use the sir_dev/irtty_sir/uart/bfin_serial drivers framework to monitor the TX status. Signed-off-by: Graf Yang Signed-off-by: Bryan Wu Signed-off-by: Alan Cox commit ebf4d3c2ce147cdfb066fd7c04d9617c49ac43e9 Author: Alan Cox Date: Wed Sep 3 10:12:15 2008 +1000 blackfin-fix-stop-bug Blackfin Serial Driver: Fix bug - Don't call tx_stop in tx_transfer. From: Sonic Zhang Disable irq and return immediately. Signed-off-by: Sonic Zhang Signed-off-by: Bryan Wu Signed-off-by: Alan Cox commit 090d64dcaa236b6cfb6f1c4459b2a9c7cad691e2 Author: Alan Cox Date: Wed Sep 3 10:12:15 2008 +1000 blackfin-remove-useless-stop Blackfin Serial Driver: Remove useless stop From: Sonic Zhang Signed-off-by: Sonic Zhang Signed-off-by: Bryan Wu Signed-off-by: Alan Cox commit af76bca64750e4d3c3de51d5c4094ea93f200979 Author: Alan Cox Date: Wed Sep 3 10:12:15 2008 +1000 blackfin-common-vars Blackfin Serial Driver: move common variables out of serial headers and into the serial driver From: Mike Frysinger move common variables out of serial headers and into the serial driver and rename "nr_ports" to "nr_active_ports" so as to easily differentiat between BFIN_UART_NR_PORTS (the # of available) and nr_ports (the # of enabled) Signed-off-by: Mike Frysinger Signed-off-by: Bryan Wu Signed-off-by: Alan Cox commit d502450abadc2cd07566e2a693b4e00f6b8420fd Author: Alan Cox Date: Wed Sep 3 10:12:14 2008 +1000 blackfin-whitespace-trim Blackfin Serial Driver: trim trailing whitespace -- no functional changes From: Mike Frysinger Signed-off-by: Mike Frysinger Signed-off-by: Bryan Wu Signed-off-by: Alan Cox commit 436f20c21b505baff88b66dee01e448d484dfa51 Author: Alan Cox Date: Wed Sep 3 10:12:14 2008 +1000 blackfin-suspend-all Blackfin Serial Driver: Fix bug - should suspend/resume/remove all uart ports. From: Sonic Zhang Signed-off-by: Sonic Zhang Signed-off-by: Bryan Wu Signed-off-by: Alan Cox commit dd79223650ad4dd605d163e06b06023a5722bb68 Author: Alan Cox Date: Wed Sep 3 10:12:14 2008 +1000 blackfin-use-initdata Blackfin Serial Driver: use __initdata for data, not __init From: Mike Frysinger Signed-off-by: Mike Frysinger Signed-off-by: Bryan Wu Signed-off-by: Alan Cox commit 15b3230cb351fd6c49b485c18c5ea3584bfc38ce Author: Alan Cox Date: Wed Sep 3 10:12:14 2008 +1000 serial-remove-nr-irq There are plans afoot to make the IRQ ranges dynamic. In that situation we don't want drivers having their own huge arrays for per IRQ data so use a hash Signed-off-by: Alan Cox commit a4b06e912e3c4095b84f9b25e0c024602a1db548 Author: Alan Cox Date: Wed Sep 3 10:12:14 2008 +1000 epca-port-init Signed-off-by: Alan Cox commit e704cf384401b0b8d3629108e5a279ed79abb2f6 Author: Adrian Bunk Date: Wed Sep 3 10:12:13 2008 +1000 mcfserial-goes-byebye This patch contains the scheduled removal of the obsolete SERIAL_COLDFIRE driver. Signed-off-by: Adrian Bunk Signed-off-by: Alan Cox commit 70cdd2ea8de98191ecaecb929bbea494743d2a2a Author: Julia Lawall Date: Wed Sep 3 10:12:13 2008 +1000 hvc-put-tty The call to put_tty_driver is out of place and is applied to the wrong argument. The function enclosing the patched code calls alloc_tty_driver and stores the result in drv. Subsequently, there are two occurrences of error handling code, one making a goto to put_tty and one making a goto to stop_thread. At the point of the first one the assignment hvc_driver = drv has not yet been executed, and from inspecting the rest of the file it seems that hvc_driver would be NULL. Thus the current call to put_tty_driver is useless, and one applied to drv is needed. The goto stop_thread is in the error handling code for a call to tty_register_driver, but the error cases in tty_register_driver do not free its argument, so it should be done here. Thus, I have moved the put_tty label after the stop_thread label, so that put_tty_driver is called in both cases. The semantic match that finds this problem is as follows: (http://www.emn.fr/x-info/coccinelle/) // @r exists@ local idexpression x; expression E,f; position p1,p2,p3; identifier l; statement S; @@ x = alloc_tty_driver@p1(...) ... if (x == NULL) S ... when != E = x when != put_tty_driver(x) goto@p2 l; ... when != E = x when != f(...,x,...) when any ( return \(0\|x\); | return@p3 ...; ) @script:python@ p1 << r.p1; p2 << r.p2; p3 << r.p3; @@ print "%s: call on line %s not freed or saved before return on line %s via line %s" % (p1[0].file,p1[0].line,p3[0].line,p2[0].line) // Signed-off-by: Julia Lawall Signed-off-by: Alan Cox commit e8d67a3a69a5c9df035ca4931480662c1e05a3e0 Author: Julia Lawall Date: Wed Sep 3 10:12:13 2008 +1000 cris-put-tty alloc_tty_driver is called at the beginning of the function containing the lines of code shown in the patch. Thus, put_tty_driver is needed before returning in the error handling code. The semantic match that finds this problem is as follows: (http://www.emn.fr/x-info/coccinelle/) // @nr exists@ local idexpression x; expression E,f; position p1,p2,p3; identifier l; statement S; @@ x = alloc_tty_driver@p1(...) ... if (x == NULL) S ... when != E = x when != put_tty_driver(x) when != goto l; ( return \(0\|x\); | return@p3 ...; ) @script:python@ p1 << nr.p1; p3 << nr.p3; @@ print "%s: call on line %s not freed or saved before return on line %s" % (p1[0].file,p1[0].line,p3[0].line) // Signed-off-by: Julia Lawall Signed-off-by: Alan Cox commit f9b107b5995f739fe985562cdb4529dd37ae48d4 Author: Elias Oltmanns Date: Wed Sep 3 10:12:11 2008 +1000 ide: Two fixes regarding memory allocation In function ide_devset_execute() we should use __GFP_WAIT rather than GFP_KERNEL. Also, the allocation cannot possibly fail at that point. More importantly, there is a potential memory leak in the device probing code. The infrastructure seems rather complex and I hope I haven't messed anything up by trying to fix this. Signed-off-by: Elias Oltmanns [bart: remove superfluous ide_lock taking] Signed-off-by: Bartlomiej Zolnierkiewicz commit 5723e148564232e6c1b824c658e268d1d36f5f9c Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:12:11 2008 +1000 ide-disk: move /proc handling to ide-disk_proc.c (take 3) While at it: - idedisk_capacity() -> ide_disk_capacity() - idedisk_proc[] -> ide_disk_proc[] - idedisk_settings[] -> ide_disk_settings[] v2/3: Build fix for CONFIG_IDE_PROC_FS=n from Elias Oltmanns. Signed-off-by: Bartlomiej Zolnierkiewicz commit bc92cfa1173f5eb7e51654e010526b400d37362b Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:12:11 2008 +1000 ide-disk: move all ioctl handling to ide-disk_ioctl.c While at it: - idedisk_ioctl() -> ide_disk_ioctl() Signed-off-by: Bartlomiej Zolnierkiewicz commit 75971b6039a6e605b6ac4bd0dd2ba14547170705 Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:12:11 2008 +1000 ide-floppy: move /proc handling to ide-floppy_proc.c (take 2) While at it: - idefloppy_capacity() -> ide_floppy_capacity() - idefloppy_proc[] -> ide_floppy_proc[] - idefloppy_settings[] -> ide_floppy_settings[] v2: Build fix for CONFIG_IDE_PROC_FS=n from Elias Oltmanns. Cc: Borislav Petkov Signed-off-by: Bartlomiej Zolnierkiewicz commit 9d08dc0f9d61409fabcdbc75ae764e4408ee1d58 Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:12:11 2008 +1000 ide-floppy: move all ioctl handling to ide-floppy_ioctl.c (take 2) While at it: - idefloppy_ioctl() -> ide_floppy_ioctl() v2: Fix for idefloppy_ioctl name change from Stephen Rothwell. Cc: Borislav Petkov Signed-off-by: Bartlomiej Zolnierkiewicz commit 945f1723a3e96a2c6b40b5defb9c2f00cacc06fe Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:12:10 2008 +1000 ide-cd: no need to zero drive->special.all Cc: Borislav Petkov Signed-off-by: Bartlomiej Zolnierkiewicz commit 3a5c306c4c2ec68b4a5adc020498769deacbeaeb Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:12:10 2008 +1000 ide: set IDE_AFLAG_DRQ_INTERRUPT in do_identify() Set IDE_AFLAG_DRQ_INTERRUPT in do_identify() instead of ATAPI device drivers *_setup() methods. While at it: - use ata_id_cdb_intr() There should be no functional changes caused by this patch. Cc: Borislav Petkov Signed-off-by: Bartlomiej Zolnierkiewicz commit 93c1bdcfb4000b39c8ce0f4958971f39ebc4e067 Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:12:10 2008 +1000 ide: remove ide_host_alloc_all() * Remove no longer used ide_host_alloc_all(). * Add MAX_HOST_PORTS define and use it instead of MAX_HWIFS as the maximum number of host ports possible. Signed-off-by: Bartlomiej Zolnierkiewicz commit 199d97cd5d087f9eb84c0fcd66bcfd16666e6ec2 Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:12:09 2008 +1000 ide-generic: remove no longer needed ide_probe_legacy() There is now a generic solution [ide_generic_check_pci_legacy_iobases()] so MIPS-specific ide_probe_legacy() is no longer necessary. Cc: Ralf Baechle Signed-off-by: Bartlomiej Zolnierkiewicz commit 8cb1c72830c9f3cfdb12c2d4e00e709ed343dc9e Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:12:09 2008 +1000 ide-generic: no need to probe all ports at once Signed-off-by: Bartlomiej Zolnierkiewicz commit b7789ccabc2ec481bde0304070de0e5fd8c5f1e1 Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:12:09 2008 +1000 ide: ->ide_dma_clear_irq() -> ->clear_irq() * Rename ->ide_dma_clear_irq method to ->clear_irq and move it from ide_hwif_t to struct ide_port_ops. * Move ->waiting_for_dma check inside ->clear_irq method. * Move ->dma_base check inside ->clear_irq method. piix.c: * Add ich_port_ops and remove init_hwif_ich() wrapper. There should be no functional changes caused by this patch. Acked-by: Sergei Shtylyov Signed-off-by: Bartlomiej Zolnierkiewicz commit 96dc02f0a9e2e536b7292f1bddc6b234d31ff3fd Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:12:09 2008 +1000 ide: use unique names for struct pci_driver instances Noticed-by: Russell King Signed-off-by: Bartlomiej Zolnierkiewicz commit f349b1e806df8c4ac8370eab84ddd4c372d662a8 Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:12:08 2008 +1000 ide: merge all TASKFILE_NO_DATA data phase handlers into taskfile_no_intr() * Add 'struct task_s' to ide_hwif_t and init it to the current command in do_rw_taskfile(). * Merge all TASKFILE_NO_DATA data phase handlers into taskfile_no_intr(). Signed-off-by: Bartlomiej Zolnierkiewicz commit adb5458d6321ac150c16a16b1d4ddbd550b8b932 Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:12:08 2008 +1000 ide: factor out reset error reporting from reset_pollfunc() Factor out reset error reporting from reset_pollfunc() to ide_reset_report_error() helper. While at it: - fix KERN_* printk() levels - remove 'switch ()' Acked-by: Sergei Shtylyov Signed-off-by: Bartlomiej Zolnierkiewicz commit 432996d79eb85ceed8f2f6719d0eacbad9e22da5 Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:12:08 2008 +1000 ide: convert 'pio_mode' device setting to use DS_SYNC flag * Convert 'pio_mode' device setting to use DS_SYNC flag. * Remove unused special_t.b.{set_tune,serviced} and ide_drive_t.tune_req. Signed-off-by: Bartlomiej Zolnierkiewicz commit eeb5dcfe5416eb94bd04e821ceaa444806471aa9 Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:12:08 2008 +1000 ide: remove [ata_]select_t * Use 'drive->dn & 1' in ide_init_disk(). * remove [ata_]select_t. While at it: * Use ATA_DEVICE_OBS define in ide_port_init_devices_data(). Acked-by: Sergei Shtylyov Signed-off-by: Bartlomiej Zolnierkiewicz commit 66f9303006e5768afb3048aa32e6eb02af59c797 Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:12:08 2008 +1000 ide: use 'drive->dn & 1' instead of drive->select.b.unit * Call ide_port_init_devices() in ide_host_register() also if 'struct ide_port_info *d' is not available. * Init drive->dn in ide_port_init_devices() instead of ide_probe_port() so it is valid also in ->init_dev. * Pass device number to ide_dev_apply_params(). * Use 'drive->dn & 1' instead of drive->select.b.unit. There should be no functional changes caused by this patch. Signed-off-by: Bartlomiej Zolnierkiewicz commit 0274c32b0821f98f27c7d8623a915cd1b2f5c69f Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:12:07 2008 +1000 cy82c693: remove no longer needed CY82C693_DEBUG_LOGS code Having CY82C693_DEBUG_INFO is enough nowadays. Signed-off-by: Bartlomiej Zolnierkiewicz commit cd8ef90b42ea5949f90a957ae2f90376bfd60901 Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:12:07 2008 +1000 cy82c693: remove dead CY82C693_SETDMA_CLOCK code Remove dead CY82C693_SETDMA_CLOCK code and now not needed init_chipset_cy82c693(). Signed-off-by: Bartlomiej Zolnierkiewicz commit fd0c38c4b6e8f22b7ae8c0f87d35a2779ce8b5b3 Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:12:07 2008 +1000 ide: sanitize ide*_pm_* enums * Move ide*_pm_* enums from ide-io.c to . * idedisk_pm_* -> ide_pm_* * ide_pm_state_* -> ide_pm_* * No need to set ide_pm_* enums to the fixed values. * Uppercase ide_pm_* enums. * Fix/update comments. Signed-off-by: Bartlomiej Zolnierkiewicz commit 1f4fd398ddc85de6d8b391e9c96736e74da5ff55 Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:12:07 2008 +1000 ide: fix HDIO_DRIVE_TASK[FILE] ioctls for CHS commands on LBA devices Add IDE_DFLAG_LBA device flag and use it instead of ->select.b.lba. Since ->tf_load uses ->select.all for ATA Device/Head register this fixes HDIO_DRIVE_TASK[FILE] ioctls for CHS commands on LBA devices. Signed-off-by: Bartlomiej Zolnierkiewicz commit a08e9dfa1428cdd9d35e7e40cfdba90a57d45dee Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:12:06 2008 +1000 ide: remove superfluous ->waiting_for_dma checks Acked-by: Sergei Shtylyov Signed-off-by: Bartlomiej Zolnierkiewicz commit 49232ae4a996830a92c69c7a50cc27dda34c3afd Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:12:06 2008 +1000 ide: remove superfluous ->dma field from ide_hwif_t Acked-by: Sergei Shtylyov Signed-off-by: Bartlomiej Zolnierkiewicz commit 63a39a1efd8b0c90e7d7fbd7284e6731df8243c9 Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:12:06 2008 +1000 ide: remove superfluous ->media field from ide_driver_t Acked-by: Sergei Shtylyov Signed-off-by: Bartlomiej Zolnierkiewicz commit 2482e69db8cf0da82fdd66472c050998b5060d05 Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:12:06 2008 +1000 ide: DMA_PIO_RETRY -> IDE_DFLAG_DMA_PIO_RETRY Add IDE_DFLAG_DMA_PIO_RETRY and use it instead of ide_drive_t.state + DMA_PIO_RETRY. There should be no functional changes cause by this patch. Signed-off-by: Bartlomiej Zolnierkiewicz commit a2d2af80144f6ec28d2a157416762363531eb672 Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:12:05 2008 +1000 ide: add device flags Add 'unsigned long dev_flags' to ide_drive_t and convert bitfields to IDE_DFLAG_* flags. While at it: - IDE_DFLAG_ADDRESSING -> IDE_DFLAG_LBA48 - fixup some comments - remove needless g->flags zeroing from ide*_probe() There should be no functional changes caused by this patch. Signed-off-by: Bartlomiej Zolnierkiewicz commit aada89ccaa5e82dae8fd5612de4ef6f63f37c46c Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:12:05 2008 +1000 ide-disk: add ide_do_setfeature() helper Add ide_do_setfeature() helper and convert set_{wcache,acoustic}() to use it. There should be no functional changes caused by this patch. Acked-by: Sergei Shtylyov Signed-off-by: Bartlomiej Zolnierkiewicz commit 13fd3fc0b66f8999149eb4a146c34f05bf36767f Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:12:05 2008 +1000 ide-disk: set_addressing() fixes * Return -EIO if arg > 0 and LBA48 is unsupported. * No need to reset ->addressing. * Make ->addressing a single bit flag. Signed-off-by: Bartlomiej Zolnierkiewicz commit 2af2f8ce853bf4e33c5d5eb7973c9198a54f6eee Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:12:05 2008 +1000 ide: fix IDE ACPI for slave device-only configurations ACPI _GTM / _PS0 / _STM were not called if only slave device was present. Signed-off-by: Bartlomiej Zolnierkiewicz commit af037886cbc554c86ab92a0f70cb0b722e9b1a51 Author: Borislav Petkov Date: Wed Sep 3 10:12:04 2008 +1000 ide-floppy: add a debug_mask module parameter ... with which to control to verbosity of debug messages on module load time. Signed-off-by: Borislav Petkov [bart: no need to zero debug_mask + move module_param() closer debug_mask] [bart: init drive->debug_mask in ide_floppy_probe() not in idefloppy_open()] Signed-off-by: Bartlomiej Zolnierkiewicz commit b231f041e1f90b637d593125e2170de9e9fd5900 Author: Borislav Petkov Date: Wed Sep 3 10:12:04 2008 +1000 ide-floppy: convert driver to the new debugging macro Also: - leave in the possibility for optimizing away all debugging macros - add a PFX macro and prepend all printk calls with it for consistency - change idefloppy_create_rw_cmd's 1st arg from idefloppy_floppy_t * to ide_drive_t *. - add a missing printk-level in idefloppy_init - fix minor checkpatch warnings Signed-off-by: Borislav Petkov Signed-off-by: Bartlomiej Zolnierkiewicz commit 4f7bf363bc4db18e51d90bd65e75b25715eb6047 Author: Borislav Petkov Date: Wed Sep 3 10:12:04 2008 +1000 ide: add a driver-wide debugging macro Add __ide_debug_log() debugging macro which is controlled by drive->debug_mask. The macro has to have the macro DRV_NAME defined in each driver before use. Also, add different debugging levels depending on the functionality debugged. Signed-off-by: Borislav Petkov Signed-off-by: Bartlomiej Zolnierkiewicz commit 81a748586068e875d36cf7fc8d74c6a817ca3e99 Author: Borislav Petkov Date: Wed Sep 3 10:12:04 2008 +1000 ide: add drive->debug_mask switch Add a debugging on/off switch for controlling driver debugging messages dynamically. Signed-off-by: Borislav Petkov Signed-off-by: Bartlomiej Zolnierkiewicz commit d6075e19bc06f7edb352f8b37d8791f6435300d3 Author: Borislav Petkov Date: Wed Sep 3 10:12:03 2008 +1000 ide: unify conversion macros Introduce to_ide_drv() and ide_drv_g() macros and replace the respective definitions of similar ones in each driver. There should be no functionality change resulting from this patch. Signed-off-by: Borislav Petkov Signed-off-by: Bartlomiej Zolnierkiewicz commit 11fce2ad88e613ddd90d895ebbc7b787a41c3084 Author: Adrian Bunk Date: Wed Sep 3 10:12:03 2008 +1000 xtensa: remove dead CONFIG_BLK_DEV_IDE code I don't know why this was there, but it was dead code. Signed-off-by: Adrian Bunk Cc: chris@zankel.net Signed-off-by: Bartlomiej Zolnierkiewicz commit 6aef3477918fe2605c8bea8efec98e3e9f11d446 Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:12:03 2008 +1000 ide: remove unnecessary MAX_HWIFS checks from ide-probe.c MAX_HWIFS is now always equal to the number of IDE major numbers. Signed-off-by: Bartlomiej Zolnierkiewicz commit 1a23dc9675aab5c7bf7e8f69d98e22ef30d41998 Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:12:03 2008 +1000 ide: remove CONFIG_BLK_DEV_IDE config option (take 2) Because hd.c was moved to drivers/block/ this config option is superfluous now and may be removed. v2: Fix drivers/ide/Makefile (noticed by Adrian Bunk). Cc: Adrian Bunk Signed-off-by: Bartlomiej Zolnierkiewicz commit 38d72ee1838fa4430a3e608aee4e705c37b1235d Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:12:03 2008 +1000 ide: make ide_transfer_pc() static * Move ->ticks field from struct ide_floppy_obj to ide_drive_t. * Move idefloppy_transfer_pc() to ide-atapi.c and make ide_transfer_pc() use it. * Always use ide_transfer_pc as a handler in ide_issue_pc(). * Remove no longer used idefloppy_start_pc_transfer(), ide*_transfer_pc() and 'handler' argument from ide_issue_pc(). * Make ide_transfer_pc() static. While at it: * idefloppy_transfer_pc() -> ide_delayed_transfer_pc() * IDEFLOPPY_TICKS_DELAY -> IDEFLOPPY_PC_DELAY * ->ticks -> ->pc_delay There should be no functional changes caused by this patch. Cc: Borislav Petkov Signed-off-by: Bartlomiej Zolnierkiewicz commit 3ed3e22a3f3b8c7873a0cdf7948f886e22b9851e Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:12:02 2008 +1000 ide: make ide_pc_intr() static * Always use ide_pc_intr as a handler in ide_pc_intr(). * Remove no longer used ide*_pc_intr() and 'handler' argument from ide_{transfer_pc,pc_intr}(). * Make ide_pc_intr() static. There should be no functional changes caused by this patch. Cc: Borislav Petkov Signed-off-by: Bartlomiej Zolnierkiewicz commit f8bf425b5d13a3dc85ce977351b6d6d4f196f4d3 Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:12:02 2008 +1000 ide: add ->pc_{update,io}_buffers methods Add ->pc_{update,io}_buffers methods to ide_drive_t and use them instead of {update,io}_buffers ide_pc_intr() arguments. There should be no functional changes caused by this patch. Cc: Borislav Petkov Signed-off-by: Bartlomiej Zolnierkiewicz commit 73c83b0205bc23896b86cd755eaea14b2245115f Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:12:02 2008 +1000 ide: add ide_retry_pc() helper * Add ide_create_request_sense_cmd() and ide_retry_pc() helpers and convert ide-{atapi,floppy,tape}.c to use them. * Remove no longer used ide*_create_request_sense_cmd(), ide*_retry_pc() and 'retry_pc' argument from ide_pc_intr(). * Make ide_queue_pc_head() static. There should be no functional changes caused by this patch. Cc: Borislav Petkov Signed-off-by: Bartlomiej Zolnierkiewicz commit 7882707ece539dedfc98a4feab509f193d16ceb2 Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:12:02 2008 +1000 ide: add request_sense_{pc,rq} to ide_drive_t Add 'struct ide_atapi_pc request_sense_pc' and 'request request_sense_rq' to ide_drive_t and use them instead of fields in struct ide_{floppy,tape}_obj. There should be no functional changes caused by this patch. Cc: Borislav Petkov Signed-off-by: Bartlomiej Zolnierkiewicz commit 92381cf0c011daec9244724b47c39888fdfec0a6 Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:12:01 2008 +1000 ide: drop 'timeout' and 'expiry' arguments from ide_pc_intr() * Move idescsi_expiry() to ide-atapi.c. * Move get_timeout() to . * Drop 'timeout' and 'expiry' arguments from ide_pc_intr(). While at it: * idescsi_expiry() -> ide_scsi_expiry() * get_timeout() -> ide_scsi_get_timeout() There should be no functional changes caused by this patch. Cc: Borislav Petkov Signed-off-by: Bartlomiej Zolnierkiewicz commit 0451835a5b82b77bed395f3d61d90da731b0174d Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:12:01 2008 +1000 ide: add pointer to the current packet command to ide_drive_t * Add pointer to the current packet command (struct ide_atapi_pc *pc) to ide_drive_t and use it instead of the pointer in struct ide_*_obj. * Use drive->pc in ide_{issue,transfer}_pc() and ide_pc_intr() instead of 'pc' argument. There should be no functional changes caused by this patch. Cc: Borislav Petkov Signed-off-by: Bartlomiej Zolnierkiewicz commit ca7968a6582f77bf97f302851a156b4fdf4e0da0 Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:12:01 2008 +1000 ide: drop dsc_handle argument from ide_pc_intr() * Add 'int dsc' argument to ->pc_callback method. * Call ide_tape_handle_dsc() internally in ide_tape_callback() if dsc argument is set and update ide_pc_intr() accordingly. There should be no functional changes caused by this patch. Cc: Borislav Petkov Acked-by: Sergei Shtylyov Signed-off-by: Bartlomiej Zolnierkiewicz commit a5f0af423c395bf4b860f4bc98fe6dbe82d3f83c Author: Elias Oltmanns Date: Wed Sep 3 10:12:01 2008 +1000 ide: Remove ide_spin_wait_hwgroup() and use special requests instead Use a special request for serialisation purposes and get rid of the awkward ide_spin_wait_hwgroup(). This also involves converting the ide_devset structure so it can be shared by the /proc and the ioctl code. Signed-off-by: Elias Oltmanns [bart: use rq->cmd[] directly] Signed-off-by: Bartlomiej Zolnierkiewicz commit b2cdf84a5149ddda811d10a5c135c916712f2b14 Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:12:00 2008 +1000 ide: move IDE{FLOPPY,TAPE}_WAIT_CMD defines to While at it: * IDE{FLOPPY,TAPE}_WAIT_CMD -> WAIT_{FLOPPY,TAPE}_CMD * Use enum for WAIT_* defines. There should be no functional changes caused by this patch. Acked-by: Borislav Petkov Signed-off-by: Bartlomiej Zolnierkiewicz commit 6a342cd102047950cee8bdeddb2b70efbc281c22 Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:12:00 2008 +1000 ide: add ide_do_test_unit_ready() helper * Add ide_do_test_unit_ready() helper and convert ide-{floppy,tape}.c to use it. * Remove no longer used idetape_create_test_unit_ready_cmd(). There should be no functional changes caused by this patch. Acked-by: Borislav Petkov Acked-by: Sergei Shtylyov Signed-off-by: Bartlomiej Zolnierkiewicz commit d49736ce9c0095ca18940ca7372d80992f614386 Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:12:00 2008 +1000 ide: add ide_do_start_stop() helper * Add ide_do_start_stop() helper and convert ide-{floppy,tape}.c to use it. * Remove no longer used idefloppy_create_start_stop_cmd() and idetape_create_load_unload_cmd(). There should be no functional changes caused by this patch. Acked-by: Borislav Petkov Signed-off-by: Bartlomiej Zolnierkiewicz commit 38d53c378538e18d07aef57d137ebeca0e271f11 Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:11:59 2008 +1000 ide: add ide_set_media_lock() helper * Set IDE_AFLAG_NO_DOORLOCK in idetape_get_mode_sense_result(), check it in ide_tape_set_media_lock() and cleanup idetape_create_prevent_cmd(). * Set IDE_AFLAG_NO_DOORLOCK in ide_floppy_create_read_capacity_cmd() and check it instead of IDE_AFLAG_CLIK_DRIVE in ide_floppy_set_media_lock(). * Add ide_set_media_lock() helper and convert ide-{floppy,tape}.c to use it. * Remove no longer used ide*_create_prevent_cmd()/ide*_set_media_lock(). * Update comment in accordingly. Acked-by: Borislav Petkov Signed-off-by: Bartlomiej Zolnierkiewicz commit 0b137d89a0d3f87e4d0c28097baea4cb2f81fb2e Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:11:59 2008 +1000 ide-floppy: move floppy ioctls handling to ide-floppy_ioctl.c While at it: - idefloppy_create_read_capacity_cmd() -> ide_floppy_create_read_capacity_cmd() - idefloppy_create_mode_sense_cmd() -> ide_floppy_create_mode_sense_cmd() - idefloppy_create_request_sense_cmd() -> ide_floppy_create_request_sense_cmd() - idefloppy_create_format_unit_cmd() -> ide_floppy_create_format_unit_cmd() - idefloppy_get_sfrp_bit() -> ide_floppy_get_sfrp_bit() Acked-by: Borislav Petkov Signed-off-by: Bartlomiej Zolnierkiewicz commit da9a5d795a560216d9193cdd052de5b9922c40ac Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:11:59 2008 +1000 ide-floppy: ->{srfp,wp} -> IDE_AFLAG_{SRFP,WP} Add IDE_AFLAG_{SRFP,WP} drive->atapi_flags and use them instead of ->{srfp,wp} struct ide_floppy_obj fields. There should be no functional changes caused by this patch. Acked-by: Borislav Petkov Signed-off-by: Bartlomiej Zolnierkiewicz commit 2477a7afc564532e01a191ce5b8ab22d24324026 Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:11:59 2008 +1000 ide: add ide_queue_pc_tail() helper * Add ide_queue_pc_tail() and convert ide-{floppy,tape}.c to use it instead of ide*_queue_pc_tail(). * Remove no longer used ide*_queue_pc_tail(). There should be no functional changes caused by this patch. Acked-by: Borislav Petkov Acked-by: Sergei Shtylyov Signed-off-by: Bartlomiej Zolnierkiewicz commit f063d7648c45fa1b33a00caa20ca6ecdb28fb8ac Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:11:59 2008 +1000 ide: add ide_queue_pc_head() helper * Move REQ_IDETAPE_* enums to . * Add ide_queue_pc_head() and convert ide-{floppy,tape}.c to use it instead of ide*_queue_pc_head(). * Remove no longer used ide*_queue_pc_head(). There should be no functional changes caused by this patch. Acked-by: Borislav Petkov Acked-by: Sergei Shtylyov Signed-off-by: Bartlomiej Zolnierkiewicz commit b07669122aa9cb2a45146ec3e888e823a375000a Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:11:58 2008 +1000 ide: add ide_init_pc() helper * Add IDE_PC_BUFFER_SIZE define. * Add ide_init_pc() and convert ide-{floppy,tape}.c to use it instead of ide*_init_pc(). * Remove no longer used IDE*_PC_BUFFER_SIZE and ide*_init_pc(). There should be no functional changes caused by this patch. Acked-by: Borislav Petkov Acked-by: Sergei Shtylyov Signed-off-by: Bartlomiej Zolnierkiewicz commit dc2921f993f95ee08fe84ad6be4b3a1db49b0b11 Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:11:58 2008 +1000 ide-tape: add ide_tape_set_media_lock() helper Add ide_tape_set_media_lock() helper and convert idetape_mtioctop(), idetape_chrdev_open() and idetape_chrdev_release() to use it. There should be no functional changes caused by this patch (it is OK to modify ->door_locked if idetape_create_prevent_cmd() fails). Acked-by: Borislav Petkov Signed-off-by: Bartlomiej Zolnierkiewicz commit b42d3437f057cbfba3f82468ac2dcd7f83e4ef42 Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:11:58 2008 +1000 ide-floppy: add ide_floppy_set_media_lock() helper Add ide_floppy_set_media_lock() helper and convert idefloppy_open(), idefloppy_release() and ide_floppy_lockdoor() to use it. There should be no functional changes caused by this patch. Acked-by: Borislav Petkov Acked-by: Sergei Shtylyov Signed-off-by: Bartlomiej Zolnierkiewicz commit 7cab8ed49f4158e412907d37025efa337339f150 Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:11:58 2008 +1000 ide: add ide_io_buffers() helper * Make ->io_buffers method return number of bytes transferred. * Use ide_end_request() instead of idefloppy_end_request() in ide_floppy_io_buffers() and then move the call out to ide_pc_intr(). * Add ide_io_buffers() helper and convert ide-{floppy,scsi}.c to use it instead of ide*_io_buffers(). There should be no functional changes caused by this patch. Acked-by: Borislav Petkov Signed-off-by: Bartlomiej Zolnierkiewicz commit 010871acbe20759a278b9367a9ecb74f50dc698a Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:11:57 2008 +1000 ide-scsi: cleanup ide_scsi_io_buffers() Preparation for ide_{floppy,scsi}_io_buffers() unification. Acked-by: Borislav Petkov Signed-off-by: Bartlomiej Zolnierkiewicz commit 0d2eec9aca7706c0c361f5d9a7331bf2b9b20ec0 Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:11:57 2008 +1000 ide-floppy: fixup ide_floppy_io_buffers() map hwif->sg_{table,nents} on pc->{sg,sg_cnt} (multi-IRQs-per-sg fix) Acked-by: Borislav Petkov Signed-off-by: Bartlomiej Zolnierkiewicz commit 8d1316aa264ab257e6d68fc227eb386d7b8889d0 Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:11:57 2008 +1000 ide-floppy: remove MODE_SENSE_* defines Only MODE_SENSE_CURRENT (0x00) is ever used so just remove these defines and then drop no longer needed 'type' argument from idefloppy_create_mode_sense_cmd(). Cc: Borislav Petkov Acked-by: Sergei Shtylyov Signed-off-by: Bartlomiej Zolnierkiewicz commit 4dadf88a49c7f64fc85d074ab1b8ac6bb5fa88a5 Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:11:57 2008 +1000 ide-{floppy,tape}: remove packet command stack * Add 'struct ide_atapi_pc queued_pc' to struct ide_{floppy,tape}_obj and switch ide*_do_request() to use it (there can be only one active request for a given device). * Add 'struct ide_atapi_pc request_sense_pc' to struct ide_*_obj and switch ide*_retry_pc() to use it. * Remove needless {floppy,tape}->pc assignment from ide*_setup(). * Remove no longer needed ide*_next_pc_storage(), pc_stack[], rq_stack_index, IDE*_PC_STACK and DBG_PC_STACK. There should be no functional changes caused by this patch. Cc: Borislav Petkov Signed-off-by: Bartlomiej Zolnierkiewicz commit 3e1a613f18da07518d87e5f64cafa53f787d81dd Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:11:56 2008 +1000 ide-{floppy,tape}: remove request stack * Add 'struct request request_sense_rq' to struct ide_{floppy,tape}_obj and switch ide*_retry_pc() to use it (there can be only one REQUEST SENSE request active for a given device). * Remove no longer needed ide*_next_rq_storage(), rq_stack[] and rq_stack_index. * DBG_PCRQ_STACK -> DBG_PC_STACK * Update comments for IDE*_PC_STACK and idetape_queue_pc_{head,tail}(). There should be no functional changes caused by this patch. Cc: Borislav Petkov Signed-off-by: Bartlomiej Zolnierkiewicz commit fe5f7c6720a3909bc9944f9425b7f6de733bca12 Author: Borislav Petkov Date: Wed Sep 3 10:11:56 2008 +1000 ide-generic: handle probing of legacy io-ports v5 Avoid probing the io-ports in case an IDE PCI controller is present and it uses the legacy iobases. If we still want to enforce the probing, we do ide_generic.probe_mask=0x3f on the kernel command line. The iobase checking code is adapted from drivers/ata/pata_legacy.c after converting hex pci ids into their corresponding macros in . Also, check only BAR0/2 resources since those are guaranteed by the workaround in drivers/pci/probe.c:pci_setup_device(). Signed-off-by: Borislav Petkov Acked-by: Sergei Shtylyov Cc: Alan Cox [bart: trivial printk() fixups] Signed-off-by: Bartlomiej Zolnierkiewicz commit 2e6c438f3573fa0bdb5d8f837cce523228e7ef41 Author: Borislav Petkov Date: Wed Sep 3 10:11:56 2008 +1000 ide-floppy: use scatterlists for pio transfers Use hwif->sg_table for pio transfers instead of fumbling with block layer internals in the driver. Also, make debug statements more informative in .._do_request() while at it. Signed-off-by: Borislav Petkov [bart: fixup pc->b_count in idefloppy_blockpc_cmd()] [bart: add missing include (noticed by Stephen Rothwell)] Signed-off-by: Bartlomiej Zolnierkiewicz commit 33ce7447d6166d1db9d752b2c836082bcae6668c Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:11:56 2008 +1000 ide-tape: remove idetape_init_rq() idetape_init_rq() is only used in idetape_queue_pc_head() so inline it there. Cc: Borislav Petkov Signed-off-by: Bartlomiej Zolnierkiewicz commit 39685fc127018cb4db157e73a40ce876330f7bb3 Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:11:56 2008 +1000 ide-floppy: add ide_floppy_format_ioctl() helper * Factor out IDEFLOPPY_IOCTL_FORMAT_* ioctls handling from idefloppy_ioctl() to ide_floppy_format_ioctl(). While at it: * Pass 'drive' instead of 'floppy' to ide_floppy_format_unit(). * idefloppy_get_format_progress() -> ide_floppy_get_format_progress() There should be no functional changes caused by this patch. Cc: Borislav Petkov Signed-off-by: Bartlomiej Zolnierkiewicz commit a76242be91ad71904edb13712c171eb4d3d31214 Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:11:55 2008 +1000 ide-floppy: remove needless parens Cc: Borislav Petkov Signed-off-by: Bartlomiej Zolnierkiewicz commit 9d167b36354ea0d9a0148b27e16621f2c91ad9de Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:11:55 2008 +1000 ide: add ide_check_atapi_device() helper * Add ide_check_atapi_device() to ide-atapi.c and convert ide-{floppy,tape}.c to use it instead of ide*_identify_device(). While at it: * Add DRV_NAME defines to ide-{floppy,tape}.c. Cc: Borislav Petkov Signed-off-by: Bartlomiej Zolnierkiewicz commit 7c8417b692ba4f108067f5ddc6b5d658676ba7d5 Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:11:55 2008 +1000 ide: move ioctls handling to ide-ioctls.c * Move ioctls handling to ide-ioctls.c (except HDIO_DRIVE_TASKFILE for now). * Make ide_{cmd,task}() static. Signed-off-by: Bartlomiej Zolnierkiewicz commit 5ea7d8157680811091b443d0092c98dcf7d6670a Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:11:54 2008 +1000 ide: cleanup generic_ide_ioctl() * Fix intendation for the main 'switch ()'. * 'switch ()' -> 'if ()' for HDIO_DRIVE_TASKFILE case. * Move HDIO_SET_NICE case under HDIO_GET_NICE one. Signed-off-by: Bartlomiej Zolnierkiewicz commit f09693ac45d24ae230f2fa6fe10071721f58f12a Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:11:54 2008 +1000 ide: add ide_setting_ioctl() helper * Add struct ide_ioctl_devset representing ioctl device setting. * Add ide_setting_ioctl() helper for matching given ioctl and its parameters against table of ioctl device settings. * Convert ide_setting_ioctl() and idedisk_ioctl() to use ide_setting_ioctl(). * Un-export ide_setting_mtx. While at it: * {get,set}_lba_addressing() -> {get,set}_addressing() There should be no functional changes caused by this patch. Signed-off-by: Bartlomiej Zolnierkiewicz commit a2ee87c7e5651e95f17ece82bcbf6b2461913c61 Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:11:54 2008 +1000 ide: remove ->bus_state field from ide_hwif_t It is always set to BUSSTATE_ON. Signed-off-by: Bartlomiej Zolnierkiewicz commit 130ab28b72445a55a13ba070840dec8f99cd790c Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:11:54 2008 +1000 ide: add proper PCI PM support * Keep pointer to ->init_chipset method also in struct ide_host and set it in ide_host_alloc_all(). * Add ide_pci_suspend() and ide_pci_resume() helpers (default ->suspend and ->resume implementations). * ->init_chipset can no longer be marked __devinit. * Add proper PCI PM support to IDE PCI host drivers (rz1000.c and tc86c001.c are skipped for now since they need to be converted from using ->init_hwif to use ->init_chipset instead). Cc: "Rafael J. Wysocki" Signed-off-by: Bartlomiej Zolnierkiewicz commit dbdbd8c821000929b1e1b3567c0f58a86a965bca Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:11:53 2008 +1000 hpt366: add hpt3xx_disable_fast_irq() helper * Factor out disabling of "fast interrupt" prediction from init_hwif_hpt366() to hpt3xx_disable_fast_irq() helper. * Use hpt3xx_disable_fast_irq() in ->init_chipset instead of ->init_hwif method. This is a preparation for adding proper PCI PM support. While at it: * Cache chip type in chip_type variable in hpt3xx_disable_fast_irq(). There should be no functional changes caused by this patch. Cc: Sergei Shtylyov Signed-off-by: Bartlomiej Zolnierkiewicz commit a3bd8da7c3bf5ad55c4fe69824a55a5a2f96205e Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:11:53 2008 +1000 ide: lba_capacity_is_ok() -> ata_id_is_lba_capacity_ok() Rename lba_capacity_is_ok() to ata_id_is_lba_capacity_ok() and move it to (remove needless parens while at it). Cc: Jeff Garzik Signed-off-by: Bartlomiej Zolnierkiewicz commit 0aeec03b46dc1be3a341b3f8b0547bd965b17525 Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:11:53 2008 +1000 ide: ide_id_to_hd_driveid() -> ata_id_to_hd_driveid() Rename ide_id_to_hd_driveid() to ata_id_to_hd_driveid() and move it to . Cc: Jeff Garzik Signed-off-by: Bartlomiej Zolnierkiewicz commit 24dfadd545c8c53a1b80952f8479473598b526c5 Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:11:53 2008 +1000 ide: use ata_id_is_cfa() Use ata_id_is_cfa() in do_identify() instead of open-coding check for CompactFlash devices (the inline helper also takes care of detecting CFs advertising themselves as ATA disks). Signed-off-by: Bartlomiej Zolnierkiewicz commit f8a49fe54da1be1c894d1d339542290ba5634846 Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:11:53 2008 +1000 ide: ide_id_has_flush_cache_ext() -> ata_id_flush_ext_enabled() * Add ata_id_flush_ext_enabled() inline helper to . * ide_id_has_flush_cache_ext() -> ata_id_flush_ext_enabled() The latter one also checks if the command is marked as supported in word 83 and validity of words 83 & 86. Cc: Jeff Garzik Signed-off-by: Bartlomiej Zolnierkiewicz commit 77017347ff85135a2b017a4d60decd3bb4c51a6f Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:11:52 2008 +1000 ide: ide_id_has_flush_cache() -> ata_id_flush_enabled() * Add ata_id_flush_enabled() inline helper to . * ide_id_has_flush_cache() -> ata_id_flush_enabled() The latter one also checks if the command is marked as supported in word 83 and validity of words 83 & 86. Cc: Jeff Garzik Signed-off-by: Bartlomiej Zolnierkiewicz commit fa712205510bf5b8263022fe79225d69954f3e53 Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:11:52 2008 +1000 ide: check only for CACHE FLUSH command support in ide_id_has_flush_cache() All devices supporting CACHE FLUSH EXT command should also support CACHE FLUSH command so it is sufficient to check only for CACHE FLUSH in ide_id_has_flush_cache(). Signed-off-by: Bartlomiej Zolnierkiewicz commit 45bbbbe2a5768638de2edacb379eb41849c67f8a Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:11:52 2008 +1000 ide: idedisk_supports_lba48() -> ata_id_lba48_enabled() * Add ata_id_lba48_enabled() inline helper to . * idedisk_supports_lba48() -> ata_id_lba48_enabled() The latter one also checks validity of words 83 & 86. Cc: Jeff Garzik Signed-off-by: Bartlomiej Zolnierkiewicz commit 1c172bde0f0f2b287e517dcc3413dc6094228d08 Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:11:51 2008 +1000 ide: ide_dev_is_sata() -> ata_id_is_sata() * Use optimized ATA version check from Sergei in ata_id_is_sata(). * ide_dev_is_sata() -> ata_id_is_sata() Cc: Jeff Garzik Cc: Sergei Shtylyov Signed-off-by: Bartlomiej Zolnierkiewicz commit 593f986de66c7694209be8e0e04d78531d4bf5ca Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:11:51 2008 +1000 ide: ide_dev_has_iordy() -> ata_id_has_iordy() * Remove (id[ATA_ID_FIELD_VALID] & 2) check from ide_dev_has_iordy() (it is for validity of words 64-70, IORDY is in word 49). * ide_dev_has_iordy() -> ata_id_has_iordy() Cc: Sergei Shtylyov Signed-off-by: Bartlomiej Zolnierkiewicz commit 1b982167ea97b9aad27f1a3de10d2531d78fb351 Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:11:51 2008 +1000 ide: factor out HDIO_*_NICE ioctl handling to ide_*_nice_ioctl() Factor out HDIO_{GET,SET}_NICE ioctl handling from generic_ide_ioctl() to ide_{get,set}_nice_ioctl(). Signed-off-by: Bartlomiej Zolnierkiewicz commit 928082b27094f3fb2c223718a3b0f48aeedc0648 Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:11:51 2008 +1000 ide: remove ->supports_dsc_overlap field from ide_driver_t * Use drive->media and drive->scsi to check if ->dsc_overlap can be set by HDIO_SET_NICE ioctl in generic_ide_ioctl(). * Remove unused ->supports_dsc_overlap field from ide_driver_t. There should be no functional changes caused by this patch. Signed-off-by: Bartlomiej Zolnierkiewicz commit a1a02de667b658e308dd6af2c6e4ed5d454c469f Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:11:50 2008 +1000 ide: remove read-only ->atapi_overlap field from ide_drive_t Signed-off-by: Bartlomiej Zolnierkiewicz commit 3ac4311037556c1138c2aaafd2a2a250c7a1c763 Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:11:50 2008 +1000 cmd640: add __set_prefetch_mode() Factor out the common code from check_prefetch() and set_prefetch_mode() to __set_prefetch_mode(). Signed-off-by: Bartlomiej Zolnierkiewicz commit da006398b14e78758cd812e97e84aa387b2e289b Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:11:50 2008 +1000 ide: remove SECTOR_WORDS define Just use SECTOR_SIZE instead. Signed-off-by: Bartlomiej Zolnierkiewicz commit 3a309354e0ccf5d495be9f15cae7f40d272a6fe1 Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:11:49 2008 +1000 ide: /proc/ide/hd*/settings rework * Add struct ide_devset, S_* flags, *DEVSET() & ide*_devset_*() macros. * Add 'const struct ide_devset **settings' to ide_driver_t. * Use 'const struct ide_devset **settings' in ide_drive_t instead of 'struct ide_settings_s *settings'. Then convert core code and device drivers to use struct ide_devset and co.: - device settings are no longer allocated dynamically for each device but instead there is an unique struct ide_devset instance per setting - device driver keeps the pointer to the table of pointers to its settings in ide_driver_t.settings - generic settings are kept in ide_generic_setting[] - ide_proc_[un]register_driver(), ide_find_setting_by_name(), ide_{read,write}_setting() and proc_ide_{read,write}_settings() are updated accordingly - ide*_add_settings() are removed * Remove no longer used __ide_add_setting(), ide_add_setting(), __ide_remove_setting() and auto_remove_settings(). * Remove no longer used TYPE_*, SETTING_*, ide_procset_t and ide_settings_t. * ->keep_settings, ->using_dma, ->unmask, ->noflush, ->dsc_overlap, ->nice1, ->addressing, ->wcache and ->nowerr ide_drive_t fields can now be bitfield flags. While at it: * Rename ide_find_setting_by_name() to ide_find_setting(). * Rename write_wcache() to set_wcache(). There should be no functional changes caused by this patch. Signed-off-by: Bartlomiej Zolnierkiewicz commit a66361152ca4f73ddef0c5d5932ac0ff41b66727 Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:11:49 2008 +1000 ide: preparations for /proc/ide/hd*/settings rework After rework settings will be no longer created dynamically for each device so we need to make some fixups first. * Use set_[ksettings,unmaskirq]() as a set function for ["keepsettings","unmaskirq"] setting. * Allow writes to ["io_32bit","unmaskirq"] settings also when drive->no_[io_32bit,unmask] is set (this is checked later inside set_[io_32bit,unmaskirq]() anywyay and keeps consistency with the corresponding HDIO_SET_[32BIT,UNMASKINTR] ioctls). * Use max possible multi sectors value (16) as an allowed max for "multcount" setting. set_multcount() set function checks against device's max possbile value anyway and it makes the proc setting consistent with the corresponding HDIO_SET_MULTCOUNT ioctl. Signed-off-by: Bartlomiej Zolnierkiewicz commit db6bf7a09653607701d8d1d7766a8c35c9ef85c5 Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:11:49 2008 +1000 ide: call ide_proc_register_driver() later Call ide_proc_register_driver() in ide*_setup() (just before ide*_add_settings() call) instead of in ->probe method. Despite being basically a preparation for /proc/ide/hd*/settings rework this is a nice cleanup in itself. Signed-off-by: Bartlomiej Zolnierkiewicz commit 482eec6d8e28e21967b91ba3c89c85c87df25bd6 Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:11:49 2008 +1000 ide: include only when needed * Include directly in instead of through . * Include only when needed. Cc: Christoph Hellwig Signed-off-by: Bartlomiej Zolnierkiewicz commit fa759f9390f2c3336cbf2de39690dadf6a820a7b Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:11:48 2008 +1000 ide: remove CONFIG_IDEDISK_MULTI_MODE Use multi PIO by default when available and remove no longer needed CONFIG_IDEDISK_MULTI_MODE (it should be safe nowadays, despite to what help entry has been saying). Signed-off-by: Bartlomiej Zolnierkiewicz commit a6b54f23276078c19b555a20d01fba6329054824 Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:11:48 2008 +1000 ide: check drive->present in ide_get_paired_drive() * Change ide_get_paired_drive() to return NULL if peer device is not present and update all users accordingly. While at it: * ide_get_paired_drive() -> ide_get_pair_dev() * Use ide_get_pair_dev() in cs5530.c, sc1200.c and via82cxxx.c. There should be no functional changes caused by this patch. Signed-off-by: Bartlomiej Zolnierkiewicz commit 47f4ff88141b6d3639b17bba018dce6efc24dac7 Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:11:48 2008 +1000 ide: remove needless drive->present checks from device drivers Remove needless drive->present checks from ->probe methods (device model takes care of that). Signed-off-by: Bartlomiej Zolnierkiewicz commit 1746ee30027a7010af6e3861e6b9a72dabb8bb67 Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:11:47 2008 +1000 ide: remove unused _IDE_C and _IDE_DISK defines Signed-off-by: Bartlomiej Zolnierkiewicz commit 86e9b41e494c0251af243ceb631c0f948e36ea60 Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:11:47 2008 +1000 ide: remove IDE_CHIPSET_* macros They just obfuscate the code. Signed-off-by: Bartlomiej Zolnierkiewicz commit 95121f9b96841fdd1906021cccafddf19f93073d Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:11:47 2008 +1000 ide: remove no longer needed BUG_ON()-s from init_irq() init_irq() is now called only during initial host registration so these BUG_ON()-s are no loner needed (+ the last one was done too late anyway). Signed-off-by: Bartlomiej Zolnierkiewicz commit e304939e785f561bf9c381c9faddf1983211b0fb Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:11:47 2008 +1000 ide: enhance ide_busy_sleep() * Make ide_busy_sleep() take timeout value as a parameter and also allow use of AltStatus Register if requested with altstatus parameter. Update existing users accordingly. * Convert ide_driveid_update() and actual_try_to_identify() to use ide_busy_sleep(). There should be no functional changes caused by this patch. Signed-off-by: Bartlomiej Zolnierkiewicz commit 48f77eafd14015f5ec96da7515c00941047d2101 Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:11:46 2008 +1000 ide: fix EXABYTENEST handling in probe_for_drive() Fix EXABYTENEST handling in probe_for_drive() (so drive->present is checked for "nested" device) and cleanup enable_nest(). Signed-off-by: Bartlomiej Zolnierkiewicz commit 6e68a9f5382b7408cadcd852f00161c5f0ed613d Author: FUJITA Tomonori Date: Wed Sep 3 10:11:46 2008 +1000 ide-cd: use the new object_is_in_stack() helper Signed-off-by: FUJITA Tomonori Cc: Borislav Petkov Cc: Thomas Bogendoerfer Cc: Tejun Heo Cc: Jens Axboe Cc: James Bottomley Signed-off-by: Andrew Morton Signed-off-by: Bartlomiej Zolnierkiewicz commit bfa003e4ea86d8485bbdb942dd0ee07d6c68f368 Author: Linus Torvalds Date: Wed Sep 3 10:11:46 2008 +1000 ide: re-code ide_fixstring() loop to be less evil On Friday 25 July 2008, Linus Torvalds wrote: > > On Fri, 25 Jul 2008, Ben Dooks wrote: > > > > personally, i would much prefer to see the loop being less evil > > like: > > > > for (p = s; p < end; p += 2) > > be16_to_cpus((u16 *)p); > > Well, in this case, the code actually depends on 'p' being back at the > start of the buffer by the end of it all, so it would need some more > changes than that. > > But yes, I applied David's patch, but I _also_ suspect that we would be > better off without code that does horrid things like casts and assignments > inside the function arguments. > > So it would be nice to re-code that loop to be more readable. But due to > the reliance of 'p' being 's' after the loop, the minimal patch would be > something like the appended. > > Bartlomiej - take this or not, I'm not going to commit it - I haven't > tested it, nor do I even have any machines that would trigger it. So this > is more a "maybe something like this" than anything else. From: Linus Torvalds CC: Ben Dooks Cc: David Miller Cc: harvey.harrison@gmail.com Signed-off-by: Bartlomiej Zolnierkiewicz commit c8aed16bb5b855e569a827b5dfb9a5cb5236eed3 Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:11:46 2008 +1000 ide: remove no longer needed ide_drive_t fields Remove ->remap_0_to_1 and ->sect0 (they are always zero now). Signed-off-by: Bartlomiej Zolnierkiewicz commit 7d7bcd08d0fae22143c08b2d92a84d32a05fd6f9 Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:11:45 2008 +1000 ide: use ATA_* defines instead of *_STAT and *_ERR ones * ERR_STAT -> ATA_ERR * INDEX_STAT -> ATA_IDX * ECC_STAT -> ATA_CORR * DRQ_STAT -> ATA_DRQ * SEEK_STAT -> ATA_DSC * WRERR_STAT -> ATA_DF * READY_STAT -> ATA_DRDY * BUSY_STAT -> ATA_BUSY * MARK_ERR -> ATA_AMNF * TRK0_ERR -> ATA_TRK0NF * ABRT_ERR -> ATA_ABORTED * MCR_ERR -> ATA_MCR * ID_ERR -> ATA_IDNF * MC_ERR -> ATA_MC * ECC_ERR -> ATA_UNC * ICRC_ERR -> ATA_ICRC * BBD_ERR -> ATA_BBK Also: * ILI_ERR -> ATAPI_ILI * EOM_ERR -> ATAPI_EOM * LFS_ERR -> ATAPI_LFS * CD -> ATAPI_COD * IO -> ATAPI_IO Signed-off-by: Bartlomiej Zolnierkiewicz commit 503550a37d4c67fcd3feb986b30ceca5560e640e Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:11:45 2008 +1000 hd: WIN_* -> ATA_CMD_* * Use ATA_CMD_* defines instead of WIN_* ones. * Include directly instead of through . Signed-off-by: Bartlomiej Zolnierkiewicz commit b66b47a3957e357f9bc3690df730db53ca608980 Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:11:45 2008 +1000 ide: WIN_* -> ATA_CMD_* * Use ATA_CMD_* defines instead of WIN_* ones. While at it: * EXABYTE_ENABLE_NEXT -> ATA_EXABYTE_ENABLE_NEST * SETFEATURES_{EN,DIS}_WCACHE -> SETFEATURES_WC_{ON,OFF} * SETFEATURES_{EN,DIS}_AAM -> SETFEATURES_AAM_{ON,OFF} * SMART_* -> ATA_SMART_* * Remove stale comment from ide-proc.c. Partially based on earlier work by Chris Wedgwood. Acked-by: Chris Wedgwood Signed-off-by: Bartlomiej Zolnierkiewicz commit 5ffe8f6b9e11699cb1c19df088c56560c4d316bd Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:11:44 2008 +1000 libata: WIN_* -> ATA_CMD_* Acked-by: Jeff Garzik Signed-off-by: Bartlomiej Zolnierkiewicz commit 8ee35d024e5e2402f452e28c09e6ae32affc84dc Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:11:44 2008 +1000 ide-disk: use ata_id_hpa_enabled() idedisk_supports_hpa() -> ata_id_hpa_enabled(). The latter one also checks validity of words 82 & 85. Signed-off-by: Bartlomiej Zolnierkiewicz commit 88efe266935cc9d8a2bd7848f3a1f7389641a731 Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:11:44 2008 +1000 ide-disk: use ata_id_wcache_enabled() Replace open-coded check by ata_id_wcache_enabled() (which also checks validity of word 85). Signed-off-by: Bartlomiej Zolnierkiewicz commit 59ab99bbc800403a81a5673ff63b670915680428 Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:11:44 2008 +1000 ide: use ata_id_current_chs_valid() Replace open-coded checks by ata_id_current_chs_valid(). There should be no functional changes caused by this patch. Signed-off-by: Bartlomiej Zolnierkiewicz commit a357a0b7467e36a7e86aa5d8f52acfd414aeb1ac Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:11:44 2008 +1000 ide: remove drive->driveid * Factor out HDIO_[OBSOLETE,GET]_IDENTITY ioctls handling to ide_get_identity_ioctl(). * Use temporary buffer in ide_get_identity_ioctl() instead of accessing drive->id directly. * Add ide_id_to_hd_driveid() inline to convert raw id into struct hd_driveid format (needed on big-endian). * Use ide_id_to_hd_driveid() in ide_get_identity_ioctl(), cleanup ide_fix_driveid() and switch ide to use use raw id. * Remove no longer needed drive->driveid. This leaves us with 3 users of struct hd_driveid in tree: - arch/um/drivers/ubd_kern.c - drivers/block/xsysace.c - drivers/usb/storage/isd200.c While at it: * Use ata_id_u{32,64}() and ata_id_has_{dma,lba,iordy}() macros. There should be no functional changes caused by this patch. Signed-off-by: Bartlomiej Zolnierkiewicz commit 9968e385e37bc1f81e8a2db49bef14fd4f497932 Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:11:43 2008 +1000 ide: make drive->id an union (take 2) Make drive->id an unnamed union so id can be accessed either by using 'u16 *id' or 'struct hd_driveid *driveid'. Then convert all existing drive->id users accordingly (using 'u16 *id' when possible). This is an intermediate step to make ide 'struct hd_driveid'-free. While at it: - Add missing KERN_CONTs in it821x.c. - Use ATA_ID_WORDS and ATA_ID_*_LEN defines. - Remove unnecessary checks for drive->id. - s/drive_table/table/ in ide_in_drive_list(). - Cleanup ide_config_drive_speed() a bit. - s/drive1/dev1/ & s/drive0/dev0/ in ide_undecoded_slave(). v2: Fix typo in drivers/ide/ppc/pmac.c. (From Stephen Rothwell) There should be no functional changes caused by this patch. Signed-off-by: Bartlomiej Zolnierkiewicz commit f5b78ed8c328f37827fd46683474eceb40b16b17 Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:11:43 2008 +1000 ide: cleanup ide_fix_driveid() Do all __le16_to_cpu() swapping in one loop. Signed-off-by: Bartlomiej Zolnierkiewicz commit 2b6c312dcb4cf9bdbead7f3edb048c11f3cfa058 Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:11:43 2008 +1000 ide: cleanup ide_disk_init_mult_count() * Remove superfluous checks for drive->mult_req. * No need to zero drive's fields. * Move the common code out of #ifdef scope. There should be no functional changes caused by this patch. Signed-off-by: Bartlomiej Zolnierkiewicz commit 81a5dac75acc6a1a290824ad7aca649d4f77005f Author: Bartlomiej Zolnierkiewicz Date: Wed Sep 3 10:11:42 2008 +1000 ide: remove superfluous check from ide_disk_special() This condition is checked by both ide_disk_init_mult_count() and set_multcount() so no need to do it again in ide_disk_special(). Signed-off-by: Bartlomiej Zolnierkiewicz commit dc8e19094872cc4c9449268a44cbc2b99654840d Author: David Woodhouse Date: Tue Sep 2 23:15:22 2008 +0100 EFS: Don't set f_fsid in statfs(). We don't have any suitable value to put in f_fsid. Using EFS_MAGIC really isn't a good idea, because all EFS file systems will have the same f_fsid then. Signed-off-by: David Woodhouse commit 34f6e15786293e8d6ed05f9c19ed784ff15d2702 Author: Sascha Hauer Date: Tue Sep 2 17:16:59 2008 +0200 [MTD] [NAND] Freescale i.MX2 NAND driver This patch adds support for the integrated NAND flash controller of the i.MX2 and i.MX3 family. It is tested on MX27 but should work on MX3 aswell. Signed-off-by: Sascha Hauer Acked-by: Juergen Beisert Signed-off-by: David Woodhouse commit c9257433f2eaf8803a1f3d3be5d984232db41ffe Author: Vladimir Sokolovsky Date: Tue Sep 2 13:38:29 2008 -0700 mlx4_core: Set RAE and init mtt_sz field in FRMR MPT entries Set the RAE (remote access enable) bit and correctly initialize the MTT size in MPT entries being set up for fast register memory regions. Otherwise the callers can't enable remote access and in fact can't fast register at all (since the HCA will think no MTT entries are allocated). Signed-off-by: Vladimir Sokolovsky Signed-off-by: Roland Dreier commit 5702ee809dcca6dfd99c62a617197a1d91b3dc09 Author: Ralph Campbell Date: Tue Sep 2 13:28:07 2008 -0700 IB/ipath: Fix SLID generation for RC/UC QPs when LMC > 0 The code to set the source LID in the sent LRH was not setting the low bits if LMC != 0 for RC/UC QPs. Signed-off-by: Ralph Campbell Signed-off-by: Roland Dreier commit a39cbe51f45ceea2a5596850bfa15332298bf61c Author: Julien Brunel Date: Tue Sep 2 13:26:38 2008 -0700 RDMA/ucma: Test ucma_alloc_multicast() return against NULL, not with IS_ERR() In case of error, the function ucma_alloc_multicast() returns a NULL pointer, but never returns an ERR pointer. So after a call to this function, an IS_ERR test should be replaced by a NULL test. The semantic match that finds this problem is as follows: (http://www.emn.fr/x-info/coccinelle/) // @match bad_is_err_test@ expression x, E; @@ x = ucma_alloc_multicast(...) ... when != x = E IS_ERR(x) // Signed-off-by: Julien Brunel Signed-off-by: Julia Lawall Signed-off-by: Roland Dreier commit a90b1050f5f43e3f8100bc7565131b511bb60ec2 Author: Michael Brooks Date: Tue Sep 2 13:23:50 2008 -0700 IB/mad: Don't discard BMA responses in kernel This fixes the problem of incoming BMA responses being dropped due to a bad "is response" check. Fix the test to use the ib_response_mad() predicate, which correctly handles BMA MADs. This fixes . Signed-off-by: Michael Brooks Acked-by: Sean Hefty Signed-off-by: Roland Dreier commit 99d64b39eba6ab6747cc95ec9ab8ee716a999132 Author: \"Hefty, Sean\ Date: Tue Sep 2 13:20:01 2008 -0700 IB/cm: Correctly free cm_device structure commit 110cf374 ("infiniband: make cm_device use a struct device and not a kobject.") introduced a memory leak, since it deleted cm_release_dev_obj(), which was where cm_dev was freed. Fix this by freeing the leaked structure after calling device_unregister(). Signed-off-by: Sean Hefty Signed-off-by: Roland Dreier commit 44be6fdf1056b685eb79e53e42bd2d321b085cfc Author: David Teigland Date: Thu Aug 28 11:36:19 2008 -0500 dlm: fix address compare Compare only the addr and port fields of sockaddr structures. Fixes a problem with ipv6 where sin6_scope_id does not match. Signed-off-by: David Teigland commit a0ac6f4c2ac37c9056c9ab79c60e20d0e3be047c Author: Paul Moore Date: Tue Sep 2 10:57:23 2008 -0400 netlabel: Add configuration support for local labeling Add the necessary NetLabel support for the new CIPSO mapping, CIPSO_V4_MAP_LOCAL, which allows full LSM label/context support. Signed-off-by: Paul Moore commit 913a4d5ec12c8812017dd2ac4ce25267fb05b4df Author: Paul Moore Date: Tue Sep 2 10:56:58 2008 -0400 cipso: Add support for native local labeling and fixup mapping names This patch accomplishes two minor tasks: add a new tag type for local labeling and rename the CIPSO_V4_MAP_STD define to CIPSO_V4_MAP_TRANS. The first change allows CIPSO to support full LSM labels/contexts, not just MLS attributes. The second change brings the mapping names inline with what userspace is using, compatibility is preserved since we don't actually change the value. Signed-off-by: Paul Moore commit 58f6eeeb0469c151d355f0b35b86880a25aed6ea Author: Paul Moore Date: Tue Sep 2 10:27:04 2008 -0400 netlabel: Changes to the NetLabel security attributes to allow LSMs to pass full contexts This patch provides support for including the LSM's secid in addition to the LSM's MLS information in the NetLabel security attributes structure. Signed-off-by: Paul Moore commit cb2e67fceb063d99a8b28f573fac5b52d41998ae Author: Paul Moore Date: Tue Sep 2 10:26:47 2008 -0400 selinux: Cache NetLabel secattrs in the socket's security struct Previous work enabled the use of address based NetLabel selectors, which while highly useful, brought the potential for additional per-packet overhead when used. This patch attempts to mitigate some of that overhead by caching the NetLabel security attribute struct within the SELinux socket security structure. This should help eliminate the need to recreate the NetLabel secattr structure for each packet resulting in less overhead. Signed-off-by: Paul Moore commit ddc82e497e0798ac6091301f85e1cab45e1c4ff4 Author: Paul Moore Date: Tue Sep 2 10:26:29 2008 -0400 selinux: Set socket NetLabel based on connection endpoint Previous work enabled the use of address based NetLabel selectors, which while highly useful, brought the potential for additional per-packet overhead when used. This patch attempts to solve that by applying NetLabel socket labels when sockets are connect()'d. This should alleviate the per-packet NetLabel labeling for all connected sockets (yes, it even works for connected DGRAM sockets). Signed-off-by: Paul Moore commit e5f68c8304868647c711c003d4fd59c29116c25e Author: Paul Moore Date: Tue Sep 2 10:26:12 2008 -0400 netlabel: Add functionality to set the security attributes of a packet This patch builds upon the new NetLabel address selector functionality by providing the NetLabel KAPI and CIPSO engine support needed to enable the new packet-based labeling. The only new addition to the NetLabel KAPI at this point is shown below: * int netlbl_skbuff_setattr(skb, family, secattr) ... and is designed to be called from a Netfilter hook after the packet's IP header has been populated such as in the FORWARD or LOCAL_OUT hooks. This patch also provides the necessary SELinux hooks to support this new functionality. Smack support is not currently included due to uncertainty regarding the permissions needed to expand the Smack network access controls. Signed-off-by: Paul Moore commit a41a77bbbda10abee2fbe901a4a04b474d24a76f Author: Paul Moore Date: Tue Sep 2 10:25:51 2008 -0400 netlabel: Add network address selectors to the NetLabel/LSM domain mapping This patch extends the NetLabel traffic labeling capabilities to individual packets based not only on the LSM domain but the by the destination address as well. The changes here only affect the core NetLabel infrastructre, changes to the NetLabel KAPI and individial protocol engines are also required but are split out into a different patch to ease review. Signed-off-by: Paul Moore commit 854e855c1f94a17a4d522fe95152a6a59f6f0c5b Author: Paul Moore Date: Tue Sep 2 10:25:30 2008 -0400 netlabel: Add a generic way to create ordered linked lists of network addrs Create an ordered IP address linked list mechanism similar to the core kernel's linked list construct. The idea behind this list functionality is to create an extensibile linked list ordered by IP address mask to ease the matching of network addresses. The linked list is ordered with larger address masks at the front of the list and shorter address masks at the end to facilitate overriding network entries with individual host or subnet entries. Signed-off-by: Paul Moore commit 0d1197f423f400fa362b063964b22f3ad928782f Author: Paul Moore Date: Tue Sep 2 10:25:15 2008 -0400 netlabel: Replace protocol/NetLabel linking with refrerence counts NetLabel has always had a list of backpointers in the CIPSO DOI definition structure which pointed to the NetLabel LSM domain mapping structures which referenced the CIPSO DOI struct. The rationale for this was that when an administrator removed a CIPSO DOI from the system all of the associated NetLabel LSM domain mappings should be removed as well; a list of backpointers made this a simple operation. Unfortunately, while the backpointers did make the removal easier they were a bit of a mess from an implementation point of view which was making further development difficult. Since the removal of a CIPSO DOI is a realtively rare event it seems to make sense to remove this backpointer list as the optimization was hurting us more then it was helping. However, we still need to be able to track when a CIPSO DOI definition is being used so replace the backpointer list with a reference count. In order to preserve the current functionality of removing the associated LSM domain mappings when a CIPSO DOI is removed we walk the LSM domain mapping table, removing the relevant entries. Signed-off-by: Paul Moore commit 477f8a8b559007c240f1c79a0caa7db576eecd4b Author: Paul Moore Date: Tue Sep 2 10:24:57 2008 -0400 smack: Fix missing calls to netlbl_skbuff_err() Smack needs to call netlbl_skbuff_err() to let NetLabel do the necessary protocol specific error handling. Signed-off-by: Paul Moore commit b023202e2a41a61165f472cc889f37c4a260ba51 Author: Paul Moore Date: Tue Sep 2 10:24:41 2008 -0400 selinux: Fix missing calls to netlbl_skbuff_err() At some point I think I messed up and dropped the calls to netlbl_skbuff_err() which are necessary for CIPSO to send error notifications to remote systems. This patch re-introduces the error handling calls into the SELinux code. Signed-off-by: Paul Moore commit bbabdfc2c98f8bf48b16eeafab4089182e667970 Author: Paul Moore Date: Tue Sep 2 10:24:23 2008 -0400 selinux: Fix a problem in security_netlbl_sid_to_secattr() Currently when SELinux fails to allocate memory in security_netlbl_sid_to_secattr() the NetLabel LSM domain field is set to NULL which triggers the default NetLabel LSM domain mapping which may not always be the desired mapping. This patch fixes this by returning an error when the kernel is unable to allocate memory. This could result in more failures on a system with heavy memory pressure but it is the "correct" thing to do. Signed-off-by: Paul Moore commit ced67de8790d6864c824943872f5dabc47163222 Author: Paul Moore Date: Tue Sep 2 10:24:03 2008 -0400 selinux: Better local/forward check in selinux_ip_postroute() It turns out that checking to see if skb->sk is NULL is not a very good indicator of a forwarded packet as some locally generated packets also have skb->sk set to NULL. Fix this by not only checking the skb->sk field but also the IP[6]CB(skb)->flags field for the IP[6]SKB_FORWARDED flag. Signed-off-by: Paul Moore commit 758f1e4d3fa760d08b4fe3bf09b811a0e8cb43eb Author: Paul Moore Date: Tue Sep 2 10:22:46 2008 -0400 netlabel: Remove unneeded in-kernel API functions After some discussions with the Smack folks, well just Casey, I now have a better idea of what Smack wants out of NetLabel in the future so I think it is now safe to do some API "pruning". If another LSM comes along that needs this functionality we can always add it back in, but I don't see any LSMs on the horizon which might make use of these functions. Thanks to Rami Rosen who suggested removing netlbl_cfg_cipsov4_del() back in February 2008. Signed-off-by: Paul Moore commit 283b4696542dbb740436def222d27259f765ee2a Author: Steven Whitehouse Date: Tue Sep 2 13:33:17 2008 +0100 GFS2: Fix race relating to glock min-hold time In the case that a request for a glock arrives right after the grant reply has arrived, it sometimes means that the gl_tstamp field hasn't been updated recently enough. The net result is that the min-hold time for the glock is ignored. If this happens often enough, it leads to poor performance. This patch adds an additional test, so that if the reply pending bit is set on a glock, then it will select the maximum length of time for the min-hold time, rather than looking at gl_tstamp. Signed-off-by: Steven Whitehouse commit 9723f38eb53eac9a851210b629555a37afa3f15c Author: David S. Miller Date: Tue Sep 2 03:15:44 2008 -0700 sparc32: Fix sun4c build warnings. Reported by Stephen Rothwell. Signed-off-by: David S. Miller commit 5f9947f593127850d406f687c6023908b8a79264 Author: Mark Brown Date: Mon Sep 1 18:47:04 2008 +0100 ALSA: ASoC: Don't suggest compile time selection of codec access Currently the boiler plate code used by most ASoC codecs to provide a placeholder for SPI access suggests making the selection of SPI a compile time option which is suboptimal when trying to build kernels supporting multiple systems. Change this template to suggest allowing runtime selection instead. Leave the drivers not yet converted to new style I2C access for now to avoid collisions. Signed-off-by: Mark Brown Signed-off-by: Takashi Iwai commit 4d2139f6c19edb5974b8c26f430b412ebaa497bb Author: Cliff Cai Date: Mon Sep 1 18:47:03 2008 +0100 ALSA: ASoC: Add SPI support for WM8731 [Modified to allow runtime selection between I2C and SPI and to select SPI_MASTER for all codecs build so this is included. -- broonie] Signed-off-by: Cliff Cai Signed-off-by: Bryan Wu Signed-off-by: Mark Brown Signed-off-by: Takashi Iwai commit da5b028a1382038dc3f8fbe1cf9b587309eba43f Author: Jean Delvare Date: Mon Sep 1 18:47:02 2008 +0100 ALSA: ASoC: Convert wm8990 to a new-style i2c driver Convert the wm8990 codec driver to the new (standard) device driver binding model. After this change, WM8990 devices are no longer discovered automatically and must instead be instantiated explicitly. Signed-off-by: Jean Delvare Signed-off-by: Mark Brown Signed-off-by: Takashi Iwai commit be99827ea333eb15560a8b52ba57a2dce1bdfbb8 Author: Jean Delvare Date: Mon Sep 1 18:47:01 2008 +0100 ALSA: ASoC: Convert wm8731 to a new-style i2c driver Convert the wm8731 codec driver to the new (standard) device driver binding model. Signed-off-by: Jean Delvare Tested-by: Manuel Lauss Signed-off-by: Mark Brown Signed-off-by: Takashi Iwai commit f4b439b785d809179fe0ed08803c371c5a266449 Author: Jean Delvare Date: Mon Sep 1 18:47:00 2008 +0100 ALSA: ASoC: Convert wm8750 to a new-style i2c driver Convert the wm8750 codec driver to the new (standard) device driver binding model. Signed-off-by: Jean Delvare Signed-off-by: Mark Brown Signed-off-by: Takashi Iwai commit 8e0d8c4d1e9a0f9736e771c0697a905fd3232ff8 Author: Jean Delvare Date: Mon Sep 1 18:46:59 2008 +0100 ALSA: ASoC: Convert ak4535 to a new-style i2c driver Convert the ak4535 codec driver to the new (standard) device driver binding model. After this change, AK4535 devices are no longer discovered automatically and must instead be instantiated explicitly. Signed-off-by: Jean Delvare Signed-off-by: Mark Brown Signed-off-by: Takashi Iwai commit 912c0157a71fe8fa1a7e32b61033a655900e9fc9 Author: Jean Delvare Date: Mon Sep 1 18:46:58 2008 +0100 ALSA: ASoC: Convert uda1380 to a new-style i2c driver Convert the uda1380 codec driver to the new (standard) device driver binding model. Signed-off-by: Jean Delvare Signed-off-by: Mark Brown Signed-off-by: Takashi Iwai commit 7b508b1857c82f55b754ac8581be3132a0549faf Author: Mark Brown Date: Mon Sep 1 18:46:57 2008 +0100 ALSA: ASoC: Make all codecs depend on rather than selecting I2C The I2C layer uses I/O operations that aren't available on all architectures and since select bypasses Kconfig dependency checking selecting I2C breaks builds like allmodconfig on some architectures. Signed-off-by: Mark Brown Signed-off-by: Takashi Iwai commit 8aef72786192a46e20791b2e854ea3ed047bc15c Author: David S. Miller Date: Mon Sep 1 20:23:18 2008 -0700 pci_sun4v: Use of_get_property(). Signed-off-by: David S. Miller commit 463801b3ae97fe1c652ce8da5a61367405d6ec3e Author: David S. Miller Date: Mon Sep 1 20:21:15 2008 -0700 pci_schizo: Use of_get_property() and delete spurious local vars. Signed-off-by: David S. Miller commit 0f73d1bbe6240bcdf14c221bbe2ece63540c5c44 Author: David S. Miller Date: Mon Sep 1 20:18:04 2008 -0700 pci_psycho: Use of_getintprop_default(). Signed-off-by: David S. Miller commit 446139a8f7078d96159a936fd6059660db425405 Author: David S. Miller Date: Tue Sep 2 00:49:38 2008 -0700 sparc64: Implement SSTATE purely using notifiers and initcalls. Don't clutter up the tree with sstate_blah() scattered all over the place. Signed-off-by: David S. Miller commit cdb3592a20b41377a28a0737dc9af95e53024470 Author: David S. Miller Date: Mon Sep 1 19:31:16 2008 -0700 sparc64: Move reboot handling into seperate file and kill power reg programming. We should always use prom_power_off(). Signed-off-by: David S. Miller commit e822358ac24550d889895d5866797ae8c9b188c2 Author: David S. Miller Date: Mon Sep 1 18:32:22 2008 -0700 sparc64: Pass proper parent device down into root pci_create_bus() call. Signed-off-by: David S. Miller commit 7cc288add44c392dfc8c1dbf0e3a26a69a14fa70 Author: David S. Miller Date: Mon Sep 1 18:32:13 2008 -0700 sparc64: Kill the scan_bus function pointer in struct pci_pbm_info. No longer used. Signed-off-by: David S. Miller commit 721f1651546231c4e53a1afe31e15e8234b076e0 Author: David Howells Date: Tue Sep 2 11:03:14 2008 +1000 drm/cred: wrap task credential accesses in the drm driver. Wrap access to task credentials so that they can be separated more easily from the task_struct during the introduction of COW creds. Change most current->(|e|s|fs)[ug]id to current_(|e|s|fs)[ug]id(). Change some task->e?[ug]id to task_e?[ug]id(). In some places it makes more sense to use RCU directly rather than a convenient wrapper; these will be addressed by later patches. Signed-off-by: David Howells Reviewed-by: James Morris Acked-by: Serge Hallyn Signed-off-by: David Airlie commit 77261d3938405532212d7b1a6ad968981af0f851 Author: Jesse Barnes Date: Mon Aug 25 15:16:19 2008 -0700 new chip name is GM45 Author: Zhenyu Wang i915: official name for GM45 chipset Signed-off-by: Zhenyu Wang Acked-by: Jesse Barnes Signed-off-by: Dave Airlie commit a850828c640735fb410c782717c9eb7f8474e356 Author: Jesse Barnes Date: Mon Aug 25 15:11:06 2008 -0700 separate i915 suspend/resume functions into their own file [Patch against drm-next. Consider this a trial balloon for our new Linux development model.] This is a big chunk of code. Separating it out makes it easier to change without churn on the main i915_drv.c file (and there will be churn as we fix bugs and add things like kernel mode setting). Also makes it easier to share this file with BSD. Signed-off-by: Jesse Barnes Signed-off-by: Dave Airlie commit febf2c862f15be6ba95640ab04393fcb53764759 Author: Dave Airlie Date: Tue Sep 2 10:10:16 2008 +1000 radeon: fix writeback across suspend/resume. Make writeback not get disabled on resume. Signed-off-by: Dave Airlie commit 2e9c9eedfe0be777c051a2198dddf459adcc407b Author: Dave Airlie Date: Tue Sep 2 10:06:06 2008 +1000 drm: fix sysfs error path. Pointed out by Roel Kluin on dri-devel. Signed-off-by: Dave Airlie commit 92d4616ee3e6e5be320598feac331374e4549cad Author: Adrian Bunk Date: Sun Aug 24 17:11:22 2008 +1000 FB_SIS=m, DRM_SIS=y is not a legal configuration. Reported-by: Randy Dunlap Signed-off-by: Adrian Bunk Signed-off-by: Dave Airlie commit 91c2ebb8e78aa64f4807399b506ec0090ae5f3d6 Author: Matthew Garrett Date: Tue Aug 5 19:37:25 2008 +0100 Add Intel ACPI IGD OpRegion support This adds the support necessary for allowing ACPI backlight control to work on some newer Intel-based graphics systems. Tested on Thinkpad T61 and HP 2510p hardware. Signed-off-by: Matthew Garrett Signed-off-by: Dave Airlie commit 75fed4ae8454aa975c274b2585ec2287dd15773d Author: Keith Packard Date: Wed Jul 30 13:03:43 2008 -0700 i915: Initialize hardware status page at device load when possible. Some chips were unstable with repeated setup/teardown of the hardware status page. Signed-off-by: Eric Anholt Signed-off-by: Dave Airlie commit 1236e8610ab9c6f9f8297e60530bedb2640c7224 Author: Keith Packard Date: Wed Jul 30 12:21:20 2008 -0700 i915: Track progress inside of batchbuffers for determining wedgedness. This avoids early termination for long-running commands. Signed-off-by: Eric Anholt Signed-off-by: Dave Airlie commit 4f99970852559935b27bc634318f34c18c5fd143 Author: Eric Anholt Date: Tue Jul 29 12:10:39 2008 -0700 i915: Add support for MSI and interrupt mitigation. Previous attempts at interrupt mitigation had been foiled by i915_wait_irq's failure to update the sarea seqno value when the status page indicated that the seqno had already been passed. MSI support has been seen to cut CPU costs by up to 40% in some workloads by avoiding other expensive interrupt handlers for frequent graphics interrupts. Signed-off-by: Eric Anholt Signed-off-by: Dave Airlie commit 573e91575687018b4307f53a50f4da0084dbdf3d Author: Jesse Barnes Date: Tue Jul 29 11:54:06 2008 -0700 i915: Use more consistent names for regs, and store them in a separate file. Signed-off-by: Eric Anholt Signed-off-by: Dave Airlie commit 20ae3cf7d4a9ae8d23bcffa67c9a34fc2640d217 Author: Keith Packard Date: Wed Jul 30 12:36:08 2008 -0700 i915: Ignore X server provided mmio address It is already correctly detected by the kernel for use in suspend/resume. Signed-off-by: Eric Anholt Signed-off-by: Dave Airlie commit 91019197abbfde388d0b71b0fc8979a936c23fe3 Author: Keith Packard Date: Wed Jul 30 12:28:47 2008 -0700 i915: remove settable use_mi_batchbuffer_start The driver can know what hardware requires MI_BATCH_BUFFER vs MI_BATCH_BUFFER_START; there's no reason to let user mode configure this. Signed-off-by: Eric Anholt Signed-off-by: Dave Airlie commit 90c6cf69c2b517dc047b70fb1f892ddfbc1d3007 Author: David Howells Date: Wed Jul 30 12:29:38 2008 -0700 SiS DRM: fix a pointer cast warning Fix a pointer cast warning in the SIS DRM code. This was introduced in patch ce65a44de07f73ceda1749812b75086b7add408d. Signed-off-by: David Howells Cc: Dave Airlie Signed-off-by: Andrew Morton Signed-off-by: Dave Airlie commit 1ad8a0d1359172c188a3837939e3a08812981c1b Author: David Howells Date: Wed Jul 30 12:29:37 2008 -0700 SiS DRM: fix the memory allocator if the SIS FB is built as a module Fix the SIS DRM memory allocator if the SIS FB built as a module. The SIS DRM code initialises the mm allocation hooks, but _only_ if the SIS FB is not built as a module because it depends on CONFIG_FB_SIS, and that's unset if the SIS FB is not built in. It must check CONFIG_FB_SIS_MODULE as well. Signed-off-by: David Howells Cc: Dave Airlie Signed-off-by: Andrew Morton Signed-off-by: Dave Airlie commit 2e6ec7cdc09f36be1cbe9aeaccfc45f307fc0060 Author: Carlos R. Mafra Date: Wed Jul 30 12:29:37 2008 -0700 drm: remove #define's for non-linux systems There is no point in considering FreeBSD et al. in the linux kernel source code. Signed-off-by: Carlos R. Mafra Signed-off-by: Andrew Morton Signed-off-by: Dave Airlie commit 33e3239775fdd1ab95a5dc40dda9c8332a8acf01 Author: Alexey Dobriyan Date: Thu Aug 28 06:26:23 2008 +0400 [PATCH 2/2] anondev: switch to IDA Signed-off-by: Alexey Dobriyan commit dedb6c3a41ef59688b6a2523e6cf36ef073461dd Author: Alexey Dobriyan Date: Thu Aug 28 06:25:49 2008 +0400 [PATCH 1/2] anondev: init IDR statically Signed-off-by: Alexey Dobriyan commit b73c80739bc03db2ca5f582f5bfdc450af8e58ed Author: David Woodhouse Date: Mon Aug 18 15:36:47 2008 +0100 [JFFS2] Use d_splice_alias() not d_add() in jffs2_lookup() Now that JFFS2 can be exported by NFS, we need to get this right. Signed-off-by: David Woodhouse Signed-off-by: Al Viro commit b22f9863ca0ed6890798ddd2b63781177960ad52 Author: David Woodhouse Date: Sun Aug 17 17:21:18 2008 +0100 [PATCH] Optimise NFS readdir hack slightly. Avoid calling the underlying ->readdir() again when we reached the end already; keep going round the loop only if we stopped due to our own buffer being full. [AV: tidy the things up a bit, while we are there] Signed-off-by: David Woodhouse Signed-off-by: Al Viro commit 4e7152c275edbcbb99cf4479e1cb7a6e5f3a2b7d Author: Al Viro Date: Sun Aug 24 07:29:52 2008 -0400 [PATCH] prepare vfs_readdir() callers to returning filldir result It's not the final state, but it allows moving ->readdir() instances to passing filldir return value to caller of vfs_readdir(). Signed-off-by: Al Viro commit 4a31e52c75af4c6b0e36eef3cbf96c871209927f Author: Al Viro Date: Sun Aug 24 07:28:39 2008 -0400 [PATCH] get rid of on-stack dentry in ext2_get_parent() Signed-off-by: Al Viro commit 44e7c16ea7ede913afb31e0e62b97f62534133e6 Author: Al Viro Date: Sun Aug 24 07:26:48 2008 -0400 [PATCH] get rid of on-stack fake dentry in ext3_get_parent() Better pass parent and qstr to ext3_find_entry() explicitly than use such kludges, especially since the stack footprint is nasty enough and we have every chance to be deep in call chain. Signed-off-by: Al Viro commit a705f7405bf43cf26436648ae27b5b2a52731d85 Author: David Woodhouse Date: Thu Jul 31 20:39:25 2008 +0100 [JFFS2] Reinstate NFS exportability Now that the readdir/lookup deadlock issues have been dealt with, we can export JFFS2 file systems again. (For now, you have to specify fsid manually; we should add a method to the export_ops to handle that too.) Signed-off-by: David Woodhouse Signed-off-by: Al Viro commit e416cba11e7c87752b1306b02fb6519dd654ad2e Author: David Woodhouse Date: Thu Jul 31 20:38:04 2008 +0100 [PATCH] Remove XFS buffered readdir hack Now that we've moved the readdir hack to the nfsd code, we can remove the local version from the XFS code. Signed-off-by: David Woodhouse Signed-off-by: Al Viro commit d536458919d54a12824131fdcee04bb017550283 Author: David Woodhouse Date: Thu Jul 31 20:29:12 2008 +0100 [PATCH] Copy XFS readdir hack into nfsd code. Some file systems with their own internal locking have problems with the way that nfsd calls the ->lookup() method from within a filldir function called from their ->readdir() method. The recursion back into the file system code can cause deadlock. XFS has a fairly hackish solution to this which involves doing the readdir() into a locally-allocated buffer, then going back through it calling the filldir function afterwards. It's not ideal, but it works. It's particularly suboptimal because XFS does this for local file systems too, where it's completely unnecessary. Copy this hack into the NFS code where it can be used only for NFS export. In response to feedback, use it unconditionally rather than only for the affected file systems. Signed-off-by: David Woodhouse Signed-off-by: Al Viro commit 7f8042914bf1886014182c461e5249e69282879a Author: David Woodhouse Date: Thu Jul 31 17:16:51 2008 +0100 [PATCH] Factor out nfsd_do_readdir() into its own function Signed-off-by: David Woodhouse Signed-off-by: Al Viro commit 4c093b6a57d8872a0d016028abe23e2e6433884e Author: Al Viro Date: Mon Aug 11 12:39:47 2008 -0400 [PATCH] reduce the stack footprint of exportfs_decode_fh() no need to have _two_ 256-byte arrays on stack... Signed-off-by: Al Viro commit 4bef5941a507dc1b41f18f33189d8afe04f77ad5 Author: Christoph Hellwig Date: Mon Aug 11 15:49:12 2008 +0200 [PATCH] kill d_alloc_anon Remove d_alloc_anon now that no users are left. Signed-off-by: Christoph Hellwig Signed-off-by: Al Viro commit 8ee6b8fff20962d17a008e230006e48c7f79ade4 Author: Christoph Hellwig Date: Mon Aug 11 15:49:04 2008 +0200 [PATCH] switch all filesystems over to d_obtain_alias Switch all users of d_alloc_anon to d_obtain_alias. Signed-off-by: Christoph Hellwig Signed-off-by: Al Viro commit cee75f3dac0b0fcdd3a91148abbf11ea0c1749aa Author: Christoph Hellwig Date: Mon Aug 11 15:48:57 2008 +0200 [PATCH] new helper: d_obtain_alias The calling conventions of d_alloc_anon are rather unfortunate for all users, and it's name is not very descriptive either. Add d_obtain_alias as a new exported helper that drops the inode reference in the failure case, too and allows to pass-through NULL pointers and inodes to allow for tail-calls in the export operations. Incidentally this helper already existed as a private function in libfs.c as exportfs_d_alloc so kill that one and switch the callers to d_obtain_alias. Signed-off-by: Christoph Hellwig Signed-off-by: Al Viro commit f5c16afb9a38d0d13798345ed530f5402ea27db8 Author: Christoph Hellwig Date: Mon Aug 11 15:37:17 2008 +0200 [PATCH] generic_file_llseek tidyups Add kerneldoc for generic_file_llseek and generic_file_llseek_unlocked, use sane variable names and unclutter the code. Signed-off-by: Christoph Hellwig Signed-off-by: Al Viro commit abfced63ed59cfbbcfd9bc4585dcadfe7574a172 Author: Christoph Hellwig Date: Mon Aug 11 15:34:22 2008 +0200 [PATCH] tidy up chrdev_open Use a single goto label for chrdev_put + return error cases. Signed-off-by: Christoph Hellwig Signed-off-by: Al Viro commit 50d831f11209d96630ad852641b0de88006a5072 Author: Christoph Hellwig Date: Mon Aug 11 00:27:59 2008 +0200 [PATCH] hpfs: cleanup ->setattr Reformat hpfs_notify_change to standard kernel style to make it readable and rename it to hpfs_setattr as that's what the method is called. Signed-off-by: Christoph Hellwig Signed-off-by: Al Viro commit a69831a1a78245a7880241b4d0f5a75aeedc2a13 Author: Christoph Hellwig Date: Mon Aug 11 00:24:08 2008 +0200 [PATCH] dm: kill lookup_device wrapper Now that lookup_bdev is exported and used by dm just use it directly instead of through a trivial wrapper. Signed-off-by: Christoph Hellwig Signed-off-by: Al Viro commit e0dbe3c395d628d426fef05e258221ed47c27fa8 Author: Al Viro Date: Tue Aug 5 03:00:49 2008 -0400 [PATCH] make O_EXCL in nd->intent.flags visible in nd->flags New flag: LOOKUP_EXCL. Set before doing the final step of pathname resolution on the paths that have LOOKUP_CREATE and O_EXCL. Signed-off-by: Al Viro commit 6b1408a82fae1a8ccc83fab8540b379e10fe7e92 Author: Al Viro Date: Sat Aug 2 22:40:42 2008 -0400 [PATCH] don't pass bogus flags to LOOKUP_PARENT lookup in spufs Signed-off-by: Al Viro commit 5ed5fdef02bd2f779bc2f6d22a2afeef83411152 Author: Al Viro Date: Sat Aug 2 22:36:57 2008 -0400 [PATCH] get rid of path_lookup_create() ... and don't pass bogus flags when we are just looking for parent. Fold __path_lookup_intent_open() into path_lookup_open() while we are at it; that's the only remaining caller. Signed-off-by: Al Viro commit 29d97e1698443b2af6b8873b6c20190e96c964cb Author: Al Viro Date: Sat Aug 2 01:06:21 2008 -0400 [PATCH] get rid of nameidata in audit_tree Signed-off-by: Al Viro commit 0b85fea6165c7d7096487b18d5c988a2cdf94715 Author: Al Viro Date: Sat Aug 2 01:04:36 2008 -0400 [PATCH] assorted path_lookup() -> kern_path() conversions more nameidata eviction Signed-off-by: Al Viro commit fef312c1811ebe1ee454bf440e80e7a0b6a12a70 Author: Al Viro Date: Sat Aug 2 01:03:36 2008 -0400 [PATCH] switch nfsd to kern_path() Signed-off-by: Al Viro commit c4c8caa899c0acecc4a90c456ca87ceb1cf7222c Author: Al Viro Date: Sat Aug 2 01:01:02 2008 -0400 [PATCH] sanitize svc_export_parse() clean up the exit paths, get rid of nameidata Signed-off-by: Al Viro commit 6ac465f99b29f74ca5a62bc32a8772985d9a071b Author: Al Viro Date: Sat Aug 2 00:57:06 2008 -0400 [PATCH] switch quota_on-related stuff to kern_path() Signed-off-by: Al Viro commit 21922d1b5590f1630baf6ded029bd67506c1990a Author: Al Viro Date: Sat Aug 2 00:55:27 2008 -0400 [PATCH] no need for noinline stuff in fs/namespace.c anymore Stack footprint from hell had been due to many struct nameidata in there. No more. Signed-off-by: Al Viro commit 95e70549a2be32726de73967c454248a572b0c63 Author: Al Viro Date: Sat Aug 2 00:51:11 2008 -0400 [PATCH] finally get rid of nameidata in namespace.c Signed-off-by: Al Viro commit e017ae1268dbe8a61965eb68e0c94ac82b91a9ee Author: Al Viro Date: Sat Aug 2 00:49:18 2008 -0400 [PATCH] new helper - kern_path() Analog of lookup_path(), takes struct path *. Signed-off-by: Al Viro commit d626c4d7df271b144ed808e4b7422407c7263c2c Author: Helge Deller Date: Sat Aug 30 12:34:51 2008 +0200 [PATCH] Fix typo in hpux_getdents filldir Signed-off-by: Helge Deller Signed-off-by: Al Viro commit 9097e1c92abd9ca3585e9cf6d3eb560fe5d74860 Author: Russell King Date: Mon Sep 1 22:07:37 2008 +0100 [ARM] omap: Fix IO_ADDRESS() macros OMAP1_IO_ADDRESS(), OMAP2_IO_ADDRESS() and IO_ADDRESS() returns cookies for use with __raw_{read|write}* for accessing registers. Therefore, these macros should return (void __iomem *) cookies, not integer values. Doing this improves typechecking, and means we can find those places where, eg, DMA controllers are incorrectly given virtual addresses to DMA to, or physical addresses are thrown through a virtual to physical address translation. Signed-off-by: Russell King commit dde42e65e642f8af520921eeaf1c90bfaaf08dbe Author: Russell King Date: Mon Sep 1 21:51:50 2008 +0100 [ARM] omap: remove an io_v2p() usage When omap_udc is also incorporated, this macro will no longer be used. Signed-off-by: Russell King commit 654cfd00e8cfad24571aed8090485a3c18df23e2 Author: Russell King Date: Mon Sep 1 21:47:59 2008 +0100 [SERIAL] 8250: serial8250_port_size() - omap ports are larger A function to contain common code for the size of the resource we need to allocate or free. OMAP ports need 22 bytes rather than the standard 8 bytes. Signed-off-by: Russell King commit 2675e9447bb5c861dbd29c5fe55b7ce2ad3ff0f5 Author: Enrico Scholz Date: Fri Aug 29 12:59:52 2008 +0200 [MTD] [NAND] pxa3xx_nand: added warning which tells id of detected NAND Minor patch to help debugging of NAND detection. Signed-off-by: Enrico Scholz Signed-off-by: David Woodhouse commit c8c17c888d936c58ceb28b084a6272d67e10ea28 Author: Enrico Scholz Date: Fri Aug 29 12:59:51 2008 +0200 [MTD] [NAND] pxa3xx_nand: moved some helper variables out from platform data This patch moves some attributes out from the platform data into the dynamically created nand device. This results into a cleaner interface and allows to use constant pxa3xx_nand_flash definitions. Signed-off-by: Enrico Scholz Signed-off-by: David Woodhouse commit 7dad482ed0648a40e403d1ed44e0ea92248632f1 Author: Enrico Scholz Date: Fri Aug 29 12:59:50 2008 +0200 [MTD] [NAND] pxa3xx_nand: added some 'const' annotations to the exported API This patch marks some attributes as 'const' which are set only once and never be modified by the driver. There are some changes in parameter list and variable declarations too which mark them as 'const'. Signed-off-by: Enrico Scholz Signed-off-by: David Woodhouse commit 80ebf20f34c30760cfba7b5e0a418241181d2cd9 Author: Enrico Scholz Date: Fri Aug 29 12:59:49 2008 +0200 [MTD] [NAND] pxa3xx_nand: allow to disable builtin flash-type table This patch adds a MTD_NAND_PXA3xx_BUILTIN configuration variables which allows to disable usage of builtin flash-type table. Not enabling this option saves some space in the generated driver. Signed-off-by: Enrico Scholz Signed-off-by: David Woodhouse commit c8ac3f818e1183eab8d08a41b01b6078c5df4b43 Author: Enrico Scholz Date: Fri Aug 29 12:59:48 2008 +0200 [MTD] [NAND] pxa3xx_nand: allow to define flash types in the platform data This patch adds 'flash' and 'num_flash' attributes to the platform data. There was added code in the driver to iterate across these attributes in the detect-flash routine. This is done similarly to the existing method which uses a 'builtin_flash_types' field. Signed-off-by: Enrico Scholz Signed-off-by: David Woodhouse commit 43035338ad772b6a4097b2ac530b75390bee87c1 Author: Enrico Scholz Date: Fri Aug 29 12:57:28 2008 +0200 [MTD] [NAND] pxa3xx_nand: moved nand definitions into shared platform header This patch moves the exported datastructures from the pxa3xx_nand.c driver into the header. This is a plain movement without any modification of the attributes. This is the first one of a set of patches which: * allows to specify used NAND flash in the platform code and allows to turn off the old way to specify NAND characteristics in the driver. This way did not worked well as these characteristics depend on the platform and can not be derived from NAND id alone. E.g. some NAND chips share the same ID (e.g. K9K8G08U0A and K9NBG08U5A) but have different timings (which are written in the common driver currently and must be modified there). * adds 'const' annotations at various places Further patches will be sent to the mtd-list. Signed-off-by: Enrico Scholz Signed-off-by: David Woodhouse commit 549c71c924b11678342d1d1bdfc2a7c8a54fba5e Author: Russell King Date: Mon Sep 1 21:25:33 2008 +0100 [ARM] omap: improve is_omap_port() Make is_omap_port() take the uart_8250_port structure so it can do whatever test it desires. Convert the test to compare the physical addresses rather than virtual addresses. Signed-off-by: Russell King commit 3eb505f9adc0bdfc4e343ebbf84f518055794d93 Author: Takashi Iwai Date: Mon Sep 1 19:45:58 2008 +0200 ALSA: harmony - fix a typo Fix a typo in the patch to remove snd_assert(). Signed-off-by: Takashi Iwai commit ddb644a6fda2f4be7763e0adecf3dcdb637317c1 Author: Sergey Lapin Date: Fri Aug 29 15:47:52 2008 +0100 [ARM] 5238/1: Very basic Palm Zire 72 support This patch contains very basic support of Palm Zire 72. Signed-off-by: Sergey Lapin Acked-by: Eric Miao Signed-off-by: Russell King commit db5555ca41dd4209ca39b145940e31480e75bdc5 Author: Russell King Date: Wed Aug 27 12:55:04 2008 +0100 [ARM] pxa: Allow platforms to override PSPR setting Currently, we set PSPR just before entering sleep mode. However, some platforms have different requirements for setting PSPR in order to properly wake up. Set PSPR earlier in the suspend cycle so that platforms can change the setting by using a sysdev driver instead. Acked-by: Eric Miao Signed-off-by: Russell King commit c8a7aba8e2d5fb8b8fcc0b226ef3da85e5cd7ef0 Author: Mark Brown Date: Tue Aug 26 18:40:57 2008 +0100 [ARM] 5224/2: PXA SSP: Introduce register accessors Introduce accessors for the SSP registers so that drivers don't need to open code offsets from the MMIO base. Signed-off-by: Mark Brown Acked-by: Eric Miao Signed-off-by: Russell King commit a3b6bc7bf1c2b4179781598a36c153e2d1122129 Author: Russell King Date: Tue Aug 26 10:40:50 2008 +0100 [I2C] pxa: provide late suspend and early resume hooks Properly hook the I2C driver into the PM code; the previous fix for this (ece5f7b3c4fde70a1ae4add7372ebca5c90bc34d) worked around the platform where I2C is required to be available early during resume. It has been found to be sufficient to use the early resume hook for this function, so the original hack can die. Leave the hack in place for the PIO transfer handler though. Signed-off-by: Russell King commit 7354d1dd9db5e16734f74fe1694f8cc823613f86 Author: Dmitry Baryshkov Date: Mon Aug 18 14:38:48 2008 +0100 [ARM] 5203/1: i2c-pxa: fix scheduling while atomic in i2c_pxa_abort() i2c_pxa_abort can be called from the atomic context. Change it to use mdelay and counted loop. Signed-off-by: Dmitry Baryshkov Acked-by: Eric Miao Signed-off-by: Russell King commit 4b48966dc3561433ab011aa9371080982623fdc2 Author: Mike Rapoport Date: Sun Aug 17 06:23:05 2008 +0100 [ARM] 5201/1: PXA3xx: Add support for power i2c bus Add power I2C support for PXA3xx processors Signed-off-by: Mike Rapoport Signed-off-by: Russell King commit 7a5063d86e95774ada66baac58fdfb7a80c75180 Author: Russell King Date: Fri Aug 22 11:09:38 2008 +0100 [ARM] pxa: introduce PXA_HAVE_BOARD_IRQS Signed-off-by: Russell King commit ff19555238150e3cf7e09583d01d4ae0673072a1 Author: Atsushi Nemoto Date: Mon Sep 1 22:22:41 2008 +0900 MIPS: TXx9: Implement prom_free_prom_memory Signed-off-by: Atsushi Nemoto Signed-off-by: Ralf Baechle commit 512b72e722dcf69ce22fd63f93b40bdad49207d8 Author: Atsushi Nemoto Date: Mon Sep 1 22:22:40 2008 +0900 MIPS: TXx9: Add RBTX4939 board support Signed-off-by: Atsushi Nemoto Signed-off-by: Ralf Baechle create mode 100644 arch/mips/txx9/rbtx4939/Makefile create mode 100644 arch/mips/txx9/rbtx4939/irq.c create mode 100644 arch/mips/txx9/rbtx4939/prom.c create mode 100644 arch/mips/txx9/rbtx4939/setup.c create mode 100644 include/asm-mips/txx9/rbtx4939.h commit 801b4553a77bb52218655657564a8ae98a7bc528 Author: Atsushi Nemoto Date: Mon Sep 1 22:22:39 2008 +0900 MIPS: TXx9: Add TX4939 SoC support Signed-off-by: Atsushi Nemoto Signed-off-by: Ralf Baechle create mode 100644 arch/mips/pci/pci-tx4939.c create mode 100644 arch/mips/txx9/generic/irq_tx4939.c create mode 100644 arch/mips/txx9/generic/setup_tx4939.c create mode 100644 include/asm-mips/txx9/tx4939.h commit c97ce5b9dbae03072e7d7e0b630830dd798307a4 Author: Atsushi Nemoto Date: Mon Sep 1 22:22:38 2008 +0900 MIPS: TXx9: IOC LED support Add leds-gpio platform device for controlling LEDs connected to IOC on RBTX49XX and JMR3927 board. Signed-off-by: Atsushi Nemoto Signed-off-by: Ralf Baechle commit b451bc8cc64dea3884f0601f8a88e3e21d365c48 Author: Atsushi Nemoto Date: Mon Sep 1 22:22:37 2008 +0900 MIPS: TXx9: Microoptimize interrupt handlers The IOC interrupt status register on RBTX49XX only have 8 bits. Use 8-bit version of __fls() to optimize interrupt handlers. Signed-off-by: Atsushi Nemoto Signed-off-by: Ralf Baechle commit 7d20ba09a39ae1c1fb0845a90af690c85c0f5e4a Author: Atsushi Nemoto Date: Mon Sep 1 22:22:36 2008 +0900 MIPS: TXx9: stop_unused_modules TXx9 SoCs have pin multiplex. Stop some controller modules which can not be used due to pin configurations. Signed-off-by: Atsushi Nemoto Signed-off-by: Ralf Baechle commit 111d0e06faa8bc498bf58649d7abfd106f336d5a Author: Florian Fainelli Date: Sat Aug 23 18:54:37 2008 +0200 Documentation: Document the RB532 specific kmac tag The Routerboard 532 bootloader passes the korina ethernet MAC adapter address to the kernel on the command line. Document this in the kernel-parameters file. Signed-off-by: Florian Fainelli Signed-off-by: Ralf Baechle commit 24eaae6f99a3b4d447df6d488805ec577bfb4a79 Author: Florian Fainelli Date: Sat Aug 23 18:54:34 2008 +0200 MIPS: RB532: Convert to GPIO lib This patch converts the rb532 code to use gpio library and register its gpio chip. Signed-off-by: Florian Fainelli Signed-off-by: Ralf Baechle commit ad5a7ddfb3ea115bce8f27c29708654213b4aab8 Author: Florian Fainelli Date: Sat Aug 23 18:54:04 2008 +0200 MIPS: RB532: Remove unused rc32434_sync_delay and rc32434_sync_udelay This patch removes these two unused functions : rc32434_sync_delay and rc32434_sync_udelay Signed-off-by: Florian Fainelli Signed-off-by: Ralf Baechle commit c0f26b237ea1d7e92a8fd62c286a686110cac0a2 Author: Florian Fainelli Date: Sat Aug 23 18:53:50 2008 +0200 MIPS: RB532: Cleanup the headers again This patch cleans up headers and regroups informations to where they should reside. While moving, try to have a consistant naming for defines. Signed-off-by: Florian Fainelli Signed-off-by: Ralf Baechle commit 01cf3e88497e8767cb4ce071af5b32b0791024d6 Author: Florian Fainelli Date: Sat Aug 23 18:53:24 2008 +0200 MIPS: RB532: Remove obsolute reference to setup_serial_port We are no longer using setup_serial_port. So just remove it from the prom code. Signed-off-by: Florian Fainelli Signed-off-by: Ralf Baechle commit 25984283b8d7f32dab4c7713014b6175edbc1142 Author: Florian Fainelli Date: Fri Aug 22 17:03:03 2008 +0200 MIPS: RB532: Fix id usage in platform devices When there is only platform device of the same type, id = -1 should be used, fix this. Signed-off-by: Florian Fainelli Signed-off-by: Ralf Baechle commit 37efb31baccb53ebb80107da610f2a774f7fedf0 Author: Florian Fainelli Date: Fri Aug 22 17:02:03 2008 +0200 MIPS: RB532: replace raw volatile read with a readl This patch replaces a raw read using volatiles with a readl. Signed-off-by: Florian Fainelli Signed-off-by: Ralf Baechle commit 06ee718306989207b340e5f152754072459bfe7b Author: Florian Fainelli Date: Fri Aug 22 17:01:31 2008 +0200 MIPS: RB532: Remove gpio bootup state We are no longer using gpio bootup state, so do not export it and do not parse the kernel command line tag for it. Instead we provide gpio-keys for the button the gpio bootup state was checking. Signed-off-by: Florian Fainelli Signed-off-by: Ralf Baechle commit 557273e0e0ee68c4d54450be0b048d1b5dc5ae2b Author: Florian Fainelli Date: Fri Aug 22 17:01:03 2008 +0200 MIPS: RB532: Use physical addresses for gpio and device controller registers This patch fixes the misuse of virtual addresses for the GPIO and third device controller which would lead to problems while accessing ioremap'd registers. Signed-off-by: Florian Fainelli Signed-off-by: Ralf Baechle commit a29e88437e023f20df95a79f7f932d523288cd37 Author: Florian Fainelli Date: Fri Aug 22 17:00:22 2008 +0200 MIPS: RB532: Cleanup and group definitions to their right places This patch moves GPIO related definitions to gpio.h and IRQ related to irq.h Signed-off-by: Florian Fainelli Signed-off-by: Ralf Baechle commit 38f183de0a0bacd426bd5f6fdf0a86507479d65f Author: Atsushi Nemoto Date: Tue Aug 19 22:55:18 2008 +0900 [MIPS] TXx9: Declare smsc_fdc37m81x_config_get() in smsc_fdc37m81x.h Signed-off-by: Atsushi Nemoto Signed-off-by: Ralf Baechle commit c14ee8f102b83aee04bc22e7fa48d01e17113af7 Author: Atsushi Nemoto Date: Tue Aug 19 22:55:17 2008 +0900 [MIPS] TXx9: Add __init tag for tx4938_pcic1_map_irq. Signed-off-by: Atsushi Nemoto Signed-off-by: Ralf Baechle commit e673ce44ae214ad1cdaa0a014aef4a5162eb99a2 Author: Atsushi Nemoto Date: Tue Aug 19 22:55:16 2008 +0900 [MIPS] TXx9: Add board_be_init for TX4927/TX4938 Setup default board_be_handler for TX4927/TX4938. Signed-off-by: Atsushi Nemoto Signed-off-by: Ralf Baechle commit 2483d16e93e6d73b791d05e2692d980c9b0e4fc8 Author: Atsushi Nemoto Date: Tue Aug 19 22:55:15 2008 +0900 [MIPS] TXx9: Default machine_restart using watchdog reset Add default machine_restart routine using watchdog reset of TX4927 and TX4938. Signed-off-by: Atsushi Nemoto Signed-off-by: Ralf Baechle commit b487cc7066d2d8430e30f88d144e21558eff623d Author: Atsushi Nemoto Date: Tue Aug 19 22:55:14 2008 +0900 [MIPS] TXx9: Make spi_eeprom.c more generic Helper routines in txx9/rbtx4938/spi_eeprom.c is not TX4938 specific. Move it to txx9/generic/ directory and make it works with SPI bus number other than 0. Signed-off-by: Atsushi Nemoto Signed-off-by: Ralf Baechle create mode 100644 arch/mips/txx9/generic/spi_eeprom.c delete mode 100644 arch/mips/txx9/rbtx4938/spi_eeprom.c commit cdc4e60c191fda093f1ef3d89b0f0a31da4347d3 Author: Atsushi Nemoto Date: Tue Aug 19 22:55:13 2008 +0900 [MIPS] RBTX4938: Add TOSHIBA_RBTX4938_MPLEX_KEEP Add TOSHIBA_RBTX4938_MPLEX_KEEP to keep MPLEX settings by firmware. Also replace some printk with pr_info. Signed-off-by: Atsushi Nemoto Signed-off-by: Ralf Baechle commit d92b869524dcddd3c2242e5bcdbe2e73b4f86482 Author: Atsushi Nemoto Date: Tue Aug 19 22:55:12 2008 +0900 [MIPS] TXx9: Raise priority of interrupts for errors, timers, SIO Signed-off-by: Atsushi Nemoto Signed-off-by: Ralf Baechle commit 0fe76420a620433f5ddfb0c950f73c0c0a245ecd Author: Atsushi Nemoto Date: Tue Aug 19 22:55:11 2008 +0900 [MIPS] TXx9: Add mtd support Add helper routines to register physmap-flash platform devices for NOR flashes. Signed-off-by: Atsushi Nemoto Signed-off-by: Ralf Baechle commit e96e82f74d5eb3f4e678814d6548c898c4f2aee9 Author: Atsushi Nemoto Date: Tue Aug 19 22:55:10 2008 +0900 [MIPS] TXx9: Runtime configuration of timeout-error Add kernel options to control bus timeout error. Signed-off-by: Atsushi Nemoto Signed-off-by: Ralf Baechle commit 247ec1df2abe43156e4f9d0eef1963c64e50f926 Author: Atsushi Nemoto Date: Tue Aug 19 22:55:09 2008 +0900 [MIPS] TXx9: Cache fixup TX39/TX49 can enable/disable I/D cache at runtime. Add kernel options to control them. This is useful to debug some cache-related issues, such as aliasing or I/D coherency. Also enable CWF bit for TX49 SoCs. Signed-off-by: Atsushi Nemoto Signed-off-by: Ralf Baechle commit 5c71e0952e9726e15f7f77135c14979f6046b363 Author: Atsushi Nemoto Date: Tue Aug 19 22:55:08 2008 +0900 [MIPS] TXx9: Early command-line preprocessing * Select board by command-line option or firmware environment variable. * Handle "masterclk=" option. * Add boards.h to centerize board_vec declaration. Signed-off-by: Atsushi Nemoto Signed-off-by: Ralf Baechle create mode 100644 include/asm-mips/txx9/boards.h commit a57b178356aa3204379e8e186a25a7c2c2f61c31 Author: Atsushi Nemoto Date: Tue Aug 19 22:55:07 2008 +0900 [MIPS] TXx9: Add prom_getenv Add prom_getenv() which can be used for YAMON. This assumes other firmware should pass NULL for fw_arg2. Signed-off-by: Atsushi Nemoto Signed-off-by: Ralf Baechle commit 1839800fd946cf9750dfba0b01568d80a656d9ae Author: Atsushi Nemoto Date: Tue Aug 19 22:55:06 2008 +0900 [MIPS] TXx9: Improve handling of built-in and command-line args * Make prom_init_cmdline() static and be called from prom_init. * Append built-in args if the first character was '+'. * Drop command-line args if the first character of built-in was '-'. * Enclose args include spaces by quotes. * TX4938_NAND_BOOT is no longer needed. Signed-off-by: Atsushi Nemoto Signed-off-by: Ralf Baechle commit 6be91c863878147ece45ed992a811f6f33c0f133 Author: Atsushi Nemoto Date: Tue Aug 19 22:55:05 2008 +0900 [MIPS] RBTX4927: More explicit initialization * Make sure all interrupts cleared on startup * Initialize some GPIOs Signed-off-by: Atsushi Nemoto Signed-off-by: Ralf Baechle commit 4fee467fd37651a5e2b3b33f5fe43a771f2af634 Author: Patrick Glass Date: Mon Aug 18 14:41:30 2008 -0700 [MIPS] PMC MSP71XX gpio drivers This new gpio driver for PMC-Sierra's MSP71xx SoC allows standard api calls for access to the general and extended gpio's. Signed-off-by: Patrick Glass Signed-off-by: Ralf Baechle create mode 100755 arch/mips/pmc-sierra/msp71xx/gpio.c create mode 100755 arch/mips/pmc-sierra/msp71xx/gpio_extended.c create mode 100755 include/asm-mips/pmc-sierra/msp71xx/gpio.h commit 605b298479ba9be3e23d08cd8ef344f2f3e161ac Author: Thomas Bogendoerfer Date: Sun Aug 17 16:49:25 2008 +0200 [MIPS] Use compat_sys_ptrace This replaces mips's sys_ptrace32 with a compat_arch_ptrace and enables the new generic definition of compat_sys_ptrace instead. Signed-off-by: Thomas Bogendoerfer Signed-off-by: Ralf Baechle commit 660dfa3291e0756e24a8f341520c04ac1c0911ff Author: Takashi Iwai Date: Mon Sep 1 15:31:50 2008 +0200 ALSA: aaci - Fix NULL test at error path The original fix by Julien Brunel . aaci_init_card() returns a pointer with ERR_PTR(), but in aaci_init() NULL is supposed at this error path. Signed-off-by: Takashi Iwai commit c9acaab9a50dc13f9b7f2e274ac2b1dd6d915fa6 Author: Takashi Iwai Date: Mon Sep 1 14:25:08 2008 +0200 ALSA: intel8x0 - use snd_pci_quirk for clock list Signed-off-by: Takashi Iwai commit 81b15ac3ff5edafafc5c54010156a7865d1c41b0 Author: Jaroslav Kysela Date: Fri Aug 29 11:29:39 2008 +0200 ALSA: intel8x0: implement ac97_clock whitelist The AC97 clock detection is not accurate in some cases. This patch adds an initial whitelist for audio devices gathered from RedHat's bugzilla: https://bugzilla.redhat.com/show_bug.cgi?id=441087 As a side effect, white-listing might speedup kernel booting (AC97 clock measuring code is not activated). Signed-off-by: Jaroslav Kysela Signed-off-by: Takashi Iwai commit 3b0486d4d23ed516e9bc9bf0fb6c6fb35f192985 Author: Michael Kerrisk Date: Mon Sep 1 14:03:50 2008 +0200 ALSA: Documentation/sound/alsa/ALSA-Configuration.txt: fix typo As noted by Gu Rui in http://bugzilla.kernel.org/show_bug.cgi?id=11444, there is a typo in Documentation/sound/alsa/ALSA-Configuration.txt. After checking the source (sound/pci/hda/hda_intel.c), the report looks correct to me. Signed-off-by: Michael Kerrisk Signed-off-by: Takashi Iwai commit 5e706469a0518ec640a122aa5da22035e2af003a Author: David Woodhouse Date: Mon Sep 1 12:21:05 2008 +0100 [MTD] [NOR] Select MTD_CFI_UTIL when MTD_CFI probe routine is enabled It requires cfi_qry_mode_on(), which is in cfi_util.c Reported by Russell King Signed-off-by: David Woodhouse commit 22acc4e65043d436bc286e6059960fa533e37356 Author: Catalin Marinas Date: Fri Aug 29 18:31:27 2008 +0100 [ARM] 5231/1: Do not save the frame pointer in the csum_partial_copy_* functions Since the other assembly functions do not seem to save the frame pointer onto the stack, this patch changes the csum_partial_copy_* functions to behave in the same way. Signed-off-by: Catalin Marinas Signed-off-by: Russell King commit 4e6a0c397f40c9d98062aaaac66cab684f0b9186 Author: Catalin Marinas Date: Fri Aug 29 18:31:15 2008 +0100 [ARM] 5230/1: Replace post-indexed LDRT/STRT in uaccess.h The post-index immediate value is optional if it is 0 and this patch removes it. The reason is to allow such instructions to compile to Thumb-2 where only pre-indexed LDRT/STRT instructions are allowed. Signed-off-by: Catalin Marinas Signed-off-by: Russell King commit 9c23e5fefaaecd494925258084a31c8ff301ad03 Author: Catalin Marinas Date: Fri Aug 29 18:31:21 2008 +0100 [ARM] 5232/1: Do not post-index STRT instruction in clear_user.S The last strnebt instruction has a post-index of 1 but the address register is set to 0 in the next instruction, so no need for post-indexing. Signed-off-by: Catalin Marinas Signed-off-by: Russell King commit 93ed3970114983543bbebd195bef65db84444ea2 Author: Catalin Marinas Date: Thu Aug 28 11:22:32 2008 +0100 [ARM] 5227/1: Add the ENDPROC declarations to the .S files This declaration specifies the "function" type and size for various assembly functions, mainly needed for generating the correct branch instructions in Thumb-2. Signed-off-by: Catalin Marinas Signed-off-by: Russell King commit 8d5796d2ec6b5a4e7a52861144e63af438d6f8f7 Author: Lennert Buytenhek Date: Mon Aug 25 21:03:32 2008 +0100 [ARM] 5222/1: Allow configuring user:kernel split via Kconfig This patch adds a config option (CONFIG_VMSPLIT_*) to allow choosing between 3:1, 2:2 and 1:3 user:kernel memory splits. Tested-by: Riku Voipio Signed-off-by: Lennert Buytenhek Signed-off-by: Russell King commit 2d4b6c9aeb94cb9cb5c250f23e81e6d00b461372 Author: Nicolas Pitre Date: Thu Aug 21 23:22:49 2008 +0100 [ARM] 5221/1: fix ldm/stm emulation for kprobes Logic for the p bit was reversed. Signed-off-by: Nicolas Pitre Signed-off-by: Russell King commit d81030a1badb4e4d08358ff2c2bda9b11d5a6559 Author: Nicolas Pitre Date: Thu Aug 21 23:09:48 2008 +0100 [ARM] 5211/2: fix a couple warnings from BUG() usage When CONFIG_DEBUG_BUGVERBOSE is not set, we get warnings such as: arch/arm/mm/ioremap.c: In function ‘remap_area_pte’: arch/arm/mm/ioremap.c:67: warning: control reaches end of non-void function mm/bootmem.c: In function ‘mark_bootmem’: mm/bootmem.c:321: warning: control reaches end of non-void function fs/dcache.c: In function ‘d_materialise_unique’: fs/dcache.c:1875: warning: control reaches end of non-void function fs/nfs/client.c: In function ‘nfs_sockaddr_match_ipaddr’: fs/nfs/client.c:251: warning: control reaches end of non-void function block/cfq-iosched.c: In function ‘cfq_async_queue_prio’: block/cfq-iosched.c:1501: warning: control reaches end of non-void function Signed-off-by: Nicolas Pitre Signed-off-by: Russell King commit e589ed23dd27b890900eb7514f0a9e297d1e02b5 Author: Mikael Pettersson Date: Wed Aug 20 09:36:07 2008 +0100 [ARM] 5218/1: arm: improved futex support Linux/ARM currently doesn't support robust or PI futexes. The problem is that the kernel wants to perform certain ops (cmpxchg, set, add, or, andn, xor) atomically on user-space addresses, and ARM's futex.h doesn't support that. This patch adds that support, but only for uniprocessor machines. For UP it's enough to disable preemption to ensure mutual exclusion with other software agents (futexes don't need to care about other hardware agents, fortunately). This patch is based on one posted by Khem Raj on 2007-08-01 . (That patch is included in the -RT kernel patches.) My changes since that version include: * corrected implementation of FUTEX_OP_ANDN (must complement oparg) * added missing memory clobber to futex_atomic_cmpxchg_inatomic() * removed spinlock because it's unnecessary for UP and insufficient for SMP, instead the code is restricted to UP and relies on the fact that pagefault_disable() also disables preemption * coding style cleanups Tested on ARMv5 XScales with the glibc-2.6 nptl test suite. Tested-by: Bruce Ashfield Signed-off-by: Mikael Pettersson Signed-off-by: Russell King commit 3305a60795442a22fe8e9f5fb93a6f1f8dea6bb2 Author: Nicolas Pitre Date: Tue Aug 19 04:15:23 2008 +0100 [ARM] 5206/1: remove kprobe_trap_handler() hack As mentioned in commit 796969104cab0d454dbc792ad0d12a4f365a8564, and because of commit b03a5b7559563dafdbe52f8b5d8e453a914db941, the direct calling of kprobe_trap_handler() can be removed. Signed-off-by: Nicolas Pitre Signed-off-by: Russell King commit ac9d7efc7da0d88f9e7a1e0f532da35b7673098e Author: Russell King Date: Mon Aug 18 17:26:00 2008 +0100 [ARM] Update arch/arm/Kconfig for drivers/Kconfig changes, add cpuidle Signed-off-by: Russell King commit d7ac4e28ccc63ed6b4d67bd9c4a67cb9533eeb45 Author: Jean PIHET Date: Tue Aug 12 19:07:39 2008 +0100 [ARM] 5195/1: ARMv7 Oprofile support Add Oprofile kernel support for ARMv7. Tested on OMAP3430 and OMAP3530 chipsets (Cortex-A8). Signed-off-by: Jean Pihet Signed-off-by: Russell King commit 46097c7dd8bfaf9fb86565b6de45ab5a63afdd53 Author: Russell King Date: Sun Aug 10 18:10:19 2008 +0100 [ARM] cachetype: move definitions to separate header Rather than pollute asm/cacheflush.h with the cache type definitions, move them to asm/cachetype.h, and include this new header where necessary. Signed-off-by: Russell King commit 0ba8b9b273c45dd23f60ff700e265a0069b33758 Author: Russell King Date: Sun Aug 10 18:08:10 2008 +0100 [ARM] cputype: separate definitions, use them Add asm/cputype.h, moving functions and definitions from asm/system.h there. Convert all users of 'processor_id' to the more efficient read_cpuid_id() function. Signed-off-by: Russell King commit 9b7edc52f5fc7bdb3d5d0cd79212928932044941 Author: Xiantao Zhang Date: Thu Aug 28 09:34:08 2008 +0800 KVM: ia64: Implement kvm_arch_vcpu_ioctl_{set,get}_mpstate Two ioctl arch functions are added to set vcpu's smp state. Signed-off-by: Xiantao Zhang Signed-off-by: Avi Kivity commit 4262bd2981307258b31e15f1a526d2b3884e77b5 Author: Semun Lee Date: Mon Sep 1 11:49:27 2008 +0100 [MTD] [NAND] pxa3xx_nand_flash: Add definition of STM2GbX16 NAND flashes Signed-off-by: Semun Lee Acked-by: Eric Miao Signed-off-by: David Woodhouse commit 0a17504e51977346edadd16ecc82405b8cdd234c Author: Guillaume GARDET Date: Fri Aug 29 10:11:24 2008 +0100 [ARM] 5228/1: Add the RGB555 wiring for the atmel LCD Add the RGB555 wiring for the atmel LCD. Acked-by: Nicolas Ferre Acked-by: Haavard Skinnemoen Signed-off-by: Guillaume GARDET Signed-off-by: Russell King commit 3fc678a0e63138f56109ea31850f19b2e29c45b8 Author: David Howells Date: Wed Aug 27 14:48:32 2008 +0100 CRED: Wrap task credential accesses in the JFFS2 filesystem Wrap access to task credentials so that they can be separated more easily from the task_struct during the introduction of COW creds. Change most current->(|e|s|fs)[ug]id to current_(|e|s|fs)[ug]id(). Change some task->e?[ug]id to task_e?[ug]id(). In some places it makes more sense to use RCU directly rather than a convenient wrapper; these will be addressed by later patches. Signed-off-by: David Howells Reviewed-by: James Morris Acked-by: Serge Hallyn Signed-off-by: David Woodhouse commit 31db6e9ea1dbdcf66b8227b4f7035dee1b1dd8c0 Author: Alexey Dobriyan Date: Fri Aug 29 07:19:50 2008 +0400 [JFFS2] Move JFFS2 config options out of fs/Kconfig Signed-off-by: Alexey Dobriyan Signed-off-by: David Woodhouse commit fefbbc73cac6f7360460cee45e3d4cc209d8d607 Author: David S. Miller Date: Mon Sep 1 03:18:49 2008 -0700 sparc64: Use ENTRY/ENDPROC in PCI SUN4V asm. Signed-off-by: David S. Miller commit 687124dda0beeb8503ae27a1588e4705b3a588c2 Author: David S. Miller Date: Mon Sep 1 03:13:17 2008 -0700 sparc64: Use ENTRY/ENDPROC in hypervisor asm. Signed-off-by: David S. Miller commit 2fa9ef7d2062ec3295fdb6fdeea842dd6688e45c Author: Mohammed Gamal Date: Mon Sep 1 04:52:24 2008 +0300 KVM: x86 emulator: Add std and cld instructions (opcodes 0xfc-0xfd) This adds the std and cld instructions to the emulator. Encountered while running the BIOS with invalid guest state emulation enabled. Signed-off-by: Mohammed Gamal Signed-off-by: Avi Kivity commit 64e7c216c5bec90ad50787c2763b47492fd50cb8 Author: Takashi Iwai Date: Wed Jul 30 15:23:06 2008 +0200 ALSA: via82xx - check continuous pages in buffer setup Check continuous pages in the buffer set up so that the number of BDL is reduced. Also increased the max buffer size. Signed-off-by: Takashi Iwai commit cd40219f90a2064e3dcce1ba83f4b0c22ae3756b Author: Takashi Iwai Date: Thu Aug 21 14:17:38 2008 +0200 ALSA: via82xx - ignore buffer preallocation errors The errors at buffer preallocations aren't fatal and safe to ignore. The buffer will be allocated dynamically when opened. Signed-off-by: Takashi Iwai commit 8a9d87e841bed8304db43e67236e49884cf94d3e Author: Takashi Iwai Date: Wed Jul 30 15:13:34 2008 +0200 ALSA: hda - check page continuity Check the continuity of allocated pages to reduce the BDL size as much as possible so that it can use more than 1MB buffers. Signed-off-by: Takashi Iwai commit 842e2d6fb3e5617e0f50282bc69f72dd0a49a34e Author: Takashi Iwai Date: Wed Jul 30 15:13:33 2008 +0200 ALSA: Allocate larger pages in sgbuf Most hardwares have limited buffer-descriptor table length. This also restricts the max buffer size of the sound driver. For example, snd-hda-intel has 1MB buffer size limit, and this is because it can have at most 256 BDL entries. For supporting larger buffers, we need to allocate larger pages even for sg-buffers. This patch changes the sgbuf allocation code to try to allocate larger pages first. At each head of the allocated pages, the number of allocated pages is stored in the lowest bits of the corresponding entry of the table addr field. This change isn't visible as long as the driver uses snd_sgbuf_get_addr() helper. Also, the patch adds a new function, snd_pcm_sgbuf_get_chunk_size(). This returns the size of the chunk on continuous pages starting at the given position offset. If the chunk reaches to a non-continuous page, it returns the size to the boundary. Signed-off-by: Takashi Iwai commit c2ec6846556ebef49dedfbb9a31647aae0694ce1 Author: Takashi Iwai Date: Wed Jul 30 15:13:33 2008 +0200 ALSA: Fix allocation size calculation in snd_dma_alloc_pages_fallback() snd_dma_alloc_pages_fallback() always tries to reduce the size in a half, but it's not good when the given size isn't a power-of-two. Check it first then try to align. Signed-off-by: Takashi Iwai commit f6039e83d133991c389b445b7ab5464ebdad4eaf Author: Takashi Iwai Date: Thu Aug 21 13:00:13 2008 +0200 ALSA: Clean up SG-buffer helper functions and macros Clean up SG-buffer helper functions and macros. Helpers take substream as arguments now. Signed-off-by: Takashi Iwai commit 3d452e55ef905fc6fbf813a66c16de1293e243a1 Author: David S. Miller Date: Mon Sep 1 01:48:52 2008 -0700 sparc64: Apply const or __initdata to vio_device_id[] This mirrors the of_device_id[] changes done in fd098316ef533e8441576f020ead4beab93154ce ("sparc: Annotate of_device_id arrays with const or __initdata.") Signed-off-by: David S. Miller commit 553132dfc96cecc25d1e72175d5bc80ed8f83c20 Author: Takashi Iwai Date: Thu Aug 14 07:51:57 2008 +0200 ALSA: fix a typo during snd_assert() removal Signed-off-by: Takashi Iwai commit 9f5ca7dfdfe521b0ad7f58f411c2a409e2e100f3 Author: Takashi Iwai Date: Fri Aug 8 17:18:08 2008 +0200 ALSA: Clean up snd_BUG() Use the standard WARN() macro for snd_BUG(). Signed-off-by: Takashi Iwai commit a1bde1af19b8b2c03de7c17572e931dfc870bc61 Author: Takashi Iwai Date: Fri Aug 8 17:14:55 2008 +0200 ALSA: Kill snd_assert() definition Remove snd_assert() completely now. Signed-off-by: Takashi Iwai commit 90e0ba98da4d101cdd4d8cae9c76e00b7ddd2e94 Author: Takashi Iwai Date: Fri Aug 8 17:12:47 2008 +0200 ALSA: Kill snd_assert() in other places Kill snd_assert() in other places, either removed or replaced with if () with snd_BUG_ON(). Signed-off-by: Takashi Iwai commit 9f61222a1882f983af5607153e38f2f232876f29 Author: Takashi Iwai Date: Fri Aug 8 17:12:14 2008 +0200 ALSA: Kill snd_assert() in sound/pci/* Kill snd_assert() in sound/pci/*, either removed or replaced with if () with snd_BUG_ON(). Signed-off-by: Takashi Iwai commit a85fd1113207479b00b305c6ee451f2d06025a92 Author: Takashi Iwai Date: Fri Aug 8 17:11:45 2008 +0200 ALSA: Kill snd_assert() in sound/isa/* Kill snd_assert() in sound/isa/*, either removed or replaced with if () with snd_BUG_ON(). Signed-off-by: Takashi Iwai commit 1c330fe63f8405f0ff4477ff3fbbaf0b27674310 Author: Takashi Iwai Date: Fri Aug 8 17:09:09 2008 +0200 ALSA: Kill snd_assert() in sound/core/* Kill snd_assert() in sound/core/*, either removed or replaced with if () with snd_BUG_ON(). Signed-off-by: Takashi Iwai commit 0105f18683fde1df6ef69e7812582a52701e8a54 Author: Takashi Iwai Date: Thu Aug 28 15:38:50 2008 +0200 ALSA: wavefront - Always use request_firmware() Always use request_firmware() for loading yss225_registers image. Signed-off-by: Takashi Iwai Signed-off-by: David Woodhouse commit 5ce7710c56151cc27ec4059aa6f4e5664adf821c Author: Humphrey Bucknell Date: Fri Aug 29 16:27:00 2008 +0100 avr32: pm_standby low-power ram bug fix The value stored into the SDRAMC LPR register should be the current value of the register with the Self-refresh value set in the lower bit field. The bug involved only the Self-refresh value being written to the register, thus over writing any low-power ram settings. Signed-off-by: Humphrey Bucknell Signed-off-by: Haavard Skinnemoen commit 0fae99540ebb53e0507f2bd6e119bede94e84f77 Author: Pekka Enberg Date: Mon Sep 1 10:11:54 2008 +0300 kmemtrace: remove unnecessary casts Now that we use _RET_IP_ there's no need to cast 'caller' to unsigned long. Signed-off-by: Pekka Enberg commit e12599654710dec6c606a73544020a3067d13957 Author: Travis Place Date: Mon Sep 1 08:24:00 2008 +0200 ALSA: hda - Add model for Toshiba L305 laptop Added Subsystem IDs (0x1179, 0xff64) for the Toshiba Satellite L305 laptop, so it automatically uses the ALC268_TOSHIBA quirk. Signed-off-by: Travis Place Signed-off-by: Takashi Iwai commit 8323d3056e92f93c5a807260fd520e2d2ff43986 Author: Harvey Harrison Date: Fri Aug 29 13:32:00 2008 -0700 ALSA: ac97_patch make functions static Only used in ac97_codec by including ac97_patch.c directly, effectively static Found by sparse: sound/pci/ac97/ac97_patch.c:3551:5: warning: symbol 'patch_vt1617a' was not declared. Should it be static? sound/pci/ac97/ac97_patch.c:3767:5: warning: symbol 'patch_vt1618' was not declared. Should it be static? Signed-off-by: Harvey Harrison Signed-off-by: Takashi Iwai commit 18cf68b08137798c5cd1065af0d583f52a658d3d Author: Takashi Iwai Date: Mon Sep 1 08:21:49 2008 +0200 ALSA: atiixp - Add PCI ID for SB600 (1002:4382) Signed-off-by: Takashi Iwai commit ba4962d7a6a10c82e55c14589d4ec635bef8446f Author: David S. Miller Date: Sun Aug 31 21:48:12 2008 -0700 sparc64: Clean up CPU chip type probing code. Three main things: 1) Make prober an arch initcall instead of using hard-coded invocation from paging_init() 2) Shrink table size, the fpu ident stuff was never used. 3) Use named struct initialized in table. Signed-off-by: David S. Miller commit 5110bd21b8af4199b8332c0ab0b23367556653d3 Author: Adrian Bunk Date: Sun Aug 31 20:59:37 2008 -0700 sparc: remove CONFIG_SUN4 While doing some easy cleanups on the sparc code I noticed that the CONFIG_SUN4 code seems to be worse than the rest - there were some "I don't know how it should work, but the current code definitely cannot work." places. And while I have seen people running Linux on machines like a SPARCstation 5 a few years ago I don't recall having seen sun4 machines, even less ones running Linux. Signed-off-by: Adrian Bunk Signed-off-by: David S. Miller commit b69416b51be0757c82f1c5a0a3f0995a4484dab4 Author: David S. Miller Date: Sun Aug 31 20:56:15 2008 -0700 sparc64: Rewrite central driver. This driver is now limited to just doing the basic clock board and FHC chip initialization and registering the platform devices for the per-board LEDs, which are driven by the new LEDS_STARFIRE driver. The IRQ register handling is already confined purely to the device tree code. Signed-off-by: David S. Miller commit 5843492ccce3568ff6eb6efc52fb793923207d0b Author: David S. Miller Date: Sun Aug 31 20:26:48 2008 -0700 leds: Add driver for Sunfire UltraSPARC server LEDs. Signed-off-by: David S. Miller commit 7ca7d8d66c31eb678e4d456c17192a09db0b6123 Author: Dmitry Torokhov Date: Mon Sep 1 09:37:07 2008 +1000 hwmon: (ams) Simplify IRQ handling routine Simplify the IRQ handling routine of ams driver. Signed-off-by: Dmitry Torokhov Signed-off-by: Johannes Berg Signed-off-by: Jean Delvare commit 8b058eca7b461f4ac0d7371624b6cb9877cc01bb Author: Dmitry Torokhov Date: Mon Sep 1 09:37:07 2008 +1000 hwmon: (ams) Fix locking issues Use a separate mutex to serialize input device creation/removal, otheriwse we deadlock if we try to remove input device while it is being polled. Also do not take ams_info.lock when it is not needed. Signed-off-by: Dmitry Torokhov Signed-off-by: Johannes Berg Signed-off-by: Jean Delvare commit 6627df75084e67b1cca58500f8408abd0b3e5a93 Author: Dmitry Torokhov Date: Mon Sep 1 09:37:07 2008 +1000 hwmon: (ams) Fix permissions on 'joystick' module parameter We should not allow writes to the 'joystick' module parameters since writing there will not trigger creation of the input device. Disable writes since we provide alternative way of enabling input device via AMS device's sysfs attribute. Signed-off-by: Dmitry Torokhov Acked-by: Johannes Berg Signed-off-by: Jean Delvare commit cf997913ee645bc911b1162e8252ef591f1344d4 Author: Jean Delvare Date: Mon Sep 1 09:37:07 2008 +1000 ams: Convert to a new-style i2c driver The legacy i2c binding model is phasing out, so the ams driver needs to be converted to a new-style i2c driver. Here is a naive approach of this conversion. Basically it is moving the i2c device creation from the ams driver to the i2c-powermac driver. This should work, but I suspect we could come up with something cleaner by declaring the i2c device as part of the platform setup. This could be done later by someone more familiar with openfirmware-based platforms than I am myself. One nice thing brought by this conversion is that the ams driver should be loaded automatically on systems where is is needed (at least when the I2C interface to the chip is used) providing coldplug-aware user-space environment. Signed-off-by: Jean Delvare Acked-by: Johannes Berg Cc: Stelian Pop Cc: Michael Hanselmann Cc: Benjamin Herrenschmidt commit 2fdac01e0c648c43a2bd0cb874863097f1374061 Author: Ben Hutchings Date: Mon Sep 1 09:37:06 2008 +1000 hwmon: (lm87) Add support for configuration through platform_data The lm87 driver normally assumes that firmware configured the chip correctly. Since this is not always the case, alllow platform code to set the channel register value via platform_data. All other configuration registers can be changed after driver initialisation. Signed-off-by: Ben Hutchings Signed-off-by: Jean Delvare commit 081b516bb255d996422b9c16f56cc5cf77006476 Author: Ben Hutchings Date: Mon Sep 1 09:37:06 2008 +1000 hwmon: (lm87) Restore original configuration register on removal This means that if we have to start the monitor when probed, we also stop it on removal. Signed-off-by: Ben Hutchings Signed-off-by: Jean Delvare commit 0febea49aadbafdf7b14ea0915cbea00cc7f2be8 Author: Ben Hutchings Date: Mon Sep 1 09:37:06 2008 +1000 hwmon: (lm87) Fix masking of config register in lm87_init_client() lm87_init_client() conditionally sets the Start bit and clears the INT#_Clear bit in the Config 1 register. The condition should be that either of these bits needs changing, but currently it checks the (self-clearing) Initialization bit instead of INT#_Clear. Fix the condition and also ensure we never set the Initialization bit. Signed-off-by: Ben Hutchings Signed-off-by: Jean Delvare commit d7ef814ac46a69885ad8482b13336d679462dc4a Author: Jean Delvare Date: Mon Sep 1 09:37:06 2008 +1000 hwmon: (lm90) Don't spam the kernel log Degrade the "Unsupported chip" message from info to debug level. There's nothing wrong with this, so no need to bother the user. Also make the message slightly more descriptive. Signed-off-by: Jean Delvare Acked-by: Martyn Welch commit 84f8cf3aeb048b864916f829a535dd7f40804667 Author: Ben Hutchings Date: Mon Sep 1 09:37:05 2008 +1000 lm90: Support MAX6646, MAX6647 and MAX6649 These Maxim chips are similar to MAX6657 but use unsigned temperature values to allow for readings up to 145 degrees. Signed-off-by: Ben Hutchings Signed-off-by: Jean Delvare commit 22946b0dbf1d912cfb16e3a360b43bb1a917397a Author: Ben Hutchings Date: Mon Sep 1 09:37:05 2008 +1000 hwmon: (lm90) Rename temperature conversion functions to match usage The encoding of temperatures varies between chips and modes. So do not use "temp1" or "temp2" in the names of the conversion functions, but specify the encoding. Signed-off-by: Ben Hutchings Signed-off-by: Jean Delvare Tested-by: Martyn Welch commit f1a350f29eb83e225d27c6ea671cb380cd5818db Author: Nate Case Date: Mon Sep 1 09:37:05 2008 +1000 hwmon: (lm90) Support ADT7461 in extended mode Support ADT7461 in extended temperature range mode, which will change the range of readings from 0..127 to -64..191 degC. Adjust the register conversion functions accordingly. Signed-off-by: Nate Case Signed-off-by: Jean Delvare Tested-by: Martyn Welch commit 4c3c3c442dc4733b6729602e502d19b77c408eb2 Author: Nate Case Date: Mon Sep 1 09:37:05 2008 +1000 hwmon: (lm90) Convert some macros to static functions Use static functions instead of the TEMPx_FROM_REG* and TEMPx_TO_REG* macros. This will ensure type safety and eliminate any side effects from arguments passed in since the macros referenced 'val' multiple times. This change should not affect functionality. Signed-off-by: Nate Case Signed-off-by: Jean Delvare Tested-by: Martyn Welch commit ec323ffe5cc64af677f34c710663a356479c574a Author: Jean Delvare Date: Mon Sep 1 09:37:04 2008 +1000 hwmon: (lm90) Update datasheet links Update the links to the datasheet of some of the devices supported by the lm90 driver. Also remove the links from the driver itself, so that we don't have to update them twice each time they change. Signed-off-by: Jean Delvare Acked-by: Martyn Welch commit 3c39a721f899e2180a31191ee946b6a07e912d25 Author: Jean Delvare Date: Mon Sep 1 09:37:04 2008 +1000 hwmon: (lm90) Don't access nonexistent registers on Maxim chips The Maxim chips supported by the lm90 driver have 8-bit high and low remote limit values, not 11-bit as the other chips have. So stop reading from and writing to registers that do not exist on these chips. Also round the limit values set by the user properly. Signed-off-by: Jean Delvare Acked-by: Martyn Welch commit 80e57551ff738b1ab0230b14f19148199cd041fc Author: Jean Delvare Date: Mon Sep 1 09:37:04 2008 +1000 hwmon: (lm90) Support the extra resolution bits of MAX6657 The Maxim MAX6657, MAX6658 and MAX6659 have extra resolution bits for the local temperature measurement. Let the lm90 driver read them and export them to user-space. Signed-off-by: Jean Delvare Acked-by: Martyn Welch commit 242637cc8b3e37346c6ff007f67abfa4aca89912 Author: Jean Delvare Date: Mon Sep 1 09:37:03 2008 +1000 hwmon: (lm90) Move 16-bit value read to a separate function Move the code which aggregates two 8-bit register values into a 16-bit value to a separate function. We'll need to do it a second time soon and I don't want to duplicate the code. Signed-off-by: Jean Delvare Acked-by: Martyn Welch commit 6a6cf40bb5f40184638c5903293af4266940ff25 Author: Adrian Bunk Date: Mon Sep 1 09:37:03 2008 +1000 hwmon: (ad7414) Make ad7414_update_device() static This patch makes the needlessly global ad7414_update_device() static. Signed-off-by: Adrian Bunk Acked-by: Sean MacLennan Signed-off-by: Jean Delvare commit 8943d30fc73b984c667a6998d907c5d1cb6e434f Author: Jean Delvare Date: Mon Sep 1 09:37:03 2008 +1000 hwmon: (atxp1) Fix device detection logic The atxp1 device detection code has a major logic flaw, fix it. Not sure how we managed to miss this when the driver was merged... Signed-off-by: Jean Delvare Acked-by: Sebastian Witt commit a3eeb09fcc630c84e3ef01f707249f44f177a683 Author: Jean Delvare Date: Mon Sep 1 09:37:01 2008 +1000 i2c-floppy: Mutually exclusive with the PC floppy driver Make sure that the i2c-floppy and floppy drivers can't both be built into the kernel. Also tag i2c-floppy EXPERIMENTAL for now, it's a new driver that did not see much testing yet. Signed-off-by: Jean Delvare Cc: Herbert Poetzl commit f590f1a7e5594b34d0a5b64ffc967693c3f230f7 Author: Herbert Poetzl Date: Mon Sep 1 09:37:01 2008 +1000 i2c: Floppy controller bus driver I recently got the idea to (re)use the (at least for me) very often unused floppy connector to attach some hardware to monitor system temperature and control some fans. The basic idea is to connect one of the Motor Control lines with the Disk Changed input to form the SDA line, and the other Motor Control line to control the SCL. This works surprisingly well, as the Motor Control lines are open drain, and the Disk Changed input is CMOS/TTL (depending on the controller). Signed-off-by: Herbert Poetzl Signed-off-by: Jean Delvare commit 25a9f70842b68c15096d48389b80c139bff2fc0d Author: Jean Delvare Date: Mon Sep 1 09:37:01 2008 +1000 hwmon: (dme1737) Convert to a new-style i2c driver The new-style dme1737 driver implements the optional detect() callback to cover the use cases of the legacy driver. I don't actually expect any new-style device for that driver, but as the old i2c API is going away soon, we have to switch to the new one. Signed-off-by: Jean Delvare Cc: Juerg Haefliger commit 151a75161869493e80234ba300ecd78629dbdab4 Author: Jean Delvare Date: Mon Sep 1 09:37:00 2008 +1000 hwmon: (dme1737) Be less i2c-centric The dme1737 driver support both LPC (ISA) and SMBus devices. At the moment it's rather i2c-centric, and LPC variants use a fake i2c_client for some operations. In a near future, i2c_client will be allocated by i2c-core rather than by the device drivers, so non-i2c drivers will not have one. As a preparation step, change the driver code to no longer assume that an i2c_client structure is always available. No functional change. Signed-off-by: Jean Delvare Cc: Juerg Haefliger commit 0e2d59186e555b93c0ccc82d399435b4ead30a1b Author: Marek Vasut Date: Mon Sep 1 09:37:00 2008 +1000 i2c/tps65010: Vibrator hookup to gpiolib All the tps6501{0,1,2,3,4} chips have a signal for hooking up with a vibrator (for non-auditory cell phone "ring") ... expose that as one more (output-only) GPIO. [ dbrownell@users.sourceforge.net: comments; list tps65014 too ] Signed-off-by: Marek Vasut Signed-off-by: David Brownell Signed-off-by: Jean Delvare commit 0e1eb5cc29980c781184952b60a5d99b55774c91 Author: Rudolf Marek Date: Mon Sep 1 09:37:00 2008 +1000 i2c-viapro: Add VX800/VX820 support Thanks to new datasheets published on http://linux.via.com.tw we can now add support for VX800/VX820 chipsets. Signed-off-by: Rudolf Marek Signed-off-by: Jean Delvare commit 445b5f26d916fc0b0871cf5662f8d831af58949d Author: Paul Mundt Date: Mon Sep 1 09:37:00 2008 +1000 i2c: Renesas Highlander FPGA SMBus support This adds support for the SMBus adapter found in the various FPGAs on the Renesas Highlander platforms. Particularly the R0P7780LC0011RL and R0P7785LC0011RL FPGAs. Functionality is fairly restricted, in that only byte and block data transfers are supported. Normal/fast mode and IRQ/polling are also supported. Primarily used for various RTCs and thermal sensors. Signed-off-by: Paul Mundt Signed-off-by: Jean Delvare commit 4001694896d65ad5e1b6902fda5a913c27d37b37 Author: Rene Herman Date: Mon Sep 1 09:36:59 2008 +1000 i2c-pca-isa: Don't grab arbitrary resources Grabbing ISA bus resources without anything or anyone telling us we should can break boot on randconfig/allyesconfig builds by keeping resources that are in fact owned by different hardware busy and does as reported by Ingo Molnar. Generally it's also dangerous to just poke at random I/O ports and especially those in the range where other old easily confused ISA hardware might live. For this specialized I2C bus driver, insist that the user specifies the resources before grabbing them. The^WA user of this driver is a one time echo "options i2c-pca-isa base=0x330 irq=10" >> /etc/modprobe.conf away from the old behaviour. Signed-off-by: Rene Herman Signed-off-by: Jean Delvare commit 6902f28ef48340cde7d91015e12d3110fdaf938f Author: Jean Delvare Date: Mon Sep 1 09:36:59 2008 +1000 i2c/isp1301_omap: Convert to a new-style i2c driver, part 2 Based on David Brownell's patch for tps65010 and previous work by Felipe Balbi, this patch finishes conversting isp1301_omap to a new-style i2c driver. There's definitely room for further drivers cleanups, but these are out of the scope of this patch. Signed-off-by: Jean Delvare commit 5213a38cd278a3f44b39c17fd45e1465e193a61a Author: Felipe Balbi Date: Mon Sep 1 09:36:59 2008 +1000 i2c/isp1301_omap: Convert to a new-style i2c driver, part 1 Based on David Brownell's patch for tps65010, this patch starts converting isp1301_omap.c to new-style i2c driver. Signed-off-by: Felipe Balbi Signed-off-by: Jean Delvare commit b996ad0e9fb15ca4acc60bcd0380912117a45d13 Author: Rodolfo Giometti Date: Wed Aug 20 16:52:58 2008 -0700 power_supply: Support for Texas Instruments BQ27200 battery managers These battery managers came in two different packages: one for I2C busses (BQ27200) and one for HDQ busses (BQ27000). This driver currently supports only the I2C chip version but the code is designed in order to easily allow the HDQ chip version integration. [akpm@linux-foundation.org: coding-style fixes] [akpm@linux-foundation.org: make things static, use kasprintf()] Signed-off-by: Rodolfo Giometti Cc: David Woodhouse Signed-off-by: Andrew Morton Signed-off-by: Anton Vorontsov commit 942ed161944b3476639916cf544e6975b29c985a Author: Matthew Garrett Date: Tue Aug 26 21:09:59 2008 +0100 power_supply: Add function to return system-wide power state Certain drivers benefit from knowing whether the system is on ac or battery, for instance when determining which backlight registers to read. This adds a simple call to determine whether there's an online power supply other than any batteries. Signed-off-by: Matthew Garrett Signed-off-by: Anton Vorontsov commit e82374fd1a804e197fc2a54c3930e70c5d300abc Author: Robert Jarzmik Date: Mon Aug 11 22:22:27 2008 +0200 pda_power: Check and handle return value of set_irq_wake The recent change in commit 2db873211ba47ef704c301f9ecf4a33413a0b649 forces the calls enable_irq_wake() and disable_irq_wake() to be balanced. But if in pda_power_suspend() the call to enable_irq_wake() fails (because attached gpio cannot wake up the CPU), the corresponding disable_irq_wake will WARN(). Fix it by storing success/failure of enable_irq_wake(). Signed-off-by: Robert Jarzmik Signed-off-by: Anton Vorontsov commit 50a11a2cc8cc3972a82973c53e90c0e7e7cb91ed Author: Artem Bityutskiy Date: Sun Aug 31 19:32:13 2008 +0300 UBI: remove BLK We do not need BLK in UBI because we serialize things properly. Signed-off-by: Artem Bityutskiy commit 10062a7e9b68f0c9f34172e5958c1755bd5bd121 Author: Christoph Lameter Date: Mon Aug 25 14:20:38 2008 -0700 dentries: dentry defragmentation The dentry pruning for unused entries works in a straightforward way. It could be made more aggressive if one would actually move dentries instead of just reclaiming them. Cc: Alexander Viro Cc: Christoph Hellwig Reviewed-by: Rik van Riel Signed-off-by: Christoph Lameter Signed-off-by: Christoph Lameter Signed-off-by: Pekka Enberg commit 6c6b763f76a48c71845cf9450526e770dd249e24 Author: Christoph Lameter Date: Mon Aug 25 14:20:37 2008 -0700 dentries: Add constructor In order to support defragmentation on the dentry cache we need to have a determined object state at all times. Without a constructor the object would have a random state after allocation. So provide a constructor. Cc: Alexander Viro Cc: Christoph Hellwig Reviewed-by: Rik van Riel Signed-off-by: Christoph Lameter Signed-off-by: Christoph Lameter Signed-off-by: Pekka Enberg commit 74fefe56a1267efd6197df3a4f349d1365bd9482 Author: Christoph Lameter Date: Mon Aug 25 14:20:36 2008 -0700 dentries: Always use list_del_init() when removing a dentry from the lru The patch restores what commit 4a0962abd187df29b7d1378b2f372a55667d54c0 already implemented. The feature was subsequently clobbered by commit da3bbdd4632c0171406b2677e31494afa5bde2f8 Before this patch some execution path use list_del() instead of list_del_init() which results in inconsitencies in the state of d_lru when the object is freed. The performance of list_del_init() and list_del() is the same. So lets just have one dentry removal function named dentry_lru_del() that always does a list_del_init(). The result of this patch is that dentry->d_lru is now always empty when a dentry is freed. The dentry defragmentation patch depends on a defined state of a dentry on free. Signed-off-by: Christoph Lameter Signed-off-by: Pekka Enberg commit b9f1ecc6428f0ba391845b2ac7df8618da287e4f Author: Eduard - Gabriel Munteanu Date: Sun Aug 24 20:49:35 2008 +0300 kmemtrace: SLUB hooks for caller-tracking functions. This patch adds kmemtrace hooks for __kmalloc_track_caller() and __kmalloc_node_track_caller(). Currently, they set the call site pointer to the value recieved as a parameter. (This could change if we implement stack trace exporting in kmemtrace.) Signed-off-by: Eduard - Gabriel Munteanu Signed-off-by: Pekka Enberg commit b3385c278d3c32aec68d4900b35bc07df1b2240c Author: Artem Bityutskiy Date: Sun Aug 31 17:13:18 2008 +0300 UBIFS: fill f_fsid UBIFS stores 16-bit UUID in the superblock, and it is a good idea to return part of it in 'f_fsid' filed of kstatfs structure. Signed-off-by: Artem Bityutskiy commit 7dad181bbe58b8fe9e170da28bcd5f6ec9addd6d Author: Artem Bityutskiy Date: Mon Aug 25 18:58:19 2008 +0300 UBIFS: improve statfs reporting even more Since free space we report in statfs is file size which should fit to the FS - change the way we calculate free space and use leb_overhead instead of dark_wm in calculations. Results of "freespace" test (120MiB volume, 16KiB LEB size, 512 bytes page size). Before the change: freespace: Test 1: fill the space we have 3 times freespace: was free: 85204992 bytes 81.3 MiB, wrote: 96489472 bytes 92.0 MiB, delta: 11284480 bytes 10.8 MiB, wrote 13.2% more than predicted freespace: was free: 83554304 bytes 79.7 MiB, wrote: 96489472 bytes 92.0 MiB, delta: 12935168 bytes 12.3 MiB, wrote 15.5% more than predicted freespace: was free: 83554304 bytes 79.7 MiB, wrote: 96493568 bytes 92.0 MiB, delta: 12939264 bytes 12.3 MiB, wrote 15.5% more than predicted freespace: Test 1 finished freespace: Test 2: gradually lessen amount of free space and fill the FS freespace: do 10 steps, lessen free space by 7596218 bytes 7.2 MiB each time freespace: was free: 78675968 bytes 75.0 MiB, wrote: 88903680 bytes 84.8 MiB, delta: 10227712 bytes 9.8 MiB, wrote 13.0% more than predicted freespace: was free: 72015872 bytes 68.7 MiB, wrote: 81514496 bytes 77.7 MiB, delta: 9498624 bytes 9.1 MiB, wrote 13.2% more than predicted freespace: was free: 63938560 bytes 61.0 MiB, wrote: 72589312 bytes 69.2 MiB, delta: 8650752 bytes 8.2 MiB, wrote 13.5% more than predicted freespace: was free: 56127488 bytes 53.5 MiB, wrote: 63762432 bytes 60.8 MiB, delta: 7634944 bytes 7.3 MiB, wrote 13.6% more than predicted freespace: was free: 48336896 bytes 46.1 MiB, wrote: 54935552 bytes 52.4 MiB, delta: 6598656 bytes 6.3 MiB, wrote 13.7% more than predicted freespace: was free: 40587264 bytes 38.7 MiB, wrote: 46157824 bytes 44.0 MiB, delta: 5570560 bytes 5.3 MiB, wrote 13.7% more than predicted freespace: was free: 32841728 bytes 31.3 MiB, wrote: 37384192 bytes 35.7 MiB, delta: 4542464 bytes 4.3 MiB, wrote 13.8% more than predicted freespace: was free: 25100288 bytes 23.9 MiB, wrote: 28618752 bytes 27.3 MiB, delta: 3518464 bytes 3.4 MiB, wrote 14.0% more than predicted freespace: was free: 17342464 bytes 16.5 MiB, wrote: 19841024 bytes 18.9 MiB, delta: 2498560 bytes 2.4 MiB, wrote 14.4% more than predicted freespace: was free: 9605120 bytes 9.2 MiB, wrote: 11063296 bytes 10.6 MiB, delta: 1458176 bytes 1.4 MiB, wrote 15.2% more than predicted freespace: Test 2 finished freespace: Test 3: gradually lessen amount of free space by trashing and fill the FS freespace: do 10 steps, lessen free space by 7606272 bytes 7.3 MiB each time freespace: trashing: was free: 83668992 bytes 79.8 MiB, need free: 7606272 bytes 7.3 MiB, files created: 248297, delete 225724 (90.9% of them) freespace: was free: 70803456 bytes 67.5 MiB, wrote: 82485248 bytes 78.7 MiB, delta: 11681792 bytes 11.1 MiB, wrote 16.5% more than predicted freespace: trashing: was free: 81080320 bytes 77.3 MiB, need free: 15212544 bytes 14.5 MiB, files created: 248711, delete 202047 (81.2% of them) freespace: was free: 59867136 bytes 57.1 MiB, wrote: 71897088 bytes 68.6 MiB, delta: 12029952 bytes 11.5 MiB, wrote 20.1% more than predicted freespace: trashing: was free: 82243584 bytes 78.4 MiB, need free: 22818816 bytes 21.8 MiB, files created: 248866, delete 179817 (72.3% of them) freespace: was free: 50905088 bytes 48.5 MiB, wrote: 63168512 bytes 60.2 MiB, delta: 12263424 bytes 11.7 MiB, wrote 24.1% more than predicted freespace: trashing: was free: 83402752 bytes 79.5 MiB, need free: 30425088 bytes 29.0 MiB, files created: 248920, delete 158114 (63.5% of them) freespace: was free: 42651648 bytes 40.7 MiB, wrote: 55406592 bytes 52.8 MiB, delta: 12754944 bytes 12.2 MiB, wrote 29.9% more than predicted freespace: trashing: was free: 84402176 bytes 80.5 MiB, need free: 38031360 bytes 36.3 MiB, files created: 248709, delete 136641 (54.9% of them) freespace: was free: 35233792 bytes 33.6 MiB, wrote: 48250880 bytes 46.0 MiB, delta: 13017088 bytes 12.4 MiB, wrote 36.9% more than predicted freespace: trashing: was free: 82530304 bytes 78.7 MiB, need free: 45637632 bytes 43.5 MiB, files created: 248778, delete 111208 (44.7% of them) freespace: was free: 27287552 bytes 26.0 MiB, wrote: 40267776 bytes 38.4 MiB, delta: 12980224 bytes 12.4 MiB, wrote 47.6% more than predicted freespace: trashing: was free: 85114880 bytes 81.2 MiB, need free: 53243904 bytes 50.8 MiB, files created: 248508, delete 93052 (37.4% of them) freespace: was free: 22437888 bytes 21.4 MiB, wrote: 35328000 bytes 33.7 MiB, delta: 12890112 bytes 12.3 MiB, wrote 57.4% more than predicted freespace: trashing: was free: 84103168 bytes 80.2 MiB, need free: 60850176 bytes 58.0 MiB, files created: 248637, delete 68743 (27.6% of them) freespace: was free: 15536128 bytes 14.8 MiB, wrote: 28319744 bytes 27.0 MiB, delta: 12783616 bytes 12.2 MiB, wrote 82.3% more than predicted freespace: trashing: was free: 84357120 bytes 80.4 MiB, need free: 68456448 bytes 65.3 MiB, files created: 248567, delete 46852 (18.8% of them) freespace: was free: 9015296 bytes 8.6 MiB, wrote: 22044672 bytes 21.0 MiB, delta: 13029376 bytes 12.4 MiB, wrote 144.5% more than predicted freespace: trashing: was free: 84942848 bytes 81.0 MiB, need free: 76062720 bytes 72.5 MiB, files created: 248636, delete 25993 (10.5% of them) freespace: was free: 6086656 bytes 5.8 MiB, wrote: 8331264 bytes 7.9 MiB, delta: 2244608 bytes 2.1 MiB, wrote 36.9% more than predicted freespace: Test 3 finished freespace: finished successfully After the change: freespace: Test 1: fill the space we have 3 times freespace: was free: 94048256 bytes 89.7 MiB, wrote: 96489472 bytes 92.0 MiB, delta: 2441216 bytes 2.3 MiB, wrote 2.6% more than predicted freespace: was free: 92246016 bytes 88.0 MiB, wrote: 96493568 bytes 92.0 MiB, delta: 4247552 bytes 4.1 MiB, wrote 4.6% more than predicted freespace: was free: 92254208 bytes 88.0 MiB, wrote: 96489472 bytes 92.0 MiB, delta: 4235264 bytes 4.0 MiB, wrote 4.6% more than predicted freespace: Test 1 finished freespace: Test 2: gradually lessen amount of free space and fill the FS freespace: do 10 steps, lessen free space by 8386001 bytes 8.0 MiB each time freespace: was free: 86605824 bytes 82.6 MiB, wrote: 88252416 bytes 84.2 MiB, delta: 1646592 bytes 1.6 MiB, wrote 1.9% more than predicted freespace: was free: 78667776 bytes 75.0 MiB, wrote: 80715776 bytes 77.0 MiB, delta: 2048000 bytes 2.0 MiB, wrote 2.6% more than predicted freespace: was free: 69615616 bytes 66.4 MiB, wrote: 71630848 bytes 68.3 MiB, delta: 2015232 bytes 1.9 MiB, wrote 2.9% more than predicted freespace: was free: 61018112 bytes 58.2 MiB, wrote: 62783488 bytes 59.9 MiB, delta: 1765376 bytes 1.7 MiB, wrote 2.9% more than predicted freespace: was free: 52424704 bytes 50.0 MiB, wrote: 53968896 bytes 51.5 MiB, delta: 1544192 bytes 1.5 MiB, wrote 2.9% more than predicted freespace: was free: 43880448 bytes 41.8 MiB, wrote: 45199360 bytes 43.1 MiB, delta: 1318912 bytes 1.3 MiB, wrote 3.0% more than predicted freespace: was free: 35332096 bytes 33.7 MiB, wrote: 36425728 bytes 34.7 MiB, delta: 1093632 bytes 1.0 MiB, wrote 3.1% more than predicted freespace: was free: 26771456 bytes 25.5 MiB, wrote: 27643904 bytes 26.4 MiB, delta: 872448 bytes 852.0 KiB, wrote 3.3% more than predicted freespace: was free: 18231296 bytes 17.4 MiB, wrote: 18878464 bytes 18.0 MiB, delta: 647168 bytes 632.0 KiB, wrote 3.5% more than predicted freespace: was free: 9674752 bytes 9.2 MiB, wrote: 10088448 bytes 9.6 MiB, delta: 413696 bytes 404.0 KiB, wrote 4.3% more than predicted freespace: Test 2 finished freespace: Test 3: gradually lessen amount of free space by trashing and fill the FS freespace: do 10 steps, lessen free space by 8397544 bytes 8.0 MiB each time freespace: trashing: was free: 92372992 bytes 88.1 MiB, need free: 8397552 bytes 8.0 MiB, files created: 248296, delete 225723 (90.9% of them) freespace: was free: 71909376 bytes 68.6 MiB, wrote: 82472960 bytes 78.7 MiB, delta: 10563584 bytes 10.1 MiB, wrote 14.7% more than predicted freespace: trashing: was free: 88989696 bytes 84.9 MiB, need free: 16795096 bytes 16.0 MiB, files created: 248794, delete 201838 (81.1% of them) freespace: was free: 60354560 bytes 57.6 MiB, wrote: 71782400 bytes 68.5 MiB, delta: 11427840 bytes 10.9 MiB, wrote 18.9% more than predicted freespace: trashing: was free: 90304512 bytes 86.1 MiB, need free: 25192640 bytes 24.0 MiB, files created: 248733, delete 179342 (72.1% of them) freespace: was free: 51187712 bytes 48.8 MiB, wrote: 62943232 bytes 60.0 MiB, delta: 11755520 bytes 11.2 MiB, wrote 23.0% more than predicted freespace: trashing: was free: 91209728 bytes 87.0 MiB, need free: 33590184 bytes 32.0 MiB, files created: 248779, delete 157160 (63.2% of them) freespace: was free: 42704896 bytes 40.7 MiB, wrote: 55050240 bytes 52.5 MiB, delta: 12345344 bytes 11.8 MiB, wrote 28.9% more than predicted freespace: trashing: was free: 92700672 bytes 88.4 MiB, need free: 41987728 bytes 40.0 MiB, files created: 248848, delete 136135 (54.7% of them) freespace: was free: 35250176 bytes 33.6 MiB, wrote: 48115712 bytes 45.9 MiB, delta: 12865536 bytes 12.3 MiB, wrote 36.5% more than predicted freespace: trashing: was free: 93986816 bytes 89.6 MiB, need free: 50385272 bytes 48.1 MiB, files created: 248723, delete 115385 (46.4% of them) freespace: was free: 29995008 bytes 28.6 MiB, wrote: 41582592 bytes 39.7 MiB, delta: 11587584 bytes 11.1 MiB, wrote 38.6% more than predicted freespace: trashing: was free: 91881472 bytes 87.6 MiB, need free: 58782816 bytes 56.1 MiB, files created: 248645, delete 89569 (36.0% of them) freespace: was free: 22511616 bytes 21.5 MiB, wrote: 34705408 bytes 33.1 MiB, delta: 12193792 bytes 11.6 MiB, wrote 54.2% more than predicted freespace: trashing: was free: 91774976 bytes 87.5 MiB, need free: 67180360 bytes 64.1 MiB, files created: 248580, delete 66616 (26.8% of them) freespace: was free: 16908288 bytes 16.1 MiB, wrote: 26898432 bytes 25.7 MiB, delta: 9990144 bytes 9.5 MiB, wrote 59.1% more than predicted freespace: trashing: was free: 92450816 bytes 88.2 MiB, need free: 75577904 bytes 72.1 MiB, files created: 248654, delete 45381 (18.3% of them) freespace: was free: 10170368 bytes 9.7 MiB, wrote: 19111936 bytes 18.2 MiB, delta: 8941568 bytes 8.5 MiB, wrote 87.9% more than predicted freespace: trashing: was free: 93282304 bytes 89.0 MiB, need free: 83975448 bytes 80.1 MiB, files created: 248513, delete 24794 (10.0% of them) freespace: was free: 3911680 bytes 3.7 MiB, wrote: 7872512 bytes 7.5 MiB, delta: 3960832 bytes 3.8 MiB, wrote 101.3% more than predicted freespace: Test 3 finished freespace: finished successfully Signed-off-by: Artem Bityutskiy commit 9bbb5726efb64e2cfed42f6eec07db80cd87e63b Author: Artem Bityutskiy Date: Fri Aug 22 18:23:22 2008 +0300 UBIFS: introduce LEB overhead This is a preparational patch for the following statfs() report fix. Signed-off-by: Artem Bityutskiy commit 131130b9a1e6e523c64b34137b14f88ae1382a6a Author: Artem Bityutskiy Date: Mon Aug 25 18:34:45 2008 +0300 UBIFS: add forgotten gc_idx_lebs component We add this component at other similar places, but not in this one. Signed-off-by: Artem Bityutskiy commit ad507653a39e0d27404291e5d813683265388a20 Author: Artem Bityutskiy Date: Mon Aug 25 18:32:57 2008 +0300 UBIFS: fix assertion The assertion was incorrect, because it did not take into account free space. This patch also amends the comments correspondingly, and cleans them up a little. Signed-off-by: Artem Bityutskiy commit 4b5f2762ec914c9dfd0e9d2377c0574f2ee9a8f9 Author: Artem Bityutskiy Date: Mon Aug 25 16:15:56 2008 +0300 UBIFS: improve statfs reporting Make free space calculation less pessimistic and more realistic, which in turn improves 'statfs()' reports. Now it lies by 10%-20%, instead of 20%-30% (10% more honest). Results of "freespace" test (120MiB volume, 16KiB LEB size, 512 bytes page size). Before the change: freespace: Test 1: fill the space we have 3 times freespace: was free: 78274560 bytes 74.6 MiB, wrote: 96489472 bytes 92.0 MiB, delta: 18214912 bytes 17.4 MiB, wrote 23.3% more than predicted freespace: was free: 76754944 bytes 73.2 MiB, wrote: 96493568 bytes 92.0 MiB, delta: 19738624 bytes 18.8 MiB, wrote 25.7% more than predicted freespace: was free: 76759040 bytes 73.2 MiB, wrote: 96489472 bytes 92.0 MiB, delta: 19730432 bytes 18.8 MiB, wrote 25.7% more than predicted freespace: Test 1 finished freespace: Test 2: gradually lessen amount of free space and fill the FS freespace: do 10 steps, lessen free space by 6977722 bytes 6.7 MiB each time freespace: was free: 72273920 bytes 68.9 MiB, wrote: 88891392 bytes 84.8 MiB, delta: 16617472 bytes 15.8 MiB, wrote 23.0% more than predicted freespace: was free: 66154496 bytes 63.1 MiB, wrote: 81506304 bytes 77.7 MiB, delta: 15351808 bytes 14.6 MiB, wrote 23.2% more than predicted freespace: was free: 58732544 bytes 56.0 MiB, wrote: 72572928 bytes 69.2 MiB, delta: 13840384 bytes 13.2 MiB, wrote 23.6% more than predicted freespace: was free: 51552256 bytes 49.2 MiB, wrote: 63754240 bytes 60.8 MiB, delta: 12201984 bytes 11.6 MiB, wrote 23.7% more than predicted freespace: was free: 44404736 bytes 42.3 MiB, wrote: 54943744 bytes 52.4 MiB, delta: 10539008 bytes 10.1 MiB, wrote 23.7% more than predicted freespace: was free: 37285888 bytes 35.6 MiB, wrote: 46161920 bytes 44.0 MiB, delta: 8876032 bytes 8.5 MiB, wrote 23.8% more than predicted freespace: was free: 30171136 bytes 28.8 MiB, wrote: 37384192 bytes 35.7 MiB, delta: 7213056 bytes 6.9 MiB, wrote 23.9% more than predicted freespace: was free: 23048192 bytes 22.0 MiB, wrote: 28606464 bytes 27.3 MiB, delta: 5558272 bytes 5.3 MiB, wrote 24.1% more than predicted freespace: was free: 15941632 bytes 15.2 MiB, wrote: 19828736 bytes 18.9 MiB, delta: 3887104 bytes 3.7 MiB, wrote 24.4% more than predicted freespace: was free: 8830976 bytes 8.4 MiB, wrote: 11063296 bytes 10.6 MiB, delta: 2232320 bytes 2.1 MiB, wrote 25.3% more than predicted freespace: Test 2 finished freespace: Test 3: gradually lessen amount of free space by trashing and fill the FS freespace: do 10 steps, lessen free space by 6985541 bytes 6.7 MiB each time freespace: trashing: was free: 76840960 bytes 73.3 MiB, need free: 6985550 bytes 6.7 MiB, files created: 248311, delete 225737 (90.9% of them) freespace: was free: 65228800 bytes 62.2 MiB, wrote: 82530304 bytes 78.7 MiB, delta: 17301504 bytes 16.5 MiB, wrote 26.5% more than predicted freespace: trashing: was free: 74485760 bytes 71.0 MiB, need free: 13971091 bytes 13.3 MiB, files created: 248712, delete 202061 (81.2% of them) freespace: was free: 55025664 bytes 52.5 MiB, wrote: 71925760 bytes 68.6 MiB, delta: 16900096 bytes 16.1 MiB, wrote 30.7% more than predicted freespace: trashing: was free: 75550720 bytes 72.1 MiB, need free: 20956632 bytes 20.0 MiB, files created: 248849, delete 179822 (72.3% of them) freespace: was free: 46669824 bytes 44.5 MiB, wrote: 63197184 bytes 60.3 MiB, delta: 16527360 bytes 15.8 MiB, wrote 35.4% more than predicted freespace: trashing: was free: 76214272 bytes 72.7 MiB, need free: 27942173 bytes 26.6 MiB, files created: 248789, delete 157576 (63.3% of them) freespace: was free: 39129088 bytes 37.3 MiB, wrote: 55164928 bytes 52.6 MiB, delta: 16035840 bytes 15.3 MiB, wrote 41.0% more than predicted freespace: trashing: was free: 77398016 bytes 73.8 MiB, need free: 34927714 bytes 33.3 MiB, files created: 248711, delete 136474 (54.9% of them) freespace: was free: 32325632 bytes 30.8 MiB, wrote: 48234496 bytes 46.0 MiB, delta: 15908864 bytes 15.2 MiB, wrote 49.2% more than predicted freespace: trashing: was free: 75796480 bytes 72.3 MiB, need free: 41913255 bytes 40.0 MiB, files created: 248674, delete 111164 (44.7% of them) freespace: was free: 25079808 bytes 23.9 MiB, wrote: 40775680 bytes 38.9 MiB, delta: 15695872 bytes 15.0 MiB, wrote 62.6% more than predicted freespace: trashing: was free: 78209024 bytes 74.6 MiB, need free: 48898796 bytes 46.6 MiB, files created: 248708, delete 93207 (37.5% of them) freespace: was free: 20582400 bytes 19.6 MiB, wrote: 34844672 bytes 33.2 MiB, delta: 14262272 bytes 13.6 MiB, wrote 69.3% more than predicted freespace: trashing: was free: 77328384 bytes 73.7 MiB, need free: 55884337 bytes 53.3 MiB, files created: 248644, delete 68951 (27.7% of them) freespace: was free: 14368768 bytes 13.7 MiB, wrote: 28278784 bytes 27.0 MiB, delta: 13910016 bytes 13.3 MiB, wrote 96.8% more than predicted freespace: trashing: was free: 77434880 bytes 73.8 MiB, need free: 62869878 bytes 60.0 MiB, files created: 248640, delete 46767 (18.8% of them) freespace: was free: 8286208 bytes 7.9 MiB, wrote: 21811200 bytes 20.8 MiB, delta: 13524992 bytes 12.9 MiB, wrote 163.2% more than predicted freespace: trashing: was free: 77856768 bytes 74.2 MiB, need free: 69855419 bytes 66.6 MiB, files created: 248576, delete 25546 (10.3% of them) freespace: was free: 5570560 bytes 5.3 MiB, wrote: 8187904 bytes 7.8 MiB, delta: 2617344 bytes 2.5 MiB, wrote 47.0% more than predicted freespace: Test 3 finished freespace: finished successfully After the change: freespace: Test 1: fill the space we have 3 times freespace: was free: 85204992 bytes 81.3 MiB, wrote: 96489472 bytes 92.0 MiB, delta: 11284480 bytes 10.8 MiB, wrote 13.2% more than predicted freespace: was free: 83554304 bytes 79.7 MiB, wrote: 96489472 bytes 92.0 MiB, delta: 12935168 bytes 12.3 MiB, wrote 15.5% more than predicted freespace: was free: 83554304 bytes 79.7 MiB, wrote: 96493568 bytes 92.0 MiB, delta: 12939264 bytes 12.3 MiB, wrote 15.5% more than predicted freespace: Test 1 finished freespace: Test 2: gradually lessen amount of free space and fill the FS freespace: do 10 steps, lessen free space by 7596218 bytes 7.2 MiB each time freespace: was free: 78675968 bytes 75.0 MiB, wrote: 88903680 bytes 84.8 MiB, delta: 10227712 bytes 9.8 MiB, wrote 13.0% more than predicted freespace: was free: 72015872 bytes 68.7 MiB, wrote: 81514496 bytes 77.7 MiB, delta: 9498624 bytes 9.1 MiB, wrote 13.2% more than predicted freespace: was free: 63938560 bytes 61.0 MiB, wrote: 72589312 bytes 69.2 MiB, delta: 8650752 bytes 8.2 MiB, wrote 13.5% more than predicted freespace: was free: 56127488 bytes 53.5 MiB, wrote: 63762432 bytes 60.8 MiB, delta: 7634944 bytes 7.3 MiB, wrote 13.6% more than predicted freespace: was free: 48336896 bytes 46.1 MiB, wrote: 54935552 bytes 52.4 MiB, delta: 6598656 bytes 6.3 MiB, wrote 13.7% more than predicted freespace: was free: 40587264 bytes 38.7 MiB, wrote: 46157824 bytes 44.0 MiB, delta: 5570560 bytes 5.3 MiB, wrote 13.7% more than predicted freespace: was free: 32841728 bytes 31.3 MiB, wrote: 37384192 bytes 35.7 MiB, delta: 4542464 bytes 4.3 MiB, wrote 13.8% more than predicted freespace: was free: 25100288 bytes 23.9 MiB, wrote: 28618752 bytes 27.3 MiB, delta: 3518464 bytes 3.4 MiB, wrote 14.0% more than predicted freespace: was free: 17342464 bytes 16.5 MiB, wrote: 19841024 bytes 18.9 MiB, delta: 2498560 bytes 2.4 MiB, wrote 14.4% more than predicted freespace: was free: 9605120 bytes 9.2 MiB, wrote: 11063296 bytes 10.6 MiB, delta: 1458176 bytes 1.4 MiB, wrote 15.2% more than predicted freespace: Test 2 finished freespace: Test 3: gradually lessen amount of free space by trashing and fill the FS freespace: do 10 steps, lessen free space by 7606272 bytes 7.3 MiB each time freespace: trashing: was free: 83668992 bytes 79.8 MiB, need free: 7606272 bytes 7.3 MiB, files created: 248297, delete 225724 (90.9% of them) freespace: was free: 70803456 bytes 67.5 MiB, wrote: 82485248 bytes 78.7 MiB, delta: 11681792 bytes 11.1 MiB, wrote 16.5% more than predicted freespace: trashing: was free: 81080320 bytes 77.3 MiB, need free: 15212544 bytes 14.5 MiB, files created: 248711, delete 202047 (81.2% of them) freespace: was free: 59867136 bytes 57.1 MiB, wrote: 71897088 bytes 68.6 MiB, delta: 12029952 bytes 11.5 MiB, wrote 20.1% more than predicted freespace: trashing: was free: 82243584 bytes 78.4 MiB, need free: 22818816 bytes 21.8 MiB, files created: 248866, delete 179817 (72.3% of them) freespace: was free: 50905088 bytes 48.5 MiB, wrote: 63168512 bytes 60.2 MiB, delta: 12263424 bytes 11.7 MiB, wrote 24.1% more than predicted freespace: trashing: was free: 83402752 bytes 79.5 MiB, need free: 30425088 bytes 29.0 MiB, files created: 248920, delete 158114 (63.5% of them) freespace: was free: 42651648 bytes 40.7 MiB, wrote: 55406592 bytes 52.8 MiB, delta: 12754944 bytes 12.2 MiB, wrote 29.9% more than predicted freespace: trashing: was free: 84402176 bytes 80.5 MiB, need free: 38031360 bytes 36.3 MiB, files created: 248709, delete 136641 (54.9% of them) freespace: was free: 35233792 bytes 33.6 MiB, wrote: 48250880 bytes 46.0 MiB, delta: 13017088 bytes 12.4 MiB, wrote 36.9% more than predicted freespace: trashing: was free: 82530304 bytes 78.7 MiB, need free: 45637632 bytes 43.5 MiB, files created: 248778, delete 111208 (44.7% of them) freespace: was free: 27287552 bytes 26.0 MiB, wrote: 40267776 bytes 38.4 MiB, delta: 12980224 bytes 12.4 MiB, wrote 47.6% more than predicted freespace: trashing: was free: 85114880 bytes 81.2 MiB, need free: 53243904 bytes 50.8 MiB, files created: 248508, delete 93052 (37.4% of them) freespace: was free: 22437888 bytes 21.4 MiB, wrote: 35328000 bytes 33.7 MiB, delta: 12890112 bytes 12.3 MiB, wrote 57.4% more than predicted freespace: trashing: was free: 84103168 bytes 80.2 MiB, need free: 60850176 bytes 58.0 MiB, files created: 248637, delete 68743 (27.6% of them) freespace: was free: 15536128 bytes 14.8 MiB, wrote: 28319744 bytes 27.0 MiB, delta: 12783616 bytes 12.2 MiB, wrote 82.3% more than predicted freespace: trashing: was free: 84357120 bytes 80.4 MiB, need free: 68456448 bytes 65.3 MiB, files created: 248567, delete 46852 (18.8% of them) freespace: was free: 9015296 bytes 8.6 MiB, wrote: 22044672 bytes 21.0 MiB, delta: 13029376 bytes 12.4 MiB, wrote 144.5% more than predicted freespace: trashing: was free: 84942848 bytes 81.0 MiB, need free: 76062720 bytes 72.5 MiB, files created: 248636, delete 25993 (10.5% of them) freespace: was free: 6086656 bytes 5.8 MiB, wrote: 8331264 bytes 7.9 MiB, delta: 2244608 bytes 2.1 MiB, wrote 36.9% more than predicted freespace: Test 3 finished freespace: finished successfully Signed-off-by: Artem Bityutskiy commit 8aabb75017291ba68c09ff5fdb998ef0a1fdaaf9 Author: Artem Bityutskiy Date: Mon Aug 25 16:02:31 2008 +0300 UBIFS: remove incorrect index space check When we report free space to user-space, we should not report 0 if the amount of empty LEBs is too low, because they would be produced by GC when needed. Thus, just call 'ubifs_calc_available()' straight away which would take 'min_idx_lebs' into account anyway. Signed-off-by: Artem Bityutskiy commit 9e5de3549615818cae9c20a0ee1fd3ad4a747758 Author: Artem Bityutskiy Date: Mon Aug 25 17:29:43 2008 +0300 UBIFS: push empty flash hack down We have a hack which forces the amount of flash space to be equivalent to 'c->blocks_cnt' in case of empty FS. This is to make users happy and see '%0' used in 'df' when they mount an empty FS. This hack is not needed in 'ubifs_calc_available()', but it is only needed the caller, in 'ubifs_budg_get_free_space()'. So push it down there. Signed-off-by: Artem Bityutskiy commit 8191e1fa8131a422f4bf7b0f2dc1f8543fd17783 Author: Artem Bityutskiy Date: Fri Aug 22 12:26:40 2008 +0300 UBIFS: do not update min_idx_lebs in stafs This is bad because the rest of the code should not depend on it, and this may hide bugss, instead of revealing them. Signed-off-by: Artem Bityutskiy commit 9e3a5af7bba6573a215d74ea83c3909df9b4c701 Author: Pierre Ossman Date: Sun Aug 31 14:10:08 2008 +0200 mmc_block: hard code 512 byte block size We use 512 byte blocks on all cards, and newer cards support nothing else, so hard code it and make the code less complex. Signed-off-by: Pierre Ossman commit 53a68a7ffbb84f0f846e6718c06b6e0973ad358f Author: Pierre Ossman Date: Sat Aug 16 20:43:04 2008 +0200 sdhci: force high speed capability on some controllers Some high speed capable controllers forget to set the high speed capability bit. Make sure we enable the functionality anyway. Signed-off-by: Pierre Ossman commit 3c9d34395725db2e1b0209d6f90f035137bf70b8 Author: Pierre Ossman Date: Sat Aug 16 20:43:48 2008 +0200 mmc_block: filter out PC requests We do not support PC (SCSI) commands, so don't pretend we do by letting them through. Signed-off-by: Pierre Ossman commit 0f7e67758a45e505dae43244564b600d612cc3bd Author: Pierre Ossman Date: Sat Aug 16 21:15:50 2008 +0200 mmc_block: indicate strict ordering The MMC block driver services requests one at a time and in strict order. Indicate this to the block layer so that it can handle barriers in an efficient manner. Signed-off-by: Pierre Ossman commit b5e739ebf9ff47e90dacef500e095aaef0338784 Author: Pierre Ossman Date: Sat Aug 16 21:34:02 2008 +0200 mmc_block: inform block layer about sector count restriction Make sure we consider the maximum block count when we tell the block layer about the maximum sector count. That way we don't have to chop up the request ourselves. Signed-off-by: Pierre Ossman commit 818e8eacc5812eb3384955ebcd55fe80b6b367fe Author: Pierre Ossman Date: Sun Aug 31 13:42:00 2008 +0200 sdio: give sdio irq thread a host specific name There is one thread per host controller so make sure they all get unique names. Signed-off-by: Pierre Ossman commit e1259206cc9a7683ce2d4abc563440107a90d7bd Author: Pierre Ossman Date: Sun Aug 31 13:38:54 2008 +0200 sdio: make sleep on error interruptable Make sure we can be woken from the forced sleep that is done on errors. Removing a card often results in -ENOMEDIUM or -EILSEQ so we previously locked up the removal process for a second. We could completely exit on -ENOMEDIUM, but it might be a transient glitch so treat it like any other error. Signed-off-by: Pierre Ossman commit 8a62e55bce1749ff24cdf452b1c2c900bae04d84 Author: Pierre Ossman Date: Mon Aug 18 22:18:14 2008 +0200 sdhci: reduce card detection delay The card detection delay was added early when the behaviour of the card interrupt was still very much unknown (i.e. before there was a public specification). As it is now known that it is a debounced signal, reduce the delay to something more sensible. Signed-off-by: Pierre Ossman commit 00b84813bad78e7d405850e7eb9f99e9cc3fe792 Author: Pierre Ossman Date: Mon Aug 18 22:16:47 2008 +0200 sdio: wait for slow (buggy) cards The SD specification mandates that cards should start responding to commands within a few milliseconds. It seems many SDIO cards fail to properly respect this requirement. Adding a delay of 10 ms seems to get most of the offenders up and running though. Signed-off-by: Pierre Ossman commit 44e27223b9475824a9c31476cb197459f8927f10 Author: Pierre Ossman Date: Fri Aug 1 18:55:11 2008 +0200 sdio: add low level i/o functions for workarounds Some shoddy hardware doesn't properly adhere to the register model of SDIO, but treats the system like a series of transaction. That means that the drivers must have full control over what goes the bus (and the core cannot optimise transactions or work around problems in host controllers). This commit adds some low level functions that gives SDIO drivers the ability to send specific register access commands. They should only be used when the hardware is truly broken though. Signed-off-by: Pierre Ossman commit 1e7f5f31c9aca1e1dbf694a610829838cac1b1c4 Author: Pierre Ossman Date: Fri Jul 25 01:09:08 2008 +0200 sdhci: let the controller wait for busy state to end The sdhci controllers can interrupt us when the busy state from the card has ended, saving CPU cycles and power. Signed-off-by: Pierre Ossman commit 10d29ff9070caf5810d37ab06e30f7acad278f1e Author: David S. Miller Date: Sun Aug 31 01:40:12 2008 -0700 sparc64: Delete starfire_cpu_setup(). It does nothing. Signed-off-by: David S. Miller commit d7472c389ee1044d04af8a5b7c51aa7af96ed2db Author: David S. Miller Date: Sun Aug 31 01:33:52 2008 -0700 sparc64: Simplify error handling in PCI controller probing. Based upon suggestions from Stephen Rothwell. Signed-off-by: David S. Miller commit fd098316ef533e8441576f020ead4beab93154ce Author: David S. Miller Date: Sun Aug 31 01:23:17 2008 -0700 sparc: Annotate of_device_id arrays with const or __initdata. As suggested by Stephen Rothwell. Signed-off-by: David S. Miller commit c0fc0c541d41011dfd65ea2c74a0d62d23bd0cd4 Author: Avi Kivity Date: Sun Aug 31 11:12:31 2008 +0300 Restore IPI commits As mainline has this fixed, restore the commits in order to merge cleanly. Signed-off-by: Avi Kivity commit 933b2a1d8d458d6fe12b5efd63a0432852c44d6d Author: David S. Miller Date: Sat Aug 30 12:34:20 2008 -0700 sparc: Stop setting NO_DMA. This fixes the build with PCI disabled, we do want the generic DMA facilities and interfaces even when just SBUS is enabled. Based upon a build failure report by Robert Reif. Signed-off-by: David S. Miller commit 36881c2d34adc3608ad977983d1903eb777ba717 Author: Simon Arlott Date: Wed Aug 20 20:44:50 2008 -0300 V4L/DVB (8726): link tuner before saa7134 If saa7134_init is run before v4l2_i2c_drv_init (tuner), then saa7134_board_init2 will try to set the tuner type for devices that don't exist yet. This moves tuner to before all of the device-specific drivers so that it's loaded early enough on boot. Signed-off-by: Simon Arlott Signed-off-by: Andrew Morton Signed-off-by: Mauro Carvalho Chehab commit a5722eda11df96efd3017c07ab85ca4bf91038ee Author: Hans Verkuil Date: Fri Aug 29 17:31:35 2008 -0300 V4L/DVB (8852): v4l2: use register_chrdev_region instead of register_chrdev Replace the old register_chrdev with the more flexible register_chrdev_region. Ensure that the release() is called when the very last chardev usage was released, and not when the sysfs devices were removed. This should simplify hotpluggable drivers considerably. Tested-by: Mike Isely Tested-by: Laurent Pinchart Signed-off-by: Hans Verkuil Acked-by: David Ellingsworth Reviewed-by: Hans de Goede Signed-off-by: Mauro Carvalho Chehab commit 1d24e0326938965b84eaabd48536034252aeb179 Author: Hans Verkuil Date: Sat Aug 30 06:03:09 2008 -0300 V4L/DVB (8850): bt856: fix define conflict Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab commit 8df6c2b7ed1dc83022590d2e0c7ca64b238e97ec Author: Laurent Pinchart Date: Fri Aug 29 17:57:10 2008 -0300 V4L/DVB (8847): uvcvideo: Add support for a Bison Electronics webcam found in the Fujitsu Amilo SI2636. Signed-off-by: Laurent Pinchart Signed-off-by: Mauro Carvalho Chehab commit 4a99841c7220fa69d63384ebdf5d8f0532bb6f4a Author: Laurent Pinchart Date: Fri Aug 29 17:37:44 2008 -0300 V4L/DVB (8846): uvcvideo: Supress spurious "EOF in empty payload" trace message Pass the payload size instead of the header size to uvc_video_decode_end() to avoid generating an extra trace message for each frame. Signed-off-by: Laurent Pinchart Signed-off-by: Mauro Carvalho Chehab commit ce12adabd1e4c81bba8eda47a69fcbb3ba8816c8 Author: Dean Anderson Date: Fri Aug 29 15:33:19 2008 -0300 V4L/DVB (8845): s2255drv: adds JPEG compression quality control adds VIDIOC_S_JPEGCOMP and VIDIOC_G_JPEGCOMP ioctls for controlling JPEG compression quality. Signed-off-by: Dean Anderson Signed-off-by: Mauro Carvalho Chehab commit 9cfb33340012477474218c72c19537448f936e81 Author: Adrian Bunk Date: Wed Aug 27 19:04:30 2008 -0300 V4L/DVB (8844): dabusb_fpga_download(): fix a memory leak This patch fixes a memory leak in an error path. Reported-by: Adrian Bunk Signed-off-by: Adrian Bunk Signed-off-by: Mauro Carvalho Chehab commit ec74834537dba0ce138c87b0c2c83717a8c14647 Author: Adrian Bunk Date: Wed Aug 27 19:03:24 2008 -0300 V4L/DVB (8843): tda10048_firmware_upload(): fix a memory leak This patch fixes a memory leak ("fw" wasn't freed). Reported-by: Adrian Bunk Signed-off-by: Adrian Bunk Signed-off-by: Mauro Carvalho Chehab commit a6f89be79781c35f761fd5a368e6601c97e781a7 Author: Adrian Bunk Date: Wed Aug 27 19:01:57 2008 -0300 V4L/DVB (8842): vivi_release(): fix use-after-free video_device_release() does kfree(), which made the following printk() doing a use-after-free. printk() first and release then. Reported-by: Adrian Bunk Signed-off-by: Adrian Bunk Signed-off-by: Mauro Carvalho Chehab commit 70b9d6117a8508443e2aac551c8774f57fc46509 Author: Michael Krufky Date: Thu Aug 28 13:14:27 2008 -0300 V4L/DVB (8840): dib0700: add basic support for Hauppauge Nova-TD-500 (84xxx) This adds basic support for the Hauppauge Nova-TD-500 84xxx series. A future patch will allow for one aerial input to supply both tuners. With the current code, an aerial must be plugged into each antannae input in order for both tuners to function. Signed-off-by: Michael Krufky Signed-off-by: Mauro Carvalho Chehab commit 383ca28ba01dd9e5802f36b9f34a2d9e8ccea81d Author: Michael Krufky Date: Thu Aug 28 13:06:26 2008 -0300 V4L/DVB (8839): dib0700: add comment to identify 35th USB id pair This comment helps to make the code more readable. Signed-off-by: Michael Krufky Signed-off-by: Mauro Carvalho Chehab commit 79323bedf7f28c4f1c991b07e1940f1cac28ab55 Author: David Howells Date: Wed Aug 27 10:46:39 2008 -0300 V4L/DVB (8838): CRED: Wrap task credential accesses in video input drivers Wrap access to task credentials so that they can be separated more easily from the task_struct during the introduction of COW creds. Change most current->(|e|s|fs)[ug]id to current_(|e|s|fs)[ug]id(). Change some task->e?[ug]id to task_e?[ug]id(). In some places it makes more sense to use RCU directly rather than a convenient wrapper; these will be addressed by later patches. Signed-off-by: David Howells Reviewed-by: James Morris Acked-by: Serge Hallyn Signed-off-by: Mauro Carvalho Chehab commit 38aa3468b618e7425759256786e9d2aff32cdf13 Author: Jean Delvare Date: Fri Aug 29 19:25:01 2008 -0300 V4L/DVB (8837): dvb: fix I2C adapters name size Some DVB drivers are incorrectly assuming that the size of i2c_adapter.name is I2C_NAME_SIZE. Here's a fix. Also change strncpy to strlcpy, as the former is error-prone (and was indeed incorrectly used.) Signed-off-by: Jean Delvare Acked-by: Uwe Bugla Reviewed-by: Michael Krufky Signed-off-by: Steven Toth Signed-off-by: Andrew Morton Signed-off-by: Mauro Carvalho Chehab commit 058363efabdbab48e14f646c857fe2c2a669ab50 Author: Hans de Goede Date: Fri Aug 29 14:09:52 2008 -0300 V4L/DVB (8835): gspca: Same pixfmt as the sn9c102 driver and raw Bayer added in sonixb. 1) Lower the hstart setting for all sensor by 1 so that we generate (compressed) BGGR data just like sn9c102 does (instead of GBRG data) 2) Add support for raw bayer output in the lowest resolutions (not enough bandwidth for higher resolutions), this should work with all sensors but to be sure only enable it for sensors where it has been tested. Signed-off-by: Hans de Goede Signed-off-by: Jean-Francois Moine Signed-off-by: Mauro Carvalho Chehab commit 436f8feea0ed1fa09510b463ea6ac593d4cd77a5 Author: Hans de Goede Date: Fri Aug 29 04:41:23 2008 -0300 V4L/DVB (8834): gspca: Have a bigger buffer for sn9c10x compressed images. Under certain conditions sonixb compressed frame size can get bigger then the uncompressed size (seen with 0c45:6028), so make the buffers slightly bigger. Signed-off-by: Hans de Goede Signed-off-by: Jean-Francois Moine Signed-off-by: Mauro Carvalho Chehab commit c84da5a936e13ed75096c7953c5f7f247e0db41b Author: Hans de Goede Date: Fri Aug 29 04:35:27 2008 -0300 V4L/DVB (8833): gspca: Cleanup the sonixb code. -the usb-id table caried several flags which were not usb-id specific but sensor specific, add a sensor_data array and move these flag there -fr_h_sz was being abused to store and check which bridge was being used instead add a bridge member to the sd struct -now that we have a sensor_data table use that to store pointers to init_sequences instead of using switch cases on sd->sensor Signed-off-by: Hans de Goede Signed-off-by: Jean-Francois Moine Signed-off-by: Mauro Carvalho Chehab commit ef955c0a976a93ce8632d1cd08583efc6119d2a4 Author: Jean-Francois Moine Date: Thu Aug 28 13:22:19 2008 -0300 V4L/DVB (8832): gspca: Bad pixelformat of vc0321 webcams. Signed-off-by: Jean-Francois Moine Signed-off-by: Mauro Carvalho Chehab commit 3369ad6fe56c60ea93f7fcbd7cf4a3d8954bb478 Author: Hans de Goede Date: Thu Aug 28 07:31:54 2008 -0300 V4L/DVB (8831): gspca: Resolve webcam conflicts between some drivers. -remove USB-id's from zc0301 for cams for which zc0301.c does not support the sensor -remove USB-id's from sn9c102 for cams where sn9c102 does not support the bridge sensor combination -no longer make inclusion of usb id's removed from zc0301 and sn9c102 conditional in gspca -fix conditional inclusion of USB-id's in gspca to also work when the conflicting drivers are build as a module -add a number of USB-id's to gspca from various windows .inf files: 0c45:608f from generic sonix sn9c103 inf file (+ ov7630 which we support) 041e:4022 from creative webcam nx pro, same as already supported 041e:401e 0ac8:0301 from generic zc0301 driver which supports many sensors 10fd:804d from typhoon webshot driver (also FlyCAM-USB 300 plus) Signed-off-by: Hans de Goede Signed-off-by: Jean-Francois Moine Signed-off-by: Mauro Carvalho Chehab commit 29c65e0190d7a30dc48f3d9cbdc2231ce83a33d2 Author: Hans de Goede Date: Wed Aug 27 07:17:27 2008 -0300 V4L/DVB (8830): gspca: Move some probe code to the new init function. Signed-off-by: Hans de Goede Signed-off-by: Jean-Francois Moine Signed-off-by: Mauro Carvalho Chehab commit 8f503f395356424c79e9fcc984176fb061b9cdf6 Author: Jean-Francois Moine Date: Wed Aug 27 03:31:22 2008 -0300 V4L/DVB (8829): gspca: Have a clean kmalloc-ated buffer for USB exchanges. The USB buffer may be used for DMA and there may be a caching problem if the buffer is part of the device structure. Thanks to Alan Stern. Signed-off-by: Jean-Francois Moine Signed-off-by: Mauro Carvalho Chehab commit c530695ab5bb474ad047d7c65f4bfd7306bb5810 Author: Jean-Francois Moine Date: Tue Aug 26 14:45:11 2008 -0300 V4L/DVB (8828): gspca: Set the clock at the end of initialization in sonixj. Signed-off-by: Jean-Francois Moine Signed-off-by: Mauro Carvalho Chehab commit b220095abd4bff68776c7ff10c0e8901ca4d0fcf Author: Hans de Goede Date: Tue Aug 26 13:51:51 2008 -0300 V4L/DVB (8827): gspca: Stop pac7302 autogain oscillation. Signed-off-by: Hans de Goede Signed-off-by: Jean-Francois Moine Signed-off-by: Mauro Carvalho Chehab commit da85cfa999d4df83f3a94143d47cffc6d6d27977 Author: Jean-Francois Moine Date: Tue Aug 26 13:47:24 2008 -0300 V4L/DVB (8826): gspca: Webcam Labtec 2200 (093a:2626) added in pac7311. Signed-off-by: Jean-Francois Moine Signed-off-by: Mauro Carvalho Chehab commit 1fb51b014d935e05c20025dbbdd768a15af53102 Author: Hans de Goede Date: Tue Aug 26 13:39:10 2008 -0300 V4L/DVB (8825): gspca: More controls for pac73xx and new webcam 093a:2624. -Add usb id for 093a:2624 (pac7302) -Report some controls to userspace with 7302 only, as they are 7302 only -Add gain and exposure controls -Add autogain -Fix 7302 imaged being mirrored by default Signed-off-by: Hans de Goede Signed-off-by: Jean-Francois Moine Signed-off-by: Mauro Carvalho Chehab commit cf88c8c78251887a532846a71af323e3a8a80d46 Author: Jean-Francois Moine Date: Tue Aug 26 12:19:01 2008 -0300 V4L/DVB (8824): gspca: Too much code removed in the suspend/resume changeset. - the stream must stop when the main application closes the device. Signed-off-by: Jean-Francois Moine Signed-off-by: Mauro Carvalho Chehab commit 81de1a881c8ed7a6597ee681fd1caab9accfb8ef Author: Jean-Francois Moine Date: Tue Aug 26 03:17:16 2008 -0300 V4L/DVB (8823): gspca: H and V flips work for ov7670 only in ov519. Signed-off-by: Jean-Francois Moine Signed-off-by: Mauro Carvalho Chehab commit eb957ec04b73dc327615f719c4ea54a1e300aa20 Author: Jean-Francois Moine Date: Tue Aug 26 03:03:51 2008 -0300 V4L/DVB (8822): gspca: Change some subdriver functions for suspend/resume. - new function 'init' called on probe and resume - remove the functions 'open' and 'closed' - 'stopN' and 'stop0' are optional Signed-off-by: Jean-Francois Moine Signed-off-by: Mauro Carvalho Chehab commit 2ab2e44fe0f92280c2bcdef8edd59b8281c3c856 Author: Jean-Francois Moine Date: Sun Aug 24 11:25:27 2008 -0300 V4L/DVB (8820): gspca: Change initialization and gamma of zc3xx - pas106. Signed-off-by: Jean-Francois Moine Signed-off-by: Mauro Carvalho Chehab commit ec0c56a33efc46cf236a60a4eb7305dd5452fa96 Author: Jean-Francois Moine Date: Sun Aug 24 10:25:35 2008 -0300 V4L/DVB (8819): gspca: Initialize the ov519 at open time and source cleanup. Signed-off-by: Jean-Francois Moine Signed-off-by: Mauro Carvalho Chehab commit d7f8bc97f7b432e98633d06373f1598754f31abb Author: Jean-Francois Moine Date: Sun Aug 24 07:54:29 2008 -0300 V4L/DVB (8818): gspca: Reinitialize the device on resume. Signed-off-by: Jean-Francois Moine Signed-off-by: Mauro Carvalho Chehab commit b531ef658417ffd068b1f05951ae5246bde4d981 Author: Hans de Goede Date: Sun Aug 24 07:02:57 2008 -0300 V4L/DVB (8817): gspca: LED and proble changes in sonixb. - turn the led of the cam off after plugging in the cam - move the probe code from open to config, so that if the probe fails we never register Signed-off-by: Hans de Goede Signed-off-by: Jean-Francois Moine Signed-off-by: Mauro Carvalho Chehab commit 137d081188aeb479c75972a318f99122e16e0ff1 Author: Hans de Goede Date: Sun Aug 24 06:59:56 2008 -0300 V4L/DVB (8816): gspca: Set disabled ctrls and fix a register pb with ovxxxx in sonixb. - set some controls as disabled instead of copying the device descr. - in the ov6650 / 7650 exposure code clamp reg 11 before (instead of after) using it to calculate reg 10. - disable brightness (instead of ignoring it) for the TAS5110. Signed-off-by: Hans de Goede Signed-off-by: Jean-Francois Moine Signed-off-by: Mauro Carvalho Chehab commit 98deb14a6394c0c81143f049e6e468004088c591 Author: Hans de Goede Date: Sun Aug 24 06:53:25 2008 -0300 V4L/DVB (8815): gspca: Fix problems with disabled controls. Signed-off-by: Hans de Goede Signed-off-by: Jean-Francois Moine Signed-off-by: Mauro Carvalho Chehab commit 3e75cbf6b818a0bbac1996d5c754ddfa30b2b8e9 Author: Jean-Francois Moine Date: Sat Aug 23 07:56:49 2008 -0300 V4L/DVB (8814): gspca: Set DISABLED the disabled controls at query control time. Signed-off-by: Jean-Francois Moine Signed-off-by: Mauro Carvalho Chehab commit a21465fec6e0319a6ffb19d57366a1bacf5a5192 Author: Hans de Goede Date: Sat Aug 23 03:56:31 2008 -0300 V4L/DVB (8813): gspca: Adjust SOF detection for pac73xx. Signed-off-by: Hans de Goede Signed-off-by: Jean-Francois Moine Signed-off-by: Mauro Carvalho Chehab commit 61237c7fa1c3cee2b043ae337b1a2e99c8ebb4d2 Author: Hans de Goede Date: Sat Aug 23 03:52:14 2008 -0300 V4L/DVB (8812): gspca: Do pac73xx webcams work. - documentation for some registers - some preparations for adding autogain_n_exposure functionality - various pac7311 fixes - disable brightness and colors controls for 7311 - fix contrast control for 7311 - add hflip and vflip controls for 7311 - minimal jpeg header - proper SOF detection Signed-off-by: Hans de Goede Signed-off-by: Jean-Francois Moine Signed-off-by: Mauro Carvalho Chehab commit 4a0ed5f63350bd979114cccd65a4cc0827830f45 Author: Jean-Francois Moine Date: Fri Aug 22 14:27:49 2008 -0300 V4L/DVB (8810): gspca: Compile error when CONFIG_PM not defined. Signed-off-by: Jean-Francois Moine Signed-off-by: Mauro Carvalho Chehab commit 758c0ffc5010f559bcaa640f1349d4053c5b3005 Author: Hans de Goede Date: Fri Aug 22 14:22:54 2008 -0300 V4L/DVB (8809): gspca: Revert commit 9a9335776548d01525141c6e8f0c12e86bbde982 the previous patch (sensor upside down). Signed-off-by: Hans de Goede Signed-off-by: Jean-Francois Moine Signed-off-by: Mauro Carvalho Chehab commit 52235245417b9e3f9e630782e3978f333dee02dc Author: Steven Toth Date: Tue Aug 12 13:30:03 2008 -0300 V4L/DVB (8807): Add DVB support for the Leadtek Winfast PxDVR3200 H This patch is on behalf of Stephen Backway , and represents two patches I received (and some subsequent whitespace cleanup I had due to how I pulled the patches). From the original author: a) Add DVB support for the Leadtek Winfast PxDVR3200 H. b) The tuner callback previously checked the command 3 times: 1) To see if it was the XC2028_RESET_CLK 2) To see if it was not the XC2028_RESET_TUNER 3) To see if it was the XC2028_RESET_TUNER This patch removes the third check. Signed-off-by: Steven Toth Signed-off-by: Stephen Backway Signed-off-by: Mauro Carvalho Chehab commit 1024b0001e48d4b73db9a3e3db2ab3bb3eec090d Author: Steven Toth Date: Thu Aug 28 11:53:08 2008 -0300 V4L/DVB (8805): Steven Toth email address change I need this so I can better isolate my linux email from my corporate email. Signed-off-by: Steven Toth Signed-off-by: Mauro Carvalho Chehab commit f7f206c1da4b80f0cd8cadab2704f39d4d3bd979 Author: Steven Toth Date: Thu Aug 28 11:13:58 2008 -0300 V4L/DVB (8804): s5h1411: Enable QAM_AUTO mode If apps pass QAM_AUTO then we need to obey it. Signed-off-by: Steven Toth Signed-off-by: Mauro Carvalho Chehab commit d5394f70e1e7ef6cae6341f9b7060441f924948f Author: Steven Toth Date: Thu Aug 28 11:12:26 2008 -0300 V4L/DVB (8803): s5h1409: Enable QAM_AUTO mode If apps pass QAM_AUTO then we need to obey it. Signed-off-by: Steven Toth Signed-off-by: Mauro Carvalho Chehab commit a1521f8e9f1255e9a43652d9d7ba10cdad14c409 Author: Geert Uytterhoeven Date: Wed Aug 27 17:20:15 2008 -0300 V4L/DVB (8801): [PATCH] VIDEO_SH_MOBILE_CEU should depend on HAS_DMA Hi Andrew, On Thu, 14 Aug 2008, Andrew Morton wrote: > ERROR: "dma_alloc_coherent" [drivers/media/video/videobuf-dma-contig.ko] undefined! > ERROR: "dma_sync_single_for_cpu" [drivers/media/video/videobuf-dma-contig.ko] undefined! > ERROR: "dma_free_coherent" [drivers/media/video/videobuf-dma-contig.ko] undefined! M68k allmodconfig still selects Sun-3, which sets NO_DMA. I guess you're also seeing this on the other NO_DMA platforms (h8300, m32r, s390, and PCI-less SPARC)? Below is a patch. Shouldn't it also (or instead) depend on SUPERH or some SuperH platform? Or is this not done to have more compile-coverage? commit 0d3244d6439c8c31d2a29efd587c7aca9042c8aa ("V4L/DVB (8342): sh_mobile_ceu_camera: Add SuperH Mobile CEU driver V3") introduced VIDEO_SH_MOBILE_CEU, which selects VIDEOBUF_DMA_CONTIG. This circumvents the dependency on HAS_DMA of VIDEOBUF_DMA_CONTIG. Add a dependency on HAS_DMA to VIDEO_SH_MOBILE_CEU to fix this. Signed-off-by: Geert Uytterhoeven Acked-by: Paul Mundt Acked-by: Magnus Damm Signed-off-by: Guennadi Liakhovetski Signed-off-by: Mauro Carvalho Chehab commit 025ba97c7660fd4e4a8af5be5cfc232db8c6e7eb Author: Harvey Harrison Date: Wed Aug 27 17:20:01 2008 -0300 V4L/DVB (8800): [v4l-dvb-maintainer] [PATCH] v4l: mt9m111.c make function static drivers/media/video/mt9m111.c:758:5: warning: symbol 'mt9m111_restore_state' was not declared. Should it be static? New warning in next-20080825 Signed-off-by: Harvey Harrison Signed-off-by: Guennadi Liakhovetski Signed-off-by: Mauro Carvalho Chehab commit d9777f75eaf05dd040c0e173020f95e0ac3f15f4 Author: Guennadi Liakhovetski Date: Fri Aug 29 15:16:31 2008 -0300 V4L/DVB (8799): soc-camera: add API documentation Signed-off-by: Guennadi Liakhovetski Acked-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab commit 52758760ba6fcf849ccc72dd8b73bca5a6d20ad6 Author: Dmitry Belimov Date: Tue Aug 26 14:16:33 2008 -0300 V4L/DVB (8797): A simple state machine was added to saa7134_ts. A simple state machine was added to saa7134_ts. It has three states: SAA7134_TS_STOPPED SAA7134_TS_BUFF_DONE SAA7134_TS_STARTED When buffer_setup is run we start the TS initialization: set SAA7134_TS_STOPPED. When all buffers are prepared we write data into DMA register and set SAA7134_TS_BUFF_DONE. When the first buffer is active start TS and set SAA7134_TS_STARTED. When ts_release is called stop TS and set SAA7134_TS_STOPPED. Signed-off-by: Beholder Intl. Ltd. Dmitry Belimov Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab commit 669d0da47216a9a4b21541d34a0b1b4a4c16c208 Author: Dmitry Belimov Date: Tue Aug 26 13:47:10 2008 -0300 V4L/DVB (8796): saa7134-empress: remove incorrect IRQ defines for TS SAA7134_IRQ1_INTE_RA2_3 and SAA7134_IRQ1_INTE_RA2_2 are used for planar video, not for TS. Signed-off-by: Beholder Intl. Ltd. Dmitry Belimov Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab commit bb383c74527c03563efe9c7f2d5a731125e832a0 Author: Dmitry Belimov Date: Tue Aug 26 13:44:40 2008 -0300 V4L/DVB (8795): saa7134-empress: insert leading null bytes for Beholder M6 empress cards Additional code to improve the init sequence and add board type tests were done by Hans Verkuil. Signed-off-by: Beholder Intl. Ltd. Dmitry Belimov Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab commit ad4a11e06480b1a18ad4e4fd216fa116f454b3aa Author: Bjorn Helgaas Date: Mon Aug 25 18:45:09 2008 -0300 V4L/DVB: follow lspci device/vendor style Use "[%04x:%04x]" for PCI vendor/device IDs to follow the format used by lspci(8). Signed-off-by: Bjorn Helgaas Signed-off-by: Mauro Carvalho Chehab commit b4b510f930b133cb24ac8fc8abf19bdba836b58d Author: Hans Verkuil Date: Sun Aug 24 11:18:47 2008 -0300 V4L/DVB (8791): v4l2-dev: do not clear the driver_data field The driver_data field of the device structure was zeroed, thus losing this information. Many drivers set this up before calling video_device_register, so we have to ensure that it isn't lost. Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab commit 854d2dc43514e86c447dfa788de069ec3e6aa5b8 Author: Hans Verkuil Date: Sun Aug 24 08:34:15 2008 -0300 V4L/DVB (8790): saa7115: call i2c_set_clientdata only when state != NULL Not a bug as such, but it looks really strange doing this before checking whether the state structure could be allocated. Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab commit 7f952aaf77d5686cdaa5ba861c8cf2cdafd73216 Author: Hans Verkuil Date: Sun Aug 24 06:29:30 2008 -0300 V4L/DVB (8789): wm8739: remove wrong kfree i2c_client is allocated for us, we should never free it ourselves. Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab commit a38a4c2b09cdd166c30b113b4df59cc78adbc01b Author: Hans Verkuil Date: Sat Aug 23 08:32:09 2008 -0300 V4L/DVB (8788): v4l: replace video_get_drvdata(video_devdata(filp)) with video_drvdata(filp) Use the new video_drvdata(filp) function where it is safe to do so. Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab commit 67c25c695fb901b0ebb156d4fc069952e1644104 Author: Hans Verkuil Date: Sat Aug 23 07:48:38 2008 -0300 V4L/DVB (8787): v4l2-dev: cleanups and add video_drvdata helper function Cleanup v4l2-dev.[ch], add/improve comments and add a new helper function: video_drvdata() that can get the private driver data from a file struct. Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab commit 97d4965221f107c95e61646c08323ce36c09004e Author: Hans Verkuil Date: Sat Aug 23 07:24:07 2008 -0300 V4L/DVB (8786): v4l2: remove the priv field, use dev_get_drvdata instead Remove the priv field and let video_get/set_drvdata use dev_get_drvdata and dev_set_drvdata instead. Convert all drivers that still used priv directly. Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab commit 3864326e952dc2ad954df6000c43f0c6e553a80e Author: Hans Verkuil Date: Sat Aug 23 06:38:11 2008 -0300 V4L/DVB (8785): v4l2: add __must_check to v4l2_dev.h Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab commit e00851f76aae6cdcdc0a9a5d0a18d902c0efde8e Author: Hans Verkuil Date: Sat Aug 23 06:27:59 2008 -0300 V4L/DVB (8784): v4l2-dev: make the video_device's release callback mandatory Now that all drivers set the release callback in the video_device struct we can put in a BUG_ON in video_register_device to ensure that the callback is always there. Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab commit b8856ff01e1659f3dd6d48ae99fa256cda14dc85 Author: Hans Verkuil Date: Sat Aug 23 06:23:55 2008 -0300 V4L/DVB (8783): v4l: add all missing video_device release callbacks All drivers that call video_device_register where checked to see if they set the release callback of struct video_device. Where that callback was missing it was added. Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab commit 082833638ac62d72275f51eb514a1dd906c619dd Author: Hans Verkuil Date: Sat Aug 23 05:47:41 2008 -0300 V4L/DVB (8782): v4l2-dev: add video_device_release_empty Add a second release function: video_device_release_empty It can be used by drivers that have statically allocated video_device structs. Its use usually, but not always, indicates laziness on the part of the driver programmer. Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab commit 48179b663fb389878f3eb600ef1870af354aef97 Author: Hans Verkuil Date: Sat Aug 23 05:34:55 2008 -0300 V4L/DVB (8781): v4l2-dev: remove obsolete video_exclusive_open/release Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab commit 799fc9d17caa3ab69d02d2d190c5e47a4e6bd940 Author: Hans Verkuil Date: Sat Aug 23 05:31:47 2008 -0300 V4L/DVB (8780): v4l: replace the last uses of video_exclusive_open/release Handle the video_exclusive_open/release functionality inside the driver. Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab commit 8540abe748d1bfaaac5bc4a42088b2d132ed5015 Author: Hans Verkuil Date: Sat Aug 23 05:02:07 2008 -0300 V4L/DVB (8779): v4l: fix more incorrect video_register_device result checks Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab commit 63057954eb49549963c4c5079381492575cab33a Author: Hans Verkuil Date: Sat Aug 23 04:56:25 2008 -0300 V4L/DVB (8778): radio: fix incorrect video_register_device result check Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab commit 0a2e13184e8f289a00b4bd92dd7511e06113f311 Author: Hans Verkuil Date: Sat Aug 23 04:52:00 2008 -0300 V4L/DVB (8777): tea575x-tuner: replace video_exclusive_open/release Move the video_exclusive_open/release functionality into the driver itself. Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab commit d65285b768d22c2e840e67a3b84ffc72817d9941 Author: Hans Verkuil Date: Sat Aug 23 04:49:13 2008 -0300 V4L/DVB (8776): radio: replace video_exclusive_open/release Move the video_exclusive_open/release functionality into the driver itself. Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab commit 4793655ba602835728c420caeb3c7062c8d756f8 Author: Andy Walls Date: Sat Aug 23 18:36:50 2008 -0300 V4L/DVB (8774): cx18: Have CX23418 release buffers at end of capture. cx18: Have CX23418 release buffers at end of capture. The CX23418 reuses task handles so we need to have it release the buffers associated with a task handle at the end of a capture. If we don't, buffer ids used for one type of stream in the driver (MPEG, TS, PCM), could be used for another type of stream by the CX23418, if a previously used handle is assigned to a different type of stream. The driver would drop valid buffers when this happened. Signed-off-by: Andy Walls Signed-off-by: Mauro Carvalho Chehab commit a59b412214b67872c0b3efed11aafaff4d54caa2 Author: Andy Walls Date: Sat Aug 23 16:42:29 2008 -0300 V4L/DVB (8773): cx18: Fix cx18_find_handle() and add error checking cx18: Fix cx18_find_handle() and add error checking. cx18_find_handle() did not find a good task handle and would use the invalid task handle under common conditions. Added a define for the invalid task handle and added error checking as well. Signed-off-by: Andy Walls Signed-off-by: Mauro Carvalho Chehab commit 884ceebcb8d249ebb96beebe12410f8b993c6547 Author: Andy Walls Date: Fri Aug 22 21:03:11 2008 -0300 V4L/DVB (8772): cx18: Convert cx18_queue buffers member to atomic_t cx18: Convert cx18_queue buffers member to atomic_t. This allows safe concurrent access to check if a queue has data without having to acquire the queue spinlock. Signed-off-by: Andy Walls Signed-off-by: Mauro Carvalho Chehab commit d6a9f42a1918d529020734f4589250c267f73820 Author: Andy Walls Date: Fri Aug 22 20:55:54 2008 -0300 V4L/DVB (8771): cx18: Remove redundant struct cx18_queue length member. cx18: Remove redundant struct cx18_queue length member. It can be trivially computed from queue->buffers * stream->buf_size, if ever really needed. Signed-off-by: Andy Walls Signed-off-by: Mauro Carvalho Chehab commit 6c6ec41e067558592bbe3f9664fac066f72efeb6 Author: Andy Walls Date: Fri Aug 22 20:46:43 2008 -0300 V4L/DVB (8770): cx18: get rid of ununsed buffers stolen field cx18: get rid of ununsed buffers stolen field. It's an unused holdover from ivtv. Signed-off-by: Andy Walls Signed-off-by: Mauro Carvalho Chehab commit f6de8b80aa0d0db21c2484c36b16021f76bb7130 Author: Hans Verkuil Date: Fri Aug 22 20:22:22 2008 -0300 V4L/DVB (8757): v4l-dvb: fix a bunch of sparse warnings Fixed a lot of sparse warnings: mostly warnings about shadowed variables and signed/unsigned mismatches. Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab commit d10d08f6c9649702c509f315cd4a4f208297ba0e Author: Laurent Pinchart Date: Fri Aug 22 17:25:10 2008 -0300 V4L/DVB (8754): uvcvideo: Implement the USB power management reset_resume method. When a suspended device has been reset instead of being resumed, USB core calls the reset_resume method if available instead of unbinding and rebinding the device. This patch implements reset_resume by reusing the current resume implementation and simplifies the resume method by skipping the controls restore stage. Resuming from autosuspend should be faster. Signed-off-by: Laurent Pinchart Signed-off-by: Mauro Carvalho Chehab commit 86504a862a125d944bf981499c46c66e1a7de9c1 Author: Dean Anderson Date: Mon Aug 25 13:58:55 2008 -0300 V4L/DVB (8752): s2255drv: firmware improvement patch Fix for reloading firmware when removing and reloading driver Handshaking for firmware loading and changing modes. Removes the restriction of one user per channel at a time. JPEG capture mode added. Signed-off-by: Dean Anderson Signed-off-by: Mauro Carvalho Chehab commit cab2d0de0fdba665da33729feea44c920d6af575 Author: Henrik Kretzschmar Date: Fri Aug 22 17:13:05 2008 -0300 V4L/DVB (8748): V4L: fix return value of meye probe callback The return value of the probe function should return -ENOMEM instead of -EBUSY if video_device_alloc() fails. Signed-off-by: Henrik Kretzschmar Signed-off-by: Mauro Carvalho Chehab commit 60a9504275a595ec5181bc7f55a55dad1f800b27 Author: Hans Verkuil Date: Fri Aug 22 17:12:08 2008 -0300 V4L/DVB (8746): v4l-dvb: fix compile warnings. Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab commit fd84d056cb8f8b8471c7f535867d24e9d17c162a Author: Hans Verkuil Date: Fri Aug 22 17:01:45 2008 -0300 V4L/DVB (8745): v4l2: fix a bunch of compile warnings. Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab commit ec8f11760fe4bad71659875a40a311afe22d939a Author: Harvey Harrison Date: Mon Aug 18 17:38:01 2008 -0300 V4L/DVB (8742): pvrusb2: use proper byteorder interface ___swab32 is an internal detail of the implementation. Acked-by: Mike Isely Signed-off-by: Harvey Harrison Signed-off-by: Mauro Carvalho Chehab commit a06647438dd3fff3471d72cc0f031b00c289bbdb Author: Antoine Jacquet Date: Mon Aug 18 18:38:51 2008 -0300 V4L/DVB (8739): dtv5100: remove prohibited space... Signed-off-by: Antoine Jacquet Signed-off-by: Mauro Carvalho Chehab commit ba4be05ce755dbde7234193fc302ca6465d96cfa Author: Antoine Jacquet Date: Mon Aug 18 18:22:00 2008 -0300 V4L/DVB (8738): dtv5100: remove old definition from header Signed-off-by: Antoine Jacquet Signed-off-by: Mauro Carvalho Chehab commit 067e664b7e607dbddf6d654bbc2ff341f13c9b15 Author: Antoine Jacquet Date: Tue Aug 12 16:56:34 2008 -0300 V4L/DVB (8736): dtv5100: CodingStyle cleanups Signed-off-by: Antoine Jacquet Signed-off-by: Mauro Carvalho Chehab commit 022d3d3b6a67543866a54da7bd70a873b29847a0 Author: Antoine Jacquet Date: Mon Aug 11 19:21:33 2008 -0300 V4L/DVB (8735): dtv5100: replace dummy frontend by zl10353 Remove the dtv5100-fe.c dummy frontend and replace it by the real frontend for the chipset. Signed-off-by: Antoine Jacquet Signed-off-by: Mauro Carvalho Chehab commit c66b8c14463bba309db31cfcaf19546473e39884 Author: Antoine Jacquet Date: Mon Aug 11 13:12:19 2008 -0300 V4L/DVB (8734): Initial support for AME DTV-5100 USB2.0 DVB-T Basic support for AME DTV-5100 USB2.0 DVB-T using the qt1010 tuner and a dummy frontend. Signed-off-by: Antoine Jacquet Signed-off-by: Mauro Carvalho Chehab commit 369edc2d315929f6dc5c28cc77f7aa117408134a Author: Antoine Jacquet Date: Mon Aug 18 17:14:30 2008 -0300 V4L/DVB (8732): zr364xx: handle video exclusive open internaly Count the users and do not use video_exclusive_open() anymore. Signed-off-by: Antoine Jacquet Signed-off-by: Mauro Carvalho Chehab commit 1527ad8b9b0ecacb5d06c309e26a688359ef2919 Author: Antoine Jacquet Date: Mon Aug 18 17:09:53 2008 -0300 V4L/DVB (8731): zr364xx: remove BKL Remove the Big Kernel Lock from zr364xx driver after pushdown. Now using an internal locking mecanism on open(). Signed-off-by: Antoine Jacquet Signed-off-by: Mauro Carvalho Chehab commit c9439ce87dbe19d0884f89660db51f0555a3db4f Author: Mauro Carvalho Chehab Date: Fri Aug 22 13:31:59 2008 -0300 V4L/DVB (8730): drx397xD: fix compilation error caused by changeset 71046dfb0853 Signed-off-by: Mauro Carvalho Chehab commit edf449fd6b1ebf41ee10c39bb12cc950589dfa78 Author: Julia Lawall Date: Wed Aug 20 20:44:53 2008 -0300 V4L/DVB (8729): Use DIV_ROUND_UP The kernel.h macro DIV_ROUND_UP performs the computation (((n) + (d) - 1) / (d)) but is perhaps more readable. An extract of the semantic patch that makes this change is as follows: (http://www.emn.fr/x-info/coccinelle/) // @haskernel@ @@ @depends on haskernel@ expression n,d; @@ ( - (n + d - 1) / d + DIV_ROUND_UP(n,d) | - (n + (d - 1)) / d + DIV_ROUND_UP(n,d) ) @depends on haskernel@ expression n,d; @@ - DIV_ROUND_UP((n),d) + DIV_ROUND_UP(n,d) @depends on haskernel@ expression n,d; @@ - DIV_ROUND_UP(n,(d)) + DIV_ROUND_UP(n,d) // Signed-off-by: Julia Lawall Signed-off-by: Andrew Morton Signed-off-by: Mauro Carvalho Chehab commit a351839c509f412554396696ee2203b6ea43dba2 Author: Harvey Harrison Date: Wed Aug 20 20:44:50 2008 -0300 V4L/DVB (8725): drx397xD.c sparse annotations Signed-off-by: Harvey Harrison Signed-off-by: Andrew Morton Signed-off-by: Mauro Carvalho Chehab commit 707194f4b7574a8fd49ee347ce0071ec0e90f1e2 Author: Felipe Balbi Date: Tue Aug 19 20:40:30 2008 -0300 V4L/DVB (8724): dvb: drx397xD: checkpatch.pl cleanups This driver sure needs some rework. For now, let's try to clean it up a bit before start reimplementing anything. checkpatch.pl still not happy with this driver after this patch, but the most annoying errors are gone, comments now use C-style only, labels are well placed and some other minor fixes. Some more clean up patches will come as I work on this driver. Please review it carefully. Cc: Mauro Carvalho Chehab Cc: Henk Vergonet [mchehab@infradead.org: Manually fixed some conflicts with a previous patch] Signed-off-by: Felipe Balbi Signed-off-by: Mauro Carvalho Chehab commit dbbc83c4923dddc7418a58d104c634d73d53d89e Author: Hans Verkuil Date: Mon Aug 18 04:48:42 2008 -0300 V4L/DVB (8695): usbvideo: add proper error check and add release function Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab commit 66cdf443c605a2254c45be15cf504b44ad69bd70 Author: Hans Verkuil Date: Sat Aug 16 08:33:14 2008 -0300 V4L/DVB (8691): i2c-id: remove obsolete SAB3036 driver ID Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab commit 58f8dab4b68e3c83341f1fbe1d8d7bf888f6fd59 Author: Hans Verkuil Date: Sat Aug 16 07:56:12 2008 -0300 V4L/DVB (8690): tuner-3036: remove driver This driver is for VERY old i2c-over-parallel port teletext receiver boxes. Rather then spending effort on converting this driver to V4L2, and since it is extremely unlikely that anyone still uses one of these devices, it was decided to drop it (after discussing this as well with the original author, Phil Blundell). Signed-off-by: Hans Verkuil Signed-off-by: Phil Blundell Signed-off-by: Mauro Carvalho Chehab commit b0efc2ac5c2a42f51d885d8c28416845e29fb676 Author: Hans Verkuil Date: Sat Aug 16 07:50:23 2008 -0300 V4L/DVB (8689): dpc7146: remove dpc7146 demonstration board driver Old driver for the dpc7146 demonstration board that is no longer relevant. The last time this was tested on actual hardware was probably around 2002. Since this is a driver for a demonstration board the decision was made (after discussing this with the original author, Michael Hunold) to remove it rather than spending a lot of effort continually updating this driver to stay in sync with the latest internal V4L2 or I2C API. Signed-off-by: Hans Verkuil Signed-off-by: Michael Hunold Signed-off-by: Mauro Carvalho Chehab commit b1db02b1c035c582f0b97229fa40a992f15e4892 Author: Stefan Herbrechtsmeier Date: Thu Aug 14 12:04:11 2008 -0300 V4L/DVB (8687): soc-camera: Move .power and .reset from soc_camera host to sensor driver Make .power and .reset callbacks per camera instead of per host, also move their invocation to camera drivers. Signed-off-by: Stefan Herbrechtsmeier Signed-off-by: Guennadi Liakhovetski Signed-off-by: Mauro Carvalho Chehab commit e777ba470ebe7c152a42efaf0dd8f6a9e1f60051 Author: Guennadi Liakhovetski Date: Thu Aug 14 12:03:49 2008 -0300 V4L/DVB (8686): mt9m111: style cleanup Fix a typo in Kconfig, simplify error checking, further minor cleanup. Tested-by: Robert Jarzmik Signed-off-by: Guennadi Liakhovetski Signed-off-by: Mauro Carvalho Chehab commit 522dbc55c7a13d80a8549a1d44216a824d4bce34 Author: Guennadi Liakhovetski Date: Thu Aug 14 12:03:18 2008 -0300 V4L/DVB (8685): mt9m001, mt9v022: Simplify return code checking i2c_smbus_write_word_data() returns 0 or a negative error, hence no need to check for "> 0". Signed-off-by: Guennadi Liakhovetski Signed-off-by: Mauro Carvalho Chehab commit 7f10ac4a77c55e45fde14e969e04dfba02c3214a Author: Robert Jarzmik Date: Thu Aug 14 12:02:51 2008 -0300 V4L/DVB (8684): Add support for Micron MT9M111 camera. Adds support for Micron MT9M111 camera chip, with basic features : - view rectangle configurable - some output formats (bayer8, bayer10, rgb565, rgb555, ycbycr) - autoexposure - only highpower mode context used (ie. context B) create mode 100644 drivers/media/video/mt9m111.c Signed-off-by: Robert Jarzmik Signed-off-by: Guennadi Liakhovetski Signed-off-by: Mauro Carvalho Chehab commit 390f46a1c63daa54bc2a2e6cc85d14e041d9e7ff Author: Robert Jarzmik Date: Thu Aug 14 11:36:37 2008 -0300 V4L/DVB (8683): Add Micron mt9m111 chip ID in V4L2 identifiers Signed-off-by: Robert Jarzmik Signed-off-by: Guennadi Liakhovetski Signed-off-by: Mauro Carvalho Chehab commit 6493df33053176c068781128846cdfb37fd2fa7f Author: Alexander Beregalov Date: Wed Aug 20 20:44:54 2008 -0300 V4L/DVB (8680): saa7134-core.c: fix warning drivers/media/video/saa7134/saa7134-core.c:366: warning: 'saa7134_buffer_requeue' defined but not used Signed-off-by: Alexander Beregalov Signed-off-by: Andrew Morton Signed-off-by: Mauro Carvalho Chehab commit 57e47fd898ae2601801338d4a15ceb86fcd81371 Author: Michael Krufky Date: Sat Aug 9 15:29:46 2008 -0300 V4L/DVB (8658): lgs8gl5: fix build warnings Fix the following build warnings: lgs8gl5.c: In function 'lgs8gl5_read_reg': lgs8gl5.c:95: warning: unused variable 'j' lgs8gl5.c: In function 'lgs8gl5_update_alt_reg': lgs8gl5.c:135: warning: unused variable 'j' lgs8gl5.c: In function 'lgs8gl5_read_ber': lgs8gl5.c:300: warning: unused variable 'state' lgs8gl5.c: In function 'lgs8gl5_read_ucblocks': lgs8gl5.c:332: warning: unused variable 'state' lgs8gl5.c: At top level: lgs8gl5.c:181: warning: 'lgs8gl5_set_inversion' defined but not used Signed-off-by: Michael Krufky Signed-off-by: Mauro Carvalho Chehab commit ab496dc5e0f5367d87f9ffc2326aa8bc72f3ff8a Author: Timothy Lee Date: Sat Aug 9 13:36:51 2008 -0300 V4L/DVB (8657): cxusb: add lgs8gl5 and support for Magic-Pro DMB-TH usb stick Add support for Magic-Pro DMB-TH usb stick. DMB-TH is the HDTV broadcast standard used in Hong Kong and China. [...] I've also attached a second patch against the dvb-apps repository which adds a DMB-TH scan file for Hong Kong. Since the ProHDTV stick contains a DMB-TH decoder (lgs8gl5) onboard, it outputs MPEG-TS to the PC. Signed-off-by: Timothy Lee Signed-off-by: Michael Krufky Signed-off-by: Mauro Carvalho Chehab commit d82cd2a1e698f1ba572f1b490ffa2f1dc967f5c4 Author: Michael Krufky Date: Sat Aug 9 14:21:58 2008 -0300 V4L/DVB (8656): fix DVB_FE_CUSTOMISE for DVB_DIB7000P and DVB_TUNER_DIB0070 with dvb-usb-cxusb Allow dvb-usb-cxusb to be built without dib7000p or dib0070 selected Signed-off-by: Michael Krufky Signed-off-by: Mauro Carvalho Chehab commit 1b1ab31b35c6b974f68063b9174bed1286f60a31 Author: Michael Krufky Date: Sat Aug 9 13:06:26 2008 -0300 V4L/DVB (8655): cxusb: fix checkpatch warnings & errors Fix the following checkpatch.pl errors and warnings: ERROR: do not use assignment in if condition 117: FILE: linux/drivers/media/dvb/dvb-usb/cxusb.c:819: + if ((adap->fe = dvb_attach(dib7000p_attach, ERROR: switch and case should be at the same indent 155: FILE: linux/drivers/media/dvb/dvb-usb/cxusb.c:857: + switch (band) { + case BAND_VHF: offset = 950; break; + case BAND_UHF: + default: offset = 550; break; WARNING: line over 80 characters 169: FILE: linux/drivers/media/dvb/dvb-usb/cxusb.c:871: + struct i2c_adapter *tun_i2c = dib7000p_get_i2c_master(adap->fe, DIBX000_I2C_INTERFACE_TUNER, 1); WARNING: line over 80 characters 213: FILE: linux/drivers/media/dvb/dvb-usb/cxusb.c:1342: +static struct dvb_usb_device_properties cxusb_bluebird_dualdig4_rev2_properties = { WARNING: line over 80 characters 226: FILE: linux/drivers/media/dvb/dvb-usb/cxusb.c:1355: + .size_of_priv = sizeof(struct dib0700_adapter_state), total: 2 errors, 3 warnings, 266 lines checked Cc: Anton Blanchard Signed-off-by: Michael Krufky Signed-off-by: Mauro Carvalho Chehab commit 1cd6aeedc0df66ea8ff3865d904804aff703cf74 Author: Anton Blanchard Date: Sat Aug 9 12:23:15 2008 -0300 V4L/DVB (8654): cxusb: add support for DViCO FusionHDTV DVB-T Dual Digital 4 (rev 2) Add support for revision 2 of the DViCO FusionHDTV DVB-T Dual Digital 4 which has new tuners and demodulators (2 x DIB7070p). With this patch both DVB reception and IR works. The dib7000p driver currently hardwires the output mode to OUTMODE_MPEG2_SERIAL regardless of what we ask for. Modify it to allow OUTMODE_MPEG2_PAR_GATED_CLK to be set. Longer term we should remove the check completely and set the output mode correctly in all the callers. Add Kconfig bits to ensure the dib7000p and dib0070 modules are enabled. It would be nice to only do this for the !DVB_FE_CUSTOMISE case, but this is what the other DIB7070 module does (there are a number of module dependencies in the attach code). Signed-off-by: Anton Blanchard Signed-off-by: Michael Krufky Signed-off-by: Mauro Carvalho Chehab commit 80b75e870112eeb9e9633a73b5497220d6a36631 Author: Hans Verkuil Date: Sat Aug 9 10:35:29 2008 -0300 V4L/DVB (8649): v4l2: add AAC bitrate control If you can select AAC as audio encoder, then you should also be able to set the bitrate. Add this missing control. Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab commit ab3fb7c091e7fab737fe41cdbc60ef392c5fa18f Author: Steven Toth Date: Mon Aug 4 22:18:19 2008 -0300 V4L/DVB (8646): cx23885: Convert framework to use a single tuner callback function. Code reduction. Tuner callback now assumes that tsport is passed as the void arg. Signed-off-by: Steven Toth Signed-off-by: Mauro Carvalho Chehab commit 8df13a3b3686b6528b9ffb03d1ddfcf9a3f76181 Author: Steven Toth Date: Mon Aug 4 21:41:06 2008 -0300 V4L/DVB (8645): Support IR remote on FusionHDTV DVB-T Dual Express From Chris Pascoe Support IR remote on FusionHDTV DVB-T Dual Express Signed-off-by: Steven Toth Signed-off-by: Anton Blanchard Signed-off-by: Mauro Carvalho Chehab commit 08a4c522dbca2aee5acb30eab6c9dcc1b34acce5 Author: Steven Toth Date: Mon Aug 4 21:39:53 2008 -0300 V4L/DVB (8644): Add support for DViCO FusionHDTV DVB-T Dual Express Add support for the DViCO FusionHDTV DVB-T Dual Express card, based on work by Chris Pascoe and Stephen Backway. Signed-off-by: Steven Toth Signed-off-by: Anton Blanchard Signed-off-by: Mauro Carvalho Chehab commit e64596171434b111e33b16e385da9cbd2cd3908b Author: Steven Toth Date: Mon Aug 4 21:38:46 2008 -0300 V4L/DVB (8643): Switch Hauppauge HVR1400 and HVR1500 to common cx23885 tuner callback The Hauppauge HVR1400 and HVR1500 can now use the common cx23885 tuner callback. Signed-off-by: Steven Toth Signed-off-by: Anton Blanchard Signed-off-by: Mauro Carvalho Chehab commit ab9077b70f02e24f6f12cda6387545685ceb3032 Author: Steven Toth Date: Mon Aug 4 21:36:49 2008 -0300 V4L/DVB (8642): cx23885: Factor out common cx23885 tuner callback Tuners currently hook different things to the private pointer in their callback function. Longer term we should make that private pointer consistent, but for now separate out the guts of the cx23885 tuner callback so we can reuse it. Signed-off-by: Steven Toth Signed-off-by: Anton Blanchard Signed-off-by: Mauro Carvalho Chehab commit f4d7133c0bb3fc0215ab5524974ea2721800f96f Author: Hans Verkuil Date: Fri Aug 8 15:47:07 2008 -0300 V4L/DVB (8641): arv: fix compilation errors/warnings - add PCI dependency for btcx - fix compile errors (doesn't like ';' at the end of a #if 0) Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab commit a99a457f7de93e82242b027ee7e17cf3e48430bd Author: Hans Verkuil Date: Fri Aug 8 13:27:16 2008 -0300 V4L/DVB (8640): saa6752hs: add PMT table for AC3 The PMT table for AC3 audio is different. Thanks to Dmitry Belimov for providing the table data. Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab commit 56deca3391ce38ca9e2618a72561ba4228f7a9f9 Author: Hans Verkuil Date: Fri Aug 8 12:43:59 2008 -0300 V4L/DVB (8639): saa6752hs: cleanup and add AC-3 support Cleaned up the saa6752hs i2c driver. Add AC-3 support. Add VIDIOC_CHIP_IDENT support. Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab commit 0187f31382142275b4b50f5bf1d8588a38e2ced3 Author: Hans Verkuil Date: Fri Aug 8 08:34:19 2008 -0300 V4L/DVB (8637): v4l2: add v4l2_ctrl_query_menu_valid_items support function v4l2_ctrl_query_menu_valid_items() makes it easy to handle control menus that have a lot of invalid 'holes'. For example, many MPEG encoders only support a limited subset of audio bitrates. In that case a driver can specify an array listing the set of valid bitrates and pass that to this function. Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab commit 6f4a183a9a69338e3ea465fdbefe891cf5e00acd Author: Hans Verkuil Date: Fri Aug 8 07:55:00 2008 -0300 V4L/DVB (8636): v4l2: add v4l2_ctrl_get_name control support function. Add function that returns the control name. Allows this to be used in places where the normal v4l2_ctrl_query_fill() function cannot be used (e.g. uvc). Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab commit dc3ba923bd4ee88eb25212a3bee7c5986d0a1a77 Author: Hans Verkuil Date: Fri Aug 8 07:38:07 2008 -0300 V4L/DVB (8635): v4l: add AC-3 audio support to the MPEG Encoding API Some models of the saa6752hs support AC-3. Extend the API with the necessary controls for AC-3. Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab commit a734b05e4504d625fa6b857d597887a37009ffe2 Author: Janne Grunau Date: Fri Aug 8 07:21:00 2008 -0300 V4L/DVB (8634): v4l2: extend MPEG Encoding API with AVC and AAC Adds Advanced Audio Coding (AAC) and MPEG-4 Advanced Video Coding (AVC/H.264) as audio/video codecs to the extended controls API. Updates cx2341x driver to the new values. Signed-off-by: Janne Grunau Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab commit 5b1c61774bb74eaed8cf3dd5d3a4473a8c784586 Author: Hans Verkuil Date: Fri Jul 25 10:31:23 2008 -0300 V4L/DVB (8630): First mxb cleanup phase Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab commit f2730ce508791c163919a79bfa7b7d8faaee7105 Author: Mauro Carvalho Chehab Date: Tue Aug 5 10:14:13 2008 -0300 V4L/DVB (8628): bttv: Add support for Encore ENLTV2-FM Thanks to Sistema Fenix (http://www.sistemafenix.com.br/) and CDI Brasil (www.cdibrasil.com.br/) for sponsoring this development. Signed-off-by: Gilberto Signed-off-by: Mauro Carvalho Chehab commit 631523eff77080792e96c48dd279a66bc65ac3fd Author: Mauro Carvalho Chehab Date: Tue Aug 5 10:12:35 2008 -0300 V4L/DVB (8627): Fix mute on bttv driver Signed-off-by: Mauro Carvalho Chehab commit 39428a0df06a1ac8d0658e07249b3b8359d78a33 Author: Mauro Carvalho Chehab Date: Tue Aug 5 10:11:25 2008 -0300 V4L/DVB (8626): Add support for TCL tuner MF02GIP-5N-E Thanks to Sistema Fenix (http://www.sistemafenix.com.br/) and CDI Brasil (www.cdibrasil.com.br/) for sponsoring this development. Signed-off-by: Gilberto Signed-off-by: Mauro Carvalho Chehab commit 272105a33b83de1cac7658b1244f475daf4df51b Author: Mauro Carvalho Chehab Date: Tue Aug 5 10:03:17 2008 -0300 V4L/DVB (8625): saa7134: Add NEC prococol IR decoding capability This patch adds the capability of decoding NEC protocol, received via GPIO18 line. This GPIO port can trigger saa7134 IRQ. A future improvement would be to make it a little more generic to work also with GPIO16 line. A pure IRQ code didn't work, since some delays were introduced on the tests we did. A possible approach would be to use polling at a rate of 2.5 ms or less. If a new code were taken, a code similar to nec_task() could be used. However, this would add an extra overhead to kernel, and will consume more power. Due to that, we took an hybrid approach: an IRQ upper half to trigger when a new key is received and a bottom half to convert pulse-distance into a keycode. The bottom half is polling based, to improve performance. During the bottom half proccess, GPIO18 IRQ line is disabled, preventing IRQ reentrancy and improving performance a little bit. Thanks to Sistema Fenix (http://www.sistemafenix.com.br/) for sponsoring this development. Signed-off-by: Gilberto Signed-off-by: Mauro Carvalho Chehab commit c5458886759c483be31ae976613c248404c184f4 Author: Hans Verkuil Date: Wed Jul 30 08:43:36 2008 -0300 V4L/DVB (8613): v4l: move BKL down to the driver level. The BKL is now moved from the video_open function in v4l2-dev.c to the various drivers. It seems about a third of the drivers already has a lock of some sort protecting the open(), another third uses video_exclusive_open (yuck!) and the last third required adding the BKL in their open function. Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab commit 8dda00ea0edd845a4345e40210a86379866247e3 Author: Michael Krufky Date: Sat Aug 2 00:19:53 2008 -0300 V4L/DVB (8600): au0828: explicitly set 6 MHz IF frequency in hauppauge_hvr950q_config Explicitly set 6 MHz IF frequency for VSB and QAM in hauppauge_hvr950q_config. The default value is 6 MHz, so this patch doesn't change anything -- this only improves code readability and may prevent future bugs. Signed-off-by: Michael Krufky Signed-off-by: Mauro Carvalho Chehab commit 3f777cd74c1fbf0b329bd770691ccd60c8647579 Author: Michael Krufky Date: Fri Aug 1 23:54:57 2008 -0300 V4L/DVB (8599): au8522: remove if frequency settings from vsb/qam modulation tables Since IF frequency is set after the vsb/qam modulation tables are written, remove the redundant register settings from the vsb/qam modulation tables. Signed-off-by: Michael Krufky Signed-off-by: Mauro Carvalho Chehab commit 2ec7bb74989777035d7faafdde4000e4d0184198 Author: Michael Krufky Date: Fri Aug 1 23:42:33 2008 -0300 V4L/DVB (8598): au8522: clean up function au8522_set_if re-write this function to make it simpler Signed-off-by: Michael Krufky Signed-off-by: Mauro Carvalho Chehab commit 4bc41f3d48b7cbaec5bd872d5b4f05e7b9cdc7d6 Author: Adrian Bunk Date: Tue Jul 22 14:20:12 2008 -0300 V4L/DVB (8561): make ivtv_claim_stream() static ivtv_claim_stream() can now become static. Signed-off-by: Adrian Bunk Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab commit 877f7f9751103d7e2fd4566a69ea1cadaf4e0d3a Author: Alexander Beregalov Date: Mon Jul 21 16:21:58 2008 -0300 V4L/DVB (8560): replace __FUNCTION__ with __func__ v4l/drx397xD: replace __FUNCTION__ with __func__ Signed-off-by: Alexander Beregalov Signed-off-by: Mauro Carvalho Chehab commit b802a3a93a7e388d2dc9f9212e9ddea28fa2df27 Author: Alexander Beregalov Date: Mon Jul 21 16:20:32 2008 -0300 V4L/DVB (8559): replace __FUNCTION__ with __func__ v4l: replace __FUNCTION__ with __func__ Signed-off-by: Alexander Beregalov Signed-off-by: Mauro Carvalho Chehab commit 7cc4404bd22b3913e858b8dee43fd19abb1d8fbc Author: Michael Krufky Date: Sun Jul 27 18:13:20 2008 -0300 V4L/DVB (8556): au0828: add support for Hauppauge Woodbury Signed-off-by: Michael Krufky Signed-off-by: Mauro Carvalho Chehab commit 3b2f8337aa1fcc67ed996b49dee9ef1ad3543c47 Author: Michael Krufky Date: Sun Jul 27 18:11:28 2008 -0300 V4L/DVB (8555): au8522: add mechanism to configure IF frequency for vsb and qam Add a mechanism to configure IF frequency for vsb and qam. Signed-off-by: Michael Krufky Signed-off-by: Mauro Carvalho Chehab commit 6d4f240101cfcbc0d3a355d0b91d8eadb1322846 Author: Mauro Carvalho Chehab Date: Mon Jul 28 13:07:42 2008 -0300 V4L/DVB (8554): media/video/Kconfig: cosmetic changes and convert select into depends on It seems cosmetically better to let USB drivers be the last one. Also, two SOC drivers were using select, instead of depends on SOC_CAMERA. Since select has some drawbacks when checking for dependencies, convert those two into depends on. Cc: Guennadi Liakhovetski Signed-off-by: Mauro Carvalho Chehab commit 3a47b5939ac549460dfa9c56d266f99337122a79 Author: Mauro Carvalho Chehab Date: Mon Jul 28 12:58:53 2008 -0300 V4L/DVB (8553): media/video/Kconfig: get rid of a select Signed-off-by: Mauro Carvalho Chehab commit 6b9d544e3b597b32a07f988676aa17aaedc41187 Author: Andy Walls Date: Fri Aug 22 20:44:44 2008 -0300 V4L/DVB (8769): cx18: Simplify queue flush logic to prevent oops in cx18_flush_queues() cx18: Simplify queue flush logic to prevent oops in cx18_flush_queues(). If accounting of a queue is in error, logic borrowed from ivtv will cause an oops when flushing the queues for a stream. This change greatly simplifies the queue flush logic, and sets the queue back to sane defaults on a flush. Signed-off-by: Andy Walls Signed-off-by: Mauro Carvalho Chehab commit 67f93c4265de4684b25278ffbb036d9bdcca0677 Author: Mauro Carvalho Chehab Date: Sun Aug 24 12:28:11 2008 -0300 V4L/DVB (8751): vivi: Fix some issues at vivi register routine This patch fixes several small issues at vivi register routines: 1) minor and n_devs should be unsigned; 2) n_devs = 0 were not properly handled; 3) if n_devs specify a high number, the driver would just roll back and won't register any device. The proper behaviour is to keep all succeded devices registered; 4) both n_devs and minor were using 0 as permissions. Better to have them with 0444. With the current patch, if n_devs specify a very large value, it will register all possible devices. For example, on a machine without any other V4L drivers loaded, with this patch, we will have something like: vivi: V4L2 device registered as /dev/video0 vivi: V4L2 device registered as /dev/video1 vivi: V4L2 device registered as /dev/video2 ... vivi: V4L2 device registered as /dev/video31 video_register_device_index: get_index failed Video Technology Magazine Virtual Video Capture Board ver 0.5.0 successfully loaded. 5) The number of allocated devices on success is now kept at n_devs: $ cat /sys/module/vivi/parameters/n_devs 32 Thanks to Henne for pointing that there were some issues at vivi. Cc: Henne Signed-off-by: Mauro Carvalho Chehab commit a3ba85649b296b42f8b6ee09c104dd226356845f Author: Henrik Kretzschmar Date: Fri Aug 22 16:41:03 2008 -0300 V4L/DVB (8750): V4L: check inval in video_register_device_index() Better check the video_device pointer before using it. Signed-off-by: Henrik Kretzschmar Signed-off-by: Mauro Carvalho Chehab commit 2763b28582e57a8def5b1f35f35ab0114f8bf9e0 Author: Mauro Carvalho Chehab Date: Sun Aug 24 10:41:53 2008 -0300 V4L/DVB (8749): Fix error code, when camera is not turned on by sonypi Signed-off-by: Mauro Carvalho Chehab commit 1d5657dd5f16d9ebf62d13fd79e388de9b524b8c Author: Rene Herman Date: Wed Aug 20 20:44:52 2008 -0300 V4L/DVB (8728): 1-make-pms-not-autoprobe-when-builtin update On 10-08-08 23:37, Alan Cox wrote: > > Would probably make the printk "pms: not enabled, use pms.enable=1 to > probe" > > So you know > a) What is wittering about not being probed > b) How to undo it. > > But thats trivia really. Signed-off-by: Rene Herman Signed-off-by: Andrew Morton Signed-off-by: Mauro Carvalho Chehab commit c6da815672fc6b6b5665b19b1d99f080b5c06895 Author: Rene Herman Date: Wed Aug 20 20:44:51 2008 -0300 V4L/DVB (8727): V4L1: make PMS not autoprobe when builtin. The old Mediavision Pro Movie Studio legacy ISA V4L1 driver was found to hang the boot during Ingo Molnar's testing of randconfig kernels. Have it require a "pms.enable=1" kernel parameter to enable the driver when builtin which avoids such problems. This is a deprecated and, very likely, unused driver. Nothing changes modular behaviour moreover. Signed-off-by: Rene Herman Acked-by: Alan Cox Signed-off-by: Andrew Morton Signed-off-by: Mauro Carvalho Chehab commit 7dc32a6c4151bed9d5dd300c5084aa6d18f587d8 Author: Michael Krufky Date: Thu Aug 21 22:37:10 2008 -0300 V4L/DVB (8722): sms1xxx: fix typo in license header This should have read, "GNU General Public License version 2" rather than, "GNU General Public License version 3" This was actually a typo mass-blunder -- this is not a change in licence, as the code was always GPLv2. Signed-off-by: Uri Shkolnik Signed-off-by: Michael Krufky Signed-off-by: Mauro Carvalho Chehab commit 9a9335776548d01525141c6e8f0c12e86bbde982 Author: Hans de Goede Date: Fri Aug 22 04:13:34 2008 -0300 V4L/DVB (8720): gspca: V4L2_CAP_SENSOR_UPSIDE_DOWN added as a cap for some webcams. This patch adds a V4L2_CAP_SENSOR_UPSIDE_DOWN flag to the capabilities flags, and sets this flag for the Philips SPC200NC cam (which has its sensor installed upside down). The same flag is also needed and added for the Philips SPC300NC. Together with a patch to libv4l which adds flipping the image in software this fixes the upside down display with the SPC200NC cam. Signed-of-by: Hans de Goede Signed-off-by: Jean-Francois Moine Signed-off-by: Mauro Carvalho Chehab commit 47eb9aea325212528493807973fe2656d71e305a Author: Jean-Francois Moine Date: Thu Aug 21 14:11:16 2008 -0300 V4L/DVB (8719): gspca: Have VIDIOC_QUERYCTRL more compliant to the spec. - return -EINVAL when control not supported. - start the private controls at V4L2_CID_PRIVATE_BASE. Signed-off-by: Jean-Francois Moine Signed-off-by: Mauro Carvalho Chehab commit 5cd583c03f2c60f67f05dd7794a955ee065f412c Author: Jean-Francois Moine Date: Thu Aug 21 11:25:31 2008 -0300 V4L/DVB (8718): gspca: suspend/resume added. Signed-off-by: Jean-Francois Moine Signed-off-by: Mauro Carvalho Chehab commit e540e276ca7efaf19a6b855871e8b7bbaab1f98d Author: Jean-Francois Moine Date: Thu Aug 21 04:16:41 2008 -0300 V4L/DVB (8717): gspca: Frame buffer too small for small resolutions (sonixj and t613). Signed-off-by: Jean-Francois Moine Signed-off-by: Mauro Carvalho Chehab commit 425644f7a5c03429c94a34bd278e4c311f103c4b Author: Jean-Francois Moine Date: Thu Aug 21 04:00:48 2008 -0300 V4L/DVB (8716): gspca: Bad start of sn9c110 and sensor ov7630. Signed-off-by: Jean-Francois Moine Signed-off-by: Mauro Carvalho Chehab commit 7a5b2bf733c8071047bb75eced9b5a84d4788105 Author: Jean-Francois Moine Date: Wed Aug 20 10:39:38 2008 -0300 V4L/DVB (8715): gspca: Change the name of some webcam in the gspca doc. Signed-off-by: Jean-Francois Moine Signed-off-by: Mauro Carvalho Chehab commit 1918d57322a2ac3b2d4a91918f763703ef186af4 Author: Jean-Francois Moine Date: Tue Aug 19 13:17:37 2008 -0300 V4L/DVB (8714): gspca: Bad start of sn9c110 and sensor om6802. Signed-off-by: Jean-Francois Moine Signed-off-by: Mauro Carvalho Chehab commit d263386db1b490099416a0a78c8b63a8ccb62aa4 Author: Jean-Francois Moine Date: Tue Aug 19 07:25:03 2008 -0300 V4L/DVB (8713): gspca: Bad color control again in sonixj. Signed-off-by: Jean-Francois Moine Signed-off-by: Mauro Carvalho Chehab commit f693ba53c182abf93145a7d907e2fe72d8c6d08b Author: Jean-Francois Moine Date: Tue Aug 19 06:31:08 2008 -0300 V4L/DVB (8712): gspca: Bad start of sonixj webcams since changeset a8779025e7e8. Signed-off-by: Jean-Francois Moine Signed-off-by: Mauro Carvalho Chehab commit 02c8259c244e84355ccbf332e9ba5368083028ff Author: Jean-Francois Moine Date: Mon Aug 18 14:40:11 2008 -0300 V4L/DVB (8711): gspca: Bad controls and quantization table of pac7311. Patch adapted from a gspca v1 patch by Thomas Kaiser. Signed-off-by: Jean-Francois Moine Signed-off-by: Mauro Carvalho Chehab commit f661a7f3b75b08c54cf01c1791a610a01dde5fba Author: Jean-Francois Moine Date: Mon Aug 18 06:45:13 2008 -0300 V4L/DVB (8710): gspca: Bad color control in sonixj. Signed-off-by: Jean-Francois Moine Signed-off-by: Mauro Carvalho Chehab commit 1cbf010d7a6142a802e989d1791139803688c5ee Author: Jean-Francois Moine Date: Mon Aug 18 06:12:43 2008 -0300 V4L/DVB (8709): gspca: Fix initialization and controls of sn9x110 - ov7630. Signed-off-by: Jean-Francois Moine Signed-off-by: Mauro Carvalho Chehab commit a6823acdfda6987b8735608f99e8634668bc15c7 Author: Jean-Francois Moine Date: Fri Aug 15 14:10:10 2008 -0300 V4L/DVB (8707): gspca: Colors, hflip and vflip controls added for pac7302. Signed-off-by: Jean-Francois Moine Signed-off-by: Mauro Carvalho Chehab commit d7ae7dc02e22ac9bc7bd382fecf19cf2f1677b04 Author: Jean-Francois Moine Date: Fri Aug 15 06:54:57 2008 -0300 V4L/DVB (8706): Make contrast and brightness work for pac7302. Signed-off-by: Jean-Francois Moine Signed-off-by: Mauro Carvalho Chehab commit fae21ad3c0743ccf8990aec6d807cfcd77e040f4 Author: Jean-Francois Moine Date: Thu Aug 14 14:53:33 2008 -0300 V4L/DVB (8705): gspca: Adjust some control limits in spca561. Signed-off-by: Jean-Francois Moine Signed-off-by: Mauro Carvalho Chehab commit df9845137b88d05afa8f39b00955af3921e85fc7 Author: Jean-Francois Moine Date: Thu Aug 14 08:37:28 2008 -0300 V4L/DVB (8703): gspca: Do controls work for spca561 revision 12a. Signed-off-by: Jean-Francois Moine Signed-off-by: Mauro Carvalho Chehab commit c05d8049f95f6a341a6b910724ad370c2edc24ea Author: Andy Walls Date: Sun Aug 17 23:13:31 2008 -0300 V4L/DVB (8701): cx18: Add missing lock for when the irq handler manipulates the queues cx18: Add missing lock for when the irq handler manipulates the queues. This was a potential source of stream queue corruption. Also changed the name of cx18_queue_find_buf() to cx18_queue_get_buf_irq(). Signed-off-by: Andy Walls Signed-off-by: Mauro Carvalho Chehab commit c8049966b7f903ce61e94efbbddf581cf8860b85 Author: David S. Miller Date: Sat Aug 30 03:12:38 2008 -0700 sparc64: Convert FIRE PCI controller driver into a real driver. And now all the by-hand PCI controller probing junk in pci.c can die too. Signed-off-by: David S. Miller commit edbe805b2b1044659e0727136213bdf42bd1b9d0 Author: David S. Miller Date: Sat Aug 30 03:14:01 2008 -0700 sparc64: Convert SABRE PCI controller driver into a real driver. Signed-off-by: David S. Miller commit b20bfe41badcbf38512fbe1118fe2e0817098e77 Author: David S. Miller Date: Sat Aug 30 03:13:20 2008 -0700 sparc64: Convert PSYCHO PCI controller driver into a real driver. Signed-off-by: David S. Miller commit 3822b50964d6702b7d8ba18ffd132d4bf786a17e Author: David S. Miller Date: Sat Aug 30 02:50:29 2008 -0700 sparc64: Convert SUN4V PCI controller driver into a real driver. Signed-off-by: David S. Miller commit 6d19c88f53bb3471a15152ea4fbdbebd36c0046c Author: David S. Miller Date: Sat Aug 30 02:30:24 2008 -0700 sparc64: Convert SCHIZO PCI controller driver into a real driver. The idea is to convert all of the PCI controller drivers into genuine OF drivers, then we can get rid of this terrible probing table and infrastructure in arch/sparc64/kernel/pci.c Signed-off-by: David S. Miller commit c510b9bfa1c34c1452f7a4389ff6de4f72a78193 Author: David S. Miller Date: Sat Aug 30 01:18:56 2008 -0700 sparc64: Don't invoke power_init() from pcibios_init(). That's just silly, use device_initcall() instead. Signed-off-by: David S. Miller commit e0ac612e6997429a21887475709ca6d6224971f2 Author: David S. Miller Date: Sat Aug 30 00:37:36 2008 -0700 sparc: Kill ebus_bus_type. No longer used. Signed-off-by: David S. Miller commit 356d164757310cd822d71da2027d50ec39798b7f Author: David S. Miller Date: Sat Aug 30 00:36:11 2008 -0700 sparc: Kill EBUS driver layer. All that remains is the EBUS DMA programming library for sparc64. Signed-off-by: David S. Miller commit 75081322c9d0d56f8880178f9fcc93778bcf0220 Author: David S. Miller Date: Sat Aug 30 00:23:51 2008 -0700 sparc32: Convert PC RTC probing to pure OF driver. Signed-off-by: David S. Miller commit afc88ad6b38797aeec4d635140099ace077df587 Author: David S. Miller Date: Sat Aug 30 00:13:55 2008 -0700 cs4231: Convert to EBUS side to pure OF driver. Signed-off-by: David S. Miller commit 3ae627a19ef0d7b5521a070e309ac7ebe57638d3 Author: David S. Miller Date: Fri Aug 29 23:26:23 2008 -0700 sparc64: Convert EBUS floppy support to pure OF driver. Signed-off-by: David S. Miller commit aae7fb87ec4d2df6cb551670b1765cf4e5795a3b Author: David S. Miller Date: Fri Aug 29 23:10:21 2008 -0700 sparc: Move EBUS DMA interfaces into seperate header file. These have no dependencies on the EBUS probing layer, the clients setup the registers and all of those details. The EBUS DMA layer just programs and manages the DMA controller found in EBUS. Signed-off-by: David S. Miller commit 39890072b320e7731b105b459cee1320957adbc7 Author: David S. Miller Date: Fri Aug 29 22:55:14 2008 -0700 bbc_envctrl: Fix build errors from bbc_i2c OF conversion. Signed-off-by: David S. Miller commit ae05f87ee2f403228bca6d28fef29d6be0bfbedc Author: David S. Miller Date: Fri Aug 29 22:42:34 2008 -0700 sparc64: Propagate PCI device archdata into OF device tree for EBUS. In order to convert EBUS drivers doing DMA into pure OF drivers, we need the of_device->dev.archdata setup properly. EBUS instances that can provide DMA for device nodes sit on PCI, so detect and propagate the information there. Signed-off-by: David S. Miller commit e21e245bcd9d5244735799387d14421789b20557 Author: David S. Miller Date: Fri Aug 29 22:34:14 2008 -0700 bbc_i2c: Convert to pure OF driver. This thing was a mess, who wrote this junk? :) Luckily we'll soon have nice generic I2C layer drivers for this PCF based I2C stuff on sparc64. Signed-off-by: David S. Miller commit 6b8c90f24e24505f97efaef1a46572d6b45929b9 Author: David S. Miller Date: Fri Aug 29 21:05:15 2008 -0700 envctrl: Convert to pure OF driver. Signed-off-by: David S. Miller commit 95d4390579e02e168a14f19506fbadd30daffced Author: David S. Miller Date: Fri Aug 29 18:01:58 2008 -0700 display7seg: Convert to pure OF device driver. Signed-off-by: David S. Miller commit 0e52fe8c01e7945881aac6aeb7c96af3f59976a8 Author: David S. Miller Date: Fri Aug 29 17:41:36 2008 -0700 sun_uflash: Convert to pure OF driver. Signed-off-by: David S. Miller commit 8ab0dc333eacb2249c63d1fc7c5241299fa0493f Author: David S. Miller Date: Fri Aug 29 17:07:01 2008 -0700 cpwatchdog: Move to drivers/watchdog/cpwd.c Signed-off-by: David S. Miller commit c5f8556cb5b8ab020f234191a6071cbeeeabd638 Author: David S. Miller Date: Fri Aug 29 17:05:51 2008 -0700 cpwatchdog: Cleanup and convert to pure OF driver. Signed-off-by: David S. Miller commit e25ecd08c43e5111148dc4d847ac7e139ef76888 Author: David S. Miller Date: Fri Aug 29 15:42:31 2008 -0700 riowd: Distinguish between driver name and OF device node name. Driver messages should print the driver name, rather than the OF device node name. Signed-off-by: David S. Miller commit 957183f32e136450eb9a4b8eed52dfac46834eed Author: David S. Miller Date: Fri Aug 29 15:40:24 2008 -0700 riowatchdog: Move under drivers/watchdog The config stuff was already in drivers/watchdog/Kconfig Signed-off-by: David S. Miller commit e42311d75107ca78868ded0286b691aad2df1f29 Author: David S. Miller Date: Fri Aug 29 15:35:59 2008 -0700 riowatchdog: Convert to pure OF driver. This also cleans up a lot of crud in this driver: 1) Don't touch the BBC regs, just leave the watchdog trigger behavior whatever the firmware programmed it to. 2) Use WATCHDOG_MINOR instead of hardcoded and not properly allocated RIOWD_MINOR. Hey, I haven't touched it since I wrote it years ago :-) Signed-off-by: David S. Miller commit f2be6de88d247cd57010944f62267b53c47d5ae3 Author: David S. Miller Date: Fri Aug 29 01:35:19 2008 -0700 sparc64: Use generic starfire RTC driver. Also, delete the mini RTC driver, no longer used. Signed-off-by: David S. Miller commit de2cf332b74614ad3d52206da03095b6b8cbdac1 Author: David S. Miller Date: Thu Aug 28 23:02:36 2008 -0700 rtc: Add Starfire platform RTC driver. Signed-off-by: David S. Miller commit 84d6bd5ef79a6ccc21af97b870f6ef94fbc9b11e Author: David S. Miller Date: Fri Aug 29 01:34:27 2008 -0700 sparc64: Use generic sun4v RTC driver. Signed-off-by: David S. Miller commit 7a138ede551c5282c1b81d191bdd4aa989b119a8 Author: David S. Miller Date: Fri Aug 29 01:32:43 2008 -0700 rtc: Add Sun4V hypervisor RTC driver. Signed-off-by: David S. Miller commit 29b503f11cd648b3628be3a546f97da95a6670ce Author: David S. Miller Date: Thu Aug 28 21:54:34 2008 -0700 sparc64: Use generic BQ4802 RTC driver. Signed-off-by: David S. Miller commit cca4c231028405950a15f5a27d7326d18d909784 Author: David S. Miller Date: Fri Aug 29 01:29:53 2008 -0700 rtc: Add TI BQ4802 RTC driver. Signed-off-by: David S. Miller commit da86783dda5ad8c64b945157108d1ace7aa79bbf Author: David S. Miller Date: Thu Aug 28 22:16:15 2008 -0700 sparc64: Use generic CMOS driver. Based largely upon a patch by Krzysztof Helt Signed-off-by: David S. Miller commit e8b75c4fd6e3bec57d268b76a0a9a8f58f1612e3 Author: David S. Miller Date: Thu Aug 28 16:46:23 2008 -0700 sparc: asm/mostek.h is now 32-bit only No need for the 64-bit header version any more. Signed-off-by: David S. Miller commit 1518e7ed08019539498f772faa1f9368fed91361 Author: David S. Miller Date: Thu Aug 28 21:06:27 2008 -0700 sparc64: Convert Mostek rtc to use generic RTC layer driver. Based largely upon a patch by Krzysztof Helt Signed-off-by: David S. Miller commit a0b31b578f9ab34826703762113f9d42f3ae9819 Author: David S. Miller Date: Thu Aug 28 17:34:31 2008 -0700 sparc64: Check for RTC class device in update_persistent_clock(). As we convert the various by-hand sparc64 RTC drivers to use the generic RTC framework and drivers, we need to keep the NTP set_rtc_mmss() support via update_persistent_clock() working. In the end, after all the RTC device cases are converted, this local set_rtc_mmss() function will be deleted. Signed-off-by: David S. Miller commit 90de9dea3bfb80d0db9e6d1ff26f7ea7b2f1f0f5 Author: David S. Miller Date: Thu Aug 28 17:28:37 2008 -0700 sparc64: Select RTC_CLASS Signed-off-by: David S. Miller commit 582defd8ddb90448d72692a8e1d5b2966d2ed819 Author: David S. Miller Date: Thu Aug 28 19:54:17 2008 -0700 rtc: Allow RTC_DRV_CMOS to be used on SPARC. Add Sparc to the Kconfig depends list. Add __sparc___ to address_sparc = 128 ifdef. Finally, don't be concerned about 24-hour BCD mode support if the RTC doesn't have a valid IRQ. We won't even use the alarm code in this case and the Sparc RTCs have this limitation. Signed-off-by: David S. Miller commit 18c8adeb0244f823ba78a51e23f813fe68bc3c54 Author: Michael Buesch Date: Thu Aug 28 19:33:40 2008 +0200 b43: Rewrite TX power adjustment This patch rewrites the TX power recalculation algorithms to scale better with changed enviromnent. If there's low TX traffic, the power will be checked against the desired values every 60 seconds. If there is high TX traffic, the check is redone every 2 seconds. This improves the reaction times a lot and confuses the rate control less. It will also reduce the time it initially takes to tune to a new TX power value. With the old algorithm it could take about 30 to 45 seconds to settle to a new power value. This will happen in about two to four seconds now. Signed-off-by: Michael Buesch Signed-off-by: John W. Linville commit ef1a628d83fc0423c36e773281162be790503168 Author: Michael Buesch Date: Wed Aug 27 18:53:02 2008 +0200 b43: Implement dynamic PHY API This patch implements a dynamic "ops" based PHY API. This is needed in order to conveniently support future PHY types to avoid the "switch"-hell. This patch does not change any functionality. It just moves lots of code from one place to another and adjusts it for the changed data structures. Signed-off-by: Michael Buesch Signed-off-by: John W. Linville commit 35e032d82f3e2a9b0d92077b4fbc97166525ed53 Author: Ivo van Doorn Date: Fri Aug 29 21:07:22 2008 +0200 rt2x00: Release rt2x00 2.2.1 Signed-off-by: Ivo van Doorn Signed-off-by: John W. Linville commit 1abc3656e961e62218257a85b3fe0a90ccd9036c Author: Mattias Nissler Date: Fri Aug 29 21:07:20 2008 +0200 rt2x00: skb->data pointer should not include TX descriptor Make sure the skb->data pointer points to the frame data, not the TX descriptor. The frame dumping code relies on that. Signed-off-by: Mattias Nissler Signed-off-by: Ivo van Doorn Signed-off-by: John W. Linville commit 6c6aa3c004e702532cb0f549a96eb2f75636bd3b Author: Ivo van Doorn Date: Fri Aug 29 21:07:16 2008 +0200 rt2x00: Add Signal type flag Instead of using the PLCP flag to indicate if the signal value is plcp or the bitrate we should add a new flag to mark the bitrate type explicitely. This is usefull when new types are added later for rt2800. Signed-off-by: Ivo van Doorn Signed-off-by: John W. Linville commit 2af0a570b45ec315f364ea2c8a6d072cfcaa9d32 Author: Ivo van Doorn Date: Fri Aug 29 21:05:45 2008 +0200 rt2x00: Initialize txop during conf_tx() callback The txop parameter is supported by rt61pci and rt73usb, and thus should be written to the register instead of using the fixed value set during initialization. Signed-off-by: Ivo van Doorn Signed-off-by: John W. Linville commit 2575c11d6ee7266f0f035e55c5056b36597cd336 Author: Mattias Nissler Date: Fri Aug 29 21:05:21 2008 +0200 rt2x00: Only configure hardware when radio is enabled Some hardware configuration registers such as antenna and channel configuration can only be written when the radio is enabled. Previously, we didn't consider this, so some configuration items could be set inconsistently after reenabling the radio. This patch changes the config() handler to only reprogram the hardware when the radio is enabled. Configuration changes that are made while the radio is off are postponed until the radio is switched back on. We also leave the radio turned off during initialization and only enable it when requested by mac80211. This allows us to get rid of the DIRTY_CONFIG flag, because the device is now guaranteed to be completely initialized when brought up by mac80211. Signed-off-by: Mattias Nissler Signed-off-by: Ivo van Doorn Signed-off-by: John W. Linville commit 3ee54a07d34fd9b5c34bb1488113fb32be58e38f Author: Ivo van Doorn Date: Fri Aug 29 21:04:50 2008 +0200 rt2x00: Map extra_tx_headroom to DMA If a driver requests additional headroom it should be mapped to DMA as well because it will be send to the hardware as well (as form of extra descriptor). Signed-off-by: Ivo van Doorn Signed-off-by: John W. Linville commit 0262ab0df64a67d4c0ed7577a29b7d866819cc68 Author: Ivo van Doorn Date: Fri Aug 29 21:04:26 2008 +0200 rt2x00: Fix race conditions in flag handling Some of the flags should be accessed atomically to prevent race conditions. The flags that are most important are those that can change often and indicate the actual state of the device, queue or queue entry. The big flag rename was done to move all state flags to the same naming type as the other rt2x00dev flags and made sure all places where the flags were used were changed. ;) Thanks to Stephen for most of the queue flags updates, which fixes some of the most obvious consequences of the race conditions. Among those the notorious: rt2x00queue_write_tx_frame: Error - Arrived at non-free entry in the non-full queue 0. rt2x00queue_write_tx_frame: Error - Arrived at non-free entry in the non-full queue 0. rt2x00queue_write_tx_frame: Error - Arrived at non-free entry in the non-full queue 0. Signed-off-by: Stephen Blackheath Signed-off-by: Ivo van Doorn Signed-off-by: John W. Linville commit de9cc7a4e6f975ca5e91cf8745b3e35a7e780bae Author: Harvey Harrison Date: Mon Aug 25 14:06:32 2008 -0700 libertas: use the common frame control functions Signed-off-by: Harvey Harrison Signed-off-by: John W. Linville commit 15635744484d4255778fc641261be27179c51f9a Author: Henrique de Moraes Holschuh Date: Tue Aug 26 11:58:00 2008 -0300 rfkill: rename rfkill_mutex to rfkill_global_mutex rfkill_mutex and rfkill->mutex are too easy to confuse with each other. Rename rfkill_mutex to rfkill_global_mutex, so that they are easier to tell apart with just one glance. Signed-off-by: Henrique de Moraes Holschuh Acked-by: Ivo van Doorn Cc: Michael Buesch Signed-off-by: John W. Linville commit f745ba03a12a1c4b98a88a96ab39d9b58ac677a2 Author: Henrique de Moraes Holschuh Date: Tue Aug 26 11:57:59 2008 -0300 rfkill: add WARN and BUG_ON paranoia (v2) BUG_ON() and WARN() the heck out of buggy drivers calling into the rfkill subsystem. Also switch from WARN_ON(1) to the new descriptive WARN(). Signed-off-by: Henrique de Moraes Holschuh Acked-by: Ivo van Doorn Cc: Johannes Berg Signed-off-by: John W. Linville commit 01b510b9c29caf2134c31d2bc8c2c5cc73987eb6 Author: Felipe Balbi Date: Tue Aug 26 11:57:58 2008 -0300 rfkill: add missing line break Trivial patch adding a missing line break on rfkill_claim_show(). Signed-off-by: Felipe Balbi Acked-by: Henrique de Moraes Holschuh Acked-by: Ivo van Doorn Signed-off-by: John W. Linville commit 849e0576a76bc421aacd782f97948856f487726c Author: Henrique de Moraes Holschuh Date: Tue Aug 26 11:57:57 2008 -0300 rfkill: use strict_strtoul (v2) Switch sysfs parsing to something that actually works properly. Signed-off-by: Henrique de Moraes Holschuh Acked-by: Ivo van Doorn Signed-off-by: John W. Linville commit 5701ed843ea87bf8a1d2c4dee5edcb463558db4a Author: Sujith Date: Tue Aug 26 08:11:26 2008 +0530 ath9k: rc.h cleanup Use kernel doc syntax for comments and remove a few unused macros. Signed-off-by: Sujith Manoharan Signed-off-by: John W. Linville commit 1fe1132bad8e98fa34cfb4a3901340d1214b95d7 Author: Sujith Date: Tue Aug 26 08:11:06 2008 +0530 ath9k: Remove sc_lastrx as we don't use it anywhere Signed-off-by: Sujith Manoharan Signed-off-by: John W. Linville commit 14cc709f338f44f1ff69fa0b0e35e9de3ee62eb5 Author: Sujith Date: Tue Aug 26 08:10:49 2008 +0530 ath9k: Do not update frame's duration field When AR_DurUpdateEna is set, the frame's duration field is updated by the MAC based on the current rate. Signed-off-by: Sujith Manoharan Signed-off-by: John W. Linville commit 822ceaefaaaea4bcd7965e3f4b3479e805f7dfa5 Author: Sujith Date: Tue Aug 26 08:10:29 2008 +0530 ath9k: Remove more dead code Signed-off-by: Sujith Manoharan Signed-off-by: John W. Linville commit c83be6885e2f1ee6e0b290b6cfc82014c675e087 Author: Vasanthakumar Thiagarajan Date: Mon Aug 25 20:47:29 2008 +0530 ath9k: Add LED support Signed-off-by: Vasanthakumar Thiagarajan Signed-off-by: John W. Linville commit 36aedc903ea11a4188de0a118d26c9f20afdd272 Author: Jouni Malinen Date: Mon Aug 25 11:58:58 2008 +0300 mac80211/cfg80211: HT capabilities for NEW_STA Allow userspace (e.g., hostapd) to set HT capabilities for associated STAs. This is based on a patch from Zhu Yi (only the NL80211_ATTR_HT_CAPABILITY for NEW_STA part is included here). Signed-off-by: Jouni Malinen Signed-off-by: John W. Linville commit 7262d59366f972b898ea134639112d34bcac35b3 Author: Christian Lamparter Date: Sun Aug 24 22:30:38 2008 +0200 p54pci: rx tasklet refactoring This patch moves the all of p54pci's receiver code out of the bloated interrupt handler routine and into a less critical tasklet. Signed-off-by: Christian Lamparter Signed-off-by: John W. Linville commit 84df3ed30b72c3516d72bc9734d4425746b15dfc Author: Chr Date: Sun Aug 24 03:15:16 2008 +0200 p54: redo queue numbering The firmware supports 8 different queues and not only 4. So, let's make some room for further tasks (ap/adhoc support) in this area. Signed-off-by: Christian Lamparter Signed-off-by: John W. Linville commit 031d10ee5a6df5aba6b4ac8bb01dd023cd5efc02 Author: Chr Date: Sun Aug 24 03:15:06 2008 +0200 p54: take tx_queue's lock in rx_frame_sent p54_rx_frame_sent will alter the tx_queue. Therefore we should hold the lock to protect against concurrent p54_assign_address calls. Signed-off-by: Christian Lamparter Signed-off-by: John W. Linville commit 154e3af17fdce617605b63f3534dac2c10c90922 Author: Christian Lamparter Date: Sat Aug 23 22:15:25 2008 +0200 p54: fix rssi auto calibration Ever wondered why the signal was so bad with p54 compared to madwifi, or intel? Well, if you have revision 1 rssi calibration curve points in your EEPROM, then wonder no more. The firmware wants a extra 1 byte padding for every curve point. But someone forgot to put them into the EEPROM's data structure... So now, big question: what happens when we blindly "memcpy" these data points? Signed-off-by: Christian Lamparter Signed-off-by: John W. Linville commit a3ec233c90f0b8a5c00bf182f2c3ea9119b46caa Author: Huang Weiyi Date: Sat Aug 23 13:56:25 2008 +0800 wireless: remove unused #include The driver(s) below do not use LINUX_VERSION_CODE nor KERNEL_VERSION. drivers/net/wireless/b43legacy/main.c drivers/net/wireless/iwlwifi/iwl-3945-led.c drivers/net/wireless/iwlwifi/iwl-led.c drivers/net/wireless/iwlwifi/iwl-rfkill.c This patch removes the said #include . Signed-off-by: Huang Weiyi Signed-off-by: John W. Linville commit e022edbd2bfb5f9a7ddf1cca43544f7b54c6fe02 Author: Jouni Malinen Date: Fri Aug 22 17:31:33 2008 +0300 ath9k: Use mac80211 for multicast power save buffering Replace the internal ath9k implementation of multicast/broadcast frame power save buffering (AP mode) in ath9k with use of mac80211 ieee80211_get_buffered_bc() mechanism. This removes quite a bit of duplicated functionality and simplifies the driver part. Signed-off-by: Jouni Malinen Signed-off-by: John W. Linville commit 87e8b64e6856a41c5204a22c47cc14b1b0b57332 Author: Jouni Malinen Date: Thu Aug 21 21:45:56 2008 +0300 mac80211_hwsim: Add minimal IEEE 802.11n support Set some semi-random values for HT and add more queues to allow IEEE 802.11n association to be tested with mac80211_hwsim. This with the latest hostapd git tree version can complete a simulated 802.11n association successfully (with mac80211 client MLME). Signed-off-by: Jouni Malinen Signed-off-by: John W. Linville commit 31ce12fb3ebf88b054deb99ad729e84888bf6125 Author: Larry Finger Date: Wed Aug 20 17:45:06 2008 -0500 ssb: Clean up extraction of MAC addresses from SPROM Only rev 1 and 2 ssb SPROMs have fields named et0mac and et1mac; however, all of the extraction routines extract pseudo data for these fields from regions that are all 1's resulting in a hardware address of FF:FF:FF:FF:FF:FF. This patch forces such a fill at the beginning of the data extraction process, and only does the formal extraction if the SPROM rev is 1 or 2. Signed-off-by: Larry Finger Signed-off-by: John W. Linville commit f5fe1fdaae86a74d6977fafd8fdd8697e398dafd Author: Dan Williams Date: Thu Aug 21 21:46:59 2008 -0400 libertas: convert adhoc operations to direct commands with fixes for v9 and later firmware too. Signed-off-by: Dan Williams Signed-off-by: John W. Linville commit d5db2dfa660de13c3643149b89c7602dd49aa168 Author: Dan Williams Date: Thu Aug 21 17:51:07 2008 -0400 libertas: convert CMD_802_11_RADIO_CONTROL to a direct command and return errors for operations like join & scan that aren't possible when the radio is turned off. Signed-off-by: Dan Williams Signed-off-by: John W. Linville commit 191bb40e725304c5fcfabd92c57eef58799f0e25 Author: Dan Williams Date: Thu Aug 21 17:46:18 2008 -0400 libertas: convert CMD_802_11_DEAUTHENTICATE to a direct command and remove DISASSOCIATE because it's not in any of the specs and has never been used. Signed-off-by: Dan Williams Signed-off-by: John W. Linville commit 87c8c72d532f96257162f978d5945dcf7f0df19e Author: Dan Williams Date: Tue Aug 19 15:15:35 2008 -0400 libertas: convert CMD_802_11_RF_TX_POWER to a direct command And while we're at it, grab min/max TX power from the firmware and use that to validate incoming TX power requests from WEXT. Signed-off-by: Dan Williams Signed-off-by: John W. Linville commit 095f695cbb07281682462da0618fffabb499d0be Author: Larry Finger Date: Tue Aug 19 12:50:31 2008 -0500 ssb: Update for Rev. 5 SPROM Although a revision 5 SPROM has not been seen in the wild, the open-source portion of the MIPS driver 4.150.10.5 describes its layout, which is mostly inherited from revision 4. This patch implements the differences. Signed-off-by: Larry Finger Acked-by: Michael Buesch Signed-off-by: John W. Linville commit 2f58bbf27fe5321a7a208be9071efc54e8a8a3bd Author: Daniel Wagner Date: Tue Aug 19 15:44:35 2008 +0200 mac80211: Use only precedence level of DSCP field for frame classification Bit 4-5 of DSCP should not be considered by classify_d1. The 802.11 QoS Priority field is only depending on the precedence level. Signed-off-by: Daniel Wagner Signed-off-by: John W. Linville commit 43ac2ca3840f64f699a239535c590fa7ebaaac27 Author: Jouni Malinen Date: Fri Aug 15 22:21:27 2008 +0300 mac80211: Handle scan result IEs in one block Clean up and extend scan result processing by storing all the IEs from Beacon/Probe Response frames in a single block instead of allocating memory for each specific IE separately. This removes lot of unnecessary code and automatically supports reporting of new IEs (e.g., IEEE 802.11r) into user space without need to manually extend mac80211 scanning code whenever a new protocol adds IE(s). Signed-off-by: Jouni Malinen Signed-off-by: John W. Linville commit 19b73c7f68fb2eeb180eafa70f9859409ec9aa08 Author: Sujith Date: Thu Aug 14 13:28:20 2008 +0530 ath9k: Add IEEE80211_HW_RX_INCLUDES_FCS to hw flags Don't trim the FCS before passing the frame to mac80211, move TSF_TO_TU to core.h and delete more unused macros. Signed-off-by: Sujith Manoharan Signed-off-by: John W. Linville commit 60653678939dcbba3aa936250b58179aa3451eee Author: Sujith Date: Thu Aug 14 13:28:02 2008 +0530 ath9k: Use definition from ieee80211.h Also, Max RX-ampdu and mpdu-density are ath9k specific. Rename appropriately. Signed-off-by: Sujith Manoharan Signed-off-by: John W. Linville commit 18d7c65ba6628d2759bd650e7039d6307f2c99e9 Author: Sujith Date: Thu Aug 14 13:27:41 2008 +0530 mac80211: Add an 802.11n definition This patch adds a HT Capability (DSSS/CCK Mode in 40MHz BSS) definition to ieee80211.h Signed-off-by: Sujith Manoharan Signed-off-by: John W. Linville commit ff9b662dab1fcd885fb728de3a8c13ebb5455117 Author: Sujith Date: Thu Aug 14 13:27:16 2008 +0530 ath9k: Miscellaneous fixes This patch removes ath_vap_listen() and dma wrapper macros. Also, Inline abuse is cleaned up and a few typos are fixed. Signed-off-by: Sujith Manoharan Signed-off-by: John W. Linville commit dc2222a85fd63103b9aad0d4b77c4d87b78c58a2 Author: Sujith Date: Thu Aug 14 13:26:55 2008 +0530 ath9k: Random cleanup Remove dead code, add newlines, fix indentation. Signed-off-by: Sujith Manoharan Signed-off-by: John W. Linville commit 927e70e9244e6ecdc7c28bc5424b0b8c11dee314 Author: Sujith Date: Thu Aug 14 13:26:34 2008 +0530 ath9k: Remove remaining occurences of ath_skb_map functions Use direct pci functions instead. Also, use sc_ht_info.tx_chan_width directly and remove ath_cwm_macmode. Signed-off-by: Sujith Manoharan Signed-off-by: John W. Linville commit b14ecdd0afa4f616fcd1fcff4b902e15334256c7 Author: Jouni Malinen Date: Mon Aug 11 14:01:51 2008 +0300 ath9k: Fix TX control flag use for no ACK and RTS/CTS Signed-off-by: Jouni Malinen Signed-off-by: John W. Linville commit 147583c057c43095925b5f331fe304f2d5b997ba Author: Jouni Malinen Date: Mon Aug 11 14:01:50 2008 +0300 ath9k: Assign seq# when mac80211 requests this Use TX control flag IEEE80211_TX_CTL_ASSIGN_SEQ as a request to update the seq# for the frames. This will likely require some further cleanup to get seq# correctly for Beacons vs. other frames and also potentially for multiple BSSes. Anyway, this is better than ending up sending out most frames with seq# 0. Signed-off-by: Jouni Malinen Signed-off-by: John W. Linville commit 580f0b8a6dc1cb4d32c351a507d1c1d319bdc1eb Author: Jouni Malinen Date: Mon Aug 11 14:01:49 2008 +0300 ath9k: Fix TX status reporting Signed-off-by: Jouni Malinen Signed-off-by: John W. Linville commit a8fff50e4d6aad520b261b3c32e2c67a7dfb7228 Author: Jouni Malinen Date: Mon Aug 11 14:01:48 2008 +0300 ath9k: Updated Beacon generation to use mac80211-style This change moves ath9k to use mac80211-generated Beacon frames instead of trying to allocate a single Beacon frame and then update it. In addition, the remaining ath_skb_{map,unmap}_single() wrapper calls are replaced with direct pci_{map,unmap}_single() calls in beacon.c. Power save buffering for multicast/broadcast frames is not yet converted to use mac80211-style (frames to be buffered inside mac80211, not in driver). Signed-off-by: Jouni Malinen Signed-off-by: John W. Linville commit 2ad67de3c8a21354b8b2721d5d2baabb7c5013c9 Author: Jouni Malinen Date: Mon Aug 11 14:01:47 2008 +0300 ath9k: Allow AP mode to be enabled Signed-off-by: Jouni Malinen Signed-off-by: John W. Linville commit 98deeea0b3464955ec416c30cbd0c3d21cacfa9a Author: Sujith Date: Mon Aug 11 14:05:46 2008 +0530 ath9k: Trim struct ath_softc Add sc_rxflush and sc_noreset as bitfields to sc_flags. Remove a few variables and function prototypes that are unused. Signed-off-by: Sujith Manoharan Signed-off-by: John W. Linville commit 7c56d24bc80112daadc7ef54247a5fc8397dbc5c Author: Sujith Date: Mon Aug 11 14:05:26 2008 +0530 ath9k: Use ah_curchan and remove sc_curchan which is redundant Signed-off-by: Sujith Manoharan Signed-off-by: John W. Linville commit 672840ac04f79f499b60b9f0eb41799c837db4eb Author: Sujith Date: Mon Aug 11 14:05:08 2008 +0530 ath9k: Use bitfields for sc operations Signed-off-by: Sujith Manoharan Signed-off-by: John W. Linville commit b4696c8b9233bea812b972a5e79c5db7ecf13867 Author: Sujith Date: Mon Aug 11 14:04:52 2008 +0530 ath9k: Use a single opmode variable ah_opmode and sc_opmode are redundant. This patch removes sc_opmode. Signed-off-by: Sujith Manoharan Signed-off-by: John W. Linville commit 6a2b9e8c8f4be9954933051719b312adcfb7263d Author: Sujith Date: Mon Aug 11 14:04:32 2008 +0530 ath9k: Unused macros, variables Signed-off-by: Sujith Manoharan Signed-off-by: John W. Linville commit d2d80ee9c6ae3d60bcbffb200959db645f5a558f Author: Sujith Date: Mon Aug 11 14:04:13 2008 +0530 ath9k: Remove ar5416hal and assign default values directly Signed-off-by: Sujith Manoharan Signed-off-by: John W. Linville commit 556bb8f141d702a84281064751a3242359a9f257 Author: Sujith Date: Mon Aug 11 14:03:53 2008 +0530 ath9k: Remove a few unnecessary macros Signed-off-by: Sujith Manoharan Signed-off-by: John W. Linville commit cd3d39a6875507f4f4d585391fe3d344f0b64b5c Author: Sujith Date: Mon Aug 11 14:03:34 2008 +0530 ath9k: Use bitfields for buffer type Signed-off-by: Sujith Manoharan Signed-off-by: John W. Linville commit 7dcfdcd908a4540512aaf06b2b35e8c8a084fb69 Author: Sujith Date: Mon Aug 11 14:03:13 2008 +0530 ath9k: RX Filter cleanup Signed-off-by: Sujith Manoharan Signed-off-by: John W. Linville commit f45144ef412422edf8018825328768e3db3ea45b Author: Sujith Date: Mon Aug 11 14:02:53 2008 +0530 ath9k: Merge reset functions Signed-off-by: Sujith Manoharan Signed-off-by: John W. Linville commit 9f1ba9062e032fb7b395cd27fc564754fe4e9867 Author: Jouni Malinen Date: Thu Aug 7 20:07:01 2008 +0300 mac80211/cfg80211: Add BSS configuration options for AP mode This change adds a new cfg80211 command, NL80211_CMD_SET_BSS, to allow AP mode BSS parameters to be changed from user space (e.g., hostapd). The drivers using mac80211 are expected to be modified with separate changes to use the new BSS info parameter for short slot time in the bss_info_changed() handler. Signed-off-by: Jouni Malinen Acked-by: Johannes Berg Signed-off-by: John W. Linville commit 7f93ea3e246db512c0c17b79847f57dd3a2891e1 Author: Johannes Berg Date: Wed Aug 6 21:45:26 2008 +0200 mac80211: fill start-sequence-number for BA session start Otherwise, drivers are required to keep track of the sequence numbers themselves, and they really shouldn't be since we already do it for them. I'll fix the race once we figure out how this code should work at all, it's currently disabled. Signed-off-by: Johannes Berg Signed-off-by: John W. Linville commit c1ea793b25be242a5db90d9c743455ab33e6d16c Author: Takashi Iwai Date: Fri Aug 29 16:17:25 2008 +0200 ALSA: ice1724 - limit channels for multi-channel playback Limit the available channels for multi-channel playback device to the real number of channels. Until now, always up to 8 channels are created, which are simply useless without the real outputs. Signed-off-by: Takashi Iwai commit a90e68f4d786dfffae61e10c6d18da401eac3447 Author: Chuck Lever Date: Wed Aug 27 16:57:46 2008 -0400 SUNRPC: Make svc_addr's argument a constant Clean up: Add extra type safety and squelch a few compiler complaints in upcoming patches. Signed-off-by: Chuck Lever Signed-off-by: J. Bruce Fields commit 72593c04f26bf91bb3401282fda281f18eec9b81 Author: Chuck Lever Date: Wed Aug 27 16:57:38 2008 -0400 lockd: Add address family-agnostic helper for zeroing the port number Signed-off-by: Chuck Lever Signed-off-by: J. Bruce Fields commit b076d6cb537d296aa003ce6b67928fbc8b0b7e6b Author: Chuck Lever Date: Wed Aug 27 16:57:31 2008 -0400 lockd: Specify address family for source address Make sure an address family is specified for source addresses passed to nlm_lookup_host(). nlm_lookup_host() will need this when it becomes capable of dealing with AF_INET6 addresses. Signed-off-by: Chuck Lever Signed-off-by: J. Bruce Fields commit 7fd1c8a663c76e807c3e3559fddb4bfffc147f80 Author: Chuck Lever Date: Wed Aug 27 16:57:23 2008 -0400 lockd: address-family independent printable addresses Knowing which source address is used for communicating with remote NLM services can be helpful for debugging configuration problems on hosts with multiple addresses. Keep the dprintk debugging here, but adapt it so it displays AF_INET6 addresses properly. There are also a couple of dprintk clean-ups as well. At some point we will aggregate the helpers that display presentation format addresses into a single set of shared helpers. Signed-off-by: Chuck Lever Signed-off-by: J. Bruce Fields commit 61b4606d1905243d7be99e9f247914dda1fdcf98 Author: Chuck Lever Date: Wed Aug 27 16:57:15 2008 -0400 NLM: Clean up before introducing new debugging messages We're about to introduce some extra debugging messages in nlm_lookup_host(). Bring the coding style up to date first so we can cleanly introduce the new debugging messages. Signed-off-by: Chuck Lever Signed-off-by: J. Bruce Fields commit 97fe3e6dc415be4b63c12b6bfe3d6cb1d56ab627 Author: Vedran Miletic Date: Fri Aug 29 18:31:13 2008 +0200 ALSA: ice1724: Enable MIDI on TerraTec PHASE 22 and PHASE 28 Even though MIDI was fixed on ice1724 chips a while ago, it wasn't yet enabled for some cards as it didn't get enough testing. This was tested with MIDI keyboard on PHASE 22 and with looping back output to input and it works stable, so it's safe to enable it. Besides this, there are some more minor fixes, not exactly user visible: * added info about PHASE 28 (collected, as I don't have a card) * added info about TS22PCI and new revisions of PHASE 22 * disable 192k on PHASE 22 as AK4524 I2S doesn't support it * enable SPDIF reciever on PHASE 22 Signed-off-by: Vedran Miletic Signed-off-by: Takashi Iwai commit 01b291bd66564b4bd826326af6bd0b6d17e99439 Author: James Bottomley Date: Thu Aug 21 15:14:14 2008 -0500 [SCSI] fix check of PQ and PDT bits for WLUNs For IBM z series certain LUNs can no longer be accessed. This is because kernel version 2.6.19 a check was introduced not to create a generic SCSI device for devices that return PQ=1 and PDT=0x1f. For WLUNs (see SAM-3, p. 41ff) generic SCSI devices should be created unconditionally without looking at the PQ bit, so add a check for WLUNs in with this test. Acked-by: Martin Petermann Signed-off-by: James Bottomley commit bb0003c1e189d5766b6b39299b08c690c985c4dc Author: Mike Anderson Date: Tue Aug 12 12:11:58 2008 -0700 [SCSI] make scsi_check_sense HARDWARE_ERROR return ADD_TO_MLQUEUE on retry Change scsi_check_sense HARDWARE_ERROR check to return ADD_TO_MLQUEUE if device->retry_hwerror is set to allow retries to occur without restriction of blk_noretry_request check. Signed-off-by: Mike Anderson Signed-off-by: James Bottomley commit c7dbb627a2505f42b2e6b3581f3716d73453dd0c Author: Mike Anderson Date: Tue Aug 12 12:11:57 2008 -0700 [SCSI] scsi_dh: make check_sense return ADD_TO_MLQUEUE Change scsi_dh check_sense functions to return ADD_TO_MLQUEUE to allow retries to occur without restriction of blk_noretry_request check. Signed-off-by: Mike Anderson Acked-by: Chandra Seetharaman Signed-off-by: James Bottomley commit 025270f0eaa2def673747ed6f77cca41f694f354 Author: Hirofumi Nakagawa Date: Thu Aug 21 13:43:37 2008 +0200 [SCSI] zfcp: Remove duplicated unlikely() macros. Some drivers have duplicated unlikely() macros. IS_ERR() already has unlikely() in itself. This patch cleans up such pointless codes although there is no real effect on the kernel's behaviour. Signed-off-by: Hirofumi Nakagawa Signed-off-by: Christof Schmitt Signed-off-by: James Bottomley commit 6139308dca9437975125290698cb9306240f525c Author: Swen Schillig Date: Thu Aug 21 13:43:36 2008 +0200 [SCSI] zfcp: channel cannot be detached due to refcount imbalance Due to an imbalance of the nameserver refcounting, channel devices couldn't be take offline anymore after the channel was activated. Signed-off-by: Swen Schillig Signed-off-by: Christof Schmitt Signed-off-by: James Bottomley commit 9528539cc2d506aa232b0d93881ac4d19738752f Author: Swen Schillig Date: Thu Aug 21 13:43:35 2008 +0200 [SCSI] zfcp: Fix reference counter for remote ports Fix the remote port reference counter handling during ELS ADISC commands and find the remote port by WWPN not by D_IDs that could change. Signed-off-by: Swen Schillig Signed-off-by: Christof Schmitt Signed-off-by: James Bottomley commit f48bf7fb00f74d93105ba69522a3f6c9435d6af3 Author: Christof Schmitt Date: Thu Aug 21 13:43:34 2008 +0200 [SCSI] zfcp: Simplify ccw notify handler The notify handler does not change the list of adapters, it only triggers erp actions to open or shutdown the adapter. We don't need to hold the config semaphore and wait for the erp to complete. This is a prerequisite for a fix in the s390 common i/o code. Signed-off-by: Christof Schmitt Signed-off-by: Martin Petermann Signed-off-by: James Bottomley commit 47f7bba52b01dd881fbd17b4b50c89ecf186eee2 Author: Christof Schmitt Date: Thu Aug 21 13:43:33 2008 +0200 [SCSI] zfcp: Correctly query end flag in gpn_ft response When the last port entry in the gpn_ft response is already a known port, the eval function would skip the end flag and try to attach ports with wwpn 0. Fix this by checking the flag first. Signed-off-by: Christof Schmitt Signed-off-by: Martin Petermann Signed-off-by: James Bottomley commit d4538817287e56abc938900886301a5bdfafbfcd Author: Christof Schmitt Date: Thu Aug 21 13:43:32 2008 +0200 [SCSI] zfcp: Fix request queue locking The request queue lock can be acquired from softirq context when the SCSI midlayer issues commands. Disable softirqs for this lock when commands are issued from zfcp. Signed-off-by: Christof Schmitt Signed-off-by: Martin Petermann Signed-off-by: James Bottomley commit bfad9ceac5d11318c99ae8a0d1e926a380a56edd Author: Stefan Richter Date: Sat Aug 2 19:49:40 2008 +0200 [SCSI] sd: select CRC_T10DIF only when necessary Signed-off-by: Stefan Richter Acked-by: "Martin K. Petersen" Signed-off-by: James Bottomley commit 29a060e9a5a47a6cfb7cb0f5632790e3fcc1eb72 Author: Maximilian Rehkopf Date: Fri Aug 29 14:11:10 2008 +0200 ALSA: ice1724: enable MIDI on Terratec Aureon 7.1 Universe This enables MIDI on Terratec Aureon 7.1 Universe cards specifically. Apparently the other envy24ht-based Aureon cards do not have MIDI ports, hence I added a Universe specific eeprom array. The newer cards (Aureon 7.1 PCI / 5.1 PCI/Fun) have MIDI but use a CMI DSP so this driver does not concern them at all. Signed-off-by: Maximilian Rehkopf Signed-off-by: Takashi Iwai commit 95e20ca4ba14447b0bff165132651822f6a2aa9f Author: Atsushi Nemoto Date: Fri Aug 29 07:02:39 2008 -0500 kgdb: kgdboc console poll hooks for serial_txx9 uart Implement the serial polling hooks for the serial_txx9 uart for use with kgdboc. Signed-off-by: Atsushi Nemoto Signed-off-by: Jason Wessel commit 6e2feb2f1eef523ac728015506d2a5780a2cb319 Author: Jason Wessel Date: Fri Aug 29 07:02:38 2008 -0500 kgdboc,tty: Fix tty polling search to use name correctly The tty_find_polling_driver() routine did not correctly check the base part of the tty name. This can lead to kgdboc selecting an incorrect driver, as well as accepting a completely invalid tty such as "echo ffff0 > /sys/module/kgdboc/parameters/kgdboc". Signed-off-by: Jason Wessel commit ee98a63d4ad1a18614e44a7c7c47b5e71fb8cdeb Author: Christian Borntraeger Date: Fri Aug 29 13:30:56 2008 +0200 KVM: s390: change help text of guest Kconfig The current help text for CONFIG_S390_GUEST is not very helpful. Lets add more text. Signed-off-by: Christian Borntraeger Signed-off-by: Avi Kivity commit f5c9467dbee5473402f3573d87c04e854925281d Author: Christian Borntraeger Date: Fri Aug 29 13:29:45 2008 +0200 KVM: s390: Make facility bits future-proof Heiko Carstens pointed out, that its safer to activate working facilities instead of disabling problematic facilities. The new code uses the host facility bits and masks it with known good ones. Signed-off-by: Christian Borntraeger Signed-off-by: Avi Kivity commit b9f286560c0349d37cfe594d48a426ad0d97dfac Author: Joerg Roedel Date: Fri Aug 29 11:52:07 2008 +0200 KVM: add MC5_MISC msr read support Currently KVM implements MC0-MC4_MISC read support. When booting Linux this results in KVM warnings in the kernel log when the guest tries to read MC5_MISC. Fix this warnings with this patch. Signed-off-by: Joerg Roedel Signed-off-by: Avi Kivity commit ab4f95bd258d2cdf5a6011b2dac2d0a2c70dfc93 Author: Haavard Skinnemoen Date: Wed Aug 20 15:46:24 2008 +0200 avr32: Fix lockup after Java stack underflow in user mode When using the Java Extension Module hardware, a Java stack underflow or overflow trap may cause the system to enter an infinite exception loop. Although there's no kernel support for the Java hardware yet, we need to be able to recover from this situation and keep the system running. This patch adds code to detect and fixup this situation in the critical exception handler and terminate the faulting process. We may have to rethink how to handle this more gracefully when the necessary kernel support for hardware-accelerated Java is added. Reported-by: Guennadi Liakhovetski Signed-off-by: Haavard Skinnemoen commit 5c4b69b8f7e0240ed638814d354da27383f6e510 Author: Harvey Harrison Date: Tue Aug 12 17:26:35 2008 -0700 avr32: use the new byteorder headers Signed-off-by: Harvey Harrison [haavard.skinnemoen@atmel.com: fix build breakage] Signed-off-by: Haavard Skinnemoen commit 0c0db98b50ed1217c0dbf4051722034ba314d06e Author: David S. Miller Date: Wed Aug 27 19:59:48 2008 -0700 sparc: Remove Documentation/sparc/sbus_drivers.txt None of the text in this document is relevant any more. Signed-off-by: David S. Miller commit 7eb1aae555663118f8d81bb26dca896d9cd8166c Author: David S. Miller Date: Wed Aug 27 05:04:18 2008 -0700 sparc: Delete asm/sbus*.h No longer used. Signed-off-by: David S. Miller commit 9dc69230a96a84ca8e6eef89cd34fad0dd8a1a09 Author: David S. Miller Date: Wed Aug 27 19:54:01 2008 -0700 sparc: Kill now spurious includes of sbus.h In order to make this week I also had to add an include of linux/dma-mapping.h to asm/pci_32.h because drivers/pci/pci.c really depends upon getting this header somehow. Signed-off-by: David S. Miller commit 0ad626a2a4c3d8e565b3a6f10eeda5b43560fbdb Author: David S. Miller Date: Tue Aug 26 21:14:05 2008 -0700 sparc32: Kill iounit_map_dma_*(). Unused. Signed-off-by: David S. Miller commit 47a2d7288538e7f334a0be318317b138f0e3dfbe Author: David S. Miller Date: Wed Aug 27 19:45:20 2008 -0700 sparc: Kill sbus_bus_type. No longer used. Signed-off-by: David S. Miller commit 046e26a8ba10b8ceff822f8d91451ab6c1e08c4e Author: David S. Miller Date: Wed Aug 27 04:54:04 2008 -0700 sparc: Remove generic SBUS probing layer. The individual SBUS IOMMU arch code now sets the IOMMU information directly into the OF device objects. Signed-off-by: David S. Miller commit 5059625ed8862e897760b86effff0f8a35989c0d Author: David S. Miller Date: Wed Aug 27 04:22:37 2008 -0700 sparc: Add OF archdata propagation helper. Add a helper function that, given a bus of_device node, propagates all iommu, stc, and host_controller values down to the child nodes. Signed-off-by: David S. Miller commit f8e4d32cb5153a9d6a8e8864e357dad1349f3b85 Author: David S. Miller Date: Wed Aug 27 04:20:14 2008 -0700 sparc: Kill sbus_arch_preinit(). 32-bit sparc just needed it to register the ioport procfs bits, do this via an arch_initcall() instead. Signed-off-by: David S. Miller commit d32bcdd7a90f19bc067a272b353800108d092c5e Author: David S. Miller Date: Wed Aug 27 04:18:55 2008 -0700 sparc32: Kill sbus_is_slave(). Unused. Signed-off-by: David S. Miller commit c6e5f661eee0ff62e7fdb263cfeee73c20dd6e99 Author: David S. Miller Date: Wed Aug 27 04:18:02 2008 -0700 sparc: Kill OBP property members of sbus_dev and sbus_bus Unused. Signed-off-by: David S. Miller commit 9b9644c6d91e9fd8edecba3ae57a35285cfce9db Author: David S. Miller Date: Wed Aug 27 04:17:24 2008 -0700 sparc: Kill sbus_devaddr() and sbus_dev_slot(). Unused. Signed-off-by: David S. Miller commit 615deeb27b7c3f51b464b47e8b9a8e433ab2d0ca Author: David S. Miller Date: Wed Aug 27 04:11:16 2008 -0700 sparc: Kill sbus_ioremap() and sbus_iounmap(). No more users. Signed-off-by: David S. Miller commit 454eeb2dd7bd0418451ea33a606d0fa50aa36718 Author: David S. Miller Date: Wed Aug 27 04:05:35 2008 -0700 sparc: Convert remaining sbus_ioremap() and sbus_iounmap() users. Use of_ioremap() and of_iounmap() instead. Signed-off-by: David S. Miller commit 98261dd1a393777f4400d8ad5a29e97cb30e5422 Author: David S. Miller Date: Wed Aug 27 03:47:56 2008 -0700 sparc: Remove dinky old-style SBUS probing facilities. No drivers or code uses this stuff any more, every driver has been converted over to OF device probing. Signed-off-by: David S. Miller commit 104364810ff5b0844a2183fbca989f70e86d486b Author: David S. Miller Date: Wed Aug 27 03:38:42 2008 -0700 sparc: Remove SBUS layer resource and irq handling. All the drivers use OF device objects now for this information. Signed-off-by: David S. Miller commit 33c4655c00e6af3ec4023f2cafd63dd4a42de49b Author: David S. Miller Date: Wed Aug 27 02:56:39 2008 -0700 sparc: Kill SBUS layer IRQ hooks. IRQs are obtained by drivers from the of_device struct. Signed-off-by: David S. Miller commit 71d3721189c0f4fad105a81e052bddfb826b693b Author: David S. Miller Date: Wed Aug 27 02:50:57 2008 -0700 sparc32: Convert sun4d IRQ code to use generic device tree probing. Signed-off-by: David S. Miller commit f1b6aa87b7eb8573d04f8cb21574fe565e86a380 Author: David S. Miller Date: Wed Aug 27 02:48:26 2008 -0700 sparc32: Convert pmc to OF driver. Signed-off-by: David S. Miller commit 7e7e2f035663c5ceb029bfb9d91e75099b0a5625 Author: David S. Miller Date: Wed Aug 27 02:45:36 2008 -0700 sparc32: Convert apc to OF driver. Signed-off-by: David S. Miller commit 4b1c5df2af38b2681b7c1a058534d17c54aaf6cf Author: David S. Miller Date: Wed Aug 27 18:40:38 2008 -0700 sparc32: Make mmu_map_dma_area and mmu_unmap_dma_area take a device pointer. This lets us kill this "map it in every IOMMU" crazy code, and also some of the final references to sbus_root. Signed-off-by: David S. Miller commit b1387c35bef6da55f6f2c27dfb748c86a4ef7ef9 Author: David S. Miller Date: Wed Aug 27 02:29:50 2008 -0700 sparc32: Kill mmu_translate_dvma and implementations. No longer used. Signed-off-by: David S. Miller commit aba945e76b9caeae5b6cfff179ca7bebb9bac805 Author: David S. Miller Date: Wed Aug 27 02:20:35 2008 -0700 sparc32: Kill mmu_translate_dvma() usage. Just simply use virt_to_page() on the provided virtual address pointer. Kill #if 0'd code. Signed-off-by: David S. Miller commit 10a104f9c591c3b1175bbb03ecb0bc8f2a4a16ee Author: David S. Miller Date: Wed Aug 27 01:55:54 2008 -0700 sparc64: Convert SBUS floppy probing to use OF device objects. Signed-off-by: David S. Miller commit 237f8aafa348d56e6ad24c49ebd23bd927fedb31 Author: David S. Miller Date: Wed Aug 27 18:39:47 2008 -0700 sparc: Convert uctrl driver to OF driver. Signed-off-by: David S. Miller commit a9540d34229c0ec1fceb9a9d1e41ea45d016044d Author: David S. Miller Date: Wed Aug 27 01:13:12 2008 -0700 sparc: Convert flash driver to OF device probing. Signed-off-by: David S. Miller commit 826b6cfcd5d4c352a461b28694720ac1dcad5813 Author: David S. Miller Date: Wed Aug 27 01:06:07 2008 -0700 fore200e: Convert over to pure OF driver. Signed-off-by: David S. Miller commit ae251031ad22a659b8261440b049d5981e57880c Author: David S. Miller Date: Wed Aug 27 18:24:01 2008 -0700 cs4231: Convert SBUS side to OF driver. Signed-off-by: David S. Miller commit 759ee81be6d87c150ea2b300c221b4fec8b5f646 Author: David S. Miller Date: Wed Aug 27 00:33:26 2008 -0700 alsa: Remove special SBUS dma support code. No longer used. Signed-off-by: David S. Miller commit 12b1c03df10da61e222b86f0e1ece9cdb2a909d6 Author: David S. Miller Date: Wed Aug 27 00:31:36 2008 -0700 cs4231: Use SNDRV_DMA_TYPE_DEV instead of SNDRV_DMA_TYPE_SBUS. SBUS layer now uses dma_*() interfaces, no need for special DMA code any longer. Signed-off-by: David S. Miller commit 2bd320f89d417c370f4cf45470d102332c25ea24 Author: David S. Miller Date: Wed Aug 27 00:30:59 2008 -0700 dbri: Convert to pure OF driver. Signed-off-by: David S. Miller commit dc8aa2e9d6c965c11ddd05fca721b2218585b9f0 Author: David S. Miller Date: Wed Aug 27 00:29:27 2008 -0700 amd7930: Convert to pure OF driver. Signed-off-by: David S. Miller commit 5dc2536bb8d8adb5fdfbe76cd6fdcdf9de3f40f8 Author: David S. Miller Date: Wed Aug 27 00:24:00 2008 -0700 qlogicpti: Convert to pure OF driver. Signed-off-by: David S. Miller commit 05bb5e93f2ef3f14e0c5a7e9281d07e7a7e4233d Author: David S. Miller Date: Wed Aug 27 00:20:58 2008 -0700 sun_esp: Convert to pure OF driver. Signed-off-by: David S. Miller commit 27167e0e63a9c53477a7de1c55888bd660c3f9a6 Author: David S. Miller Date: Wed Aug 27 00:17:50 2008 -0700 parport_sunbpp: Convert to pure OF driver. Signed-off-by: David S. Miller commit 8e912b333981a90959e9665e6ec2758be36ab805 Author: David S. Miller Date: Wed Aug 27 00:12:27 2008 -0700 sunqe: Convert to pure OF driver. Signed-off-by: David S. Miller commit af736fede772d92096b52da9aa1b0cf5de62eceb Author: David S. Miller Date: Wed Aug 27 00:07:53 2008 -0700 sunlance: Convert to pure OF driver. Signed-off-by: David S. Miller commit db1a8611c8733711b40bbce11c87336e3e374634 Author: David S. Miller Date: Fri Aug 29 02:14:29 2008 -0700 sunhme: Convert to pure OF driver. Signed-off-by: David S. Miller commit 8ef2175c86821350775718bfe7d3490bbea2e3cf Author: David S. Miller Date: Tue Aug 26 23:40:25 2008 -0700 sunbmac: Convert to pure OF driver. Signed-off-by: David S. Miller commit 9e6b6e7d8e48dedc384a377941feecec99be889e Author: David S. Miller Date: Tue Aug 26 23:36:58 2008 -0700 myri_sbus: Convert to pure OF driver. Signed-off-by: David S. Miller commit 63237eeb5ac92d618a0a6055f4b1f65c5d14682b Author: David S. Miller Date: Tue Aug 26 23:33:42 2008 -0700 sparc: Move SBUS DMA attribute interfaces out of asm/sbus.h This is in preparation for the subsequent asm/sbus.h removal. Also, make these routines take a "struct device" or no arguments, as appropriate. Signed-off-by: David S. Miller commit 738f2b7b813913e651f39387d007dd961755dee2 Author: David S. Miller Date: Wed Aug 27 18:09:11 2008 -0700 sparc: Convert all SBUS drivers to dma_*() interfaces. And all the SBUS dma interfaces are deleted. A private implementation remains inside of the 32-bit sparc port which exists only for the sake of the implementation of dma_*(). Signed-off-by: David S. Miller commit 944c67dff7a88f0a775e5b604937f9e30d2de555 Author: David S. Miller Date: Wed Aug 27 18:01:36 2008 -0700 sparc32: Implement more generic dma_*() interfaces. These dispatch to either PCI or SBUS routines based upon the device bus type. This will allow us to let SBUS drivers call these routines. Signed-off-by: David S. Miller commit 260489fa8a9735c76073ace95f03ffaf10cca884 Author: David S. Miller Date: Tue Aug 26 23:00:58 2008 -0700 sparc32: Make mmu_{get,release}_*() take a struct device pointer. Signed-off-by: David S. Miller commit 7a715f46012f3552294154978aed59cba9804928 Author: David S. Miller Date: Wed Aug 27 18:37:58 2008 -0700 sparc: Make SBUS DMA interfaces take struct device. This is the first step in converting all the SBUS drivers over to generic dma_*(). Signed-off-by: David S. Miller commit 5778002874de0fb7e3d8c4a0a4afb6b1a6297069 Author: David S. Miller Date: Mon Aug 25 22:52:37 2008 -0700 sparc: Propagate SBUS iommu archdata into real of_device objects. Signed-off-by: David S. Miller commit e003934876e75f96f1445565d8c9084c07943253 Author: David S. Miller Date: Mon Aug 25 22:47:20 2008 -0700 sparc32: Make IOMMU and IO-UNIT init work with device nodes. And stick the iommu archdata pointer into the generic OF device tree of_device struct as well. We still have to pass the sbus_bus object down into the routines so that the SBUS bus objects get the iommu cookies set properly. After drivers get converted to being pure OF drivers, that can go away. Signed-off-by: David S. Miller commit 334ae614772b1147435dce9be3911f9040dff0d9 Author: David S. Miller Date: Wed Aug 27 17:01:57 2008 -0700 sparc: Kill SBUS DVMA layer. This thing was completely pointless. Just find the OF device in the parent of drivers that want to program this device, and map the DMA regs inside such drivers too. This also moves the dummy claim_dma_lock() and release_dma_lock() implementation to floppy_32.h, which makes it handle this issue just like floppy_64.h does. Signed-off-by: David S. Miller commit 7f06a3b2c162573c924f425053227a52b4bd7cb1 Author: David S. Miller Date: Tue Aug 26 22:26:21 2008 -0700 sparc: Kill videopix SBUS driver. This has been marked BROKEN for a long time and it's more likely to get rewritten from scratch than to be fixed up and made usable. Signed-off-by: David S. Miller commit 902663f6ea4a2603bee0d88450aae2d653a46f5d Author: David S. Miller Date: Tue Aug 26 22:25:03 2008 -0700 sparc: Delete bare sbus char bpp driver, obsoleted by parport_sunbpp Signed-off-by: David S. Miller commit 35200d865d49d0207b054074055e1487a0c28ae4 Author: Dominik Brodowski Date: Thu Aug 28 23:44:45 2008 +0200 pcmcia: device_id header cleanup Wrap in #ifdef to include header just once, and wrap in another #ifdef to avoid it being used in userspace. Also, format the header similar to the other PCMCIA header files. Signed-off-by: Dominik Brodowski commit d39bd56452b509f8d6054883b8a0129950ba50cc Author: Dominik Brodowski Date: Thu Aug 28 01:05:34 2008 +0200 pcmcia: encapsulate ioaddr_t By now, ioaddr_t should only be used by the deprecated ioctl, as it does not correctly reflect the maximum ioport range at least on some architectures. Signed-off-by: Dominik Brodowski commit a58357862e71919555ea96cd272e535593a8b3da Author: Dominik Brodowski Date: Thu Aug 28 00:41:16 2008 +0200 pcmcia: cleanup device driver header file The header file primarily used for (in-kernel) PCMCIA device drivers also deserved a major cleanup. This header file also serves as the dumping ground for all typedefs and definitions only used by the deprecated PCMCIA ioctl and the deprecated PCMCIA userspace tools using this ioctl. Signed-off-by: Dominik Brodowski commit a0f000ec9b61b99111757df138b11144236fc59b Author: Herbert Xu Date: Thu Aug 14 22:21:31 2008 +1000 crypto: skcipher - Use RNG interface instead of get_random_bytes This patch makes the IV generators use the new RNG interface so that the user can pick an RNG other than the default get_random_bytes. Signed-off-by: Herbert Xu commit 17f0f4a47df9aea9ee26c939f8057c35e0be1847 Author: Neil Horman Date: Thu Aug 14 22:15:52 2008 +1000 crypto: rng - RNG interface and implementation This patch adds a random number generator interface as well as a cryptographic pseudo-random number generator based on AES. It is meant to be used in cases where a deterministic CPRNG is required. One of the first applications will be as an input in the IPsec IV generation process. Signed-off-by: Neil Horman Signed-off-by: Herbert Xu commit ccb778e1841ce04b4c10b39f0dd2558ab2c6dcd4 Author: Neil Horman Date: Tue Aug 5 14:13:08 2008 +0800 crypto: api - Add fips_enable flag Add the ability to turn FIPS-compliant mode on or off at boot In order to be FIPS compliant, several check may need to be preformed that may be construed as unusefull in a non-compliant mode. This patch allows us to set a kernel flag incating that we are running in a fips-compliant mode from boot up. It also exports that mode information to user space via a sysctl (/proc/sys/crypto/fips_enabled). Tested successfully by me. Signed-off-by: Neil Horman Signed-off-by: Herbert Xu commit 5be5e667a9a5d8d5553e009e67bc692d95e5916a Author: Herbert Xu Date: Sun Aug 17 18:04:30 2008 +1000 crypto: skcipher - Move IV generators into their own modules This patch moves the default IV generators into their own modules in order to break a dependency loop between cryptomgr, rng, and blkcipher. Signed-off-by: Herbert Xu commit 1aa4ecd95d8d67d21731a00646326a71295dafa3 Author: Herbert Xu Date: Sun Aug 17 17:01:56 2008 +1000 crypto: cryptomgr - Test ciphers using ECB As it is we only test ciphers when combined with a mode. That means users that do not invoke a mode of operations may get an untested cipher. This patch tests all ciphers using the ECB mode so that simple cipher users such as ansi-cprng are also protected. Signed-off-by: Herbert Xu commit 73d3864a4823abda19ebc4387b6ddcbf416e3a77 Author: Herbert Xu Date: Sun Aug 3 21:15:23 2008 +0800 crypto: api - Use test infrastructure This patch makes use of the new testing infrastructure by requiring algorithms to pass a run-time test before they're made available to users. Signed-off-by: Herbert Xu commit da7f033ddc9fdebb3223b0bf88a2a2ab5b797608 Author: Herbert Xu Date: Thu Jul 31 17:08:25 2008 +0800 crypto: cryptomgr - Add test infrastructure This patch moves the newly created alg_test infrastructure into cryptomgr. This shall allow us to use it for testing at algorithm registrations. Signed-off-by: Herbert Xu commit 01b323245e4f6d4a22ffd73754f145f45c85988c Author: Herbert Xu Date: Thu Jul 31 15:41:55 2008 +0800 crypto: tcrypt - Add alg_test interface This patch creates a new interface algorithm testing. A test can be requested for a particular implementation of an algorithm. This is achieved by taking both the name of the algorithm and that of the implementation. The all-inclusive test has also been rewritten to no longer require a duplicate listing of all algorithms with tests. In that process a number of missing tests have also been discovered and rectified. Signed-off-by: Herbert Xu commit bdecd22821a0fab1f5c9e4c9b7fba894593507d4 Author: Herbert Xu Date: Thu Jul 31 14:03:44 2008 +0800 crypto: tcrypt - Abort and only log if there is an error The info printed is a complete waste of space when there is no error since it doesn't tell us anything that we don't already know. If there is an error, we can also be more verbose. In case that there is an error, this patch also aborts the test and returns the error to the caller. In future this will be used to algorithms at registration time. Signed-off-by: Herbert Xu commit 8cb51ba8e06570a5fff674b3744d12a1b089f2d0 Author: Austin Zhang Date: Thu Aug 7 09:57:03 2008 +0800 crypto: crc32c - Use Intel CRC32 instruction From NHM processor onward, Intel processors can support hardware accelerated CRC32c algorithm with the new CRC32 instruction in SSE 4.2 instruction set. The patch detects the availability of the feature, and chooses the most proper way to calculate CRC32c checksum. Byte code instructions are used for compiler compatibility. No MMX / XMM registers is involved in the implementation. Signed-off-by: Austin Zhang Signed-off-by: Kent Liu Signed-off-by: Herbert Xu commit f139cfa7cdccd0b315fad098889897b5fcd389b0 Author: Herbert Xu Date: Thu Jul 31 12:23:53 2008 +0800 crypto: tcrypt - Avoid using contiguous pages If tcrypt is to be used as a run-time integrity test, it needs to be more resilient in a hostile environment. For a start allocating 32K of physically contiguous memory is definitely out. This patch teaches it to use separate pages instead. Signed-off-by: Herbert Xu commit a7581a01fbc69771a2b391de4220ba670c0aa261 Author: Herbert Xu Date: Mon Aug 4 14:22:29 2008 +0800 crypto: api - Display larval objects properly Rather than displaying larval objects as real objects, this patch makes them show up under /proc/crypto as of type larval. Signed-off-by: Herbert Xu commit c51b6c8102a82239163c8c04e404c7cc2857b4be Author: Herbert Xu Date: Mon Aug 4 11:44:59 2008 +0800 crypto: api - Export crypto_alg_lookup instead of __crypto_alg_lookup Since the only user of __crypto_alg_lookup is doing exactly what crypto_alg_lookup does, we can now the latter in lieu of the former. Signed-off-by: Herbert Xu commit b6d44341864b50a308f932c39f03fb8ad5efb021 Author: Adrian Bunk Date: Wed Jul 16 19:28:00 2008 +0800 crypto: Kconfig - Replace leading spaces with tabs Instead of tabs there were two spaces. Signed-off-by: Adrian Bunk Signed-off-by: Herbert Xu commit a7ced862d955c891507e6664fe9f1206d7dae8b5 Author: Tejun Heo Date: Thu Aug 28 15:31:55 2008 -0500 9p-trans_fd: use single poller trans_fd used pool of upto 100 pollers to monitor the r/w fds. The approach makes sense in userspace back when the only available interfaces were poll(2) and select(2). As each event monitor - trigger - handling iteration took O(n) where `n' is the number of watched fds, it makes sense to spread them to many pollers such that the `n' can be divided by the number of pollers. However, this doesn't make any sense in kernel because persistent edge triggered event monitoring is how the whole thing is implemented in the kernel in the first place. This patch converts trans_fd to use single poller which watches all the fds instead of the poll of pollers approach. All the fds are registered for monitoring on creation and only the fds with pending events are scanned when something happens much like how epoll is implemented. This change makes trans_fd fd monitoring more efficient and simpler. Signed-off-by: Tejun Heo Signed-off-by: Eric Van Hensbergen commit baa16ca249155a69bb86505f8c4d41d7c222c10a Author: Tejun Heo Date: Thu Aug 28 15:32:43 2008 -0500 9p-trans_fd: fix and clean up module init/exit paths trans_fd leaked p9_mux_wq on module unload. Fix it. While at it, collapse p9_mux_global_init() into p9_trans_fd_init(). It's easier to follow this way and the global poll_tasks array is about to removed anyway. Signed-off-by: Tejun Heo Signed-off-by: Eric Van Hensbergen commit e9a4c2737a10fc70b9546067810660406426fbc3 Author: Tejun Heo Date: Thu Aug 28 13:30:08 2008 -0500 9p-trans_fd: don't do fs segment mangling in p9_fd_poll() p9_fd_poll() is never called with user pointers and f_op->poll() doesn't expect its arguments to be from userland. There's no need to set kernel ds before calling f_op->poll() from p9_fd_poll(). Remove it. Signed-off-by: Tejun Heo Signed-off-by: Eric Van Hensbergen commit b3e2da7e455752c076a7cadb7250e6153304d44b Author: Tejun Heo Date: Thu Aug 28 13:29:15 2008 -0500 9p-trans_fd: clean up p9_conn_create() * Use kzalloc() to allocate p9_conn and remove 0/NULL initializations. * Clean up error return paths. Signed-off-by: Tejun Heo Signed-off-by: Eric Van Hensbergen commit acc64e0b8a5c0093712ea9f27fac70bf8535a5b1 Author: Tejun Heo Date: Thu Aug 28 13:28:28 2008 -0500 9p-trans_fd: fix trans_fd::p9_conn_destroy() p9_conn_destroy() first kills all current requests by calling p9_conn_cancel(), then waits for the request list to be cleared by waiting on p9_conn->equeue. After that, polling is stopped and the trans is destroyed. This sequence has a few problems. * Read and write works were never cancelled and the p9_conn can be destroyed while the works are running as r/w works remove requests from the list and dereference the p9_conn from them. * The list emptiness wait using p9_conn->equeue wouldn't trigger because p9_conn_cancel() always clears all the lists and the only way the wait can be triggered is to have another task to issue a request between the slim window between p9_conn_cancel() and the wait, which isn't safe under the current implementation with or without the wait. This patch fixes the problem by first stopping poll, which can schedule r/w works, first and cancle r/w works which guarantees that r/w works are not and will not run from that point and then calling p9_conn_cancel() and do the rest of destruction. Signed-off-by: Tejun Heo Signed-off-by: Eric Van Hensbergen commit d8c5e9abb6009efa80114eeedd8e749df2a013a4 Author: Tejun Heo Date: Thu Aug 28 13:27:34 2008 -0500 9p: implement proper trans module refcounting and unregistration 9p trans modules aren't refcounted nor were they unregistered properly. Fix it. * Add 9p_trans_module->owner and reference the module on each trans instance creation and put it on destruction. * Protect v9fs_trans_list with a spinlock. This isn't strictly necessary as the list is manipulated only during module loading / unloading but it's a good idea to make the API safe. * Unregister trans modules when the corresponding module is being unloaded. * While at it, kill unnecessary EXPORT_SYMBOL on p9_trans_fd_init(). Signed-off-by: Tejun Heo Signed-off-by: Eric Van Hensbergen commit c1dcf65ffc5796bf4ff75c13f448e63b3a416fd6 Author: David Teigland Date: Mon Aug 18 14:03:25 2008 -0500 dlm: fix locking of lockspace list in dlm_scand The dlm_scand thread needs to lock the list of lockspaces when going through it. Signed-off-by: David Teigland commit dc68c7ed362a00a48290252573a8eb9f74463c3a Author: David Teigland Date: Mon Aug 18 11:43:30 2008 -0500 dlm: detect available userspace daemon If dlm_controld (the userspace daemon that controls the setup and recovery of the dlm) fails, the kernel should shut down the lockspaces in the kernel rather than leaving them running. This is detected by having dlm_controld hold a misc device open while running, and if the kernel detects a close while the daemon is still needed, it stops the lockspaces in the kernel. Knowing that the userspace daemon isn't running also allows the lockspace create/remove routines to avoid waiting on the daemon for join/leave operations. Signed-off-by: David Teigland commit 0f8e0d9a317406612700426fad3efab0b7bbc467 Author: David Teigland Date: Wed Aug 6 13:30:24 2008 -0500 dlm: allow multiple lockspace creates Add a count for lockspace create and release so that create can be called multiple times to use the lockspace from different places. Also add the new flag DLM_LSFL_NEWEXCL to create a lockspace with the previous behavior of returning -EEXIST if the lockspace already exists. Signed-off-by: David Teigland commit 918ace5f9ad364776ab9329511741a5c32f3de65 Author: Avi Kivity Date: Thu Aug 28 18:27:15 2008 +0300 KVM: SVM: No need to unprotect memory during event injection when using npt No memory is protected anyway. Signed-off-by: Avi Kivity commit fa2beb8a883cff9471826c6b968e7d1ef7342374 Author: Avi Kivity Date: Thu Aug 28 18:24:55 2008 +0300 KVM: MMU: Fix tlb flush during page zap The tlb is flushed after kvm_mmu_page_unlink_children(), but not after kvm_mmu_unlink_parents(), leading to pontentially stale caches of intermediate entries (not classical tlb entries though). Move the flush lower to prevent this. Noticed by Joerg Roedel. Signed-off-by: Avi Kivity commit 1be95f401657e75984871c369d774d507e462939 Author: Tejun Heo Date: Thu Aug 28 16:42:51 2008 +0200 sound: make OSS sound core optional sound/sound_core.c implements soundcore.ko and contains two parts - sound_class which is shared by both ALSA and OSS and device redirection support for OSS. It's always compiled when any sound support is enabled although it's necessary only when OSS (the actual one or emulation) is enabled. This is slightly wasteful and as device redirection always registers character device region for major 14, it prevents alternative implementation. This patch introduces a new config SOUND_OSS_CORE which is selected iff OSS support is actually necessary and build the OSS core part conditionally. If OSS is disabled, soundcore merely contains sound_class but leaving it that way seems to be the simplest approach as otherwise sound_class should be in ALSA core file if OSS is disabled but should be in soundcore if OSS is enabled. Also, there's also the user confusion factor. Signed-off-by: Tejun Heo Signed-off-by: Takashi Iwai commit d9250dea3f89fe808a525f08888016b495240ed4 Author: KaiGai Kohei Date: Thu Aug 28 16:35:57 2008 +0900 SELinux: add boundary support and thread context assignment The purpose of this patch is to assign per-thread security context under a constraint. It enables multi-threaded server application to kick a request handler with its fair security context, and helps some of userspace object managers to handle user's request. When we assign a per-thread security context, it must not have wider permissions than the original one. Because a multi-threaded process shares a single local memory, an arbitary per-thread security context also means another thread can easily refer violated information. The constraint on a per-thread security context requires a new domain has to be equal or weaker than its original one, when it tries to assign a per-thread security context. Bounds relationship between two types is a way to ensure a domain can never have wider permission than its bounds. We can define it in two explicit or implicit ways. The first way is using new TYPEBOUNDS statement. It enables to define a boundary of types explicitly. The other one expand the concept of existing named based hierarchy. If we defines a type with "." separated name like "httpd_t.php", toolchain implicitly set its bounds on "httpd_t". This feature requires a new policy version. The 24th version (POLICYDB_VERSION_BOUNDARY) enables to ship them into kernel space, and the following patch enables to handle it. Signed-off-by: KaiGai Kohei Acked-by: Stephen Smalley Signed-off-by: James Morris commit 26ec6cdb66e9f965ce2893a9e27990cac7e6600c Author: Hiroshi Miura Date: Thu Aug 28 16:09:06 2008 +0200 ALSA: hda - Add support of Toshiba RX1 Added the support of Toshiba RX1 laptop with ALC262 codec chip. Related ALSA bug#3386: https://bugtrack.alsa-project.org/alsa-bug/view.php?id=3386 Signed-off-by: Hiroshi Miura Signed-off-by: Takashi Iwai commit b86586bdabebf90d3c35976b73b40c1cdcbf280c Author: John L. Utz III Date: Thu Aug 28 16:04:40 2008 +0200 ALSA: ac97 - vt1618 7.1 Audio Support 1. Implement 7.1 Output for vt1618 codec. 2. Fix typos in comments from my previous 1617a patch. Signed-off-by: John L. Utz III Signed-off-by: Takashi Iwai commit 84c772014dc6b3a8416d4e7aa11a961d60879e0d Author: Takashi Iwai Date: Wed Aug 27 15:31:03 2008 +0200 ALSA: remove obsolete *_FIRMARE_IN_KERNEL in isa/Kconfig Signed-off-by: Takashi Iwai commit 42ed53e27096aa38de5deea0ce8450d4769dd907 Author: Mark Brown Date: Thu Aug 28 12:46:24 2008 +0100 ALSA: ASoC: Convert DAPM pop time configuration to debugfs Pop time configuration is a debugging feature which shouldn't be used in normal operation so move it to debugfs where it is clearer. This also simplifies the code since debugfs provides standard facilities for exposing simple integer values to user space. Signed-off-by: Mark Brown Signed-off-by: Takashi Iwai commit af01d537463714e36e2c96d2da35902b76cd6827 Author: Alexey Dobriyan Date: Thu Aug 28 02:53:51 2008 -0700 net: more #ifdef CONFIG_COMPAT All users of struct proto::compat_[gs]etsockopt and struct inet_connection_sock_af_ops::compat_[gs]etsockopt are under #ifdef already, so use it in structure definition too. Signed-off-by: Alexey Dobriyan Signed-off-by: David S. Miller commit a627266570605a98c5fda5b8234d9e92015e4d14 Author: Eric Dumazet Date: Thu Aug 28 01:11:25 2008 -0700 ip: speedup /proc/net/rt_cache handling When scanning route cache hash table, we can avoid taking locks for empty buckets. Both /proc/net/rt_cache and NETLINK RTM_GETROUTE interface are taken into account. Signed-off-by: Eric Dumazet Signed-off-by: David S. Miller commit 6be547a61d6220199826070cda792297c3d15994 Author: Andi Kleen Date: Thu Aug 28 01:09:54 2008 -0700 inet_diag: Add empty bucket optimization to inet_diag too Skip quickly over empty buckets in inet_diag. Signed-off-by: Andi Kleen Signed-off-by: David S. Miller commit 6eac56040787c3ff604fe7d48bbbb7897cd1387c Author: Andi Kleen Date: Thu Aug 28 01:08:02 2008 -0700 tcp: Skip empty hash buckets faster in /proc/net/tcp On most systems most of the TCP established/time-wait hash buckets are empty. When walking the hash table for /proc/net/tcp their read locks would always be aquired just to find out they're empty. This patch changes the code to check first if the buckets have any entries before taking the lock, which is much cheaper than taking a lock. Since the hash tables are large this makes a measurable difference on processing /proc/net/tcp, especially on architectures with slow read_lock (e.g. PPC) On a 2GB Core2 system time cat /proc/net/tcp > /dev/null (with a mostly empty hash table) goes from 0.046s to 0.005s. On systems with slower atomics (like P4 or POWER4) or larger hash tables (more RAM) the difference is much higher. This can be noticeable because there are some daemons around who regularly scan /proc/net/tcp. Original idea for this patch from Marcus Meissner, but redone by me. Signed-off-by: Andi Kleen Signed-off-by: David S. Miller commit 22e0e43771471f64ecba1a72e83954c4204daac1 Author: Paul Mundt Date: Fri Aug 8 01:23:34 2008 +0900 sh: Display CPU information in show_regs(). Signed-off-by: Paul Mundt commit b5b0f28b237dcb7de38129b80989efc8d4a7efdc Author: Paul Mundt Date: Fri Aug 8 01:18:48 2008 +0900 sh: Early dummy clockevent registration on boot CPU. The dummy timer needs to be registered on the boot CPU before the system timer clockevent is registered, or broadcasting doesn't work as advertized. Signed-off-by: Paul Mundt commit 6ab742221ab42b597551ea32129ceb44414988d8 Author: Paul Mundt Date: Wed Aug 6 18:39:32 2008 +0900 sh: smp: shove a cpu_relax() in the plat_start_cpu() busy loop. Without this, certain versions of GCC will happily optimize the entire loop out. Signed-off-by: Paul Mundt commit 63d7e90b0ebbca496cf613a433303fe1e40ef9e7 Author: Paul Mundt Date: Wed Aug 6 18:37:07 2008 +0900 sh: generic clockevent broadcast support. This hooks up GENERIC_CLOCKEVENTS_BROADCAST and a dummy local timer, which we call in to from the timer IPI when no other local timer is provided. Signed-off-by: Paul Mundt commit e86a42ca325b7e78e43c716f39149c996c61a3f2 Author: Paul Mundt Date: Wed Aug 6 18:21:03 2008 +0900 sh: smp: Hook up a timer IPI stub. Signed-off-by: Paul Mundt commit c4864b17f2ea2539852dafe1fe56b9fad78e5d37 Author: Paul Mundt Date: Wed Aug 6 18:05:09 2008 +0900 sh: smp: Hook in to the generic IPI handler for SH-X3 SMP. Signed-off-by: Paul Mundt commit 044999c6ffe6024730b7febebfa5578e357175d5 Author: Paul Mundt Date: Wed Aug 6 18:02:48 2008 +0900 sh: smp: Provide a generic IPI handler. This provides a generic smp_message_recv() routine (based on the PPC one), that IPI IRQs can wrap in to. Signed-off-by: Paul Mundt commit aec85da64b2c60cc995e41fb9c5b8482cb7aacb6 Author: Paul Mundt Date: Wed Aug 6 17:29:14 2008 +0900 sh: Kill off unused defines from asm/smp.h. Signed-off-by: Paul Mundt commit 063313cfc65cba0e4fedd069948cf58209f5bb02 Author: Paul Mundt Date: Thu Aug 7 18:01:43 2008 +0900 sh: Provide movli.l/movco.l-based cmpxchg. Signed-off-by: Paul Mundt commit a8163adc9542871777495d7224ed64e5430ec8f2 Author: Paul Mundt Date: Thu Aug 7 17:36:12 2008 +0900 sh: Provide movli.l/movco.l-based bitops. Signed-off-by: Paul Mundt commit 3af7043c57080f1ae7cd80c661d3e1308f164e1b Author: Ingo Molnar Date: Thu Aug 28 08:56:33 2008 +0200 sparseirq: export nr_irqs on m68k/sparc/s390 Stephen Rothwell reported such build failures on m68k/sparc/s390: > ERROR: "nr_irqs" [drivers/net/hamradio/baycom_ser_fdx.ko] undefined! > ERROR: "nr_irqs" [drivers/net/3c59x.ko] undefined! export nr_irqs on these architectures too. Reported-by: Stephen Rothwell Signed-off-by: Ingo Molnar commit 3c31bf73134038a417a9ae3fa3c02c279b42c550 Author: Yoshihiro Shimoda Date: Wed Aug 27 20:16:46 2008 +0900 sh: fix semtimedop syscall fix the problem that cannot work semtimedop system call. Signed-off-by: Yoshihiro Shimoda Signed-off-by: Paul Mundt commit f9bed3f2040b2ed44f0d1b7f0280458533c5d2a0 Author: Magnus Damm Date: Wed Aug 27 18:23:52 2008 +0900 sh: update AP325RXA defconfig This patch updates the AP325RXA defconfig to include the recently merged uio_pdrv_genirq driver. Signed-off-by: Magnus Damm Signed-off-by: Paul Mundt commit be8c129f1a853daac9085d81256c9d4bd38c6a11 Author: Magnus Damm Date: Wed Aug 27 18:22:49 2008 +0900 sh: update Migo-R defconfig This patch updates the MigoR defconfig to include the recently merged uio_pdrv_genirq driver. Signed-off-by: Magnus Damm Signed-off-by: Paul Mundt commit c773d8af8ebccb723e9843c1e73840b2c5e00572 Author: Magnus Damm Date: Wed Aug 27 18:21:29 2008 +0900 sh: fix platform_resource_setup_memory() section mismatch This patch kills a section mismatch for platform_resource_setup_memory(). Signed-off-by: Magnus Damm Signed-off-by: Paul Mundt commit 5734493bac88b28d8d7e2f262305fd6e83545ac5 Author: Magnus Damm Date: Wed Aug 27 18:19:01 2008 +0900 sh: fix kexec entry point for crash kernels The crash kernel entry point is currently checked by the kexec kernel code and only physical addresses in the reserved memory window are accepted. This means that we can't pass P2 or P1 addresses as entry points in the case of crash kernels. This patch makes sure we can start crash kernels by adding support for physical address entry points. Signed-off-by: Magnus Damm Signed-off-by: Paul Mundt commit 34894c7843e00972d88b3592027703d4e05a06a7 Author: Magnus Damm Date: Wed Aug 27 18:15:43 2008 +0900 sh: crash kernel resource fix The reserved crash kernel memory range is currently missing from /proc/iomem. crashk_res is mistakenly setup after __add_active_range(). Reorder things to make sure the resource shows up in /proc/iomem. Signed-off-by: Magnus Damm Signed-off-by: Paul Mundt commit da31894ed7b654e2e1741e7ac4ef6c15be0dd14b Author: Eric Paris Date: Fri Aug 22 11:35:57 2008 -0400 securityfs: do not depend on CONFIG_SECURITY Add a new Kconfig option SECURITYFS which will build securityfs support but does not require CONFIG_SECURITY. The only current user of securityfs does not depend on CONFIG_SECURITY and there is no reason the full LSM needs to be built to build this fs. Signed-off-by: Eric Paris Signed-off-by: James Morris commit 945d2d9689f0bcd9666c783b5e62270a7f290716 Author: Kenji Kaneshige Date: Fri Aug 22 17:16:48 2008 +0900 PCI: pciehp: fix irq initialization Current pciehp driver gets irq number from pci_dev->irq. But because pciehp driver is a pci express port service driver, it should get irq number from pcie_device->irq. Signed-off-by: Kenji Kaneshige Signed-off-by: Jesse Barnes commit f78d3617595b6c167db80e27506bc179b6be9498 Author: Andi Kleen Date: Fri Aug 22 09:53:39 2008 +0200 PCI: Document that most pci options are shared between i386 and x86-64 Since the code is shared pretty much most of the pci= options are shared, but kernel-parameters.txt marked most of them as i386 only. Signed-off-by: Andi Kleen Signed-off-by: Jesse Barnes commit 0ea1dd2c8c5ae5781cd5872162e38b1ebb8232ac Author: Bjorn Helgaas Date: Fri Aug 22 09:37:02 2008 -0600 PCI: tidy PME support messages This patch changes these two messages: pci 0000:00:03.0: supports D1 pci 0000:00:03.0: supports D2 to this: pci 0000:00:03.0: supports D1 D2 It also trivially converts a "dev_printk(KERN_INFO, ...)" to "dev_info(...)". Signed-off-by: Bjorn Helgaas Signed-off-by: Jesse Barnes commit 20e8804151d722923a7c8056356254daccb947eb Author: Johann Felix Soden Date: Fri Aug 22 20:25:10 2008 +0200 PCI: Fix printk warnings in setup-bus.c Again, the cleaned up code introduced some resource warnings: drivers/pci/setup-bus.c: In function 'pci_bus_dump_res': drivers/pci/setup-bus.c:542: warning: format '%llx' expects type 'long long unsigned int', but argument 5 has type 'resource_size_t' drivers/pci/setup-bus.c:542: warning: format '%llx' expects type 'long long unsigned int', but argument 6 has type 'resource_size_t' Fix those up too. Signed-off-by: Johann Felix Soden Signed-off-by: Jesse Barnes commit b04f03a8d89a55222de88e9b68a8b574a8356b23 Author: Johann Felix Soden Date: Fri Aug 22 20:46:59 2008 +0200 PCI: Fix printk warnings in probe.c The cleaned up resource code in probe.c introduced some warnings: drivers/pci/probe.c: In function 'pci_read_bridge_bases': drivers/pci/probe.c:386: warning: format '%llx' expects type 'long long unsigned int', but argument 3 has type 'resource_size_t' drivers/pci/probe.c:386: warning: format '%llx' expects type 'long long unsigned int', but argument 4 has type 'resource_size_t' drivers/pci/probe.c:398: warning: format '%llx' expects type 'long long unsigned int', but argument 3 has type 'resource_size_t' drivers/pci/probe.c:398: warning: format '%llx' expects type 'long long unsigned int', but argument 4 has type 'resource_size_t' drivers/pci/probe.c:434: warning: format '%llx' expects type 'long long unsigned int', but argument 4 has type 'resource_size_t' drivers/pci/probe.c:434: warning: format '%llx' expects type 'long long unsigned int', but argument 5 has type 'resource_size_t' So fix them up. Signed-off-by: Johann Felix Soden Signed-off-by: Jesse Barnes commit 2ec42824d05e313f77ea49b75cc3fa547ce14f33 Author: akpm@linux-foundation.org Date: Fri Aug 22 13:30:14 2008 -0700 PCI: ibmphp: list_for_each to list_for_each_entry-checkpatch cleanups Please run checkpatch prior to sending patches, this one fixes several style issues with the list_for_each conversion patch. Cc: Cordelia Sam Cc: Cordelia Sam Cc: Kristen Carlson Accardi Signed-off-by: Andrew Morton Signed-off-by: Jesse Barnes commit f138d5a1965108f6beb74708c30443c514b7b5d8 Author: akpm@linux-foundation.org Date: Fri Aug 22 13:28:17 2008 -0700 PCI: ibmphp: list_for_each to list_for_each_entry Make code more readable with list_for_each_entry(). Signed-off-by: Cordelia Sam Cc: Kristen Carlson Accardi Signed-off-by: Andrew Morton Signed-off-by: Jesse Barnes commit 9e3f79519040abb470dcbe2a32fbbfdace1212a2 Author: Bjorn Helgaas Date: Mon Aug 25 15:45:20 2008 -0600 PCI: follow lspci device/vendor style Use "[%04x:%04x]" for PCI vendor/device IDs to follow the format used by lspci(8). Signed-off-by: Bjorn Helgaas Signed-off-by: Jesse Barnes commit b1d4cd6fc9d97116f31cc18540c06236eee231e8 Author: Bjorn Helgaas Date: Mon Aug 25 15:44:59 2008 -0600 x86/PCI: follow lspci device/vendor style Use "[%04x:%04x]" for PCI vendor/device IDs to follow the format used by lspci(8). Signed-off-by: Bjorn Helgaas Signed-off-by: Jesse Barnes commit 41d5ab1f0d147873e1cbfd5c414f466b96f1b0c5 Author: Greg KH Date: Tue Aug 26 08:20:34 2008 -0700 PCI: fix compiler warnings in pci_get_subsys() pci_get_subsys() changed in 2.6.26 so that the from pointer is modified when the call is being invoked, so fix up the 'const' marking of it that the compiler is complaining about. Reported-by: Rufus & Azrael Signed-off-by: Greg Kroah-Hartman Signed-off-by: Jesse Barnes commit 2dabbc99928123ebaefef5f2be5e777afb6de6ad Author: Yinghai Lu Date: Fri Aug 15 19:36:45 2008 -0700 PCI: change MSI-x vector to 32bit We are using 28bit pci (bus/dev/fn + 12 bits) as irq number, so the cache for irq number should be 32 bit too. Signed-off-by: Yinghai Lu Cc: Andrew Vasquez Signed-off-by: Jesse Barnes commit abe430b1903750bceabd7a9901f3e013b0ce1f2f Author: Rafael J. Wysocki Date: Mon Aug 18 21:38:00 2008 +0200 PCI PM: Introduce function pci_wake_from_d3 Many device drivers use the following sequence of statements to enable the device to wake up the system while being in the D3_hot or D3_cold low power state: pci_enable_wake(pdev, PCI_D3hot, 1); pci_enable_wake(pdev, PCI_D3cold, 1); However, the second call is not necessary if the first one succeeds (the ordering of the statements above doesn't matter here) and it may even be harmful, because we are not supposed to enable PME# after the wake-up power has been enabled for the device. To allow drivers to overcome this problem, introduce function pci_wake_from_d3() that will enable the device to wake up the system from any of D3_hot and D3_cold as long as the wake-up from at least one of them is supported. Acked-by: Pavel Machek Signed-off-by: Rafael J. Wysocki Signed-off-by: Jesse Barnes commit 76e839681aa413924ce18424a1bc9896501e28d6 Author: Stephen Rothwell Date: Tue Aug 19 11:45:55 2008 +1000 PCI: hotplug/rpaphp: remove unused error path code Commit f46753c5e354b857b20ab8e0fe7b2579831dc369 ("PCI: introduce pci_slot") removed the need for this error path. Eliminate this warning: drivers/pci/hotplug/rpaphp_slot.c: In function 'rpaphp_register_slot': drivers/pci/hotplug/rpaphp_slot.c:151: warning: label 'sysfs_fail' defined but not used Signed-off-by: Stephen Rothwell Signed-off-by: Jesse Barnes commit 9da5bc7b975915d2b3fba2f11d5e762d1e5a7da7 Author: Thomas Petazzoni Date: Tue Aug 19 10:28:24 2008 +0200 PCI: allow quirks to be compiled out This patch adds the CONFIG_PCI_QUIRKS option which allows to remove all the PCI quirks, which are not necessarily used on embedded systems when PCI is working properly. As this is a size-reduction option, it depends on CONFIG_EMBEDDED. It allows to save almost 12 kilobytes of kernel code: text data bss dec hex filename 1287806 123596 212992 1624394 18c94a vmlinux.old 1275854 123596 212992 1612442 189a9a vmlinux -11952 0 0 -11952 -2EB0 +/- This patch has originally been written by Zwane Mwaikambo and is part of the Linux Tiny project. Signed-off-by: Thomas Petazzoni Signed-off-by: Jesse Barnes commit 2ea4851c5a950cb7ca7a3c9de8ac6b24aa3670e8 Author: Jean Delvare Date: Sun Aug 17 21:06:59 2008 +0200 PCI: Check dynids driver_data value for validity Only accept dynids whose driver_data value matches one of the driver's pci_driver_id entries. This prevents the user from accidentally passing values the drivers do not expect. Cc: Milton Miller Acked-by: Greg Kroah-Hartman Signed-off-by: Jean Delvare Signed-off-by: Jesse Barnes commit 3021c21fc771e14c463bcacd90c9dd34d5e0b194 Author: Milton Miller Date: Thu Jul 10 16:29:37 2008 -0500 PCI: remove dynids.use_driver_data The driver flag dynids.use_driver_data is almost consistently not set, and causes more problems than it solves. It was initially intended as a flag to indicate whether a driver's usage of driver_data had been carefully inspected and was ready for values from userspace. That audit was never done, so most drivers just get a 0 for driver_data when new IDs are added from userspace via sysfs. So remove the flag, allowing drivers to see the data directly (a followon patch validates the passed driver_data value against what the drivers expect). Acked-by: Greg Kroah-Hartman Acked-by: Jean Delvare Signed-off-by: Milton Miller Signed-off-by: Jesse Barnes commit 46006b35f9e32479181c4ede98980a30ef536a49 Author: Jonathan Corbet Date: Tue Aug 26 17:15:45 2008 -0600 UIO: BKL removal Fill in needed locking around idr accesses, then remove the big kernel lock from the UIO driver. Since there are no in-tree UIO drivers with open() methods, no further BKL pushdown is required. Acked-by: Hans J. Koch Acked-by: Greg Kroah-Hartman Signed-off-by: Jonathan Corbet commit 5b9207ec01681337786c7898ffc0165ec4e7c2e4 Author: Avi Kivity Date: Wed Aug 27 20:01:04 2008 +0300 KVM: MMU: Fix setting the accessed bit on non-speculative sptes The accessed bit was accidentally turned on in a random flag word, rather than, the spte itself, which was lucky, since it used the non-EPT compatible PT_ACCESSED_MASK. Fix by turning the bit on in the spte and changing it to use the portable accessed mask. Signed-off-by: Avi Kivity commit e2c706f9ee9c9236bdcf593d6f1ac6f50b73f557 Author: Takashi Iwai Date: Wed Aug 27 18:12:42 2008 +0200 ALSA: hda - Add descriptions of missing model values Added the descriptions of missing model values. Also, fixed the model strings of a few new models to a standard style. Signed-off-by: Takashi Iwai commit 6eaa802ce5187e8508b07293633af00d8ccc911b Author: Joerg Roedel Date: Wed Aug 27 14:18:43 2008 +0200 KVM: SVM: fix random segfaults with NPT enabled This patch introduces a guest TLB flush on every NPF exit in KVM. This fixes random segfaults and #UD exceptions in the guest seen under some workloads (e.g. long running compile workloads or tbench). A kernbench run with and without that fix showed that it has a slowdown lower than 0.5% Cc: stable@kernel.org Signed-off-by: Joerg Roedel Signed-off-by: Alexander Graf Signed-off-by: Avi Kivity commit 8ab544cf9b4b5d1c87b923e0a3178615f083243b Author: Avi Kivity Date: Wed Aug 27 16:40:51 2008 +0300 KVM: MMU: Flush tlbs after clearing write permission when accessing dirty log Otherwise, the cpu may allow writes to the tracked pages, and we lose some display bits or fail to migrate correctly. Signed-off-by: Avi Kivity commit d2c000b28bda64095936ece73b470c6cf67ef8c3 Author: Avi Kivity Date: Wed Aug 27 16:32:24 2008 +0300 KVM: MMU: Add locking around kvm_mmu_slot_remove_write_access() It was generally safe due to slots_lock being held for write, but it wasn't very nice. Signed-off-by: Avi Kivity commit efdb63f35a2c1f6dfe010a71945c723bbac86263 Author: Avi Kivity Date: Wed Aug 27 16:30:56 2008 +0300 KVM: MMU: Account for npt/ept/realmode page faults Now that two-dimensional paging is becoming common, account for tdp page faults. Signed-off-by: Avi Kivity commit ffbbae25778235324f61e3adf329e860aaff3c37 Author: Joseph Chan Date: Tue Aug 26 14:38:03 2008 +0200 ALSA: hda - Fix VIA recording problem Add a workaround for bad DMA-position reporting on VIA chipset. Signed-off-by: Joseph Chan [modified and cleaned up by tiwai] Signed-off-by: Takashi Iwai commit 0188d6c5807b65e2e20dcb75a668efbe5418b27e Author: Steven Whitehouse Date: Tue Aug 26 09:38:26 2008 +0100 GFS2: Fix & clean up GFS2 rename This patch fixes a locking issue in the rename code by ensuring that we hold the per sb rename lock over both directory and "other" renames which involve different parent directories. At the same time, this moved the (only called from one place) function gfs2_ok_to_move into the file that its called from, so we can mark it static. This should make a code a bit easier to follow. Signed-off-by: Steven Whitehouse Cc: Peter Staubach commit 74379c9ff26dfc1cbb05c227e21da7228c8ecb35 Author: Mohammed Gamal Date: Wed Aug 27 05:02:56 2008 +0300 KVM: x86 emulator: Add mov r, imm instructions (opcodes 0xb0-0xbf) The emulator only supported one instance of mov r, imm instruction (opcode 0xb8), this adds the rest of these instructions. Signed-off-by: Mohammed Gamal Signed-off-by: Avi Kivity commit 11c231a962c740b3216eb6565149ae5a7944cba7 Author: Suresh Siddha Date: Sat Aug 23 17:47:11 2008 +0200 x86: use x2apic id reported by cpuid during topology discovery, fix v2: Fix for !SMP build Signed-off-by: Suresh Siddha Signed-off-by: Ingo Molnar commit eff253c4272cd2aac95ccff46d3d2e1a495f22b1 Author: Gerrit Renker Date: Sat Aug 23 13:28:27 2008 +0200 dccp ccid-3: Replace lazy BUG_ON with condition The BUG_ON(w_tot == 0) only holds if there is no more than 1 loss interval in the loss history. If there is only a single loss interval, the calc_i_mean() routine need in fact not be called (RFC 3448, 6.3.1). Signed-off-by: Gerrit Renker commit 157439fa4a9b38ac4ce41e2fc379fc5031affec8 Author: Gerrit Renker Date: Sat Aug 23 13:28:27 2008 +0200 dccp: Toggle debug output without module unloading This sets the sysfs permissions so that root can toggle the `debug' parameter available for nearly every DCCP module. This is useful since there are various module inter-dependencies. The debug flag can now be toggled at runtime using echo 1 > /sys/module/dccp/parameters/dccp_debug echo 1 > /sys/module/dccp_ccid2/parameters/ccid2_debug echo 1 > /sys/module/dccp_ccid3/parameters/ccid3_debug echo 1 > /sys/module/dccp_tfrc_lib/parameters/tfrc_debug The last is not very useful yet, since no code at the moment calls the tfrc_debug() macro. Signed-off-by: Gerrit Renker commit b569d5a134074d4e15ab8e26cf2dd9f02c29fadc Author: Gerrit Renker Date: Sat Aug 23 13:28:27 2008 +0200 dccp: Empty the write queue when disconnecting dccp_disconnect() can be called due to several reasons: 1. when the connection setup failed (inet_stream_connect()); 2. when shutting down (inet_shutdown(), inet_csk_listen_stop()); 3. when aborting the connection (dccp_close() with 0 linger time). In case (1) the write queue is empty. This patch empties the write queue, if in case (2) or (3) it was not yet empty. This avoids triggering the write-queue BUG_TRAP in sk_stream_kill_queues() later on. It also seems natural to do: when breaking an association, to delete all packets that were originally intended for the soon-disconnected end (compare with call to tcp_write_queue_purge in tcp_disconnect()). Signed-off-by: Gerrit Renker commit 5a056417e696fabab8642ec38783de0b496bde76 Author: Gerrit Renker Date: Sat Aug 23 13:28:27 2008 +0200 dccp: Fill in the Data fields for "Option Error" Resets This updates the use of the `out_invalid_option' label, which produces a Reset (code 5, "Option Error"), to fill in the Data1...Data3 fields as specified in RFC 4340, 5.6. Signed-off-by: Gerrit Renker commit 1efa6bbac876318ebf6f3a757f18e7d9ebe02dd0 Author: Gerrit Renker Date: Sat Aug 23 13:28:27 2008 +0200 dccp: Silently ignore options with nonsensical lengths This updates the option-parsing code with regard to RFC 4340, 5.8: "[..] options with nonsensical lengths (length byte less than two or more than the remaining space in the options portion of the header) MUST be ignored, and any option space following an option with nonsensical length MUST likewise be ignored." Hence in the following cases erratic options will be ignored: 1. The type byte of a multi-byte option is the last byte of the header options (i.e. effective option length of 1). 2. The value of the length byte is less than the minimum 2. This has been changed from previously 3: although no multi-byte option with a length less than 3 yet exists (cf. table 3 in 5.8), a length of 2 is valid. (The switch-statement in dccp_parse has further per-option length checks.) 3. The option length exceeds the length of the remaining option space. Signed-off-by: Gerrit Renker commit 33c449675c0e371edd35b3bd7ce8a14451ff2f0b Author: Wei Yongjun Date: Sat Aug 23 13:28:27 2008 +0200 dccp: Always generate a Reset in response to option errors RFC4340 states that if a packet is received with an option error (such as a Mandatory Option as the last byte of the option list), the endpoint should repond with a Reset. In the LISTEN and RESPOND states, the endpoint correctly reponds with Reset, while in the REQUEST/OPEN states, packets with option errors are just ignored. The packet sequence is as follows: Case 1: Endpoint A Endpoint B (CLOSED) (CLOSED) <---------------- REQUEST RESPONSE -----------------> (*1) (with invalid option) <---------------- RESET (with Reset Code 5, "Option Error") (*1) currently just ignored, no Reset is sent Case 2: Endpoint A Endpoint B (OPEN) (OPEN) DATA-ACK -----------------> (*2) (with invalid option) <---------------- RESET (with Reset Code 5, "Option Error") (*2) currently just ignored, no Reset is sent This patch fixes the problem, by generating a Reset instead of silently ignoring option errors. Signed-off-by: Wei Yongjun Acked-by: Arnaldo Carvalho de Melo Acked-by: Gerrit Renker commit e3c2ced8d21410e8bc897480081e2ffc516c0f70 Author: Julius Volz Date: Fri Aug 22 14:06:13 2008 +0200 IPVS: Rename ip_vs_proto_ah.c to ip_vs_proto_ah_esp.c After integrating ESP into ip_vs_proto_ah, rename it (and the references to it) to ip_vs_proto_ah_esp.c and delete the old ip_vs_proto_esp.c. Signed-off-by: Julius Volz Signed-off-by: Simon Horman commit 409a19669e4cd8d1bab7dff31d3b6aa493ff60f0 Author: Julius Volz Date: Fri Aug 22 14:06:12 2008 +0200 IPVS: Integrate ESP protocol into ip_vs_proto_ah.c Rename all ah_* functions to ah_esp_* (and adjust comments). Move ESP protocol definition into ip_vs_proto_ah.c and remove all usage of ip_vs_proto_esp.c. Make the compilation of ip_vs_proto_ah.c dependent on a new config variable, IP_VS_PROTO_AH_ESP, which is selected either by IP_VS_PROTO_ESP or IP_VS_PROTO_AH. Only compile the selected protocols' structures within this file. Signed-off-by: Julius Volz Signed-off-by: Simon Horman commit 93c06cbbf9fea5d5be1778febb7fa9ab1a74e5f5 Author: Serge E. Hallyn Date: Tue Aug 26 14:47:57 2008 -0500 selinux: add support for installing a dummy policy (v2) In August 2006 I posted a patch generating a minimal SELinux policy. This week, David P. Quigley posted an updated version of that as a patch against the kernel. It also had nice logic for auto-installing the policy. Following is David's original patch intro (preserved especially bc it has stats on the generated policies): se interested in the changes there were only two significant changes. The first is that the iteration through the list of classes used NULL as a sentinel value. The problem with this is that the class_to_string array actually has NULL entries in its table as place holders for the user space object classes. The second change was that it would seem at some point the initial sids table was NULL terminated. This is no longer the case so that iteration has to be done on array length instead of looking for NULL. Some statistics on the policy that it generates: The policy consists of 523 lines which contain no blank lines. Of those 523 lines 453 of them are class, permission, and initial sid definitions. These lines are usually little to no concern to the policy developer since they will not be adding object classes or permissions. Of the remaining 70 lines there is one type, one role, and one user statement. The remaining lines are broken into three portions. The first group are TE allow rules which make up 29 of the remaining lines, the second is assignment of labels to the initial sids which consist of 27 lines, and file system labeling statements which are the remaining 11. In addition to the policy.conf generated there is a single file_contexts file containing two lines which labels the entire system with base_t. This policy generates a policy.23 binary that is 7920 bytes. (then a few versions later...): The new policy is 587 lines (stripped of blank lines) with 476 of those lines being the boilerplate that I mentioned last time. The remaining 111 lines have the 3 lines for type, user, and role, 70 lines for the allow rules (one for each object class including user space object classes), 27 lines to assign types to the initial sids, and 11 lines for file system labeling. The policy binary is 9194 bytes. Changelog: Aug 26: Added Documentation/SELinux.txt Aug 26: Incorporated a set of comments by Stephen Smalley: 1. auto-setup SELINUXTYPE=dummy 2. don't auto-install if selinux is enabled with non-dummy policy 3. don't re-compute policy version 4. /sbin/setfiles not /usr/sbin/setfiles Aug 22: As per JMorris comments, made sure make distclean cleans up the mdp directory. Removed a check for file_contexts which is now created in the same file as the check, making it superfluous. Signed-off-by: Serge Hallyn Signed-off-by: David Quigley Signed-off-by: James Morris commit 8c41be48d999dec99990b94e17ee257618d22574 Author: Sergey Lapin Date: Tue Aug 12 13:35:34 2008 +0100 [ARM] 5219/2: MACB ethernet support for AFEB9260 MACB ethernet support for AFEB9260 Depends on 5210/2 Acked-by: Andrew Victor Signed-off-by: Sergey Lapin Signed-off-by: Russell King commit d48134e709d51d0ce74d0285e2684ecf38438c7a Author: Mike Rapoport Date: Wed Aug 20 09:03:26 2008 +0100 [ARM] 5217/1: update maintainer entry for CompuLab machines Signed-off-by: Mike Rapoport Acked-by: Eric Miao Signed-off-by: Russell King commit fb6ff9a6f948462b240cc4f8df1c87c552584219 Author: Mike Rapoport Date: Wed Aug 20 09:03:02 2008 +0100 [ARM] 5216/1: Add CM-X300 defconfig Signed-off-by: Mike Rapoport Acked-by: Eric Miao Signed-off-by: Russell King commit cf75d8d213f58c01791940c4392c4122e0063bc0 Author: Mike Rapoport Date: Tue Aug 26 14:03:44 2008 +0100 [ARM] 5215/2: Add support for CM-X300 board This patch adds core support for CM-X300 board based on PXA300 processor Signed-off-by: Mike Rapoport Acked-by: Eric Miao Signed-off-by: Russell King commit a461a8d2dff84ab027dd77f04e0d79f95931ef8f Author: Mark Brown Date: Tue Aug 26 10:58:54 2008 +0100 [ARM] 5223/1: zylonite: Staticise zylonite_i2c_board_info Signed-off-by: Mark Brown Acked-by: Eric Miao Signed-off-by: Russell King commit 58d27fcfe64a21c7094e0b60784258e1cccf26a4 Author: Mark Brown Date: Thu Jul 10 17:52:10 2008 +0100 [ARM] 5111/2: zylonite: Configure SSP SSP3 is connected to the voice PCM of the WM9713 audio codec on the Zylonite so configure the MFPs appropriately and select SSP support. Signed-off-by: Mark Brown Acked-by: Eric Miao Signed-off-by: Russell King commit ad826e22c1343ceca76d814539a6fc94dd474def Author: Eric Miao Date: Wed Aug 20 10:18:26 2008 +0800 [ARM] pxa: fix incorrect definitions of SSP3 on pxa320 Signed-off-by: Eric Miao Signed-off-by: Russell King commit e6d492d0a71550bbe3405017be6ab81aaa607323 Author: Jürgen Schindele Date: Mon Aug 18 21:45:03 2008 +0100 [ARM] 5204/1: Trizeps4 SOM update - use MFP-API for GPIO - support TRIZEPS4WL module - cleanups Signed-off-by: Jrgen Schindele Acked-by: Eric Miao Signed-off-by: Russell King commit eda6f6ecbbd6bea070ca296e40c2117d80117b76 Author: Robert Jarzmik Date: Sun Aug 17 09:34:30 2008 +0100 [ARM] 5202/1: pxa: Added Mitac Mio A701 smartphone support. The Mio A701 support features : - GSM support - Bluetooth support - GPS support - LED/Vibrator support - Suspend/Resume support (very dependant on Mio FlashRam) - Screen/Backlight support - Keys/Keyboard support - USB udc support - MMC/SDIO support - Flash Memory support - Battery/AC plugin support Signed-off-by: Robert Jarzmik Signed-off-by: Russell King commit d8ad7859e2044ecae26c4810b8a8c3d17afca0ca Author: Jaya Kumar Date: Sat Aug 16 04:07:18 2008 +0100 [ARM] 5197/1: gumstix: conversion to MFP support and add bluetooth support This patch converts gumstix over to the MFP configuration system and adds bluetooth support. Signed-off-by: Jaya Kumar Acked-by: Eric Miao Signed-off-by: Russell King commit 922613436ae562a2903698f3a6e16998382a549d Author: Jaya Kumar Date: Sun Aug 17 05:59:32 2008 +0100 [ARM] 5200/1: am200epd: use fb notifiers and gpio api The original am200epd driver was designed with bad assumptions. It manipulated GPSR/GPLR registers directly. It relied on direct access to the pxa LCDC registers which have since conflicted with commit ce4fb7b892a6d6c6a0f87366b26fd834d2923dd7 . This patch moves it into mach-pxa and overhauls it to use a fb obtained through fb notifiers. It now uses the generic GPIO api. Signed-off-by: Jaya Kumar Acked-by: Krzysztof Helt Acked-by: Eric Miao Signed-off-by: Russell King commit e935508515cc5592d7c80d7f51f21103f73efb2d Author: Jaya Kumar Date: Tue Aug 19 11:17:55 2008 +0100 [ARM] 5209/1: metronomefb: changes to use platform framebuffer These changes are used in order to support the use of the framebuffer provided by the platform device driver rather than to directly allocate one. Other changes are cleanup to error handling and order of release. Signed-off-by: Jaya Kumar Acked-by: Krzysztof Helt Acked-by: Eric Miao Signed-off-by: Russell King commit 28501336f8b9fb5ec6c2d7bb07b4dfa88ceed272 Author: Jaya Kumar Date: Tue Aug 5 13:52:14 2008 +0100 [ARM] 5186/1: metronomefb: convert printk to dev_dbg/err messages This patch converts the printk messages in metronomefb to dev_dbg/err type messages. Signed-off-by: Jaya Kumar Acked-by: Eric Miao Signed-off-by: Russell King commit a1dadadf571960a5720b5b131eef439e4a457bcd Author: Sergey Lapin Date: Sun Aug 3 02:29:48 2008 +0100 [ARM] 5210/2: AFEB9260: board support This patch adds support for AT91SAM9260-based board AFEB9260 which is a product from both Open Source design which runs Open Source software. Some commertial projects are made with this design. A board is basically AT91SAM9260-EK with some modifications and different peripherals and different parts used. Main purpose of this project is to gain experience in hardware design. More info: http://groups.google.com/group/arm9fpga-evolution-board (In Russian only, sorry). Subversion repository: svn://194.85.238.22/home/users/george/svn/arm9eb By this patch only basic functionality is provided. Signed-off-by: Sergey Lapin Acked-by: Andrew Victor Signed-off-by: Russell King commit 8d8fd15c9d8201f615bdea69cef1d3005e98c2ce Author: Mark Brown Date: Tue Aug 26 15:29:11 2008 +0100 ALSA: ASoC: WM8903 I2C cleanups Fix a few issues identified by Jean Delvare: - Add missing newline to error display. - Return an error when we fail to locate the I2C adaptor. - Remove the static wm8903_i2c_device Jean suggested, it's redundant. Signed-off-by: Mark Brown Acked-by: Jean Delvare Signed-off-by: Takashi Iwai commit 40d353201ef0705b91d7810e8a5338cbb58cbef2 Author: Avi Kivity Date: Tue Aug 26 17:31:31 2008 +0300 KVM: Don't call get_user_pages(.force = 1) This is esoteric and only needed to break COW on MAP_SHARED mappings. Since KVM no longer does these sorts of mappings, breaking COW on them is no longer necessary. Signed-off-by: Avi Kivity commit 0f4275c0f583cf9bb1f9041a4151094abfe13efa Author: Avi Kivity Date: Tue Aug 26 17:22:47 2008 +0300 KVM: Allocate guest memory as MAP_PRIVATE, not MAP_SHARED There is no reason to share internal memory slots with fork()ed instances. Signed-off-by: Avi Kivity commit 5a28eed4c2a3fff72bc012804613186db5cc515d Author: Jean Delvare Date: Tue Aug 26 15:47:55 2008 +0200 ALSA: ASoC: Add missing new-line at end of strings Two warning messages lack their trailing new-line, add it. Signed-off-by: Jean Delvare Signed-off-by: Takashi Iwai commit 438027fdf4cad36897ec6d74d3cc6e7b827e5559 Author: Avi Kivity Date: Fri Aug 22 19:11:39 2008 +0300 KVM: MMU: Convert the paging mode shadow walk to use the generic walker Signed-off-by: Avi Kivity commit 5207d2f61ee59e2bd164d064b92c4465e3c69de8 Author: Avi Kivity Date: Fri Aug 22 19:28:04 2008 +0300 KVM: MMU: Convert direct maps to use the generic shadow walker Signed-off-by: Avi Kivity commit 9ca3307fef5d4c5d699c2bec45cd0e61a50be993 Author: Avi Kivity Date: Fri Aug 22 19:24:38 2008 +0300 KVM: MMU: Add generic shadow walker We currently walk the shadow page tables in two places: direct map (for real mode and two dimensional paging) and paging mode shadow. Since we anticipate requiring a third walk (for invlpg), it makes sense to have a generic facility for shadow walk. This patch adds such a shadow walker, walks the page tables and calls a method for every spte encountered. The method can examine the spte, modify it, or even instantiate it. The walk can be aborted by returning nonzero from the method. Signed-off-by: Avi Kivity commit 67ebadb40c8014e7524eed2ffd68bd21d0fb6ba1 Author: Avi Kivity Date: Tue Aug 26 16:16:08 2008 +0300 KVM: MMU: Infer shadow root level in direct_map() In all cases the shadow root level is available in mmu.shadow_root_level, so there is no need to pass it as a parameter. Signed-off-by: Avi Kivity commit 1b045c3d7c5f9034b4e6ddd71c08713808c9f60d Author: Kailang Yang Date: Tue Aug 26 14:03:29 2008 +0200 ALSA: hda - Add more ALC662/663 codec support - Add support for ECS (1019:9087) - Delete G71V record from alc662_cfg_tbl[] The PCI SubsystemID was the same with M70V - Add more ASUS notebook support Signed-off-by: Kailang Yang Signed-off-by: Takashi Iwai commit 51e1abc0edca9221ff526dd67ac1ab2798563c52 Author: Kailang Yang Date: Tue Aug 26 13:17:46 2008 +0200 ALSA: hda - support more ALC888 devices - Add Lenovo Sky support (17aa:101d) - Add ASUS M90V support (1043:8317) - Add ASUS Eee 1601 support (1043:835f) Signed-off-by: Kailang Yang Signed-off-by: Takashi Iwai commit 6003e779a0d0ecf86d1fb3b9af10b48ad64ed3af Author: Kailang Yang Date: Tue Aug 26 13:13:00 2008 +0200 ALSA: hda - Add support of Quanta FL1 Added the support of Quanta FL1 with ALC269 code chip. Also a bit space clean-ups. Signed-off-by: Kailang Yang Signed-off-by: Takashi Iwai commit e349ad57c1cfafef975c1bc2e347fc98027a335a Author: Kailang Yang Date: Tue Aug 26 13:10:22 2008 +0200 ALSA: hda - Add support of Acer Aspire One Added the support of Acer Aspire One with ALC269 codec chip. Signed-off-by: Kailang Yang Signed-off-by: Takashi Iwai commit 3687cb4c4245b457f124a9f4e660caee4087e114 Author: Kailang Yang Date: Tue Aug 26 13:05:55 2008 +0200 ALSA: hda - Add support of Toshiba S06 Added the support of Toshiba S06 with ALC262 codec chip. Signed-off-by: Kailang Yang Signed-off-by: Takashi Iwai commit c12f537ca054c5f6340a1e363bdd86781ab8f6bb Author: Kailang Yang Date: Tue Aug 26 13:02:23 2008 +0200 ALSA: hda - Add support of HP DC7600 Fixed the support of HP DC7600 with ALC260, which was formerly handled as model=hp-3013. Signed-off-by: Kailang Yang Signed-off-by: Takashi Iwai commit 3399e087123cf0016b6513b22a8cc521d485647e Author: Kailang Yang Date: Tue Aug 26 12:58:38 2008 +0200 ALSA: hda - fix spaces in patch_realtek.c Signed-off-by: Kailang Yang Signed-off-by: Takashi Iwai commit dc86140300e674611abb6527a36b5863c2b808f6 Author: Mark Brown Date: Tue Aug 26 13:05:27 2008 +0100 ALSA: ASoC: Add WM8903 CODEC driver The WM8903 is a high performance ultra-low power stereo CODEC optimised for portable audio applications. Features include: * 5mW power consumption for DAC to headphone playback * Stereo DAC SNR 96dB typical, THD -86dB typical * Stereo ADC SNR 93dB typical, THD -80dB typical * Up to 3 single ended inputs per stereo channel * Up to 2 pseudo differential inputs per stereo channel * Up to 1 fully differential mic input per stereo channel * Digital Dynamic Range Controller (compressor/limiter) * Digital sidetone mixing Signed-off-by: Mark Brown Signed-off-by: Takashi Iwai commit 353d37698a27cff3f5663f92ed61434a3209c37a Author: David Howells Date: Thu Aug 21 14:52:24 2008 +0100 CRED: Document the credential API's (ab)use of const pointers Document the credential API's (ab)use of const pointers. Various pointers to credentials, such as those in the task_struct, are declared const. The purpose of this is to compile-time discouragement of altering credentials through those pointers. Once a set of credentials has been made public through one of these pointers, it may not be modified, except under special circumstances: (1) Its reference count may incremented and decremented. (2) The keyrings to which it points may be modified, but not replaced. The only safe way to modify anything else is to create a replacement and commit using the functions described in Documentation/credentials.txt. Signed-off-by: David Howells Signed-off-by: James Morris commit 3cb851ed491cd7350881a9d2e41499c717434ed1 Author: Cyrill Gorcunov Date: Mon Aug 25 21:27:26 2008 +0400 x86: apic - unify smp_spurious/error_interrupt declaration According to entry_64.S we do pass pt_regs pointer into interrupt handlers but don't use them. So we safely may merge the declarations. Signed-off-by: Cyrill Gorcunov Signed-off-by: Ingo Molnar commit 0acfd728bc11a1fbe3bf8568c93f97ca74e2c47e Author: Xiantao Zhang Date: Tue Aug 26 08:58:53 2008 +0800 KVM: ia64: Enable virtio driver for ia64 in Kconfig kvm/ia64 uses the virtio drivers to optimize its I/O subsytem. Signed-off-by: Xiantao Zhang Signed-off-by: Avi Kivity commit 310e8db127b2cb729240033d2902f742f109b7d2 Author: Yinghai Lu Date: Mon Aug 25 12:41:19 2008 -0700 sparseirq: move kstat_irqs from kstat to irq_desc - fix fix non-sparseirq architectures. Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit 84d0391c75dc8b7ee93f047bb44e95a09674a03d Author: Kumar Gala Date: Fri Jun 27 09:39:00 2008 -0500 math-emu: Add support for reporting exact invalid exception Some architectures (like powerpc) provide status information on the exact type of invalid exception. This is pretty straight forward as we already report invalid exceptions via FP_SET_EXCEPTION. We add new flags (FP_EX_INVALID_*) the architecture code can define if it wants the exact invalid exception reported. We had to split out the INF/INF and 0/0 cases for divide to allow reporting the two invalid forms properly. Signed-off-by: Kumar Gala Acked-by: David S. Miller commit 1a550192702469d03f718e31f3978423d1085b45 Author: Kumar Gala Date: Fri Jun 27 09:33:59 2008 -0500 math-emu: Fix compiler warnings Fix warnings of the form: arch/powerpc/math-emu/fsubs.c:15: warning: 'R_f1' may be used uninitialized in this function arch/powerpc/math-emu/fsubs.c:15: warning: 'R_f0' may be used uninitialized in this function Signed-off-by: Kumar Gala commit d53d018535098ba8f0ebc050c7b3b4ba627acad7 Author: Johannes Berg Date: Tue Jul 8 19:00:26 2008 +0200 remove CONFIG_KMOD Now that nothing depends on it any more, remove CONFIG_KMOD. Signed-off-by: Johannes Berg Signed-off-by: Rusty Russell commit b49727ef9f3a2ea2466065ccf2d51aa1dc862d85 Author: Rusty Russell Date: Tue Aug 26 10:19:48 2008 +1000 module:remove-kmod.c-CONFIG_KMOD-comment Signed-off-by: Rusty Russell commit 4cb9da6ecc2b0e25056b45981239475f8509d59d Author: Johannes Berg Date: Wed Jul 9 10:28:42 2008 +0200 remove CONFIG_KMOD from net Some code here depends on CONFIG_KMOD to not try to load protocol modules or similar, replace by CONFIG_MODULES where more than just request_module depends on CONFIG_KMOD and and also use try_then_request_module in ebtables. Signed-off-by: Johannes Berg Cc: netdev@vger.kernel.org Signed-off-by: Rusty Russell commit f04b9ade38c4edf8faef164a8af580dfc30c5716 Author: Johannes Berg Date: Wed Jul 9 10:28:40 2008 +0200 remove CONFIG_KMOD from fs Just always compile the code when the kernel is modular. Convert load_nls to use try_then_request_module to tidy up the code. Signed-off-by: Johannes Berg Signed-off-by: Rusty Russell commit 2b6ec5275e92de2dc08545d14ea515563e78f0b9 Author: Johannes Berg Date: Wed Jul 9 10:28:38 2008 +0200 remove CONFIG_KMOD from drivers Straight forward conversions to CONFIG_MODULE; many drivers include conditionally and then don't have any other conditional code so remove it from those. Signed-off-by: Johannes Berg Cc: video4linux-list@redhat.com Cc: David Woodhouse Cc: linux-ppp@vger.kernel.org Cc: dm-devel@redhat.com Signed-off-by: Rusty Russell commit 51e0f004a9ab9104acbe323c0b20e0279bf9be85 Author: David S. Miller Date: Mon Aug 25 16:44:58 2008 -0700 sparc64: Fix irq_of_parse_and_map() and irq_dispose_mapping(). Stephen Rothwell noticed that I committed an earlier version of the patch that didn't have two things fixed: 1) irq_of_parse_and_map() should return "unsigned int" not "int" and it should return zero for "no irq" 2) irq_dispose_mapping() should be an inline function, not a macro, for type checking With feedback and suggestions from Anton Vorontsov. Signed-off-by: David S. Miller commit 783c98b911fce8d47aa2906468ca39d44d46d7ce Author: David S. Miller Date: Mon Aug 25 16:21:08 2008 -0700 sparc64: Use the cond_syscall()s in kernel/sys_ni.c instead of home-grown copy. This also allows arch/sparc64/kernel/pci.c to be properly CONFIG_PCI conditional compiled in the Makefile. Signed-off-by: David S. Miller commit c23889ca5afcce60bb01739cd831c3cbcbab2a06 Author: Dominik Brodowski Date: Tue Aug 26 00:09:56 2008 +0200 pcmcia: cleanup socket services header file The header file for use by (in-kernel) PCMCIA sockets deserved a major cleanup. Some stuff only used by the pcmcia core modules was moved to cs_internal.h Signed-off-by: Dominik Brodowski commit b60a5ede1e3a6a09a881c3ff014164fbe4d481b4 Author: Dominik Brodowski Date: Mon Aug 25 23:32:37 2008 +0200 pcmcia: merge ds_internal.h into cs_internal.h Merge ds_internal.c into cs_internal.h. Signed-off-by: Dominik Brodowski commit dc953e550bf1624a17465b9deb15487fdde98869 Author: Dominik Brodowski Date: Mon Aug 25 23:18:20 2008 +0200 pcmcia: cleanup cs_internal.h Small cleanup to cs_internal.h. Signed-off-by: Dominik Brodowski commit 33343723cfad49efa16a8f9d97cc1ae9fe088fa1 Author: Dominik Brodowski Date: Mon Aug 25 23:12:20 2008 +0200 pcmcia: cs_internal.h is internal cs_internal.h is meant for definitions internal to the PCMCIA core modules. It must not be included by PCMCIA socket drivers or by PCMCIA device drivers. Signed-off-by: Dominik Brodowski commit 85269eb5542b425b99d79dc4c312dce0157eac7e Author: David S. Miller Date: Mon Aug 25 13:38:30 2008 -0700 sparc64: Add JBUS UltraSPARC-IIIi support to memory controller driver. Signed-off-by: David S. Miller commit 14f68716ee226450e18a0fab9d58d6e7cbd88b5a Author: Steven Rostedt Date: Mon Aug 25 14:52:11 2008 -0400 ftrace: objcopy version test for local symbols The --globalize-symbols option came out in objcopy version 2.17. If the kernel is being compiled on a system with a lower version of objcopy, then we can not use the globalize / localize trick to link to symbols pointing to local functions. This patch tests the version of objcopy and will only use the trick if the version is greater than or equal to 2.17. Otherwise, if an object has only local functions within a section, it will give a nice warning and recommend the user to upgrade their objcopy. Leaving the symbols unrecorded is not that big of a deal, since the mcount record method changes the actual mcount code to be a simple "ret" without recording registers or anything. Reported-by: Stephen Rothwell Signed-off-by: Steven Rostedt Signed-off-by: Ingo Molnar commit 601c0bc46753007be011b513ba4fc50ed8e30aef Author: Adrian Hunter Date: Fri Aug 22 14:23:35 2008 +0300 UBIFS: allow for racing between GC and TNC The TNC mutex is unlocked prematurely when reading leaf nodes with non-hashed keys. This is unsafe because the node may be moved by garbage collection and the eraseblock unmapped, although that has never actually happened during stress testing. This patch fixes the flaw by detecting the race and retrying with the TNC mutex locked. Signed-off-by: Adrian Hunter commit 761e29f3bb19b05bea55285dfdf2d28e001a63b8 Author: Adrian Hunter Date: Wed Aug 20 16:32:40 2008 +0300 UBIFS: always read hashed-key nodes under TNC mutex Leaf-nodes that have a hashed key are stored in the leaf-node-cache (LNC) which is protected by the TNC mutex. Consequently, when reading a leaf node with a hashed key (i.e. directory entries, xattr entries) the TNC mutex is always required. Signed-off-by: Adrian Hunter commit d68156cfad0fe09201dd049fff167a8a881427ad Author: Singh, Vimal Date: Sat Aug 23 18:18:34 2008 +0200 [MTD] [NAND] nand_ecc.c: adding support for 512 byte ecc Support 512 byte ECC calculation [FM: updated two comments] Signed-off-by: Vimal Singh Signed-off-by: Frans Meulenbroeks Signed-off-by: David Woodhouse commit dffc8d66544563fe00f176f230d5d8a5b45847bb Author: Huang Weiyi Date: Sat Aug 23 13:56:21 2008 +0800 [MTD] [NAND] au1550nd.c: remove unused #include It doesn't use LINUX_VERSION_CODE nor KERNEL_VERSION. This patch removes the said #include . Signed-off-by: Huang Weiyi Signed-off-by: David Woodhouse commit 670be1820d611b2710345516cad7fed8f5b7aae8 Author: Adrian Bunk Date: Wed Aug 6 01:36:09 2008 +0300 KVM: fix userspace ABI breakage The following part of commit 9ef621d3be56e1188300476a8102ff54f7b6793f (KVM: Support mixed endian machines) changed on the size of a struct that is exported to userspace: include/linux/kvm.h: Packing a struct was the correct idea, but it packed the wrong struct. Signed-off-by: Adrian Bunk Signed-off-by: Avi Kivity commit c09ff7e1744047be1043cb32453ef90b7f6b8451 Author: Stephen Rothwell Date: Mon Aug 25 20:22:21 2008 +1000 linux-next: fix x86 tree build failure Today's linux-next build (powerpc allyesconfig) failed like this: drivers/char/agp/uninorth-agp.c:541: error: unknown field 'agp_destroy_paged' specified in initializer Caused by commit 5f310b63781f6777bf4e812570560ec0f8ea42d8 ("agp: enable optimized agp_alloc_pages methods"). A simple typo ... Signed-off-by: Stephen Rothwell Signed-off-by: Ingo Molnar commit de82ff783bcb2b52353a7c99b4a8524ae739da73 Author: Bjorn Helgaas Date: Fri Aug 22 09:47:17 2008 -0600 PNPACPI: ignore the producer/consumer bit for extended IRQ descriptors The Extended Interrupt descriptor has a producer/consumer bit, but it's not clear what that would mean, and existing BIOSes use the bit inconsistently. This patch makes Linux PNPACPI ignore the bit. The ACPI spec contains examples of PCI Interrupt Link devices marked as ResourceProducers, but many BIOSes mark them as ResourceConsumers. I also checked with a Windows contact, who said: Windows uses only "resource consumer" when dealing with interrupts. There's no useful way of looking at a resource producer of interrupts. ... NT-based Windows largely infers the producer/consumer stuff from the device type and ignores the bits in the namespace. This was necessary because Windows 98 ignored them and early namespaces contained random junk. The reason I want to change this is because if PNPACPI devices exclude ResourceProducer IRQ resources, we can't write PNP drivers for those devices. For example, on machines such as the the HP rx7620, rx7640, rx8620, rx8640, and Superdome, HPET interrupts are ResourceProducers. The HPET driver currently has to use acpi_bus_register_driver() and do its own _CRS parsing, even though it requires absolutely no ACPI-specific functionality. It would be better if the HPET driver were a PNP driver and took advantage of the _CRS parsing built into PNPACPI. This producer/consumer check was originally added here: http://git.kernel.org/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commitdiff;h=2b8de5f50e4a302b83ebcd5b0120621336d50bd6 to fix this bug: http://bugzilla.kernel.org/show_bug.cgi?id=6292 However, the bug was related only to memory and I/O port resources, where the distinction is sensible and important to Linux. Given that the distinction is muddled for IRQ resources, I think it was a mistake to add the check there. Signed-off-by: Bjorn Helgaas Signed-off-by: Andi Kleen commit 0107b425e1a6e1fbd5adb032046c1cf58176b9f3 Author: Yinghai Lu Date: Sun Aug 24 22:41:26 2008 -0700 x86: let 64 bit to use 32 bit calibrate_apic_clock Use the 32-bit APIC calibration code - it's more mature. Signed-of-by: Yinghai Lu Signed-off-by: Ingo Molnar commit 432238adfc79e07b8c8630ef699c1038bfbe0f5f Author: Ingo Molnar Date: Mon Aug 25 08:12:04 2008 +0200 ftrace: clean up macro usage enclose the argument in parenthesis. (especially since we cast it, which is a high prio operation) Signed-off-by: Ingo Molnar commit b2528d2a50942e9d546d3c2e29cde89336053a03 Author: Stephen Rothwell Date: Mon Aug 25 13:08:44 2008 +1000 ftrace: fix build failure After disabling FTRACE_MCOUNT_RECORD via a patch, a dormant build failure surfaced: kernel/trace/ftrace.c: In function 'ftrace_record_ip': kernel/trace/ftrace.c:416: error: incompatible type for argument 1 of '_spin_lock_irqsave' kernel/trace/ftrace.c:433: error: incompatible type for argument 1 of '_spin_lock_irqsave' Introduced by commit 6dad8e07f4c10b17b038e84d29f3ca41c2e55cd0 ("ftrace: add necessary locking for ftrace records"). Signed-off-by: Stephen Rothwell Signed-off-by: Ingo Molnar commit e25ae4fd3ccba79cfd5628642754a145394225f6 Author: Risto Suominen Date: Mon Aug 25 08:04:23 2008 +0200 ALSA: snd-powermac: HP detection for 1st iMac G3 SL Correct headphone detection for 1st generation iMac G3 Slot-loading (Screamer). Signed-off-by: Risto Suominen Signed-off-by: Takashi Iwai commit 8352a6fe67a0f804302b93178f2e13b66004a693 Author: Risto Suominen Date: Mon Aug 25 08:02:12 2008 +0200 ALSA: snd-powermac: mixers for PowerMac G4 AGP Add mixer controls for PowerMac G4 AGP (Screamer). Signed-off-by: Risto Suominen Signed-off-by: Takashi Iwai commit ec49727d81d9b485e570b0697e0b075bc9c55fbb Author: Krzysztof Helt Date: Sun Aug 24 18:08:03 2008 +0200 ALSA: wss_lib: do not mess mixer settings during probe Use the wss_dout function which does not mess shadowed register values during chip probing. Otherwise, user ends up with stupid mixer settings after driver loading. Signed-off-by: Krzysztof Helt Acked-by: Rene Herman Signed-off-by: Takashi Iwai commit 41660e9ac639c97840258d3c5294f618ca8cc46f Author: David S. Miller Date: Sun Aug 24 22:17:29 2008 -0700 sparc64: Allow chmc to be built as a module. Signed-off-by: David S. Miller commit 881d021ab0d675f519b68df916fde969940ef988 Author: David S. Miller Date: Sun Aug 24 22:08:34 2008 -0700 sparc64: Add generic interface for registering a dimm printing handler. The way to do this varies by platform type and the exact memory controller the cpu uses. For Spitfire cpus we currently just use prom_getunumber() and hope that works. For Cheetah cpus we have a memory controller driver that can compute this information. Signed-off-by: David S. Miller commit e311be521fa9daedd8959d1a89f5e9bc5b54bb40 Author: Adrian Bunk Date: Fri Aug 22 18:20:36 2008 +0300 sh: fix ptrace_64.c:user_disable_single_step() This patch fixes the following compile error caused by commit c459dbf294b4a3d70490a468a7ca3907fb2c2f57 (sh: ptrace single stepping cleanups.): <-- snip --> ... CC arch/sh/kernel/ptrace_64.o arch/sh/kernel/ptrace_64.c: In function 'user_disable_single_step': arch/sh/kernel/ptrace_64.c:134: error: 'regs' undeclared (first use in this function) arch/sh/kernel/ptrace_64.c:134: error: (Each undeclared identifier is reported only once arch/sh/kernel/ptrace_64.c:134: error: for each function it appears in.) ... make[2]: *** [arch/sh/kernel/ptrace_64.o] Error 1 <-- snip --> Reported-by: Adrian Bunk Signed-off-by: Adrian Bunk Signed-off-by: Paul Mundt commit a1068264522cb0a9b863d5357ade844e490bea41 Author: Adrian Bunk Date: Fri Aug 22 18:20:29 2008 +0300 sh64: re-add the __strnlen_user() prototype Commit 42fd3b142d8867f5b58d6fb75592cd20fd654c1b (sh: Initial consolidation of the _32/_64 uaccess split.) mistakenly removed the sh64 __strnlen_user() prototype, resulting in the following compile error: <-- snip --> ... CC init/main.o In file included from include/linux/poll.h:13, from include/linux/rtc.h:113, from include/linux/efi.h:19, from init/main.c:43: arch/sh/include/asm/uaccess.h: In function 'strnlen_user': arch/sh/include/asm/uaccess.h:213: error: implicit declaration of function '__strnlen_user' ... make[2]: *** [init/main.o] Error 1 <-- snip --> Reported-by: Adrian Bunk Signed-off-by: Adrian Bunk Signed-off-by: Paul Mundt commit 83ef64b9dea6e3ed287a45d56166913bffcd2497 Author: David S. Miller Date: Sun Aug 24 21:45:44 2008 -0700 sparc64: Use consistent chmc_ prefix in variables, types, and functions. Signed-off-by: David S. Miller commit b28422e32b9127ab4178ce05a419069db3d11d19 Author: David S. Miller Date: Sun Aug 24 21:32:42 2008 -0700 sparc64: Convert UltraSPARC-III memory controller driver to OF driver probing. Signed-off-by: David S. Miller commit e04180882faf69e896a8131ff3137788dd08b8d3 Author: David S. Miller Date: Sun Aug 24 20:59:49 2008 -0700 hwmon: Add Ultra45 workstation hwmon driver. This is a PIC16F747 based controller that monitors and consolidates the hardware access to various fan and temperature values reported by adr7462 and similar devices behind an I2C bus. Signed-off-by: David S. Miller commit 8394b3a84bf3e4665da4e535d34980aa6ba78969 Author: David S. Miller Date: Sun Aug 24 20:13:42 2008 -0700 sparc64: Kill duplicated sys_pause() implementation. sys32_pause() is identical to the generically provided sys_pause() in kernel/signal.c Noticed by Christoph Hellwig. Signed-off-by: David S. Miller commit fe06ccaad20257e3bd348b2df9e811fd92211a80 Author: David S. Miller Date: Sun Aug 24 20:10:23 2008 -0700 sparc64: Split syscall_trace() into two functions. Christoph Hellwig noticed that having both entry and exit logic in one function no longer makes sense, and having seperate ones simplifies things a lot. Signed-off-by: David S. Miller commit 15df0f3302fdecaa97da0b95d72b3a9a59be8692 Author: David S. Miller Date: Wed Aug 20 23:03:24 2008 -0700 sparc: Add GPIO layer support. Signed-off-by: David S. Miller commit 44266215e3c8209613cea014721015113b7cd2d9 Author: David S. Miller Date: Wed Aug 20 16:34:39 2008 -0700 sparc: Implement irq_of_parse_and_map() and irq_dispose_mapping(). This allows more OF layer code to be shared between powerpc and sparc. Signed-off-by: David S. Miller commit 2481d76615d5e15340ccfb0243fe8779766dfc6e Author: David S. Miller Date: Tue Aug 19 21:56:35 2008 -0700 sparc: Add mutex for set property calls. On some platforms, the I2C controller is shared between the OS and OBP. OBP uses this I2C controller to access the EEPROM, and thus is programmed when the kernel calls prom_setprop(). Wrap such calls with the new of_set_property_mutex. Relevant I2C bus drivers can grab this mutex around top-level I2C operations to provide the proper protection. Signed-off-by: David S. Miller commit 072bd413b88c17509c7aa7dbc398ab8bade633b3 Author: David S. Miller Date: Mon Aug 18 20:36:17 2008 -0700 sparc64: Add JBUS NUMA detection. Signed-off-by: David S. Miller commit 0ee6c14f7f9adb84b85b5173ea64f96a178d5f23 Author: Avi Kivity Date: Sun Aug 24 19:27:56 2008 +0300 Revert "generic-ipi: fix stack and rcu interaction bug in smp_call_function_mask()" This reverts commit cc7a486cac78f6fc1a24e8cd63036bae8d2ab431. commit 1eab1da64958863ba2ab3be6e46d114c61b6a77f Author: Avi Kivity Date: Sun Aug 24 19:27:32 2008 +0300 Revert "generic-ipi: fix stack and rcu interaction bug in smp_call_function_mask(), fix" This reverts commit c2fc11985db304572322f1dcdcb0f71337315006. commit 33a430468ce61c55f628e91a88b29cc706be6b42 Author: Yinghai Lu Date: Sun Aug 24 02:01:56 2008 -0700 x86: rename apic_32.c and apic_64.c to apic.c Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit 25ef8fe031ac2cbe7ef476a4f9b7203552f95f89 Author: Yinghai Lu Date: Sun Aug 24 02:01:55 2008 -0700 x86: apic copy apic_64.c to apic_32.c Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit 3132ec89b5a1eac3e9453c7b5c54faf4d7d9a295 Author: Yinghai Lu Date: Sun Aug 24 02:01:54 2008 -0700 x86: apic copy calibrate_APIC_clock to each other in apic_32/64.c Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit b0d0552b07348f1c4e4d065b1b3bcae212fc8c13 Author: Yinghai Lu Date: Sun Aug 24 02:01:53 2008 -0700 x86: apic unify smp_spurious/error_interrupt Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit 12f4d09b87527d780ad0ce549fec122b3deb601b Author: Yinghai Lu Date: Sun Aug 24 02:01:52 2008 -0700 x86: merge header files in apic_xx.c Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit 1f3b645c73dcc4f5bb744aa530b464484639a273 Author: Yinghai Lu Date: Sun Aug 24 02:01:51 2008 -0700 x86: copy detect_init_APIC to the other Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit 6972ab5fdd81be684bd1683930fdfc01c037525a Author: Yinghai Lu Date: Sun Aug 24 02:01:50 2008 -0700 x86: merge APIC_init_uniprocessor Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit 2cfcb91adbc4241af9683f5a61eebacee2a09ccf Author: Yinghai Lu Date: Sun Aug 24 02:01:49 2008 -0700 x86: make apic_32/64.c more like except x2apic, detec_init_APIC, and calibrating_APIC_clock Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit 624b9d5dcf0858610192b7fa642569b17561f066 Author: Yinghai Lu Date: Sun Aug 24 02:01:48 2008 -0700 x86: add hard_smp_prossor_id with MACRO in io_apic_xx.c Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit 46c55c10ecd19a3ed0a40ba6f93e189af7872a16 Author: Yinghai Lu Date: Sun Aug 24 02:01:47 2008 -0700 x86: use HAVE_X2APIC in apic_64.c Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit ab235ba9ce3768aee8a841b78172bdd6894cedc1 Author: Yinghai Lu Date: Sun Aug 24 02:01:46 2008 -0700 x86: apic_xx.c order variables Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit f4058daa26ed7a4195c16cb13b4827c527d884eb Author: Cyrill Gorcunov Date: Sun Aug 24 02:01:45 2008 -0700 x86: apic - unify smp_apic_timer_interrupt Signed-off-by: Cyrill Gorcunov Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit 3122920e500d0641f0b8e2ae2b2495902eb5f352 Author: Cyrill Gorcunov Date: Sun Aug 24 02:01:44 2008 -0700 x86: apic_32.c should use __cpuinit section All callers are __init or __cpuinit so there is no need to hold this code without CPU_HOTPLUG being set. Signed-off-by: Cyrill Gorcunov Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit 342579d5b76a3098478a6437fa11506eb37bde8e Author: Cyrill Gorcunov Date: Sun Aug 24 02:01:43 2008 -0700 x86: apic - unify setup_local_APIC - remove useless read of APIC_LVR - wrap with preempt_disable/enable - check for integrated APIC just in place v2: fix by Yinghai Lu. fix lapic_is_integrated using let 64-bit too have pic_mode Signed-off-by: Cyrill Gorcunov Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit 6240bbd01004a09b9facc5cd386a4b190667a8ee Author: Cyrill Gorcunov Date: Sun Aug 24 02:01:42 2008 -0700 x86: apic_64.c - add sanity check for spurious vector definition Do not check for SPUTIOUS_APIC_VECTOR definition twice. Check it once - is what we need. Signed-off-by: Cyrill Gorcunov Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit 6ed4232439f72373f2696f780cd3fc964273a436 Author: Cyrill Gorcunov Date: Sun Aug 24 02:01:41 2008 -0700 x86: apic - unify setup_apicpmtimer Signed-off-by: Cyrill Gorcunov Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit 07a81c2c6213c46b8e2b4a4f0531a716bca1f7ec Author: Cyrill Gorcunov Date: Sun Aug 24 02:01:40 2008 -0700 x86: apic - introduce get_physical_broadcast for 64bit We don't really use it now on 64bit mode but could reserve it for future. Signed-off-by: Cyrill Gorcunov Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit e97b6d50a182b21673527dfe5f3d2e515e98f8b8 Author: Cyrill Gorcunov Date: Sun Aug 24 02:01:39 2008 -0700 x86: apic_64.c - setup_APIC_timer has to be __cpuinit function There is no need to hold this code if CPU_HOTPLUG is not defined. Signed-off-by: Cyrill Gorcunov Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit e17941b0c140562d92e5a3bc12b4ad88281c7926 Author: Suresh Siddha Date: Sat Aug 23 17:47:11 2008 +0200 x86: use x2apic id reported by cpuid during topology discovery use x2apic id reported by cpuid during topology discovery, instead of the apic id configured in the APIC. For most of the systems, x2apic id reported by cpuid leaf 0xb will be same as the physical apic id reported by the APIC_ID register of the APIC. We follow the suggested guidelines and use the apic id reported by the cpuid. No change to non-generic UV platforms, will use the apic id reported in the APIC_ID register as the cpuid reported apic id's may not be unique. Signed-off-by: Suresh Siddha Signed-off-by: Ingo Molnar commit bbb65d2d365efe9951290e61678dcf81ec60add4 Author: Suresh Siddha Date: Sat Aug 23 17:47:10 2008 +0200 x86: use cpuid vector 0xb when available for detecting cpu topology cpuid leaf 0xb provides extended topology enumeration. This interface provides the 32-bit x2APIC id of the logical processor and it also provides a new mechanism to detect SMT and core siblings (which provides increased addressability). Signed-off-by: Suresh Siddha Signed-off-by: Ingo Molnar commit 01de05af94db5d5214b0a5e191068d19c82059a8 Author: Venki Pallipadi Date: Fri Aug 22 12:08:17 2008 -0700 x86: have set_memory_array_{uc,wb} coalesce memtypes, fix Fix the start addr for free_memtype calls in the error path. Signed-off-by: Venkatesh Pallipadi Acked-by: Rene Herman Signed-off-by: Ingo Molnar commit 9c7205161b03a43861765a26fc72f5a00fdadf75 Author: Krzysztof Hałasa Date: Thu Aug 14 19:18:17 2008 +0200 WAN: syncppp.c is no longer used by any kernel code. Remove it. Signed-off-by: Krzysztof Hałasa commit a4356b2920fd4861dd6c75f558749fa5c38a00e8 Author: Ilpo Järvinen Date: Sat Aug 23 05:12:29 2008 -0700 tcp: Add tcp_parse_aligned_timestamp Some duplicated code lying around. Located with my suffix tree tool. Signed-off-by: Ilpo Järvinen Signed-off-by: David S. Miller commit 2cf46637b501794d7fe9e365f0a3046f5d1f5dfb Author: Ilpo Järvinen Date: Sat Aug 23 05:11:41 2008 -0700 tcp: Add tcp_collapse_one to eliminate duplicated code Signed-off-by: Ilpo Järvinen Signed-off-by: David S. Miller commit cbe2d128a01315fb4bd55b96cf8b963f5df28ea2 Author: Ilpo Järvinen Date: Sat Aug 23 05:10:12 2008 -0700 tcp: Add tcp_validate_incoming & put duplicated code there Large block of code duplication removed. Sadly, the return value thing is a bit tricky here but it seems the most sensible way to return positive from validator on success rather than negative. Signed-off-by: Ilpo Järvinen Signed-off-by: David S. Miller commit 79ba6757277ea7228480bee4c56c0f028f806b91 Author: Dominik Brodowski Date: Sun Aug 3 14:03:07 2008 +0200 pcmcia: use dev_printk for cs_error() Use dev_printk() in cs_error()-based error reporting. While this function-turned-macro will hopefully go away soon, using dev_printk simplifies the code much. Signed-off-by: Dominik Brodowski commit 9c8b7965f594fdff37c59446b9314ed7b4b44d07 Author: Dominik Brodowski Date: Sun Aug 3 12:27:56 2008 +0200 pcmcia: remove CS_ error codes alltogether Remoe the CS_ error codes. Drivers are expected to use default error definitions (errno.h etc.). Only one CS_ error code -- CS_IN_USE -- is used internally by the (deprecated) pcmcia-cs userspace package. Therefore, keep this one around so that it still compiles. Signed-off-by: Dominik Brodowski commit 3f9c5f4cb7e00d424a56a6431e9c98b3b17851e4 Author: Dominik Brodowski Date: Sun Aug 3 12:22:40 2008 +0200 pcmcia: deprecate CS_BAD_TUPLE CS_BAD_TUPLE was used to denote a bad tuple being passed to the parse function. Therefore, replace it with -EINVAL and a verbose message. Signed-off-by: Dominik Brodowski commit 926c5402c287f6d911f7d00f936f09ea00880527 Author: Dominik Brodowski Date: Sun Aug 3 12:15:11 2008 +0200 pcmcia: deprecate CS_BAD_ARGS CS_BAD_ARGS mean a badly written driver or invalid userspace ioctl access, so translate that to -EINVAL. Signed-off-by: Dominik Brodowski commit 69ba44331e81e4a15b504175ec70b7b4b4e5a8b9 Author: Dominik Brodowski Date: Sun Aug 3 12:10:53 2008 +0200 pcmcia: deprecate CS_BAD_BASE, CS_BAD_IRQ, CS_BAD_OFFSET and CS_BAD_SIZE These four error values mostly mean a badly written driver, so ds_dbg() output and -EINVAL seems to be enough. Signed-off-by: Dominik Brodowski commit 610e23749e87920136e1a221266a43cb7e3823f1 Author: Dominik Brodowski Date: Sun Aug 3 11:58:53 2008 +0200 pcmcia: deprecate CS_BAD_ATTRIBUTE, CS_BAD_TYPE and CS_BAD_PAGE CS_BAD_TYPE was only used in cs.c and already properly annotated by error messages. CS_BAD_ATTRIBUTE and CS_BAD_PAGE mean a badly written driver, so ds_dbg() output and -EINVAL seems to be enough. (includes bugfix from and Signed-off-by: Harvey Harrison ) Signed-off-by: Dominik Brodowski commit 635d19bea0e91df473a81391ec8f3db2d049a218 Author: Dominik Brodowski Date: Sun Aug 3 11:47:29 2008 +0200 pcmcia: deprecate CS_NO_MORE_ITEMS CS_NO_MORE_ITEMS is returned by the CIS tuple reading and parsing code if the end of a tuple chain is reached. As at least one PCMCIA driver relies on matching this return value, replace it with -ENOSPC which is now uniquely used for this purpose within the in-kernel pcmcia subsystem. CC: Russell King CC: linux-serial@vger.kernel.org CC: Michael Buesch Signed-off-by: Dominik Brodowski commit f958095ef4fc96e978c6eddcaca29100e5276c7f Author: Dominik Brodowski Date: Sun Aug 3 11:40:19 2008 +0200 pcmcia: deprecate CS_IN_USE If a resource is already in use, mark it with -EBUSY. Same for cards already asleep. (includes a fix for a bug found by Larry Finger -- thanks!) Signed-off-by: Dominik Brodowski commit 943f70f1b5182c5220641ccb7bb905005162e227 Author: Dominik Brodowski Date: Sun Aug 3 11:23:42 2008 +0200 pcmcia: deprecate CS_CONFIGURATION_LOCKED This error code meant that trying to change the configuration after the initialization phase is forbidden. Signed-off-by: Dominik Brodowski commit ffb8da20271bcfb343e299e5f630dab9ccfb6214 Author: Dominik Brodowski Date: Sun Aug 3 11:18:00 2008 +0200 pcmcia: deprecate CS_BAD_HANDLE CS_BAD_HANDLE means that something went badly wrong: no parameter was passed, or the paramater passed wasn't the correct one. Therefore, replace it with -EINVAL. Signed-off-by: Dominik Brodowski commit 8567142e87322141f9344d1ab632ccf5190cd0d3 Author: Dominik Brodowski Date: Sun Aug 3 11:15:45 2008 +0200 pcmcia: deprecate CS_GENERAL_FAILURE It's only used by pcmcia_core when socket-related queries time out. Signed-off-by: Dominik Brodowski commit 3939c1ef1f954409d1441c09fbc08376655758fe Author: Dominik Brodowski Date: Sun Aug 3 11:10:56 2008 +0200 pcmcia: deprecate CS_NO_CARD It means that no card can be detected in the socket, so return -ENODEV Signed-off-by: Dominik Brodowski commit d8b0a49da4f213c637d458319432016f4ea5e12a Author: Dominik Brodowski Date: Sun Aug 3 10:56:13 2008 +0200 pcmcia: deprecate CS_BAD_VCC and CS_BAD_VPP They were either used to report that changing voltage is not allowed, or that changing voltage failed. Signed-off-by: Dominik Brodowski commit de6405e9d1e7530ea33b62e1a3921338f836a046 Author: Dominik Brodowski Date: Sun Aug 3 10:47:59 2008 +0200 pcmcia: deprecate CS_UNSUPPORTED_* CS_UNSUPPORTED_MODE and CS_UNSUPPORTED_FUNCTION were mostly used to denote trying to use PCMCIA functions on CardBus cards. Signed-off-by: Dominik Brodowski commit 1168386aa7d850ead2ae135d5a7949a592c6e9a0 Author: Dominik Brodowski Date: Sun Aug 3 10:22:47 2008 +0200 pcmcia: deprecate CS_OUT_OF_RESOURCE CS_OUT_OF_RESOURCE was almost only used to note -ENOMEM situations. Therefore, use -ENOMEM explicitely, and also print out warnings. CC: netdev@vger.kernel.org Signed-off-by: Dominik Brodowski commit 5ff87db6792844ae24cc784512a95e0c94521b19 Author: Dominik Brodowski Date: Sun Aug 3 10:36:50 2008 +0200 pcmcia: deprecate unused CS_ error codes Deprecate unused CS_ error codes by replacing their definitions with generic error messages, and removing them from the error_t lookup table. Signed-off-by: Dominik Brodowski commit 4c89e88bfde6a3c179790e21004f24e09a058290 Author: Dominik Brodowski Date: Sun Aug 3 10:07:45 2008 +0200 pcmcia: deprecate CS_SUCCESS Instead of using own error or success codes, the PCMCIA code should rely on the generic return values. Therefore, replace all occurrences of CS_SUCCESS with 0. CC: netdev@vger.kernel.org Signed-off-by: Dominik Brodowski commit 1a53088c101789bfca431de709ff6e45e8c77003 Author: Dominik Brodowski Date: Sun Aug 3 08:57:51 2008 +0200 pcmcia: move config_info_t definition to ioctl-related parts in header files Signed-off-by: Dominik Brodowski commit 64f346425175ad33812cd693fbca48cd512dab63 Author: Dominik Brodowski Date: Sat Aug 2 17:00:46 2008 +0200 pcmcia: move pccard_get_configuration_info to ioctl With the PCMCIA ioctl being the only remaining user of _get_configuration_info, move the function to pcmcia_ioctl.c Signed-off-by: Dominik Brodowski commit ef313e36d8896a42fc567a83a5d4b86821634e8d Author: Dominik Brodowski Date: Sat Aug 2 16:25:26 2008 +0200 pcmcia: remove remaining in-kernel pcmcia_get_configuration_info() users Remove the three remaining pcmcia_get_configuration_info() users: - pcmciamtd is marked broken anyway. - serial_cs.c can access the relevant structs directly - ipwireless didn't use the output CC: linux-serial@vger.kernel.org CC: Russell King Acked-by: David Sterba Signed-off-by: Dominik Brodowski commit 7d16b658bd093e75a9f72a69e2dafd2b154c4395 Author: Dominik Brodowski Date: Sat Aug 2 21:02:01 2008 +0200 pcmcia: don't add extra DEBUG cflag Use CONFIG_PCMCIA_DEBUG instead of DEBUG so that dev_dbg() and other tricks work properly. (includes bugfixes from and Signed-off-by: Stephen Rothwell Signed-off-by: Larry Finger ) Signed-off-by: Dominik Broodwski commit 2bccc2a89012173f48a690caea7d9e4b3e950db9 Author: Dominik Brodowski Date: Sun Aug 3 09:03:53 2008 +0200 pcmcia: remove unused cs_socket_name() definition Signed-off-by: Dominik Brodowski commit dbe4ea5fde198a3808e46b665d889818c1e600f5 Author: Dominik Brodowski Date: Sat Aug 2 21:36:19 2008 +0200 pcmcia: use dev_printk in module rsrc_nonstatic Signed-off-by: Dominik Brodowski commit ac449d6e2c81d26f91d092aba114ab3cb2a02ca0 Author: Dominik Brodowski Date: Sat Aug 2 18:33:56 2008 +0200 pcmcia: use dev_printk in module pcmcia (includes bugfix from and Signed-off-by: Harvey Harrison ) Signed-off-by: Dominik Brodowski commit 2e55bf6b99fb05f3f4228e7f1381624ac8ac7e3d Author: Dominik Brodowski Date: Sat Aug 2 18:08:38 2008 +0200 pcmcia: use dev_printk in module pcmcia_core Signed-off-by: Dominik Brodowski commit dd797d81d3d7da31a50031f2741b93327ed22260 Author: Dominik Brodowski Date: Sat Aug 2 17:54:14 2008 +0200 pcmcia: use dev_printk and dev_dbg in yenta_socket Signed-off-by: Dominik Brodowski commit 23edcc4147ad36f8d55f0eb79c21e245ffb9f211 Author: David Kilroy Date: Thu Aug 21 23:28:05 2008 +0100 orinoco: Add MIC on TX and check on RX Use the MIC algorithm from the crypto subsystem. Signed-off-by: David Kilroy Signed-off-by: John W. Linville commit 31afcef385bb8bf528c6fbe05b359af9f456f02a Author: David Kilroy Date: Thu Aug 21 23:28:04 2008 +0100 orinoco: Process bulk of receive interrupt in a tasklet Read the packet data off the hardware and straight into an skb in the interrupt. We have to do this in case we don't process the tasklet in time. Signed-off-by: David Kilroy Signed-off-by: John W. Linville commit 06009fda9fde1b97074ab3d932d0468396bf5d10 Author: David Kilroy Date: Thu Aug 21 23:28:03 2008 +0100 orinoco: Send association events to userspace Signed-off-by: David Kilroy Signed-off-by: John W. Linville commit d03032af511c56d3c1580fa4f54f6285f650e638 Author: David Kilroy Date: Thu Aug 21 23:28:02 2008 +0100 orinoco: Add WE-18 ioctls for WPA Includes basic plumbing to get the data into firmware, and retrieve it. SIOCxIWGENIE simply record (and return) the IE, and do not act on it. SIOCxIWENCODEEXT, SIOCxIWAUTH and SIOCSIWMLME should be as functional as the driver will support. Signed-off-by: David Kilroy Signed-off-by: John W. Linville commit 409644a98bfffef79985f2c39924a06288b1dfcf Author: David Kilroy Date: Thu Aug 21 23:28:01 2008 +0100 orinoco: Use a macro to define wireless handlers The macro identifiers for the various ioctls required for WPA support are longer than those currently used by the driver. This makes it messy to keep line length below 80 character. By defining a macro to initialise the handler table, we recover the common text. Signed-off-by: David Kilroy Signed-off-by: John W. Linville commit 6cd90b1cac290c64a93b7e992bb1ef495988465f Author: David Kilroy Date: Thu Aug 21 23:28:00 2008 +0100 orinoco: Split wevent work thread from wevent sending This allows us to send more wevents from the work thread. We will need to do this to support WPA. Signed-off-by: David Kilroy Signed-off-by: John W. Linville commit 4ae6ee2d72e4904909d63c6ebb0240b254b72e85 Author: David Kilroy Date: Thu Aug 21 23:27:59 2008 +0100 orinoco: Don't use boolean parameter to record encoding type For WPA support we need to encode NONE, WEP and TKIP in the encoding parameter. In anticipation of this we need to change the usage away from the current boolean usage. Signed-off-by: David Kilroy Signed-off-by: John W. Linville commit 01632fa4af34addf78ce999eabb4430f33942ee2 Author: David Kilroy Date: Thu Aug 21 23:27:58 2008 +0100 orinoco: Use extended Agere scans available on 9.x series firmwares This provides more information than the standard Agere scan, including the WPA IE. Signed-off-by: David Kilroy Signed-off-by: John W. Linville commit 3056c40426b9cd4f7c334d773d69db64e195431d Author: David Kilroy Date: Thu Aug 21 23:27:57 2008 +0100 orinoco: address checkpatch typedef warning Just sprinkle the necessary structs around... Signed-off-by: David Kilroy Signed-off-by: John W. Linville commit 6eecad77861b193bcfc109de12835ca0bddf7c58 Author: David Kilroy Date: Thu Aug 21 23:27:56 2008 +0100 orinoco: Fix transmit for Agere/Lucent with fw 9.x The tx control word has moved into the 802.11 header area on these firmwares. Signed-off-by: David Kilroy Signed-off-by: John W. Linville commit 3994d502017a2239e30152d1231843ad05d04a7b Author: David Kilroy Date: Thu Aug 21 23:27:54 2008 +0100 orinoco: Invoke firmware download in main driver Firmware download is enabled for Agere in orinoco_cs. Symbol firmware download has been moved out of spectrum_cs into orinoco_cs. Firmware download is not enabled for Intersil. Symbol based firmware is restricted to only download on spectrum_cs based cards. The firmware names are hardcoded for each firmware type. Signed-off-by: David Kilroy Signed-off-by: John W. Linville commit 8f5ae73c5366128d3800cf9765507422bcf1ef96 Author: David Kilroy Date: Thu Aug 21 23:27:53 2008 +0100 orinoco: Extend hermes_dld routines for Agere firmware Add programming initialisation and termination functions. Add checks to avoid overrunning the firmware image or PDA areas. Extra algorithm to program PDA values using defaults where necessary. Signed-off-by: David Kilroy Signed-off-by: John W. Linville commit e23341809b7b60981d14a368155cd1f0724fb8d5 Author: David Kilroy Date: Thu Aug 21 23:27:52 2008 +0100 orinoco: Make firmware download logic more generic Ensure PDA read is terminated. Prevent invalid programming blocks from causing reads outside the firmware image Turn off aux stuff when finished. Option to program in limited block sizes (controlled by macro). Option to read PDA from EEPROM. Signed-off-by: David Kilroy Signed-off-by: John W. Linville commit f482eb797a391a098046a934f55af8bd785a4494 Author: David Kilroy Date: Thu Aug 21 23:27:51 2008 +0100 orinoco: Move firmware download functionality into new module Move the functionality from spectrum_cs to hermes_dld in preparation for making it more generic and usable by other orinoco drivers. Signed-off-by: David Kilroy Signed-off-by: John W. Linville commit fc5a62d8b7052ea588e4f7750cd78b0c4c47015a Author: David Kilroy Date: Thu Aug 21 23:27:50 2008 +0100 orinoco: Add function to execute Hermes initialisation commands synchronously The current synchronous execution function doesn't work for certain Hermes commands which clear the MAGIC number from SWSUPPORT0. These commands seem to be related to initialisation or programming, for example HERMES_CMD_INIT. Replicate hermes_docmd_wait for commands which clear the MAGIC number from SWSUPPORT0. This version accepts two extra arguments which are passed straight to the firmware. Functionality copied out of hermes_init. Signed-off-by: David Kilroy Signed-off-by: John W. Linville commit 82a06ee518f570eb8fbb6588e75a4a5d838ac901 Author: David Kilroy Date: Thu Aug 21 23:27:49 2008 +0100 orinoco: Move EXPORT_SYMBOL declarations next to exported function Signed-off-by: David Kilroy Signed-off-by: John W. Linville commit a1d81f1523de0c588f1d7798a49d66559f538e4f Author: David Kilroy Date: Thu Aug 21 23:27:48 2008 +0100 orinoco: Specify all three parameters to every Hermes command. hermes_issue_cmd now takes two more parameters. Signed-off-by: David Kilroy Signed-off-by: John W. Linville commit 17a1a887041ea39a19c5d469f1e31df940b00622 Author: David Kilroy Date: Thu Aug 21 23:27:47 2008 +0100 orinoco: Update scan translation Report channel, beacon interval and capabilities. Use WEXT defines instead of magic numbers. State quality stats in dB. Also a few changes to keep line length less than 80. Signed-off-by: David Kilroy Signed-off-by: John W. Linville commit 0753bba2d45762f83b9f4db94d15a3047f592964 Author: David Kilroy Date: Thu Aug 21 23:27:46 2008 +0100 orinoco: Add ESSID specific scanning for Agere fw Pass the ESSID to the card. This allows 'iwlist eth1 scan essid ' to work, and will help with routers setup not to broadcast the ESSID. Signed-off-by: David Kilroy Signed-off-by: John W. Linville commit ad913c11928f51abb6174f165db8d8d205b22e21 Author: Dominik Brodowski Date: Sat Aug 2 16:12:00 2008 +0200 pcmcia: pcmcia_config_loop() improvement by passing vcc By passing the current Vcc setting to the pcmcia_config_loop callback function, we can remove pcmcia_get_configuration_info() calls from many drivers. Signed-off-by: Dominik Brodowski commit 8e2fc39ddea7fe8c6798837da282db88a09af793 Author: Dominik Brodowski Date: Sat Aug 2 15:30:31 2008 +0200 pcmcia: pcmcia_config_loop() default CIS entry handling Many drivers use the default CIS entry within their pcmcia_config_loop() callback function. Therefore, factor the default CIS entry handling out. Signed-off-by: Dominik Brodowski commit 498ac1899b62626bf6879a251d75c22ec564c559 Author: Dominik Brodowski Date: Sat Aug 2 14:59:13 2008 +0200 pcmcia: pcmcia_config_loop() ConfigIndex unification Almost all drivers set p_dev->conf.ConfigIndex to cfg->index in the pcmcia_config_loop() callback function. Therefore, factor it out. Signed-off-by: Dominik Brodowski commit 84e2d34004dcd0c90d1af43a143511b334f11a4d Author: Dominik Brodowski Date: Tue Jul 29 08:38:55 2008 +0200 pcmcia: use pcmcia_loop_config in misc pcmcia drivers Use the config loop helper in misc pcmcia drivers. CC: Harald Welte CC: CC: Russell King CC: Ed Okerson CC: linux-serial@vger.kernel.org CC: boti@rocketmail.com CC: linux-usb@vger.kernel.org Signed-off-by: Dominik Brodowski commit b54bf94bf91e4ca2a489eb02bca0424ddb55242a Author: Dominik Brodowski Date: Sat Aug 2 14:28:43 2008 +0200 pcmcia: use pcmcia_loop_config in net pcmcia drivers Use the config loop helper in (some) net pcmcia drivers. CC: netdev@vger.kernel.org Signed-off-by: Dominik Brodowski commit 5fcd4da0090828bd34a1956cb322a483c6bf163c Author: Dominik Brodowski Date: Tue Jul 29 08:38:55 2008 +0200 pcmcia: use pcmcia_loop_config in ISDN pcmcia drivers Use the config loop helper in ISDN pcmcia drivers. CC: Karsten Keil Signed-off-by: Dominik Brodowski commit 0e6f9d2708409cd8e864cdb94edbe599872a19d1 Author: Dominik Brodowski Date: Tue Jul 29 08:38:55 2008 +0200 pcmcia: use pcmcia_loop_config in scsi pcmcia drivers Use the config loop helper in scsi pcmcia drivers. CC: James E.J. Bottomley CC: linux-scsi@vger.kernel.org Signed-off-by: Dominik Brodowski commit ed58872aa33e16a0d5352080e47c65fa14e6ad1c Author: Dominik Brodowski Date: Tue Jul 29 08:38:55 2008 +0200 pcmcia: use pcmcia_loop_config in bluetooth drivers Use the config loop helper in bluetooth pcmcia drivers. CC: Marcel Holtmann CC: linux-bluetooth@vger.kernel.org Signed-off-by: Dominik Brodowski commit 0bac660a77b672f85d713d1898382993299df5de Author: Dominik Brodowski Date: Tue Jul 29 08:43:20 2008 +0200 pcmcia: use pcmcia_loop_config in pata and ide drivers Use the config loop helper in pata_pcmcia and ide_cs CC: Tejun Heo CC: Alan Cox CC: linux-ide@vger.kernel.org Signed-off-by: Dominik Brodowski commit a804b574e6c7236222593046fc2b1b8bd0298fce Author: Dominik Brodowski Date: Tue Jul 29 08:38:30 2008 +0200 pcmcia: add pcmcia_loop_config() helper By calling pcmcia_loop_config(), a pcmcia driver can iterate over all available configuration options. During a driver's probe() phase, one doesn't need to use pcmcia_get_{first,next}_tuple, pcmcia_get_tuple_data and pcmcia_parse_tuple directly in most if not all cases. Signed-off-by: Dominik Brodowski commit 795659ef0ee175d47723f806e7a29427b171e61b Author: Dominik Brodowski Date: Sun Aug 3 21:12:07 2008 +0200 pcmcia: uniform device IDs of pata_pcmcia and ide-cs Over time, a few differences have accumulated between pata_pcmcia and ide-cs. Fix those. CC: linux-ide@vger.kernel.org Signed-off-by: Dominik Brodowski commit 68c2a629cc39176260a3827fc213bd49ae02a3e3 Author: David Howells Date: Fri Aug 22 14:46:36 2008 +0100 CRED: Further fix execve cred_exec_mutex handling [ver #2] Further fix the way cred_exec_mutex is handled by [compat_]do_execve(). The mutex is now only unlocked by the function that locked it, and is no longer unlocked by free_bprm() or install_exec_creds(). This means that PTRACE_ATTACH may have to wait a little longer before being allowed to proceed. This patch cleans up the order in which the mutex is locked and unlocked and gets rid of a potential double unlock. Signed-off-by: David Howells Signed-off-by: James Morris commit 9a73e7fdd6dee11cde5c9c872cc3700cefb3ce9f Author: Henrik Kretzschmar Date: Sat Aug 9 03:54:24 2008 -0300 V4L/DVB (8682): V4L: fix return value of register video func If a wrong device type is used with video_register_device_index() it should better return an error number, instead of a constant. Signed-off-by: Henrik Kretzschmar Signed-off-by: Mauro Carvalho Chehab commit ebf62569865de19d89493f43394f8ad2f1f72cd3 Author: Alexander Beregalov Date: Thu Aug 21 19:09:42 2008 -0300 V4L/DVB (8681): v4l2-ioctl.c: fix warning drivers/media/video/v4l2-ioctl.c:496: warning: format '%08ld' expects type 'long int', but argument 5 has type 'suseconds_t' Signed-off-by: Alexander Beregalov Signed-off-by: Mauro Carvalho Chehab commit b6e002a02b5e37e0b3345e690aa0ca9544f867cf Author: Stephen Rothwell Date: Fri Aug 22 16:33:18 2008 -0400 Input: cm109 - don't use obsolete logging macros err(), warn(), info() are being removed in favor of dev_* variants. Signed-off-by: Stephen Rothwell Signed-off-by: Dmitry Torokhov commit 2338263e2cb3cd2f77cdc3fcab0312b6c7fc02c3 Author: Henrik Rydberg Date: Fri Aug 22 16:18:22 2008 -0400 Input: bcm5974 - add maintainer entry Signed-off-by: Henrik Rydberg Signed-off-by: Dmitry Torokhov commit 9859b81eaeb8d48563b5fbd90215c0ae606455a3 Author: Ron Rindjunsky Date: Sat Aug 9 03:02:19 2008 +0300 mac80211: add direct probe before association This patch adds a direct probe request as first step in the association flow if data we have is not up to date. Motivation of this step is to make sure that the bss information we have is correct, since last scan could have been done a while ago, and beacons do not fully answer this need as there are potential differences between them and probe responses (e.g. WMM parameter element) Signed-off-by: Ron Rindjunsky Signed-off-by: Tomas Winkler Signed-off-by: John W. Linville commit 32ddf0718590f410d5f18cb4fcda419f4aeefc57 Author: Christian Lamparter Date: Fri Aug 8 21:17:37 2008 +0200 p54: rename prism54xyz -> p54xyz It's been a long time, but fullmac prism54 driver is still around... I think we should rename every prism54* in order to avoid some confusion about "what is actually what" in the future ;-). Thanks-to: Maxi Signed-off-by: Christian Lamparter Signed-off-by: John W. Linville commit 6042a3e3ff7943e4ff5cbcb8c223ea87337501ea Author: Ron Rindjunsky Date: Fri Aug 8 01:50:46 2008 +0300 mac80211: change number of pre-assoc scans This patch fixes noticed problem in noisy environments of 50+ APs that scan fails to find the requested AP on first try, which leads to connection refusal. second scan has empirically proven to fix this problem in almost all cases. Signed-off-by: Ron Rindjunsky Signed-off-by: Esti Kummer Signed-off-by: Tomas Winkler Signed-off-by: John W. Linville commit 008c44825db74c6cdcea13dfb1598896e74fe908 Author: Ivo van Doorn Date: Wed Aug 6 17:27:31 2008 +0200 rt2x00: Add module parameter to disable HW crypto Add a module parameter to rt61 and rt73 to disable HW crypto. The option should only be checked when determining if the SUPPORT_HW_CRYPTO flag should be set or not. Signed-off-by: Ivo van Doorn Signed-off-by: John W. Linville commit ba2ab47129eee76f6f0ef52b4beae30a12cee7f6 Author: Ivo van Doorn Date: Wed Aug 6 16:22:17 2008 +0200 rt2x00: Move lna_gain calculation to config() callback We can optimize lna calculation in IRQ context by calculating most of the value during the config() callback when most of the value is actually influenced. This will be required later by rt2800pci and rt2800usb as well, since they need the lna_gain value during config(). Signed-off-by: Ivo van Doorn Signed-off-by: John W. Linville commit 48c2fc59aa415ba92be0ad3a7e741c46883e3944 Author: Tomas Winkler Date: Wed Aug 6 14:22:01 2008 +0300 mac80211: cleanup mlme state namespace This patch move add STA_MLME to station mlme state defines. Signed-off-by: Tomas Winkler Acked-by: Johannes Berg Signed-off-by: John W. Linville commit 06303352d3de02a371ccaec1366a92db5e1d7c30 Author: Bruno Randolf Date: Tue Aug 5 19:32:23 2008 +0200 ath5k: set short preamble flag for rx set the short preamble flag in ieee80211_rx_status for frames received with a short preamble. drivers/net/wireless/ath5k/base.c: Changes-licensed-under: 3-Clause-BSD Signed-off-by: Bruno Randolf Signed-off-by: John W. Linville commit edcc25b22f7c328f56e8c129afa1e10c8bacb2ef Author: Ivo van Doorn Date: Mon Aug 4 16:39:05 2008 +0200 rt2x00: Release rt2x00 2.2.0 Signed-off-by: Ivo van Doorn Signed-off-by: John W. Linville commit 8c5e7a5f59f9d11597bd47de28334da318ea0e80 Author: Ivo van Doorn Date: Mon Aug 4 16:38:47 2008 +0200 rt2x00: Gather channel information in structure Channel information which is read from EEPROM should be read into an array containing per-channel information. This removes the requirement of multiple arrays and makes the channel handling a bit cleaner and easier to expand. Signed-off-by: Ivo van Doorn Signed-off-by: John W. Linville commit 906c110fcc24bdd5bf0fa22d89ac75d99c747e53 Author: Ivo van Doorn Date: Mon Aug 4 16:38:24 2008 +0200 rt2x00: Implement HW encryption (rt73usb) rt73usb supports hardware encryption. rt73usb supports up to 4 shared keys and up to 64 pairwise keys. Signed-off-by: Ivo van Doorn Signed-off-by: John W. Linville commit 61e754f44b57060464b1fcf261a8428ecfa23bed Author: Ivo van Doorn Date: Mon Aug 4 16:38:02 2008 +0200 rt2x00: Implement HW encryption (rt61pci) rt61pci supports hardware encryption. rt61pci supports up to 4 shared keys and up to 64 pairwise keys. Signed-off-by: Ivo van Doorn Signed-off-by: John W. Linville commit 2bb057d07a0bc17475a7bf897fc41667ab08b73f Author: Ivo van Doorn Date: Mon Aug 4 16:37:44 2008 +0200 rt2x00: Implement HW encryption Various rt2x00 devices support hardware encryption. Most of them require the IV/EIV to be generated by mac80211, but require it to be provided seperately instead of within the frame itself. This means that rt2x00lib should extract the data from the frame and place it in the frame descriptor. During RX the IV/EIV is provided in the descriptor by the hardware which means that it should be inserted into the frame by rt2x00lib. Signed-off-by: Ivo van Doorn Signed-off-by: John W. Linville commit 8e7cdbb6333ef7654e708bd60e50a123688dcd7b Author: Tomas Winkler Date: Sun Aug 3 14:32:01 2008 +0300 mac80211: filter probes in ieee80211_rx_mgmt_probe_resp This patch moves filtering statement from ieee80211_rx_bss_info which is called for both beacon and probe to ieee80211_rx_mgmt_probe_resp and save few cycles in beacon parsing. Signed-off-by: Tomas Winkler Signed-off-by: John W. Linville commit f698d856f65c3fea091cc303a135967965c5b880 Author: Jasper Bryant-Greene Date: Sun Aug 3 12:04:37 2008 +1200 replace net_device arguments with ieee80211_{local,sub_if_data} as appropriate This patch replaces net_device arguments to mac80211 internal functions with ieee80211_{local,sub_if_data} as appropriate. It also does the same for many 802.11s mesh functions, and changes the mesh path table to be indexed on sub_if_data rather than net_device. If the mesh part needs to be a separate patch let me know, but since mesh uses a lot of mac80211 functions which were being converted anyway, the changes go hand-in-hand somewhat. This patch probably does not convert all the functions which could be converted, but it is a large chunk and followup patches will be provided. Signed-off-by: Jasper Bryant-Greene Signed-off-by: John W. Linville commit fef1643bf0cdd092a52dc3378479e4811fd65152 Author: Jasper Bryant-Greene Date: Sun Aug 3 11:30:55 2008 +1200 move ETH_P_PAE from ieee80211_i.h to if_ether.h ETH_P_PAE belongs in if_ether.h with the other ETH_P_* definitions. This patch moves it there. Signed-off-by: Jasper Bryant-Greene Acked-by: Johannes Berg Signed-off-by: John W. Linville commit 96c87607ac8f9b0e641d11ba6e57f8ec0214ea1c Author: Henrique de Moraes Holschuh Date: Sat Aug 2 15:11:00 2008 -0300 rfkill: introduce RFKILL_STATE_MAX While it is interesting to not add last-enum-markers because it allows gcc to warn us of switch() statements missing a valid state, we really should be handling memory corruption on a rfkill state with default clauses, anyway. So add RFKILL_STATE_MAX and use it where applicable. It makes for safer code in the long run. Signed-off-by: Henrique de Moraes Holschuh Acked-by: Ivo van Doorn Signed-off-by: John W. Linville commit 77fba13ccc3a2a3db100892a4a6cc5e2f8290cc7 Author: Henrique de Moraes Holschuh Date: Sat Aug 2 15:10:59 2008 -0300 rfkill: add __must_check annotations rfkill is not a small, mere detail in wireless support. Once it starts supporting rfkill and users start counting on that support, a wireless device is at risk of operating in dangerous conditions should rfkill support fail to properly activate. Therefore, add the required __must_check annotations on some key functions of the rfkill API, for which the wireless drivers absolutely MUST handle the failure mode safely in order to avoid a potentially dangerous situation where the wireless transmitter is left enabled when the user don't want it to. Signed-off-by: Henrique de Moraes Holschuh Acked-by: Ivo van Doorn Cc: Matthew Garrett Signed-off-by: John W. Linville commit 9961920199ec88d6b581d3e38502088935925c04 Author: Henrique de Moraes Holschuh Date: Sat Aug 2 15:10:58 2008 -0300 rfkill: add default global states (v2) Add a second set of global states, "rfkill_default_states", to track the state that will be used when the first rfkill class of a given type is registered, and also to save "undo" information when rfkill_epo is called. Add a new exported function, rfkill_set_default(), which can be used by platform drivers to restore radio state saved by the platform across reboots or shutdown. Also, fix rfkill_epo to properly update rfkill_states, but still preserve a copy of the state so that we can undo the effect of rfkill_epo later if we want to. Add rfkill_restore_states() to restore rfkill_states from the copy. Signed-off-by: Henrique de Moraes Holschuh Acked-by: Ivo van Doorn Signed-off-by: John W. Linville commit 02589f60510030a3c1496e7a8c511e4f674ef5ff Author: Henrique de Moraes Holschuh Date: Sat Aug 2 15:10:57 2008 -0300 rfkill: detect bogus double-registering (v2) Detect and abort with -EEXIST if rfkill_register is called twice on the same rfkill struct. And WARN_ON(it) for good measure. While at it, flag when we are adding the first switch of a type, we will need that information later. Signed-off-by: Henrique de Moraes Holschuh Acked-by: Ivo van Doorn Cc: Johannes Berg Signed-off-by: John W. Linville commit c94c93da90a9e46a73a5733ff8454fb4b14733fb Author: Harvey Harrison Date: Mon Jul 28 23:01:34 2008 -0700 wireless: replace __FUNCTION__ with __func__ __FUNCTION__ is gcc-specific, use __func__ Signed-off-by: Harvey Harrison Signed-off-by: John W. Linville commit d9c6350431d0c8cac000c6a230d9a20dad52e26d Author: Luis Carlos Cobo Date: Thu Aug 14 10:41:10 2008 -0700 libertas_tf: config and makefile Signed-off-by: Luis Carlos Cobo Signed-off-by: John W. Linville commit c305a19a0d0a47ac59a58865a4a63be65b1bf7c8 Author: Luis Carlos Cobo Date: Thu Aug 14 10:41:06 2008 -0700 libertas_tf: usb specific functions The libertas thin firmware only supports usb devices, but the usb functions have been kept separate to ease future support for other devices. Signed-off-by: Luis Carlos Cobo Signed-off-by: John W. Linville commit 691cdb49388b808bfbfacaea93afb5c2807db45e Author: Luis Carlos Cobo Date: Thu Aug 14 10:41:01 2008 -0700 libertas_tf: command helper functions for libertas_tf Signed-off-by: Luis Carlos Cobo Signed-off-by: John W. Linville commit 06b16ae5319251c26377afcb401e46056d5673f4 Author: Luis Carlos Cobo Date: Thu Aug 14 10:40:57 2008 -0700 libertas_tf: main.c, data paths and mac80211 handlers This patch contains most of the libertastf driver, just lacking command helper functions and usb specific functions. Currently, monitor, managed, ap and mesh interfaces are supported. Even though this driver supports the same hardware as the "libertas" driver, it uses a different (thin) firmware, that makes it suitable for a mac80211 driver. Signed-off-by: Luis Carlos Cobo Signed-off-by: John W. Linville commit 7670e62c7ed6d1a70a98c3047898712be6aa9ff8 Author: Luis Carlos Cobo Date: Thu Aug 14 10:40:52 2008 -0700 libertas_tf: header file Signed-off-by: Luis Carlos Cobo Signed-off-by: John W. Linville commit bdbe819540f3365249095692118dbfeee308140d Author: Luis Carlos Cobo Date: Thu Aug 14 10:40:48 2008 -0700 mac80211: allow no mac address until firmware load Originally by Johannes Berg. This patch adds support for devices that do not report their MAC address until the firmware is loaded. While the address is not known, a multicast on is used. Signed-off-by: Luis Carlos Cobo Signed-off-by: John W. Linville commit 4eb2ae9a42b77de48ee9fecfaccc66c640313188 Author: Harvey Harrison Date: Tue Jul 15 18:44:15 2008 -0700 mac80211: remove WLAN_FC_DATA_PRESENT All users are gone now. Signed-off-by: Harvey Harrison Signed-off-by: John W. Linville commit a4b7d7bda566acaa65fbf767f65a83b3a8dc74b9 Author: Harvey Harrison Date: Tue Jul 15 18:44:14 2008 -0700 mac80211: remove rx/tx_data->fc member Signed-off-by: Harvey Harrison Signed-off-by: John W. Linville commit 358c8d9d332230b14e130b78a6930996cdbf84c2 Author: Harvey Harrison Date: Tue Jul 15 18:44:13 2008 -0700 mac80211: use ieee80211 frame control directly Remove the last users of the rx/tx_data->fc data members and use the le16 frame_control from the header directly. Signed-off-by: Harvey Harrison Signed-off-by: John W. Linville commit e7827a7031a931c74c48e4a53f73ed862f0c8da0 Author: Harvey Harrison Date: Tue Jul 15 18:44:13 2008 -0700 mac80211: remove IEEE80211_FC helper Signed-off-by: Harvey Harrison Signed-off-by: John W. Linville commit 6b644e524bbd4089a28e0711de4f1cf2daa5db50 Author: Harvey Harrison Date: Tue Jul 15 18:44:12 2008 -0700 mac80211: remove ieee80211_get_hdrlen All users have been moved over to the version taking a le16 frame control rather than a cpu-endian value. Signed-off-by: Harvey Harrison Signed-off-by: John W. Linville commit b73d70ad8665fd3f35c855075b9a94de3e2b69e2 Author: Harvey Harrison Date: Tue Jul 15 18:44:12 2008 -0700 mac80211: rx.c/tx.c remove more users of tx/rx_data->fc Those functions that still use ieee80211_get_hdrlen are moved over to use the little endian frame control. Signed-off-by: Harvey Harrison Signed-off-by: John W. Linville commit d298487260d01934a8df3a4a2a09513d84a8e69b Author: Harvey Harrison Date: Tue Jul 15 18:44:10 2008 -0700 mac80211: wep.c replace magic numbers in IV/ICV removal Signed-off-by: Harvey Harrison Signed-off-by: John W. Linville commit c44d040e186e1af9d947f7bad886b7c1d35a22f6 Author: Harvey Harrison Date: Tue Jul 15 18:44:07 2008 -0700 mac80211: wme.h remove unused QOS_CONTROL_LEN linux/ieee80211.h now has IEEE80211_QOS_CTL_LEN for this purpose. Signed-off-by: Harvey Harrison Signed-off-by: John W. Linville commit 62bf1d762e24006fa9b6c8d56a22cf47a2310af3 Author: Harvey Harrison Date: Tue Jul 15 18:44:05 2008 -0700 mac80211: explicitly check skb->len ieee80211_get_hdrlen_from_skb internally checks the skb is long enough to hold the full ieee80211_hdr, else it returns zero. Use ieee80211_hdrlen which always returns the hdrlen and check the remaining room in the skb explicitly when removing encryption headers or the qos control field. Signed-off-by: Harvey Harrison Signed-off-by: John W. Linville commit 798ee9850e9bf94b4436f9c7238823322e326885 Author: Harvey Harrison Date: Tue Jul 15 18:44:02 2008 -0700 ath5k: explicitly check skb->len ieee80211_get_hdrlen_from_skb internally checks that the skb is long enough to hold the full header, or it returns 0 if not. The check in ath5k does not check this case and assumes it always got the actual header length which it then checks against the skb->len plus some headroom. Change to ieee80211_hdrlen which always returns the hdrlen and keep the existing headroom check. Signed-off-by: Harvey Harrison Signed-off-by: John W. Linville commit 7294ec955cb0c3eeefca2f4dd271c8068ab4edc5 Author: Harvey Harrison Date: Tue Jul 15 18:43:59 2008 -0700 iwlwifi: use le16 frame control directly, use QOS symbolic constant mask Signed-off-by: Harvey Harrison Signed-off-by: John W. Linville commit ba5b6efe5d945f7a4c5b656051cc16698afdda24 Author: Harvey Harrison Date: Tue Jul 15 18:43:56 2008 -0700 b43legacy: use le16 frame control directly, avoid byteswapping Acked-by: Michael Buesch Signed-off-by: Harvey Harrison Signed-off-by: John W. Linville commit ded2ae7c1fbff22516fd55ff0edcf6cd86f76186 Author: Esti Kummer Date: Mon Aug 4 16:00:45 2008 +0800 iwlwifi: add level for debugging host command This patch adds another level for debugging host command. This adds an option to suppress the debug prints for sensitivity and link quality commands. Signed-off-by: Esti Kummer Signed-off-by: Tomas Winkler Signed-off-by: Zhu Yi Signed-off-by: John W. Linville commit 39351fa343289070f6f30bd0652e10c8d97f0a3b Author: Tomas Winkler Date: Mon Aug 4 16:00:41 2008 +0800 iwlwifi: kill struct iwl4965_lq_mngr This patch removes struct iwl4965_lq_mngr it is not used. Signed-off-by: Tomas Winkler Signed-off-by: Zhu Yi Signed-off-by: John W. Linville commit 73ae98a1334c7ab7c4f01e8a1c0c773470979688 Author: roel kluin Date: Mon Jul 21 20:29:52 2008 -0400 iwl-4965: test below 0 on unsigned num_tbs num_tbs is unsigned so the test doesn't work. Signed-off-by: Roel Kluin Signed-off-by: John W. Linville commit 6f0a2c4dfc96d268233a6a882f3805975f91216c Author: Bruno Randolf Date: Wed Jul 30 17:20:14 2008 +0200 iwlwifi: use generic mac80211 radiotap headers remove drivers own implementation of radiotap in favor of the generic one provided by mac80211. also remove priv->add_radiotap because it is not used any more. Signed-off-by: Bruno Randolf Signed-off-by: John W. Linville commit 9deb1ae572364a37d054d916c5bae858f91a3f9a Author: Bruno Randolf Date: Wed Jul 30 17:20:06 2008 +0200 mac80211: radiotap: assume modulation from rates use the rates ERP flag to derive CCK or OFDM modulation for the radiotap header. (it might be more correct to get this information from the hardware itself, but it seems safe to assume this in most practical cases.) Signed-off-by: Bruno Randolf Signed-off-by: John W. Linville commit b4f28bbb9bf0b2c829ecf97ce2173f204fde4f10 Author: Bruno Randolf Date: Wed Jul 30 17:19:55 2008 +0200 mac80211: add rx status flag for short preamble and use it for the radiotap header Signed-off-by: Bruno Randolf Signed-off-by: John W. Linville commit 63266a653589e1a237527479f10212ea77ce7844 Author: Bruno Randolf Date: Wed Jul 30 17:12:58 2008 +0200 ath5k: rates cleanup cleanup the rates structures used by ath5k. instead of separate driver and mac80211 rate structures we now setup a static ieee80211_rate array and use it directly. no conversion between two different rate structures has to be done any more. a lot of unused and confusing junk was deleted. renamed ath5k_getchannels into ath5k_setup_bands because this is what it does. rewrote it to copy the bitrates correctly for each band. this is necessary for running different hardware with the same driver (e.g. 5211 and 5212 based cards). add special handling of rates for AR5211 chipsets: it uses different rate codes for CCK rates (which are actually like the other chips but with a 0xF mask). setup a hardware code to rate index reverse mapping table for getting the rate index of received frames. the rates for control frames which have to be set in ath5k_hw_write_rate_duration are now in one single array. drivers/net/wireless/ath5k/ath5k.h: Changes-licensed-under: ISC drivers/net/wireless/ath5k/base.c: Changes-licensed-under: 3-Clause-BSD drivers/net/wireless/ath5k/base.h: Changes-licensed-under: 3-Clause-BSD drivers/net/wireless/ath5k/hw.c: Changes-licensed-under: ISC Signed-off-by: Bruno Randolf Signed-off-by: John W. Linville commit 92ab85354993ac3a364c65cab45745af470ffc67 Author: Tomas Winkler Date: Thu Jul 24 21:02:04 2008 +0300 mac80211: add ieee80211_queue_stopped) This patch adds ieee80211_queue_stopped that let drivers to query queue status Signed-off-by: Tomas Winkler Signed-off-by: John W. Linville commit 5442060c08a49bd0b416f033e0ae43ccedef5278 Author: Robert P. J. Day Date: Thu Jul 24 12:20:09 2008 -0400 WIRELESS: Make wireless one-click selectable. Use "menuconfig" to make wireless support one-click selectable. Signed-off-by: Robert P. J. Day Signed-off-by: John W. Linville commit d7dc100374df0c21afd8a198336ecd7999697159 Author: Jiri Slaby Date: Wed Jul 23 13:17:35 2008 +0200 Ath5k: unify resets There were 3 code copy and pastes of reset. Unify the resets and place in separate function. Signed-off-by: Jiri Slaby Cc: Nick Kossifidis Cc: Luis R. Rodriguez Signed-off-by: John W. Linville commit b9740c2396851178b99c03c2260a0adfe7f52e36 Author: Daniel Wagner Date: Wed Jul 23 19:17:01 2008 +0200 rt2x00mac: In error case stop netdev queue, free skb and return NETDEV_TX_OK It is not allowed to use NETDEV_TX_BUSY in tx path anymore. Signed-off-by: Daniel Wagner Acked-by: Ivo van Doorn Signed-off-by: John W. Linville commit 8e5f3d0aaa3ae5305613553f869727b0361cd472 Author: Andrey Yurovsky Date: Thu Jul 17 13:12:24 2008 -0700 ath5k: add Mesh Point support This enables draft-802.11s Mesh Point operation. For that we need mesh beaconing. Tested with AR5212/AR5213 PCI card against Zydas and b43 mesh nodes. Signed-off-by: Andrey Yurovsky Signed-off-by: John W. Linville commit d92a8e81e097968d8f2bac0581a0a43bff14b8f0 Author: Julia Lawall Date: Wed Jul 16 16:34:54 2008 +0200 net/ieee80211: adjust error handling Converts a test in error handling code to a sequence of labels. The semantic match that found the problem is: (http://www.emn.fr/x-info/coccinelle/) // @@ expression E,E1,E2; @@ E = alloc_etherdev(...) ... when != E = E1 if (...) { ... free_netdev(E); ... return ...; } ... when != E = E2 ( if (...) { ... when != free_netdev(E); return dev; } | * if (...) { ... when != free_netdev(E); return ...; } | register_netdev(E) ) // Signed-off-by: Julia Lawall Signed-off-by: John W. Linville commit 1ff41eb0d9a937957d481d4f058a91230851ae17 Author: Brian Cavagnolo Date: Mon Jul 21 11:03:16 2008 -0700 libertas: add sysfs hooks to update boot2 and persistent firmware To use these features, copy the boot2 and firmware images to /lib/firmware and: echo > /sys/class/net/ethX/lbs_flash_boot2 echo > /sys/class/net/ethX/lbs_flash_fw Signed-off-by: Brian Cavagnolo Acked-by: Dan Williams Signed-off-by: John W. Linville commit 1556c0f22df77800d2e99342ce354a4ce94c5a0f Author: Brian Cavagnolo Date: Mon Jul 21 11:02:46 2008 -0700 libertas: support boot commands to write persistent firmware and bootloader Add locking and non-locking versions of if_usb_prog_firmware to support programming firmware after and before driver bring-up respectively. Add more suitable error codes for firmware programming process. Add capability checks for persistent features before attempting to use them. Based on patches from Brajesh Dave and Priyank Singh. Signed-off-by: Brian Cavagnolo Acked-by: Dan Williams Signed-off-by: John W. Linville commit 38e3b0d86eaa0bf90a74677b6d6c442ec66daa0c Author: Herton Ronaldo Krzesinski Date: Wed Jul 16 11:44:18 2008 -0300 rtl818x: merge tx/rx descriptor flags Tx/Rx descriptor flags are common between rtl818x devices, only with additions for newer chips, thus use same flags in the code. Signed-off-by: Herton Ronaldo Krzesinski Signed-off-by: John W. Linville commit 7c4b45fd9164d068fb92c290085fe124329247b1 Author: Adrian Bunk Date: Tue Aug 5 15:00:11 2008 -0300 V4L/DVB (8678): Remove the dead CONFIG_RADIO_MIROPCM20{,_RDS} code The CONFIG_RADIO_MIROPCM20{,_RDS} code became dead code 1.5 years ago. Signed-off-by: Adrian Bunk Signed-off-by: Mauro Carvalho Chehab commit a81ec1004c6242897f51d257c27a0f53a0ca52bd Author: Jean-Francois Moine Date: Thu Aug 14 05:50:14 2008 -0300 V4L/DVB (8675): gspca: Pixmap PJPG (Pixart 73xx JPEG) added, generated by pac7311. The JPEG frames generated by the Pixart 73xx have: - special markers 'ff ff ff xx' every 1024/512 bytes, - unused 8 bits at end of JPEG blocks, and then ask for a new pixel format. Signed-off-by: Jean-Francois Moine Signed-off-by: Mauro Carvalho Chehab commit 976deb2afa480ed4abbaae881cc24944aac065d1 Author: Jean-Francois Moine Date: Mon Aug 11 15:14:52 2008 -0300 V4L/DVB (8674): gspca: Webcam 0c45:612e added in sonixj. Signed-off-by: Jean-Francois Moine Signed-off-by: Mauro Carvalho Chehab commit 3b340e58117a1703a1aabcfdc4af76927d20c26f Author: Jean-Francois Moine Date: Mon Aug 11 12:06:20 2008 -0300 V4L/DVB (8673): gspca: Bad frame scanning again and bad init in pac7311. Signed-off-by: Jean-Francois Moine Signed-off-by: Mauro Carvalho Chehab commit 1fbf0a3910e6107d26c7dc60499847990863464f Author: Jean-Francois Moine Date: Mon Aug 11 06:13:12 2008 -0300 V4L/DVB (8672): gspca: Big rewrite of spca561. Bug register/value inversions in USB exchanges. Exposure and gain controls added for rev 12a. Separate the functions and controls of the revisions 12a and 72a. Signed-off-by: Jean-Francois Moine Signed-off-by: Mauro Carvalho Chehab commit 81128e3706b7c5b505c6ccd55914d3fe21c08b5e Author: Jean-Francois Moine Date: Mon Aug 11 05:26:51 2008 -0300 V4L/DVB (8671): gspca: Remove the unused field 'dev_name' of the device structure. Signed-off-by: Jean-Francois Moine Signed-off-by: Mauro Carvalho Chehab commit 1e4e5f2693533d5ec8e307690c92a29062bcd8b5 Author: Jean-Francois Moine Date: Fri Aug 8 07:08:29 2008 -0300 V4L/DVB (8669): gspca: Add white balance control for spca561 rev 012A. Signed-off-by: Jean-Francois Moine Signed-off-by: Mauro Carvalho Chehab commit bf06b24dd830c8f5c1faeecceca371005bdcea13 Author: Jean-Francois Moine Date: Fri Aug 8 04:35:25 2008 -0300 V4L/DVB (8668): gspca: Conflict GSPCA / ET61X251 for the webcam 102c:6251. Fix a double handling of 102c:6251 and no handling of 102c:6151 when both drivers GSPCA and ET61X251. Signed-off-by: Jean-Francois Moine Signed-off-by: Mauro Carvalho Chehab commit 17c09bf7395eaa085f4be1d9aaec7488cf52afe6 Author: Hans de Goede Date: Fri Aug 8 04:31:36 2008 -0300 V4L/DVB (8667): gspca: Bad probe of Z-Star/Vimicro webcams with pas106 sensor. This patch moves the detection of the 2wr SIF pas106b sensor to before detecting other sensors. Patch change by jfm: Check SIF for identified webcams only. Signed-off-by: Hans de Goede Signed-off-by: Jean-Francois Moine Signed-off-by: Mauro Carvalho Chehab commit b7d0a97abcd3e821db613d4aa6b8c4ddfa9f7d32 Author: Jean-Francois Moine Date: Fri Aug 8 02:59:04 2008 -0300 V4L/DVB (8666): gspca: Bad scanning of frames in pac7311. The previous change in packet scanning did not work, Also, autogain was no more treated at interrupt level. Signed-off-by: Jean-Francois Moine Signed-off-by: Mauro Carvalho Chehab commit 2890d6e50b5d484db829245d6b48ef4d50e619b5 Author: Jean-Francois Moine Date: Wed Aug 6 10:45:38 2008 -0300 V4L/DVB (8665): gspca: Fix the 640x480 resolution of the webcam 093a:2621. Signed-off-by: Jean-Francois Moine Signed-off-by: Mauro Carvalho Chehab commit fa5e37329f5522e1c9afcb36c4726b0ca0cd29f9 Author: Jean-Francois Moine Date: Wed Aug 6 04:11:18 2008 -0300 V4L/DVB (8664): gspca: The bridge/sensor of the webcam 093a:2621 is a PAC 7302. Signed-off-by: Jean-Francois Moine Signed-off-by: Mauro Carvalho Chehab commit d47a4d04539ef5d790db748bc7b938ec413e4750 Author: Jean-Francois Moine Date: Wed Aug 6 03:18:38 2008 -0300 V4L/DVB (8663): gspca: Webcam 0c45:6128 added in sonixj. Patch adapted from a patch to gspcav1 made by the google microdia group. Signed-off-by: Jean-Francois Moine Signed-off-by: Mauro Carvalho Chehab commit 80380e965b315833b824c7008901d119800782fa Author: Jean-Francois Moine Date: Tue Aug 5 06:16:19 2008 -0300 V4L/DVB (8661): gspca: Bug in the previous changeset about pac7311. Signed-off-by: Jean-Francois Moine Signed-off-by: Mauro Carvalho Chehab commit aff8c1b6ceab6d6303e51bf20829c2d62c5ceea9 Author: Jean-Francois Moine Date: Tue Aug 5 05:01:44 2008 -0300 V4L/DVB (8660): gspca: Simplify the scan of URB packets in pac7311. Signed-off-by: Jean-Francois Moine Signed-off-by: Mauro Carvalho Chehab commit 98c088d15b918d4113251d95bf56dcaff8ea9976 Author: Joel Becker Date: Fri Aug 22 12:46:09 2008 -0700 ocfs2: Change ocfs2_get_*_extent_tree() to ocfs2_init_*_extent_tree() The original get/put_extent_tree() functions held a reference on et_root_bh. However, every single caller already has a safe reference, making the get/put cycle irrelevant. We change ocfs2_get_*_extent_tree() to ocfs2_init_*_extent_tree(). It no longer gets a reference on et_root_bh. ocfs2_put_extent_tree() is removed. Callers now have a simpler init+use pattern. Signed-off-by: Joel Becker commit 69e691c4cb7837b5dce7e52d2ecfab90d6db0495 Author: Joel Becker Date: Thu Aug 21 17:11:10 2008 -0700 ocfs2: Comment struct ocfs2_extent_tree_operations. struct ocfs2_extent_tree_operations provides methods for the different on-disk btrees in ocfs2. Describing what those methods do is probably a good idea. Signed-off-by: Joel Becker commit 23d544af16b3aff7fe87302e3a5e930ba51099c8 Author: Joel Becker Date: Wed Aug 20 19:36:33 2008 -0700 ocfs2: Make ocfs2_extent_tree the first-class representation of a tree. We now have three different kinds of extent trees in ocfs2: inode data (dinode), extended attributes (xattr_tree), and extended attribute values (xattr_value). There is a nice abstraction for them, ocfs2_extent_tree, but it is hidden in alloc.c. All the calling functions have to pick amongst a varied API and pass in type bits and often extraneous pointers. A better way is to make ocfs2_extent_tree a first-class object. Everyone converts their object to an ocfs2_extent_tree() via the ocfs2_get_*_extent_tree() calls, then uses the ocfs2_extent_tree for all tree calls to alloc.c. This simplifies a lot of callers, making for readability. It also provides an easy way to add additional extent tree types, as they only need to be defined in alloc.c with a ocfs2_get__extent_tree() function. Signed-off-by: Joel Becker commit 49b6a0582b15359307b2b3e38d534764ffb6dced Author: Joel Becker Date: Wed Aug 20 18:32:45 2008 -0700 ocfs2: Add an insertion check to ocfs2_extent_tree_operations. A couple places check an extent_tree for a valid inode. We move that out to add an eo_insert_check() operation. It can be called from ocfs2_insert_extent() and elsewhere. We also have the wrapper calls ocfs2_et_insert_check() and ocfs2_et_sanity_check() ignore NULL ops. That way we don't have to provide useless operations for xattr types. Signed-off-by: Joel Becker commit 2712160fe3a17c1b2e8874289de29c037ee8dbe9 Author: Hans Verkuil Date: Sat Aug 9 09:46:55 2008 -0300 V4L/DVB (8648): ivtv: improve CC support - change the work-queue to a single threaded high prio workqueue - use DMA instead of PIO for the sliced VBI data. - remove some incorrect tests - increase the internal VBI capture queue size for sliced VBI packets - ignore duplicate VBI lines With these changes it should finally be possible to get reliable closed captions. Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab commit 06385c2529ebb730953806a423bba8b8d54224ad Author: Avi Kivity Date: Fri Aug 22 19:19:38 2008 +0300 KVM: MMU: Fix torn shadow pte The shadow code assigns a pte directly in one place, which is nonatomic on i386 can can cause random memory references. Fix by using an atomic setter. Signed-off-by: Avi Kivity commit bfcec11caf819f39f30e61a7d5c55c2dcade4e16 Author: Avi Kivity Date: Fri Aug 22 19:14:17 2008 +0300 KVM: MMU: Unify direct map 4K and large page paths The two paths are equivalent except for one argument, which is already available. Merge the two codepaths. Signed-off-by: Avi Kivity commit 4df51070c30256bf60a7a3800c40db20380aaada Author: Nick Warne Date: Sun Aug 17 00:00:44 2008 +0200 [SCSI] tmscsim: Fixup KERN_INFO in printk Multiline kernel messages should contain a priority in every line, besides, some log daemons represent a tabulator as "^I", fix both these issues. Signed-off-by: Nick Warne Signed-off-by: Guennadi Liakhovetski Signed-off-by: James Bottomley commit f44aae0a17c8c563647c9ea5e6b7a4d270bd33f2 Author: Matthew Wilcox Date: Wed Aug 13 21:36:55 2008 -0700 [SCSI] qla2xxx: Remove semaphore.h Now that qla2xxx has been converted to mutexes, it no longer needs the semaphore include. Signed-off-by: Matthew Wilcox Signed-off-by: Andrew Vasquez Signed-off-by: James Bottomley commit 25258ef762bc4a05fa9c4523f7dae56e3fd01864 Author: Jeremy Fitzhardinge Date: Wed Aug 20 11:31:07 2008 -0700 x86: export pv_lock_ops non-GPL None of the spinlock API is exported GPL, so there's no reason for pv_lock_ops to be. Signed-off-by: Jeremy Fitzhardinge Signed-off-by: Ingo Molnar Cc: drago01 commit 62d2b9dfff9224686b4565ed5a65b9fbd9752639 Author: Hans Verkuil Date: Thu Aug 7 13:26:25 2008 -0300 V4L/DVB (8633): ivtv: update ivtv version number Since for 2.6.27 ivtvfb uses DMA for write it is important that you can identify which ivtv version supports this and which doesn't. Increase the version number so we can tell the difference. Thanks to Ian Armstrong for pointing this out to me. Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab commit 85395fcf714317936a582277656a63ade6211ec0 Author: Hans Verkuil Date: Sun Jul 27 16:37:23 2008 -0300 V4L/DVB (8629): v4l2-ioctl: do not try to handle private V4L1 ioctls Some drivers (e.g. zoran) have private V4L1 ioctls. Do not try to pass them to v4l1_compat_translate because then the driver will never see them. Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab commit ec45c2801c7f57bc2ab63d020458f4b5aae082d0 Author: Ingo Molnar Date: Fri Aug 22 15:32:20 2008 +0200 Revert "x2apic: use x2apic id reported by cpuid during topology discovery" This reverts commit 276605dddb74cbf1b77696e32c4a947e42cec52d. commit 5f31eaa36780b61bdbfa180662505db0f8d06e86 Author: Ingo Molnar Date: Fri Aug 22 15:19:51 2008 +0200 Revert "x2apic: use cpuid vector 0xb when available for detecting cpu topology" This reverts commit d92ca3e085e9ec39adb20d93bc8266b6fdc83d3d. Conflicts: include/asm-x86/cpufeature.h Signed-off-by: Ingo Molnar commit facbb8cfa35fd246a411ea5c780ba30c6298f622 Author: Ingo Molnar Date: Fri Aug 22 15:17:53 2008 +0200 Revert "sched: properly account IRQ and RT load in SCHED_OTHER load balancing" This reverts commit aca64e0ba2419e6afa6dcc3a5afd66cae169c742. commit 93dcf55f828b035fc93fc19eb03c1390e1e6d570 Author: Oleg Nesterov Date: Wed Aug 20 16:54:44 2008 -0700 wait_task_inactive: "improve" the returned value for ->nvcsw == 0 wait_task_inactive() returns 1 when p->nvcsw == 0 || p->nvcsw == 1. This means that two subsequent calls can return the same number while the task was scheduled in between. Change the code to return "nvcsw | LONG_MIN" instead of "nvcsw ?: 1", now the overlap always needs LONG_MAX schedules. Signed-off-by: Oleg Nesterov Signed-off-by: Andrew Morton Signed-off-by: Ingo Molnar commit f31e11d87a5d7601636710195891ba462ad99f11 Author: Oleg Nesterov Date: Wed Aug 20 16:54:44 2008 -0700 wait_task_inactive(): don't consider task->nivcsw If wait_task_inactive() returns success the task was deactivated. In that case schedule() always increments ->nvcsw which alone can be used as a "generation counter". If the next call returns the same number, we can be sure that the task was unscheduled. Otherwise, because we know that .on_rq == 0 again, ->nvcsw should have been changed in between. Q: perhaps it is better to do "ncsw = (p->nvcsw << 1) | 1" ? This decreases the possibility of "was it unscheduled" false positive when ->nvcsw == 0. Signed-off-by: Oleg Nesterov Signed-off-by: Andrew Morton Signed-off-by: Ingo Molnar commit 94d3d8247de22c5b0624aa00616ceca459498e55 Author: Oleg Nesterov Date: Wed Aug 20 16:54:41 2008 -0700 sched: do_wait_for_common: use signal_pending_state() Change do_wait_for_common() to use signal_pending_state() instead of open coding. Signed-off-by: Oleg Nesterov Signed-off-by: Andrew Morton Signed-off-by: Ingo Molnar commit ba5246a7ac71158b0fa23e01ff9d3d0626f146c1 Author: Rafael J. Wysocki Date: Thu Aug 21 21:59:36 2008 +0200 ftrace: fix ftraced and suspend to ram Steven Rostedt observed: > In latest 2.6.27(git) enabling dynamic ftrace makes resume from a suspend > to ram reboot instead of resuming. Queued for 2.6.28 is a new method of > recording mcount callers at compile time that does not have this issue. > > But the new method is still too "green" to be pulled into 27, so the old > ftraced (daemon method) needs to be fixed for 27. > > The way dynamic ftrace works with the daemon method is this. On boot up > the mcount function simply returns. When ftrace is initialized, it calls > kstop_machine to modify the mcount function to call another function > called "ftrace_record_ip". This new function will record in a preallocated > hash (allocated by the ftrace initializer) all the callers of mcount. A > check is made to see if the caller has already been put into the hash, and > if so, it is not recorded again. > > Later on a kernel thread ftraced is created. This kernel thread wakes up > once a second and checks to see if any new functions were added to the > hash. If so, it then calls kstop_machine and modifies those callers to > mcount into nops. It will suffice to make it freezable, so that it doesn't run while the system is suspending and resuming. Signed-off-by: Ingo Molnar commit 66f80be8e51a9334ff270b21576af79bfbcce682 Author: Michael Ellerman Date: Wed Aug 20 16:36:11 2008 -0700 ftrace: make output nicely spaced for up to 999 cpus Currently some of the ftrace output goes skewiff if you have more than 9 cpus, and some if you have more than 99. Twiddle with the headers and format strings to make up to 999 cpus display without causing spacing problems. Signed-off-by: Michael Ellerman Acked-by: Steven Rostedt Signed-off-by: Andrew Morton Signed-off-by: Ingo Molnar commit b05f78f5c713eda2c34e495d92495ee4f1c3b5e1 Author: Yinghai Lu Date: Fri Aug 22 01:32:50 2008 -0700 x86_64: printout msr -v2 commandline show_msr=1 for bsp, show_msr=32 for all 32 cpus. [ mingo@elte.hu: added documentation ] Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit 421076e2bec1b917bdcf83da35b24f6349bf35db Author: FUJITA Tomonori Date: Fri Aug 22 16:29:10 2008 +0900 x86: dma_*_coherent rework patchset v2, fix alloc_coherent dma_ops callback was added to GART, however, it doesn't return a size aligned address wrt dma_alloc_coherent, as DMA-mapping.txt defines. This patch fixes it. This patch also removes unused gart_map_simple (dma_mapping_ops->map_simple has gone). Signed-off-by: FUJITA Tomonori Signed-off-by: Ingo Molnar commit 412ca575df7d61ad628c37a9fc8b3c848927e475 Author: Jaswinder Singh Date: Thu Jul 17 20:19:26 2008 +0530 starfire: use request_firmware() Firmware blob is big endian Signed-off-by: Jaswinder Singh Signed-off-by: David Woodhouse commit 229d9a03273684dc2175821be4104dbaa52f3ce0 Author: Jaswinder Singh Date: Fri Jul 11 18:14:02 2008 +0530 qlogicpti: use request_firmware Firmware blob is little endian Thanks to Stephen Rothwell for fixing typos Signed-off-by: Jaswinder Singh Signed-off-by: David Woodhouse commit c6c1000573c0b136753542aecc32237c99ca179d Author: Jaswinder Singh Date: Thu Jul 10 21:52:03 2008 +0530 advansys: use request_firmware Firmware blob looks like this... __le32 checksum unsigned char data[] Signed-off-by: Jaswinder Singh Signed-off-by: David Woodhouse Acked-by: Matthew Wilcox commit 0e55349855dd05a5d287c4f7c15b4676799cc104 Author: Jaswinder Singh Date: Sun Jul 6 14:33:15 2008 +0530 qla1280: use request_firmware Firmware blob is little endian looks like this... unsigned char Version1 unsigned char Version2 unsigned char Version3 unsigned char Padding unsigned short start_address unsigned short data Signed-off-by: Jaswinder Singh Signed-off-by: David Woodhouse Acked-by: Jes Sorensen commit 93d112e73faa63488be753031ecaa64eca5e53a4 Author: Jaswinder Singh Date: Sun Jun 22 18:24:19 2008 +0530 Remove fdump tool for av7110 firmware There's no point in this, since the user can use the BUILTIN_FIRMWARE option to include arbitrary firmware files directly in the kernel image. Thanks to David Woodhouse for help. Signed-off-by: Jaswinder Singh Signed-off-by: David Woodhouse commit 5011bdacb6b86e0dd1f351654044c17107dde9de Author: Jaswinder Singh Date: Sun Jun 22 15:09:35 2008 +0530 firmware: convert av7110 driver to request_firmware() Signed-off-by: Jaswinder Singh Signed-off-by: David Woodhouse commit eda18c5900f240cb6c7421d7b2426cd1af354e34 Author: Jaswinder Singh Date: Wed Jun 18 19:58:33 2008 +0530 firmware: convert tg3 driver to request_firmware() Firmware blob looks like this... u8 firmware_major u8 firmware_minor u8 firmware_fix u8 pad __be32 start_address __be32 length (total, including BSS sections to be zeroed) data... (in __be32 words, which is native for the firmware) Signed-off-by: Jaswinder Singh Signed-off-by: David Woodhouse commit 2d790f69c9e7e7271582aa0d91fdfd40624e1be3 Author: Jaswinder Singh Date: Mon Jun 16 00:45:38 2008 +0530 firmware: convert acenic driver to request_firmware() We store the firmware in its native big-endian form now, so the loop in ace_copy() is modified to use be32_to_cpup() when writing it out. We can forget the BSS,SBSS sections of the firmware, since we were clearing all the device's RAM anyway. And the text,rodata,data sections can all be loaded as a single chunk since they're contiguous (give or take a few dozen bytes in between). Signed-off-by: Jaswinder Singh Signed-off-by: David Woodhouse Acked-by: Jes Sorensen commit 9e0fa5d599deeb9e34376af4f7c645b69b577758 Author: Jaswinder Singh Date: Sat Jun 14 22:30:37 2008 +0530 firmware: convert e100 driver to request_firmware() Thanks to David Woodhouse for help. Signed-off-by: Jaswinder Singh Signed-off-by: David Woodhouse commit 766af9fa812f49feb4a3e62cf92f3d37f33c7fb6 Author: FUJITA Tomonori Date: Fri Aug 22 00:12:09 2008 +0900 dma-mapping.h, x86: remove last user of dma_mapping_ops->map_simple pci-dma.c doesn't use map_simple hook any more so we can remove it from struct dma_mapping_ops now. Signed-off-by: FUJITA Tomonori Signed-off-by: Ingo Molnar commit 5582271d85060492f1d5ee800c5e3b57c13e29a9 Author: Rene Herman Date: Thu Aug 21 23:07:43 2008 +0200 ALSA: snd-ad1816a: add different TerraTec EWS64 S model Signed-off-by: Rene Herman Signed-off-by: Takashi Iwai commit 7f1e558d20e3019329a13abaa30d5b556662042c Author: Andreas Mohr Date: Thu Aug 21 21:55:57 2008 +0200 ALSA: ALS4000 driver work, step 2 - more register naming work - finally figured out that weird CR register stuff (and did I mention that I hate _really_ undecipherable open-coded values?) - fix handling of IRQ sharing in interrupt handler (hopefully properly, otherwise I'd be grateful to hear your pedantic comments ;) - add handy SPECS_PAGE references wherever useful - comments, cleanup - add me as module author Signed-off-by: Andreas Mohr Signed-off-by: Takashi Iwai commit a38409fbb5181324fb73b359189a72e02b6c7030 Author: Ingo Molnar Date: Wed Aug 20 12:16:09 2008 +0200 dma-coherent: export dma_[alloc|release]_from_coherent methods fixes modular builds: ERROR: "dma_alloc_from_coherent" [sound/core/snd-page-alloc.ko] undefined! ERROR: "dma_release_from_coherent" [sound/core/snd-page-alloc.ko] undefined! Signed-off-by: Ingo Molnar commit 2cd54961caff9fe9109807c6603a0af0729b9591 Author: Joerg Roedel Date: Tue Aug 19 16:32:46 2008 +0200 x86, AMD IOMMU: remove obsolete FIXME comment Signed-off-by: Joerg Roedel Signed-off-by: Ingo Molnar commit 6c505ce3930c6a6b455cda53fab3e88ae44f8221 Author: Joerg Roedel Date: Tue Aug 19 16:32:45 2008 +0200 x86: move dma_*_coherent functions to include file All the x86 DMA-API functions are defined in asm/dma-mapping.h. This patch moves the dma_*_coherent functions also to this header file because they are now small enough to do so. This is done as a separate patch because it also includes some renaming and restructuring of the dma-mapping.h file. Signed-off-by: Joerg Roedel Signed-off-by: Ingo Molnar commit c647c3bb2d16246a87f49035985ddb7c1eb030df Author: Joerg Roedel Date: Tue Aug 19 16:32:44 2008 +0200 x86: cleanup dma_*_coherent functions All dma_ops implementations support the alloc_coherent and free_coherent callbacks now. This allows a big simplification of the dma_alloc_coherent function which is done with this patch. The dma_free_coherent functions is also cleaned up and calls now the free_coherent callback of the dma_ops implementation. Signed-off-by: Joerg Roedel Signed-off-by: Ingo Molnar commit a3a76532e0caa093c279806d8fe8608232538af0 Author: Joerg Roedel Date: Tue Aug 19 16:32:43 2008 +0200 x86: add free_coherent dma_ops callback to NOMMU driver Signed-off-by: Joerg Roedel Signed-off-by: Ingo Molnar commit c5e835f9641e9fcb95d1afb24906821e98b2c6a8 Author: Joerg Roedel Date: Tue Aug 19 16:32:42 2008 +0200 x86: add alloc_coherent dma_ops callback to NOMMU driver Signed-off-by: Joerg Roedel Signed-off-by: Ingo Molnar commit e4ad68b651f22fa71820c0b30bb2807999b2b49f Author: Joerg Roedel Date: Tue Aug 19 16:32:41 2008 +0200 x86: add free_coherent dma_ops callback to Calgary IOMMU driver Signed-off-by: Joerg Roedel Acked-by: Muli Ben-Yehuda Signed-off-by: Ingo Molnar commit 43a5a5a09b8cfd56047706cf904718d073ccfd33 Author: Joerg Roedel Date: Tue Aug 19 16:32:40 2008 +0200 x86: add free_coherent dma_ops callback to GART driver Signed-off-by: Joerg Roedel Signed-off-by: Ingo Molnar commit 94581094e774402a11887719bac10505236c2d51 Author: Joerg Roedel Date: Tue Aug 19 16:32:39 2008 +0200 x86: add alloc_coherent dma_ops callback to GART driver [ v2 - x86: make gart_alloc_coherent return zeroed memory FUJITA Tomonori pointed it out that the dma_alloc_coherent function should return memory set to zero. This patch adds this to the GART implementation too. ] Signed-off-by: Joerg Roedel Signed-off-by: Ingo Molnar commit ee7686bc043921a488d9bf89fe93241c5457a74e Author: Jeremy Fitzhardinge Date: Thu Aug 21 13:17:56 2008 -0700 x86: build fix in "xen spinlock updates and performance measurements" Ingo Molnar wrote: > -tip testing found this build failure: > > arch/x86/xen/spinlock.c: In function ‘spin_time_start’: > arch/x86/xen/spinlock.c:60: error: implicit declaration of function ‘xen_clocksource_read’ > > i've excluded these new commits for now from tip/master - could you > please send a delta fix against tip/x86/xen? Make xen_clocksource_read non-static. Signed-off-by: Jeremy Fitzhardinge Signed-off-by: Ingo Molnar commit 377bf1e4ac2d894791733270604594c7c851ef83 Author: Anton Vorontsov Date: Thu Aug 21 22:58:28 2008 +0400 genirq: fix irq_desc->depth handling with DEBUG_SHIRQ When DEBUG_SHIRQ is selected, a spurious IRQ is issued before the setup_irq() initializes the desc->depth. An IRQ handler may call disable_irq_nosync(), but then setup_irq() will overwrite desc->depth, and upon enable_irq() we'll catch this WARN: ------------[ cut here ]------------ Badness at kernel/irq/manage.c:180 NIP: c0061ab8 LR: c0061f10 CTR: 00000000 REGS: cf83be50 TRAP: 0700 Not tainted (2.6.27-rc3-23450-g74919b0) MSR: 00021032 CR: 22042022 XER: 20000000 TASK = cf829100[5] 'events/0' THREAD: cf83a000 GPR00: c0061f10 cf83bf00 cf829100 c038e674 00000016 00000000 cf83bef8 00000038 GPR08: c0298910 00000000 c0310d28 cf83a000 00000c9c 1001a1a8 0fffe000 00800000 GPR16: ffffffff 00000000 007fff00 00000000 007ffeb0 c03320a0 c031095c c0310924 GPR24: cf8292ec cf807190 cf83a000 00009032 c038e6a4 c038e674 cf99b1cc c038e674 NIP [c0061ab8] __enable_irq+0x20/0x80 LR [c0061f10] enable_irq+0x50/0x70 Call Trace: [cf83bf00] [c038e674] irq_desc+0x630/0x9000 (unreliable) [cf83bf10] [c0061f10] enable_irq+0x50/0x70 [cf83bf30] [c01abe94] phy_change+0x68/0x108 [cf83bf50] [c0046394] run_workqueue+0xc4/0x16c [cf83bf90] [c0046834] worker_thread+0x74/0xd4 [cf83bfd0] [c004ab7c] kthread+0x48/0x84 [cf83bff0] [c00135e0] kernel_thread+0x44/0x60 Instruction dump: 4e800020 3d20c031 38a94214 4bffffcc 9421fff0 7c0802a6 93e1000c 7c7f1b78 90010014 8123001c 2f890000 409e001c <0fe00000> 80010014 83e1000c 38210010 That trace corresponds to this line: WARN(1, KERN_WARNING "Unbalanced enable for IRQ %d\n", irq); The patch fixes the problem by moving the SHIRQ code below the setup_irq(). Unfortunately we can't easily move the SHIRQ code inside the setup_irq(), since it grabs a spinlock, so to prvent a 'real' IRQ from interfere us we should disable that IRQ. p.s. The driver in question is drivers/net/phy/phy.c. Signed-off-by: Anton Vorontsov Cc: David Woodhouse Signed-off-by: Ingo Molnar commit 07bbcc405ec83b8108c6d782b767409a41259ecf Author: Alok Kataria Date: Thu Aug 21 11:26:43 2008 -0700 x86: VMI, initialize IRQ vector Initialize vector_irq for the vmi used vector, to point to correct irq. Signed-off-by: Alok N Kataria Signed-off-by: Ingo Molnar commit 5b792d320f28ff83dd4c13f984807e26235f7703 Author: Randy Dunlap Date: Thu Aug 21 13:43:51 2008 -0700 x86, microcode_amd: fix shift warning microcode_amd.c uses ">> 32" on a 32-bit value, so gcc warns about that. The code could use something like this *untested* patch. linux-next-20080821/arch/x86/kernel/microcode_amd.c:229: warning: right shift count >= width of type Signed-off-by: Randy Dunlap Signed-off-by: Ingo Molnar commit 916c7a855174e3b53d182b97a26b2e27a29726a1 Author: Roman Zippel Date: Wed Aug 20 16:46:08 2008 -0700 ntp: fix ADJ_OFFSET_SS_READ bug and do_adjtimex() cleanup Thanks to the review by Michael Kerrisk a bug in the recent ADJ_OFFSET_SS_READ option was discovered, where the ntp time_offset was inadvertently set by it. This fixes this by making the adjtime code more separate from the ntp_adjtime code (both of which really want to be separate syscalls). Signed-off-by: Roman Zippel Signed-off-by: Andrew Morton Acked-by: John Stultz Signed-off-by: Ingo Molnar commit e0a1c59d26653f4d1f5432c8fcd0bf2dda97601b Author: Yinghai Lu Date: Thu Aug 21 13:10:09 2008 -0700 x86: fix probe_nr_irqs for xen otherwise Xen is _completely_ unusable with 5 or more VCPUs. (when !CONFIG_HAVE_SPARSE_IRQ). based on Alex Nixon's patch. also add +1 offset after redir_entries Signed-off-by: Yinghai Lu Acked-by: Jeremy Fitzhardinge Acked-by: Alex Nixon Signed-off-by: Ingo Molnar commit 5f310b63781f6777bf4e812570560ec0f8ea42d8 Author: Rene Herman Date: Thu Aug 21 19:15:46 2008 +0200 agp: enable optimized agp_alloc_pages methods The pageattr-array patch that you currently have in tip/master only enables it for intel-agp, not the others. The attached enables it for all drivers currently directly using agp_generic_alloc_page() and agp_generic_destroy_page() (ocal driver is amd-k7-agp). The new agp_generic_alloc_pages() interface uses the also new pageattr array interface API. This makes all AGP drivers that up to now used generic_{alloc,destroy}_page() use it. Signed-off-by: Rene Herman Signed-off-by: Ingo Molnar commit c5e147cf5aeb31aa1a9030be9727914855fc4133 Author: Rene Herman Date: Fri Aug 22 01:02:20 2008 +0200 x86: have set_memory_array_{uc,wb} coalesce memtypes. Actually, might as well simply reconstruct the memtype list at free time I guess. How is this for a coalescing version of the array functions? Compiles, boots and provides me with: root@7ixe4:~# wc -l /debug/x86/pat_memtype_list 53 /debug/x86/pat_memtype_list otherwise (down from 16384+). Signed-off-by: Ingo Molnar commit 9a79f4f491f92bc713e1f28f96516b141b752600 Author: Rene Herman Date: Fri Aug 22 00:10:13 2008 +0200 x86: {reverve,free}_memtype() take a physical address The new set_memory_array_{uc,wb}() pass virtual addresses to {reserve,free}_memtype() it seems. Signed-off-by: Rene Herman Signed-off-by: Ingo Molnar commit c3524521d8511d874f33f29903f7794d4e9914fb Author: Yinghai Lu Date: Thu Aug 21 12:56:32 2008 -0700 x86: fix 32-bit ioapic lockup with sparseirqs Missed two lines when copying. Fix panic on one of Ingo's machines that need to adjust ioapic id when acpi off/ 32bit. Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit f86399396ce7a4f4069828b7dceac5aa5113dfb5 Author: Eduardo Habkost Date: Wed Jul 30 18:32:27 2008 -0300 x86, paravirt_ops: use unsigned long instead of u32 for alloc_p*() pfn args This patch changes the pfn args from 'u32' to 'unsigned long' on alloc_p*() functions on paravirt_ops, and the corresponding implementations for Xen and VMI. The prototypes for CONFIG_PARAVIRT=n are already using unsigned long, so paravirt.h now matches the prototypes on asm-x86/pgalloc.h. It shouldn't result in any changes on generated code on 32-bit, with or without CONFIG_PARAVIRT. On both cases, 'codiff -f' didn't show any change after applying this patch. On 64-bit, there are (expected) binary changes only when CONFIG_PARAVIRT is enabled, as the patch is really supposed to change the size of the pfn args. [ v2: KVM_GUEST: use the right parameter type on kvm_release_pt() ] Signed-off-by: Eduardo Habkost Acked-by: Jeremy Fitzhardinge Acked-by: Zachary Amsden Signed-off-by: Ingo Molnar commit e89087c99f2be002ff46126742c21da5d357b324 Author: Paul Walmsley Date: Tue May 20 18:41:35 2008 -0600 [ARM] OMAP: clockdomain: add clkdm_get_pwrdm() Add clkdm_get_pwrdm() to the clockdomain code. It will return a pointer to the powerdomain struct that the clockdomain is contained within. Used by the PM code. Signed-off-by: Paul Walmsley Signed-off-by: Tony Lindgren Signed-off-by: Russell King commit 0b7cbfb5e1f03f58241bf236cca303ee45e14b4f Author: Paul Walmsley Date: Wed Jun 25 18:09:37 2008 -0600 [ARM] OMAP3 pwrdm: add hardware save-and-restore (SAR) support OMAP3430ES2+ introduces a new feature: optional powerdomain context hardware save-and-restore (SAR). Currently, this feature only applies to USBHOST and USBTLL module context when the USBHOST or CORE powerdomains enter a low-power sleep state[1]. This feature avoids re-enumeration of USB devices when the powerdomains return from idle, which is potentially time-consuming. This patch adds support for enabling and disabling hardware save-and-restore to the powerdomain code. Three new functions are added, pwrdm_enable_hdwr_sar(), pwrdm_disable_hdwr_sar(), and pwrdm_can_hdwr_sar(). A new struct powerdomain "flags" field is added, with a PWRDM_HAS_HDWR_SAR flag to indicate powerdomains with SAR support. Thanks to Jouni Högander for reviewing an earlier version of these patches, and Richard Woodruff for clarifying the purpose of these bits. 1. For the USBHOST controller module, context loss occurs when the USBHOST powerdomain enters off-idle. For USBTLL, context loss occurs either if CORE enters off-idle, or if the CORE logic is configured to turn off when CORE enters retention-idle (OSWR). 34xx ES2 TRM 4.8.6.1.1, 4.8.6.1.2 Signed-off-by: Paul Walmsley Signed-off-by: Tony Lindgren Signed-off-by: Russell King commit 22e336f259f285818a9ad4ff085dfbc2f67eb0ec Author: Becky Bruce Date: Thu Aug 21 13:50:22 2008 -0500 powerpc/85xx: fix build warning, remove silly cast This fixes a build warning when PHYS_64BIT is enabled, and removes an unnecessary cast to phys_addr_t (the variable being cast is already a phys_addr_t) Signed-off-by: Becky Bruce Signed-off-by: Kumar Gala commit 58c78f3de02917fcdff138e8b50299ad93e0e79d Author: James Smart Date: Thu Aug 7 20:49:30 2008 -0400 [SCSI] scsi_host_lookup: error returns and NULL pointers This patch cleans up the behavior of scsi_host_lookup(). The original implementation attempted to use the dual role of either returning a pointer value, or a negative error code. User's needed to use IS_ERR() to check the result. Additionally, the IS_ERR() macro never checks for when a NULL pointer was returned, so a NULL pointer actually passes with a success case. Note: scsi_host_get(), used by scsi_host_lookup(), can return a NULL pointer. Talk about a mudhole for the unitiated to step into.... This patch converts scsi_host_lookup() to return either NULL or a valid pointer. The consumers were updated for the change. Signed-off-by: James Smart Signed-off-by: James Bottomley commit 7bebc7a4014cdaa5256c8c7508c78e3ab7e527b4 Author: Avi Kivity Date: Thu Aug 21 17:49:56 2008 +0300 KVM: MMU: Move SHADOW_PT_INDEX to mmu.c It is not specific to the paging mode, so can be made global (and reusable). Signed-off-by: Avi Kivity commit 0bf50593750175bbe6af07a455923ac330c77353 Author: Avi Kivity Date: Thu Aug 21 17:41:39 2008 +0300 KVM: x86 emulator: remove bad ByteOp specifier from NEG descriptor Signed-off-by: Avi Kivity commit 08fad0d725004e0ac6db245992b84313d8621567 Author: roel kluin Date: Mon Aug 18 21:25:01 2008 -0400 KVM: x86 emulator: remove duplicate SrcImm Signed-off-by: Roel Kluin Signed-off-by: Avi Kivity commit 650313a8570732190e2af7b086d5620c70e57419 Author: Takashi Iwai Date: Thu Aug 21 16:25:07 2008 +0200 ALSA: hda - Fix ALC269 capture source ALC269 capture source wasn't properly set up. It's an independent MUX (0x23), not a source of ADC. Signed-off-by: Takashi Iwai commit 275a89bdd3868af3008852594d2e169eaf69441b Author: Paul E. McKenney Date: Thu Aug 21 06:14:55 2008 -0700 rcu: use irq-safe locks Some earlier tip/core/rcu patches caused RCU to incorrectly enable irqs too early in boot. This caused Yinghai's repeated-kexec testing to hit oopses, presumably due to so that device interrupts left over from the prior kernel instance (which would oops the newly booting kernel before it got a chance to reset said devices). This patch therefore converts all the local_irq_disable()s in rcuclassic.c to local_irq_save(). Besides, I never did like local_irq_disable() anyway. ;-) Signed-off-by: Paul E. McKenney Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit 293a623c8edb927e1c9a2658255aed8413c0d746 Author: Eduardo Habkost Date: Tue Aug 19 20:00:08 2008 -0300 KVM: Use .fixup instead of .text.fixup on __kvm_handle_fault_on_reboot vmlinux.lds expects the fixup code to be on a section named .fixup. The .text.fixup section is not mentioned on vmlinux.lds, and is included on the resulting vmlinux (just after .text) only because of ld heuristics on placing orphan sections. However, placing .text.fixup outside .text breaks the definition of _etext, making it exclude the .text.fixup contents. That makes .text.fixup be ignored by the kernel initialization code that needs to know about section locations, such as the code setting page protection bits. Signed-off-by: Eduardo Habkost Signed-off-by: Avi Kivity commit 04da11bfcf511544ae19e0a7e5f994b3237752ac Author: Artem Bityutskiy Date: Wed Aug 20 17:16:34 2008 +0300 UBIFS: fix zero-length truncations Always allow truncations to zero, even if budgeting thinks there is no space. UBIFS reserves some space for deletions anyway. Otherwise, the following happans: 1. create a file, and write as much as possible there, until ENOSPC 2. truncate the file, which fails with ENOSPC, which is not good. Signed-off-by: Artem Bityutskiy commit f8eca41f0afcc7042dc3398c8ba5878c59b1cf1b Author: Jeremy Fitzhardinge Date: Wed Aug 20 17:02:21 2008 -0700 xen: measure how long spinlocks spend blocking Measure how long spinlocks spend blocked. Also rename some fields to be more consistent. Signed-off-by: Jeremy Fitzhardinge Acked-by: Jan Beulich Signed-off-by: Ingo Molnar commit 1e696f638b523958ee3d95e655becdb4c4b6fcde Author: Jeremy Fitzhardinge Date: Wed Aug 20 17:02:20 2008 -0700 xen: allow interrupts to be enabled while doing a blocking spin If spin_lock is called in an interrupts-enabled context, we can safely enable interrupts while spinning. We don't bother for the actual spin loop, but if we timeout and fall back to blocking, it's definitely worthwhile enabling interrupts if possible. Signed-off-by: Jeremy Fitzhardinge Acked-by: Jan Beulich Signed-off-by: Ingo Molnar commit 994025caba3e6beade9bde84dd1b70d9d250f27b Author: Jeremy Fitzhardinge Date: Wed Aug 20 17:02:19 2008 -0700 xen: add debugfs support Add support for exporting statistics on mmu updates, multicall batching and pv spinlocks into debugfs. The base path is xen/ and each subsystem adds its own directory: mmu, multicalls, spinlocks. In each directory, writing 1 to "zero_stats" will cause the corresponding stats to be zeroed the next time they're updated. Signed-off-by: Jeremy Fitzhardinge Acked-by: Jan Beulich Signed-off-by: Ingo Molnar commit 168d2f464ab9860f0d1e66cf1f9684973222f1c6 Author: Jeremy Fitzhardinge Date: Wed Aug 20 17:02:18 2008 -0700 xen: save previous spinlock when blocking A spinlock can be interrupted while spinning, so make sure we preserve the previous lock of interest if we're taking a lock from within an interrupt handler. We also need to deal with the case where the blocking path gets interrupted between testing to see if the lock is free and actually blocking. If we get interrupted there and end up in the state where the lock is free but the irq isn't pending, then we'll block indefinitely in the hypervisor. This fix is to make sure that any nested lock-takers will always leave the irq pending if there's any chance the outer lock became free. Signed-off-by: Jeremy Fitzhardinge Acked-by: Jan Beulich Signed-off-by: Ingo Molnar commit ab7e79243746e2a9c5f00243e60108189c44c9eb Author: Shaohua Li Date: Thu Aug 21 10:46:21 2008 +0800 x86: fix pageattr-test We changed the interface of some pageattr, this patch makes pageattr-test compile. Signed-off-by: Dave Airlie Signed-off-by: Shaohua Li Signed-off-by: Ingo Molnar commit bd07928c0f9c3dbe53baf28eae4de4c579772c4c Author: Shaohua Li Date: Thu Aug 21 10:46:17 2008 +0800 agp: add agp_generic_destroy_pages() Add agp_generic_destroy_pages(), it uses new pageattr array interface API. Signed-off-by: Dave Airlie Signed-off-by: Shaohua Li Signed-off-by: Ingo Molnar commit 37acee10f49cf3caa323e05675e8dc9221ef4fd8 Author: Shaohua Li Date: Thu Aug 21 10:46:11 2008 +0800 agp: generic_alloc_pages() Add agp_generic_alloc_pages(), it uses new pageattr array interface API. Signed-off-by: Dave Airlie Signed-off-by: Shaohua Li Signed-off-by: Ingo Molnar commit d75586ad01e6c5a30e7337fb87d61e03556a1ecb Author: Shaohua Li Date: Thu Aug 21 10:46:06 2008 +0800 x86, pageattr: introduce APIs to change pageattr of a page array Add array interface APIs of pageattr. page based cache flush is quite slow for a lot of pages. If pages are more than 1024 (4M), the patch will use a wbinvd(). We have a simple test here (run a 3d game - open arena), nearly all agp memory allocation are small (< 1M), so suppose this will not impact runtime performance. Signed-off-by: Dave Airlie Signed-off-by: Shaohua Li Signed-off-by: Ingo Molnar commit cacf890694a36124ceddce44ff4c7b02d372ce7c Author: Ingo Molnar Date: Thu Aug 21 13:46:33 2008 +0200 Revert "introduce two APIs for page attribute" This reverts commit 1ac2f7d55b7ee1613c90631e87fea22ec06781e5. commit 9326d61bf64c4293f834e86c11f52db5be9798d6 Author: Ingo Molnar Date: Thu Aug 21 13:46:25 2008 +0200 Revert "reduce tlb/cache flush times of agpgart memory allocation" This reverts commit 466ae837424dcc538b1af2a0eaf53be32edcdbe7. commit c3c1993b49d5ff44199fbf5d167bc752e7b3ae64 Author: Oleg Nesterov Date: Wed Aug 20 16:54:44 2008 -0700 wait_task_inactive: "improve" the returned value for ->nvcsw == 0 wait_task_inactive() returns 1 when p->nvcsw == 0 || p->nvcsw == 1. This means that two subsequent calls can return the same number while the task was scheduled in between. Change the code to return "nvcsw | LONG_MIN" instead of "nvcsw ?: 1", now the overlap always needs LONG_MAX schedules. Signed-off-by: Oleg Nesterov Signed-off-by: Andrew Morton Signed-off-by: Ingo Molnar commit 138f4e92e14ca765400454aa624bfe422232d601 Author: Oleg Nesterov Date: Wed Aug 20 16:54:44 2008 -0700 wait_task_inactive(): don't consider task->nivcsw If wait_task_inactive() returns success the task was deactivated. In that case schedule() always increments ->nvcsw which alone can be used as a "generation counter". If the next call returns the same number, we can be sure that the task was unscheduled. Otherwise, because we know that .on_rq == 0 again, ->nvcsw should have been changed in between. Q: perhaps it is better to do "ncsw = (p->nvcsw << 1) | 1" ? This decreases the possibility of "was it unscheduled" false positive when ->nvcsw == 0. Signed-off-by: Oleg Nesterov Signed-off-by: Andrew Morton Signed-off-by: Ingo Molnar commit d933c9cef9a610a2dcc8ff95347980ab463b4d5a Author: Oleg Nesterov Date: Wed Aug 20 16:54:41 2008 -0700 sched: do_wait_for_common: use signal_pending_state() Change do_wait_for_common() to use signal_pending_state() instead of open coding. Signed-off-by: Oleg Nesterov Signed-off-by: Andrew Morton Signed-off-by: Ingo Molnar commit d82f0b0f6f1a0a25afc288fb7135b1601fe6df18 Author: Oleg Nesterov Date: Wed Aug 20 16:46:04 2008 -0700 migrate_timers: add comment, use spinlock_irq() Add the comment to explain why the double lock in migrate_timers() can't deadlock. Change the code to use spinlock_irq() instead of local_irq_disable() + spin_lock(). Signed-off-by: Oleg Nesterov Acked-by: Steven Rostedt Signed-off-by: Andrew Morton Signed-off-by: Ingo Molnar commit 59dfc3f8fbabb8681ab4f2fb2df795f9211f40f9 Author: venkatesh.pallipadi@intel.com Date: Wed Aug 20 16:45:54 2008 -0700 x86: PAT documentation updates with debug info Documentation update for PAT. Reflect the latest API details. Also, adds details about ways to get more info in order to debug PAT. Signed-off-by: Venkatesh Pallipadi Signed-off-by: Ingo Molnar commit 671eef85a3e885dff4ce210d8774ad50a91d5967 Author: Cihula, Joseph Date: Wed Aug 20 16:43:07 2008 -0700 x86, e820: add support for AddressRangeUnusuable ACPI memory type Add support for the E820_UNUSABLE memory type, which is defined in Revision 3.0b (Oct. 10, 2006) of the ACPI Specification on p. 394 Table 14-1: AddressRangeUnusuable This range of address contains memory in which errors have been detected. This range must not be used by the OSPM. Signed-off-by: Joseph Cihula Signed-off-by: Shane Wang Signed-off-by: Gang Wei Signed-off-by: Andrew Morton Signed-off-by: Ingo Molnar commit 4e1d112cac08049e764fe3c4f6d3ec92529f9f68 Author: Huang Weiyi Date: Wed Aug 20 16:43:07 2008 -0700 arch/x86/kernel/apm_32.c: remove duplicated #include Removed duplicated include file in arch/x86/kernel/apm_32.c. Signed-off-by: Huang Weiyi Acked-by: Pavel Machek Signed-off-by: Ingo Molnar Signed-off-by: Andrew Morton commit aca64e0ba2419e6afa6dcc3a5afd66cae169c742 Author: Peter Zijlstra Date: Thu Aug 21 11:18:50 2008 +0200 sched: properly account IRQ and RT load in SCHED_OTHER load balancing We used to account for RT tasks in SCHED_OTHER load-balancing by giving them some phantom weight. This is incorrect because there is no saying how much time a RT task will actually consume. Also, it doesn't take IRQ time into account. This patch tries to solve this issue by accounting the time spend on both Real-Time tasks and IRQ handling, and using that to proportionally inflate the SCHED_OTHER load. [ mingo@elte.hu: UP build fix ] Signed-off-by: Peter Zijlstra Signed-off-by: Ingo Molnar commit d5e92e8978fd2574e415dc2792c5eb592978243d Author: Steven Rostedt Date: Wed Aug 20 12:55:07 2008 -0400 ftrace: x86 use copy to and from user functions The modification of code is performed either by kstop_machine, before SMP starts, or on module code before the module is executed. There is no reason to do the modifications from assembly. The copy to and from user functions are sufficient and produces cleaner and easier to read code. Thanks to Benjamin Herrenschmidt for suggesting the idea. Signed-off-by: Steven Rostedt Signed-off-by: Ingo Molnar commit a532e19680ada3b8579b81e67e76d3ebd19c340f Author: Yinghai Lu Date: Wed Aug 20 20:46:25 2008 -0700 x86: sparse_irq needs spin_lock in allocations Suresh Siddha noticed that we should have a spinlock around it. Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit 11494547b1754c4f3bd7f707ab869e2adf54d52f Author: Yinghai Lu Date: Thu Aug 21 01:01:19 2008 -0700 x86: fix apic version warning after following patch, commit 1b313f4a6d7bee7b2c034b3f1e203bc360a71cca Author: Cyrill Gorcunov Date: Mon Aug 18 20:45:57 2008 +0400 x86: apic - generic_processor_info - use physid_set instead of phys_cpu and physids_or - set phys_cpu_present_map bit AFTER check for allowed number of processors - add checking for APIC valid version in 64bit mode (mostly not needed but added for merging purpose) - add apic_version definition for 64bit mode which is used now we are getting warning for acpi path on 64 bit system. make the 64-bit side fill in apic_version[] as well. [ mingo@elte.hu: build fix ] Signed-off-by: Ingo Molnar commit 0fb3ab2dfad2a85ee9c5df28e815491054140261 Author: Alexander Beregalov Date: Thu Aug 21 08:28:42 2008 +0400 ALSA: revo51: add headphone output It is ALSA bug #1754. D6 bit in 02 register is PW4. Signed-off-by: Alexander Beregalov Signed-off-by: Takashi Iwai commit 52f0dd2f02ce1d8892f1ef34d3dee6e95da978f7 Author: Suresh Siddha Date: Wed Aug 20 17:22:51 2008 -0700 sparseirq: fix intr-remap with dyn_array/nr_irqs changes] In irq_2_iommu_alloc() and set_irte_irq(), irq_to_desc or irq_2_iommu pointers may not be allocated. So use the routines which will allocate them if they are not already allocated. Signed-off-by: Suresh Siddha Signed-off-by: Ingo Molnar commit e621bd18958ef5dbace3129ebe17a0a475e127d9 Author: Dave Young Date: Wed Aug 20 16:43:03 2008 -0700 i386: vmalloc size fix Booting kernel with vmalloc=[any size<=16m] will oops on my pc (i386/1G memory). BUG_ON in arch/x86/mm/init_32.c triggered: BUG_ON((unsigned long)high_memory > VMALLOC_START); It's due to the vm area hole. In include/asm-x86/pgtable_32.h: #define VMALLOC_OFFSET (8 * 1024 * 1024) #define VMALLOC_START (((unsigned long)high_memory + 2 * VMALLOC_OFFSET - 1) \ & ~(VMALLOC_OFFSET - 1)) There's several related point: 1. MAXMEM : (-__PAGE_OFFSET - __VMALLOC_RESERVE). The space after VMALLOC_END is included as well, I set it to (VMALLOC_END - PAGE_OFFSET - __VMALLOC_RESERVE) 2. VMALLOC_OFFSET is not considered in __VMALLOC_RESERVE fixed by adding VMALLOC_OFFSET to it. 3. VMALLOC_START : (((unsigned long)high_memory + 2 * VMALLOC_OFFSET - 1) & ~(VMALLOC_OFFSET - 1)) So it's not always 8M, bigger than 8M possible. I set it to ((unsigned long)high_memory + VMALLOC_OFFSET) 4. the VMALLOC_RESERVE is an unused macro, so remove it here. Signed-off-by: Dave Young Cc: akpm@linux-foundation.org Cc: hidave.darkstar@gmail.com Signed-off-by: Ingo Molnar Signed-off-by: Andrew Morton commit 2d96ae6b0dc03a568398c1655fb8967f01f8e40a Author: Andrew Morton Date: Wed Aug 20 16:43:02 2008 -0700 arch/x86/pci/irq.c: attempt to clean up code layout Signed-off-by: Andrew Morton Signed-off-by: Ingo Molnar commit 2d42244ae71d6c7b0884b5664cf2eda30fb2ae68 Author: John Stultz Date: Wed Aug 20 16:37:30 2008 -0700 clocksource: introduce CLOCK_MONOTONIC_RAW In talking with Josip Loncaric, and his work on clock synchronization (see btime.sf.net), he mentioned that for really close synchronization, it is useful to have access to "hardware time", that is a notion of time that is not in any way adjusted by the clock slewing done to keep close time sync. Part of the issue is if we are using the kernel's ntp adjusted representation of time in order to measure how we should correct time, we can run into what Paul McKenney aptly described as "Painting a road using the lines we're painting as the guide". I had been thinking of a similar problem, and was trying to come up with a way to give users access to a purely hardware based time representation that avoided users having to know the underlying frequency and mask values needed to deal with the wide variety of possible underlying hardware counters. My solution is to introduce CLOCK_MONOTONIC_RAW. This exposes a nanosecond based time value, that increments starting at bootup and has no frequency adjustments made to it what so ever. The time is accessed from userspace via the posix_clock_gettime() syscall, passing CLOCK_MONOTONIC_RAW as the clock_id. Signed-off-by: John Stultz Signed-off-by: Roman Zippel Signed-off-by: Andrew Morton Signed-off-by: Ingo Molnar commit 9a055117d3d9cb562f83f8d4cd88772761f4cab0 Author: Roman Zippel Date: Wed Aug 20 16:37:28 2008 -0700 clocksource: introduce clocksource_forward_now() To keep the raw monotonic patch simple first introduce clocksource_forward_now(), which takes care of the offset since the last update_wall_time() call and adds it to the clock, so there is no need anymore to deal with it explicitly at various places, which need to make significant changes to the clock. This is also gets rid of the timekeeping_suspend_nsecs, instead of waiting until resume, the value is accumulated during suspend. In the end there is only a single user of __get_nsec_offset() left, so I integrated it back to getnstimeofday(). Signed-off-by: Roman Zippel Signed-off-by: Andrew Morton Signed-off-by: Ingo Molnar commit 1aa5dfb751d275ae7117d3b73ac423b4a46f2a73 Author: John Stultz Date: Wed Aug 20 16:37:28 2008 -0700 clocksource: keep track of original clocksource frequency The clocksource frequency is represented by clocksource->mult/2^(clocksource->shift). Currently, when NTP makes adjustments to the clock frequency, they are made directly to the mult value. This has the drawback that once changed, we cannot know what the orignal mult value was, or how much adjustment has been applied. This property causes problems in calculating proper ntp intervals when switching back and forth between clocksources. This patch separates the current mult value into a mult and mult_orig pair. The mult_orig value stays constant, while the ntp clocksource adjustments are done only to the mult value. This allows for correct ntp interval calculation and additionally lays the groundwork for a new notion of time, what I'm calling the monotonic-raw time, which is introduced in a following patch. Signed-off-by: John Stultz Signed-off-by: Roman Zippel Signed-off-by: Andrew Morton Signed-off-by: Ingo Molnar commit ee974e01e5ef2914036f08c8e41d1a3fa8bfc9d9 Author: David Howells Date: Wed Aug 20 16:37:26 2008 -0700 clocksource: check range Check that the value being passed to parse_pmtmr() does not exceed the limits of pmtmr_ioport. Signed-off-by: David Howells Signed-off-by: Andrew Morton Signed-off-by: Ingo Molnar commit dbd3dca3d7d5b1cd36a3df2ee9ed2c46d99b7f64 Author: Robert P. J. Day Date: Wed Jul 30 12:48:55 2008 -0700 xtensa: use newer __SPIN_LOCK_UNLOCKED macro SPIN_LOCK_UNLOCKED() breaks lockdep and is deprecated. Signed-off-by: Robert P. J. Day Signed-off-by: Andrew Morton Signed-off-by: Chris Zankel commit d37ec7a1324564cd84b52f2ad40ec0141bb4ec99 Author: Robert P. J. Day Date: Wed Jul 30 12:48:53 2008 -0700 XTENSA: warn about including directly. For consistency with other architectures, warn about including directly. Signed-off-by: Robert P. J. Day Signed-off-by: Andrew Morton Signed-off-by: Chris Zankel commit 8679c5e3d59b5e19719257f7202c3bca41eed71e Author: Harvey Harrison Date: Wed Jul 30 12:48:54 2008 -0700 xtensa: replace remaining __FUNCTION__ occurrences __FUNCTION__ is gcc-specific, use __func__ Signed-off-by: Harvey Harrison Signed-off-by: Andrew Morton Signed-off-by: Chris Zankel commit b9fc996331ee520e99a5742140efe0d3e94e48c7 Author: Adrian Bunk Date: Wed Aug 20 10:35:44 2008 +1000 xtensa: remove dead CONFIG_BLK_DEV_IDE code I don't know why this was there, but it was dead code. Signed-off-by: Adrian Bunk Cc: chris@zankel.net Signed-off-by: Bartlomiej Zolnierkiewicz commit f0df2d6b52ad7db5edf56909509d51be66fe90be Author: Cyrill Gorcunov Date: Wed Aug 20 16:41:45 2008 -0700 acpi: add checking for NULL early param The early_param handling function could recieve NULL pointer as argument in case if user didn't enter parameter value. So we have to be ready for a such situation and do check for NULL pointer if needed. Signed-off-by: Cyrill Gorcunov Cc: Andi Kleen Signed-off-by: Andrew Morton Signed-off-by: Andi Kleen commit 79c4375bf2df96d725475e0c061a4d78c3bd0884 Author: Dennis Jansen Date: Wed Aug 20 16:44:03 2008 +0200 ACPI: Fix typo in "Disable MWAIT via DMI on broken Compal board" This fixes a typo in commit 2a2a64714d9c40f7705c4de1e79a5b855c7211a9 "Disable MWAIT via DMI on broken Compal board". It allows the nomwait dmi check to actually detect the Acer 5220. Signed-off-by: Dennis Jansen Tested-by: Dennis Jansen Acked-by: Zhao Yakui Signed-off-by: Andi Kleen commit f58e2c33ffa31b8d4a71609a5e71e8d893574a07 Author: Claudio Scordino Date: Wed Aug 20 15:18:45 2008 +0200 sched: new documentation about CFS Rewrite of the CFS documentation - because the old one was sorely out-dated. Signed-off-by: Claudio Scordino Acked-by: Peter Zijlstra Signed-off-by: Ingo Molnar commit 6d2b39229ffe3191b966f57d6a5f95b4e59a6f0d Author: Steven Rostedt Date: Wed Aug 20 10:07:35 2008 -0400 ftrace: handle weak symbol functions During tests and checks, I've discovered that there were failures to convert mcount callers into nops. Looking deeper into these failures, code that was attempted to be changed was not an mcount caller. The current code only updates if the code being changed is what it expects, but I still investigate any time there is a failure. What was happening is that a weak symbol was being used as a reference for other mcount callers. That weak symbol was also referenced elsewhere so the offsets were using the strong symbol and not the function symbol that it was referenced from. This patch changes the setting up of the mcount_loc section to search for a global function that is not weak. It will pick a local over a weak but if only a weak is found in a section, a warning is printed and the mcount location is not recorded (just to be safe). Signed-off-by: Steven Rostedt Signed-off-by: Ingo Molnar commit 01291d17b6257e5b91136995f07a1bb9db3ad448 Author: Anton Vorontsov Date: Thu Aug 14 21:13:42 2008 +0400 powerpc/83xx: mpc836x_mds: add support for the nor flash This patch adds the localbus node, moves the bcsr node into the localbus node, and adds the flash node. Also enable MTD support in the defconfig. Signed-off-by: Anton Vorontsov Signed-off-by: Kumar Gala commit e3f15abbd65fb5250567d6d5dfa4d479ec9365f1 Author: Kumar Gala Date: Mon Aug 4 08:27:52 2008 -0500 serial/cpm_uart: Remove dead Kconfig options With the change to device tree based setup we no longer need the explicit Kconfig options for each SCC{1,4} or SMC{1,2} port. Signed-off-by: Kumar Gala commit 2730a044ef3a4c762884e354b933a342edefef24 Author: Heiko Schocher Date: Wed Jun 18 10:38:32 2008 +0200 powerpc: Add support for mpc8247 based board MGCOGE from keymile. Signed-off-by: Heiko Schocher Signed-off-by: Kumar Gala commit b57c8ce49ce6be5aa75c7616e1ea6653e23c7a3c Author: Heiko Schocher Date: Sat Jun 14 21:02:04 2008 +0200 powerpc: Add support for the MPC852 based mgsuvd board from keymile. Supported SMC1 (serial console), SCC3 Ethernet (10Mbps hdx). Signed-off-by: Heiko Schocher Signed-off-by: Kumar Gala commit 3e290f7ee87070dd84065dd7cc7352938329aabc Author: Joel Becker Date: Wed Aug 20 17:44:24 2008 -0700 ocfs2: Create specific get_extent_tree functions. A caller knows what kind of extent tree they have. There's no reason they have to call ocfs2_get_extent_tree() with a NULL when they could just as easily call a specific function to their type of extent tree. Introduce ocfs2_dinode_get_extent_tree(), ocfs2_xattr_tree_get_extent_tree(), and ocfs2_xattr_value_get_extent_tree(). They only take the necessary arguments, calling into the underlying __ocfs2_get_extent_tree() to do the real work. __ocfs2_get_extent_tree() is the old ocfs2_get_extent_tree(), but without needing any switch-by-type logic. ocfs2_get_extent_tree() is now a wrapper around the specific calls. It exists because a couple alloc.c functions can take et_type. This will go later. Another benefit is that ocfs2_xattr_value_get_extent_tree() can take a struct ocfs2_xattr_value_root* instead of void*. This gives us typechecking where we didn't have it before. Signed-off-by: Joel Becker commit 6c0c1a42fee9a29e05d9255f3e49e6e729c3511f Author: Joel Becker Date: Wed Aug 20 17:31:10 2008 -0700 ocfs2: Determine an extent tree's max_leaf_clusters in an et_op. Provide an optional extent_tree_operation to specify the max_leaf_clusters of an ocfs2_extent_tree. If not provided, the value is 0 (unlimited). Signed-off-by: Joel Becker commit f5d54cf22e2eedd855d4c663aa5cbd423e2db500 Author: Joel Becker Date: Wed Aug 20 17:09:42 2008 -0700 ocfs2: Use struct ocfs2_extent_tree in ocfs2_num_free_extents(). ocfs2_num_free_extents() re-implements the logic of ocfs2_get_extent_tree(). Now that ocfs2_get_extent_tree() does not allocate, let's use it in ocfs2_num_free_extents() to simplify the code. The inode validation code in ocfs2_num_free_extents() is not needed. All callers are passing in pre-validated inodes. Signed-off-by: Joel Becker commit 7afa648c3afb8cc6b31b97e91e2b3be7be0deb9f Author: Joel Becker Date: Wed Aug 20 17:19:50 2008 -0700 ocfs2: Provide the get_root_el() method to ocfs2_extent_tree_operations. The root_el of an ocfs2_extent_tree needs to be calculated from et->et_object. Make it an operation on et->et_ops. Signed-off-by: Joel Becker commit 886068dff1f5f3ce22426d07c97d22ce95e747d6 Author: Joel Becker Date: Wed Aug 20 16:57:27 2008 -0700 ocfs2: Make 'private' into 'object' on ocfs2_extent_tree. The 'private' pointer was a way to store off xattr values, which don't live at a set place in the bh. But the concept of "the object containing the extent tree" is much more generic. For an inode it's the struct ocfs2_dinode, for an xattr value its the value. Let's save off the 'object' at all times. If NULL is passed to ocfs2_get_extent_tree(), 'object' is set to bh->b_data; Signed-off-by: Joel Becker commit ca2dc75d814d83e280ceed9993279b71ca8957c8 Author: Joel Becker Date: Wed Aug 20 16:48:35 2008 -0700 ocfs2: Make ocfs2_extent_tree get/put instead of alloc. Rather than allocating a struct ocfs2_extent_tree, just put it on the stack. Fill it with ocfs2_get_extent_tree() and drop it with ocfs2_put_extent_tree(). Now the callers don't have to ENOMEM, yet still safely ref the root_bh. Signed-off-by: Joel Becker commit f68e8668cef2835766c991d0357d7a43ccde96c7 Author: Joel Becker Date: Wed Aug 20 16:30:07 2008 -0700 ocfs2: Prefix the ocfs2_extent_tree structure. The members of the ocfs2_extent_tree structure gain a prefix of 'et_'. All users are updated. Signed-off-by: Joel Becker commit 098f8563277419c204ee04b9cf349a8a92000b29 Author: Joel Becker Date: Wed Aug 20 16:25:06 2008 -0700 ocfs2: Prefix the extent tree operations structure. The ocfs2_extent_tree_operations structure gains a field prefix on its members. The ->eo_sanity_check() operation gains a wrapper function for completeness. All of the extent tree operation wrappers gain a consistent name (ocfs2_et_*()). Signed-off-by: Joel Becker commit 1523131225e258006489e8c208ad422d35fc9813 Author: Chuck Lever Date: Mon Aug 18 19:34:16 2008 -0400 SUNRPC: Support IPv6 when registering kernel RPC services In order to advertise NFS-related services on IPv6 interfaces via rpcbind, the kernel RPC server implementation must use rpcb_v4_register() instead of rpcb_register(). A new kernel build option allows distributions to use the legacy v2 call until they integrate an appropriate user-space rpcbind daemon that can support IPv6 RPC services. I tried adding some automatic logic to fall back if registering with a v4 protocol request failed, but there are too many corner cases. So I just made it a compile-time switch that distributions can throw when they've replaced portmapper with rpcbind. Signed-off-by: Chuck Lever Signed-off-by: J. Bruce Fields commit 1e2d05b1531a046a1eeb7e3d4b706da469a42d2b Author: Chuck Lever Date: Mon Aug 18 19:34:08 2008 -0400 SUNRPC: Split portmap unregister API into separate function Create a separate server-level interface for unregistering RPC services. The mechanics of, and the API for, registering and unregistering RPC services will diverge further as support for IPv6 is added. Signed-off-by: Chuck Lever Signed-off-by: J. Bruce Fields commit 5900b51ee2ed1fbe0ba87aa35d34e86eea97f242 Author: Chuck Lever Date: Mon Aug 18 19:34:00 2008 -0400 SUNRPC: Simplify rpcb_register() API Bruce suggested there's no need to expose the difference between an error sending the PMAP_SET request and an error reply from the portmapper to rpcb_register's callers. The user space equivalent of rpcb_register() is pmap_set(3), which returns a bool_t : either the PMAP set worked, or it didn't. Simple. So let's remove the "*okay" argument from rpcb_register() and rpcb_v4_register(), and simply return an error if any part of the call didn't work. Signed-off-by: Chuck Lever Signed-off-by: J. Bruce Fields commit 445279a9dfec1741649233bfa8fd3b19ac1e1a40 Author: Chuck Lever Date: Mon Aug 18 19:33:44 2008 -0400 SUNRPC: Set V6ONLY socket option for RPC listener sockets My plan is to use an AF_INET listener on systems that support only IPv4, and an AF_INET6 listener on systems that can support IPv6. Incoming IPv4 packets will be posted to an AF_INET6 listener with a mapped IPv4 address. Max Matveev says: Creating a single listener can be dangerous - if net.ipv6.bindv6only is enabled then it's possible to create another listener in v4 namespace on the same port and steal the traffic from the "unifed" listener. You need to disable V6ONLY explicitly via a sockopt to stop that. Set appropriate socket option on RPC server listener sockets to prevent this. Signed-off-by: Chuck Lever Signed-off-by: J. Bruce Fields commit d9105c2b01eedb620cae96073dde4f760367817f Author: Marek Vašut Date: Sun Aug 3 21:34:08 2008 +0100 [ARM] 5184/1: Split ucb1400_ts into core and touchscreen This patch splits ucb1400_ts into ucb1400_ts and ucb1400_core. Since this chip supports more features than only touchscreen, it was necessary to prepare it for feature addition. The previous functionality is preserved by applying this patch. [Build fixes for non-ARM by Stephen Rothwell and Takashi Iwai] Signed-off-by: Marek Vasut Signed-off-by: Russell King commit 17c1d2be28e485c0c8b09661db39d5bf2605069d Author: Alexey Korolev Date: Wed Aug 20 22:32:08 2008 +0100 [MTD] [NAND] Fix missing kernel-doc [Reported by Randy Dunlap] Signed-off-by: Alexey Korolev Signed-off-by: David Woodhouse commit 1077be58ad7baadd86e47e8b4f6209fa5b6364a5 Author: frans Date: Wed Aug 20 21:11:50 2008 +0200 [MTD] [NAND] nand_ecc.c: fix big endian, strengthen test, add printk This patch for nand_ecc.c fixes three issues - fix code so it also works on big endian architectures - added a printk in case of an uncorrectable ecc error - strengthen the test for correctable errors (decreasing the chance that multiple bit faults by accident will be seen as correctable) Note: the big endian code is only tested in a testbed (running on big endian hardware) as I cannot rebuild and test a big endian kernel at the moment. However the only thing that can go wrong is if does not give __BIG_ENDIAN in that case. In my eyes very unlikely. Signed-off-by: Frans Meulenbroeks Signed-off-by: David Woodhouse commit e035021f0f67584683babde9b6c9819f1f6f708f Author: Takashi Iwai Date: Wed Aug 20 18:38:26 2008 +0200 ALSA: hda - Create beep control on ALC269 codec ALC269 codec has a beep, but it was not used, so far. Create a beep control appropriately. Signed-off-by: Takashi Iwai commit 1fa63a817d27af7dc0d5ed454eb8fe5dec65fac7 Author: Jiri Kosina Date: Wed Aug 20 14:40:55 2008 +0200 printk: robustify printk, update comment Remove the comment describing the possibility of printk() deadlocking on runqueue lock. Signed-off-by: Jiri Kosina Acked-by: Peter Zijlstra Signed-off-by: Ingo Molnar commit ce094fc0d25cb364bce6f854dffc6849876ab89a Author: Avi Kivity Date: Wed Aug 20 15:51:42 2008 +0300 KVM: Load real mode segments correctly Real mode segments to not reference the GDT or LDT; they simply compute base = selector * 16. Signed-off-by: Avi Kivity commit 7ed52248201f22614f6f83a50248ed627c1f06f5 Author: Avi Kivity Date: Wed Aug 20 15:50:34 2008 +0300 KVM: VMX: Leave atomic context while emulating real mode Emulation requires access to user memory, and potentially schedules. Signed-off-by: Avi Kivity commit d63142f9998355a76e850e06cad24ea5af9b267e Author: Avi Kivity Date: Wed Aug 20 15:48:27 2008 +0300 KVM: VMX: Change segment dpl at reset to 3 This is more emulation friendly, if not 100% correct. Signed-off-by: Avi Kivity commit 344a43ee3b5a6558dc48fc7b07664c58397dc0bb Author: Avi Kivity Date: Wed Aug 20 15:07:31 2008 +0300 KVM: VMX: Change cs reset state to be a data segment Real mode cs is a data segment, not a code segment. Signed-off-by: Avi Kivity commit 0a7c144ca555c86b8410f2d6e1c10bf14fd481d1 Author: Ingo Molnar Date: Mon Aug 18 13:04:26 2008 +0200 warning: fix arch x86 kernel io_apic c fix warning: arch/x86/kernel/io_apic.c: In function ‘print_local_APIC’: arch/x86/kernel/io_apic.c:1786: warning: format ‘%08x’ expects type ‘unsigned int’, but argument 2 has type ‘u64’ arch/x86/kernel/io_apic.c:1787: warning: format ‘%08x’ expects type ‘unsigned int’, but argument 2 has type ‘u64’ By creating uniform behavior on 32-bit and 64-bit and printing out the ICR value in two 32-bit words. Code has changed: text data bss dec hex filename 22901 19650 17040 59591 e8c7 io_apic.o.before 22899 19650 17040 59589 e8c5 io_apic.o.after Due to the 32-bit cast narrowing the printed out value on 64-bit. Signed-off-by: Ingo Molnar commit 863d6e1a39dba3af46a9a5bc9273e7f4a7b85113 Author: Steven Rostedt Date: Fri Aug 15 11:40:24 2008 -0400 ftrace: update recordmount.pl arch changes I'm trying to keep all the arch changes in recordmcount.pl in one place. I moved your code into that area, by adding the flags to the commands that were passed in. Signed-off-by: Steven Rostedt Signed-off-by: Ingo Molnar commit 7708ad64a24a674f7905aa7a5099a50f055debec Author: Jeremy Fitzhardinge Date: Tue Aug 19 13:34:22 2008 -0700 xen: add xen_ prefixes to make tracing with ftrace easier It's easier to pattern match on Xen function if they all start with xen_. Signed-off-by: Jeremy Fitzhardinge Signed-off-by: Ingo Molnar commit 11ad93e59d114f4b218873f1c93261be725d2e22 Author: Jeremy Fitzhardinge Date: Tue Aug 19 13:32:51 2008 -0700 xen: clarify locking used when pinning a pagetable. Add some comments explaining the locking and pinning algorithm when using split pte locks. Also implement a minor optimisation of not pinning the PTE when not using split pte locks. Signed-off-by: Jeremy Fitzhardinge Cc: Xen-devel Signed-off-by: Ingo Molnar commit 63d3a75d6f1fcf2f33e6abbe84e1f428c3586152 Author: Jeremy Fitzhardinge Date: Tue Aug 19 13:19:36 2008 -0700 x86/paravirt: add spin_lock_flags lock op It is useful for a pv_lock_ops backend to know whether interrupts are enabled or not in the context a spin_lock is being called. This allows it to enable interrupts while spinning, which could be particularly helpful when spinning becomes blocking. The default implementation just calls the normal spin_lock op, ignoring the flags. Signed-off-by: Jeremy Fitzhardinge Signed-off-by: Ingo Molnar commit 6e833587e11ed0dbf12e647127f2650e2f80b26d Author: Jeremy Fitzhardinge Date: Tue Aug 19 13:16:17 2008 -0700 xen: clean up domain mode predicates There are four operating modes Xen code may find itself running in: - native - hvm domain - pv dom0 - pv domU Clean up predicates for testing for these states to make them more consistent. Signed-off-by: Jeremy Fitzhardinge Cc: Xen-devel Signed-off-by: Ingo Molnar commit 27990eac52dae87b909ef4f7e796fb6ec758bb94 Author: Jeremy Fitzhardinge Date: Tue Aug 19 13:10:07 2008 -0700 x86: another user of PTE_FLAGS_MASK Signed-off-by: Jeremy Fitzhardinge Signed-off-by: Ingo Molnar commit b6edbb1e045a7116d5571544dae25c6c37c94a48 Author: Jeremy Fitzhardinge Date: Tue Aug 19 13:04:19 2008 -0700 x86_64: use save/loadsegment in ia32 compat Use savesegment and loadsegment consistently in ia32 compat code. Signed-off-by: Jeremy Fitzhardinge Signed-off-by: Ingo Molnar commit fa33507a22623b3bd543b15a21c362cf364b6cff Author: Peter Zijlstra Date: Wed Aug 20 09:31:26 2008 +0200 printk: robustify printk, fix #2 Dmitry Adamushko reported: > [*] btw., with DEBUG being enabled, pr_debug() generates [1] when > debug_smp_processor_id() is used (CONFIG_DEBUG_PREEMPT). > > the problem seems to be caused by the following commit: > commit b845b517b5e3706a3729f6ea83b88ab85f0725b0 > Author: Peter Zijlstra > Date: Fri Aug 8 21:47:09 2008 +0200 > > printk: robustify printk > > > wake_up_klogd() -> __get_cpu_var() -> smp_processor_id() > > and that's being called from release_console_sem() which is, in turn, > said to be "may be called from any context" [2] > > and in this case, it seems to be called from some non-preemptible > context (although, it can't be printk()... > although, I haven't looked carefully yet). > > Provided [2], __get_cpu_var() is perhaps not the right solution there. > > > [1] > > [ 7697.942005] BUG: using smp_processor_id() in preemptible [00000000] code: syslogd/3542 > [ 7697.942005] caller is wake_up_klogd+0x1b/0x50 > [ 7697.942005] Pid: 3542, comm: syslogd Not tainted 2.6.27-rc3-tip-git #2 > [ 7697.942005] Call Trace: > [ 7697.942005] [] debug_smp_processor_id+0xe8/0xf0 > [ 7697.942005] [] wake_up_klogd+0x1b/0x50 > [ 7697.942005] [] release_console_sem+0x1e7/0x200 > [ 7697.942005] [] do_con_write+0xb7/0x1f30 > [ 7697.942005] [] ? show_trace+0x10/0x20 > [ 7697.942005] [] ? dump_stack+0x72/0x80 > [ 7697.942005] [] ? __ratelimit+0xbd/0xe0 > [ 7697.942005] [] ? debug_smp_processor_id+0xe8/0xf0 > [ 7697.942005] [] ? wake_up_klogd+0x1b/0x50 > [ 7697.942005] [] ? release_console_sem+0x1e7/0x200 > [ 7697.942005] [] con_write+0x19/0x30 > [ 7697.942005] [] write_chan+0x276/0x3c0 > [ 7697.942005] [] ? default_wake_function+0x0/0x10 > [ 7697.942005] [] ? _spin_lock_irqsave+0x22/0x50 > [ 7697.942005] [] tty_write+0x194/0x260 > [ 7697.942005] [] ? write_chan+0x0/0x3c0 > [ 7697.942005] [] redirected_tty_write+0xa4/0xb0 > [ 7697.942005] [] ? redirected_tty_write+0x0/0xb0 > [ 7697.942005] [] do_loop_readv_writev+0x52/0x80 > [ 7697.942005] [] do_readv_writev+0x1bd/0x1d0 > [ 7697.942005] [] vfs_writev+0x39/0x60 > [ 7697.942005] [] sys_writev+0x50/0x90 > [ 7697.942005] [] system_call_fastpath+0x16/0x1b Signed-off-by: Peter Zijlstra Reported-by: Dmitry Adamushko Signed-off-by: Ingo Molnar commit d45de40934897c6ee5b05141f7895bbb28512395 Author: Dmitry Adamushko Date: Wed Aug 20 00:22:26 2008 +0200 x86-microcode: generic interface refactoring This is the 1st patch in the series. Here the aim was to avoid any significant changes, logically-wise. So it's mainly about generic interface refactoring: e.g. make microcode_{intel,amd}.c more about arch-specific details and less about policies like make-sure-we-run-on-a-target-cpu (no more set_cpus_allowed_ptr() here) and generic synchronization (no more microcode_mutex here). All in all, more line have been deleted than added. 4 files changed, 145 insertions(+), 198 deletions(-) Signed-off-by: Dmitry Adamushko Signed-off-by: Ingo Molnar commit 8343ef2437c599d30568e6b5a257a40bf2f4902b Author: Dmitry Adamushko Date: Wed Aug 20 00:16:13 2008 +0200 x86-microcode: fix unbalanced use of get_cpu() Don't use get_cpu() at all. Resort to checking a boot-up CPU (#0) in microcode_{intel,amd}_module_init(). Signed-off-by: Dmitry Adamushko Signed-off-by: Ingo Molnar commit 3f23d815c5049c9d7022226cec2242e384dd0b43 Author: Randy Dunlap Date: Sun Aug 17 21:44:22 2008 -0700 security: add/fix security kernel-doc Add security/inode.c functions to the kernel-api docbook. Use '%' on constants in kernel-doc notation. Fix several typos/spellos in security function descriptions. Signed-off-by: Randy Dunlap Signed-off-by: James Morris commit c171f465b7281f2d3b03e9145ec763d6a8bab176 Author: Uros Bizjak Date: Wed Aug 20 10:44:47 2008 +0200 x86, cleanup: use X86_CR4_PGE in x86/power/hibernate_asm_32.S Signed-off-by: Uros Bizjak Signed-off-by: Ingo Molnar commit 3fb4198766c38aa03492cc3996475076073c22ea Author: Ingo Molnar Date: Wed Aug 20 11:17:40 2008 +0200 softlockup: increase hung tasks check from 2 minutes to 8 minutes Andrew says: > Seems that about 100% of the reports we get of this warning triggering > are sys_sync, transaction commit, etc. increase the timeout. If it still triggers for people, we can kill it. Signed-off-by: Ingo Molnar commit 10b9662e0688b33e30600f4117ab3fed3d154367 Author: Alex Nixon Date: Mon Aug 18 22:17:08 2008 -0700 xen: Fix bug `do_IRQ: cannot handle IRQ -1 vector 0x6 cpu 1' Following commit 9c3f2468d8339866d9ef6a25aae31a8909c6be0d, do_IRQ() looks up the IRQ number in the per-cpu variable vector_irq. This commit makes Xen initialise an identity vector_irq map for both X86_32 and X86_64. Signed-off-by: Alex Nixon Acked-by: Jeremy Fitzhardinge Signed-off-by: Ingo Molnar commit 35aa85ded56859bb637bf36be5d4e7c5e62a60e8 Author: Yinghai Lu Date: Tue Aug 19 20:50:54 2008 -0700 dyn_array: split dyn_array functions from init/main.c Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit 47dd1317e00176e6494e33bad30ad2bc80a0013f Author: Alex Nixon Date: Tue Aug 19 20:50:53 2008 -0700 xen: fix memory access violation bug when CONFIG_HAVE_SPARSE_IRQ is enabled When sparse IRQs are enabled, it is not safe to assume an IRQ descriptor exists for every possible IRQ. This patch causes init_evtchn_cpu_bindings to skip initialisation of IRQ descriptors which don't exist. Signed-off-by: Alex Nixon Acked-by: Jeremy Fitzhardinge Signed-off-by: Ingo Molnar commit 16e62580564d1389737e228b9a421857177ade0d Author: Yinghai Lu Date: Tue Aug 19 20:50:52 2008 -0700 x86: probe nr_irqs even only mptable is used for !CONFIG_HAVE_SPARSE_IRQ fix: In file included from arch/x86/kernel/early-quirks.c:18: include/asm/io_apic.h: In function 'probe_nr_irqs': include/asm/io_apic.h:209: error: 'NR_IRQS' undeclared (first use in this function) include/asm/io_apic.h:209: error: (Each undeclared identifier is reported only once include/asm/io_apic.h:209: error: for each function it appears in.) v2: fix by Ingo Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit f9fd45f2685e4e40dad84c002226e9aeb860dffe Author: Yinghai Lu Date: Tue Aug 19 20:50:51 2008 -0700 x86: make HAVE_SPARSE_IRQ support selectable Ingo said sparse_irq is some intrusive. need to make it selectable to make it simple, remove irq_desc as parameter in some functions. (ack, eoi, set_affinity). may need to make member if irq_chip to take irq_desc, or struct irq later. Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit dfcfe14b26b014f209a3dc2ec67874e8f0e89e77 Author: Yinghai Lu Date: Tue Aug 19 20:50:50 2008 -0700 x86: print local APIC of APs one by one instead of print that of all APs at the time Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit 1ecaaac1292ec5e28d099fe0e16b1ce08a3a255a Author: Yinghai Lu Date: Tue Aug 19 20:50:49 2008 -0700 x86: remove first_free_entry/pin_map_size no user now Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit 1902eb681d9e9ffc2a22dca89c76c53fcc2975c8 Author: Yinghai Lu Date: Tue Aug 19 20:50:48 2008 -0700 x86: unify ack_apic_edge use code in 64 to replace move_native_irq(irq, desc); in 32 bit Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit 2eb9d357edaf77bb8b260840f6c80afca3c60998 Author: Yinghai Lu Date: Tue Aug 19 20:50:47 2008 -0700 x86: unify mask_IO_APIC_irq use MACRO for 32 bit too Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit 3f5edd7678b227130e5003f58561219711ecf18c Author: Yinghai Lu Date: Tue Aug 19 20:50:46 2008 -0700 x86: irq: interrupt array size should be NR_VECTORS Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit 9e40236d55418e1cd7d385b6474639b10d8ddee0 Author: Yinghai Lu Date: Tue Aug 19 20:50:45 2008 -0700 pci: change msi-x vector to 32bit we are using 28bit pci (bus/dev/fn + 12 bits) as irq number, so the cache for irq number should be 32 bit too. Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit 8a61eb45f46dd3f24e771fd4d1072f25463cb95f Author: Yinghai Lu Date: Tue Aug 19 20:50:43 2008 -0700 io_apic: make 32 bit have io_apic resource in /proc/iomem Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit aaf2118867696ccfe7b600263a2352ba333f5964 Author: Yinghai Lu Date: Tue Aug 19 20:50:42 2008 -0700 rename io_apic_64.c and io_apic_32.c to io_apic.c The two files are now line by line equal. Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit de300b223c2ecd186bced39e623930080abc02d3 Author: Ingo Molnar Date: Wed Aug 20 09:07:45 2008 +0200 x86: make io_apic_32.c the same as io_apic_64.c Signed-off-by: Ingo Molnar commit 47367da0e335610bfac8b659ff288d3c09e63c3f Author: Yinghai Lu Date: Tue Aug 19 20:50:41 2008 -0700 x86: make io_apic_64.c and io_apic_32.c the same all the same except INTR_REMAPPING related and ioapic io resource. Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit e8a3198b9ef3c8ca9c6bf0abc95e69f907600b70 Author: Yinghai Lu Date: Tue Aug 19 20:50:40 2008 -0700 x86: remove ioapic_force no user left. Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit 0a849011aa7c298586573334d0b8a4ed0bf968c8 Author: Yinghai Lu Date: Tue Aug 19 20:50:39 2008 -0700 x86: make 64 handle sis_apic_bug like the 32 bit do we have 64bit system with sis chipset? [ mingo@elte.hu: nope, the problem chipset was 32-bit only. The code symmetry is good nevertheless. ] Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit b3f3f223d4be8aa051c3e659f226b8e48c5981a3 Author: Yinghai Lu Date: Tue Aug 19 20:50:38 2008 -0700 x86: make headers files the same in io_apic_xx.c also make no_timer_check to be global on 64 bit, because vmi_32 is using that. Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit 95e9fdf90f0f4bd5d14a79437ac7c1769ec69f8e Author: Ingo Molnar Date: Tue Aug 19 20:50:37 2008 -0700 sparseirq: fix lockdep -tip testing found this lockdep splat: [ 0.000000] Initializing CPU#0 [ 0.000000] found new irq_desc for irq 0 [ 0.000000] INFO: trying to register non-static key. [ 0.000000] the code is fine but needs lockdep annotation. [ 0.000000] turning off the locking correctness validator. [ 0.000000] Pid: 0, comm: swapper Not tainted 2.6.27-rc3-tip-00191-g98ccb89-dirty #1 [ 0.000000] [] register_lock_class+0x3d2/0x400 [ 0.000000] [] ? mcount_call+0x5/0xa [ 0.000000] [] __lock_acquire+0x22a/0x5d0 [ 0.000000] [] ? mcount_call+0x5/0xa [ 0.000000] [] lock_acquire+0x71/0xa0 [ 0.000000] [] ? set_irq_chip+0x3f/0x90 [ 0.000000] [] _spin_lock_irqsave+0x58/0x90 [ 0.000000] [] ? set_irq_chip+0x3f/0x90 [ 0.000000] [] set_irq_chip+0x3f/0x90 [ 0.000000] [] ? handle_level_irq+0x0/0xe0 [ 0.000000] [] set_irq_chip_and_handler_name+0x1a/0x40 [ 0.000000] [] init_ISA_irqs+0x51/0xa0 [ 0.000000] [] pre_intr_init_hook+0x25/0x30 [ 0.000000] [] native_init_IRQ+0x13/0x370 [ 0.000000] [] ? lock_release+0xcc/0x1d0 [ 0.000000] [] ? mcount_call+0x5/0xa [ 0.000000] [] ? __mutex_unlock_slowpath+0x92/0x110 [ 0.000000] [] ? mutex_unlock+0xd/0x10 [ 0.000000] [] ? cpu_maps_update_done+0x12/0x20 [ 0.000000] [] ? register_cpu_notifier+0x23/0x30 [ 0.000000] [] init_IRQ+0xe/0x10 [ 0.000000] [] start_kernel+0x1c5/0x340 [ 0.000000] [] ? unknown_bootoption+0x0/0x210 [ 0.000000] [] i386_start_kernel+0x6b/0x80 [ 0.000000] ======================= [ 0.000000] found new irq_desc for irq 1 [ 0.000000] found new irq_desc for irq 2 [ 0.000000] found new irq_desc for irq 3 this: static void init_one_irq_desc(struct irq_desc *desc) { memcpy(desc, &irq_desc_init, sizeof(struct irq_desc)); #ifdef CONFIG_TRACE_IRQFLAGS lockdep_set_class(&desc->lock, &irq_desc_lock_class); #endif } should be unconditional. Signed-off-by: Ingo Molnar commit 7d5bac793c966af5524e5c4cbdf3ea4d7c86d5dd Author: Yinghai Lu Date: Tue Aug 19 20:50:36 2008 -0700 x86: order variables in io_apic_xx.c move first_system_vector to apic_64.c. also add #ifdef CONFIG_INTR_REMAP to prepare 32 bit to use same file. Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit 613b1c368f5a3823145eb898e7fb2e3131c3af97 Author: Yinghai Lu Date: Tue Aug 19 20:50:35 2008 -0700 x86: ordering functions in io_apic_64.c try to make functions have the same order between 32-bit and 64-bit. Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit 9aef78f37c5af907391bc11f4e708a8a252697d0 Author: Yinghai Lu Date: Tue Aug 19 20:50:34 2008 -0700 x86: ordering functions in io_apic_32.c prepare for unification: try to make functions be of the same order to io_apic_64.c. v2: add calling setup_msi_irq back to arch_setup_msi_irq Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit 029675fcea486b78a3976a01470069c43bb73453 Author: Yinghai Lu Date: Tue Aug 19 20:50:33 2008 -0700 x86, io-apic: remove union about dest for log/phy let user decide the meaning of the bits. This unifies the 32-bit and 64-bit io-apic code a bit. Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit af6e0966168a9f481d8e9c110a6e2f63d5c20a15 Author: Yinghai Lu Date: Tue Aug 19 20:50:32 2008 -0700 x86: add debug info for 32bit sparse_irq so could figure out bugs where we get an interrupt, but vector_irq is not initialized yet. Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit 315bc870563c9e1e4aab69f0fddbf4081864bbdb Author: Yinghai Lu Date: Tue Aug 19 20:50:28 2008 -0700 x86: make 32bit support per_cpu vector so we can merge io_apic_32.c and io_apic_64.c v2: Use cpu_online_map as target cpus for bigsmp, just like 64-bit is doing. Also remove some unused TARGET_CPUS macro. v3: need to check if desc is null in smp_irq_move_cleanup also migration needs to reset vector too, so copy __target_IO_APIC_irq from 64bit. (the duplication will go away once the two files are unified.) Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit 70426a06a58561c401e64c5767d71a011d4b978b Author: Yinghai Lu Date: Tue Aug 19 20:50:27 2008 -0700 x86: make 32 bit to use sparse_irq but actually irq still needs to be less than NR_IRQS, because interrupt[NR_IRQS] in entry.S. need to enable per_cpu vector... Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit 3e5a1c17440394ba2f7edebe7aa8526c83a561db Author: Yinghai Lu Date: Tue Aug 19 20:50:26 2008 -0700 x86: make 32bit to use irq_2_pin in irq_cfg so it is more like 64 bit. Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit dc45855468bcfe0eaf4efecae38cd3e2a1868bdd Author: Yinghai Lu Date: Tue Aug 19 20:50:25 2008 -0700 x86: make 32bit use irq_cfg_alloc, etc Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit fc9830589b1713ad35927a58f2a35eaffec3f0bf Author: Yinghai Lu Date: Tue Aug 19 20:50:24 2008 -0700 x86: add irq_cfg for 32bit it only contains vector ... Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit b07e51e949d029973972bca95a933ee2a48b06c7 Author: Yinghai Lu Date: Tue Aug 19 20:50:23 2008 -0700 x86: remove irqbalance in kernel for 32 bit This has been deprecated for years, the user space irqbalanced utility works better with numa, has configurable policies, etc... Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit 393b543bf99ac8d4f5ab9b2d0c03f75df7f7df5d Author: Yinghai Lu Date: Tue Aug 19 20:50:22 2008 -0700 x86: use 28 bits irq NR for pci msi/msix and ht also print out irq no in /proc/interrups and /proc/stat in hex, so could tell bus/dev/func. Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit 0cd45681b88f1f9064a3ce7107e330d5e193fbf5 Author: Yinghai Lu Date: Tue Aug 19 20:50:21 2008 -0700 x86: put irq_2_iommu pointer into irq_desc when CONFIG_HAVE_SPARSE_IRQ preallocate some irq_2_iommu entries, and use get_one_free_irq_2_iomm to get new one and link to irq_desc if needed. else will use dyn_array or static array. v2: <= nr_irqs fix Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit 9ac68c3e185111347b2d62a834197a30a785b182 Author: Yinghai Lu Date: Tue Aug 19 20:50:20 2008 -0700 x86_64: make /proc/interrupts work with dyn irq_desc loop with irq_desc list Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit 1a9cd3d3065c4188db953080cdbf39af3d153950 Author: Yinghai Lu Date: Tue Aug 19 20:50:19 2008 -0700 x86_64: separate irq_cfgx from irq_cfgx_free so later don't need to compare with -1U Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit 93dce194f969977cdb3ea1f73234d390a4537aeb Author: Yinghai Lu Date: Tue Aug 19 20:50:18 2008 -0700 irq: separate sparse_irqs from sparse_irqs_free so later don't need compare with -1U Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit 847f10693117db311e12ca58afa034467df5426f Author: Yinghai Lu Date: Tue Aug 19 20:50:17 2008 -0700 x86_64: rename irq_desc/irq_desc_alloc change names: irq_desc() ==> irq_desc_alloc __irq_desc() ==> irq_desc Also split a few of the uses in lowlevel x86 code. v2: need to check if desc is null in smp_irq_move_cleanup Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit 1b0dfd1863b4a455d25138e106b7dc91c363edbe Author: Yinghai Lu Date: Tue Aug 19 20:50:16 2008 -0700 x86: check with without_new in show_interrupts so we don't get new one that we don't need it. Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit 8d1d05e9feb908a634fb8e377da6abf4b538da29 Author: Yinghai Lu Date: Tue Aug 19 20:50:15 2008 -0700 generic: add irq_desc in function in parameter So we could remove some duplicated calling to irq_desc v2: make sure irq_desc in init/main.c is not used without generic_hardirqs Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit 1928d438ff09aff977d0e1bcee3f48109a38bb86 Author: Yinghai Lu Date: Tue Aug 19 20:50:14 2008 -0700 irq: remove >= nr_irqs checking with config_have_sparse_irq remove irq limit checks - nr_irqs is dynamic and we expand anytime. v2: fix checking about result irq_cfg_without_new, so could use msi again v3: use irq_desc_without_new to check irq is valid Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit 48e08b5de11d347e4d0876404a23703d82485b4b Author: Yinghai Lu Date: Tue Aug 19 20:50:13 2008 -0700 x86, ioapic: replace loop with nr_irqs with for_each_irq_icfg Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit 40643ffad6bb55f15796e7668f7792935247fc80 Author: Yinghai Lu Date: Tue Aug 19 20:50:12 2008 -0700 irq, fs/proc: replace loop with nr_irqs for proc/stat Replace another nr_irqs loop to avoid the allocation of all sparse irq entries - use for_each_irq_desc instead. v2: make sure arch without GENERIC_HARDIRQS works too Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit 7329b0cf6b812caea0abb97740cb09571dea1dc0 Author: Yinghai Lu Date: Tue Aug 19 20:50:11 2008 -0700 irq: replace loop with nr_irqs with for_each_irq_desc There are a handful of loops that go from 0 to nr_irqs and use get_irq_desc() on them. These would allocate all the irq_desc entries, regardless of the need for them. Use the smarter for_each_irq_desc() iterator that will only iterate over the present ones. v2: make sure arch without GENERIC_HARDIRQS work too Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit 7ef7c433df5a4e9ae23814757ccd28a6ab16f3fc Author: Yinghai Lu Date: Tue Aug 19 20:50:10 2008 -0700 irq: add irq_desc_without_new add an irq_desc accessor that will not allocate any sparse entry but returns failure if there's no entry present. Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit fb6dc57946f9ebfeac546dd0698d9f065c191668 Author: Yinghai Lu Date: Tue Aug 19 20:50:09 2008 -0700 x86: move kstat_irqs from kstat to irq_desc based on Eric's patch ... together mold it with dyn_array for irq_desc, will allcate kstat_irqs for nr_irq_desc alltogether if needed. -- at that point nr_cpus is known already. v2: make sure system without generic_hardirqs works they don't have irq_desc v3: fix merging v4: [mingo@elte.hu] fix typo [ mingo@elte.hu ] irq: build fix fix: arch/x86/xen/spinlock.c: In function 'xen_spin_lock_slow': arch/x86/xen/spinlock.c:90: error: 'struct kernel_stat' has no member named 'irqs' Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit 0f8348bdcf136243f3201ec5d6e2340fa8625fdc Author: Yinghai Lu Date: Tue Aug 19 20:50:08 2008 -0700 x86: put timer_rand_state pointer into irq_desc irq_timer_state[] is a NR_IRQS sized array that is a side-by array to the real irq_desc[] array. Integrate that field into the (now dynamic) irq_desc dynamic array and save some RAM. v2: keep the old way to support arch not support irq_desc Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit e36c523077935d74b34308a0815c81e025c28fd3 Author: Yinghai Lu Date: Tue Aug 19 20:50:07 2008 -0700 x86: put irq_2_pin pointer into irq_cfg preallocate 32 irq_2_pin entries, and use get_one_free_irq_2_pin() to get one more and link to irq_cfg if needed. so don't waste one where no irq is enabled. Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit 276fa72ceff13e05e29633d3b01669fe4b8a2e38 Author: Yinghai Lu Date: Tue Aug 19 20:50:06 2008 -0700 x86: add irq_cfg in io_apic_64.c preallocate size is 32, and if it is not enough, irq_cfg will more via alloc_bootmem() or kzalloc(). (depending on how early we are in system setup) v2: fix typo about size of init_one_irq_cfg ... should use sizeof(struct irq_cfg) v3: according to Eric, change get_irq_cfg() to irq_cfg() v4: squash add irq_cfg_alloc in Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit ff2973bf146acd26e6e9b877423fb9187044829f Author: Ingo Molnar Date: Tue Aug 19 20:50:29 2008 -0700 irq: sparse irqs, fix IRQ auto-probe crash fix: [ 10.631533] calling yenta_socket_init+0x0/0x20 [ 10.631533] Yenta: CardBus bridge found at 0000:15:00.0 [17aa:2012] [ 10.631533] Yenta: Using INTVAL to route CSC interrupts to PCI [ 10.631533] Yenta: Routing CardBus interrupts to PCI [ 10.631533] Yenta TI: socket 0000:15:00.0, mfunc 0x01d01002, devctl 0x64 [ 10.731599] BUG: unable to handle kernel NULL pointer dereference at 00000040 [ 10.731838] IP: [] _spin_lock_irq+0xf/0x20 [ 10.732221] *pde = 00000000 [ 10.732741] Oops: 0002 [#1] SMP [ 10.733453] [ 10.734253] Pid: 1, comm: swapper Tainted: G W (2.6.27-rc3-tip-00173-gd7eaa4f-dirty #1) [ 10.735188] EIP: 0060:[] EFLAGS: 00010002 CPU: 0 [ 10.735523] EIP is at _spin_lock_irq+0xf/0x20 [ 10.735523] EAX: 00000040 EBX: 00000000 ECX: f6e04c90 EDX: 00000100 [ 10.735523] ESI: 000000df EDI: f6e04c90 EBP: f7867df0 ESP: f7867df0 [ 10.735523] DS: 007b ES: 007b FS: 00d8 GS: 0000 SS: 0068 [ 10.735523] Process swapper (pid: 1, ti=f7867000 task=f7870000 task.ti=f7867000) [ 10.735523] Stack: f7867e04 c0155fbd 00000000 00000000 f6e04c90 f7867e5c c0c6e319 c0f6a074 [ 10.735523] f6e04c90 000017aa 00002012 c112b648 f791f240 c112b5e0 f7867e44 c010440b [ 10.735523] f791f240 f791f29c c112b8ec f791f240 00000000 f7867e5c c048f893 03c0b648 [ 10.735523] Call Trace: [ 10.735523] [] ? probe_irq_on+0x3d/0x140 [ 10.735523] [] ? yenta_probe+0x529/0x640 [ 10.735523] [] ? mcount_call+0x5/0xa [ 10.735523] [] ? pci_match_device+0xa3/0xb0 [ 10.735523] [] ? pci_device_probe+0x5e/0x80 [ 10.735523] [] ? driver_probe_device+0x83/0x180 [ 10.735523] [] ? __driver_attach+0x74/0x80 [ 10.735523] [] ? bus_for_each_dev+0x49/0x70 [ 10.735523] [] ? driver_attach+0x1e/0x20 [ 10.735523] [] ? __driver_attach+0x0/0x80 [ 10.735523] [] ? bus_add_driver+0x1a3/0x220 [ 10.735523] [] ? pci_device_remove+0x0/0x40 [ 10.735523] [] ? driver_register+0x54/0x130 [ 10.735523] [] ? __pci_register_driver+0x4f/0x90 [ 10.735523] [] ? yenta_socket_init+0x19/0x20 [ 10.735523] [] ? do_one_initcall+0x35/0x160 [ 10.735523] [] ? yenta_socket_init+0x0/0x20 [ 10.735523] [] ? __queue_work+0x36/0x50 [ 10.735523] [] ? queue_work_on+0x3d/0x50 [ 10.735523] [] ? kernel_init+0x148/0x210 [ 10.735523] [] ? kernel_init+0x0/0x210 [ 10.735523] [] ? kernel_thread_helper+0x7/0x10 [ 10.735523] ======================= [ 10.735523] Code: 10 38 f2 74 06 f3 90 8a 10 eb f6 5d 89 c8 c3 8d b6 00 00 00 00 8d bc 27 00 00 00 00 55 89 e5 e8 a4 e8 46 ff fa ba 00 01 00 00 90 <66> 0f c1 10 38 f2 74 06 f3 90 8a 10 eb f6 5d c3 90 55 89 e5 53 as auto-probing wants to iterate over existing irqs. Signed-off-by: Ingo Molnar commit f2f61d198649e25e4ddce33f716729eae1aab02b Author: Yinghai Lu Date: Tue Aug 19 20:50:05 2008 -0700 generic: sparse irqs: use irq_desc() together with dyn_array, instead of irq_desc[] add CONFIG_HAVE_SPARSE_IRQ to for use condensed array. Get rid of irq_desc[] array assumptions. Preallocate 32 irq_desc, and irq_desc() will try to get more. ( No change in functionality is expected anywhere, except the odd build failure where we missed a code site or where a crossing commit itroduces new irq_desc[] usage. ) v2: according to Eric, change get_irq_desc() to irq_desc() Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit f308510fd4ecb9fbbb43487b3a133aee108ae7b7 Author: Yinghai Lu Date: Tue Aug 19 20:50:04 2008 -0700 x86: remove nr_irq_vectors remove unused defines derived from the (now obsolete) NR_IRQS define. Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit ae81934a84fdeaa3f4758ee26d3d3170fc58b9de Author: Yinghai Lu Date: Tue Aug 19 20:50:03 2008 -0700 x86, irq: get nr_irqs from madt Until now, NR_IRQS was derived from black magic defines that had to be "large enough" to both accomodate NR_CPUS and MAX_NR_IO_APICs. This resulted in a way too large irq_desc[] array on most x86 systems. Especially with larger CPU masks, the size of irq_desc can spiral out of control quickly. So be smarter about it and use precise allocation instead: determine the default maximum possible IRQ number from the ACPI MADT. Use a minimum limit of at least 32 IRQs for broken BIOSes. Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit ec3f0cd69f3e0169e2ae22258e6d258e2d59df53 Author: Ingo Molnar Date: Tue Aug 19 20:50:31 2008 -0700 irq: sparse irqs, fix #3 fix non-APIC UP build: arch/x86/kernel/built-in.o: In function `setup_arch': : undefined reference to `pin_map_size' arch/x86/kernel/built-in.o: In function `setup_arch': : undefined reference to `first_free_entry' Signed-off-by: Ingo Molnar commit 8d4686b301bde2861b06bc4e397bb8bd694395f0 Author: Yinghai Lu Date: Tue Aug 19 20:50:02 2008 -0700 x86: use dyn_array in io_apic_xx.c Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit f90949170e5729341f07cd726d2a9d26f2b66f06 Author: Yinghai Lu Date: Tue Aug 19 20:50:01 2008 -0700 irq: make irqs in kernel stat use per_cpu_dyn_array Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit 414ec26ea1ccebf768193c98fad137b478dc740d Author: Ingo Molnar Date: Tue Aug 19 20:50:30 2008 -0700 irq: sparse irqs, export nr_irqs fix: Building modules, stage 2. MODPOST 458 modules ERROR: "nr_irqs" [drivers/serial/8250.ko] undefined! Signed-off-by: Ingo Molnar commit 78c82c3dc57f423314a18c2fa23d76e14d753c5e Author: Yinghai Lu Date: Tue Aug 19 20:50:00 2008 -0700 irq: make irq_desc to use dyn_array Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit 7dd5896723d16154f6b938f824711c375a7c1364 Author: Yinghai Lu Date: Tue Aug 19 20:49:59 2008 -0700 irq: make irq2_iommu to use dyn_array Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit 7d95b2f1145e3b55ac0635681a5a23ce0954c359 Author: Yinghai Lu Date: Tue Aug 19 20:49:58 2008 -0700 irqs: make irq_timer_state to use dyn_array Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit b2e5f326bb57ea744763af4be2b14aa1727d3209 Author: Yinghai Lu Date: Tue Aug 19 20:49:57 2008 -0700 drivers/xen: use nr_irqs Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit eb2befe03968fca653cce9e0bff3d07213544ddd Author: Yinghai Lu Date: Tue Aug 19 20:49:56 2008 -0700 fs/proc: use nr_irqs Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit 06d4e4888f6b8a7ce94701454aa46a24cc71cf34 Author: Yinghai Lu Date: Tue Aug 19 20:49:55 2008 -0700 drivers/serial: use nr_irqs Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit 400163a42600b52bf76a1f08a4e15235f82c9778 Author: Yinghai Lu Date: Tue Aug 19 20:49:54 2008 -0700 drivers/scsi: use nr_irqs Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit 437dff21e77adb3e8f83a01228bbf36519075fa5 Author: Yinghai Lu Date: Tue Aug 19 20:49:53 2008 -0700 drivers/rtc: use nr_irqs Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit 32d730e4f4e3157f4a57dd4de9314f1476159637 Author: Yinghai Lu Date: Tue Aug 19 20:49:52 2008 -0700 drivers/pcmcia: use nr_irqs Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit 09baa17ff8076403f0217fad9b7af0d01e9756b4 Author: Yinghai Lu Date: Tue Aug 19 20:49:51 2008 -0700 drivers/pci/ intr remapping: use nr_irqs Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit 11eb18338f74b9ca69f6669a695cec34175fcef8 Author: Yinghai Lu Date: Tue Aug 19 20:49:50 2008 -0700 drivers/net: use nr_irqs Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit efe5f1f61af57417a724bb3e09c637506c1931bb Author: Yinghai Lu Date: Tue Aug 19 20:49:49 2008 -0700 drivers/char: use nr_irqs convert them to nr_irqs. Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit fde2c75d812a92babd65076cedadfed7640594c0 Author: Yinghai Lu Date: Tue Aug 19 20:49:48 2008 -0700 x86: use nr_irqs also add first_free_entry and pin_map_size, which were NR_IRQS derived constants. Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit 9e89c54256b4eac96587eaa238063294881eb585 Author: Yinghai Lu Date: Tue Aug 19 20:49:47 2008 -0700 irq: introduce nr_irqs at this point nr_irqs is equal NR_IRQS convert a few easy users from NR_IRQS to dynamic nr_irqs. v2: according to Eric, we need to take care of arch without generic_hardirqs Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit f4e4080ab9687ab1e9405aad1ae9673c62310aa2 Author: Yinghai Lu Date: Tue Aug 19 20:49:46 2008 -0700 x86: enable dyn_array support Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit dac5f107f2370456b7b71dff71aa64e0ad5fc5fe Author: Yinghai Lu Date: Tue Aug 19 20:49:45 2008 -0700 x86: alloc dyn_array all together so could spare some memory with small alignment in bootmem also tighten the alignment checking, and make print out less debug info. Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit 28c00bc1528663da0a1d4b3534093764f8171acd Author: Yinghai Lu Date: Tue Aug 19 20:49:44 2008 -0700 add per_cpu_dyn_array support allow dyn-array in per_cpu area, allocated dynamically. usage: | /* in .h */ | struct kernel_stat { | struct cpu_usage_stat cpustat; | unsigned int *irqs; | }; | | /* in .c */ | DEFINE_PER_CPU(struct kernel_stat, kstat); | | DEFINE_PER_CPU_DYN_ARRAY_ADDR(per_cpu__kstat_irqs, per_cpu__kstat.irqs, sizeof(unsigned int), nr_irqs, sizeof(unsigned long), NULL); after setup_percpu()/per_cpu_alloc_dyn_array(), the dyn_array in per_cpu area is ready to use. Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit 565a0e86d6ba9a470dd4a3a16e4c10d08d17d9bb Author: Yinghai Lu Date: Tue Aug 19 20:49:43 2008 -0700 generic: add dyn_array support Allow crazy big arrays via bootmem at init stage. Architectures use CONFIG_HAVE_DYN_ARRAY to enable it. usage: | static struct irq_desc irq_desc_init __initdata = { | .status = IRQ_DISABLED, | .chip = &no_irq_chip, | .handle_irq = handle_bad_irq, | .depth = 1, | .lock = __SPIN_LOCK_UNLOCKED(irq_desc->lock), | #ifdef CONFIG_SMP | .affinity = CPU_MASK_ALL | #endif | }; | | static void __init init_work(void *data) | { | struct dyn_array *da = data; | struct irq_desc *desc; | int i; | | desc = *da->name; | | for (i = 0; i < *da->nr; i++) | memcpy(&desc[i], &irq_desc_init, sizeof(struct irq_desc)); | } | | struct irq_desc *irq_desc; | DEFINE_DYN_ARRAY(irq_desc, sizeof(struct irq_desc), nr_irqs, PAGE_SIZE, init_work); after pre_alloc_dyn_array() after setup_arch(), the array is ready to be used. Via this facility we can replace irq_desc[NR_IRQS] array with dyn_array irq_desc[nr_irqs]. v2: remove _nopanic in pre_alloc_dyn_array() Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit a7b95935b320759707b31c3ee274c5b997f56fb6 Author: Yinghai Lu Date: Tue Aug 19 20:49:42 2008 -0700 x86: remove irq_vectors_limits there's no user left. Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit 6d131316de21d45732a69ca15118111f3301dfb8 Author: Yinghai Lu Date: Tue Aug 19 20:49:41 2008 -0700 x86: add after_bootmem flag for 32bit to prepare to use dyn_array support etc. Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit d1c115207ad93ecf1140c38c3cef249352433c28 Author: Alan Cox Date: Tue Aug 19 20:49:40 2008 -0700 serial, 8250: remove NR_IRQ usage Works on my test box with a quick test. Signed-off-by: Alan Cox Signed-off-by: Ingo Molnar commit 6d1e45f2c785f87b9dd64a7d3333ac7d6aaf530e Author: Roel Kluin Date: Wed Aug 20 10:31:38 2008 +0200 ALSA: aoa - Remove duplicate assignment of SNDRV_PCM_FMTBIT_S{16,24}_BE bits Signed-off-by: Roel Kluin Signed-off-by: Takashi Iwai commit ce67a8ea83e43d8f422cdf8a029353ad45e9ccc5 Author: Krzysztof Helt Date: Tue Aug 19 21:51:49 2008 +0200 ALSA: opl3sa2: replace nd_opl3sa2_info_xxx() with snd_wss_info_xxx() Replace snd_opl3sa2_info_xxx() with snd_wss_info_xxx(). Drop check of card->private_data which cannot be NULL if card is not NULL (spotted by Rene Herman). Signed-off-by: Krzysztof Helt Reviewed-by: Rene Herman Signed-off-by: Takashi Iwai commit 4517f5cf2d09cb3a46cad06bee09018a45557c81 Author: Andreas Mohr Date: Wed Aug 20 10:04:56 2008 +0200 ALSA: als4000 - Code clean up - use specs-derived register name enums instead of open-coded numeric values, for better understanding of things - fix naming confusion ("gcr" was _NOT_ the GCR register stuff, but instead the io _base_ which has multiplexed _access_ to GCR config space, at _sub_ registers 0x08 and 0x0c) - add FIXME comments about a race condition and MPU401 features Signed-off-by: Andreas Mohr Signed-off-by: Takashi Iwai commit 7713fef06517d216f96ee7c8ad750e72bc08d38f Author: Stephen Rothwell Date: Tue Aug 19 18:19:25 2008 +1000 powerpc: Remove include of linux/of_device.h from asm/of_device.h Now that we have removed all inclusions of asm/of_device.h, this compatability include can be removed. Signed-off-by: Stephen Rothwell Signed-off-by: Paul Mackerras commit f6f11018dc7ea62482f36846e9f6eb0f27df7c3c Author: Stephen Rothwell Date: Mon Aug 11 17:04:32 2008 +1000 powerpc/drivers: Use linux/of_device.h instead of asm/of_device.h Signed-off-by: Stephen Rothwell Acked-by: Takashi Iwai Signed-off-by: Paul Mackerras commit 738e686055332a11884081ea85514514cb12fa20 Author: Stephen Rothwell Date: Tue Aug 19 11:45:55 2008 +1000 hotplug/rpaphp: Remove unused error path code Commit f46753c5e354b857b20ab8e0fe7b2579831dc369 ("PCI: introduce pci_slot") removed the need for this error path. Eliminate this warning: drivers/pci/hotplug/rpaphp_slot.c: In function 'rpaphp_register_slot': drivers/pci/hotplug/rpaphp_slot.c:151: warning: label 'sysfs_fail' defined but not used Signed-off-by: Stephen Rothwell Signed-off-by: Paul Mackerras commit b950bdd0fc247d0ab4aea88d46e8cced3eac949e Author: Benjamin Herrenschmidt Date: Mon Aug 18 14:23:51 2008 +1000 powerpc: Expose PMCs & cache topology in sysfs on 32-bit The file arch/powerpc/kernel/sysfs.c is currently only compiled for 64-bit kernels. It contain code to register CPU sysdevs in sysfs and add various properties such as cache topology and raw access by root to performance monitor counters (PMCs). A lot of that can be re-used as is on 32-bits. This makes the file be built for both, with appropriate ifdef'ing for the few bits that are really 64-bit specific, and adds some support for the raw PMCs for 75x and 74xx processors. Signed-off-by: Benjamin Herrenschmidt Signed-off-by: Paul Mackerras commit 41eba0ad0033967eda346dd833194e96fdf5f405 Author: Benjamin Herrenschmidt Date: Mon Aug 18 14:23:48 2008 +1000 powerpc: Turn get/set_hard_smp_proccessor_id into inlines They don't need to be macros, and having them as inline functions avoids warnings about unused variables on some configurations when the argument isn't evaluated. Signed-off-by: Benjamin Herrenschmidt Signed-off-by: Paul Mackerras commit f3d3d307e6f577de3b384ef64ffb03c8b5676748 Author: Nathan Lynch Date: Wed Aug 13 07:34:57 2008 +1000 powerpc: Remove redundant sysfs_remove_file calls for cache info When removing a directory, the sysfs core takes care of removing files in the directory (see sysfs_remove_dir()). So when we are about to delete a kobject (and thus cause its sysfs directory to be removed), we don't have to explicitly remove the files attached to it, although it's harmless to do so. Signed-off-by: Nathan Lynch Signed-off-by: Paul Mackerras commit 8f6ba49207199cab60a4bdf43507666b93d12e18 Author: Adrian Bunk Date: Sat Aug 9 02:34:53 2008 +1000 powerpc: Use bcd2bin/bin2bcd This changes powerpc to use the new bcd2bin/bin2bcd functions instead of the obsolete BCD_TO_BIN/BIN_TO_BCD macros. Signed-off-by: Adrian Bunk Signed-off-by: Paul Mackerras commit ed95d7450dcbfeb45ffc9d39b1747aee82b49a51 Author: David Gibson Date: Thu Aug 7 12:24:17 2008 +1000 powerpc: Update in-kernel dtc and libfdt to version 1.2.0 Some time ago, a copies of the upstream dtc and libfdt sources were included in the kernel tree to avoid having these as external dependencies for building the kernel. Since then development on the upstream dtc and libfdt has continued. This updates the in-kernel versions to match the recently released upstream dtc version 1.2.0. This includes a number of bugfixes, many cleanups and a few new features. Signed-off-by: David Gibson Signed-off-by: Paul Mackerras commit 0ec27c049d80535f77901654a310b090106b046c Author: Stephen Rothwell Date: Thu Aug 7 10:30:40 2008 +1000 powerpc: Remove include of linux/of_platform.h from asm/of_platform.h Now that we have removed all inclusions of asm/of_platform.h, this compatibility include can be removed. Signed-off-by: Stephen Rothwell Signed-off-by: Paul Mackerras commit 25235f712b680d00756a73ee64289137989fc6fd Author: Michael Ellerman Date: Wed Aug 6 09:10:03 2008 +1000 powerpc: Convert the MPIC MSI code to use msi_bitmap This affects the U3 MSI code as well as the PASEMI MSI code. We keep some of the MPIC routines as helpers, and also the U3 best-guess reservation logic. The rest is replaced by the generic code. And a few printk format changes due to hwirq type change. Signed-off-by: Michael Ellerman Signed-off-by: Paul Mackerras commit 7e7ab3677502a0f798f38bfa1a7d53dd22faa0bc Author: Michael Ellerman Date: Wed Aug 6 09:10:02 2008 +1000 powerpc: Convert the FSL MSI code to use msi_bitmap This is 90% straight forward, although we have to change a few printk format strings as well because of the change in type of hwirq. Signed-off-by: Michael Ellerman Signed-off-by: Paul Mackerras commit 7e302869e0c5261aba779e059cddcd2fbf7aedbe Author: Michael Ellerman Date: Wed Aug 6 09:10:01 2008 +1000 powerpc: Split-out common MSI bitmap logic into msi_bitmap.c There are now two almost identical implementations of an MSI bitmap allocator, one in mpic_msi.c and the other in fsl_msi.c. Merge them together and put the result in msi_bitmap.c. Some of the MPIC bits will remain to provide a nicer interface for the MPIC users. In the process we fix two buglets. The first is that the allocation routines, now msi_bitmap_alloc_hwirqs(), returned an unsigned result, even though they use -1 to indicate allocation failure. Although all the callers were checking correctly, it is much better for the routine to just return an int. At least until someone wants > ~2 billion MSIs. The second buglet is that the device tree reservation logic only allowed power-of-two reservations. AFAICT that didn't effect any existing code but it's nicer if we can reserve arbitrary irqs from MSI use. We also add some selftests, which exposed the two buglets and now test for them, as well as some basic sanity tests. The tests are only built when CONFIG_DEBUG_KERNEL=y. Signed-off-by: Michael Ellerman Signed-off-by: Paul Mackerras commit 611cd90c91494d1ff9bd4bc349fe38789828733e Author: Michael Ellerman Date: Wed Aug 6 09:10:00 2008 +1000 powerpc: fsl_msi doesn't need it's own of_node The FSL MSI code keeps a pointer to the of_node from the device it represents. However it also has an irq_host, which contains a pointer to the of_node, so use that one instead. Signed-off-by: Michael Ellerman Signed-off-by: Paul Mackerras commit dcfcfe756762682d084f40b96c78507f0d27d379 Author: Tony Breeds Date: Thu Jul 31 16:54:20 2008 +1000 powerpc: Guard print_device_node_tree() with #if 0 Currently print_device_node_tree() isn't called but it can be useful for debugging. Leave the function there but hide it behind '#if 0' to save it being rewritten. If you want to call it you're already editing this file anyway. ;P Signed-off-by: Tony Breeds Signed-off-by: Paul Mackerras commit fedcf4c73e1b9c1c594cf12d946ea90b7a47cc08 Author: Tony Breeds Date: Thu Jul 31 13:51:43 2008 +1000 powerpc: Guard from_rtc_time() in platforms/powermac/time.c from_rtc_time() is only called when one of 3 CONFIG options are defined. Guard the declaration appropriately. Signed-off-by: Tony Breeds Signed-off-by: Paul Mackerras commit e16a9c0990a18ee2f2874363392fdfedcf9ded58 Author: Tony Breeds Date: Thu Jul 31 13:51:42 2008 +1000 powerpc: Guard htab_dt_scan_hugepage_blocks appropriately htab_dt_scan_hugepage_blocks is only used when CONFIG_HUGETLB_PAGE is defined, so guard the declaration likewise. Signed-off-by: Tony Breeds Signed-off-by: Paul Mackerras commit 5df72bf3f7345a84f5ef274bf72a4546caf3ad02 Author: Harvey Harrison Date: Thu Jul 31 05:29:03 2008 +1000 powerpc: Replace __FUNCTION__ with __func__ __FUNCTION__ is gcc-specific, use __func__ [akpm@linux-foundation.org: coding-style fixes] Signed-off-by: Harvey Harrison Cc: Benjamin Herrenschmidt Signed-off-by: Andrew Morton Signed-off-by: Paul Mackerras commit 542ad5d4ccbaf49f581bacff1af206077189bc30 Author: Harvey Harrison Date: Thu Jul 31 05:29:03 2008 +1000 powerpc: Use the common ascii hex helpers [akpm@linux-foundation.org: exclude prom_init.c] Signed-off-by: Harvey Harrison Signed-off-by: Andrew Morton Signed-off-by: Paul Mackerras commit 01f3880dd8a7fa78c419da2db740cba511ca7798 Author: Michael Ellerman Date: Wed Jul 16 14:21:34 2008 +1000 powerpc: Streamline ret_from_except_lite for non-iSeries platforms There is a small passage of code in ret_from_except_lite which is only required on iSeries. For a multi-platform kernel on non-iSeries machines this means we end up executing ~15 nops in ret_from_except_lite. It would be nicer if non-iSeries could skip the code entirely, and on iSeries we can jump out of line to execute the code. I have no performance numbers to justify this, other than the assertion that executing 15 nops takes longer than executing 0. Signed-off-by: Michael Ellerman Signed-off-by: Paul Mackerras commit e9cb165aed38ae155d120502b26fcd10c1180e6e Author: Bjorn Helgaas Date: Tue Aug 19 16:53:52 2008 -0600 PNP: remove old CONFIG_PNP_DEBUG option CONFIG_PNP_DEBUG is no longer used to turn on dev_dbg() in PNP, since we have pnp_dbg() which can be enabled at boot-time, so this patch removes the config option. Note that pnp_dock_event() checks "#ifdef DEBUG". But there's never been a clear path for enabling that via configgery. It happened that CONFIG_PNP_DEBUG enabled it after 1bd17e63a068db6, but that was accidental and only in 2.6.26. Signed-off-by: Bjorn Helgaas Signed-off-by: Andi Kleen commit 82206f4d59f486c2a1f9a4554c02bf2580a721f9 Author: Bjorn Helgaas Date: Tue Aug 19 16:53:47 2008 -0600 PNP: convert to using pnp_dbg() pnp_dbg() is equivalent to dev_dbg() except that we can turn it on at boot-time with the "pnp.debug" kernel parameter, so we don't have to build a new kernel image. Signed-off-by: Bjorn Helgaas Signed-off-by: Andi Kleen commit cc83a834e1b246e01583fb7ca736364136a09f8a Author: Bjorn Helgaas Date: Tue Aug 19 16:53:41 2008 -0600 PNP: add CONFIG_PNP_DEBUG_MESSAGES and pnp_dbg() This adds the core function pnp_dbg() and a new config option to enable it. The PNP core debugging messages can be enabled at boot-time with the "pnp.debug" kernel parameter. Signed-off-by: Bjorn Helgaas Signed-off-by: Andi Kleen commit 67f8bb7bcbf42b0ff46adab158296c1e3e10aafb Author: Bjorn Helgaas Date: Tue Aug 19 16:53:36 2008 -0600 PNP: remove some uses of DEBUG ifdef Use scnprintf() to build up a buffer of PNP IDs to print. This makes the printk atomic and helps get rid of an #ifdef. Also remove an "#ifdef DEBUG" from some debug functions. The functions only produce debug output, so it's OK to run the function and just have the output be dropped at the end. Signed-off-by: Bjorn Helgaas Signed-off-by: Andi Kleen commit 7b5991de7494f08e9163eea1b02018971f911b26 Author: Bjorn Helgaas Date: Tue Aug 19 16:53:31 2008 -0600 PNP: use new vsprintf symbolic function pointer format Use the '%pF' format to get rid of an "#ifdef DEBUG". Signed-off-by: Bjorn Helgaas Signed-off-by: Andi Kleen commit 261f7be5dfc68dd83d643ad9558cafd735d9711f Author: Bjorn Helgaas Date: Tue Aug 19 16:53:26 2008 -0600 PNP: convert the last few pnp_info() uses to printk() There are only a few remaining uses of pnp_info(), so I just converted them to printk and removed the pnp_err(), pnp_info(), pnp_warn(), and pnp_dbg() wrappers. I also removed a couple debug messages that don't seem useful any more ("driver registered", "driver unregistered", "driver attached"). Signed-off-by: Bjorn Helgaas Signed-off-by: Andi Kleen commit 467bb839b837ed04c816486a9ad4d2b9f02ad5cd Author: Bjorn Helgaas Date: Tue Aug 19 16:53:21 2008 -0600 PNPACPI: use dev_printk when possible Use dev_printk() when possible for more informative error messages. Signed-off-by: Bjorn Helgaas Signed-off-by: Andi Kleen commit 0606b0b467aa32fce52b1d69691fe2b944838cf7 Author: Bjorn Helgaas Date: Tue Aug 19 16:53:16 2008 -0600 PNP: fix debug formatting (cosmetic) This patch just fixes indentation of a couple debug messages. Signed-off-by: Bjorn Helgaas Signed-off-by: Andi Kleen commit b58f0a6b7d7a0148d9cf51ce7fb4a98961657c47 Author: Mark Fasheh Date: Tue Aug 19 10:54:29 2008 -0700 ocfs2: fix printk format warnings This patch fixes the following build warnings: fs/ocfs2/xattr.c: In function 'ocfs2_half_xattr_bucket': fs/ocfs2/xattr.c:3282: warning: format '%d' expects type 'int', but argument 7 has type 'long int' fs/ocfs2/xattr.c:3282: warning: format '%d' expects type 'int', but argument 8 has type 'long int' fs/ocfs2/xattr.c:3282: warning: format '%d' expects type 'int', but argument 7 has type 'long int' fs/ocfs2/xattr.c:3282: warning: format '%d' expects type 'int', but argument 8 has type 'long int' fs/ocfs2/xattr.c:3282: warning: format '%d' expects type 'int', but argument 7 has type 'long int' fs/ocfs2/xattr.c:3282: warning: format '%d' expects type 'int', but argument 8 has type 'long int' fs/ocfs2/xattr.c: In function 'ocfs2_xattr_set_entry_in_bucket': fs/ocfs2/xattr.c:4092: warning: format '%d' expects type 'int', but argument 6 has type 'size_t' fs/ocfs2/xattr.c:4092: warning: format '%d' expects type 'int', but argument 6 has type 'size_t' fs/ocfs2/xattr.c:4092: warning: format '%d' expects type 'int', but argument 6 has type 'size_t' Signed-off-by: Mark Fasheh commit 3e07b1a9306728f6fb12b96b919598cecb35b62b Author: Tiger Yang Date: Mon Aug 18 17:11:46 2008 +0800 [PATCH 16/16] ocfs2: Add incompatible flag for extended attribute This patch adds the s_incompat flag for extended attribute support. This helps us ensure that older versions of Ocfs2 or ocfs2-tools will not be able to mount a volume with xattr support. Signed-off-by: Tiger Yang Signed-off-by: Mark Fasheh commit 2884832b8bef54042cdd96075a46cd11b04b93ed Author: Tao Ma Date: Mon Aug 18 17:38:54 2008 +0800 [PATCH 15/16] ocfs2: Delete all xattr buckets during inode removal In inode removal, we need to iterate all the buckets, remove any externally-stored EA values and delete the xattr buckets. Signed-off-by: Tao Ma Signed-off-by: Mark Fasheh commit 524c679411cfc31a80aafe70b1e075f38e01201c Author: Tao Ma Date: Mon Aug 18 17:38:53 2008 +0800 [PATCH 14/16] ocfs2: Enable xattr set in index btree Where the previous patches added the ability of list/get xattr in buckets for ocfs2, this patch enables ocfs2 to store large numbers of EAs. The original design doc is written by Mark Fasheh, and it can be found in http://oss.oracle.com/osswiki/OCFS2/DesignDocs/IndexedEATrees. I only had to make small modifications to it. First, because the bucket size is 4K, a new field named xh_free_start is added in ocfs2_xattr_header to indicate the next valid name/value offset in a bucket. It is used when we store new EA name/value. With this field, we can find the place more quickly and what's more, we don't need to sort the name/value every time to let the last entry indicate the next unused space. This makes the insert operation more efficient for blocksizes smaller than 4k. Because of the new xh_free_start, another field named as xh_name_value_len is also added in ocfs2_xattr_header. It records the total length of all the name/values in the bucket. We need this so that we can check it and defragment the bucket if there is not enough contiguous free space. An xattr insertion looks like this: 1. xattr_index_block_find: find the right bucket by the name_hash, say bucketA. 2. check whether there is enough space in bucketA. If yes, insert it directly and modify xh_free_start and xh_name_value_len accordingly. If not, check xh_name_value_len to see whether we can store this by defragment the bucket. If yes, defragment it and go on insertion. 3. If defragement doesn't work, check whether there is new empty bucket in the clusters within this extent record. If yes, init the new bucket and move all the buckets after bucketA one by one to the next bucket. Move half of the entries in bucketA to the next bucket and go on insertion. 4. If there is no new bucket, grow the extent tree. As for xattr deletion, we will delete an xattr bucket when all it's xattrs are removed and move all the buckets after it to the previous one. When all the xattr buckets in an extend record are freed, free this extend records from ocfs2_xattr_tree. Signed-off-by: Tao Ma Signed-off-by: Mark Fasheh commit c797db3113c2def213327e04e4a2e80b9630df57 Author: Tao Ma Date: Mon Aug 18 17:38:52 2008 +0800 [PATCH 13/16] ocfs2: Optionally limit extent size in ocfs2_insert_extent() In xattr bucket, we want to limit the maximum size of a btree leaf, otherwise we'll lose the benefits of hashing because we'll have to search large leaves. So add a new field in ocfs2_extent_tree which indicates the maximum leaf cluster size we want so that we can prevent ocfs2_insert_extent() from merging the leaf record even if it is contiguous with an adjacent record. Other btree types are not affected by this change. Signed-off-by: Tao Ma Signed-off-by: Mark Fasheh commit 2ff7536715d718497ff260e8b8b2bce149c2b1b3 Author: Tao Ma Date: Mon Aug 18 17:38:51 2008 +0800 [PATCH 12/16] ocfs2: Add xattr lookup code xattr btrees Add code to lookup a given extended attribute in the xattr btree. Lookup follows this general scheme: 1. Use ocfs2_xattr_get_rec to find the xattr extent record 2. Find the xattr bucket within the extent which may contain this xattr 3. Iterate the bucket to find the xattr. In ocfs2_xattr_block_get(), we need to recalcuate the block offset and name offset for the right position of name/value. Signed-off-by: Tao Ma Signed-off-by: Mark Fasheh commit bb355633ecac60c1feb4a9502beea158e2a63e90 Author: Tao Ma Date: Mon Aug 18 17:38:50 2008 +0800 [PATCH 11/16] ocfs2: Add xattr bucket iteration for large numbers of EAs Ocfs2 breaks up xattr index tree leaves into 4k regions, called buckets. Attributes are stored within a given bucket, depending on hash value. After a discussion with Mark, we decided that the per-bucket index (xe_entry[]) would only exist in the 1st block of a bucket. Likewise, name/value pairs will not straddle more than one block. This allows the majority of operations to work directly on the buffer heads in a leaf block. This patch adds code to iterate the buckets in an EA. A new abstration of ocfs2_xattr_bucket is added. It records the bhs in this bucket and ocfs2_xattr_header. This keeps the code neat, improving readibility. Signed-off-by: Tao Ma Signed-off-by: Mark Fasheh commit 5a10e527c61dfad694704164134f3cb6e1b342fd Author: Tao Ma Date: Mon Aug 18 17:38:49 2008 +0800 [PATCH 10/16] ocfs2: Add xattr index tree operations When necessary, an ocfs2_xattr_block will embed an ocfs2_extent_list to store large numbers of EAs. This patch adds a new type in ocfs2_extent_tree_type and adds the implementation so that we can re-use the b-tree code to handle the storage of many EAs. Signed-off-by: Tao Ma Signed-off-by: Mark Fasheh commit c1e373cab440880302d299f3afc445ce34b18e7d Author: David Howells Date: Tue Aug 19 16:18:29 2008 +0100 CRED: Take cred_exec_mutex in compat_do_execve() and fix error handling in do_execve() Take cred_exec_mutex in compat_do_execve(). This reflects what do_execve() does. The mutex protects credentials calculation against PTRACE_ATTACH needing to alter it mid-exec. Also fix the error handling in do_execve(). The mutex needs to be unlocked if an error occurs after it is taken, but before the install_exec_creds() released it. Signed-off-by: David Howells Signed-off-by: James Morris commit 5ce1ca3c1ba43a8c12a2d358eedd1af2ffb2390d Author: J. Bruce Fields Date: Tue Mar 18 19:00:19 2008 -0400 lockd: don't depend on lockd main loop to end grace End lockd's grace period using schedule_delayed_work() instead of a check on every pass through the main loop. After a later patch, we'll depend on lockd to end its grace period even if it's not currently handling requests; so it shouldn't depend on being woken up from the main loop to do so. Also, Nakano Hiroaki (who independently produced a similar patch) noticed that the current behavior is buggy in the face of jiffies wraparound: "lockd uses time_before() to determine whether the grace period has expired. This would seem to be enough to avoid timer wrap-around issues, but, unfortunately, that is not the case. The time_* family of comparison functions can be safely used to compare jiffies relatively close in time, but they stop working after approximately LONG_MAX/2 ticks. nfsd can suffer this problem because the time_before() comparison in lockd() is not performed until the first request comes in, which means that if there is no lockd traffic for more than LONG_MAX/2 ticks we are screwed. "The implication of this is that once time_before() starts misbehaving any attempt from a NFS client to execute fcntl() will be received with a NLM_LCK_DENIED_GRACE_PERIOD message for 25 days (assuming HZ=1000). In other words, the 50 seconds grace period could turn into a grace period of 50 days or more. "Note: This bug was analyzed independently by Oda-san and myself." Signed-off-by: J. Bruce Fields Cc: Nakano Hiroaki Cc: Itsuro Oda commit 135b296d451df20956aff1ad44122aef7f38ebc6 Author: J. Bruce Fields Date: Thu Jan 24 11:11:34 2008 -0500 locks: allow lockd to process blocked locks during grace period The check here is currently harmless but unnecessary, since, as the comment notes, there aren't any blocked-lock callbacks to process during the grace period anyway. And eventually we want to allow multiple grace periods that come and go for different filesystems over the course of the lifetime of lockd, at which point this check is just going to get in the way. Signed-off-by: J. Bruce Fields commit 8ccff787f84329c200fd094df42fcaae846cccd8 Author: Tiger Yang Date: Mon Aug 18 17:11:00 2008 +0800 [PATCH 09/16] ocfs2: Add extended attribute support This patch implements storing extended attributes both in inode or a single external block. We only store EA's in-inode when blocksize > 512 or that inode block has free space for it. When an EA's value is larger than 80 bytes, we will store the value via b-tree outside inode or block. Signed-off-by: Tiger Yang Signed-off-by: Mark Fasheh commit 6ec9673e9670264f66f507c6f1a8041c5ee927e1 Author: Tiger Yang Date: Mon Aug 18 17:08:55 2008 +0800 [PATCH 08/16] ocfs2: reserve inline space for extended attribute Add the structures and helper functions we want for handling inline extended attributes. We also update the inline-data handlers so that they properly function in the event that we have both inline data and inline attributes sharing an inode block. Signed-off-by: Tiger Yang Signed-off-by: Mark Fasheh commit 62a8f4fd95609e961a40a580aa36376b2cf6241f Author: Tao Ma Date: Mon Aug 18 17:38:48 2008 +0800 [PATCH 07/16] ocfs2: Add extent tree operation for xattr value btrees Add some thin wrappers around ocfs2_insert_extent() for each of the 3 different btree types, ocfs2_inode_insert_extent(), ocfs2_xattr_value_insert_extent() and ocfs2_xattr_tree_insert_extent(). The last is for the xattr index btree, which will be used in a followup patch. All the old callers in file.c etc will call ocfs2_dinode_insert_extent(), while the other two handle the xattr issue. And the init of extent tree are handled by these functions. When storing xattr value which is too large, we will allocate some clusters for it and here ocfs2_extent_list and ocfs2_extent_rec will also be used. In order to re-use the b-tree operation code, a new parameter named "private" is added into ocfs2_extent_tree and it is used to indicate the root of ocfs2_exent_list. The reason is that we can't deduce the root from the buffer_head now. It may be in an inode, an ocfs2_xattr_block or even worse, in any place in an ocfs2_xattr_bucket. Signed-off-by: Tao Ma Signed-off-by: Mark Fasheh commit c869e043741349ac9fad5aa65a33624665ac97d0 Author: Eduard - Gabriel Munteanu Date: Tue Aug 19 20:43:24 2008 +0300 kmemtrace: Better alternative to "kmemtrace: fix printk format warnings". Fix the problem "kmemtrace: fix printk format warnings" attempted to fix, but resulted in marker-probe format mismatch warnings. Instead of carrying size_t into probes, we get rid of it by casting to unsigned long, just as we did with gfp_t. This way, we don't need to change marker format strings and we don't have to rely on other format specifiers like "%zu", making for consistent use of more generic data types (since there are no format specifiers for gfp_t, for example). Signed-off-by: Eduard - Gabriel Munteanu Signed-off-by: Pekka Enberg commit 3b93c33dcd0e9d8bb37f77c791f0b42b795b138b Author: Eduard - Gabriel Munteanu Date: Tue Aug 19 20:43:27 2008 +0300 kmemtrace: Fix typos in documentation. Corrected the ABI description and the kmemtrace usage guide. Thanks to Randy Dunlap for noticing these errors. Signed-off-by: Eduard - Gabriel Munteanu Signed-off-by: Pekka Enberg commit e63352fa06fb8c476e56e51323d80f2e7baee67f Author: Eduard - Gabriel Munteanu Date: Tue Aug 19 20:43:26 2008 +0300 kmemtrace: SLUB hooks. This adds hooks for the SLUB allocator, to allow tracing with kmemtrace. Signed-off-by: Eduard - Gabriel Munteanu Signed-off-by: Pekka Enberg commit 04be8567dab2a793f4ec8050c65af6845e6e3af3 Author: Eduard - Gabriel Munteanu Date: Tue Aug 19 20:43:25 2008 +0300 SLUB: Replace __builtin_return_address(0) with _RET_IP_. This patch replaces __builtin_return_address(0) with _RET_IP_, since a previous patch moved _RET_IP_ and _THIS_IP_ to include/linux/kernel.h and they're widely available now. This makes for shorter and easier to read code. [penberg@cs.helsinki.fi: remove _RET_IP_ casts to void pointer] Signed-off-by: Eduard - Gabriel Munteanu Signed-off-by: Pekka Enberg commit 0a6538cc7cf190ba7adc6ece0f36242419aa5db9 Author: Tao Ma Date: Mon Aug 18 17:38:47 2008 +0800 [PATCH 06/16] ocfs2: Add helper function in uptodate.c for removing xattr clusters The old uptodate only handles the issue of removing one buffer_head from ocfs2 inode's buffer cache. With xattr clusters, we may need to remove multiple buffer_head's at a time. Signed-off-by: Tao Ma Signed-off-by: Mark Fasheh commit e6c2a62bf293387417879134a37d418dc6bfde4f Author: Tao Ma Date: Mon Aug 18 17:38:46 2008 +0800 [PATCH 05/16] Add the basic xattr disk layout in ocfs2_fs.h Ocfs2 uses a very flexible structure for storing extended attributes on disk. Small amount of attributes are stored directly in the inode block - up to 256 bytes worth. If that fills up, attributes are also stored in an external block, linked to from the inode block. That block can in turn expand to a btree, capable of storing large numbers of attributes. Individual attribute values are stored inline if they're small enough (currently about 80 bytes, this can be changed though), and otherwise are expanded to a btree. The theoretical limit to the size of an individual attribute is about the same as an inode, though the kernel's upper bound on the size of an attributes data is far smaller. Signed-off-by: Tao Ma Signed-off-by: Mark Fasheh commit 382bf9e3e787a4bffe6863fc12bcc31714f0b322 Author: Tao Ma Date: Mon Aug 18 17:38:45 2008 +0800 [PATCH 04/16] ocfs2: Make high level btree extend code generic Factor out the non-inode specifics of ocfs2_do_extend_allocation() into a more generic function, ocfs2_do_cluster_allocation(). ocfs2_do_extend_allocation calls ocfs2_do_cluster_allocation() now, but the latter can be used for other btree types as well. Signed-off-by: Tao Ma Signed-off-by: Mark Fasheh commit fe44e432c94cee822d2d2698b5b4192c51ee8d73 Author: Xiantao Zhang Date: Tue Aug 19 20:48:03 2008 +0800 KVM: ia64: add a dummy irq ack notification Before enabling notify_acked_irq for ia64, leave the related APIs as nop-op first. Signed-off-by: Xiantao Zhang Signed-off-by: Avi Kivity commit ebcce7b13be837616a3f9d996f637cf3241e3948 Author: Ian Molton Date: Tue Aug 19 13:34:56 2008 +0100 [ARM] eseries: move UDC defs to machine files This patchset moves the UDC definitons for e7xx compatible eseries machines to a common location and moves the 'oddball' e800 definition to its machine file. Signed-off-by: Ian Molton commit 0ec3cf69304d2e35ad29da3aa9ab43c3dd97677c Author: Ian Molton Date: Tue Aug 19 13:01:28 2008 +0100 [ARM] eseries: move LCD defs into machine files This patch removes the seperate files used for the LCD definitions on e-series and places the definitions into the machine specific files. Signed-off-by: Ian Molton commit 7dc964148c2850e5df84fc17807ba48edb628c88 Author: Ian Molton Date: Tue Aug 19 12:14:21 2008 +0100 [ARM] eseries: Split machine definitions This patchset breaks out the e-series machine definitions into one-per-machine. Signed-off-by: Ian Molton commit b51a146e294d925f214a91996dce05edfc84f8f4 Author: Ingo Molnar Date: Tue Aug 19 13:40:47 2008 +0200 sched: extract walk_tg_tree(), fix fix: kernel/sched.c: In function '__rt_schedulable': kernel/sched.c:8771: error: implicit declaration of function 'walk_tg_tree' kernel/sched.c:8771: error: 'tg_nop' undeclared (first use in this function) kernel/sched.c:8771: error: (Each undeclared identifier is reported only once kernel/sched.c:8771: error: for each function it appears in.) Signed-off-by: Ingo Molnar commit 561fedb420678e5d60975a30c9939b583a72a841 Author: Ingo Molnar Date: Tue Aug 19 13:10:12 2008 +0200 sched: set rt-bandwidth period from 1 second to 10 seconds Set bandwidth control from 1 second periods to 10 second periods. This means that RT task can still monopolize the CPU up to 9.5 seconds uninterrupted. If there's a runaway RT task on the system, the desktop will be _very_ laggy, but it will still be debuggable. If someone needs even more CPU time for RT tasks, the sysctl can be turned off completely by setting it to -1. (but running RT tasks for such long time can have bad side-effects on other parts of the kernel so it should be done with extreme care) Signed-off-by: Ingo Molnar Signed-off-by: Peter Zijlstra commit 9a7e0b180da21885988d47558671cf580279f9d6 Author: Peter Zijlstra Date: Tue Aug 19 12:33:06 2008 +0200 sched: rt-bandwidth fixes The last patch allows sysctl_sched_rt_runtime to disable bandwidth accounting for the group scheduler - however it doesn't deal with sched_setscheduler(), which will keep tasks out of groups that have no assigned runtime. If we relax this, we get into the situation where RT tasks can get into a group when we disable bandwidth control, and then starve them by enabling it again. Rework the schedulability code to check for this condition and fail to turn on bandwidth control with -EBUSY when this situation is found. Signed-off-by: Peter Zijlstra Signed-off-by: Ingo Molnar commit eb755805f21bd5ded84026e167b7a90887ac42e5 Author: Peter Zijlstra Date: Tue Aug 19 12:33:05 2008 +0200 sched: extract walk_tg_tree() Extract walk_tg_tree() and make it a little more generic so we can use it in the schedulablity test. Signed-off-by: Peter Zijlstra Signed-off-by: Ingo Molnar commit 0b148fa04852859972abbf848177b92daeef138a Author: Peter Zijlstra Date: Tue Aug 19 12:33:04 2008 +0200 sched: rt-bandwidth group disable fixes More extensive disable of bandwidth control. It allows sysctl_sched_rt_runtime to disable full group bandwidth control. Signed-off-by: Peter Zijlstra Signed-off-by: Ingo Molnar commit 6f0d5c390e4206dcb3804a5072a048fdb7d2b428 Author: Peter Zijlstra Date: Tue Aug 19 12:33:03 2008 +0200 sched: rt-bandwidth accounting fix It fixes an accounting bug where we would continue accumulating runtime even though the bandwidth control is disabled. This would lead to very long throttle periods once bandwidth control gets turned on again. Signed-off-by: Peter Zijlstra Signed-off-by: Ingo Molnar commit af4491e51632d01fbc2b856ffa9ebcd4b38db68c Author: Peter Zijlstra Date: Tue Aug 19 12:33:02 2008 +0200 sched: rt-bandwidth for user grouping interface rt_runtime is a signed value Signed-off-by: Peter Zijlstra Signed-off-by: Ingo Molnar commit d17a004a1a17762a940138d657e0fc8a2cc9a983 Author: Takashi Iwai Date: Tue Aug 19 13:10:04 2008 +0200 ALSA: Update MAINTAINERS Added tiwai to MAINTAINERS (per request of akpm) Signed-off-by: Takashi Iwai commit 9f86371ca935d35191f2420194e50608a4f694e6 Author: Thomas Bogendoerfer Date: Tue Aug 19 11:54:14 2008 +0200 oss: remove driver for SGI HAL2 audio device With the restructering of the indy button handling the old OSS HAL2 driver got broken. Since there is a new ALSA driver for HAL2, the experimental OSS driver is obsolete and will be removed by this patch. Signed-off-by: Thomas Bogendoerfer Cc: Ralf Baechle Signed-off-by: Andrew Morton Signed-off-by: Takashi Iwai commit 5436f93b488c915ca4f834f00e27b3770b77f58f Author: Ilpo Järvinen Date: Tue Aug 19 11:45:58 2008 +0200 mpu401: reindent misindented spinlock Signed-off-by: Ilpo Järvinen Signed-off-by: Takashi Iwai commit 1404e403157eb8d96db4d51961e1cc592eda87ed Author: Andi Kleen Date: Tue Aug 19 03:13:38 2008 +0200 x86: fix oprofile + hibernation badness Vegard Nossum reported oprofile + hibernation problems: > Now some warnings: > > ------------[ cut here ]------------ > WARNING: at /uio/arkimedes/s29/vegardno/git-working/linux-2.6/kernel/smp.c:328 s > mp_call_function_mask+0x194/0x1a0() The usual problem: the suspend function when interrupts are already disabled calls smp_call_function which is not allowed with interrupt off. But at this point all the other CPUs should be already down anyways, so it should be enough to just drop that. This patch should fix that problem at least by fixing cpu hotplug& suspend support. [ mingo@elte.hu: fixed 5 coding style errors. ] Signed-off-by: Andi Kleen Tested-by: Vegard Nossum Signed-off-by: Ingo Molnar commit 97e1cfb08616987878f91a46cefdd7fc5fa3dba1 Author: Jan Kara Date: Mon Aug 18 13:44:48 2008 +0200 udf: Fix error paths in udf_new_inode() I case we failed to allocate memory for inode when creating it, we did not properly free block already allocated for this inode. Move memory allocation before the block allocation which fixes this issue (thanks for the idea go to Ingo Oeser ). Also remove a few superfluous initializations already done in udf_alloc_inode(). Reviewed-by: Ingo Oeser Signed-off-by: Jan Kara commit db0badc58e948b810c7a75cfcc48845e2949ee37 Author: Jan Kara Date: Mon Aug 18 13:40:18 2008 +0200 udf: Fix lock inversion between iprune_mutex and alloc_mutex (v2) A memory allocation inside alloc_mutex must not recurse back into the filesystem itself because that leads to lock inversion between iprune_mutex and alloc_mutex (and thus to deadlocks - see traces below). alloc_mutex is actually needed only to update allocation statistics in the superblock so we can drop it before we start allocating memory for the inode. tar D ffff81015b9c8c90 0 6614 6612 ffff8100d5a21a20 0000000000000086 0000000000000000 00000000ffff0000 ffff81015b9c8c90 ffff81015b8f0cd0 ffff81015b9c8ee0 0000000000000000 0000000000000003 0000000000000000 0000000000000000 0000000000000000 Call Trace: [] __mutex_lock_slowpath+0x64/0x9b [] mutex_lock+0xa/0xb [] shrink_icache_memory+0x38/0x200 [] shrink_slab+0xe3/0x15b [] try_to_free_pages+0x221/0x30d [] isolate_pages_global+0x0/0x31 [] __alloc_pages_internal+0x252/0x3ab [] cache_alloc_refill+0x22e/0x47b [] kmem_cache_alloc+0x3b/0x61 [] cache_alloc_refill+0x2fe/0x47b [] __kmalloc+0x76/0x9c [] :udf:udf_new_inode+0x202/0x2e2 [] :udf:udf_create+0x2f/0x16d [] :udf:udf_lookup+0xa6/0xad ... kswapd0 D ffff81015b9d9270 0 125 2 ffff81015b903c28 0000000000000046 ffffffff8028cbb0 00000000fffffffb ffff81015b9d9270 ffff81015b8f0cd0 ffff81015b9d94c0 000000000271b490 ffffe2000271b458 ffffe2000271b420 ffffe20002728dc8 ffffe20002728d90 Call Trace: [] __set_page_dirty+0xeb/0xf5 [] get_dirty_limits+0x1d/0x22f [] __mutex_lock_slowpath+0x64/0x9b [] mutex_lock+0xa/0xb [] :udf:udf_bitmap_free_blocks+0x47/0x1eb [] :udf:udf_discard_prealloc+0xc6/0x172 [] :udf:udf_clear_inode+0x1e/0x48 [] clear_inode+0x6d/0xc4 [] dispose_list+0x56/0xee [] shrink_icache_memory+0x1d0/0x200 [] shrink_slab+0xe3/0x15b [] kswapd+0x346/0x447 ... Reported-by: Tibor Tajti Reviewed-by: Ingo Oeser Signed-off-by: Jan Kara commit 0c925d79234fe77589d8ff3861f9f8bb9e7fc3f6 Author: Hiroshi Shimamoto Date: Mon Aug 18 21:49:51 2008 -0700 rcuclassic: fix compilation NG fix: CC kernel/rcuclassic.o kernel/rcuclassic.c: In function '__rcu_process_callbacks': kernel/rcuclassic.c:561: error: 'flags' undeclared (first use in this function) kernel/rcuclassic.c:561: error: (Each undeclared identifier is reported only once kernel/rcuclassic.c:561: error: for each function it appears in.) Declare missing variable flags. Signed-off-by: Hiroshi Shimamoto Signed-off-by: Ingo Molnar commit 5955902fb5c31f6a784ddb7aa16079a2bec588f5 Author: Högander Jouni Date: Tue Aug 19 11:08:45 2008 +0300 ARM: OMAP2: Clock: Combine 34xx l3_icks and l4_icks E.g dss_l3_ick and dss_l4_ick have same gating control. Having own clock for both of them causes race condition between enable / disable. This patch combines this kind of clocks and names new clock as _ick. Signed-off-by: Jouni Hogander Acked-by: Paul Walmsley Signed-off-by: Tony Lindgren commit 333943ba9e1716a3751af82f2dcc7620b83091ed Author: Paul Walmsley Date: Tue Aug 19 11:08:45 2008 +0300 ARM: OMAP2: Clockdomain: Integrate OMAP3 clocks with clockdomain code This patch integrates the OMAP3 clock tree with the clockdomain code. This patch: - marks OMAP34xx clocks with their corresponding clockdomain. - adds code to convert the clockdomain name to a clockdomain pointer in the struct clk during clk_register(). - modifies OMAP2 clock usecounting to call into the clockdomain code when clocks are enabled or disabled. Signed-off-by: Paul Walmsley Signed-off-by: Tony Lindgren commit d1b03f615ae7ede957551dd26bf8929bdc2bb786 Author: Paul Walmsley Date: Tue Aug 19 11:08:44 2008 +0300 ARM: OMAP2: Clockdomain: Associate clocks with clockdomains Associate each OMAP24xx clock in arch/arm/mach-omap2/clock24xx.h with a clockdomain. Also move the L4 clock up higher in the file in preparation to define the SSI L4 iclk. Signed-off-by: Paul Walmsley Signed-off-by: Tony Lindgren commit 801954d3debb87af9fa7f9187cb1100175d76ac7 Author: Paul Walmsley Date: Tue Aug 19 11:08:44 2008 +0300 ARM: OMAP2: Clockdomain: Encode OMAP2/3 clockdomains Add clockdomain definitions for OMAP24xx and OMAP34xx chips. Signed-off-by: Paul Walmsley Signed-off-by: Tony Lindgren commit 8420bb13630032097be911a039cb64b5f62c01da Author: Paul Walmsley Date: Tue Aug 19 11:08:44 2008 +0300 ARM: OMAP2: Clockdomain: Connect clockdomain code to powerdomain code Thie patch adds code to the powerdomain layer to track the clockdomains associated with each powerdomain. It also modifies the clockdomain code to register clockdomains with their corresponding powerdomain when the clockdomain is registered. Signed-off-by: Paul Walmsley Signed-off-by: Tony Lindgren commit d459bfe01f523983a822de8c2d3fe0bd2f2c194e Author: Paul Walmsley Date: Tue Aug 19 11:08:43 2008 +0300 ARM: OMAP2: Clockdomain: Add base OMAP2/3 clockdomain code This patch creates an interface to the clockdomain registers in the PRM/CM modules on OMAP2/3. This interface is intended to be used by PM code, e.g., pm.c; not by device drivers directly. The patch also adds clockdomain usecount tracking. This is intended to be called whenever the first clock in a clockdomain is enabled, or when the last enabled clock in a clockdomain is disabled. If the clockdomain is in software-supervised mode, the code will force-wakeup or force-sleep the clockdomain. If the clockdomain is in hardware-supervised mode, the first clock enable will add sleep and wakeup dependencies on a user-selectable set of parent domains (usually MPU & IVA2), and the disable will remove them. Each clockdomain will be defined in later patches as static structures. The clockdomain structures are linked into a list at boot by clkdm_register(), similar to the OMAP clock code. The patch adds a Kconfig option, CONFIG_OMAP_DEBUG_CLOCKDOMAIN, which when enabled will emit verbose debug messages via pr_debug(). Signed-off-by: Paul Walmsley Signed-off-by: Tony Lindgren commit ecb24aa129c6d4b2152571f856320aa7dea41676 Author: Paul Walmsley Date: Tue Aug 19 11:08:43 2008 +0300 ARM: OMAP: Powerdomain: Add OMAP3 powerdomains Add OMAP3-specific powerdomains. Signed-off-by: Paul Walmsley Signed-off-by: Tony Lindgren commit fe6a58f8f50500a4c9a82da4a9bdae41c1500fa0 Author: Paul Walmsley Date: Tue Aug 19 11:08:42 2008 +0300 ARM: OMAP2: Powerdomain: Add OMAP2 powerdomains Add OMAP2-specific powerdomains. Signed-off-by: Paul Walmsley Signed-off-by: Tony Lindgren commit 9717100f77538bbee54d2b5c293fd829b252d2a6 Author: Paul Walmsley Date: Tue Aug 19 11:08:40 2008 +0300 ARM: OMAP2: Powerdomain: Add OMAP2/3 common powerdomains Add powerdomains common to both OMAP2 and OMAP3 (WKUP and GFX/SGX). Modify mach-omap2/io.c to initialize the powerdomain code on boot. Signed-off-by: Paul Walmsley Signed-off-by: Tony Lindgren commit ad67ef6848a1608b0430003e11e7af1ce706e341 Author: Paul Walmsley Date: Tue Aug 19 11:08:40 2008 +0300 ARM: OMAP2: Powerdomain: Add base OMAP2/3 powerdomain code This patch creates an interface to the powerdomain registers in the PRM/CM modules on OMAP2/3. This interface is intended to be used by PM code, e.g., pm.c; not by device drivers directly. Each powerdomain will be defined in later patches as static structures. Also defined are dependencies between powerdomains, used for adding and removing PM_WKDEP and CM_SLEEPDEP bits. The powerdomain structures are linked into a list at boot by pwrdm_register(), similar to the OMAP clock code. The patch adds a Kconfig option, CONFIG_OMAP_DEBUG_POWERDOMAIN, which when enabled will emit verbose debug messages via pr_debug(). Signed-off-by: Paul Walmsley Signed-off-by: Tony Lindgren commit f728bafb5698076dd35bca35ee6cfe52ea1b8ab2 Author: Sven Wegener Date: Tue Aug 19 08:16:19 2008 +0200 ipvs: Fix race conditions in lblcr scheduler We can't access the cache entry outside of our critical read-locked region, because someone may free that entry. Also getting an entry under read lock, then locking for write and trying to delete that entry looks fishy, but should be no problem here, because we're only comparing a pointer. Also there is no need for our own rwlock, there is already one in the service structure for use in the schedulers. Signed-off-by: Sven Wegener Signed-off-by: Simon Horman commit 39ac50d0c79747b186c1268d9a488f8c1d256be7 Author: Sven Wegener Date: Mon Aug 18 00:52:08 2008 +0200 ipvs: Fix race conditions in lblc scheduler We can't access the cache entry outside of our critical read-locked region, because someone may free that entry. And we also need to check in the critical region wether the destination is still available, i.e. it's not in the trash. If we drop our reference counter, the destination can be purged from the trash at any time. Our caller only guarantees that no destination is moved to the trash, while we are scheduling. Also there is no need for our own rwlock, there is already one in the service structure for use in the schedulers. Signed-off-by: Sven Wegener Signed-off-by: Simon Horman commit eff9b713ee3540ddab862095aaf4b1511a6758bc Author: Paul E. McKenney Date: Mon Aug 18 17:51:08 2008 -0700 rcu: fix locking cleanup fallout Given that the rcp->lock is now acquired from call_rcu(), which can be invoked from irq-disable regions, all acquisitions need to disable irqs. The following patch fixes this. Although I don't have any reason to believe that this is the cause of Yinghai's oops, it does need to be fixed. Signed-off-by: Paul E. McKenney Cc: Yinghai Lu Signed-off-by: Ingo Molnar commit 20211e4d344729f4d4c93da37a590fc1c3a1fd9b Author: Paolo Ciarrocchi Date: Mon Aug 18 21:25:38 2008 +0200 x86: Coding style fixes to arch/x86/oprofile/op_model_p4.c A coding style patch to arch/x86/oprofile/op_model_p4.c that removes 87 errors and 4 warnings. Before: total: 89 errors, 13 warnings, 722 lines checked After: total: 2 errors, 9 warnings, 721 lines checked Compile tested, binary verified as follow: paolo@paolo-desktop:~/linux.trees.git$ size /tmp/op_model_p4.o.* text data bss dec hex filename 2691 968 32 3691 e6b /tmp/op_model_p4.o.after 2691 968 32 3691 e6b /tmp/op_model_p4.o.before paolo@paolo-desktop:~/linux.trees.git$ md5sum /tmp/op_model_p4.o.* 8c1c9823bab33333e1f7f76574e62561 /tmp/op_model_p4.o.after 8c1c9823bab33333e1f7f76574e62561 /tmp/op_model_p4.o.before Signed-off-by: Paolo Ciarrocchi Cc: robert.richter@amd.com Signed-off-by: Ingo Molnar commit 8df9676d6402563da91427e8d9f2da8a4598aede Author: H. Peter Anvin Date: Mon Aug 18 18:13:33 2008 -0700 x86: consistency cleanups Rename _ASM_MOV_UL to _ASM_MOV for consistency with other _ASM_ instructions (_ASM_ADD, _ASM_SUB and so on.) Add ASM_SP, _ASM_BP, _ASM_SI, and _ASM_DI for consistency with _ASM_[ABCD]X. Signed-off-by: H. Peter Anvin commit f1c5d30e1d79bbfb60eaf189db862d3cb2bcac92 Author: H. Peter Anvin Date: Mon Aug 18 17:50:33 2008 -0700 x86: use X86_FEATURE_NOPL in alternatives Use X86_FEATURE_NOPL to determine if it is safe to use P6 NOPs in alternatives. Also, replace table and loop with simple if statement. Signed-off-by: H. Peter Anvin commit 7e00df5818964298c9821365a6cb7a8304227c5c Author: H. Peter Anvin Date: Mon Aug 18 17:39:32 2008 -0700 x86: add NOPL as a synthetic CPU feature bit The long noops ("NOPL") are supposed to be detected by family >= 6. Unfortunately, several non-Intel x86 implementations, both hardware and software, don't obey this dictum. Instead, probe for NOPL directly by executing a NOPL instruction and see if we get #UD. Signed-off-by: H. Peter Anvin commit e2fe16d91228a005811335fbc4fbad5d4f5b75af Author: H. Peter Anvin Date: Fri Aug 15 15:36:31 2008 -0700 x86: boot: stub out unimplemented CPU feature words The CPU feature detection code in the boot code is somewhat minimal, and doesn't include all possible CPUID words. In particular, it doesn't contain the code for CPU feature words 2 (Transmeta), 3 (Linux-specific), 5 (VIA), or 7 (scattered). Zero them out, so we can still set those bits as known at compile time; in particular, this allows creating a Linux-specific NOPL flag and have it required (and therefore resolvable at compile time) in 64-bit mode. Signed-off-by: H. Peter Anvin commit a8734cc26fe7d00213d58de01e209758b93fd5bb Author: Jeremy Fitzhardinge Date: Mon Aug 18 15:58:12 2008 -0700 ftrace: fix build problem with CONFIG_FTRACE I'm seeing when I use separate src/build dirs: make[3]: *** [arch/x86/kernel/time_32.o] Error 1 /bin/sh: scripts/recordmcount.pl: No such file or directory make[3]: *** [arch/x86/kernel/irq_32.o] Error 1 /bin/sh: scripts/recordmcount.pl: No such file or directory make[3]: *** [arch/x86/kernel/ldt.o] Error 1 /bin/sh: scripts/recordmcount.pl: No such file or directory make[3]: *** [arch/x86/kernel/i8259.o] Error 1 /bin/sh: scripts/recordmcount.pl: No such file or directory This fixes it. Signed-off-by: Ingo Molnar commit 16f9b13de93c8bfdac16b4d15577af2c132358ef Author: Arjan van de Ven Date: Fri Aug 15 15:29:38 2008 -0700 debug: add notifier chain debugging during some development we suspected a case where we left something in a notifier chain that was from a module that was unloaded already... and that sort of thing is rather hard to track down. This patch adds a very simple sanity check (which isn't all that expensive) to make sure the notifier we're about to call is actually from either the kernel itself of from a still-loaded module, avoiding a hard-to-chase-down crash. Signed-off-by: Arjan van de Ven Signed-off-by: Ingo Molnar commit 479fa18280562a9c2432fc65c692b11b14ece78c Author: Randy Dunlap Date: Tue Aug 19 10:36:08 2008 +1000 docum-fs-dnotify Make dnotify_test.c source file and add it to Makefile so that bitrot can be prevented. Signed-off-by: Randy Dunlap commit 58a129001e1459e8c5062394970762511bc27391 Author: Randy Dunlap Date: Tue Aug 19 10:36:08 2008 +1000 docum-fs-smount Make smount.c source file and add that to Makefile so that its build can be checked. Signed-off-by: Randy Dunlap commit bcbfb613cdca2d5c4c3f67ed428d7464abe7fb2f Author: Randy Dunlap Date: Tue Aug 19 10:36:08 2008 +1000 kerndoc-block-add Add some block/ source files to the kernel-api docbook. Fix kernel-doc notation in them as needed. Fix changed function parameter names. Fix typos/spellos. In comments, change REQ_SPECIAL to REQ_TYPE_SPECIAL and REQ_BLOCK_PC to REQ_TYPE_BLOCK_PC. Signed-off-by: Randy Dunlap commit 94ec74359a9177422b79dd1478fc495d7f2c797f Author: Randy Dunlap Date: Tue Aug 19 10:36:08 2008 +1000 kerndoc-security-add Add security/inode.c functions to the kernel-api docbook. Use '%' on constants in kernel-doc notation. Fix several typos/spellos in security function descriptions. Signed-off-by: Randy Dunlap commit f14625bd5eacb09928ff3c3f20933a32a99d5fea Author: Randy Dunlap Date: Tue Aug 19 10:36:07 2008 +1000 doc-move-initrd-txt Continuing Documentation/ tree cleanups and re-organizations. Add early-userspace/00-INDEX file. Move initrd.txt to early-userspace/ sub-dir and remove some trailing whitespace. Signed-off-by: Randy Dunlap commit e2bf6726cc7461e96944619fe78608bbf01b556c Author: Randy Dunlap Date: Tue Aug 19 10:36:07 2008 +1000 doc-timers-move-hpet Move hpet.txt to Documentation/timers/ subdirectory. Add 00-INDEX to Documentation/timers/ subdirectory. Signed-off-by: Randy Dunlap commit d7487f82f7c799903892be2396331ddb0319432e Author: Randy Dunlap Date: Tue Aug 19 10:36:07 2008 +1000 doc-x86-move-mtrr Move mtrr.txt to the Documentation/x86/ subdirectory. Add 00-INDEX to the Documentation/x86/ subdirectory. Signed-off-by: Randy Dunlap commit 2a4100292a42d0ea3f50578617175ed90c972216 Author: Randy Dunlap Date: Tue Aug 19 10:36:07 2008 +1000 kerndoc-macro-find Allow macros that are annotated with kernel-doc to contain whitespace between the '#' and "define". It's valid and being used, so allow it. Signed-off-by: Randy Dunlap commit 41c4f3d7471128d9e7e184d21470babc562cdff1 Author: Randy Dunlap Date: Tue Aug 19 10:36:07 2008 +1000 kernelh-kerndoc1 Put the kernel-doc for might_sleep() _immediately_ before the macro (no intervening lines). Otherwise kernel-doc complains like so: Warning(linux-2.6.27-rc3-git2//include/linux/kernel.h:129): No description found for parameter 'file' Warning(linux-2.6.27-rc3-git2//include/linux/kernel.h:129): No description found for parameter 'line' because kernel-doc is looking at the wrong function prototype (i.e., __might_sleep). [Yes, I have a todo note to myself to check/warn for that inconsistency in scripts/kernel-doc.] Signed-off-by: Randy Dunlap cc: Uwe Kleine-König commit 276605dddb74cbf1b77696e32c4a947e42cec52d Author: Suresh Siddha Date: Mon Aug 18 11:13:02 2008 -0700 x2apic: use x2apic id reported by cpuid during topology discovery use x2apic id reported by cpuid during topology discovery, instead of the apic id configured in the APIC. For most of the systems, x2apic id reported by cpuid leaf 0xb will be same as the physical apic id reported by the APIC_ID register of the APIC. We follow the suggested guidelines and use the apic id reported by the cpuid. No change to non-generic UV platforms, will use the apic id reported in the APIC_ID register as the cpuid reported apic id's may not be unique. Signed-off-by: Suresh Siddha Signed-off-by: Ingo Molnar commit d92ca3e085e9ec39adb20d93bc8266b6fdc83d3d Author: Suresh Siddha Date: Mon Aug 18 11:13:01 2008 -0700 x2apic: use cpuid vector 0xb when available for detecting cpu topology cpuid leaf 0xb provides extended topology enumeration. This interface provides the 32-bit x2APIC id of the logical processor and it also provides a new mechanism to detect SMT and core siblings (which provides increased addressability). Signed-off-by: Suresh Siddha Signed-off-by: Ingo Molnar commit 467cd0529a480c9c25f06154b788d1d1ba77828a Author: Harvey Harrison Date: Mon Aug 18 16:56:29 2008 -0700 x86: early_printk.c trivial sparse fixes arch/x86/kernel/early_printk.c:404:13: warning: incorrect type in assignment (different base types) arch/x86/kernel/early_printk.c:404:13: expected restricted __le16 [assigned] [usertype] wValue arch/x86/kernel/early_printk.c:404:13: got int [signed] value arch/x86/kernel/early_printk.c:405:13: warning: incorrect type in assignment (different base types) arch/x86/kernel/early_printk.c:405:13: expected restricted __le16 [assigned] [usertype] wIndex arch/x86/kernel/early_printk.c:405:13: got int [signed] index arch/x86/kernel/early_printk.c:406:14: warning: incorrect type in assignment (different base types) arch/x86/kernel/early_printk.c:406:14: expected restricted __le16 [assigned] [usertype] wLength arch/x86/kernel/early_printk.c:406:14: got int [signed] size arch/x86/kernel/early_printk.c:845:16: warning: Using plain integer as NULL pointer arch/x86/kernel/early_printk.c:992:13: warning: symbol 'enable_debug_console' was not declared. Should it be static? Signed-off-by: Harvey Harrison Signed-off-by: Ingo Molnar commit 1b4ee4e4096d430c4c12516c1d30a6b0b4f9e9e4 Author: Cyrill Gorcunov Date: Mon Aug 18 23:12:33 2008 +0400 x86: apic - compilation warnings fix Signed-off-by: Cyrill Gorcunov Signed-off-by: Ingo Molnar commit e75bedf415f300a08e9bbcc755784e488574a73e Author: Cyrill Gorcunov Date: Mon Aug 18 20:46:03 2008 +0400 x86: apic - lapic_resume 32bit - unification fix Just add parenthesis to be identical of current 64bit implementation (so diff will not complain). Signed-off-by: Cyrill Gorcunov Signed-off-by: Ingo Molnar commit 3415610b8e38b26b52a430b8846665c2d6bb3558 Author: Cyrill Gorcunov Date: Mon Aug 18 20:46:02 2008 +0400 x86: apic - rearrange parse_lapic_timer_c2_ok Signed-off-by: Cyrill Gorcunov Signed-off-by: Ingo Molnar commit 789fa735712d726b5cfa5c6be57171b5637a4872 Author: Cyrill Gorcunov Date: Mon Aug 18 20:46:01 2008 +0400 x86: apic - unify disableapic and nolapic setup handlers Signed-off-by: Cyrill Gorcunov Signed-off-by: Ingo Molnar commit 79af9bec60e6e218a1e48e8830d603d64a7fc441 Author: Cyrill Gorcunov Date: Mon Aug 18 20:46:00 2008 +0400 x86: apic - unify apic_set_verbosity Signed-off-by: Cyrill Gorcunov Signed-off-by: Ingo Molnar commit 0b23e8cf553f5e706b0057363f1319867bcd1a7d Author: Cyrill Gorcunov Date: Mon Aug 18 20:45:59 2008 +0400 x86: apic - unify local_apic_timer_interrupt Signed-off-by: Cyrill Gorcunov Signed-off-by: Ingo Molnar commit fa6b95fc7c6f2f3eb1560e1f33cd13197546c5a0 Author: Cyrill Gorcunov Date: Mon Aug 18 20:45:58 2008 +0400 x86: apic - unify end_local_APIC_setup Signed-off-by: Cyrill Gorcunov Signed-off-by: Ingo Molnar commit 1b313f4a6d7bee7b2c034b3f1e203bc360a71cca Author: Cyrill Gorcunov Date: Mon Aug 18 20:45:57 2008 +0400 x86: apic - generic_processor_info - use physid_set instead of phys_cpu and physids_or - set phys_cpu_present_map bit AFTER check for allowed number of processors - add checking for APIC valid version in 64bit mode (mostly not needed but added for merging purpose) - add apic_version definition for 64bit mode which is used now Signed-off-by: Cyrill Gorcunov Signed-off-by: Ingo Molnar commit c177b0bc03e0e11623e2099db42903fb0caf0fd3 Author: Cyrill Gorcunov Date: Mon Aug 18 20:45:56 2008 +0400 x86: apic - unify disconnect_bsp_APIC - just #ifdef added Signed-off-by: Cyrill Gorcunov Signed-off-by: Ingo Molnar commit c40aaec6868401671a0ca14ed77e9b2da2d1f223 Author: Cyrill Gorcunov Date: Mon Aug 18 20:45:55 2008 +0400 x86: apic - unify __setup_APIC_LVTT Signed-off-by: Cyrill Gorcunov Signed-off-by: Ingo Molnar commit c43da2f5e92fe3bcc256f0c0d6cb858368da5bd9 Author: Cyrill Gorcunov Date: Mon Aug 18 20:45:54 2008 +0400 x86: apic - unify lapic_setup_esr We use 32bit code former for 64bit mode since it's much better implementation and easier to merge. Signed-off-by: Cyrill Gorcunov Signed-off-by: Ingo Molnar commit 36c9d6742897fa414f51c4e9d0f20ab4e6bf942c Author: Cyrill Gorcunov Date: Mon Aug 18 20:45:53 2008 +0400 x86: apic - unify connect_bsp_APIC Signed-off-by: Cyrill Gorcunov Signed-off-by: Ingo Molnar commit fe4024dcb0c01e5399394d2807406a2c13fb1eb7 Author: Cyrill Gorcunov Date: Mon Aug 18 20:45:52 2008 +0400 x86: apic - unify lapic_shutdown Signed-off-by: Cyrill Gorcunov Signed-off-by: Ingo Molnar commit 990b183e58cb513a62492b6218987750e106cbfb Author: Cyrill Gorcunov Date: Mon Aug 18 20:45:51 2008 +0400 x86: apic - unify disable_local_APIC Signed-off-by: Cyrill Gorcunov Signed-off-by: Ingo Molnar commit f1ee37891dab6014f6b0ec77b18bc07e2369a55f Author: Cyrill Gorcunov Date: Mon Aug 18 20:45:50 2008 +0400 x86: apic - unify setup_boot_APIC_clock Signed-off-by: Cyrill Gorcunov Signed-off-by: Ingo Molnar commit b6c8051311e1a14d229df05ea39d0a1b2ce90cdd Author: Cyrill Gorcunov Date: Mon Aug 18 20:45:49 2008 +0400 x86: apic - rearrange maxcpu definition Signed-off-by: Cyrill Gorcunov Signed-off-by: Ingo Molnar commit e33cb81eae2fb35b3d1034c2e08486c771262979 Author: Tao Ma Date: Mon Aug 18 17:38:44 2008 +0800 [PATCH 03/16] ocfs2: Abstract ocfs2_extent_tree in b-tree operations. In the old extent tree operation, we take the hypothesis that we are using the ocfs2_extent_list in ocfs2_dinode as the tree root. As xattr will also use ocfs2_extent_list to store large value for a xattr entry, we refactor the tree operation so that xattr can use it directly. The refactoring includes 4 steps: 1. Abstract set/get of last_eb_blk and update_clusters since they may be stored in different location for dinode and xattr. 2. Add a new structure named ocfs2_extent_tree to indicate the extent tree the operation will work on. 3. Remove all the use of fe_bh and di, use root_bh and root_el in extent tree instead. So now all the fe_bh is replaced with et->root_bh, el with root_el accordingly. 4. Make ocfs2_lock_allocators generic. Now it is limited to be only used in file extend allocation. But the whole function is useful when we want to store large EAs. Note: This patch doesn't touch ocfs2_commit_truncate() since it is not used for anything other than truncate inode data btrees. Signed-off-by: Tao Ma Signed-off-by: Mark Fasheh commit 7caf04db82b3e819572fe7f73422418f9467c761 Author: Tao Ma Date: Mon Aug 18 17:38:43 2008 +0800 [PATCH 02/16] ocfs2: Use ocfs2_extent_list instead of ocfs2_dinode. ocfs2_extend_meta_needed(), ocfs2_calc_extend_credits() and ocfs2_reserve_new_metadata() are all useful for extent tree operations. But they are all limited to an inode btree because they use a struct ocfs2_dinode parameter. Change their parameter to struct ocfs2_extent_list (the part of an ocfs2_dinode they actually use) so that the xattr btree code can use these functions. Signed-off-by: Tao Ma Signed-off-by: Mark Fasheh commit 0a126e934ce26727a71a12b41274cc9902e42b00 Author: Tao Ma Date: Mon Aug 18 17:38:42 2008 +0800 [PATCH 01/16] ocfs2: Modify ocfs2_num_free_extents for future xattr usage. ocfs2_num_free_extents() is used to find the number of free extent records in an inode btree. Hence, it takes an "ocfs2_dinode" parameter. We want to use this for extended attribute trees in the future, so genericize the interface the take a buffer head. A future patch will allow that buffer_head to contain any structure rooting an ocfs2 btree. Signed-off-by: Tao Ma Signed-off-by: Mark Fasheh commit 75caf6b5acc6b895df9bdd36db631220e1096e9f Author: David Woodhouse Date: Mon Aug 18 16:23:53 2008 +0100 [JFFS2] Fill in f_fsid field in jffs2_statfs() Signed-off-by: David Woodhouse commit 73ab4e5d65f937d01ef5b751255272e4bea0162e Author: Takashi Iwai Date: Mon Aug 18 17:11:09 2008 +0200 ALSA: hda - disable delayed period-ack with bdl_pos_adj=0 When bdl_pos_adj=0 is given, disable the position-check and the delayed period update mechanism. Usually bdl_pos_adj=0 is set only for the debugging purpose on really broken hardwares. It's better to disable the extra complexity in such a case. Signed-off-by: Takashi Iwai commit 8d02c2110b3fb8e2700b31596a582a2989fd72ba Author: Thomas Petazzoni Date: Tue Aug 5 11:45:19 2008 +0200 x86: configuration options to compile out x86 CPU support code This patch adds some configuration options that allow to compile out CPU vendor-specific code in x86 kernels (in arch/x86/kernel/cpu). The new configuration options are only visible when CONFIG_EMBEDDED is selected, as they are mostly interesting for space savings reasons. An example of size saving, on x86 with only Intel CPU support: text data bss dec hex filename 1125479 118760 212992 1457231 163c4f vmlinux.old 1121355 116536 212992 1450883 162383 vmlinux -4124 -2224 0 -6348 -18CC +/- However, I'm not exactly sure that the Kconfig wording is correct with regard to !64BIT / 64BIT. [ mingo@elte.hu: convert macro to inline ] Signed-off-by: Thomas Petazzoni Signed-off-by: Ingo Molnar commit 774400a3ba23b63f4de39e67ce6c4e48935809dc Author: Thomas Petazzoni Date: Mon Aug 18 12:33:21 2008 +0200 x86: move cmpxchg fallbacks to a generic place arch/x86/kernel/cpu/intel.c defines a few fallback functions (cmpxchg_*()) that are used when the CPU doesn't support cmpxchg and/or cmpxchg64 natively. However, while defined in an Intel-specific file, these functions are also used for CPUs from other vendors when they don't support cmpxchg and/or cmpxchg64. This breaks the compilation when support for Intel CPUs is disabled. This patch moves these functions to a new arch/x86/kernel/cpu/cmpxchg.c file, unconditionally compiled when X86_32 is enabled. Signed-off-by: Thomas Petazzoni Cc: michael@free-electrons.com Signed-off-by: Ingo Molnar commit 8bfcb3960fde049b863266dab8c3617bb5a541aa Author: Thomas Petazzoni Date: Mon Aug 18 12:33:20 2008 +0200 x86: make movsl_mask definition non-CPU specific movsl_mask is currently defined in arch/x86/kernel/cpu/intel.c, which contains code specific to Intel CPUs. However, movsl_mask is used in the non-CPU specific code in arch/x86/lib/usercopy_32.c, which breaks the compilation when support for Intel CPUs is compiled out. This patch solves this problem by moving movsl_mask's definition close to its users in arch/x86/lib/usercopy_32.c. Signed-off-by: Thomas Petazzoni Cc: michael@free-electrons.com Signed-off-by: Ingo Molnar commit f33b0bf1b0e5ce19f77ab5efe133fac0406ed4e8 Author: Harvey Harrison Date: Mon Aug 11 16:54:20 2008 -0700 KVM: make irq ack notifier functions static sparse says: arch/x86/kvm/x86.c:107:32: warning: symbol 'kvm_find_assigned_dev' was not declared. Should it be static? arch/x86/kvm/i8254.c:225:6: warning: symbol 'kvm_pit_ack_irq' was not declared. Should it be static? Signed-off-by: Harvey Harrison Signed-off-by: Andrew Morton Signed-off-by: Avi Kivity commit 588ad7ea8255377c5c86ff205558ca29f280edd5 Author: Amit Shah Date: Mon Aug 18 15:07:05 2008 +0300 KVM: Use kvm_set_irq to inject interrupts ... instead of using the pic and ioapic variants Signed-off-by: Amit Shah Signed-off-by: Avi Kivity commit a0ff2e572ad17ba9aa79a62a590317e3a5b495ee Author: Krzysztof Helt Date: Sun Aug 17 22:38:27 2008 +0200 ALSA: wss_lib: snd_wss_calibrate_mute improvement Mute sound by setting mute bit without setting volume to 0. It makes both source code and binary shorter. Signed-off-by: Krzysztof Helt Signed-off-by: Takashi Iwai commit 8748e820479ae55f546bd9173f052b3bcd76ba23 Author: Takashi Iwai Date: Mon Aug 18 13:53:07 2008 +0200 ALSA: hda - Add AD1882A codec support Added the basic support of AD1882A codec chip. It's almost compatible with AD1882, but with a digital mic and some differences in connections. Signed-off-by: Takashi Iwai commit 94d9ff7819529420c6b8fa6e791942b8309b7f30 Author: Amit Shah Date: Mon Aug 18 13:11:46 2008 +0300 KVM: SVM: Fix typo Fix typo in as-yet unused macro definition. Signed-off-by: Amit Shah Signed-off-by: Avi Kivity commit 00261b8037c130780f9d83cfaf31672601d524a3 Author: Mohammed Gamal Date: Sun Aug 17 16:42:16 2008 +0300 KVM: VMX: Modify mode switching and vmentry functions This patch modifies mode switching and vmentry function in order to drive invalid guest state emulation. Signed-off-by: Mohammed Gamal Signed-off-by: Avi Kivity commit 29698e2f5b8fb494c37370e9e72ae58adfdc7b20 Author: Mohammed Gamal Date: Sun Aug 17 16:47:05 2008 +0300 KVM: VMX: Add invalid guest state handler This adds the invalid guest state handler function which invokes the x86 emulator until getting the guest to a VMX-friendly state. Signed-off-by: Laurent Vivier Signed-off-by: Guillaume Thouvenin Signed-off-by: Mohammed Gamal Signed-off-by: Avi Kivity commit d39201bd3a47aa0fbf28180e05510684f02cc286 Author: Mohammed Gamal Date: Sun Aug 17 16:39:48 2008 +0300 KVM: VMX: Add module parameter and emulation flag. The patch adds the module parameter required to enable emulating invalid guest state, as well as the emulation_required flag used to drive emulation whenever needed. Signed-off-by: Mohammed Gamal Signed-off-by: Avi Kivity commit 4e7b3641b8097edfcfde66b5d27258ee3d7c2fa6 Author: Mohammed Gamal Date: Sun Aug 17 16:38:32 2008 +0300 KVM: VMX: Add Guest State Validity Checks This patch adds functions to check whether guest state is VMX compliant. Signed-off-by: Mohammed Gamal Signed-off-by: Avi Kivity commit 2127b9623bca45b012f62a7c09b2c6cfdfd4ab0c Author: Amit Shah Date: Wed Aug 13 16:22:37 2008 +0300 KVM: Device assignment: Check for privileges before assigning irq Even though we don't share irqs at the moment, we should ensure regular user processes don't try to allocate system resources. We check for capability to access IO devices (CAP_SYS_RAWIO) before we request_irq on behalf of the guest. Noticed by Avi. Signed-off-by: Amit Shah Signed-off-by: Avi Kivity commit 2e7c6c2408d04b19af639790d718ef9a39da8f7d Author: Sheng Yang Date: Mon Aug 18 11:04:22 2008 +0800 KVM: Fix KVM_GET_LAPIC using wrong size Which caused migration fail in recent commits. Signed-off-by: Sheng Yang Signed-off-by: Avi Kivity commit 3462b4669cfacd5db7d259df48f5cb93f350a611 Author: Huang Ying Date: Mon Aug 18 16:24:56 2008 +0800 ftrace: fix incorrect comment style of __ftrace_enabled_save() This patch fixes incorrect comment style of __ftrace_enabled_save(). Signed-off-by: Huang Ying Signed-off-by: Ingo Molnar commit ded00a56e99555c3f4000ef3eebfd5fe0d574565 Author: Paul E. McKenney Date: Sun Aug 17 12:50:36 2008 -0700 rcu: remove redundant ACCESS_ONCE definition from rcupreempt.c Remove the redundant definition of ACCESS_ONCE() from rcupreempt.c in favor of the one in compiler.h. Also merge the comment header from rcupreempt.c's definition into that in compiler.h. Signed-off-by: Paul E. McKenney Signed-off-by: Ingo Molnar commit d5e629a6f88137fb77c4cc857be5ea7c3f27110d Author: Yinghai Lu Date: Sun Aug 17 21:12:27 2008 -0700 x86: apic - unify lapic_resume - fix Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit 34d0a9ee7fa617283df0399e38cdd7a6a79f0f9b Author: Krzysztof Helt Date: Sun Aug 17 20:01:14 2008 +0200 ALSA: opl3sa2: drop snd_card pointer from the snd_opl3sa2 structure Remove card pointer from the snd_opl3sa2 structure and break circular reference snd_card->snd_opl3sa2->snd_card. Signed-off-by: Krzysztof Helt Acked-by: Rene Herman Signed-off-by: Takashi Iwai commit e0c42ae0f9e3b6a318ea065bc912bbcbd4a90d06 Author: Zhao Yakui Date: Mon Aug 18 11:14:34 2008 +0800 ACPI: Avoid twice read access to EC data I/O port In current kernel when OS reads the data returned by the EC controller, the EC data I/O port is accessed twice. In fact is is meaningless. Only once access to EC data I/O port is enough to get data returned by EC controller. Signed-off-by : Zhao Yakui Acked-by : Alexey Starikovskiy Signed-off-by: Andi Kleen commit 1371c893ff9de0d57fa5b5cf0255d66b8849e13d Author: Ming Ling Date: Mon Aug 18 04:14:59 2008 +0200 ACPI: Change package length error to warning The condition is harmless and no need to scare the user http://bugzilla.kernel.org/show_bug.cgi?id=11245 Signed-off-by: Andi Kleen commit 7b22ff5344fda666e0938e5261ea7b9a3dfce497 Author: FUJITA Tomonori Date: Mon Aug 18 00:36:18 2008 +0900 x86 gart: allocate size-aligned address for alloc_coherent, v2 This patch changes GART IOMMU to return a size aligned address wrt dma_alloc_coherent, as DMA-mapping.txt defines: The cpu return address and the DMA bus master address are both guaranteed to be aligned to the smallest PAGE_SIZE order which is greater than or equal to the requested size. This invariant exists (for example) to guarantee that if you allocate a chunk which is smaller than or equal to 64 kilobytes, the extent of the buffer you receive will not cross a 64K boundary. Signed-off-by: FUJITA Tomonori Signed-off-by: Ingo Molnar commit cd95851785bcfe95fdf73689e8ecb5a1c5959231 Author: Paul E. McKenney Date: Sun Aug 17 07:37:15 2008 -0700 rcu: fix classic RCU locking cleanup lockdep problem On Fri, Aug 15, 2008 at 04:24:30PM +0200, Ingo Molnar wrote: > > Paul, > > one of your two recent RCU patches caused this lockdep splat in -tip > testing: > > -------------------> > Brought up 2 CPUs > Total of 2 processors activated (6850.87 BogoMIPS). > PM: Adding info for No Bus:platform > khelper used greatest stack depth: 3124 bytes left > > ================================= > [ INFO: inconsistent lock state ] > 2.6.27-rc3-tip #1 > --------------------------------- > inconsistent {softirq-on-W} -> {in-softirq-W} usage. > ksoftirqd/0/4 [HC0[0]:SC1[1]:HE1:SE0] takes: > (&rcu_ctrlblk.lock){-+..}, at: [] __rcu_process_callbacks+0x1ac/0x1f0 > {softirq-on-W} state was registered at: > [] __lock_acquire+0x3f4/0x5b0 > [] lock_acquire+0x89/0xc0 > [] _spin_lock+0x3b/0x70 > [] rcu_init_percpu_data+0x29/0x80 > [] rcu_cpu_notify+0xaf/0xd0 > [] notifier_call_chain+0x2d/0x60 > [] __raw_notifier_call_chain+0x1e/0x30 > [] _cpu_up+0x79/0x110 > [] cpu_up+0x4d/0x70 > [] kernel_init+0xb1/0x200 > [] kernel_thread_helper+0x7/0x10 > [] 0xffffffff > irq event stamp: 14 > hardirqs last enabled at (14): [] trace_hardirqs_on+0xb/0x10 > hardirqs last disabled at (13): [] trace_hardirqs_off+0xb/0x10 > softirqs last enabled at (0): [] copy_process+0x276/0x1190 > softirqs last disabled at (11): [] call_on_stack+0x1a/0x30 > > other info that might help us debug this: > no locks held by ksoftirqd/0/4. > > stack backtrace: > Pid: 4, comm: ksoftirqd/0 Not tainted 2.6.27-rc3-tip #1 > [] print_usage_bug+0x16c/0x1b0 > [] mark_lock+0xa75/0xb10 > [] ? sched_clock+0x15/0x30 > [] __lock_acquire+0x3ad/0x5b0 > [] lock_acquire+0x89/0xc0 > [] ? __rcu_process_callbacks+0x1ac/0x1f0 > [] _spin_lock+0x3b/0x70 > [] ? __rcu_process_callbacks+0x1ac/0x1f0 > [] __rcu_process_callbacks+0x1ac/0x1f0 > [] rcu_process_callbacks+0x26/0x50 > [] __do_softirq+0x95/0x120 > [] ? __do_softirq+0x0/0x120 > [] call_on_stack+0x1a/0x30 > [] ? ksoftirqd+0x96/0x110 > [] ? ksoftirqd+0x0/0x110 > [] ? kthread+0x47/0x80 > [] ? kthread+0x0/0x80 > [] ? kernel_thread_helper+0x7/0x10 > ======================= > calling init_cpufreq_transition_notifier_list+0x0/0x20 > initcall init_cpufreq_transition_notifier_list+0x0/0x20 returned 0 after 0 msecs > calling net_ns_init+0x0/0x190 > net_namespace: 676 bytes > initcall net_ns_init+0x0/0x190 returned 0 after 0 msecs > calling cpufreq_tsc+0x0/0x20 > initcall cpufreq_tsc+0x0/0x20 returned 0 after 0 msecs > calling reboot_init+0x0/0x20 > initcall reboot_init+0x0/0x20 returned 0 after 0 msecs > calling print_banner+0x0/0x10 > Booting paravirtualized kernel on bare hardware > > <----------------------- > > my guess is on: > > commit 1f7b94cd3d564901f9e04a8bc5832ae7bfd690a0 > Author: Paul E. McKenney > Date: Tue Aug 5 09:21:44 2008 -0700 > > rcu: classic RCU locking and memory-barrier cleanups > > Ingo Fixes a problem detected by lockdep in which rcu->lock was acquired both in irq context and in process context, but without disabling from process context. Signed-off-by: Paul E. McKenney Signed-off-by: Ingo Molnar commit 2857ffb7b8913ef713533ac5783abd70a20529e4 Author: Francois Romieu Date: Sat Aug 2 21:08:49 2008 +0200 r8169: additional 8101 and 8102 support Signed-off-by: Ivan Vecera Signed-off-by: Francois Romieu Cc: Edward Hsu commit dacf815434a4d5f5b45687873df46927c64cfb19 Author: Francois Romieu Date: Sat Aug 2 20:44:13 2008 +0200 r8169: add hw start helpers for the 8168 and the 8101 This commit triggers three 'defined but not used' warnings but I prefer avoiding to tie these helpers to a specific change in the hw start sequences of the 8168 or of the 8101. Signed-off-by: Francois Romieu Cc: Edward Hsu commit f162a5d1b326d54b0be7e3100f69763d8a707721 Author: Francois Romieu Date: Sun Jun 1 22:37:49 2008 +0200 r8169: add 8168/8101 registers description Signed-off-by: Francois Romieu Cc: Edward Hsu commit 9c14ceafa5ca7f57225a43fb0785c56ddc7f1823 Author: Francois Romieu Date: Sat Jul 5 00:21:15 2008 +0200 r8169: use pci_find_capability for the PCI-E features Signed-off-by: Francois Romieu Cc: Edward Hsu commit 458a9f617adfb2fc5f38e7673339115c4ba3290f Author: Francois Romieu Date: Sat Aug 2 15:50:02 2008 +0200 r8169: Tx performance tweak helper Signed-off-by: Francois Romieu Cc: Edward Hsu commit ccdffb9a88b2907b159538d7bfd6256621db4f84 Author: Francois Romieu Date: Sat Jul 26 14:26:06 2008 +0200 r8169: get ethtool settings through the generic mii helper It avoids to report unsupported link capabilities with the fast-ethernet only 8101/8102. Signed-off-by: Francois Romieu Tested-by: Martin Capitanio Fixed-by: Ivan Vecera Cc: Edward Hsu commit b991ede96ac946975477ed11f61cf16b3d34d7ff Author: Avi Kivity Date: Sun Aug 17 16:03:46 2008 +0300 KVM: Handle spurious acks for PIT interrupts Spurious acks can be generated, for example if the PIC is being reset. Handle those acks gracefully rather than flooding the log with warnings. Signed-off-by: Avi Kivity commit fa7fed6d2dfa9f62c658414ca1a1be0b2cc94438 Author: Marcelo Tosatti Date: Thu Aug 14 20:53:25 2008 -0300 KVM: fix i8259 reset irq acking The irq ack during pic reset has three problems: - Ignores slave/master PIC, using gsi 0-8 for both. - Generates an ACK even if the APIC is in control. - Depends upon IMR being clear, which is broken if the irq was masked at the time it was generated. The last one causes the BIOS to hang after the first reboot of Windows installation, since PIT interrupts stop. [avi: fix check whether pic interrupts are seen by cpu] Signed-off-by: Marcelo Tosatti Signed-off-by: Avi Kivity commit cf9768d7514d59b3179a886c4a47908d72e6cf76 Author: Cyrill Gorcunov Date: Sat Aug 16 23:21:55 2008 +0400 x86: apic - unify xapic_icr_read Signed-off-by: Cyrill Gorcunov Signed-off-by: Ingo Molnar commit 9c803869f5f5e3d7ad94b2926474b2882e30073b Author: Cyrill Gorcunov Date: Sat Aug 16 23:21:54 2008 +0400 x86: apic - unify lapic_is_integrated Signed-off-by: Cyrill Gorcunov Signed-off-by: Ingo Molnar commit 274cfe5912eebe9d4e1a4c451fe617289a181fcf Author: Cyrill Gorcunov Date: Sat Aug 16 23:21:53 2008 +0400 x86: apic - rearrange functions and comments Rearrange functions and comments to find differences easier. Also use apic_printk in setup_boot_APIC_clock for 64bit mode. Signed-off-by: Cyrill Gorcunov Signed-off-by: Ingo Molnar commit 24968cfdd4c3cf61338495dd0f9bb8a6907d2087 Author: Cyrill Gorcunov Date: Sat Aug 16 23:21:52 2008 +0400 x86: apic - unify lapic_suspend Signed-off-by: Cyrill Gorcunov Signed-off-by: Ingo Molnar commit 92206c909ad1d4f9c355b4842722d5a355d6b76b Author: Cyrill Gorcunov Date: Sat Aug 16 23:21:51 2008 +0400 x86: apic - unify lapic_resume Signed-off-by: Cyrill Gorcunov Signed-off-by: Ingo Molnar commit 6764014bc8bb4849f6a4f336477e873ad5861ed2 Author: Cyrill Gorcunov Date: Sat Aug 16 23:21:50 2008 +0400 x86: apic - unify clear_local_APIC - Remove redundant masking of APIC_LVTTHMR register in apic_32.c - Add masking of APIC_LVTTHMR register to apic_64.c. We use a bit complicated #ifdef here: CONFIG_X86_MCE_P4THERMAL is 32bit specific and X86_MCE_INTEL is 64bit specific so the appropriate config variable will be set by Kconfig. - the APIC_ESR register clearing in apic_64.c now uses not straightforward way but this is allowed tradeoff. Signed-off-by: Cyrill Gorcunov Signed-off-by: Ingo Molnar commit 7c516ee411f38cffbd4ab09b089c210202f9bd0f Author: Ingo Molnar Date: Sun Aug 17 12:18:01 2008 +0200 debug, x86: move BUILD_BUG_ON() and __FUNCTION__ move BUILD_BUG_ON variants and the __FUNCTION__ definition from kernel.h to compiler.h. Besides being the correct location for such trivial wrappers around compiler functionality, this also allows the removal of a duplicate (and now slighly incompatible) definition of BUILD_BUG_ON from arch/x86/boot/boot.h. [ boot.h cannot just include kernel.h to pick up the new definition of BUILD_BUG_ON(), as it is also built into user-space utilities on the host system. ] Signed-off-by: Ingo Molnar commit f5b5d41dd51a31fe70e3a04fb80a3b90b84c6a4e Author: Ingo Molnar Date: Sun Aug 17 11:58:58 2008 +0200 debug: fix BUILD_BUG_ON() for non-constant expressions constant expressions get detected at build time via: kernel/sched.c: In function ‘test': kernel/sched.c:9187: error: size of array ‘type name' is negative make[1]: *** [kernel/sched.o] Error 1 but non-constant expressions (for example BUILD_BUG_ON(variable)) simply get discarded by the compiler - turning BUILD_BUG_ON() into a dangerous construct. So add another layer at the link level to detect such mishaps: kernel/built-in.o: In function `test': : undefined reference to `__BUILD_BUG_ON_non_constant' Signed-off-by: Ingo Molnar commit 8ee991dd343df57910ff6947696afada9f02bf7e Author: Huang Weiyi Date: Sun Aug 17 07:50:44 2008 +0800 [MTD] removed unused #include The drivers below do not use LINUX_VERSION_CODE nor KERNEL_VERSION. drivers/mtd/maps/amd76xrom.c drivers/mtd/maps/ck804xrom.c drivers/mtd/maps/esb2rom.c This patch removes the said #include . Signed-off-by: Huang Weiyi Signed-off-by: David Woodhouse commit 6d341675f8e715464849e5d5563a72c1d39e800d Author: Marek Vašut Date: Sat Aug 16 15:35:57 2008 +0100 [ARM] 5199/1: PalmLD: PCMCIA driver PCMCIA driver for Palm LifeDrive Signed-off-by: Marek Vasut Signed-off-by: Russell King commit 638c0411922540deaf8797cacf73513b17618405 Author: Cyrill Gorcunov Date: Fri Aug 15 23:05:18 2008 +0400 x86: apic - unify init_bsp_APIC - remove redundant read of APIC_LVR register in 64bit mode - APIC is always integrated for 64bit mode so gcc will eliminate lapic_is_integrated call Signed-off-by: Cyrill Gorcunov Acked-by: Maciej W. Rozycki Signed-off-by: Ingo Molnar commit 6f6da97faf29f87b3980a6992fb8cab44b4c444d Author: Cyrill Gorcunov Date: Fri Aug 15 23:05:19 2008 +0400 x86: apic - sync_Arb_IDs style fixup No changes on binary level Signed-off-by: Cyrill Gorcunov Acked-by: Maciej W. Rozycki Signed-off-by: Ingo Molnar commit 6dad8e07f4c10b17b038e84d29f3ca41c2e55cd0 Author: Steven Rostedt Date: Fri Aug 15 21:40:05 2008 -0400 ftrace: add necessary locking for ftrace records The new design of pre-recorded mcounts and updating the code outside of kstop_machine has changed the way the records themselves are protected. This patch uses the ftrace_lock to protect the records. Note, the lock still does not need to be taken within calls that are only called via kstop_machine, since the that code can not run while the spin lock is held. Also removed the hash_lock needed for the daemon when MCOUNT_RECORD is configured. Also did a slight cleanup of an unused variable. Signed-off-by: Steven Rostedt Signed-off-by: Ingo Molnar commit fad615f891ed1ba6274fb34ca0e075ad331dc730 Author: Steven Rostedt Date: Fri Aug 15 21:40:04 2008 -0400 ftrace: do not init module on ftrace disabled If one of the self tests of ftrace has disabled the function tracer, do not run the code to convert the mcount calls in modules. Signed-off-by: Steven Rostedt Signed-off-by: Ingo Molnar commit ccbcd6cba5ef6e071deb072188ad044921f6b91e Author: David Woodhouse Date: Sat Aug 16 11:01:31 2008 +0100 [MTD] [NAND] Minor cleanup of nand_ecc.c Make the standalone stuff a little cleaner, fix some checkpatch warnings. Signed-off-by: David Woodhouse commit e6cf5df1838c28bb060ac45b5585e48e71bbc740 Author: frans Date: Fri Aug 15 23:14:31 2008 +0200 [MTD] [NAND] nand_ecc.c: rewrite for improved performance This patch improves the performance of the ecc generation code by a factor of 18 on an INTEL D920 CPU, a factor of 7 on MIPS and a factor of 5 on ARM (NSLU2) Signed-off-by: Frans Meulenbroeks Signed-off-by: David Woodhouse commit 924e61a90f61b1c22fcb51aaf3afc065399cec81 Author: Milan Broz Date: Sat Aug 16 02:11:28 2008 +0200 ACPI: Fix now signed module parameter. Signed-off-by: Milan Broz Signed-off-by: Andi Kleen commit 36b17da76d153673178e36ee44fba00ebbc6ea4d Author: Frédéric Weisbecker Date: Fri Aug 15 21:08:22 2008 +0200 ftrace: fix some mistakes in error messages This patch fixes some mistakes on the tracer in warning messages when debugfs fails to create tracing files. Signed-off-by: Frederic Weisbecker Cc: srostedt@redhat.com Signed-off-by: Ingo Molnar commit 5bbd4c3724008c93cf3efdfc38a3402e245ab506 Author: Mathieu Desnoyers Date: Fri Aug 15 12:56:59 2008 -0400 x86: spinlock use LOCK_PREFIX Since we are now using DS prefixes instead of NOP to remove LOCK prefixes, there is no longer any problems with instruction boundaries moving around. * Linus Torvalds (torvalds@linux-foundation.org) wrote: > > > On Thu, 14 Aug 2008, Mathieu Desnoyers wrote: > > > > Changing the 0x90 (single-byte nop) currently used into a 0x3E DS segment > > override prefix should fix this issue. Since the default of the atomic > > instructions is to use the DS segment anyway, it should not affect the > > behavior. > > Ok, so I think this is an _excellent_ patch, but I'd like to also then use > LOCK_PREFIX in include/asm-x86/futex.h. > > See commit 9d55b9923a1b7ea8193b8875c57ec940dc2ff027. > > Linus Unless there a rationale for this, I think these be changed to LOCK_PREFIX too. grep "lock ;" include/asm-x86/spinlock.h "lock ; cmpxchgw %w1,%2\n\t" asm volatile("lock ; xaddl %0, %1\n" "lock ; cmpxchgl %1,%2\n\t" Applies to 2.6.27-rc2. Signed-off-by: Mathieu Desnoyers Acked-by: Linus Torvalds CC: Linus Torvalds CC: H. Peter Anvin CC: Jeremy Fitzhardinge CC: Roland McGrath CC: Ingo Molnar Cc: Steven Rostedt CC: Steven Rostedt CC: Thomas Gleixner CC: Peter Zijlstra CC: Andrew Morton CC: David Miller CC: Ulrich Drepper CC: Rusty Russell CC: Gregory Haskins CC: Arnaldo Carvalho de Melo CC: "Luis Claudio R. Goncalves" CC: Clark Williams CC: Christoph Lameter CC: Andi Kleen CC: Harvey Harrison Signed-off-by: H. Peter Anvin commit 1f49a2c2aeb22d5abc6d4ea574ff63d37ca55fbe Author: Mathieu Desnoyers Date: Fri Aug 15 12:45:09 2008 -0400 x86: revert replace LOCK_PREFIX in futex.h Since we now use DS prefixes instead of NOP to remove LOCK prefixes, there are no longer any issues with instruction boundaries moving around. Depends on : x86 alternatives : fix LOCK_PREFIX race with preemptible kernel and CPU hotplug On Thu, 14 Aug 2008, Mathieu Desnoyers wrote: > > Changing the 0x90 (single-byte nop) currently used into a 0x3E DS segment > override prefix should fix this issue. Since the default of the atomic > instructions is to use the DS segment anyway, it should not affect the > behavior. Ok, so I think this is an _excellent_ patch, but I'd like to also then use LOCK_PREFIX in include/asm-x86/futex.h. See commit 9d55b9923a1b7ea8193b8875c57ec940dc2ff027. Linus Applies to 2.6.27-rc2 (and -rc3 unless hell broke loose in futex.h between rc2 and rc3). Signed-off-by: Mathieu Desnoyers CC: Linus Torvalds CC: H. Peter Anvin CC: Jeremy Fitzhardinge CC: Roland McGrath CC: Ingo Molnar Cc: Steven Rostedt CC: Steven Rostedt CC: Thomas Gleixner CC: Peter Zijlstra CC: Andrew Morton CC: David Miller CC: Ulrich Drepper CC: Rusty Russell CC: Gregory Haskins CC: Arnaldo Carvalho de Melo CC: "Luis Claudio R. Goncalves" CC: Clark Williams CC: Christoph Lameter CC: Andi Kleen CC: Harvey Harrison Signed-off-by: H. Peter Anvin commit f88f07e0f0fd6376e081b10930d272a08fbf082f Author: Mathieu Desnoyers Date: Thu Aug 14 16:58:15 2008 -0400 x86: alternatives : fix LOCK_PREFIX race with preemptible kernel and CPU hotplug If a kernel thread is preempted in single-cpu mode right after the NOP (nop about to be turned into a lock prefix), then we CPU hotplug a CPU, and then the thread is scheduled back again, a SMP-unsafe atomic operation will be used on shared SMP variables, leading to corruption. No corruption would happen in the reverse case : going from SMP to UP is ok because we split a bit instruction into tiny pieces, which does not present this condition. Changing the 0x90 (single-byte nop) currently used into a 0x3E DS segment override prefix should fix this issue. Since the default of the atomic instructions is to use the DS segment anyway, it should not affect the behavior. The exception to this are references that use ESP/RSP and EBP/RBP as the base register (they will use the SS segment), however, in Linux (a) DS == SS at all times, and (b) we do not distinguish between segment violations reported as #SS as opposed to #GP, so there is no need to disassemble the instruction to figure out the suitable segment. This patch assumes that the 0x3E prefix will leave atomic operations as-is (thus assuming they normally touch data in the DS segment). Since there seem to be no obvious ill-use of other segment override prefixes for atomic operations, it should be safe. It can be verified with a quick grep -r LOCK_PREFIX include/asm-x86/ grep -A 1 -r LOCK_PREFIX arch/x86/ Taken from This source : AMD64 Architecture Programmer's Manual Volume 3: General-Purpose and System Instructions States "Instructions that Reference a Non-Stack Segment—If an instruction encoding references any base register other than rBP or rSP, or if an instruction contains an immediate offset, the default segment is the data segment (DS). These instructions can use the segment-override prefix to select one of the non-default segments, as shown in Table 1-5." Therefore, forcing the DS segment on the atomic operations, which already use the DS segment, should not change. This source : http://wiki.osdev.org/X86_Instruction_Encoding States "In 64-bit the CS, SS, DS and ES segment overrides are ignored." Confirmed by "AMD 64-Bit Technology" A.7 http://www.amd.com/us-en/assets/content_type/white_papers_and_tech_docs/x86-64_overview.pdf "In 64-bit mode, the DS, ES, SS and CS segment-override prefixes have no effect. These four prefixes are no longer treated as segment-override prefixes in the context of multipleprefix rules. Instead, they are treated as null prefixes." This patch applies to 2.6.27-rc2, but would also have to be applied to earlier kernels (2.6.26, 2.6.25, ...). Performance impact of the fix : tests done on "xaddq" and "xaddl" shows it actually improves performances on Intel Xeon, AMD64, Pentium M. It does not change the performance on Pentium II, Pentium 3 and Pentium 4. Xeon E5405 2.0GHz : NR_TESTS 10000000 test empty cycles : 162207948 test test 1-byte nop xadd cycles : 170755422 test test DS override prefix xadd cycles : 170000118 * test test LOCK xadd cycles : 472012134 AMD64 2.0GHz : NR_TESTS 10000000 test empty cycles : 146674549 test test 1-byte nop xadd cycles : 150273860 test test DS override prefix xadd cycles : 149982382 * test test LOCK xadd cycles : 270000690 Pentium 4 3.0GHz NR_TESTS 10000000 test empty cycles : 290001195 test test 1-byte nop xadd cycles : 310000560 test test DS override prefix xadd cycles : 310000575 * test test LOCK xadd cycles : 1050103740 Pentium M 2.0GHz NR_TESTS 10000000 test empty cycles : 180000523 test test 1-byte nop xadd cycles : 320000345 test test DS override prefix xadd cycles : 310000374 * test test LOCK xadd cycles : 480000357 Pentium 3 550MHz NR_TESTS 10000000 test empty cycles : 510000231 test test 1-byte nop xadd cycles : 620000128 test test DS override prefix xadd cycles : 620000110 * test test LOCK xadd cycles : 800000088 Pentium II 350MHz NR_TESTS 10000000 test empty cycles : 200833494 test test 1-byte nop xadd cycles : 340000130 test test DS override prefix xadd cycles : 340000126 * test test LOCK xadd cycles : 530000078 Speed test modules can be found at http://ltt.polymtl.ca/svn/trunk/tests/kernel/test-prefix-speed-32.c http://ltt.polymtl.ca/svn/trunk/tests/kernel/test-prefix-speed.c Macro-benchmarks 2.0GHz E5405 Core 2 dual Quad-Core Xeon Summary * replace smp lock prefixes with DS segment selector prefixes no lock prefix (s) with lock prefix (s) Speedup make -j1 kernel/ 33.94 +/- 0.07 34.91 +/- 0.27 2.8 % hackbench 50 2.99 +/- 0.01 3.74 +/- 0.01 25.1 % * replace smp lock prefixes with 0x90 nops no lock prefix (s) with lock prefix (s) Speedup make -j1 kernel/ 34.16 +/- 0.32 34.91 +/- 0.27 2.2 % hackbench 50 3.00 +/- 0.01 3.74 +/- 0.01 24.7 % Detail : 1 CPU, replace smp lock prefixes with DS segment selector prefixes make -j1 kernel/ real 0m34.067s user 0m30.630s sys 0m2.980s real 0m33.867s user 0m30.582s sys 0m3.024s real 0m33.939s user 0m30.738s sys 0m2.876s real 0m33.913s user 0m30.806s sys 0m2.808s avg : 33.94s std. dev. : 0.07s hackbench 50 Time: 2.978 Time: 2.982 Time: 3.010 Time: 2.984 Time: 2.982 avg : 2.99 std. dev. : 0.01 1 CPU, noreplace-smp make -j1 kernel/ real 0m35.326s user 0m30.630s sys 0m3.260s real 0m34.325s user 0m30.802s sys 0m3.084s real 0m35.568s user 0m30.722s sys 0m3.168s real 0m34.435s user 0m30.886s sys 0m2.996s avg.: 34.91s std. dev. : 0.27s hackbench 50 Time: 3.733 Time: 3.750 Time: 3.761 Time: 3.737 Time: 3.741 avg : 3.74 std. dev. : 0.01 1 CPU, replace smp lock prefixes with 0x90 nops make -j1 kernel/ real 0m34.139s user 0m30.782s sys 0m2.820s real 0m34.010s user 0m30.630s sys 0m2.976s real 0m34.777s user 0m30.658s sys 0m2.916s real 0m33.924s user 0m30.634s sys 0m2.924s real 0m33.962s user 0m30.774s sys 0m2.800s real 0m34.141s user 0m30.770s sys 0m2.828s avg : 34.16 std. dev. : 0.32 hackbench 50 Time: 2.999 Time: 2.994 Time: 3.004 Time: 2.991 Time: 2.988 avg : 3.00 std. dev. : 0.01 I did more runs (20 runs of each) to compare the nop case to the DS prefix case. Results in seconds. They actually does not seems to show a significant difference. NOP 34.155 33.955 34.012 35.299 35.679 34.141 33.995 35.016 34.254 33.957 33.957 34.008 35.013 34.494 33.893 34.295 34.314 34.854 33.991 34.132 DS 34.080 34.304 34.374 35.095 34.291 34.135 33.940 34.208 35.276 34.288 33.861 33.898 34.610 34.709 33.851 34.256 35.161 34.283 33.865 35.078 Used http://www.graphpad.com/quickcalcs/ttest1.cfm?Format=C to do the T-test (yeah, I'm lazy) : Group Group One (DS prefix) Group Two (nops) Mean 34.37815 34.37070 SD 0.46108 0.51905 SEM 0.10310 0.11606 N 20 20 P value and statistical significance: The two-tailed P value equals 0.9620 By conventional criteria, this difference is considered to be not statistically significant. Confidence interval: The mean of Group One minus Group Two equals 0.00745 95% confidence interval of this difference: From -0.30682 to 0.32172 Intermediate values used in calculations: t = 0.0480 df = 38 standard error of difference = 0.155 So, unless these calculus are completely bogus, the difference between the nop and the DS case seems not to be statistically significant. Signed-off-by: Mathieu Desnoyers Acked-by: H. Peter Anvin CC: Linus Torvalds CC: Jeremy Fitzhardinge CC: Roland McGrath CC: Ingo Molnar Cc: Steven Rostedt CC: Steven Rostedt CC: Thomas Gleixner CC: Peter Zijlstra CC: Andrew Morton CC: David Miller CC: Ulrich Drepper CC: Rusty Russell CC: Gregory Haskins CC: Arnaldo Carvalho de Melo CC: "Luis Claudio R. Goncalves" CC: Clark Williams CC: Christoph Lameter CC: Andi Kleen CC: Harvey Harrison Signed-off-by: H. Peter Anvin commit 9c7138be4c67acbc59264d31980c76038c277d98 Author: Jeff Layton Date: Wed Aug 13 22:03:27 2008 -0400 knfsd: allocate readahead cache in individual chunks I had a report from someone building a large NFS server that they were unable to start more than 585 nfsd threads. It was reported against an older kernel using the slab allocator, and I tracked it down to the large allocation in nfsd_racache_init failing. It appears that the slub allocator handles large allocations better, but large contiguous allocations can often be problematic. There doesn't seem to be any reason that the racache has to be allocated as a single large chunk. This patch breaks this up so that the racache is built up from separate allocations. (Thanks also to Takashi Iwai for a bugfix.) Signed-off-by: Jeff Layton Signed-off-by: J. Bruce Fields Cc: Takashi Iwai commit a3222138d3820eb8000d2e49ce3f0ffad62b8ae8 Author: Matthew Garrett Date: Fri Aug 15 13:54:51 2008 -0400 Input: atkbd - expand Latitude's force release quirk to other Dells Dell laptops fail to send key up events for several of their special keys. There's an existing quirk in the kernel to handle this, but it's limited to the Latitude range. This patch extends it to cover all portable Dells. Signed-off-by: Matthew Garrett Signed-off-by: Dmitry Torokhov commit 9441194af77e991d6546f37d96007597d44ebab5 Author: Michael Hennerich Date: Fri Aug 15 13:53:08 2008 -0400 Input: bf54x-keys - add power management support Fix Bug: does nor properply resume after suspend mem Fix for PM_SUSPEND_MEM: Save and restore peripheral base registers Signed-off-by: Michael Hennerich Signed-off-by: Bryan Wu Signed-off-by: Dmitry Torokhov commit 8abfb10f9191210a15baa25b142862a4ab7bf3e3 Author: Ingo Molnar Date: Mon Jun 9 20:54:22 2008 +0200 ftrace: scripts/recordmcount.pl cross-build hack hack around: ld: Relocatable linking with relocations from format elf32-i386 (init/.tmp_gl_calibrate.o) to format elf64-x86-64 (init/.tmp_mx_calibrate.o) i CC arch/x86/mm/extable.o objcopy: 'init/.tmp_mx_calibrate.o': No such file rm: cannot remove `init/.tmp_mx_calibrate.o': No such file or directory ld: Relocatable linking with relocations from format elf32-i386 (arch/x86/mm/extable.o) to format elf64-x86-64 (arch/x86/mm/.tmp_mx_extable.o) is not supported mv: cannot stat `arch/x86/mm/.tmp_mx_extable.o': No such file or directory ld: Relocatable linking with relocations from format elf32-i386 (arch/x86/mm/fault.o) to format elf64-x86-64 (arch/x86/mm/.tmp_mx_fault.o) is not supported Signed-off-by: Ingo Molnar commit dc4e138ec01b319a6ca5b315c83e2095be195c9c Author: Ingo Molnar Date: Fri Aug 15 18:22:09 2008 +0200 ftrace: ftrace_kill_atomic() build fix fix: kernel/built-in.o: In function `ftrace_dump': (.text+0x2e2ea): undefined reference to `ftrace_kill_atomic' Signed-off-by: Ingo Molnar commit 48e2bd56b1d1ae4b95fb21be778927b64d5c4235 Author: Gustavo F. Padovan Date: Sat Aug 2 12:50:37 2008 -0300 x86: coding style fixes to arch/x86/kernel/traps_64.c Fix coding style of traps_64.c with improvements suggested by Ingo. Signed-off-by: Gustavo F. Padovan Signed-off-by: Ingo Molnar commit 5802294f1b1895ee19a3d0ae72805da453afb9de Author: Steven Rostedt Date: Wed Jul 30 14:20:55 2008 -0400 rcu: trace fix possible mem-leak In the initialization of the RCU trace module, if rcupreempt_debugfs_init() fails, we never free the the trace buffer. This patch frees the trace buffer in case the debugfs fails. Signed-off-by: Steven Rostedt Reviewed-by: "Paul E. McKenney" Signed-off-by: Ingo Molnar commit dd0078f4f04d939950a792c493d7d97d7ce663b8 Author: Steven Rostedt Date: Wed Jul 30 14:20:54 2008 -0400 rcu: just rename call_rcu_bh instead of making it a macro Seems that I found a box that has a config that passes call_rcu_bh as a function pointer (see net/sctp/sm_make_chunk.c), so declaring the call_rcu_bh has a macro function isn't good enough. This patch makes it just another name of call_rcu for rcupreempt. Signed-off-by: Steven Rostedt Reviewed-by: "Paul E. McKenney" Signed-off-by: Ingo Molnar commit cee4ee678cec2947f7035d00bcba23a31da4fc3c Author: Ingo Molnar Date: Fri Aug 15 17:48:02 2008 +0200 ftrace: build fix fix: In file included from init/main.c:65: include/linux/ftrace.h:166: error: expected ‘,' or ‘;' before ‘{' token make[1]: *** [init/main.o] Error 1 make: *** [init/main.o] Error 2 Signed-off-by: Ingo Molnar commit 66b1d2bf314d8f3ed96541802e772e672f225693 Author: Steven Rostedt Date: Wed Jul 30 22:36:46 2008 -0400 ftrace: dump out ftrace buffers to console on panic At OLS I had a lot of interest to be able to have the ftrace buffers dumped on panic. Usually one would expect to uses kexec and examine the buffers after a new kernel is loaded. But sometimes the resources do not permit kdump and kexec, so having an option to still see the sequence of events up to the crash is very advantageous. This patch adds the option to have the ftrace buffers dumped to the console in the latency_trace format on a panic. When the option is set, the default entries per CPU buffer are lowered to 16384, since the writing to the serial (if that is the console) may take an awful long time otherwise. [ Changes since -v1: Got alpine to send correctly (as well as spell check working). Removed config option. Moved the static variables into ftrace_dump itself. Gave printk a log level. ] Signed-off-by: Steven Rostedt Cc: Peter Zijlstra Signed-off-by: Ingo Molnar commit 0685ea2da91f63ac141af9a8c2542ef1b0d12ee9 Author: Mark Brown Date: Fri Aug 15 16:22:33 2008 +0100 ALSA: wm8990: Implement speaker volume PGA The latest revisions of the WM8990 provide a programmable gain amplifier for the speaker - configure the register cache and implement controls for this. Older revisions of the device ignore writes to these controls. Signed-off-by: Mark Brown Signed-off-by: Takashi Iwai commit 032d4e99f40e5f536d0e45fa3fbd48f81359b928 Author: Mark Brown Date: Fri Aug 15 16:22:32 2008 +0100 ALSA: wm8990: Fix routing of left DAC to speaker mixer Signed-off-by: Mark Brown Signed-off-by: Takashi Iwai commit c9c3dddd8f9a05b25d4ce53e8e80cc0ea1759d18 Author: Alexey Dobriyan Date: Fri Aug 1 03:51:38 2008 +0400 x86_64: remove empty lines from stack traces/oopses Signed-off-by: Alexey Dobriyan Cc: ak@suse.de Cc: akpm@osdl.org Signed-off-by: Ingo Molnar commit 5843d9a4d0ba89719916c8f07fc9c57b7126be6d Author: Nick Piggin Date: Fri Aug 1 03:15:21 2008 +0200 x86, pat: avoid highmem cache attribute aliasing Highmem code can leave ptes and tlb entries around for a given page even after kunmap, and after it has been freed. >From what I can gather, the PAT code may change the cache attributes of arbitrary physical addresses (ie. including highmem pages), which would result in aliases in the case that it operates on one of these lazy tlb highmem pages. Flushing kmaps should solve the problem. I've also just added code for conditional flushing if we haven't got any dangling highmem aliases -- this should help performance if we change page attributes frequently or systems that aren't using much highmem pages (eg. if < 4G RAM). Should be turned into 2 patches, but just for RFC... Signed-off-by: Ingo Molnar commit 636a31781684d0f49208aa163f1a5a3a74210eb4 Author: Peter Oruba Date: Fri Aug 1 12:46:46 2008 +0200 x86: Fixed NULL function pointer dereference in AMD microcode patch loader. Dereference took place in code part responsible for manual installation of microcode patches through /dev/cpu/microcode. Signed-off-by: Peter Oruba Cc: Peter Oruba Cc: Tigran Aivazian Signed-off-by: Ingo Molnar commit d33dcb9e7d272cc3171dcc3a21049902185ab03d Author: Peter Oruba Date: Fri Aug 1 12:46:45 2008 +0200 x86: Microcode patch loader style corrections Style corrections to main microcode module. Signed-off-by: Peter Oruba Cc: Peter Oruba Cc: Tigran Aivazian Signed-off-by: Ingo Molnar commit 3fb669dd6ec11e14819c0114a0e68a9ddcec65e1 Author: Richard Kennedy Date: Fri Aug 1 13:36:28 2008 +0100 reorder struct prop_local_single to remove padding on 64 bit builds reorder structure to remove 8 bytes of padding on 64 bit builds (also removes 8 bytes from task_struct) Signed-off-by: Richard Kennedy Cc: peterz@infradead.org Signed-off-by: Ingo Molnar commit bee367ed066e26c14263d808136fba8eec3bd70a Author: Richard Kennedy Date: Fri Aug 1 13:24:08 2008 +0100 sched: reorder struct sched_rt_entity to remove padding on 64 bit builds remove 8 bytes of padding on 64 bit builds (also removes 8 bytes from task_struct) Signed-off-by: Richard Kennedy Signed-off-by: Ingo Molnar commit 07dd20e0324f4d3e33bde1944d4f7771a09c498c Author: Richard Kennedy Date: Fri Aug 1 13:18:04 2008 +0100 sched: reorder signal_struct to remove 8 bytes on 64 bit builds reorder structure to remove 8 bytes of padding on 64 bit builds Signed-off-by: Richard Kennedy Signed-off-by: Ingo Molnar commit 34d7c2b38d124219b7034356716e3455c439acd3 Author: Paul E. McKenney Date: Fri Aug 1 14:11:05 2008 -0700 rcu: remove list_for_each_rcu() All of the in-tree uses of list_for_each_rcu() have been converted to list_for_each_entry_rcu(), so list_for_each_rcu() can now be removed. Signed-off-by: Paul E. McKenney Signed-off-by: Ingo Molnar commit ff9cf2ce7afe76435d66c898cc9dacaa68e79d41 Author: Paul E. McKenney Date: Fri Aug 1 14:10:02 2008 -0700 rcu: fixes to include/linux/rcupreempt.h Hello! Compared tip/core/rcu to my latest patchset, and found the following issues: o the memory barrier in rcu_exit_nohz() somehow got out of place (it is correct in mainline as of 2.6.26-rc7). o There is a duplicate declaration of rcu_dyntick_sched. The attached patch fixes these. Signed-off-by: Paul E. McKenney Signed-off-by: Ingo Molnar commit c874e57d887dceb4c42a0f9196c255e2687adbba Author: Steven Rostedt Date: Fri Aug 1 16:45:49 2008 -0400 ftrace: ftrace_printk doc moved Based on Randy Dunlap's suggestion, the ftrace_printk kernel-doc belongs with the ftrace_printk macro that should be used. Not with the __ftrace_printk internal function. Signed-off-by: Steven Rostedt Acked-by: Randy Dunlap Signed-off-by: Ingo Molnar commit eecffb194c1ef33b3c05ac5e404c43d09556a684 Author: Steven Rostedt Date: Fri Aug 1 12:26:41 2008 -0400 ftrace: printk formatting infrastructure This patch adds a feature that can help kernel developers debug their code using ftrace. int ftrace_printk(const char *fmt, ...); This records into the ftrace buffer using printf formatting. The entry size in the buffers are still a fixed length. A new type has been added that allows for more entries to be used for a single recording. The start of the print is still the same as the other entries. It returns the number of characters written to the ftrace buffer. For example: Having a module with the following code: static int __init ftrace_print_test(void) { ftrace_printk("jiffies are %ld\n", jiffies); return 0; } Gives me: insmod-5441 3...1 7569us : ftrace_print_test: jiffies are 4296626666 for the latency_trace file and: insmod-5441 [03] 1959.370498: ftrace_print_test jiffies are 4296626666 for the trace file. Note: Only the infrastructure should go into the kernel. It is to help facilitate debugging for other kernel developers. Calls to ftrace_printk is not intended to be left in the kernel, and should be frowned upon just like scattering printks around in the code. But having this easily at your fingertips helps the debugging go faster and bugs be solved quicker. Maybe later on, we can hook this with markers and have their printf format be sucked into ftrace output. Signed-off-by: Steven Rostedt Signed-off-by: Ingo Molnar commit 0cf69cfcc4aaab27dbf01b820f0ff0333180e6d3 Author: Steven Rostedt Date: Fri Aug 1 12:26:40 2008 -0400 ftrace: new continue entry - separate out from trace_entry Some tracers will need to work with more than one entry. In order to do this the trace_entry structure was split into two fields. One for the start of all entries, and one to continue an existing entry. The trace_entry structure now has a "field" entry that consists of the previous content of the trace_entry, and a "cont" entry that is just a string buffer the size of the "field" entry. Thanks to Andrew Morton for suggesting this idea. Signed-off-by: Steven Rostedt Signed-off-by: Ingo Molnar commit d9336a9b47d57db835453968efbd0d5cedfe0260 Author: Paolo Ciarrocchi Date: Sat Aug 2 21:25:43 2008 +0200 x86: coding style fixes to arch/x86/kernel/paravirt_patch_32.c Before: total: 3 errors, 1 warnings, 49 lines checked After: total: 2 errors, 1 warnings, 49 lines checked paolo@paolo-desktop:~/linux.trees.git$ md5sum /tmp/paravirt_patch_32.o.* a78eea4264723e18c49dcfbe0ee0aae7 /tmp/paravirt_patch_32.o.after a78eea4264723e18c49dcfbe0ee0aae7 /tmp/paravirt_patch_32.o.before Signed-off-by: Paolo Ciarrocchi Signed-off-by: Ingo Molnar commit 3492cdf0176bde5e35223a1388d59676bc67c145 Author: Paolo Ciarrocchi Date: Sat Aug 2 21:25:13 2008 +0200 x86: coding style fixes to arch/x86/lib/string_32.c Before: total: 21 errors, 0 warnings, 237 lines checked After: total: 0 errors, 0 warnings, 237 lines checked paolo@paolo-desktop:~/linux.trees.git$ md5sum /tmp/string_32.o.* c55d059ef1612b32a8bb2771a72ae0d5 /tmp/string_32.o.after c55d059ef1612b32a8bb2771a72ae0d5 /tmp/string_32.o.before Signed-off-by: Paolo Ciarrocchi Signed-off-by: Ingo Molnar commit 209b580fd8c3a42b69550c98de434671d41a4ebb Author: Paolo Ciarrocchi Date: Sat Aug 2 21:24:45 2008 +0200 x86: coding style fixes to arch/x86/lib/strstr_32.c Before: total: 3 errors, 0 warnings, 31 lines checked After: total: 0 errors, 0 warnings, 31 lines checked paolo@paolo-desktop:~/linux.trees.git$ md5sum /tmp/strstr_32.o.* c96006ec3387862e5bacb139207a3098 /tmp/strstr_32.o.after c96006ec3387862e5bacb139207a3098 /tmp/strstr_32.o.before Signed-off-by: Paolo Ciarrocchi Signed-off-by: Ingo Molnar commit 2070dae10f50ec244f58292436ace9a3f9dc1d71 Author: Paolo Ciarrocchi Date: Sat Aug 2 21:24:06 2008 +0200 x86: coding style fixes to arch/x86/kernel/bios_uv.c paolo@paolo-desktop:~/linux.trees.git$ md5sum /tmp/bios_uv.o.* 9afe794594831166704744184e192ed8 /tmp/bios_uv.o.after 9afe794594831166704744184e192ed8 /tmp/bios_uv.o.before Signed-off-by: Paolo Ciarrocchi Signed-off-by: Ingo Molnar commit 020878ac427aa053414602cef975c2b5a2e33bf8 Author: Paolo Ciarrocchi Date: Sat Aug 2 21:23:36 2008 +0200 x86: coding style fixes to arch/x86/boot/compressed/misc.c Before: total: 4 errors, 6 warnings, 439 lines checked After: total: 1 errors, 5 warnings, 441 lines checked Before -#include +#include paolo@paolo-desktop:~/linux.trees.git$ md5sum /tmp/misc.o.* 8b2394e1fe519a9542e9a7e3e7b69c39 /tmp/misc.o.after 8b2394e1fe519a9542e9a7e3e7b69c39 /tmp/misc.o.before After -#include +#include paolo@paolo-desktop:~/linux.trees.git$ md5sum /tmp/misc.o.* 59a2d264284be5e72b5af4f3a8ccfb47 /tmp/misc.o.after 8b2394e1fe519a9542e9a7e3e7b69c39 /tmp/misc.o.before Signed-off-by: Paolo Ciarrocchi Signed-off-by: Ingo Molnar commit 2bd455dbfebfd632a8dcf1d3d1612737986fde0a Author: Li Zefan Date: Mon Aug 4 11:26:38 2008 +0800 x86: remove nesting CONFIG_HOTPLUG_CPU prefill_possible_map() is defined inside CONFIG_HOTPLUG_CPU, so the nesting CONFIG_HOTPLUG_CPU is just redundant. Signed-off-by: Li Zefan Signed-off-by: Ingo Molnar commit 466ae837424dcc538b1af2a0eaf53be32edcdbe7 Author: Shaohua Li Date: Mon Aug 4 14:51:30 2008 +0800 reduce tlb/cache flush times of agpgart memory allocation To reduce tlb/cache flush, makes agp memory allocation do one flush after all pages in a region are changed to uc. All agp drivers except agp-sgi uses agp_generic_alloc_page() for .agp_alloc_page, so the patch should work for them. agp-sgi is only for ia64, so not a problem too. Signed-off-by: Shaohua Li Cc: airlied@linux.ie Cc: Andrew Morton Cc: Arjan van de Ven Signed-off-by: Ingo Molnar commit 1ac2f7d55b7ee1613c90631e87fea22ec06781e5 Author: Shaohua Li Date: Mon Aug 4 14:51:24 2008 +0800 introduce two APIs for page attribute Introduce two APIs for page attribute. flushing tlb/cache in every page attribute is expensive. AGP gart usually will do a lot of operations to change a page to uc, new APIs can reduce flush. Signed-off-by: Shaohua Li Cc: airlied@linux.ie Cc: Andrew Morton Cc: Arjan van de Ven Signed-off-by: Ingo Molnar commit 516cbf3730c49739629d66313b20bdc50c98aa2c Author: Tim Bird Date: Tue Aug 12 12:52:36 2008 -0700 x86, bootup: add built-in kernel command line for x86 (v2) Allow x86 to support a built-in kernel command line. The built-in command line can override the one provided by the boot loader, for those cases where the boot loader is broken or it is difficult to change the command line in the the boot loader. H. Peter Anvin wrote: > Ingo Molnar wrote: >> Best would be to make it really apparent in the code that nothing >> changes if this config option is not set. Preferably there should be >> no extra code at all in that case. >> > > I would like to see this: [...Nested ifdefs...] OK. This version changes absolutely nothing if CONFIG_CMDLINE_BOOL is not set (the default). Also, no space is appended even when CONFIG_CMDLINE_BOOL is set, but the builtin string is empty. This is less sloppy all the way around, IMHO. Note that I use the same option names as on other arches for this feature. [ mingo@elte.hu: build fix ] Signed-off-by: Tim Bird Cc: Matt Mackall Signed-off-by: Ingo Molnar commit 1f7b94cd3d564901f9e04a8bc5832ae7bfd690a0 Author: Paul E. McKenney Date: Tue Aug 5 09:21:44 2008 -0700 rcu: classic RCU locking and memory-barrier cleanups This patch simplifies the locking and memory-barrier usage in the Classic RCU grace-period-detection mechanism, incorporating Lai Jiangshan's feedback from the earlier version (http://lkml.org/lkml/2008/8/1/400 and http://lkml.org/lkml/2008/8/3/43). Passed 10 hours of rcutorture concurrent with CPUs being put online and taken offline on a 128-hardware-thread Power machine. My apologies to whoever in the Eastern Hemisphere was planning to use this machine over the Western Hemisphere night, but it was sitting idle and... So this is ready for tip/core/rcu. This patch is in preparation for moving to a hierarchical algorithm to allow the very large SMP machines -- requested by some people at OLS, and there seem to have been a few recent patches in the 4096-CPU direction as well. The general idea is to move to a much more conservative concurrency design, then apply a hierarchy to reduce contention on the global lock by a few orders of magnitude (larger machines would see greater reductions). The reason for taking a conservative approach is that this code isn't on any fast path. Prototype in progress. This patch is against the linux-tip git tree (tip/core/rcu). If you wish to test this against 2.6.26, use the following set of patches: http://www.rdrop.com/users/paulmck/patches/2.6.26-ljsimp-1.patch http://www.rdrop.com/users/paulmck/patches/2.6.26-ljsimpfix-3.patch The first patch combines commits 5127bed588a2f8f3a1f732de2a8a190b7df5dce3 and 3cac97cbb14aed00d83eb33d4613b0fe3aaea863 from Lai Jiangshan , and the second patch contains my changes. Signed-off-by: Paul E. McKenney Signed-off-by: Ingo Molnar commit 293a17ebc944c958e24e6ffbd1d5a49abdbf489e Author: Paul E. McKenney Date: Tue Aug 12 17:25:03 2008 -0700 rcu: prevent console flood when one CPU sees another AWOL via RCU One small change needed to keep from flooding the console when one CPU notices that another is AWOL. Unless I am missing something subtle. Otherwise the cleanups look good! Signed-off-by: Paul E. McKenney Signed-off-by: Ingo Molnar commit 2da8377fe924a17ed666edff945854f001d3393d Author: Jaroslav Kysela Date: Fri Aug 15 13:33:10 2008 +0200 ALSA: release v1.0.18rc1 Signed-off-by: Jaroslav Kysela Signed-off-by: Takashi Iwai commit 9ce38cbd47c2fda452efab6292500a045af46ca8 Author: Jaroslav Kysela Date: Fri Aug 15 12:59:02 2008 +0200 ALSA: dummy driver - do not use assignment in if condition checkpatch.pl does not like assignment in if condition Signed-off-by: Jaroslav Kysela Signed-off-by: Takashi Iwai commit 84571e9036fd8f2dd20f53fd4f6b83758932b9de Author: Daniel THOMPSON Date: Fri Aug 15 10:53:38 2008 +0100 sound: Fix esoteric double free in the dummy sound driver. The dummy driver uses runtime->private_free but still frees its pcm structures on error paths. This is esoteric because the error paths in question are unreachable. Thus the bug is only a problem when someone copies this code into other drivers. Signed-off-by: Daniel R Thompson Signed-off-by: Jaroslav Kysela Signed-off-by: Takashi Iwai commit 296cb9511dcc3895fda84d0cd5b411bd926e4bb3 Author: Cyrill Gorcunov Date: Fri Aug 15 13:51:23 2008 +0200 x86: apic - unify sync_Arb_IDs Signed-off-by: Cyrill Gorcunov Signed-off-by: Ingo Molnar commit c93baa1ae51cdba25a5f5ad37b2348e700e75daf Author: Cyrill Gorcunov Date: Fri Aug 15 13:51:22 2008 +0200 x86: apic - unify verify_local_APIC Signed-off-by: Cyrill Gorcunov Signed-off-by: Ingo Molnar commit 64e474d168e3cf31e44890b4947644d361f84e43 Author: Cyrill Gorcunov Date: Fri Aug 15 13:51:22 2008 +0200 x86: apic - get rid of local_apic_timer_verify_ok We are able to use clock_event_device as it's done in 64bit apic code so lets get rid of local_apic_timer_verify_ok variable. Signed-off-by: Cyrill Gorcunov Signed-off-by: Ingo Molnar commit 9ce122c6e55c44ae9a4c4c777579b87d83e7f898 Author: Cyrill Gorcunov Date: Fri Aug 15 13:51:21 2008 +0200 x86: apic - do not clear APIC twice in lapic_shutdown There is no need to clear APIC twice since disable_local_APIC will clear it anyway. Signed-off-by: Cyrill Gorcunov Signed-off-by: Ingo Molnar commit f07f4f9046121ac803bc2f0ded3d77b7c2ab481b Author: Cyrill Gorcunov Date: Fri Aug 15 13:51:21 2008 +0200 x86: apic - unify __setup_APIC_LVTT To be able to unify this function we RE-introduce APIC_DIVISOR for 64bit mode. This snipped was eliminated in some time ago in a sake of clenup but now we need it again since it allow up to get rid of #ifdef(s). And lapic_is_integrated call is added in apic_64.c but since we always have APIC integrated on 64bit cpu compiler will ignore this call. Signed-off-by: Cyrill Gorcunov Signed-off-by: Ingo Molnar commit 36fef0949c14445d231a68663e8a01860f7caca3 Author: Cyrill Gorcunov Date: Fri Aug 15 13:51:20 2008 +0200 x86: apic - unify disable_apic_timer Get rid of local_apic_timer_disabled and use disable_apic_timer instead. Signed-off-by: Cyrill Gorcunov Signed-off-by: Ingo Molnar commit ed4e5ec177d20504c51aebb93db12d57716cde9c Author: Cyrill Gorcunov Date: Fri Aug 15 13:51:20 2008 +0200 x86: apic - use SET_APIC_DEST_FIELD instead of hardcoded shift Signed-off-by: Cyrill Gorcunov Signed-off-by: Ingo Molnar commit b76d69ed721e8365739c3bd5dd7891efbea88494 Author: Hiroshi Shimamoto Date: Thu Aug 14 17:25:37 2008 -0700 x86_64: uml: fix rename header guard In unistd_64.h, the guard macro _ASM_X86_64_UNISTD_H_ is renamed to ASM_X86__UNISTD_64_H. This change should be applied to arch/um/sys-x86_64/syscall_table.c. Signed-off-by: Hiroshi Shimamoto Signed-off-by: Ingo Molnar commit 61e679bf257baf9a089641999cf618e92f07b5dd Author: Steven Rostedt Date: Thu Aug 14 22:47:19 2008 -0400 ftrace: remove old pointers to mcount When a mcount pointer is recorded into a table, it is used to add or remove calls to mcount (replacing them with nops). If the code is removed via removing a module, the pointers still exist. At modifying the code a check is always made to make sure the code being replaced is the code expected. In-other-words, the code being replaced is compared to what it is expected to be before being replaced. There is a very small chance that the code being replaced just happens to look like code that calls mcount (very small since the call to mcount is relative). To remove this chance, this patch adds ftrace_release to allow module unloading to remove the pointers to mcount within the module. Another change for init calls is made to not trace calls marked with __init. The tracing can not be started until after init is done anyway. Signed-off-by: Steven Rostedt Signed-off-by: Ingo Molnar commit fd8ef8ad4555702593662aea9a7df8a58fe27a1e Author: Steven Rostedt Date: Thu Aug 14 22:47:18 2008 -0400 ftrace: move notrace to compiler.h The notrace define belongs in compiler.h so that it can be used in init.h Signed-off-by: Steven Rostedt Signed-off-by: Ingo Molnar commit 5f0f2d0d857c4b9c4205e60a1e3de1d9ed76482d Author: Steven Rostedt Date: Thu Aug 14 22:47:17 2008 -0400 ftrace: do not show freed records in available_filter_functions Seems that freed records can appear in the available_filter_functions list. This patch fixes that. Signed-off-by: Steven Rostedt Signed-off-by: Ingo Molnar commit 4c3dc21b136f8cb4b72afee16c3ba7e961656c0b Author: Steven Rostedt Date: Thu Aug 14 18:05:05 2008 -0400 ftrace: use only 5 byte nops for x86 Mathieu Desnoyers revealed a bug in the original code. The nop that is used to relpace the mcount caller can be a two part nop. This runs the risk where a process can be preempted after executing the first nop, but before the second part of the nop. The ftrace code calls kstop_machine to keep multiple CPUs from executing code that is being modified, but it does not protect against a task preempting in the middle of a two part nop. If the above preemption happens and the tracer is enabled, after the kstop_machine runs, all those nops will be calls to the trace function. If the preempted process that was preempted between the two nops is executed again, it will execute half of the call to the trace function, and this might crash the system. This patch instead uses what both the latest Intel and AMD spec suggests. That is the P6_NOP5 sequence of "0x0f 0x1f 0x44 0x00 0x00". Note, some older CPUs and QEMU might fault on this nop, so this nop is executed with fault handling first. If it detects a fault, it will then use the code "0x66 0x66 0x66 0x66 0x90". If that faults, it will then default to a simple "jmp 1f; .byte 0x00 0x00 0x00; 1:". The jmp is not optimal but will do if the first two can not be executed. TODO: Examine the cpuid to determine the nop to use. Signed-off-by: Steven Rostedt Signed-off-by: Ingo Molnar commit 00a7ed975de063101e397f26882369f1aac7008d Author: Steven Rostedt Date: Thu Aug 14 15:45:12 2008 -0400 ftrace: x86 mcount stub x86 now sets up the mcount locations through the build and no longer needs to record the ip when the function is executed. This patch changes the initial mcount to simply return. There's no need to do any other work. If the ftrace start up test fails, the original mcount will be what everything will use, so having this as fast as possible is a good thing. Signed-off-by: Steven Rostedt Signed-off-by: Ingo Molnar commit c2ffd56692cc4b762c175fad69b70a4ec0dfca3f Author: Steven Rostedt Date: Thu Aug 14 15:45:11 2008 -0400 ftrace: enable using mcount recording on x86 Enable the use of the __mcount_loc infrastructure on x86_64 and i386. Signed-off-by: Steven Rostedt Signed-off-by: Ingo Molnar commit 75a4c7b7fdfbf134a9fbc421f659430582bcd02d Author: Steven Rostedt Date: Thu Aug 14 15:45:10 2008 -0400 ftrace: rebuild everything on change to FTRACE_MCOUNT_RECORD When enabling or disabling CONFIG_FTRACE_MCOUNT_RECORD, we want a full kernel compile to handle the adding of the __mcount_loc sections. Signed-off-by: Steven Rostedt Signed-off-by: Ingo Molnar commit be1c870c22e9b27170b5dd5028b6eaf2aab7b508 Author: Steven Rostedt Date: Thu Aug 14 15:45:09 2008 -0400 ftrace: enable mcount recording for modules This patch enables the loading of the __mcount_section of modules and changing all the callers of mcount into nops. The modification is done before the init_module function is called, so again, we do not need to use kstop_machine to make these changes. Signed-off-by: Steven Rostedt Signed-off-by: Ingo Molnar commit 855e3a060a11d5664cbf7cb230cd2092d49380a4 Author: Steven Rostedt Date: Thu Aug 14 15:45:08 2008 -0400 ftrace: mcount call site on boot nops core This is the infrastructure to the converting the mcount call sites recorded by the __mcount_loc section into nops on boot. It also allows for using these sites to enable tracing as normal. When the __mcount_loc section is used, the "ftraced" kernel thread is disabled. This uses the current infrastructure to record the mcount call sites as well as convert them to nops. The mcount function is kept as a stub on boot up and not converted to the ftrace_record_ip function. We use the ftrace_record_ip to only record from the table. This patch does not handle modules. That comes with a later patch. Signed-off-by: Steven Rostedt Signed-off-by: Ingo Molnar commit 46483cdbb5dc06d84d9572bac1b90f6744c7fc95 Author: Steven Rostedt Date: Thu Aug 14 15:45:07 2008 -0400 ftrace: create __mcount_loc section This patch creates a section in the kernel called "__mcount_loc". This will hold a list of pointers to the mcount relocation for each call site of mcount. For example: objdump -dr init/main.o [...] Disassembly of section .text: 0000000000000000 : 0: 55 push %rbp [...] 000000000000017b : 17b: 55 push %rbp 17c: 48 89 e5 mov %rsp,%rbp 17f: 53 push %rbx 180: 48 83 ec 08 sub $0x8,%rsp 184: e8 00 00 00 00 callq 189 185: R_X86_64_PC32 mcount+0xfffffffffffffffc [...] We will add a section to point to each function call. .section __mcount_loc,"a",@progbits [...] .quad .text + 0x185 [...] The offset to of the mcount call site in init_post is an offset from the start of the section, and not the start of the function init_post. The mcount relocation is at the call site 0x185 from the start of the .text section. .text + 0x185 == init_post + 0xa We need a way to add this __mcount_loc section in a way that we do not lose the relocations after final link. The .text section here will be attached to all other .text sections after final link and the offsets will be meaningless. We need to keep track of where these .text sections are. To do this, we use the start of the first function in the section. do_one_initcall. We can make a tmp.s file with this function as a reference to the start of the .text section. .section __mcount_loc,"a",@progbits [...] .quad do_one_initcall + 0x185 [...] Then we can compile the tmp.s into a tmp.o gcc -c tmp.s -o tmp.o And link it into back into main.o. ld -r main.o tmp.o -o tmp_main.o mv tmp_main.o main.o But we have a problem. What happens if the first function in a section is not exported, and is a static function. The linker will not let the tmp.o use it. This case exists in main.o as well. Disassembly of section .init.text: 0000000000000000 : 0: 55 push %rbp 1: 48 89 e5 mov %rsp,%rbp 4: e8 00 00 00 00 callq 9 5: R_X86_64_PC32 mcount+0xfffffffffffffffc The first function in .init.text is a static function. 00000000000000a8 t __setup_set_reset_devices 000000000000105f t __setup_str_set_reset_devices 0000000000000000 t set_reset_devices The lowercase 't' means that set_reset_devices is local and is not exported. If we simply try to link the tmp.o with the set_reset_devices we end up with two symbols: one local and one global. .section __mcount_loc,"a",@progbits .quad set_reset_devices + 0x10 00000000000000a8 t __setup_set_reset_devices 000000000000105f t __setup_str_set_reset_devices 0000000000000000 t set_reset_devices U set_reset_devices We still have an undefined reference to set_reset_devices, and if we try to compile the kernel, we will end up with an undefined reference to set_reset_devices, or even worst, it could be exported someplace else, and then we will have a reference to the wrong location. To handle this case, we make an intermediate step using objcopy. We convert set_reset_devices into a global exported symbol before linking it with tmp.o and set it back afterwards. 00000000000000a8 t __setup_set_reset_devices 000000000000105f t __setup_str_set_reset_devices 0000000000000000 T set_reset_devices 00000000000000a8 t __setup_set_reset_devices 000000000000105f t __setup_str_set_reset_devices 0000000000000000 T set_reset_devices 00000000000000a8 t __setup_set_reset_devices 000000000000105f t __setup_str_set_reset_devices 0000000000000000 t set_reset_devices Now we have a section in main.o called __mcount_loc that we can place somewhere in the kernel using vmlinux.ld.S and access it to convert all these locations that call mcount into nops before starting SMP and thus, eliminating the need to do this with kstop_machine. Note, A well documented perl script (scripts/recordmcount.pl) is used to do all this in one location. Signed-off-by: Steven Rostedt Signed-off-by: Ingo Molnar commit 9bceab672b60a7dec46d2bc8c6ce54c1ec43e129 Author: Matthew Ranostay Date: Fri Aug 15 07:45:52 2008 +0200 ALSA: hda: 92HD75xx fixes Fixed several noise issues with DACs and ADCs on some 92HD75xxx based codecs with certain revision id's. Signed-off-by: Matthew Ranostay Signed-off-by: Takashi Iwai commit e5b0a2b8fadc35a2d15146bbbf272d53323d8ff1 Author: Matthew Ranostay Date: Fri Aug 15 07:43:24 2008 +0200 ALSA: hda: dynamically create capture mux controls Dynamically create capture mux volume controls when a output amp is detected. Signed-off-by: Matthew Ranostay Signed-off-by: Takashi Iwai commit 28d1bb56750579f600df0f9dabab4c9a3243649d Author: Dan Liang Date: Thu Aug 14 22:36:41 2008 -0400 Input: atmel_tsadcc - improve accuracy Discard the last sample just before pen is up because it is quite often errorneous. Signed-off-by: Nicolas Ferre Signed-off-by: Dan Liang Signed-off-by: Dmitry Torokhov commit 4770e7c76f2808a726fb846f735c2eee0f5a1a84 Author: Bob Moore Date: Fri Aug 15 04:32:59 2008 +0200 ACPICA: Fix warning for 64-bit build Fixes warning from exconfig.c on 64-bit build. AK: This actually was fixed earlier in Linux, this just syncs with AK: the version of the fix that went into the ACPCA codebase Signed-off-by: Bob Moore Signed-off-by: Lin Ming Signed-off-by: Andi Kleen commit 40807be9e5365631916c6f9aff2fe56d3f608dc8 Author: Bob Moore Date: Mon Aug 4 13:22:10 2008 +0800 ACPICA: Add function to dereference returned reference objects Examines the return object from a call to acpi_evaluate_object. Any Index or RefOf references are automatically dereferenced in an attempt to return something useful (these reference types cannot be converted into an external ACPI_OBJECT.) Lin Ming, Bob Moore. Linux BZ 11105 http://bugzilla.kernel.org/show_bug.cgi?id=11105 Signed-off-by: Lin Ming Signed-off-by: Bob Moore Signed-off-by: Andi Kleen commit 2b98d480a6e28196ed6d4a540a2f94fbb75311d9 Author: Yi Yang Date: Mon Aug 4 10:30:09 2008 +0800 ACPICA: Return status from global init function Return status from AcpiUtGlobalInitialize. This is used by both the kernel subsystem and the utilities such as iASL compiler. The function could possibly fail when the caches are initialized. Yang Yi. Signed-off-by: Yi Yang Signed-off-by: Bob Moore Signed-off-by: Lin Ming Signed-off-by: Andi Kleen commit 7a01421c4fec3ed1582b3f6b3fd5c70a5e405bf6 Author: Bob Moore Date: Fri Jul 4 10:57:51 2008 +0800 ACPICA: Fix table compare code, length then data Split the ACPI table compare. First check that the lengths match exactly. Then compare the data. Signed-off-by: Bob Moore Signed-off-by: Lin Ming Signed-off-by: Andi Kleen commit b8b7b2271177d780069099e97b52f6fa4b0d0613 Author: Bob Moore Date: Fri Jul 4 10:56:13 2008 +0800 ACPICA: Fix wrong resource descriptor length for 64-bit build The "minimal" descriptors such as EndTag are calculated as 12 bytes long, but the actual length in the internal descriptor is 16 because of the round-up to 8 on 64-bit build. BZ 728 http://www.acpica.org/bugzilla/show_bug.cgi?id=728 Signed-off-by: Bob Moore Signed-off-by: Lin Ming Signed-off-by: Andi Kleen commit e00c749d4573523e6fa80b046a649517a65c7923 Author: Bob Moore Date: Fri Jul 4 10:48:43 2008 +0800 ACPICA: Allow same ACPI table to be loaded/unloaded more than once Without this change, a table cannot be loaded again once it has been loaded/unloaded one time. The current mechanism does not unregister a table upon an unload. During a load, if the same table is found, this no longer returns an exception. BZ 722 http://www.acpica.org/bugzilla/show_bug.cgi?id=722 Signed-off-by: Bob Moore Signed-off-by: Lin Ming Signed-off-by: Andi Kleen commit 75cdf8037c61601a169d06f6726a2fb76150d5aa Author: Bob Moore Date: Fri Jul 4 10:18:34 2008 +0800 ACPICA: Add check for invalid handle in acpi_get_object_info Return AE_BAD_PARAMETER if input handle is invalid. BZ 474 http://www.acpica.org/bugzilla/show_bug.cgi?id=474 Signed-off-by: Fiodor Suietov Signed-off-by: Bob Moore Signed-off-by: Lin Ming Signed-off-by: Andi Kleen commit 8af045f927cc3bc38c4173e294b7df7b60c9ee6f Author: Bob Moore Date: Fri Aug 15 09:37:58 2008 +0800 ACPICA: Copy dynamically loaded tables to local buffer From: Bob Moore Previously, dynamically loaded tables were simply mapped, but on some machines this memory is corrupted after suspend. Now copy the table to a local buffer. For OpRegion case, added checksum verify. Use the table length from the table header, not the region length. For Buffer case, use the table length also. Dennis Noordsij, Bob Moore. BZ 10734 http://bugzilla.kernel.org/show_bug.cgi?id=10734 Signed-off-by: Dennis Noordsij Signed-off-by: Bob Moore Signed-off-by: Lin Ming Signed-off-by: Andi Kleen commit c2583540fa2c669b42293c961b4f03a660c0126a Author: Zhao Yakui Date: Tue Aug 12 10:20:22 2008 +0800 ACPI : Add the support for _TTS object The _TTS object is defined in the section 7.3 of acpi 3.0b spec. The _TTS control method is executed by the OSPM at the beginning of the sleep transition process for S1,S2, S3, S4, and orderly S5 shutdown. OS will invoke _TTS before it has notified any native mode device drivers of the sleep state transition. The target sleeping state value is passed to the _TTS control method. The _TTS control method is also executed by the OSPM at the end of any sleep transition process when the system transitions to S0 from S1, S2, S3, or S4. The _TTS object should be evaluated after it has notified any native mode device drivers of the end of the sleep state transition. The working state value (0) is passed to the _TTS control method. So it is necessary to add the support for _TTS object. The _TTS object will be evaluated if it exists. At the same time a block notifier is added to the reboot notifier list so that the _TTS object will also be evaluated when the system shutdown. http://bugzilla.kernel.org/show_bug.cgi?id=11132 Signed-off-by: Zhao Yakui Signed-off-by: Li Shaohua Signed-off-by: Andi Kleen commit 251c59e2a78e63f23f682659f78426dbfccef450 Author: Matthew Garrett Date: Wed Aug 6 19:12:04 2008 +0100 ACPI: Clear WAK_STS on resume The leading other brand OS appears to clear the WAK_STS flag on resume. When rebooted, certain BIOSes assume that the system is actually resuming if it's still set and so fail to reboot correctly. Make sure that it's cleared at resume time. Comment clarified as suggested by Bob Moore Signed-off-by: Matthew Garrett Signed-off-by: Andi Kleen commit 782b7a367d81da005d93b28cb00f9ae086773c24 Author: Adrian Hunter Date: Thu Aug 14 14:00:12 2008 +0300 [MTD] [OneNAND] OMAP3: add delay for GPIO On OMAP3, the driver was occasionally not seeing the GPIO interrupt. Adding a small delay of one register read eliminates the problem. Signed-off-by: Adrian Hunter Signed-off-by: David Woodhouse commit 4a031b0e6acd8a8c23725ceb5db6a0aa5c4e231f Author: Simon Horman Date: Fri Aug 15 09:26:15 2008 +1000 ipvs: rename __ip_vs_wlc_schedule in lblc and lblcr schedulers For the sake of clarity, rename __ip_vs_wlc_schedule() in lblc.c to __ip_vs_lblc_schedule() and the version in lblcr.c to __ip_vs_lblc_schedule(). I guess the original name stuck from a copy and paste. Cc: Sven Wegener Signed-off-by: Simon Horman commit a919cf4b6b499416b6e2247dbc79196c4325f2e6 Author: Sven Wegener Date: Thu Aug 14 00:47:16 2008 +0200 ipvs: Create init functions for estimator code Commit 8ab19ea36c5c5340ff598e4d15fc084eb65671dc ("ipvs: Fix possible deadlock in estimator code") fixed a deadlock condition, but that condition can only happen during unload of IPVS, because during normal operation there is at least our global stats structure in the estimator list. The mod_timer() and del_timer_sync() calls are actually initialization and cleanup code in disguise. Let's make it explicit and move them to their own init and cleanup function. Signed-off-by: Sven Wegener Signed-off-by: Simon Horman commit 82dfb6f32219d8e6cf6b979a520cb2b11d977d4e Author: Sven Wegener Date: Mon Aug 11 19:36:06 2008 +0000 ipvs: Only call init_service, update_service and done_service for schedulers if defined There are schedulers that only schedule based on data available in the service or destination structures and they don't need any persistent storage or initialization routine. These schedulers currently provide dummy functions for the init_service, update_service and/or done_service functions. For the init_service and done_service cases we already have code that only calls these functions, if the scheduler provides them. Do the same for the update_service case and remove the dummy functions from all schedulers. Signed-off-by: Sven Wegener Signed-off-by: Simon Horman commit 9a812198ae49967f239789164c55ec3e72b7e0dd Author: Julius Volz Date: Thu Aug 14 14:08:44 2008 +0200 IPVS: Add genetlink interface implementation Add the implementation of the new Generic Netlink interface to IPVS and keep the old set/getsockopt interface for userspace backwards compatibility. Signed-off-by: Julius Volz Acked-by: Sven Wegener Signed-off-by: Simon Horman commit c1bc667e844c2677cdf927102ab384fe7b033762 Author: Julius Volz Date: Thu Aug 7 16:43:38 2008 +0200 IPVS: Add genetlink interface definitions to ip_vs.h Add IPVS Generic Netlink interface definitions to include/linux/ip_vs.h. Signed-off-by: Julius Volz Signed-off-by: Simon Horman commit 863de52249c7e73d4891906deba7bf7cc598223f Author: Benny Halevy Date: Tue Aug 12 20:46:18 2008 +0300 nfsd: nfs4xdr decode_stateid helper function Signed-off-by: Benny Halevy Signed-off-by: J. Bruce Fields commit eb3cc461d84bf4df78135ae43eea2a9da5ed1a4f Author: Benny Halevy Date: Tue Aug 12 20:45:51 2008 +0300 nfsd: properly xdr-decode NFS4_OPEN_CLAIM_DELEGATE_CUR stateid Signed-off-by: Benny Halevy Signed-off-by: J. Bruce Fields commit 6b26c499c9fe4d5e42a65cf651c295f4b38007e3 Author: Benny Halevy Date: Tue Aug 12 20:45:28 2008 +0300 nfsd: don't declare p in ENCODE_SEQID_OP_HEAD After using the encode_stateid helper the "p" pointer declared by ENCODE_SEQID_OP_HEAD is warned as unused. In the single site where it is still needed it can be declared separately using the ENCODE_HEAD macro. Signed-off-by: Benny Halevy Signed-off-by: J. Bruce Fields commit 0177cc3bbcf4c4af731bb4bd974dd5c9414f002a Author: Benny Halevy Date: Tue Aug 12 20:45:07 2008 +0300 nfsd: nfs4xdr encode_stateid helper function Signed-off-by: Benny Halevy Signed-off-by: J. Bruce Fields commit aa2d562c5dd3bb865731f90242b4094d6a37cd19 Author: Benny Halevy Date: Tue Aug 12 20:44:41 2008 +0300 nfsd: fix nfsd4_encode_open buffer space reservation nfsd4_encode_open first reservation is currently for 36 + sizeof(stateid_t) while it writes after the stateid a cinfo (20 bytes) and 5 more 4-bytes words, for a total of 40 + sizeof(stateid_t). Signed-off-by: Benny Halevy Signed-off-by: J. Bruce Fields commit 2d80ba43f10c00949c5f026fc0369f78919e59be Author: Benny Halevy Date: Tue Aug 12 20:43:37 2008 +0300 nfsd: properly xdr-encode deleg stateid returned from open Signed-off-by: Benny Halevy Signed-off-by: J. Bruce Fields commit f7a7c390e05ecc858e100416e4335f24097fffcd Author: Benny Halevy Date: Tue Aug 12 20:42:51 2008 +0300 nfsd: properly xdr-encode stateid4.seqid as uint32_t for cb_recall Signed-off-by: Benny Halevy Signed-off-by: J. Bruce Fields commit e88d56b36e2ce1d6ee9c911113b175f52c158912 Author: Thomas Petazzoni Date: Wed Aug 6 15:12:22 2008 +0200 Configure out file locking features This patch adds the CONFIG_FILE_LOCKING option which allows to remove support for advisory locks. With this patch enabled, the flock() system call, the F_GETLK, F_SETLK and F_SETLKW operations of fcntl() and NFS support are disabled. These features are not necessarly needed on embedded systems. It allows to save ~11 Kb of kernel code and data: text data bss dec hex filename 1125436 118764 212992 1457192 163c28 vmlinux.old 1114299 118564 212992 1445855 160fdf vmlinux -11137 -200 0 -11337 -2C49 +/- This patch has originally been written by Matt Mackall , and is part of the Linux Tiny project. Signed-off-by: Thomas Petazzoni Signed-off-by: Matt Mackall Cc: matthew@wil.cx Cc: linux-fsdevel@vger.kernel.org Cc: mpm@selenic.com Cc: akpm@linux-foundation.org Signed-off-by: J. Bruce Fields commit dbc74c65b3fd841985935f676388c82d6b85c485 Author: Vesa-Matti Kari Date: Thu Aug 7 03:18:20 2008 +0300 selinux: Unify for- and while-loop style Replace "thing != NULL" comparisons with just "thing" to make the code look more uniform (mixed styles were used even in the same source file). Signed-off-by: Vesa-Matti Kari Acked-by: Stephen Smalley Signed-off-by: James Morris commit 168ec8830f0b91aba201473f270d5f77a2b3f356 Author: Stefan Richter Date: Sat Aug 9 20:22:17 2008 +0200 firewire: fw-sbp2: fix another small generation access bug queuecommand() looked at the remote and local node IDs before it read the bus generation. The corresponding race with sbp2_reconnect updating these data was probably impossible to happen though because the current code blocks the SCSI layer during reconnection. However, better safe than sorry, especially if someone later improves the code to not block the SCSI layer. Signed-off-by: Stefan Richter commit 1ff0bf369cae18089a313c7b985686d65ed110a8 Author: Stefan Richter Date: Thu Aug 14 21:47:21 2008 +0200 firewire: fw-sbp2: enforce s/g segment size limit 1. We don't need to round the SBP-2 segment size limit down to a multiple of 4 kB (0xffff -> 0xf000). It is only necessary to ensure quadlet alignment (0xffff -> 0xfffc). 2. Use dma_set_max_seg_size() to tell the DMA mapping infrastructure and the block IO layer about the restriction. This way we can remove the size checks and segment splitting in the queuecommand path. This assumes that no other code in the firewire stack uses dma_map_sg() with conflicting requirements. It furthermore assumes that the controller device's platform actually allows us to set the segment size to our liking. Assert the latter with a BUG_ON(). 3. Also use blk_queue_max_segment_size() to tell the block IO layer about it. It cannot know it because our scsi_add_host() does not point to the FireWire controller's device. Thanks to Grant Grundler and FUJITA Tomonori for advice. Signed-off-by: Stefan Richter commit b1428d745899adc9a2df17080c780f92a8141962 Author: Stefan Richter Date: Thu Aug 14 09:28:14 2008 +0200 ieee1394: sbp2: enforce s/g segment size limit 1. We don't need to round the SBP-2 segment size limit down to a multiple of 4 kB (0xffff -> 0xf000). It is only necessary to ensure quadlet alignment (0xffff -> 0xfffc). 2. Use dma_set_max_seg_size() to tell the DMA mapping infrastructure and the block IO layer about the restriction. This way we can remove the size checks and segment splitting in the queuecommand path. This assumes that no other code in the ieee1394 stack uses dma_map_sg() with conflicting requirements. It furthermore assumes that the controller device's platform actually allows us to set the segment size to our liking. Assert the latter with a BUG_ON(). 3. Also use blk_queue_max_segment_size() to tell the block IO layer about it. It cannot know it because our scsi_add_host() does not point to the FireWire controller's device. We can also uniformly use dma_map_sg() for the single segment case just like for the multi segment case, to further simplify the code. Also clean up how the page table is converted to big endian. Thanks to Grant Grundler and FUJITA Tomonori for advice. Signed-off-by: Stefan Richter commit 8ea807772d16b18552746ca0ed75fa0cc5d400be Author: Stefan Richter Date: Sat Aug 9 20:16:24 2008 +0200 ieee1394: sbp2: check for DMA mapping failures Signed-off-by: Stefan Richter commit 09a06657b6e263cb3c72727baa0b567c5527f7df Author: Stefan Richter Date: Sat Aug 9 20:13:00 2008 +0200 ieee1394: sbp2: stricter dma_sync Two dma_sync_single_for_cpu() were called in the wrong place. Luckily they were merely for DMA_TO_DEVICE, hence nobody noticed. Also reorder the matching dma_sync_single_for_device() a little bit so that they reside in the same functions as their counterparts. This also avoids syncing the s/g table for requests which don't use it. Signed-off-by: Stefan Richter commit 793924c89049a6eb449c97be49b45c4e421f20a9 Author: Avi Kivity Date: Thu Aug 14 21:25:47 2008 +0300 KVM: Simplify exception entries by using __ASM_SIZE and _ASM_PTR Signed-off-by: Avi Kivity commit 6f5aaf20abde1544eee449a84dcbb8e94745fee5 Author: Krzysztof Hałasa Date: Thu Aug 14 19:17:38 2008 +0200 WAN: new synchronous PPP implementation for generic HDLC. Signed-off-by: Krzysztof Hałasa commit cf417141cbb3a4ceb5cca15b2c1f099bd0a6603c Author: Max Krasnyansky Date: Mon Aug 11 14:33:53 2008 -0700 sched, cpuset: rework sched domains and CPU hotplug handling (v4) This is an updated version of my previous cpuset patch on top of the latest mainline git. The patch fixes CPU hotplug handling issues in the current cpusets code. Namely circular locking in rebuild_sched_domains() and unsafe access to the cpu_online_map in the cpuset cpu hotplug handler. This version includes changes suggested by Paul Jackson (naming, comments, style, etc). I also got rid of the separate workqueue thread because it is now safe to call get_online_cpus() from workqueue callbacks. Here are some more details: rebuild_sched_domains() is the only way to rebuild sched domains correctly based on the current cpuset settings. What this means is that we need to be able to call it from different contexts, like cpu hotplug for example. Also latest scheduler code in -tip now calls rebuild_sched_domains() directly from functions like arch_reinit_sched_domains(). In order to support that properly we need to rework cpuset locking rules to avoid circular dependencies, which is what this patch does. New lock nesting rules are explained in the comments. We can now safely call rebuild_sched_domains() from virtually any context. The only requirement is that it needs to be called under get_online_cpus(). This allows cpu hotplug handlers and the scheduler to call rebuild_sched_domains() directly. The rest of the cpuset code now offloads sched domains rebuilds to a workqueue (async_rebuild_sched_domains()). This version of the patch addresses comments from the previous review. I fixed all miss-formated comments and trailing spaces. I also factored out the code that builds domain masks and split up CPU and memory hotplug handling. This was needed to simplify locking, to avoid unsafe access to the cpu_online_map from mem hotplug handler, and in general to make things cleaner. The patch passes moderate testing (building kernel with -j 16, creating & removing domains and bringing cpus off/online at the same time) on the quad-core2 based machine. It passes lockdep checks, even with preemptable RCU enabled. This time I also tested in with suspend/resume path and everything is working as expected. Signed-off-by: Max Krasnyansky Acked-by: Paul Jackson Cc: menage@google.com Cc: a.p.zijlstra@chello.nl Cc: vegard.nossum@gmail.com Signed-off-by: Ingo Molnar commit bde86fec7c822b6009d3cfefc20b76b8d34716af Author: Adrian Hunter Date: Thu Aug 14 11:57:45 2008 +0300 [JFFS2] Correct symlink name too long error code Signed-off-by: Adrian Hunter Signed-off-by: David Woodhouse commit f65bc214e042916135256620f900e9599d65e0cb Author: Suresh Siddha Date: Wed Aug 13 11:38:15 2008 -0700 x86, xsave: use BUG_ON() instead of BUILD_BUG_ON() All these structure sizes are runtime determined. So use a runtime bug check. Signed-off-by: Suresh Siddha Signed-off-by: Ingo Molnar commit ed405958057ca6a8c4c9178a7a3b1167fabb45f5 Author: Suresh Siddha Date: Wed Aug 13 11:38:14 2008 -0700 x86, xsave: clear the user buffer before doing fxsave/xsave fxsave/xsave instructions will not touch all the bytes in the fxsave/xsave frame. Clear the user buffer before doing fxsave/xsave directly to user buffer during the sigcontext setup. This is essentially needed in the context of xsave(for example, some of the fields in the xsave header are not touched by the xsave and defined as must be zero). This will also present uniform and clean context to the user (from which user can safely do fxrstor/xrstor). Signed-off-by: Suresh Siddha Signed-off-by: Ingo Molnar commit ee2b92a8201a40021ecd1aee6f0625dc03bacc54 Author: Suresh Siddha Date: Wed Aug 13 11:38:13 2008 -0700 x86, xsave: remove the redundant access_ok() in setup_rt_frame() save_i387_xstate() is already doing the required access_ok(). Remove the redundant access_ok() before it. Signed-off-by: Suresh Siddha Signed-off-by: Ingo Molnar commit 37304c6f9ced347cf013bcd4bf808d6fd4fb6ce1 Author: Avi Kivity Date: Thu Aug 14 11:13:16 2008 +0300 KVM: VMX: Use interrupt queue for !irqchip_in_kernel Signed-off-by: Avi Kivity commit fd340378e177d3a69b7ac170f7275708a7d60e6e Author: Jaroslav Kysela Date: Wed Aug 13 20:55:32 2008 +0200 ALSA: hda - put all HDA codec IDs to components for precise hw detection Export HDA codec subvendor ID and revision ID to user space via the components variable. Our alsactl utility requires these values for the perfect hardware identification. Signed-off-by: Jaroslav Kysela Signed-off-by: Takashi Iwai commit d31c10f2dd9b23778c719317ad15603253b2878a Author: Randy Dunlap Date: Wed Aug 13 10:52:34 2008 -0700 slabinfo: fix printf formats Fix slabinfo printf format warnings: linux-next-20080813/Documentation/vm/slabinfo.c:619: warning: format '%7d' expects type 'int', but argument 4 has type 'long unsigned int' linux-next-20080813/Documentation/vm/slabinfo.c:619: warning: format '%7d' expects type 'int', but argument 5 has type 'long unsigned int' linux-next-20080813/Documentation/vm/slabinfo.c:619: warning: format '%7d' expects type 'int', but argument 6 has type 'long unsigned int' linux-next-20080813/Documentation/vm/slabinfo.c:619: warning: format '%7d' expects type 'int', but argument 7 has type 'long unsigned int' linux-next-20080813/Documentation/vm/slabinfo.c:619: warning: format '%7d' expects type 'int', but argument 8 has type 'long unsigned int' linux-next-20080813/Documentation/vm/slabinfo.c:619: warning: format '%7d' expects type 'int', but argument 9 has type 'long unsigned int' Signed-off-by: Randy Dunlap Signed-off-by: Pekka Enberg commit 34a1b9fc4995102ecbb3a980b348aebf168d8196 Author: David Woodhouse Date: Tue Aug 12 13:25:44 2008 +0100 Fix date output in x86 microcode driver. The microcode stores its date in a uint32_t in some weird order approximating pdp-endian. Rather than printing it like that, print it properly in ISO standard form. Signed-off-by: David Woodhouse Cc: Shaohua Li Signed-off-by: Ingo Molnar commit fd429be53b1dc3b0503f35bdee490e2edf17a6fb Author: Takashi Iwai Date: Wed Aug 13 15:40:53 2008 +0200 ALSA: usb-audio - Add ignore_ctl_error parameter Added the ignore_ctl_error parameter to enable/disable the control-error handling for mixer interfaces. It was a hard-coded ifdef, and now you can change it more easily. Signed-off-by: Takashi Iwai commit 1eb070477e13c43049dbe7197e5ba6e2f9c0edc0 Author: Takashi Iwai Date: Wed Aug 13 15:27:43 2008 +0200 ALSA: Add missing description of usb-audio parameters Added the missing description of module parameters of usb-audio driver to ALSA-Configuration.txt. Signed-off-by: Takashi Iwai commit 8929dda869d51b953c8f300864da62297db8a74e Author: Li, Shaohua Date: Wed Aug 13 17:26:01 2008 +0800 fastboot: remove duplicate unpack_to_rootfs() we check if initrd is initramfs first and then do real unpack. The check isn't required, we can directly do unpack. If initrd isn't initramfs, we can remove garbage. In my laptop, this saves 0.1s boot time. This penalizes non-initramfs case, but now initramfs is mostly widely used. Signed-off-by: Shaohua Li Acked-by: Arjan van de Ven Signed-off-by: Ingo Molnar commit 26d809af6397ce5c37f5c44d89734d19cce1ad25 Author: Ingo Molnar Date: Wed Aug 13 12:46:26 2008 +0200 x86: fix xsave build error fix this build failure with certain glibc versions: In file included from /usr/include/bits/sigcontext.h:28, from /usr/include/signal.h:333, from Documentation/accounting/getdelays.c:24: /home/mingo/tip/usr/include/asm/sigcontext.h:191: error: expected specifier-qualifier-list before ‘u64’ Signed-off-by: Ingo Molnar commit 2d48a1122fbf1bbc3d0f7ea8848d6588e300e423 Author: Marcelo Tosatti Date: Fri Aug 1 20:09:13 2008 -0300 KVM: set debug registers after "schedulable" section The vcpu thread can be preempted after the guest_debug_pre() callback, resulting in invalid debug registers on the new vcpu. Move it inside the non-preemptable section. Signed-off-by: Marcelo Tosatti Signed-off-by: Avi Kivity commit bc4c6817e9163f2ebd939eb9b87e642b27a5b8ad Author: Krzysztof Hałasa Date: Fri Jul 11 00:13:09 2008 +0200 WAN: Simplify sca_init_port() in HD64572 driver. Signed-off-by: Krzysztof Hałasa commit fdce22dc83d082005aa216002153cba005e5f99d Author: Krzysztof Hałasa Date: Thu Jul 10 00:30:51 2008 +0200 WAN: Correct comments in hd6457[02].c Signed-off-by: Krzysztof Hałasa commit 99ba593577082093cd627dee9c37f34d13940989 Author: Krzysztof Hałasa Date: Wed Jul 9 23:39:12 2008 +0200 WAN: HD64572 drivers don't use next_desc() anymore. Signed-off-by: Krzysztof Hałasa commit e43b4dd228789c7cf8c7087d3e7f5fb492bdf824 Author: Krzysztof Hałasa Date: Wed Jul 9 23:13:49 2008 +0200 WAN: Simplify HD64572 drivers. Signed-off-by: Krzysztof Hałasa commit 35aa54e1e998b809505481dfa9cdefd4f25ee5bf Author: Krzysztof Hałasa Date: Wed Jul 9 21:30:17 2008 +0200 WAN: don't print HD64572 driver versions anymore. Signed-off-by: Krzysztof Hałasa commit 565b618049e9e90da2556eeca556c4a1cb9ee87f Author: Krzysztof Hałasa Date: Wed Jul 9 21:24:42 2008 +0200 WAN: Simplify HD64572 status handling. Signed-off-by: Krzysztof Hałasa commit 4d1ad1a756061cf94787dd5f2720c0c2203aa6bb Author: Krzysztof Hałasa Date: Wed Jul 9 19:28:45 2008 +0200 WAN: rework HD64572 interrupts a bit. Signed-off-by: Krzysztof Hałasa commit b19c211ac0daf0bc45ea1605b58aad36f36f8503 Author: Krzysztof Hałasa Date: Wed Jul 9 20:01:23 2008 +0200 WAN: HD64572 already handles TX underruns with DMAC. Signed-off-by: Krzysztof Hałasa commit be9696700ea81752646e51e73fce80b33796b709 Author: Krzysztof Hałasa Date: Wed Jul 9 19:47:05 2008 +0200 WAN: TX-done handler now uses the ownership bit in HD64572 drivers. Signed-off-by: Krzysztof Hałasa commit 125c0b590f9ad4b8d278318df04968e164f336bf Author: Krzysztof Hałasa Date: Wed Jul 9 16:49:37 2008 +0200 WAN: convert HD64572-based drivers to NAPI. Signed-off-by: Krzysztof Hałasa commit 32c9ec117eb59a79b5dee4a34442cf44f030756b Author: Krzysztof Hałasa Date: Mon Mar 24 20:24:23 2008 +0100 WAN: remove SCA support from SCA-II drivers Signed-off-by: Krzysztof Hałasa commit e5f4106dba58925c13e34bf5775628069d43c313 Author: Krzysztof Hałasa Date: Mon Mar 24 19:12:23 2008 +0100 WAN: remove SCA II support from SCA drivers Signed-off-by: Krzysztof Hałasa commit ff457284946a568fc41cd244007792af2800c035 Author: Krzysztof Hałasa Date: Mon Mar 24 16:39:02 2008 +0100 WAN: split hd6457x.c into hd64570.c and hd64572.c Supporting both original SCA and SCA-II in one file was nice at some point but now it's increasingly painful. Signed-off-by: Krzysztof Hałasa commit 40c1e63d11941b18aec1308f730bc260c70ae438 Author: Alexander Beregalov Date: Wed Aug 13 00:10:55 2008 +0400 ALSA: ALSA-Configuration.txt: supported cards update ALSA-Configuration.txt: supported cards update Signed-off-by: Alexander Beregalov Signed-off-by: Takashi Iwai commit 120ea9be42cbac798674729acf09a464176938b8 Author: Alexander Beregalov Date: Wed Aug 13 12:36:21 2008 +0400 ALSA: sound/pci: supported cards update sound/pci: supported cards update Signed-off-by: Alexander Beregalov Signed-off-by: Takashi Iwai commit b288740a8b29ab7fdef48dfa467ae01a82073792 Author: Ben-Ami Yassour Date: Tue Aug 5 15:30:13 2008 +0300 KVM: remove unused field from the assigned dev struct Remove unused field: struct kvm_assigned_pci_dev assigned_dev from struct: struct kvm_assigned_dev_kernel Signed-off-by: Ben-Ami Yassour Signed-off-by: Avi Kivity commit 72dbf4790fc6736f9cb54424245114acf0b0038c Author: Bob Peterson Date: Tue Aug 12 13:39:29 2008 -0500 GFS2: rm on multiple nodes causes panic This patch fixes a problem whereby simultaneous unlink, rmdir, rename and link operations (e.g. rm -fR *) from multiple nodes on the same GFS2 file system can cause kernel panics, hangs, and/or memory corruption. It also gets rid of all the non-rgrp calls to gfs2_glock_nq_m. Signed-off-by: Bob Peterson Signed-off-by: Steven Whitehouse commit 9b8df98fc8973ad1c5f0d7c4cf71c7fb84fe22c5 Author: Steven Whitehouse Date: Fri Aug 8 13:45:13 2008 +0100 GFS2: Fix metafs mounts This patch is intended to fix the issues reported in bz #457798. Instead of having the metafs as a separate filesystem, it becomes a second root of gfs2. As a result it will appear as type gfs2 in /proc/mounts, but it is still possible (for backwards compatibility purposes) to mount it as type gfs2meta. A new mount flag "meta" is introduced so that its possible to tell the two cases apart in /proc/mounts. As a result it becomes possible to mount type gfs2 with -o meta and get the same result as mounting type gfs2meta. So it is possible to mount just the metafs on its own. Currently if you do this, its then impossible to mount the "normal" root of the gfs2 filesystem without first unmounting the metafs root. I'm not sure if thats a feature or a bug :-) Either way, this is a great improvement on the previous scheme and I've verified that it works ok with bind mounts on both the "normal" root and the metafs root in various combinations. There were also a bunch of functions in super.c which didn't belong there, so this moves them into ops_fstype.c where they can be static. Hopefully the mount/umount sequence is now more obvious as a result. Signed-off-by: Steven Whitehouse Cc: Alexander Viro commit c1e817d03a7de57a963654c35e6e80af9a5dbff5 Author: Steven Whitehouse Date: Tue Jul 22 22:58:03 2008 +0100 GFS2: Fix debugfs glock file iterator Due to an incorrect iterator, some glocks were being missed from the glock dumps obtained via debugfs. This patch fixes the problem and ensures that we don't miss any glocks in future. Signed-off-by: Steven Whitehouse commit 9f1c29c624d863a2cab1f88b2081f808eebe7e9b Author: Sheng Yang Date: Wed Aug 13 14:10:33 2008 +0800 KVM: VMX: Clean up magic number 0x66 in init_rmode_tss Signed-off-by: Sheng Yang Signed-off-by: Avi Kivity commit 0ebfa83373ace68bd192b6d6455c0891620bb035 Author: Christoph Lameter Date: Mon Aug 11 08:06:31 2008 -0700 Filesystem: XFS slab defragmentation Support inode defragmentation for xfs Reviewed-by: Rik van Riel Signed-off-by: Christoph Lameter Signed-off-by: Christoph Lameter Signed-off-by: Pekka Enberg commit d4491361be49c313a2ee46b41939b3b6442f3823 Author: Christoph Lameter Date: Mon Aug 11 08:06:33 2008 -0700 Filesystem: Slab defrag: Reiserfs support Slab defragmentation: Support reiserfs inode defragmentation. Reviewed-by: Rik van Riel Signed-off-by: Christoph Lameter Signed-off-by: Christoph Lameter Signed-off-by: Pekka Enberg commit 6095e1ace17ac72f57d33f3b575ab41bcb377a1a Author: Christoph Lameter Date: Mon Aug 11 08:06:32 2008 -0700 Filesystem: /proc filesystem support for slab defrag Support procfs inode defragmentation Cc: Alexey Dobriyan Reviewed-by: Rik van Riel Signed-off-by: Christoph Lameter Signed-off-by: Christoph Lameter Signed-off-by: Pekka Enberg commit 00bf67e3b68d7cf8d45aa0aa2206f63d95a320a6 Author: Christoph Lameter Date: Mon Aug 11 08:06:30 2008 -0700 Filesystem: Ext4 filesystem defrag Support defragmentation for ext4 filesystem inodes Acked-by: "Theodore Ts'o" Reviewed-by: Rik van Riel Signed-off-by: Christoph Lameter Signed-off-by: Christoph Lameter Signed-off-by: Pekka Enberg commit 02081bc81ea85dbd362b0229ab3423255bda5057 Author: Eduard - Gabriel Munteanu Date: Sun Aug 10 20:14:07 2008 +0300 kmemtrace: SLOB hooks. This adds hooks for the SLOB allocator, to allow tracing with kmemtrace. We also convert some inline functions to __always_inline to make sure _RET_IP_, which expands to __builtin_return_address(0), always works as expected. Acked-by: Matt Mackall Signed-off-by: Eduard - Gabriel Munteanu Signed-off-by: Pekka Enberg commit 894679357edf38ba5a8bfbb178534721dc04d982 Author: Eduard - Gabriel Munteanu Date: Sun Aug 10 20:14:05 2008 +0300 kmemtrace: SLAB hooks. This adds hooks for the SLAB allocator, to allow tracing with kmemtrace. We also convert some inline functions to __always_inline to make sure _RET_IP_, which expands to __builtin_return_address(0), always works as expected. Signed-off-by: Eduard - Gabriel Munteanu Signed-off-by: Pekka Enberg commit fe8bbe03e888cc8523737073c56f0cb44e51a357 Author: Eduard - Gabriel Munteanu Date: Sun Aug 10 20:14:04 2008 +0300 kmemtrace: Additional documentation. Documented kmemtrace's ABI, purpose and design. Also includes a short usage guide, FAQ, as well as a link to the userspace application's Git repository, which is currently hosted at repo.or.cz. Signed-off-by: Eduard - Gabriel Munteanu Signed-off-by: Pekka Enberg commit 424ba859e896c883baef61d7fe05b71097e2dfeb Author: Eduard - Gabriel Munteanu Date: Sun Aug 10 20:14:03 2008 +0300 kmemtrace: Core implementation. kmemtrace provides tracing for slab allocator functions, such as kmalloc, kfree, kmem_cache_alloc, kmem_cache_free etc.. Collected data is then fed to the userspace application in order to analyse allocation hotspots, internal fragmentation and so on, making it possible to see how well an allocator performs, as well as debug and profile kernel code. Signed-off-by: Eduard - Gabriel Munteanu Signed-off-by: Pekka Enberg commit 13278e3ed303af8229c818dfffa97f658b2ff40b Author: Christoph Lameter Date: Mon Aug 11 08:06:29 2008 -0700 Filesystem: Ext3 filesystem defrag Support defragmentation for ext3 filesystem inodes Reviewed-by: Rik van Riel Signed-off-by: Christoph Lameter Signed-off-by: Christoph Lameter Signed-off-by: Pekka Enberg commit bd9a7be95fb2b35963c78aa5f50acc2102070180 Author: Christoph Lameter Date: Mon Aug 11 08:06:28 2008 -0700 Filesystem: Ext2 filesystem defrag Support defragmentation for ext2 filesystem inodes Reviewed-by: Rik van Riel Signed-off-by: Christoph Lameter Signed-off-by: Christoph Lameter Signed-off-by: Pekka Enberg commit b50daba5e530a338263c27e044c13e52a94eb17e Author: Christoph Lameter Date: Mon Aug 11 08:06:27 2008 -0700 inodes: Support generic defragmentation This implements the ability to remove inodes in a particular slab from inode caches. In order to remove an inode we may have to write out the pages of an inode, the inode itself and remove the dentries referring to the node. Provide generic functionality that can be used by filesystems that have their own inode caches to also tie into the defragmentation functions that are made available here. Cc: Alexander Viro Cc: Christoph Hellwig Reviewed-by: Rik van Riel Signed-off-by: Christoph Lameter Signed-off-by: Christoph Lameter Signed-off-by: Pekka Enberg commit f79e96f25587dcf5f924a418161ae35f9aa64375 Author: Christoph Lameter Date: Mon Aug 11 08:06:26 2008 -0700 buffer heads: Support slab defrag Defragmentation support for buffer heads. We convert the references to buffers to struct page references and try to remove the buffers from those pages. If the pages are dirty then trigger writeout so that the buffer heads can be removed later. Reviewed-by: Rik van Riel Signed-off-by: Christoph Lameter Signed-off-by: Christoph Lameter Signed-off-by: Pekka Enberg commit f85619df6deb5cb2c8c23eaeea9489b32055c4a2 Author: Christoph Lameter Date: Mon Aug 11 08:06:25 2008 -0700 slub: Trigger defragmentation from memory reclaim This patch triggers slab defragmentation from memory reclaim. The logical point for this is after slab shrinking was performed in vmscan.c. At that point the fragmentation ratio of a slab was increased because objects were freed via the LRU lists maitained for various slab caches. So we call kmem_cache_defrag() from there. shrink_slab() is called in some contexts to do global shrinking of slabs and in others to do shrinking for a particular zone. Pass the zone to shrink_slab(), so that slab_shrink() can call kmem_cache_defrag() and restrict the defragmentation to the node that is under memory pressure. The callback frequency into slab reclaim can be controlled by a new field /proc/sys/vm/slab_defrag_limit. Reviewed-by: Rik van Riel Signed-off-by: Christoph Lameter Signed-off-by: Pekka Enberg Signed-off-by: Christoph Lameter Signed-off-by: Pekka Enberg commit a0a66769f56f4e1e0ff9040b030534ac5b85ae24 Author: Christoph Lameter Date: Mon Aug 11 08:06:24 2008 -0700 slub/slabinfo: add defrag statistics Add statistics counters for slab defragmentation. Signed-off-by: Christoph Lameter Signed-off-by: Pekka Enberg Signed-off-by: Christoph Lameter Signed-off-by: Pekka Enberg commit bcede76535066f608763bf853447b44f8e74e49e Author: Christoph Lameter Date: Mon Aug 11 08:06:23 2008 -0700 slub: Extend slabinfo to support -D and -F options -F lists caches that support defragmentation -C lists caches that use a ctor. Change field names for defrag_ratio and remote_node_defrag_ratio. Add determination of the allocation ratio for a slab. The allocation ratio is the percentage of available slots for objects in use. Reviewed-by: Rik van Riel Signed-off-by: Christoph Lameter Signed-off-by: Pekka Enberg Signed-off-by: Christoph Lameter Signed-off-by: Pekka Enberg commit 95879d68983f17e904b25c2a7e6706ed9f2923ca Author: Christoph Lameter Date: Mon Aug 11 08:06:22 2008 -0700 slub: Add KICKABLE to avoid repeated kick() attempts Add a flag KICKABLE to be set on slabs with a defragmentation method Clear the flag if a kick action is not successful in reducing the number of objects in a slab. This will avoid future attempts to kick objects out. The KICKABLE flag is set again when all objects of the slab have been allocated (Occurs during removal of a slab from the partial lists). Reviewed-by: Rik van Riel Signed-off-by: Christoph Lameter Signed-off-by: Pekka Enberg Signed-off-by: Christoph Lameter Signed-off-by: Pekka Enberg commit e8305cd73e953fa0d42433e55750d3e4e2e04017 Author: Christoph Lameter Date: Mon Aug 11 08:06:21 2008 -0700 slub: Slab defrag core Slab defragmentation may occur: 1. Unconditionally when kmem_cache_shrink is called on a slab cache by the kernel calling kmem_cache_shrink. 2. Through the use of the slabinfo command. 3. Per node defrag conditionally when kmem_cache_defrag() is called (can be called from reclaim code with a later patch). Defragmentation is only performed if the fragmentation of the slab is lower than the specified percentage. Fragmentation ratios are measured by calculating the percentage of objects in use compared to the total number of objects that the slab page can accomodate. The scanning of slab caches is optimized because the defragmentable slabs come first on the list. Thus we can terminate scans on the first slab encountered that does not support defragmentation. kmem_cache_defrag() takes a node parameter. This can either be -1 if defragmentation should be performed on all nodes, or a node number. A couple of functions must be setup via a call to kmem_cache_setup_defrag() in order for a slabcache to support defragmentation. These are kmem_defrag_get_func (void *get(struct kmem_cache *s, int nr, void **objects)) Must obtain a reference to the listed objects. SLUB guarantees that the objects are still allocated. However, other threads may be blocked in slab_free() attempting to free objects in the slab. These may succeed as soon as get() returns to the slab allocator. The function must be able to detect such situations and void the attempts to free such objects (by for example voiding the corresponding entry in the objects array). No slab operations may be performed in get(). Interrupts are disabled. What can be done is very limited. The slab lock for the page that contains the object is taken. Any attempt to perform a slab operation may lead to a deadlock. kmem_defrag_get_func returns a private pointer that is passed to kmem_defrag_kick_func(). Should we be unable to obtain all references then that pointer may indicate to the kick() function that it should not attempt any object removal or move but simply remove the reference counts. kmem_defrag_kick_func (void kick(struct kmem_cache *, int nr, void **objects, void *get_result)) After SLUB has established references to the objects in a slab it will then drop all locks and use kick() to move objects out of the slab. The existence of the object is guaranteed by virtue of the earlier obtained references via kmem_defrag_get_func(). The callback may perform any slab operation since no locks are held at the time of call. The callback should remove the object from the slab in some way. This may be accomplished by reclaiming the object and then running kmem_cache_free() or reallocating it and then running kmem_cache_free(). Reallocation is advantageous because the partial slabs were just sorted to have the partial slabs with the most objects first. Reallocation is likely to result in filling up a slab in addition to freeing up one slab. A filled up slab can also be removed from the partial list. So there could be a double effect. kmem_defrag_kick_func() does not return a result. SLUB will check the number of remaining objects in the slab. If all objects were removed then the operation was successful. Reviewed-by: Rik van Riel Signed-off-by: Christoph Lameter Signed-off-by: Pekka Enberg Signed-off-by: Christoph Lameter Signed-off-by: Pekka Enberg commit acfa6641f4b17ff55f9e5d76d6e5ded5f29ca0be Author: Christoph Lameter Date: Mon Aug 11 08:06:20 2008 -0700 slub: Sort slab cache list and establish maximum objects for defrag slabs When defragmenting slabs then it is advantageous to have all defragmentable slabs together at the beginning of the list so that there is no need to scan the complete list. Put defragmentable caches first when adding a slab cache and others last. Determine the maximum number of objects in defragmentable slabs. This allows to size the allocation of arrays holding refs to these objects later. Reviewed-by: Rik van Riel Signed-off-by: Christoph Lameter Signed-off-by: Pekka Enberg Signed-off-by: Christoph Lameter Signed-off-by: Pekka Enberg commit c8d2e2c3f6a217a6befbdc71f86803b1d5247c46 Author: Christoph Lameter Date: Mon Aug 11 08:06:19 2008 -0700 slub: Add get() and kick() methods Add the two methods needed for defragmentation and add the display of the methods via the proc interface. Add documentation explaining the use of these methods and the prototypes for slab.h. Add functions to setup the defrag methods for a slab cache. Add empty functions for SLAB/SLOB. The API is generic so it could be theoretically implemented for either allocator. Reviewed-by: Rik van Riel Signed-off-by: Christoph Lameter Signed-off-by: Pekka Enberg Signed-off-by: Christoph Lameter Signed-off-by: Pekka Enberg commit 396113e5523cb2aee50e80635a455e13c8d737fe Author: Christoph Lameter Date: Mon Aug 11 08:06:18 2008 -0700 slub: Replace ctor field with ops field in /sys/slab/* Create an ops field in /sys/slab/*/ops to contain all the operations defined on a slab. This will be used to display the additional operations that will be defined soon. Reviewed-by: Rik van Riel Signed-off-by: Christoph Lameter Signed-off-by: Pekka Enberg Signed-off-by: Christoph Lameter Signed-off-by: Pekka Enberg commit 13670fa2a68ae2d8cee47386fa3e2c24300f3d10 Author: Christoph Lameter Date: Mon Aug 11 08:06:17 2008 -0700 slub: Add defrag_ratio field and sysfs support. The defrag_ratio is used to set the threshold at which defragmentation should be attempted on a slab page. The allocation ratio is measured by the percentage of the available slots allocated. Add a defrag ratio field and set it to 30% by default. A limit of 30% specified that less than 3 out of 10 available slots for objects are in use before slab defragmeentation runs. Reviewed-by: Rik van Riel Signed-off-by: Christoph Lameter Signed-off-by: Pekka Enberg Signed-off-by: Christoph Lameter Signed-off-by: Pekka Enberg commit 1e058f1bdced1ea0e16e1d072d8a00ed4b23c444 Author: David Howells Date: Tue Aug 12 10:24:54 2008 +0100 CRED: Fix IA64 COW credentials handling Fix the IA64 arch's use of COW credentials. Signed-off-by: David Howells Tested-by: Kamalesh Babulal Signed-off-by: James Morris commit ca80290ebda9009aedc4bd93ede5d397cb1853dc Author: J. Bruce Fields Date: Thu Aug 7 13:00:20 2008 -0400 nfsd: permit unauthenticated stat of export root RFC 2623 section 2.3.2 permits the server to bypass gss authentication checks for certain operations that a client may perform when mounting. In the case of a client that doesn't have some form of credentials available to it on boot, this allows it to perform the mount unattended. (Presumably real file access won't be needed until a user with credentials logs in.) Being slightly more lenient allows lots of old clients to access krb5-only exports, with the only loss being a small amount of information leaked about the root directory of the export. This affects only v2 and v3; v4 still requires authentication for all access. Thanks to Peter Staubach testing against a Solaris client, which suggesting addition of v3 getattr, to the list, and to Trond for noting that doing so exposes no additional information. Signed-off-by: J. Bruce Fields Cc: Peter Staubach Cc: Trond Myklebust commit ff3a005265214f833452a6ad9678265f1779cc54 Author: Libin Yang Date: Tue Aug 12 12:25:46 2008 +0200 ALSA: hda - support new AMD HDMI Audio (1002:970f) Signed-off-by: Libin Yang Signed-off-by: Takashi Iwai commit 72a9c938443d1b10150966b55d9a04f4a8fe5790 Author: Dave Hansen Date: Mon Aug 11 10:01:49 2008 -0700 KVM: Reduce stack usage in kvm_pv_mmu_op() We're in a hot path. We can't use kmalloc() because it might impact performance. So, we just stick the buffer that we need into the kvm_vcpu_arch structure. This is used very often, so it is not really a waste. We also have to move the buffer structure's definition to the arch-specific x86 kvm header. Signed-off-by: Dave Hansen Signed-off-by: Avi Kivity commit 3242dad12ed9e8c278b742f48f85703d2885af6e Author: Dave Hansen Date: Mon Aug 11 10:01:47 2008 -0700 KVM: Reduce stack usage in kvm_arch_vcpu_ioctl() Signed-off-by: Dave Hansen Signed-off-by: Avi Kivity commit b622d0035b9933072932ded3b2ac2a488767c78f Author: Dave Hansen Date: Mon Aug 11 10:01:46 2008 -0700 KVM: Reduce stack usage in kvm_vcpu_ioctl() Signed-off-by: Dave Hansen Signed-off-by: Avi Kivity commit e46dfac7a7266b097e67a8d669241d7bc9eed30a Author: Dave Hansen Date: Mon Aug 11 10:01:45 2008 -0700 KVM: Reduce kvm stack usage in kvm_arch_vm_ioctl() On my machine with gcc 3.4, kvm uses ~2k of stack in a few select functions. This is mostly because gcc fails to notice that the different case: statements could have their stack usage combined. It overflows very nicely if interrupts happen during one of these large uses. This patch uses two methods for reducing stack usage. 1. dynamically allocate large objects instead of putting on the stack. 2. Use a union{} member for all of the case variables. This tricks gcc into combining them all into a single stack allocation. (There's also a comment on this) Signed-off-by: Dave Hansen Signed-off-by: Avi Kivity commit ada01f2513450837aeb6ae9d9c771624921ba50a Author: Dmitry Baryshkov Date: Tue Aug 12 02:45:31 2008 +0400 ALSA: wm8750: add missing VREF output Add missing output VREF. After a65f0568f6cc8433877fb71dd7d36b551854b0bc it's critical, since it makes chip routing initialisation to fail. Signed-off-by: Dmitry Baryshkov Acked-by: Mark Brown Signed-off-by: Takashi Iwai commit a19cf98fa78e2ed1f2b67af2a43c11e95d6f6f8e Author: Dmitry Baryshkov Date: Tue Aug 12 02:45:30 2008 +0400 ALSA: spitz: MONO -> MONO1 Correct route name to be MONO1 instead of MONO to follow recent fix in wm8750. Signed-off-by: Dmitry Baryshkov Acked-by: Mark Brown Signed-off-by: Takashi Iwai commit 36cd4fb5d277f34fe9e4db0deac2d4efd7dff735 Author: Adrian Hunter Date: Wed Aug 6 10:08:46 2008 +0300 [MTD] [OneNAND] Add OMAP2 / OMAP3 OneNAND driver This driver had resided in the OMAP tree but is now to be in MTD. Original authors were: Jarkko Lavinen and Juha Yrjölä IRQ and DMA support written by Timo Teras Signed-off-by: Adrian Hunter Signed-off-by: David Woodhouse commit bb0eb217c980d50c45f3e793b4dcc70ab9ee820d Author: Adrian Hunter Date: Tue Aug 12 12:40:50 2008 +0300 [MTD] Define and use MTD_FAIL_ADDR_UNKNOWN instead of 0xffffffff Signed-off-by: Adrian Hunter Signed-off-by: David Woodhouse commit 5aa411849f1a95d94ec96ff49d9f973dee6ff0f3 Author: Ben Dooks Date: Sun Aug 10 23:45:24 2008 +0200 mfd: update sm501 debugging/low information messages Make the default output of the SM501 driver to be less noisy wrt to message that have low informational value, or simply should be debug. Signed-off-by: Ben Dooks Signed-off-by: Andrew Morton Signed-off-by: Samuel Ortiz commit de18f4b0ab4c35255aa150d670d4c6155ee5e4e3 Author: Ian Molton Date: Fri Jul 25 22:59:29 2008 +0100 mfd: reduce stack usage in mfd-core.c This patch moves the allocation of the resources off the stack in mfd_add_device(). Signed-off-by: Ian Molton Signed-off-by: Samuel Ortiz commit 99809963c99e1ed868d9ebeb4a5e7ee1cbe0309f Author: Jeff Chua Date: Wed Aug 6 19:09:53 2008 +0800 x86: make sparsemem more available With CONFIG_X86_PC, I can set CONFIG_SPARSEMEM=y. With CONFIG_X86_GENERICARCH, CONFIG_SPARSEMEM depends on CONFIG_NUMA. I'm using the patch below to enable sparsemem instead of flatmem. System booted and is running. Signed-off-by: Ingo Molnar commit b55793f7528ce1b73c25b3ac8a86a6cda2a0f9a4 Author: Andreas Herrmann Date: Wed Aug 6 10:29:37 2008 +0200 x86: cpu_init(): fix memory leak when using CPU hotplug Exception stacks are allocated each time a CPU is set online. But the allocated space is never freed. Thus with one CPU hotplug offline/online cycle there is a memory leak of 24K (6 pages) for a CPU. Fix is to allocate exception stacks only once -- when the CPU is set online for the first time. Signed-off-by: Andreas Herrmann Cc: akpm@linux-foundation.org Signed-off-by: Ingo Molnar commit 49800efcb17afdf973f33e8aa8807b7f83993cc6 Author: Andreas Herrmann Date: Wed Aug 6 10:27:30 2008 +0200 x86: pda_init(): fix memory leak when using CPU hotplug pda->irqstackptr is allocated whenever a CPU is set online. But it is never freed. This results in a memory leak of 16K for each CPU offline/online cycle. Fix is to allocate pda->irqstackptr only once. Signed-off-by: Andreas Herrmann Cc: akpm@linux-foundation.org Signed-off-by: Ingo Molnar commit 59f09ba2b62e6f89beeb4c8fc2c83fe14321dda9 Author: Philipp Kohlbecher Date: Wed Aug 6 15:25:26 2008 +0200 x86: fix comment in protected mode header Comments in arch/x86/boot/compressed/head_32.S erroneously refer to the real mode pointer as the second and the heap area as the third argument to decompress_kernel(). In fact, these have been the first and second argument, respectively, since v2.6.20. This patch corrects the comments. It introduces no code changes. Signed-off-by: Philipp Kohlbecher Signed-off-by: Ingo Molnar commit 012f09e7942716d5f4339f1fd9a831a485bb1d4a Author: Andreas Herrmann Date: Wed Aug 6 16:23:08 2008 +0200 x86: compile pat debugfs interface only if CONFIG_X86_PAT is set Recently I've run a kernel w/o PAT support and wondered why there was a file "x86/pat_memtype_list" in debugfs. Of course it's empty if PAT is disabled ... so just get rid of this interface if PAT is disabled. Signed-off-by: Andreas Herrmann Signed-off-by: Ingo Molnar commit d0e8c47c58575b9131e786edb488fd029eba443e Author: Chen Gong Date: Mon Aug 11 16:59:15 2008 +0800 [MTD] m25p80.c extended jedec support - add extended device information support - add s25sl128 device support Signed-off-by: Chen Gong Signed-off-by: David Woodhouse commit 75d0ee2202b5740e94e913d8a52f91c6557c4c81 Author: Chen Gong Date: Mon Aug 11 16:59:14 2008 +0800 [MTD] m25p80.c code cleanup code cleanup for m25p80.c Signed-off-by: Chen Gong Signed-off-by: David Woodhouse commit faff37508a104e9ec5285d5adecaab7e8dde472a Author: Chen Gong Date: Mon Aug 11 16:59:13 2008 +0800 [MTD] m25p80.c erase enhance This patch adds an erase_block command to enhance erase operation Signed-off-by: Chen Gong Signed-off-by: David Woodhouse commit d483492cb5401283b3c6e46b829fec0b42297e68 Author: Huang Weiyi Date: Sun Aug 10 18:46:50 2008 +0800 [MTD] [NAND] drivers/mtd/nand/nandsim.c: remove duplicated #include Removed duplicated include in drivers/mtd/nand/nandsim.c. Signed-off-by: Huang Weiyi Signed-off-by: David Woodhouse commit 7c13e6a3d15a4ebcc3f40df5f4d19665479f8ca3 Author: Dimitri Sivanich Date: Mon Aug 11 10:46:46 2008 -0500 x86: remove EXPERIMENTAL restriction from CONFIG_HOTPLUG_CPU This removes the EXPERIMENTAL restriction from CONFIG_HOTPLUG_CPU on the x86 architecture. Signed-off-by: Dimitri Sivanich Signed-off-by: Ingo Molnar commit d3657a3672a87efb95993611cb6fe4d1ed6e92ed Author: Takashi Iwai Date: Mon Aug 11 18:08:54 2008 +0200 ALSA: hda - initialize node 0x21 properly on AD1988 codecs The widget node 0x21 should be initialized as unmuted/full (0dB) as default. This will reduce additional manual work by user at the first time use. Signed-off-by: Takashi Iwai commit 2ae111cdd8d83ebf9de72e36e68a8c84b6ebbeea Author: Cyrill Gorcunov Date: Mon Aug 11 18:34:08 2008 +0400 x86: apic interrupts - move assignments to irqinit_32.c, v2 64bit mode APIC interrupt handlers are set within irqinit_64.c. Lets do tha same for 32bit mode which would help in furter code merging. Signed-off-by: Cyrill Gorcunov Signed-off-by: Ingo Molnar commit e48f4444c5f8199e8ab5e77705385d238e9c10a8 Author: Bob Moore Date: Mon Aug 4 11:15:11 2008 +0800 ACPICA: Update version to 20080729 Update acconfig.h Signed-off-by: Bob Moore Signed-off-by: Lin Ming Signed-off-by: Andi Kleen commit 126dbb9d81a0001878f21b206533355b7aff9812 Author: Bob Moore Date: Mon Aug 4 10:42:47 2008 +0800 ACPICA: x2APIC support: changes for MADT and SRAT ACPI tables Support for the x2APIC. There are 2 new subtables for the MADT and one new subtable for the SRAT. Includes disassembler and AcpiSrc support. Data from the Intel 64 Architecture x2APIC Specification, June 2008. Signed-off-by: Bob Moore Signed-off-by: Lin Ming Signed-off-by: Andi Kleen commit ba27705d679055e8feb985ad4818ea1729e17253 Author: Bob Moore Date: Mon Aug 4 10:41:29 2008 +0800 ACPICA: Improve object conversion error messages Better error messages during object conversion from internal to the external ACPI_OBJECT. Used for external calls to AcpiEvaluateObject. Signed-off-by: Bob Moore Signed-off-by: Lin Ming Signed-off-by: Andi Kleen commit 01b60aaaeac0d45195dfc0a2815582bd06d94e79 Author: Bob Moore Date: Mon Aug 4 10:40:09 2008 +0800 ACPICA: Add function to decode reference obj types to strings Created for improved error messages. Signed-off-by: Bob Moore Signed-off-by: Lin Ming Signed-off-by: Andi Kleen commit 888cfd8325083227e5bab83161b6c5499eff55c3 Author: Bob Moore Date: Mon Aug 4 10:12:31 2008 +0800 ACPICA: Update version to 20080701 Update version to 20080701. Signed-off-by: Bob Moore Signed-off-by: Lin Ming Signed-off-by: Andi Kleen commit 52875deaff6e7e23bb4d57b89b272e9ecf7812a8 Author: Bob Moore Date: Fri Jul 4 10:53:58 2008 +0800 ACPICA: Return method arg count from acpi_get_object_info Also update the debugger so that the correct number of arguments is passed to the method. Prevents a warning message from the debugger. Signed-off-by: Bob Moore Signed-off-by: Lin Ming Signed-off-by: Andi Kleen commit cef7a67fa178f27de697eca48e2b648f2ce3f30f Author: Bob Moore Date: Mon Aug 4 09:54:17 2008 +0800 Cleanup macro definition file. Removed unused macros. Ensure that multiple parameters always have a space after a comma. Cleanup some comments. Signed-off-by: Bob Moore Signed-off-by: Lin Ming Signed-off-by: Andi Kleen commit fe47d850fb4fe77751f3a7a6d6f03c6da2418b7d Author: Bob Moore Date: Mon Aug 4 11:13:01 2008 +0800 ACPICA: Additional error checking for pathname utilities Add error check after all calls to acpi_ns_get_pathname_length. Add status return from acpi_ns_build_external_path and check after all calls. Add parameter validation to acpi_ut_initialize_buffer. Reported by and initial patch by Ingo Molnar. http://lkml.org/lkml/2008/7/21/176 Signed-off-by: Bob Moore Signed-off-by: Lin Ming Signed-off-by: Andi Kleen commit 905272f4539472d513a8412926a1dd413558915a Author: Bob Moore Date: Mon Aug 4 13:22:10 2008 +0800 ACPICA: Add function to dereference returned reference objects Examines the return object from a call to acpi_evaluate_object. Any Index or RefOf references are automatically dereferenced in an attempt to return something useful (these reference types cannot be converted into an external ACPI_OBJECT.) Lin Ming, Bob Moore. Linux BZ 11105 http://bugzilla.kernel.org/show_bug.cgi?id=11105 Signed-off-by: Lin Ming Signed-off-by: Bob Moore Signed-off-by: Andi Kleen commit f515f652f6a062af38360884e81b7752024e6cc9 Author: Yi Yang Date: Mon Aug 4 10:30:09 2008 +0800 ACPICA: Return status from global init function Return status from AcpiUtGlobalInitialize. This is used by both the kernel subsystem and the utilities such as iASL compiler. The function could possibly fail when the caches are initialized. Yang Yi. Signed-off-by: Yi Yang Signed-off-by: Bob Moore Signed-off-by: Lin Ming Signed-off-by: Andi Kleen commit fc038d6c39b59e583817790fca8ab3e8eb536d39 Author: Bob Moore Date: Fri Jul 4 10:57:51 2008 +0800 ACPICA: Fix table compare code, length then data Split the ACPI table compare. First check that the lengths match exactly. Then compare the data. Signed-off-by: Bob Moore Signed-off-by: Lin Ming Signed-off-by: Andi Kleen commit ee95966b73d04dfb28c27b15f74251cce93cfcda Author: Bob Moore Date: Fri Jul 4 10:56:13 2008 +0800 ACPICA: Fix wrong resource descriptor length for 64-bit build The "minimal" descriptors such as EndTag are calculated as 12 bytes long, but the actual length in the internal descriptor is 16 because of the round-up to 8 on 64-bit build. BZ 728 http://www.acpica.org/bugzilla/show_bug.cgi?id=728 Signed-off-by: Bob Moore Signed-off-by: Lin Ming Signed-off-by: Andi Kleen commit 6e03ea2307da3fcc6c45f95ee424d225d4b0b676 Author: Lin Ming Date: Fri Jul 4 10:51:41 2008 +0800 ACPICA: Fix possible memory leak in Unload() operator The DdbHandle returned by Load() does not have its reference count decremented during unload, leading to a memory leak. Lin Ming. Signed-off-by: Lin Ming Signed-off-by: Bob Moore Signed-off-by: Andi Kleen commit 42a2d497c553e860f5354aeb269eb5f7f65dd97f Author: Bob Moore Date: Fri Jul 4 10:48:43 2008 +0800 ACPICA: Allow same ACPI table to be loaded/unloaded more than once Without this change, a table cannot be loaded again once it has been loaded/unloaded one time. The current mechanism does not unregister a table upon an unload. During a load, if the same table is found, this no longer returns an exception. BZ 722 http://www.acpica.org/bugzilla/show_bug.cgi?id=722 Signed-off-by: Bob Moore Signed-off-by: Lin Ming Signed-off-by: Andi Kleen commit 09a2a7a9e5cbd5c2b1c2018666052135bb662bc2 Author: Bob Moore Date: Fri Jul 4 10:41:41 2008 +0800 ACPICA: Fix memory leak when deleting thermal/processor objects Fixes a possible memory leak when thermal and processor objects are deleted. Any associated notify handlers (and objects) were not being deleted. Fiodor Suietov. BZ 506 http://www.acpica.org/bugzilla/show_bug.cgi?id=506 Signed-off-by: Fiodor Suietov Signed-off-by: Bob Moore Signed-off-by: Lin Ming Signed-off-by: Andi Kleen commit 7a866af502456703a15fd6a7fce8d719428530d6 Author: Bob Moore Date: Fri Jul 4 10:18:34 2008 +0800 ACPICA: Add check for invalid handle in acpi_get_object_info Return AE_BAD_PARAMETER if input handle is invalid. BZ 474 http://www.acpica.org/bugzilla/show_bug.cgi?id=474 Signed-off-by: Fiodor Suietov Signed-off-by: Bob Moore Signed-off-by: Lin Ming Signed-off-by: Andi Kleen commit 908c8140f49b3b2374bd47ef666a42c5d1cb0616 Author: Bob Moore Date: Mon Aug 4 10:09:26 2008 +0800 ACPICA: Fix warning for 64-bit build Fixes warning from exconfig.c on 64-bit build. Signed-off-by: Bob Moore Signed-off-by: Lin Ming Signed-off-by: Andi Kleen commit 5c7f5b3d631a54c12005edba2be1695246c51eca Author: Bob Moore Date: Fri Jul 4 10:06:47 2008 +0800 ACPICA: Copy dynamically loaded tables to local buffer Previously, dynamically loaded tables were simply mapped, but on some machines this memory is corrupted after suspend. Now copy the table to a local buffer. For OpRegion case, added checksum verify. Use the table length from the table header, not the region length. For Buffer case, use the table length also. Dennis Noordsij, Bob Moore. BZ 10734 http://bugzilla.kernel.org/show_bug.cgi?id=10734 Signed-off-by: Dennis Noordsij Signed-off-by: Bob Moore Signed-off-by: Lin Ming Signed-off-by: Andi Kleen commit d97332faafc82766eb68f90da942670737fcbc3f Author: Randy Dunlap Date: Wed Aug 6 17:29:38 2008 -0700 Panasonic ACPI depends on INPUT Panasonic ACPI driver needs to depend on INPUT. Otherwise it has build errors when CONFIG_INPUT=n: drivers/built-in.o: In function `acpi_pcc_hotkey_remove': pcc_acpi.c:(.text+0x25ded): undefined reference to `input_unregister_device' pcc_acpi.c:(.text+0x25e03): undefined reference to `input_free_device' drivers/built-in.o: In function `acpi_pcc_hotkey_notify': pcc_acpi.c:(.text+0x260d5): undefined reference to `input_event' pcc_acpi.c:(.text+0x260e2): undefined reference to `input_event' drivers/built-in.o: In function `acpi_pcc_hotkey_add': pcc_acpi.c:(.text+0x26267): undefined reference to `input_allocate_device' pcc_acpi.c:(.text+0x26348): undefined reference to `input_register_device' pcc_acpi.c:(.text+0x26405): undefined reference to `input_unregister_device' pcc_acpi.c:(.text+0x26423): undefined reference to `input_free_device' make[1]: *** [.tmp_vmlinux1] Error 1 Signed-off-by: Randy Dunlap Signed-off-by: Andi Kleen commit 42db3f16783f58348cec9055dbf7d7bd05bb3e4d Author: Zhao Yakui Date: Mon Aug 11 10:33:31 2008 +0800 ACPI: Avoid bogus EC timeout when EC is in Polling mode When EC is in Polling mode, OS will check the EC status continually by using the following source code: clear_bit(EC_FLAGS_WAIT_GPE, &ec->flags); while (time_before(jiffies, delay)) { if (acpi_ec_check_status(ec, event)) return 0; msleep(1); } But msleep is realized by the function of schedule_timeout. At the same time although one process is already waken up by some events, it won't be scheduled immediately. So maybe there exists the following phenomena: a. The current jiffies is already after the predefined jiffies. But before timeout happens, OS has no chance to check the EC status again. b. If preemptible schedule is enabled, maybe preempt schedule will happen before checking loop. When the process is resumed again, maybe timeout already happens, which means that OS has no chance to check the EC status. In such case maybe EC status is already what OS expects when timeout happens. But OS has no chance to check the EC status and regards it as AE_TIME. So it will be more appropriate that OS will try to check the EC status again when timeout happens. If the EC status is what we expect, it won't be regarded as timeout. Only when the EC status is not what we expect, it will be regarded as timeout, which means that EC controller can't give a response in time. http://bugzilla.kernel.org/show_bug.cgi?id=9823 http://bugzilla.kernel.org/show_bug.cgi?id=11141 Signed-off-by: Zhao Yakui Signed-off-by: Zhang Rui Signed-off-by: Andi Kleen commit 90dd975438b08cd7a51a3919f09ee485a238016d Author: Carlos Corbacho Date: Wed Aug 6 19:14:45 2008 +0100 acer-wmi: Add mail LED quirk for Acer TravelMate 4280 series Reported-by: Mattias Jernberg Signed-off-by: Carlos Corbacho Signed-off-by: Andi Kleen commit 70ea586cc54ab2fb2af42d7ee97ba4f26e315f45 Author: Carlos Corbacho Date: Wed Aug 6 19:13:56 2008 +0100 acer-wmi: Fix wireless and bluetooth on early AMW0 v2 laptops In the old acer_acpi, I discovered that on some of the newer AMW0 laptops that supported the WMID methods, they don't work properly for setting the wireless and bluetooth values. So for the AMW0 V2 laptops, we want to use both the 'old' AMW0 and the 'new' WMID methods for setting wireless & bluetooth to guarantee we always enable it. This was fixed in acer_acpi some time ago, but I forgot to port the patch over to acer-wmi when it was merged. (Without this patch, early AMW0 V2 laptops such as the Aspire 5040 won't work with acer-wmi, where-as they did with the old acer_acpi). Signed-off-by: Carlos Corbacho CC: stable@kernel.org Signed-off-by: Andi Kleen commit d0434dfc70faa6cb981013eeeda6545c8fbe03e9 Author: Carlos Corbacho Date: Sat Aug 2 17:28:45 2008 +0100 ACPI: WMI: Set instance for query block calls ACPI: WMI: Set instance for query block calls From: Carlos Corbacho Although the necessary data structure was set up, it was never actually passed in, so data block calls have only been working by sheer chance. (On Acer laptops. the data block methods we've been calling never look at the instance value, hence acer-wmi never triggered this before). f3454ae8104efb2dbf0d08ec42c6f5d0fe9225bc brought this to light. Signed-off-by: Carlos Corbacho Signed-off-by: Andi Kleen commit ec26796b0941d81513a7d1f03ba77353d3754dfa Author: Matthew Garrett Date: Wed Aug 6 19:12:04 2008 +0100 Clear WAK_STS on resume The leading other brand OS appears to clear the WAK_STS flag on resume. When rebooted, certain BIOSes assume that the system is actually resuming if it's still set and so fail to reboot correctly. Make sure that it's cleared at resume time. Comment clarified as suggested by Bob Moore Signed-off-by: Matthew Garrett Signed-off-by: Andi Kleen commit 2a7feab28d3fc060d320eaba192e49dad1079b7e Author: Holger Macht Date: Wed Aug 6 17:56:01 2008 +0200 ACPI: Properly clear flags on false-positives and send uevent on sudden unplug Some devices emit a ACPI_NOTIFY_DEVICE_CHECK while physically unplugging even if the software undock has already been done and dock_present() check fails. However, the internal flags need to be cleared (complete_undock()). Also, even notify userspace if the dock station suddently went away without proper software undocking. This happens on a Acer TravelMate 3000 Signed-off-by: Holger Macht Signed-off-by: Andi Kleen commit ba2058572ac27e3a8a0ca570dab0cf70b210cdb1 Author: Zhao Yakui Date: Mon Aug 11 13:40:22 2008 +0800 ACPI : Load device driver according to the status of acpi device According to ACPI spec when the status of some device is not present but functional, the device is valid and the children of this device should be enumerated. It means that the device should be added to linux acpi device tree. But the device driver for this device should not be loaded. The detailed info can be found in the section 6.3.7 of ACPI 3.0b spec. _STA may return bit 0 clear (not present) with bit 3 set (device is functional). This case is used to indicate a valid device for which no device driver should be loaded (for example, a bridge device.). Children of this device may be present and valid. OS should continue enumeration below a device whose _STA returns this bit combination http://bugzilla.kernel.org/show_bug.cgi?id=3358 Signed-off-by: Zhao Yakui Signed-off-by: Li Shaohua Signed-off-by: Zhang Rui Signed-off-by: Andi Kleen commit 0873f0a5e39668e869bf717c843a201e7aa8640b Author: Zhao Yakui Date: Mon Aug 11 14:59:59 2008 +0800 ACPI: Add DMI check to disable power state check in power transition Add the DMI check to disable power check in the course of device power transistion. http://bugzilla.kernel.org/show_bug.cgi?id=11000 Signed-off-by: Zhao Yakui Signed-off-by: Li Shaohua Signed-off-by: Andi Kleen commit 1382827e93799ec07790849e361267993cfe549e Author: Zhao Yakui Date: Mon Aug 11 14:57:50 2008 +0800 ACPI: Add "acpi.power_nocheck=1" to disable power state check in power transition Maybe the incorrect power state is returned on the bogus bios, which is different with the real power state. For example: the bios returns D0 state and the real power state is D3. OS expects to set the device to D0 state. In such case if OS uses the power state returned by the BIOS and checks the device power state very strictly in power transition, the device can't be transited to the correct power state. So the boot option of "acpi.power_nocheck=1" is added to avoid checking the device power in the course of device power transition. http://bugzilla.kernel.org/show_bug.cgi?id=8049 http://bugzilla.kernel.org/show_bug.cgi?id=11000 Signed-off-by: Zhao Yakui Signed-off-by: Zhang Rui Signed-off-by: Li Shaohua Signed-off-by: Andi Kleen commit ced9cd40ac14111befd6b0c73ec90106c22a3fd7 Author: Ingo Molnar Date: Mon Aug 11 14:38:12 2008 +0200 printk: robustify printk, fix fix: include/linux/kernel.h: In function ‘printk_needs_cpu': include/linux/kernel.h:217: error: parameter name omitted Signed-off-by: Ingo Molnar commit ad166a4bc01f13607ab9165c12ba97f0c455e4de Author: Zhao Yakui Date: Mon Aug 11 14:54:16 2008 +0800 ACPI: Attach the ACPI device to the ACPI handle as early as possible Attach the ACPI device to the ACPI handle as early as possible so that OS can get the corresponding ACPI device by the acpi handle in the course of getting the power/wakeup/performance flags. http://bugzilla.kernel.org/show_bug.cgi?id=8049 http://bugzilla.kernel.org/show_bug.cgi?id=11000 Signed-off-by: Zhao Yakui Signed-off-by: Zhang Rui Signed-off-by: Andi Kleen commit fba5325bf1db7e09e233c669c0030ed0ed5a139a Author: Zhao Yakui Date: Mon Aug 11 14:55:05 2008 +0800 ACPI: Get the device power state in the course of scanning device Get the device power state in the course of scanning device if the device power flag is power_managable. i.e. The device has the _PSx/_PRx object. At the same time before the drivers/acpi/power module is loaded, there is no relation between acpi_power_resource and acpi device. So the first parameter of acpi_power_get_state is changed to acpi_handle. http://bugzilla.kernel.org/show_bug.cgi?id=8049 http://bugzilla.kernel.org/show_bug.cgi?id=11000 Signed-off-by: Zhao Yakui Signed-off-by: Li Shaohua Signed-off-by: Andi Kleen commit dfaa27030913d153de7e101f6c24a9096d2be5b9 Author: Lin Ming Date: Fri Aug 8 11:57:11 2008 +0800 acpi: replace AE_BAD_ADDRESS exception code with AE_ERROR The AE_BAD_ADDRESS exception code is now unused in ACPICA. For linux, it's only used at wmi.c and acer-wmi.c. I checked both wmi.c and acer-wmi.c, the AE_BAD_ADDRESS exception code has no special meaning. The parent functions just call AE_SUCCESS() or AE_FAILURE() to check the return status. So it's safe to replace AE_BAD_ADDRESS with AE_ERROR. Signed-off-by Lin Ming Signed-off-by: Andi Kleen commit ae3d469c8162c01c1577c53833479de98a338ead Author: Andi Kleen Date: Mon Aug 11 15:03:20 2008 +0200 ACPI: Add missing acpi.debug_layer Documentation hunk from Thomas Renninger Signed-off-by: Andi Kleen commit b845b517b5e3706a3729f6ea83b88ab85f0725b0 Author: Peter Zijlstra Date: Fri Aug 8 21:47:09 2008 +0200 printk: robustify printk Avoid deadlocks against rq->lock and xtime_lock by deferring the klogd wakeup by polling from the timer tick. Signed-off-by: Peter Zijlstra Signed-off-by: Ingo Molnar commit 78635fc739b1254f3e0362ac430edbdd2cff01dc Author: Ingo Molnar Date: Mon Aug 11 13:34:15 2008 +0200 rcu, debug: detect stalled grace periods, cleanups small cleanups. Signed-off-by: Ingo Molnar commit 67182ae1c42206e516f7efb292b745e826497b24 Author: Paul E. McKenney Date: Sun Aug 10 18:35:38 2008 -0700 rcu, debug: detect stalled grace periods this is a diagnostic patch for Classic RCU. The approach is to record a timestamp at the beginning of the grace period (in rcu_start_batch()), then have rcu_check_callbacks() complain if: 1. it is running on a CPU that has holding up grace periods for a long time (say one second). This will identify the culprit assuming that the culprit has not disabled hardware irqs, instruction execution, or some such. 2. it is running on a CPU that is not holding up grace periods, but grace periods have been held up for an even longer time (say two seconds). It is enabled via the default-off CONFIG_DEBUG_RCU_STALL kernel parameter. Rather than exponential backoff, it backs off to once per 30 seconds. My feeling upon thinking on it was that if you have stalled RCU grace periods for that long, a few extra printk() messages are probably the least of your worries... Signed-off-by: Paul E. McKenney Cc: Peter Zijlstra Cc: Yinghai Lu Cc: David Witbrodt Signed-off-by: Ingo Molnar commit 8aeb4022633f7d0eca5e13a9622bd73df92bbf2a Author: Huang Weiyi Date: Sun Aug 10 21:09:22 2008 +0800 arch/x86/kernel/cpuid.c: removed duplicated #include Removed duplicated include file in arch/x86/kernel/cpuid.c. Signed-off-by: Huang Weiyi Signed-off-by: Ingo Molnar commit 4c942654a4514d7d0a9b592a7d1b198a212e8a03 Author: Huang Weiyi Date: Sun Aug 10 20:57:45 2008 +0800 arch/x86/kernel/acpi/boot.c: removed duplicated #include Removed duplicated include file in arch/x86/kernel/acpi/boot.c. Signed-off-by: Huang Weiyi Signed-off-by: Ingo Molnar commit 380a8e072619c9007e04a0456a7326e61bcd882f Author: Takashi Iwai Date: Mon Aug 11 10:04:40 2008 +0200 ALSA: hda - Don't reset SPDIF in each status change The SPDIF output is toggled at each time any SPDIF status bits are changed because of the known problems on some codecs. But, this also results in loosing the sync, and the problem is more obvious on HDMI output over SPDIF. Since the toggle is necessary only for some codecs, we should check whether this workaround is needed and skip if unnecessary. Signed-off-by: Takashi Iwai commit 6890cb06a4ee9c9f056a3a83f7a2a0a4b17b63d6 Author: Seth Heasley Date: Fri Aug 8 15:56:39 2008 -0700 ALSA: hda_intel: ALSA HD Audio patch for Intel Ibex Peak DeviceIDs This patch adds the Intel Ibex Peak (PCH) HD Audio Controller DeviceIDs. Signed-off by: Seth Heasley Signed-off-by: Takashi Iwai commit 1ea6183ad1fe8288f2a08b4503681f6f48609dc4 Author: Dmitry Baryshkov Date: Sat Aug 9 15:05:28 2008 +0400 ALSA: wm8750: it's MONO1, not MONO Since first commit wm8750 contained output named MONO, but all routes mentioned MONO1. Correct MONO to be MONO1. Signed-off-by: Dmitry Baryshkov Acked-by: Mark Brown Signed-off-by: Takashi Iwai commit 55b909fce742fb2f748be4e038e617cf6739f14b Author: Alexander Beregalov Date: Mon Aug 11 02:52:42 2008 +0400 ALSA: sound/pci/Kconfig: update for ice1712/24 sound/pci/Kconfig: update for ice1712/24 Signed-off-by: Alexander Beregalov Signed-off-by: Takashi Iwai commit cbc5e26b497323ecfb5d35dfe181b5adae69766c Author: Alexander Beregalov Date: Mon Aug 11 02:09:04 2008 +0400 ALSA: ice1724/revo: simple clean up ice1724/revo: simple clean up Signed-off-by: Alexander Beregalov Signed-off-by: Takashi Iwai commit d406d21d90dce2e66c7eb4a44605aac947fe55fb Author: Marcin Slusarz Date: Mon Aug 11 00:09:38 2008 +0200 x86: mpparse.c: fix section mismatch warning WARNING: vmlinux.o(.text+0x118f7): Section mismatch in reference from the function construct_ioapic_table() to the function .init.text:MP_bus_info() The function construct_ioapic_table() references the function __init MP_bus_info(). This is often because construct_ioapic_table lacks a __init annotation or the annotation of MP_bus_info is wrong. construct_ioapic_table is called only from construct_default_ISA_mptable which is __init Signed-off-by: Marcin Slusarz Cc: Thomas Gleixner Cc: Ingo Molnar Cc: H. Peter Anvin Signed-off-by: H. Peter Anvin commit bafc1dae8215c862c2e6ae913ddadc20581e59b9 Author: Marcin Slusarz Date: Mon Aug 11 00:11:13 2008 +0200 x86: mmconf: fix section mismatch warning WARNING: arch/x86/kernel/built-in.o(.cpuinit.text+0x1591): Section mismatch in reference from the function init_amd() to the function .init.text:check_enable_amd_mmconf_dmi() The function __cpuinit init_amd() references a function __init check_enable_amd_mmconf_dmi(). If check_enable_amd_mmconf_dmi is only used by init_amd then annotate check_enable_amd_mmconf_dmi with a matching annotation. check_enable_amd_mmconf_dmi is only called from init_amd which is __cpuinit Signed-off-by: Marcin Slusarz Cc: Thomas Gleixner Cc: Ingo Molnar Cc: H. Peter Anvin Signed-off-by: H. Peter Anvin commit 85a14437ed24244c78f9a70d58b8299753b03c92 Author: Marcin Slusarz Date: Mon Aug 11 00:12:37 2008 +0200 x86: fix MP_processor_info section mismatch warning WARNING: arch/x86/kernel/built-in.o(.cpuinit.text+0x1fe7): Section mismatch in reference from the function MP_processor_info() to the variable .init.data:x86_quirks The function __cpuinit MP_processor_info() references a variable __initdata x86_quirks. If x86_quirks is only used by MP_processor_info then annotate x86_quirks with a matching annotation. MP_processor_info uses x86_quirks which is __init and is used only from smp_read_mpc and construct_default_ISA_mptable which are __init Signed-off-by: Marcin Slusarz Cc: Thomas Gleixner Cc: Ingo Molnar Cc: H. Peter Anvin Signed-off-by: H. Peter Anvin commit 90936cfe6c8f7e90a6f8b0c5cb44d3a012dfd313 Author: Marcin Slusarz Date: Mon Aug 11 00:07:44 2008 +0200 x86, tsc: fix section mismatch warning WARNING: vmlinux.o(.text+0x7950): Section mismatch in reference from the function native_calibrate_tsc() to the function .init.text:tsc_read_refs() The function native_calibrate_tsc() references the function __init tsc_read_refs(). This is often because native_calibrate_tsc lacks a __init annotation or the annotation of tsc_read_refs is wrong. tsc_read_refs is called from native_calibrate_tsc which is not __init and native_calibrate_tsc cannot be marked __init Signed-off-by: Marcin Slusarz Cc: Thomas Gleixner Cc: Ingo Molnar Cc: H. Peter Anvin Signed-off-by: H. Peter Anvin commit 7680a920c75b242adaedf3d93b7f6d253db56792 Author: Sebastian Siewior Date: Mon Apr 28 11:43:16 2008 +0200 m68knommu: use one exist from execption Part of the code that did not make sense to me got removed by Greg. This is part two: The first compare is to check whether the interrupts are disabled or not. Depending on the result we exectute the RESTORE_ALL macro is not only restoring the stack but also returning to caller. The test for pending softirq has been removed because it is allready done in irq_exit(). Since system_call() is allso using the SAVE_ALL macro and returning via ret_from_exception label I see no reason why we could not do this here as well. This is also handy because if we return from the timer interrupt and we need to resched than we check for this :) Signed-off-by: Sebastian Siewior Signed-off-by: Greg Ungerer commit 27afc2b247cc308745a4be755df45e0127fff010 Author: David Howells Date: Mon Aug 11 01:21:10 2008 +0100 CRED: Inc the user processes count on cred share return from copy_creds() Increment the user processes count in the case where copy_creds() returns after sharing the parent's credentials instead of allocating new ones. Signed-off-by: David Howells Signed-off-by: James Morris commit ea40dc0e3240d1dc9743b7d92d0c53783b10c5e5 Author: Harvey Harrison Date: Sat Aug 9 15:56:59 2008 -0700 cred: add static, remove extern on function definitions kernel/cred.c:460:13: warning: function 'revert_creds' with external linkage has definition kernel/cred.c:72:6: warning: symbol 'put_tgcred' was not declared. Should it be static? Signed-off-by: Harvey Harrison Acked-by: David Howells Signed-off-by: James Morris commit e5b8d0a5f8ce9e907237ac8c3bc64c2a0fd2b568 Author: Joe Rouvier Date: Sun Aug 10 00:29:25 2008 -0400 Input: convert drivers to use strict_strtoul() strict_strtoul() allows newline character at the end of the the input string and therefore is more user-friendly. Signed-off-by: Dmitry Torokhov commit 40241a94e773a8af64bbc13ff8a16838c05b95ef Author: David Howells Date: Sat Aug 9 09:07:51 2008 +1000 CRED: Fix inclusion problems Under certain configurations, some .c files obtain linux/sched.h and/or linux/cred.h through other include files, but not under all configurations. A couple of places (one in Coda, one in nfsd) need extra includes. Signed-off-by: David Howells Signed-off-by: James Morris commit 393084e9e8c20c63cef574a6466ec0e59c711727 Author: Roland McGrath Date: Fri Aug 8 15:58:39 2008 -0700 x86: ioperm user_regset This adds a user_regset type for the x86 io permissions bitmap. This makes it appear in core dumps (when ioperm has been used). It will also make it visible to debuggers in the future. Signed-off-by: Roland McGrath Signed-off-by: H. Peter Anvin commit 82a196f481661170b4982dc7e68a12e9253309d0 Author: Sven Anders Date: Fri Aug 8 16:31:33 2008 -0400 Input: appletouch - handle geyser 3/4 status bits Implement support for status bits on Geyser 3/4. Signed-off-by: Sven Anders Signed-off-by: Johannes Berg Signed-off-by: Dmitry Torokhov commit d83d213d9fda671dfd84ea81182742f9e329a6b4 Author: Sven Anders Date: Fri Aug 8 16:31:31 2008 -0400 Input: appletouch - prepare for geyser 3/4 handling Split complete function into separate functions for GEYSER1/2 and GEYSER 3/4. Signed-off-by: Sven Anders Signed-off-by: Johannes Berg Signed-off-by: Dmitry Torokhov commit 621114980de1e236ffa4e72899e226de75031a5f Author: venkatesh.pallipadi@intel.com Date: Mon Aug 4 11:59:12 2008 -0700 [CPUFREQ][6/6] cpufreq: Add idle microaccounting in ondemand governor (take 2) Use get_cpu_idle_time_us() to get micro-accounted idle information. This enables ondemand to get more accurate idle and busy timings than the jiffy based calculation. As a result, we can decrease the ondemand safety gaurd band from 80-10 to 95-3. Results in more aggressive power savings. Signed-off-by: Venkatesh Pallipadi Signed-off-by: Dave Jones commit 4fa90bef5a67731d8cd527f9c775e95bec23749c Author: venkatesh.pallipadi@intel.com Date: Mon Aug 4 11:59:11 2008 -0700 [CPUFREQ][5/6] cpufreq: Changes to get_cpu_idle_time_us(), used by ondemand governor (take 2) export get_cpu_idle_time_us() for it to be used in ondemand governor. Last update time can be current time when the CPU is currently non-idle, accounting for the busy time since last idle. Signed-off-by: Venkatesh Pallipadi Signed-off-by: Dave Jones commit 5d61d1790cdac9df961fecb83270455310d62fe8 Author: venkatesh.pallipadi@intel.com Date: Mon Aug 4 11:59:10 2008 -0700 [CPUFREQ][4/6] cpufreq_ondemand: Parameterize down differential (take 2) Use a parameter for down differential, instead of hardcoded 10%. Follow-on patch changes the down-differential dynamically, based on whether we are using idle micro-accounting or not. Signed-off-by: Venkatesh Pallipadi Signed-off-by: Dave Jones commit 9f106b646dbc750c29df20fc542b83c5eb98eef0 Author: venkatesh.pallipadi@intel.com Date: Mon Aug 4 11:59:09 2008 -0700 [CPUFREQ][3/6] cpufreq: get_cpu_idle_time() changes in ondemand for idle-microaccounting (take 2) Preparatory changes for doing idle micro-accounting in ondemand governor. get_cpu_idle_time() gets extra parameter and returns idle time and also the wall time that corresponds to the idle time measurement. Signed-off-by: Venkatesh Pallipadi Signed-off-by: Dave Jones commit 290c418546ba4e78c25fac62d9768057b0d331f1 Author: venkatesh.pallipadi@intel.com Date: Mon Aug 4 11:59:08 2008 -0700 [CPUFREQ][2/6] cpufreq: Change load calculation in ondemand for software coordination (take 2) Change the load calculation algorithm in ondemand to work well with software coordination of frequency across the dependent cpus. Multiply individual CPU utilization with the average freq of that logical CPU during the measurement interval (using getavg call). And find the max CPU utilization number in terms of CPU freq. That number is then used to get to the target freq for next sampling interval. Signed-off-by: Venkatesh Pallipadi Signed-off-by: Dave Jones commit 94b5cbe9786af6a4041b87671b00a5f7b9d54141 Author: venkatesh.pallipadi@intel.com Date: Mon Aug 4 11:59:07 2008 -0700 [CPUFREQ][1/6] cpufreq: Add cpu number parameter to __cpufreq_driver_getavg() (take 2) Add a cpu parameter to __cpufreq_driver_getavg(). This is needed for software cpufreq coordination where policy->cpu may not be same as the CPU on which we want to getavg frequency. A follow-on patch will use this parameter to getavg freq from all cpus in policy->cpus. Change since last patch. Fix the offline/online and suspend/resume oops reported by Youquan Song Signed-off-by: Venkatesh Pallipadi Signed-off-by: Dave Jones commit f58a6f73ee9c40f9fb9b038786ecbb5b8862b517 Author: Ben Slusky Date: Mon Jul 7 13:16:20 2008 -0400 [CPUFREQ] use deferrable delayed work init in conservative governor Venki Pallipadi made a similar change to the ondemand governor a while back (in commit 28287033e12463c8ff89f1ea8038783d0360391c). It seems to work just as well in the conservative governor, leading to fewer wakeups as reported by powertop. Signed-off-by: Ben Slusky Signed-off-by: Dave Jones commit 0bf801045f19cf10347e86a59888580c5bf34f4e Author: Julia Lawall Date: Fri Jul 25 22:44:53 2008 +0200 [CPUFREQ] drivers/cpufreq/cpufreq.c: Adjust error handling code involving cpufreq_cpu_put After calling cpufreq_cpu_get, error handling code should call cpufreq_cpu_put. The semantic match that finds this problem is as follows: (http://www.emn.fr/x-info/coccinelle/) // @r@ expression x,E; statement S; position p1,p2,p3; @@ ( if ((x = cpufreq_cpu_get@p1(...)) == NULL || ...) S | x = cpufreq_cpu_get@p1(...) ... when != x if (x == NULL || ...) S ) <... if@p3 (...) { ... when != cpufreq_cpu_put(x) when != if (x) { ... cpufreq_cpu_put(x); ...} return@p2 ...; } ...> ( return x; | return 0; | x = E | E = x | cpufreq_cpu_put(x) ) @exists@ position r.p1,r.p2,r.p3; expression x; int ret != 0; statement S; @@ * x = cpufreq_cpu_get@p1(...) <... * if@p3 (...) S ...> * return@p2 \(NULL\|ret\); // Signed-off-by: Julia Lawall Signed-off-by: Dave Jones commit 7d6f699abafcab15ca298bb3a907101889778119 Author: Akinobu Mita Date: Mon Jul 14 12:00:45 2008 +0900 [CPUFREQ] add error handling for cpufreq_register_governor() error Add error handling for cpufreq_register_governor() error Signed-off-by: Akinobu Mita Cc: cpufreq@lists.linux.org.uk Signed-off-by: Dave Jones commit efce92606428f6cc54c96c1199afd6e1c81875be Author: Akinobu Mita Date: Mon Jul 14 11:59:44 2008 +0900 [CPUFREQ] acpi-cpufreq: add error handling for cpufreq_register_driver() error add error handling for cpufreq_register_driver() error Signed-off-by: Akinobu Mita Cc: cpufreq@lists.linux.org.uk Signed-off-by: Dave Jones commit 8128fa2696da44b7577800e2ca7a521963bbe5de Author: Paolo Ciarrocchi Date: Mon Jul 28 21:08:16 2008 +0200 [CPUFREQ] Coding style fixes to arch/x86/kernel/cpu/cpufreq/powernow-k6.c Before: total: 11 errors, 15 warnings, 255 lines checked After: total: 0 errors, 6 warnings, 254 lines checked paolo@paolo-desktop:~/linux.trees.git$ md5sum /tmp/powernow-k6.o.* 476932f5e1ffe365db9d1dfb3f860369 /tmp/powernow-k6.o.after 476932f5e1ffe365db9d1dfb3f860369 /tmp/powernow-k6.o.before Signed-off-by: Paolo Ciarrocchi Signed-off-by: Dave Jones commit ec2be435f84e51769dcfd6f216a0e7dc1bbd660d Author: Paolo Ciarrocchi Date: Mon Jul 28 13:00:49 2008 +0200 [CPUFREQ] Coding style fixes to arch/x86/kernel/cpu/cpufreq/elanfreq.c Before: total: 15 errors, 10 warnings, 308 lines checked After: total: 0 errors, 4 warnings, 308 lines checked paolo@paolo-desktop:~/linux.trees.git$ md5sum /tmp/elafreq.o.* add1d36c2f077c5aab7682e8642a9f34 /tmp/elafreq.o.after add1d36c2f077c5aab7682e8642a9f34 /tmp/elafreq.o.before paolo@paolo-desktop:~/linux.trees.git$ size /tmp/elafreq.o.* text data bss dec hex filename 934 270 4 1208 4b8 /tmp/elafreq.o.after 934 270 4 1208 4b8 /tmp/elafreq.o.before Signed-off-by: Paolo Ciarrocchi Signed-off-by: Dave Jones commit ce25d7e90c7543f0046c3bdcdcc7594546c57dcc Author: Uwe Kleine-König Date: Fri Aug 8 12:14:36 2008 -0400 Input: gpio-keys - simplify argument list for report_event For now this only saves a few instructions (for gpio_keys_report_event, gpio_keys_isr and gpio_check_button one instraction each on ARM using arm-linux-gnu-gcc 4.2.3---I assume this is similar for other arch/compiler combinations). Signed-off-by: Uwe Kleine-König Signed-off-by: Dmitry Torokhov commit 57ffe9d539e0eb741bb9ca8f2834d210e70ee2e3 Author: Uwe Kleine-König Date: Fri Aug 8 12:14:34 2008 -0400 Input: gpio-keys - optimize interrupt handler By passing a gpio_button_data structure to the handler instead of the whole platform_device the search for the right button can go away. Signed-off-by: Uwe Kleine-König Signed-off-by: Dmitry Torokhov commit 34a7c48c221676ff8322ca4b8ded84eada34cf12 Author: Remi Herilier Date: Fri Aug 8 12:13:13 2008 -0400 Input: wistron - add support for Fujitsu-Siemens Amilo Pro v3505 Wistron button support for Fujitsu-Siemens Amilo Pro Edition V3505. Signed-off-by: Remi Herilier Signed-off-by: Andrew Morton Signed-off-by: Dmitry Torokhov commit c04148f915e5ba7947752e6348e0da4cdab1329e Author: Alfred E. Heggestad Date: Fri Aug 8 11:49:08 2008 -0400 Input: add driver for USB VoIP phones with CM109 chipset Signed-off-by: Alfred E. Heggestad Signed-off-by: Dmitry Torokhov commit 7db3610810c4f4a8a22a3e3310aa5677e14e4191 Author: Takashi Iwai Date: Fri Aug 8 17:06:01 2008 +0200 ALSA: Introduce snd_BUG_ON() macro Introduced snd_BUG_ON() macro as a replacement of snd_assert() macro. snd_assert() is pretty ugly as it has the control flow in its argument. OTOH, snd_BUG_ON() behaves like a normal conditional, thus it's much easier to read the flow. Signed-off-by: Takashi Iwai commit f335cca64774dab859590a07faa225466221eca9 Author: Rene Herman Date: Fri Aug 8 16:39:21 2008 +0200 ALSA: wss_lib: missing closing brace in (ifdeffed out) debug function. Signed-off-by: Rene Herman Signed-off-by: Takashi Iwai commit 93a92d62f65ff74ab3339094bccada2752f5b913 Author: David Howells Date: Fri Aug 8 13:41:55 2008 +0100 KEYS: Revert NULL debracketing of key_get() [ver #2] Restore the bracketing on the CONFIG_KEYS=n versions of key_get() that was taken away by: [PATCH 03/24] KEYS: Alter use of key instantiation link-to-keyring argument [ver #7] This reverts the no-op fallback for key_get() from this: #define key_get(k) NULL to this: #define key_get(k) ({ NULL; }) The two are not equivalent on gcc because when the macro is called like this: int foo(struct key *key) { ... key_get(key); ... } This warning will occur foo.c:87: warning: statement with no effect because nothing uses the NULL. The ({ NULL; }) construct, however, does not result in this warning. The no-op key_get() may not be made into a function instead as it must ignore its argument lest that access something that doesn't exist if CONFIG_KEYS=n. Furthermore, a do{...}while(0) may not be used instead as the macro must return NULL to indicate there's no usable key. Signed-off-by: David Howells Signed-off-by: James Morris commit 840fb4b398c48229adf70ba548b41294edf4a7d8 Author: Stephen Rothwell Date: Fri Aug 8 16:36:33 2008 +1000 creds: build fixes for powerpc and !CONFIG_KEYS Fix build errors encountered in linux-next. Signed-off-by: Stephen Rothwell Acked-by: David Howells Signed-off-by: James Morris commit a932f308bec4713923f5647d4b1484bdcc9f2125 Author: roel kluin Date: Thu Aug 7 15:56:22 2008 -0400 ALSA: au88x0: clipping ceiling loop wrong in comment As is the clipping ceiling loop appears wrong anyways Signed-off-by: Roel Kluin Signed-off-by: Takashi Iwai commit c314dfdc358847eef0fc07ec8682e1acc8cadd00 Author: David Woodhouse Date: Thu Aug 7 11:55:07 2008 +0100 [MTD] [NOR] Rename and export new cfi_qry_*() functions They need to be exported, so let's give them less generic-sounding names while we're at it. Original export patch, along with the suggestion about the nomenclature, from Stephen Rothwell. Signed-off-by: David Woodhouse commit 8c64038e4c077b2b37c6b27d0c40c77a3ddfaeef Author: David Brownell Date: Wed Aug 6 21:55:14 2008 -0700 [MTD] make dataflash write-verify be optional This adds a WRITE_VERIFY Kconfig option to the DataFlash driver, closely mirroring the similar NAND and ONENAND options, giving an option to disable some code that's currently always enabled. Removing this step probably saves a millisecond or so per page when writing data, which will add up quickly since these pages are small (the largest is 1 KiB). It doesn't seem to add a lot in terms of reliability, and wouldn't detect errors which crop up when transferring data to the on-chip SRAM buffer. Signed-off-by: David Brownell Acked-by: Haavard Skinnemoen Acked-by: Andrew Victor Signed-off-by: David Woodhouse commit 6202336e82ab8211e72204ad69922d3e9d20d3ed Author: Timur Tabi Date: Wed Aug 6 15:01:01 2008 -0500 ALSA: ASoC - fix DMA channel selection in Freescale MPC8610 sound drivers On the Freescale MPC8610, SSI1 is hard-coded to use DMA channels 0 and 1 for playback and capture, and SSI2 is hard-coded to use DMA channels 2 and 3. This patch fixes the fabric driver so that it uses the right channels. Signed-off-by: Timur Tabi Signed-off-by: Takashi Iwai commit cf93ae02600e2c752bf2570085e7970a1c0f2b94 Author: David Brownell Date: Wed Aug 6 13:12:04 2008 -0700 [MTD] Compile fix for dataflash OTP support > > linux-next-20080805/drivers/mtd/devices/mtd_dataflash.c: In function 'add_dataflash_otp': > > linux-next-20080805/drivers/mtd/devices/mtd_dataflash.c:670: error: too many arguments to function 'otp_setup' Whoops, sorry ... I see what was going on. My bad. Signed-off-by: David Brownell Signed-off-by: David Woodhouse commit 4799f8d09e80821fab2b43f65669949c78a784b0 Author: David Howells Date: Thu Aug 7 20:02:24 2008 +1000 CRED: Allow kernel services to override LSM settings for task actions Allow kernel services to override LSM settings appropriate to the actions performed by a task by duplicating a set of credentials, modifying it and then using task_struct::cred to point to it when performing operations on behalf of a task. This is used, for example, by CacheFiles which has to transparently access the cache on behalf of a process that thinks it is doing, say, NFS accesses with a potentially inappropriate (with respect to accessing the cache) set of credentials. This patch provides two LSM hooks for modifying a task security record: (*) security_kernel_act_as() which allows modification of the security datum with which a task acts on other objects (most notably files). (*) security_kernel_create_files_as() which allows modification of the security datum that is used to initialise the security data on a file that a task creates. The patch also provides four new credentials handling functions, which wrap the LSM functions: (1) prepare_kernel_cred() Prepare a set of credentials for a kernel service to use, based either on a daemon's credentials or on init_cred. All the keyrings are cleared. (2) set_security_override() Set the LSM security ID in a set of credentials to a specific security context, assuming permission from the LSM policy. (3) set_security_override_from_ctx() As (2), but takes the security context as a string. (4) set_create_files_as() Set the file creation LSM security ID in a set of credentials to be the same as that on a particular inode. Signed-off-by: Casey Schaufler [Smack changes] Signed-off-by: David Howells commit 7b8ebe2a3adc129b8b03dbe4fb7b15214d0fb3d9 Author: David Howells Date: Thu Aug 7 20:02:23 2008 +1000 CRED: Add a kernel_service object class to SELinux Add a 'kernel_service' object class to SELinux and give this object class two access vectors: 'use_as_override' and 'create_files_as'. The first vector is used to grant a process the right to nominate an alternate process security ID for the kernel to use as an override for the SELinux subjective security when accessing stuff on behalf of another process. For example, CacheFiles when accessing the cache on behalf on a process accessing an NFS file needs to use a subjective security ID appropriate to the cache rather then the one the calling process is using. The cachefilesd daemon will nominate the security ID to be used. The second vector is used to grant a process the right to nominate a file creation label for a kernel service to use. Signed-off-by: David Howells commit e6295f09c6b296e80c460ed6a64022ed97940850 Author: David Howells Date: Thu Aug 7 20:02:23 2008 +1000 CRED: Differentiate objective and effective subjective credentials on a task Differentiate the objective and real subjective credentials from the effective subjective credentials on a task by introducing a second credentials pointer into the task_struct. task_struct::real_cred then refers to the objective and apparent real subjective credentials of a task, as perceived by the other tasks in the system. task_struct::cred then refers to the effective subjective credentials of a task, as used by that task when it's actually running. These are not visible to the other tasks in the system. __task_cred(task) then refers to the objective/real credentials of the task in question. current_cred() refers to the effective subjective credentials of the current task. prepare_creds() uses the objective creds as a base and commit_creds() changes both pointers in the task_struct (indeed commit_creds() requires them to be the same). override_creds() and revert_creds() change the subjective creds pointer only, and the former returns the old subjective creds. These are used by NFSD, faccessat() and do_coredump(), and will by used by CacheFiles. In SELinux, current_has_perm() is provided as an alternative to task_has_perm(). This uses the effective subjective context of current, whereas task_has_perm() uses the objective/real context of the subject. Signed-off-by: David Howells commit d23e18323fbcadd85337f8e37a114f3871aa3bea Author: David Howells Date: Thu Aug 7 20:02:22 2008 +1000 CRED: Documentation Document credentials and the new credentials API. Signed-off-by: David Howells commit 4ef270ff1038157a64dbd1ccbbe506d22dcd9614 Author: David Howells Date: Thu Aug 7 20:02:21 2008 +1000 CRED: Use creds in file structs Attach creds to file structs and discard f_uid/f_gid. file_operations::open() methods (such as hppfs_open()) should use file->f_cred rather than current_cred(). At the moment file->f_cred will be current_cred() at this point. Signed-off-by: David Howells Reviewed-by: James Morris commit 7ba159cf641572bcd91250e08545e2a3c44c3ca6 Author: David Howells Date: Thu Aug 7 20:02:21 2008 +1000 CRED: Prettify commoncap.c Prettify commoncap.c. Signed-off-by: David Howells Acked-by: Serge Hallyn Reviewed-by: James Morris commit d9a939fb80ef390b78b3c801f668bd1e35ebc970 Author: David Howells Date: Thu Aug 7 20:02:20 2008 +1000 CRED: Make execve() take advantage of copy-on-write credentials Make execve() take advantage of copy-on-write credentials, allowing it to set up the credentials in advance, and then commit the whole lot after the point of no return. This patch and the preceding patches have been tested with the LTP SELinux testsuite. This patch makes several logical sets of alteration: (1) execve(). The credential bits from struct linux_binprm are, for the most part, replaced with a single credentials pointer (bprm->cred). This means that all the creds can be calculated in advance and then applied at the point of no return with no possibility of failure. I would like to replace bprm->cap_effective with: cap_isclear(bprm->cap_effective) but this seems impossible due to special behaviour for processes of pid 1 (they always retain their parent's capability masks where normally they'd be changed - see cap_bprm_set_creds()). The following sequence of events now happens: (a) At the start of do_execve, the current task's cred_exec_mutex is locked to prevent PTRACE_ATTACH from obsoleting the calculation of creds that we make. (a) prepare_exec_creds() is then called to make a copy of the current task's credentials and prepare it. This copy is then assigned to bprm->cred. This renders security_bprm_alloc() and security_bprm_free() unnecessary, and so they've been removed. (b) The determination of unsafe execution is now performed immediately after (a) rather than later on in the code. The result is stored in bprm->unsafe for future reference. (c) prepare_binprm() is called, possibly multiple times. (i) This applies the result of set[ug]id binaries to the new creds attached to bprm->cred. Personality bit clearance is recorded, but now deferred on the basis that the exec procedure may yet fail. (ii) This then calls the new security_bprm_set_creds(). This should calculate the new LSM and capability credentials into *bprm->cred. This folds together security_bprm_set() and parts of security_bprm_apply_creds() (these two have been removed). Anything that might fail must be done at this point. (iii) bprm->cred_prepared is set to 1. bprm->cred_prepared is 0 on the first pass of the security calculations, and 1 on all subsequent passes. This allows SELinux in (ii) to base its calculations only on the initial script and not on the interpreter. (d) flush_old_exec() is called to commit the task to execution. This performs the following steps with regard to credentials: (i) Clear pdeath_signal and set dumpable on certain circumstances that may not be covered by commit_creds(). (ii) Clear any bits in current->personality that were deferred from (c.i). (e) install_exec_creds() [compute_creds() as was] is called to install the new credentials. This performs the following steps with regard to credentials: (i) Calls security_bprm_committing_creds() to apply any security requirements, such as flushing unauthorised files in SELinux, that must be done before the credentials are changed. This is made up of bits of security_bprm_apply_creds() and security_bprm_post_apply_creds(), both of which have been removed. This function is not allowed to fail; anything that might fail must have been done in (c.ii). (ii) Calls commit_creds() to apply the new credentials in a single assignment (more or less). Possibly pdeath_signal and dumpable should be part of struct creds. (iii) Unlocks the task's cred_replace_mutex, thus allowing PTRACE_ATTACH to take place. (iv) Clears The bprm->cred pointer as the credentials it was holding are now immutable. (v) Calls security_bprm_committed_creds() to apply any security alterations that must be done after the creds have been changed. SELinux uses this to flush signals and signal handlers. (f) If an error occurs before (d.i), bprm_free() will call abort_creds() to destroy the proposed new credentials and will then unlock cred_replace_mutex. No changes to the credentials will have been made. (2) LSM interface. A number of functions have been changed, added or removed: (*) security_bprm_alloc(), ->bprm_alloc_security() (*) security_bprm_free(), ->bprm_free_security() Removed in favour of preparing new credentials and modifying those. (*) security_bprm_apply_creds(), ->bprm_apply_creds() (*) security_bprm_post_apply_creds(), ->bprm_post_apply_creds() Removed; split between security_bprm_set_creds(), security_bprm_committing_creds() and security_bprm_committed_creds(). (*) security_bprm_set(), ->bprm_set_security() Removed; folded into security_bprm_set_creds(). (*) security_bprm_set_creds(), ->bprm_set_creds() New. The new credentials in bprm->creds should be checked and set up as appropriate. bprm->cred_prepared is 0 on the first call, 1 on the second and subsequent calls. (*) security_bprm_committing_creds(), ->bprm_committing_creds() (*) security_bprm_committed_creds(), ->bprm_committed_creds() New. Apply the security effects of the new credentials. This includes closing unauthorised files in SELinux. This function may not fail. When the former is called, the creds haven't yet been applied to the process; when the latter is called, they have. The former may access bprm->cred, the latter may not. (3) SELinux. SELinux has a number of changes, in addition to those to support the LSM interface changes mentioned above: (a) The bprm_security_struct struct has been removed in favour of using the credentials-under-construction approach. (c) flush_unauthorized_files() now takes a cred pointer and passes it on to inode_has_perm(), file_has_perm() and dentry_open(). Signed-off-by: David Howells Acked-by: James Morris Acked-by: Serge Hallyn commit 89be244cbb79a6c4a6d73730a1f042fc04d30967 Author: David Howells Date: Thu Aug 7 20:02:20 2008 +1000 CRED: Inaugurate COW credentials Inaugurate copy-on-write credentials management. This uses RCU to manage the credentials pointer in the task_struct with respect to accesses by other tasks. A process may only modify its own credentials, and so does not need locking to access or modify its own credentials. A mutex (cred_replace_mutex) is added to the task_struct to control the effect of PTRACE_ATTACHED on credential calculations, particularly with respect to execve(). With this patch, the contents of an active credentials struct may not be changed directly; rather a new set of credentials must be prepared, modified and committed using something like the following sequence of events: struct cred *new = prepare_creds(); int ret = blah(new); if (ret < 0) { abort_creds(new); return ret; } return commit_creds(new); There are some exceptions to this rule: the keyrings pointed to by the active credentials may be instantiated - keyrings violate the COW rule as managing COW keyrings is tricky, given that it is possible for a task to directly alter the keys in a keyring in use by another task. This patch and the preceding patches have been tested with the LTP SELinux testsuite. This patch makes several logical sets of alteration: (1) execve(). This now prepares and commits credentials in various places in the security code rather than altering the current creds directly. (2) Temporary credential overrides. do_coredump() and sys_faccessat() now prepare their own credentials and temporarily override the ones currently on the acting thread, whilst preventing interference from other threads by holding cred_replace_mutex on the thread being dumped. This will be replaced in a future patch by something that hands down the credentials directly to the functions being called, rather than altering the task's objective credentials. (3) LSM interface. A number of functions have been changed, added or removed: (*) security_capset_check(), ->capset_check() (*) security_capset_set(), ->capset_set() Removed in favour of security_capset(). (*) security_capset(), ->capset() New. This is passed a pointer to the new creds, a pointer to the old creds and the proposed capability sets. It should fill in the new creds or return an error. All pointers, barring the pointer to the new creds, are now const. (*) security_bprm_apply_creds(), ->bprm_apply_creds() Changed; now returns a value, which will cause the process to be killed if it's an error. (*) security_task_alloc(), ->task_alloc_security() Removed in favour of security_prepare_creds(). (*) security_cred_free(), ->cred_free() New. Free security data attached to cred->security. (*) security_prepare_creds(), ->cred_prepare() New. Duplicate any security data attached to cred->security. (*) security_commit_creds(), ->cred_commit() New. Apply any security effects for the upcoming installation of new security by commit_creds(). (*) security_task_post_setuid(), ->task_post_setuid() Removed in favour of security_task_fix_setuid(). (*) security_task_fix_setuid(), ->task_fix_setuid() Fix up the proposed new credentials for setuid(). This is used by cap_set_fix_setuid() to implicitly adjust capabilities in line with setuid() changes. Changes are made to the new credentials, rather than the task itself as in security_task_post_setuid(). (*) security_task_reparent_to_init(), ->task_reparent_to_init() Removed. Instead the task being reparented to init is referred directly to init's credentials. NOTE! This results in the loss of some state: SELinux's osid no longer records the sid of the thread that forked it. (*) security_key_alloc(), ->key_alloc() (*) security_key_permission(), ->key_permission() Changed. These now take cred pointers rather than task pointers to refer to the security context. (4) sys_capset(). This has been simplified and uses less locking. The LSM functions it calls have been merged. (5) reparent_to_kthreadd(). This gives the current thread the same credentials as init by simply using commit_thread() to point that way. (6) __sigqueue_alloc() and switch_uid() __sigqueue_alloc() can't stop the target task from changing its creds beneath it, so this function gets a reference to the currently applicable user_struct which it then passes into the sigqueue struct it returns if successful. switch_uid() is now called from commit_creds(), and possibly should be folded into that. commit_creds() should take care of protecting __sigqueue_alloc(). (7) [sg]et[ug]id() and co and [sg]et_current_groups. The set functions now all use prepare_creds(), commit_creds() and abort_creds() to build and check a new set of credentials before applying it. security_task_set[ug]id() is called inside the prepared section. This guarantees that nothing else will affect the creds until we've finished. The calling of set_dumpable() has been moved into commit_creds(). Much of the functionality of set_user() has been moved into commit_creds(). The get functions all simply access the data directly. (8) security_task_prctl() and cap_task_prctl(). security_task_prctl() has been modified to return -ENOSYS if it doesn't want to handle a function, or otherwise return the return value directly rather than through an argument. Additionally, cap_task_prctl() now prepares a new set of credentials, even if it doesn't end up using it. (9) Keyrings. A number of changes have been made to the keyrings code: (a) switch_uid_keyring(), copy_keys(), exit_keys() and suid_keys() have all been dropped and built in to the credentials functions directly. They may want separating out again later. (b) key_alloc() and search_process_keyrings() now take a cred pointer rather than a task pointer to specify the security context. (c) copy_creds() gives a new thread within the same thread group a new thread keyring if its parent had one, otherwise it discards the thread keyring. (d) The authorisation key now points directly to the credentials to extend the search into rather pointing to the task that carries them. (e) Installing thread, process or session keyrings causes a new set of credentials to be created, even though it's not strictly necessary for process or session keyrings (they're shared). (10) Usermode helper. The usermode helper code now carries a cred struct pointer in its subprocess_info struct instead of a new session keyring pointer. This set of credentials is derived from init_cred and installed on the new process after it has been cloned. call_usermodehelper_setup() allocates the new credentials and call_usermodehelper_freeinfo() discards them if they haven't been used. A special cred function (prepare_usermodeinfo_creds()) is provided specifically for call_usermodehelper_setup() to call. call_usermodehelper_setkeys() adjusts the credentials to sport the supplied keyring as the new session keyring. (11) SELinux. SELinux has a number of changes, in addition to those to support the LSM interface changes mentioned above: (a) selinux_setprocattr() no longer does its check for whether the current ptracer can access processes with the new SID inside the lock that covers getting the ptracer's SID. Whilst this lock ensures that the check is done with the ptracer pinned, the result is only valid until the lock is released, so there's no point doing it inside the lock. (12) is_single_threaded(). This function has been extracted from selinux_setprocattr() and put into a file of its own in the lib/ directory as join_session_keyring() now wants to use it too. The code in SELinux just checked to see whether a task shared mm_structs with other tasks (CLONE_VM), but that isn't good enough. We really want to know if they're part of the same thread group (CLONE_THREAD). (13) nfsd. The NFS server daemon now has to use the COW credentials to set the credentials it is going to use. It really needs to pass the credentials down to the functions it calls, but it can't do that until other patches in this series have been applied. Signed-off-by: David Howells Acked-by: James Morris commit 3aef995c0537d5ba27936d2e8cb42d307084932c Author: David Howells Date: Thu Aug 7 20:02:18 2008 +1000 CRED: Pass credentials through dentry_open() Pass credentials through dentry_open() so that the COW creds patch can have SELinux's flush_unauthorized_files() pass the appropriate creds back to itself when it opens its null chardev. The security_dentry_open() call also now takes a creds pointer, as does the dentry_open hook in struct security_operations. Signed-off-by: David Howells Acked-by: James Morris commit fd24c71e68c54905a82e8f068244ff4689fd315d Author: David Howells Date: Thu Aug 7 20:02:17 2008 +1000 CRED: Make inode_has_perm() and file_has_perm() take a cred pointer Make inode_has_perm() and file_has_perm() take a cred pointer rather than a task pointer. Signed-off-by: David Howells Acked-by: James Morris Acked-by: Serge Hallyn commit 26b29343ded238828c4a263f1cd48cb1893aeeca Author: David Howells Date: Thu Aug 7 20:02:17 2008 +1000 CRED: Rename is_single_threaded() to is_wq_single_threaded() Rename is_single_threaded() to is_wq_single_threaded() so that a new is_single_threaded() can be created that refers to tasks rather than waitqueues. Signed-off-by: David Howells Reviewed-by: James Morris commit cf7c7a530e568ca54ba3a3c021c7e7efb71fe10f Author: David Howells Date: Thu Aug 7 20:02:16 2008 +1000 CRED: Separate per-task-group keyrings from signal_struct Separate per-task-group keyrings from signal_struct and dangle their anchor from the cred struct rather than the signal_struct. Signed-off-by: David Howells Reviewed-by: James Morris commit bdf4cba5d9ff34788307fe66fbefcf43ba50be19 Author: David Howells Date: Thu Aug 7 20:02:16 2008 +1000 CRED: Wrap access to SELinux's task SID Wrap access to SELinux's task SID, using task_sid() and current_sid() as appropriate. Signed-off-by: David Howells Acked-by: James Morris commit ea3164d295c9fc6e8680570b187b4671fa4f40d1 Author: David Howells Date: Thu Aug 7 20:02:15 2008 +1000 CRED: Use RCU to access another task's creds and to release a task's own creds Use RCU to access another task's creds and to release a task's own creds. This means that it will be possible for the credentials of a task to be replaced without another task (a) requiring a full lock to read them, and (b) seeing deallocated memory. Signed-off-by: David Howells Acked-by: James Morris Acked-by: Serge Hallyn commit ca1633259d306b15d3b3c42f385b226a7051c15b Author: David Howells Date: Thu Aug 7 20:02:15 2008 +1000 CRED: Wrap current->cred and a few other accessors Wrap current->cred and a few other accessors to hide their actual implementation. Signed-off-by: David Howells Acked-by: James Morris Acked-by: Serge Hallyn commit 855ac6b785d3f9f405cc6d4ece57c19f8c6f3bc7 Author: David Howells Date: Thu Aug 7 20:02:14 2008 +1000 CRED: Detach the credentials from task_struct Detach the credentials from task_struct, duplicating them in copy_process() and releasing them in __put_task_struct(). Signed-off-by: David Howells Acked-by: James Morris Acked-by: Serge Hallyn commit 7931c65268777ed10cab22486de149d742a1f269 Author: David Howells Date: Thu Aug 7 20:02:13 2008 +1000 CRED: Separate task security context from task_struct Separate the task security context from task_struct. At this point, the security data is temporarily embedded in the task_struct with two pointers pointing to it. Note that the Alpha arch is altered as it refers to (E)UID and (E)GID in entry.S via asm-offsets. Signed-off-by: David Howells Acked-by: James Morris Acked-by: Serge Hallyn commit f4d399d40debd14b22967153294b94087cbcf789 Author: David Howells Date: Thu Aug 7 20:02:12 2008 +1000 CRED: Wrap most current->e?[ug]id and some task->e?[ug]id Change most current->e?[ug]id to current_e?[ug]id(). Change some task->e?[ug]id to task_e?[ug]id(). In some places it makes more sense to use RCU directly rather than a convenient wrapper; these are addressed by a later patch (see the patch entitled "CRED: Use RCU to access another task's creds and to release a task's own creds"). Signed-off-by: David Howells Reviewed-by: James Morris Acked-by: Serge Hallyn commit 785af0f385cd424d4b40908bf0e467df3dc05434 Author: David Howells Date: Thu Aug 7 20:02:11 2008 +1000 CRED: Change current->fs[ug]id to current_fs[ug]id() Change current->fs[ug]id to current_fs[ug]id() so that fsgid and fsuid can be separated from the task_struct. Signed-off-by: David Howells Reviewed-by: James Morris Acked-by: Serge Hallyn commit 471e6394d37cf3f32de0fb158d26038db5bf58ba Author: David Howells Date: Thu Aug 7 20:02:10 2008 +1000 CRED: Constify the kernel_cap_t arguments to the capset LSM hooks Constify the kernel_cap_t arguments to the capset LSM hooks. Signed-off-by: David Howells Acked-by: Serge Hallyn Acked-by: James Morris commit d035eaea412aab0f9964d111deb7736293a39133 Author: David Howells Date: Thu Aug 7 20:02:10 2008 +1000 CRED: Neuter sys_capset() Take away the ability for sys_capset() to affect processes other than current. This means that current will not need to lock its own credentials when reading them against interference by other processes. This has effectively been the case for a while anyway, since: (1) Without LSM enabled, sys_capset() is disallowed. (2) With file-based capabilities, sys_capset() is neutered. Signed-off-by: David Howells Acked-by: Serge Hallyn Acked-by: Andrew G. Morgan Acked-by: James Morris commit 5d359103023fbbe070db9f288291a8067a35969b Author: David Howells Date: Thu Aug 7 20:02:09 2008 +1000 KEYS: Alter use of key instantiation link-to-keyring argument Alter the use of the key instantiation and negation functions' link-to-keyring arguments. Currently this specifies a keyring in the target process to link the key into, creating the keyring if it doesn't exist. This, however, can be a problem for copy-on-write credentials as it means that the instantiating process can alter the credentials of the requesting process. This patch alters the behaviour such that: (1) If keyctl_instantiate_key() or keyctl_negate_key() are given a specific keyring by ID (ringid >= 0), then that keyring will be used. (2) If keyctl_instantiate_key() or keyctl_negate_key() are given one of the special constants that refer to the requesting process's keyrings (KEY_SPEC_*_KEYRING, all <= 0), then: (a) If sys_request_key() was given a keyring to use (destringid) then the key will be attached to that keyring. (b) If sys_request_key() was given a NULL keyring, then the key being instantiated will be attached to the default keyring as set by keyctl_set_reqkey_keyring(). (3) No extra link will be made. Decision point (1) follows current behaviour, and allows those instantiators who've searched for a specifically named keyring in the requestor's keyring so as to partition the keys by type to still have their named keyrings. Decision point (2) allows the requestor to make sure that the key or keys that get produced by request_key() go where they want, whilst allowing the instantiator to request that the key is retained. This is mainly useful for situations where the instantiator makes a secondary request, the key for which should be retained by the initial requestor: +-----------+ +--------------+ +--------------+ | | | | | | | Requestor |------->| Instantiator |------->| Instantiator | | | | | | | +-----------+ +--------------+ +--------------+ request_key() request_key() This might be useful, for example, in Kerberos, where the requestor requests a ticket, and then the ticket instantiator requests the TGT, which someone else then has to go and fetch. The TGT, however, should be retained in the keyrings of the requestor, not the first instantiator. To make this explict an extra special keyring constant is also added. Signed-off-by: David Howells Reviewed-by: James Morris commit 25865696f919bb2bc601d088c5edbabc41163557 Author: David Howells Date: Thu Aug 7 20:02:09 2008 +1000 KEYS: Disperse linux/key_ui.h Disperse the bits of linux/key_ui.h as the reason they were put here (keyfs) didn't get in. Signed-off-by: David Howells Reviewed-by: James Morris commit ad3a538bde9577c471025e6a1f43fc73cf90de51 Author: David Howells Date: Thu Aug 7 20:02:08 2008 +1000 Fix setting of PF_SUPERPRIV by __capable() Fix the setting of PF_SUPERPRIV by __capable() as it could corrupt the flags the target process if that is not the current process and it is trying to change its own flags in a different way at the same time. __capable() is using neither atomic ops nor locking to protect t->flags. This patch removes __capable() and introduces has_capability() that doesn't set PF_SUPERPRIV on the process being queried. This patch further splits security_ptrace() in two: (1) security_ptrace_may_access(). This passes judgement on whether one process may access another only (PTRACE_MODE_ATTACH for ptrace() and PTRACE_MODE_READ for /proc), and takes a pointer to the child process. current is the parent. (2) security_ptrace_traceme(). This passes judgement on PTRACE_TRACEME only, and takes only a pointer to the parent process. current is the child. In Smack and commoncap, this uses has_capability() to determine whether the parent will be permitted to use PTRACE_ATTACH if normal checks fail. This does not set PF_SUPERPRIV. Two of the instances of __capable() actually only act on current, and so have been changed to calls to capable(). Of the places that were using __capable(): (1) The OOM killer calls __capable() thrice when weighing the killability of a process. All of these now use has_capability(). (2) cap_ptrace() and smack_ptrace() were using __capable() to check to see whether the parent was allowed to trace any process. As mentioned above, these have been split. For PTRACE_ATTACH and /proc, capable() is now used, and for PTRACE_TRACEME, has_capability() is used. (3) cap_safe_nice() only ever saw current, so now uses capable(). (4) smack_setprocattr() rejected accesses to tasks other than current just after calling __capable(), so the order of these two tests have been switched and capable() is used instead. (5) In smack_file_send_sigiotask(), we need to allow privileged processes to receive SIGIO on files they're manipulating. (6) In smack_task_wait(), we let a process wait for a privileged process, whether or not the process doing the waiting is privileged. I've tested this with the LTP SELinux and syscalls testscripts. Signed-off-by: David Howells Acked-by: Serge Hallyn Acked-by: Casey Schaufler Acked-by: Andrew G. Morgan Acked-by: James Morris Acked-by: Al Viro commit a3a926f3fac35f10f30c6658e4d8a603740fe705 Author: Mauro Carvalho Chehab Date: Wed Aug 6 20:13:46 2008 -0300 V4L/DVB (8628a): Remove duplicated include Removes duplicated #include Signed-off-by: Mauro Carvalho Chehab commit 421fae06be9e0dac45747494756b3580643815f9 Author: Vesa-Matti Kari Date: Wed Aug 6 18:24:51 2008 +0300 selinux: conditional expression type validation was off-by-one expr_isvalid() in conditional.c was off-by-one and allowed invalid expression type COND_LAST. However, it is this header file that needs to be fixed. That way the if-statement's disjunction's second component reads more naturally, "if expr type is greater than the last allowed value" ( rather than using ">=" in conditional.c): if (expr->expr_type <= 0 || expr->expr_type > COND_LAST) Signed-off-by: Vesa-Matti Kari Signed-off-by: James Morris commit 61055a5622bf58c22d27ac6bd156d78a5250e984 Author: Mark Brown Date: Wed Aug 6 13:18:26 2008 +0100 ALSA: ASoC: Add WM8580 CODEC driver The WM8580 is an audio CODEC designed for DVD and surround sound applications, offering three stereo DACs and a stereo ADC. Signed-off-by: Mark Brown Signed-off-by: Takashi Iwai commit a2eae4f7fffb0a49890534cc6dcac4732fa04045 Author: Rene Herman Date: Wed Aug 6 08:09:34 2008 +0200 ALSA: wss_lib: rework snd_ad1848_probe() Make snd_ad1848_probe() easier to follow. With an exception for only trying once as soon as the codec is out of init (which should be all that's needed) the detection logic should be unchanged. Signed-off-by: Rene Herman Acked-by: Krzysztof Helt Signed-off-by: Takashi Iwai commit e93cafe45fd74935e0aca2b79e533f0e3ed9640f Author: Anders Grafström Date: Tue Aug 5 18:37:41 2008 +0200 [MTD] [NOR] cfi_cmdset_0001: Timeouts for erase, write and unlock operations Timeouts are currently given by the typical operation time times 8. It works in the general well-behaved case but not when an erase block is failing. For erase operations, it seems that a failing erase block will keep the device state machine in erasing state until the vendor specified maximum timeout period has passed. By this time the driver would have long since timed out, left erasing state and attempted further operations which all fail. This patch implements timeouts using values from the CFI Query structure when available. The patch also sets a longer timeout for locking operations. The current value used for locking/unlocking given by 1000000/HZ microseconds is too short for devices like J3 and J5 Strataflash which have a typical clear lock-bits time of 0.5 seconds. Signed-off-by: Anders Grafström Signed-off-by: David Woodhouse commit 2e489e077a6ad118c4f247faedf330117b107cce Author: Alexey Korolev Date: Tue Aug 5 16:39:42 2008 +0100 [MTD] [NOR] Add qry_mode_on()/qry_omde_off() to deal with odd chips There are some CFI chips which require non standard procedures to get into QRY mode. The possible way to support them would be trying different modes till QRY will be read. This patch introduce two new functions qry_mode_on qry_mode_off. qry_mode_on tries different commands in order switch chip into QRY mode. So if we have one more "odd" chip - we just could add several lines to qry_mode_on. Also using these functions remove unnecessary code duplicaton in porbe procedure. Currently there are two "odd" cases 1. Some old intel chips which require 0xFF before 0x98 2. ST M29DW chip which requires 0x98 to be sent at 0x555 (according to CFI should be 0x55) This patch is partialy based on the patch from Uwe (see "[PATCH 2/4] [RFC][MTD] cfi_probe: remove Intel chip workaround" thread ) Signed-off-by: Alexey Korolev Signed-off-by: Alexander Belyakov Signed-off-by: David Woodhouse commit a0e7229edbfef9495e73bc8baea2131a7e69e365 Author: George G. Davis Date: Mon Aug 4 19:43:25 2008 -0400 [MTD] [NOR] Add "Spansion" to MTD_CFI_AMDSTD kconfig menu description This long overdue trivial change to the MTD_CFI_AMDSTD kconfig menu description is intended to help clarify that this option also supports Spansion flash devices. Signed-off-by: George G. Davis Signed-off-by: David Woodhouse commit f823697562675f6f45aab35afdb7b51311fa38a4 Author: Takashi Iwai Date: Tue Aug 5 15:45:45 2008 +0200 ALSA: ac97 - Enable mono-out on ALC203 codec as default Use pin 37 for mono-out as default on ALC203. Reported-by: george pee Tested-by: george pee Signed-off-by: Takashi Iwai commit 58214ab4240ca52db1f2f699f8b24dfa513f53d5 Author: Phillip Michael Jordan Date: Tue Aug 5 11:01:00 2008 +0200 ALSA: snd_usb_audio: fix SB Extigy IR Remote regression The support for the SB Extigy's remote seems to be broken in all recent ALSA versions, including 1.0.17. The driver detects the event correctly, then submits a URB to query the RC code. On the Extigy, the URB is submitted with a length of 2 bytes. My hardware, however, only replies with 1 byte, containing the correct RC button code. The current implementation discards this as being too short. (line 1784 of usbmixer.c) This patch specifies a "minimum packet length" in the remote control configuration. I've left the values for the Audigy 2/Live! the same as the packet length, as I'm assuming the existing code works with them. (I don't have the hardware to confirm) This fixes the Extigy RC support, e.g. for use with Lirc. Signed-off-by: Phillip Michael Jordan Signed-off-by: Takashi Iwai commit 8540071a3b6daa982cacd8950c819d592f8339ca Author: Mark Brown Date: Mon Aug 4 12:06:45 2008 +0100 ALSA: ASoC: Add WM8900 CODEC driver The WM8900 is designed for portable multimedia applications requiring low power consumption, high performance audio and a compact form factor providing: - 24 bit stereo ADC and DAC - Microphone and line inputs - Line outputs - Class G headphone amplifier Signed-off-by: Mark Brown Signed-off-by: Takashi Iwai commit 9b250b5b1925767c62afba5d20907d062c4c51dd Author: Pawel MOLL Date: Fri Aug 1 11:23:44 2008 +0100 ALSA: IEC958 definition for consumer status channel update Updated IEC958 consumer status channel definitions according to the third edition of IEC60958-3 spec. Signed-off-by: Pawel Moll Signed-off-by: Takashi Iwai commit e7e4ec1b7161091eb33c4cff10e3e35fb19097b5 Author: Misha Zhilin Date: Fri Aug 1 12:45:14 2008 +0200 ALSA: ice1724 - Support for Terrasoniq/MUSONIK TS22 PCI card Added support for Terrasoniq/MUSONIK TS22 PCI card. Signed-off-by: Misha Zhilin Signed-off-by: Takashi Iwai commit 77bc23a5b6885544cdba42b0f89790097efb86c6 Author: Pawel MOLL Date: Wed Jul 30 12:46:40 2008 +0100 ALSA: Fix limit of 8 PCM devices in SNDRV_CTL_IOCTL_PCM_NEXT_DEVICE When compiled with CONFIG_SND_DYNAMIC_MINORS the ALSA core is fine to have more than 8 PCM devices per card, except one place - the SNDRV_CTL_IOCTL_PCM_NEXT_DEVICE ioctl, which will not enumerate devices > 7. This patch fixes the issue, changing the devices list organisation. Instead of adding new device to the tail, the list is now kept always ordered (by card number, then device number). Thus, during enumeration, it is easy to discover the fact that there is no more given card's devices. Additionally the device field of struct snd_pcm had to be changed to int, as its "unsignednity" caused a lot of problems when comparing it to potentially negative signed values. (-1 is 0xffffffff or even more then ;-) Signed-off-by: Pawel Moll Signed-off-by: Takashi Iwai commit 5429f5a35995647e635a86c9d458152c75127f63 Author: Karsten Wiese Date: Wed Jul 30 15:13:29 2008 +0200 ALSA: Add USB US122L driver Added a new US122L usb-audio driver. This driver works together with a dedicated alsa-lib plugin. Signed-off-by: Takashi Iwai commit 753e8359e93ef952bf892be4b2b252ab5d5515b7 Author: Mark Brown Date: Mon Jul 28 19:05:36 2008 +0100 ALSA: Build jack detection Since jack detection requires the input subsystem which may not be desired on small systems it is not built unless required by a driver that is being built. Drivers using jack detection should use a pattern like this: config SND_FOO tristate "..." ... select SND_JACK if INPUT=y || INPUT=SND to ensure that the jack detection API is enabled if the input subsystem is. If the input subsystem is not enabled then a stub version of the API is provided. Signed-off-by: Mark Brown Signed-off-by: Takashi Iwai commit 63c60035a8f399ba8bbf75222213cfb55adc75fd Author: Mark Brown Date: Mon Jul 28 19:05:35 2008 +0100 ALSA: Add jack reporting API Currently very few systems provide information about jack status to user space, even though many have hardware facilities to do detection. Those systems that do use an input device with the existing SW_HEADPHONE_INSERT switch type to do so, often independently of ALSA. This patch introduces a standard method for representing jacks to user space into ALSA. It allows drivers to register jacks for a sound card with the input subsystem, binding the input device to the card to help user space associate the input devices with their sound cards. The created input devices are named in the form "card longname jack" where jack is provided by the driver when allocating a jack. By default the parent for the input device is the sound card but this can be overridden by the card driver. The existing user space API with SW_HEADPHONE_INSERT is preserved. Signed-off-by: Mark Brown Signed-off-by: Takashi Iwai commit 2ef5132a68865cb577e0e564a5bc4b4c86029e2b Author: Clemens Ladisch Date: Mon Jul 28 10:28:43 2008 +0200 ALSA: virtuoso: add Xonar D1 support Add support for the Asus Xonar D1. It is the same as the DX, but without the external power detection. Signed-off-by: Clemens Ladisch Signed-off-by: Takashi Iwai commit b4f1258b365343e441a32d1fc3d38f1582a70284 Author: Clemens Ladisch Date: Mon Jul 28 10:19:39 2008 +0200 ALSA: usb-audio: add BOSS GT-10 support Add a quirk entry for the BOSS GT-10. Signed-off-by: Clemens Ladisch Signed-off-by: Takashi Iwai commit 9d527642320795746b5c26e837266ba211a08df7 Author: Mauro Carvalho Chehab Date: Mon Aug 4 10:39:59 2008 -0300 ALSA: hda: Add support for ECS/PC Chips boards with Sigmatel codecs Thanks to Sistema Fenix (http://www.sistemafenix.com.br/) and CDI Brasil (www.cdibrasil.com.br/) for sponsoring this development. Signed-off-by: Gilberto Signed-off-by: Mauro Carvalho Chehab Signed-off-by: Takashi Iwai commit 442632d6359fd301eca0401c4cafd5eecaba6508 Author: Pascal Terjan Date: Mon Aug 4 14:36:05 2008 +0200 ALSA: hda - Fix sound on NEC Versa S9100 This patch adds sound support for NEC Versa S9100 With it, we get sound on the internal speaker and headphone (with automute working) while there is no sound by default. External mic also works fine but I don't know if there is an internal one (if there is an internal mic it does not work currently), and I had to send back the hardware. Signed-off-by: Pascal Terjan Signed-off-by: Takashi Iwai commit cab7408010dd4cef8653de23e367cdacd00de390 Author: Takashi Iwai Date: Tue Jul 29 12:08:16 2008 +0200 ALSA: hda - use input_free_device() Use input_free_devce() correctly instead of kfree() at error path. Signed-off-by: Takashi Iwai commit 5387b0a39ea4e0fd4e44e28ea8fea22abb35317a Author: Matthew Ranostay Date: Sun Jul 27 10:30:30 2008 +0200 ALSA: hda: added 92HD81/83 support Added support for 92HD81/83 family of codecs. This also includes a pwr_mapping array for pins that have more than one amp to power down. Signed-off-by: Matthew Ranostay Signed-off-by: Takashi Iwai commit 0b21c15a859e6bdcc101a8dd90aef31f2b0de587 Author: Matthew Ranostay Date: Fri Jul 18 18:20:52 2008 +0200 ALSA: hda: digital pc-beep support hd-audio codecs Added digital pc-beep support using linear tone generation for hd-codecs along with initial support for several IDT codecs. Signed-off-by: Matthew Ranostay Signed-off-by: Takashi Iwai commit 0daa075ea4905823ee7c2375d26bb134e5e74f74 Author: Timur Tabi Date: Tue Jul 29 16:35:52 2008 -0500 ALSA: make the CS4270 driver a new-style I2C driver Update the CS4270 ALSA device driver to use the new-style I2C interface. Starting with the 2.6.27 PowerPC kernel, I2C devices that have entries in the device trees can no longer be probed by old-style I2C drivers. The device tree for Freescale MPC8610 HPCD has included an entry for the CS4270 since 2.6.25, but that entry was previously ignored by the PowerPC I2C subsystem. Since that's no longer the case, the best solution is to update the CS4270 driver to a new-style interface, rather than try to revert the behavior of new PowerPC I2C subsystem. Signed-off-by: Timur Tabi Signed-off-by: Takashi Iwai commit 497c666b01002aa71491798c5c2f4079c5a07e7b Author: Jon Smirl Date: Tue Jul 29 10:22:24 2008 -0400 ALSA: ASoC: convert use of uint to unsigned int ASOC: convert use of uint to unsigned int Signed-off-by: Jon Smirl Acked-by: Mark Brown Signed-off-by: Takashi Iwai commit c93b70bbc236bb86ec834459f662cf823c9ffa2d Author: Mark Brown Date: Tue Jul 29 11:42:35 2008 +0100 ALSA: ASoC: Add all CODECs Kconfig option Allow all the CODEC drivers to be built without a machine driver in order to facilitate testing of subsystem-wide changes and gain better coverage from automated testing efforts. This also helps things like the generic OpenFirmware machine driver for PowerPC. Currently AC97 CODECs are not included since the current setup relies on having a controller driver available. Signed-off-by: Mark Brown Signed-off-by: Takashi Iwai commit 7339af67ebe53d333c98403ff399b92773706e62 Author: Cliff Cai Date: Tue Jul 29 11:42:34 2008 +0100 ALSA: ASoC: AD1980 audio codec driver [Mechanical updates from code review applied -- broonie] Signed-off-by: Cliff Cai Signed-off-by: Bryan Wu Signed-off-by: Mark Brown Signed-off-by: Takashi Iwai commit 28a883621a173a000009eed5d69766fb45b2019a Author: Mark Brown Date: Tue Jul 29 11:42:33 2008 +0100 ALSA: ASoC: Staticise keyclick dev_attr in tlv320aic26 Signed-off-by: Mark Brown Acked-by: Grant Likely Signed-off-by: Takashi Iwai commit 7c676f721bbea4e6ec62ac24ae014f1cc7a445f2 Author: Mark Brown Date: Tue Jul 29 11:42:32 2008 +0100 ALSA: ASoC: Export DAI and codec for TLV320AIC26 This fixes sparse warnings and allows non-OpenFirmware systems to attempt to bind to the device. Signed-off-by: Mark Brown Acked-by: Grant Likely Signed-off-by: Takashi Iwai commit 008b3662abebe7a19eb362991102eec9feeb6f07 Author: Grant Likely Date: Tue Jul 29 11:42:31 2008 +0100 ALSA: ASoC: Add Texas Instruments TLV320AIC26 codec driver ASoC Codec driver for the TLV320AIC26 device. As it stands, this driver doesn't support all the modes and clocking options of the AIC16, but it is a start. Signed-off-by: Grant Likely Signed-off-by: Mark Brown Signed-off-by: Takashi Iwai commit 01cd580d6c5724199c5a090fd7d8482175ee9606 Author: Grant Likely Date: Tue Jul 29 11:42:30 2008 +0100 ALSA: ASoC: Add mpc5200-psc I2S driver This is an I2S bus driver for the MPC5200 PSC device. It depends on the soc-of helper functions to match a PSC device with a codec based on data in the device tree. Signed-off-by: Grant Likely Signed-off-by: Mark Brown Signed-off-by: Takashi Iwai commit 8c0682b5c3ac1e33a6f7850e790e18b1e0d795f6 Author: Mark Brown Date: Tue Jul 29 11:42:29 2008 +0100 ALSA: ASoC: Make OpenFirmware helper include file conditional The OpenFirmware API headers don't build on all platforms so ensure that they are not included unless they are being used. Signed-off-by: Mark Brown Acked-by: Grant Likely Signed-off-by: Takashi Iwai commit 50926fca4ef074fcbfbada158b22c805a7f85407 Author: Grant Likely Date: Tue Jul 29 11:42:28 2008 +0100 ALSA: ASoC: Add OpenFirmware helper for matching bus and codec drivers Simple utility layer for creating ASoC machine instances based on data in the OpenFirmware device tree. OF aware platform drivers and codec drivers register themselves with this framework and the framework automatically instantiates a machine driver. At the moment, the driver is not very capable and it is expected to be extended as more features are needed for specifying the configuration in the device tree. This is most likely temporary glue code to work around limitations in the ASoC v1 framework. When v2 is merged, most of this driver will need to be reworked. Signed-off-by: Grant Likely Signed-off-by: Mark Brown Signed-off-by: Takashi Iwai commit 34997b09c55982532117e773cf981ec4f5ffd027 Author: Jon Smirl Date: Tue Jul 29 11:42:27 2008 +0100 ALSA: ASoC: Rename mask to max to reflect usage Most of the ASoC controls refer to the maximum value that can be set for a control as mask but there is no actual requirement for all bits to be set at the highest possible value making the name mask misleading. Change the code to use max instead. Signed-off-by: Jon Smirl Signed-off-by: Mark Brown Signed-off-by: Takashi Iwai commit c70d8ee3ec3abdd0770ce2f02fd2c625a472ac69 Author: Jon Smirl Date: Tue Jul 29 11:42:26 2008 +0100 ALSA: ASoC: Convert bitfields in ASoC into full int width Convert bitfields in ASoC into full int width. This is a simple mechanical conversion. Two places in the DAPM code were fixed to properly use mask. Signed-off-by: Jon Smirl Signed-off-by: Mark Brown Signed-off-by: Takashi Iwai commit 62126e599bc0a99fac74d8ab076c09573cc859d7 Author: Mark Brown Date: Tue Jul 29 11:42:25 2008 +0100 ALSA: ASoC: Allow codecs to override register display Some codecs have unusual features in their register maps such as very large registers representing arrays of coefficients. Support these codecs in the register cache sysfs file by allowing them to provide a function register_display() overriding the default output for register contents. Also ensure that we don't overflow PAGE_SIZE while writing out the register dump. Signed-off-by: Mark Brown Signed-off-by: Takashi Iwai commit b5076dffddfb3cb09c5dddfafd458575ceed2ee0 Author: Dmitry Baryshkov Date: Tue Jul 29 11:42:24 2008 +0100 ALSA: ASoC: Permit simultaneous compilation of both PXA AC97 drivers Signed-off-by: Dmitry Baryshkov Signed-off-by: Mark Brown Signed-off-by: Takashi Iwai commit c89a628f585aefa8a6cc50646130b34953481eab Author: Rene Herman Date: Tue Aug 5 09:33:33 2008 +0200 ALSA: wss_lib: fix AZT2320 probe. After the transition from cs4321_lib to wss_lib, azt2320 probe visits snd_ad1848_probe during detection. It expects register 0 (LEFT_INPUT) to be able to retain the value 0xaa during detection but AZT2320 does not support MIC gain meaning it reads back as 0x8a instead. Signed-off-by: Rene Herman Acked-by: Krzysztof Helt Signed-off-by: Takashi Iwai commit 4d668d3722e0597003607c27523223feb740ac58 Author: Rene Herman Date: Mon Aug 4 01:23:43 2008 +0200 ALSA: snd-cs4236: add Techmakers MF-4236PW PnP card ID Add the Techmakers MF-4236PW (Crystal CX4236B-XQ3) PnP card ID. Signed-off-by: Rene Herman Signed-off-by: Takashi Iwai commit 557caae2543430577737fb171cb7c09255b1452a Author: Krzysztof Helt Date: Sun Aug 3 17:57:21 2008 +0200 ALSA: wss_lib: remove second mutexes initialization Remove initializations of spinlock and mutexes which are done earlier in snd_wss_new(). The snd_wss_new() is called from snd_wss_create(). Signed-off-by: Krzysztof Helt Signed-off-by: Takashi Iwai commit c08b7090b3552e3ceb20a6eff6a8972c13279b2d Author: Rene Herman Date: Mon Aug 4 05:26:26 2008 +0200 ALSA: wss_lib: opti92x-ad1848 WSS_HW_DETECT fix snd-opti92x-ad1848 mistakingly passes WSS_HW_OPTI93X currently. This fixes it as tested with a OPTi 82C929A/AD1848 card. Signed-off-by: Rene Herman Acked-by: Krzysztof Helt Signed-off-by: Takashi Iwai commit a7b084851cfdf5655a205469a4e5a03618880fd0 Author: Krzysztof Helt Date: Thu Jul 31 21:11:46 2008 +0200 ALSA: wss_lib: fix opti93x capture formats limitations Limit opti93x cards capture formats to only linear ones. Signed-off-by: Krzysztof Helt Reviewed-by: Rene Herman Signed-off-by: Takashi Iwai commit eea5e3543bd0beed22c21ff37e5cfec6ebe14405 Author: Krzysztof Helt Date: Thu Jul 31 21:10:47 2008 +0200 ALSA: wss_lib: use wss detection code instead of ad1848 one Use the wss detection code and kill the ad1848 library. The library is fully assimilated into the new wss library. This required reworking of the AD1848 family code so the code is changed to correctly detect chips from the AD1848 and CS4231 families. I have tested it on following cards: Gallant SC-6600 (codec: AD1848, driver: snd-sc6600) SoundScape VIVO/90 (codec: AD1845, driver: snd-sscape) SG Waverider (codec: CS4231A, driver: Rene Herman's snd-galaxy) Opti930 (codec: built-in - CS4231 compatible, driver: snd-opti93x) Opti931 (codec: built-in - CS4231 compatible, driver: snd-opti93x) Gallant SC-70P (chip/codec: CS4237B, driver: snd-cs4236) Audio Plus 3D (chip/codec: CMI8330A, driver: snd-cmi8330) Dell Latitude CP (chip/codec: cs4236, driver snd-cs4232) Sound playback and recording works on all these cards. Signed-off-by: Krzysztof Helt Reviewed-by: Rene Herman Signed-off-by: Takashi Iwai commit a83a2302c4c4e2cb729cbcdb5f7cc91c131506a4 Author: Krzysztof Helt Date: Thu Jul 31 21:09:32 2008 +0200 ALSA: wss_lib: use wss pcm code instead of ad1848 one Use the wss pcm code and kill the ad1848 pcm code. The AD1848 chip is much slower than CS4231 chips so the waiting loop was increased 100x (10x is not enough). Signed-off-by: Krzysztof Helt Reviewed-by: Rene Herman Signed-off-by: Takashi Iwai commit 757cd3f3b9beb79ddb8ebae8bc6f17897509a89f Author: Krzysztof Helt Date: Thu Jul 31 21:08:32 2008 +0200 ALSA: wss_lib: use wss mixer code instead of ad1848 one Use the wss mixer code and kill the ad1848 mixer code. Signed-off-by: Krzysztof Helt Reviewed-by: Rene Herman Signed-off-by: Takashi Iwai commit 5e848d2201e5fb9c0c7e33cdc5d2d9636092033a Author: Krzysztof Helt Date: Thu Jul 31 21:07:30 2008 +0200 ALSA: wss_lib: use CS4231P instead of AD1848P (kill the AD1848P) Use CS4231P instead of AD1848P (kill the AD1848P). Signed-off-by: Krzysztof Helt Reviewed-by: Rene Herman Signed-off-by: Takashi Iwai commit 2e3d508497fbb12c53a153f48c35817218d5184e Author: Krzysztof Helt Date: Thu Jul 31 21:06:46 2008 +0200 ALSA: wss_lib: replace ad1848 mixer element macros with wss ones Use the wss macros instead of ad1848 ones. Signed-off-by: Krzysztof Helt Reviewed-by: Rene Herman Signed-off-by: Takashi Iwai commit 0d1cf4aab28a99314bae2130d1ee3e7797fcccea Author: Krzysztof Helt Date: Thu Jul 31 21:05:44 2008 +0200 ALSA: wss_lib: use wss constants instead of ad1848 ones Use wss constants for mode. Move ad1848 hardware constants to the wss.h. Move mixer tlv macros into the ad1848_lib.c from the ad1848.h. Drop the MODE_RUNNING spurious IRQ guard on AD1848 as it doesn not seem to be needed. Signed-off-by: Krzysztof Helt Reviewed-by: Rene Herman Signed-off-by: Takashi Iwai commit 66f053c666575a184d06b25472ee5d20b44148f3 Author: Krzysztof Helt Date: Thu Jul 31 21:04:37 2008 +0200 ALSA: wss_lib: use struct snd_wss instead of snd_ad1848 The snd_wss is superset of the snd_ad1848 so kill the latter and replace it with the snd_wss. Signed-off-by: Krzysztof Helt Reviewed-by: Rene Herman Signed-off-by: Takashi Iwai commit 3aa62e0aff38da815bfc2660bde4af6debb77ba4 Author: Krzysztof Helt Date: Thu Jul 31 21:03:41 2008 +0200 ALSA: wss_lib: rename cs4321_foo to wss_foo Rename functions and structures from the former cs4321_lib to names more corresponding with the new name: wss_lib. Signed-off-by: Krzysztof Helt Reviewed-by: Rene Herman Signed-off-by: Takashi Iwai commit 899e7ef48d0ecb128260beaf312afcbce7113ec0 Author: Krzysztof Helt Date: Thu Jul 31 21:02:42 2008 +0200 ALSA: wss_lib: rename cs4231.h into wss.h Rename file include/sound/cs4231.h into include/sound/wss.h Signed-off-by: Krzysztof Helt Reviewed-by: Rene Herman Signed-off-by: Takashi Iwai commit 79019e9e6f5afe3c39a0e5d23601b3cfdd1f1e3a Author: Krzysztof Helt Date: Thu Jul 31 21:00:17 2008 +0200 ALSA: wss_lib: move cs4231_lib into wss_lib Move the file sound/isa/cs423x/cs4231_lib.c into sound/isa/cs423x/wss_lib.c This is the first step toward merging all libraries for Windows Sound System compatible chips into a single library. Signed-off-by: Krzysztof Helt Reviewed-by: Rene Herman Signed-off-by: Takashi Iwai commit 15446235367fa4a621ff5abfa4b6ebbe25b33763 Author: Casey Schaufler Date: Wed Jul 30 15:37:11 2008 -0700 smack: limit privilege by label There have been a number of requests to make the Smack LSM enforce MAC even in the face of privilege, either capability based or superuser based. This is not universally desired, however, so it seems desirable to make it optional. Further, at least one legacy OS implemented a scheme whereby only processes running with one particular label could be exempt from MAC. This patch supports these three cases. If /smack/onlycap is empty (unset or null-string) privilege is enforced in the normal way. If /smack/onlycap contains a label only processes running with that label may be MAC exempt. If the label in /smack/onlycap is the star label ("*") the semantics of the star label combine with the privilege restrictions to prevent any violations of MAC, even in the presence of privilege. Again, this will be independent of the privilege scheme. Signed-off-by: Casey Schaufler Reviewed-by: James Morris commit cf9481e289247fe9cf40f2e2481220d899132049 Author: David Howells Date: Sun Jul 27 21:31:07 2008 +1000 SELinux: Fix a potentially uninitialised variable in SELinux hooks Fix a potentially uninitialised variable in SELinux hooks that's given a pointer to the network address by selinux_parse_skb() passing a pointer back through its argument list. By restructuring selinux_parse_skb(), the compiler can see that the error case need not set it as the caller will return immediately. Signed-off-by: David Howells Signed-off-by: James Morris commit 0c0e186f812457e527c420f7a4d02865fd0dc7d2 Author: Vesa-Matti J Kari Date: Mon Jul 21 02:50:20 2008 +0300 SELinux: trivial, remove unneeded local variable Hello, Remove unneeded local variable: struct avtab_node *newnode Signed-off-by: Vesa-Matti Kari Signed-off-by: James Morris commit df4ea865f09580b1cad621c0426612f598847815 Author: Vesa-Matti J Kari Date: Sun Jul 20 23:57:01 2008 +0300 SELinux: Trivial minor fixes that change C null character style Trivial minor fixes that change C null character style. Signed-off-by: Vesa-Matti Kari Signed-off-by: James Morris commit 3583a71183a02c51ca71cd180e9189cfb0411cc1 Author: Adrian Bunk Date: Tue Jul 22 20:21:23 2008 +0300 make selinux_write_opts() static This patch makes the needlessly global selinux_write_opts() static. Signed-off-by: Adrian Bunk Signed-off-by: James Morris commit 69597340b0353423687798645cfb8fc30219bbd7 Author: Laurent Pinchart Date: Thu Jul 31 17:11:12 2008 -0300 V4L/DVB (8617): uvcvideo: don't use stack-based buffers for USB transfers. Data buffers on the stack are not allowed for USB I/O. Use dynamically allocated buffers instead. Signed-off-by: Bruce Schmid Signed-off-by: Laurent Pinchart Signed-off-by: Mauro Carvalho Chehab commit 384d71960dfbce957b09bca6690c924cc7c26bfe Author: Laurent Pinchart Date: Wed Jul 30 18:54:48 2008 -0300 V4L/DVB (8616): uvcvideo: Add support for two Bison Electronics webcams The Bison Electronics 5986:0300 and 5986:0303 webcams require the UVC_QUIRK_PROBE_MINMAX quirk. Signed-off-by: Laurent Pinchart Signed-off-by: Mauro Carvalho Chehab commit 57de1f19f632f82a6f484cebafb635eb10ce2852 Author: Robert Jarzmik Date: Sat Aug 2 07:10:04 2008 -0300 V4L/DVB (8611): Add suspend/resume to pxa_camera driver PXA suspend switches off DMA core, which loses all context of previously assigned descriptors. As pxa_camera driver relies on DMA transfers, setup the lost descriptors on resume and retrigger frame acquisition if needed. Signed-off-by: Robert Jarzmik Signed-off-by: Guennadi Liakhovetski Signed-off-by: Mauro Carvalho Chehab commit dddad02471ed7edd55d5ee33c7bcca2cddc56803 Author: Robert Jarzmik Date: Fri Aug 1 20:14:50 2008 -0300 V4L/DVB (8610): Add suspend/resume capabilities to soc_camera. Add suspend/resume hooks to call soc operation specific suspend and resume functions. This ensures the camera chip has been previously resumed, as well as the camera bus. These hooks in camera chip drivers should save/restore chip context between suspend and resume time. Signed-off-by: Robert Jarzmik Signed-off-by: Guennadi Liakhovetski Signed-off-by: Mauro Carvalho Chehab commit 8539488840ade3124284eebe7abcd3c6dd0b7f77 Author: Paul Mundt Date: Fri Aug 1 19:48:51 2008 -0300 V4L/DVB (8609): media: Clean up platform_driver_unregister() bogosity. So, platform_driver_unregister() doesn't actually have a return value, nor do any of the void __exit routines. It's reassuring to know that people copy and paste blindly. This completely blew up my compiler. Signed-off-by: Paul Mundt Signed-off-by: Guennadi Liakhovetski Signed-off-by: Mauro Carvalho Chehab commit 0dadf365e1e099e9d274b0373321ad54b6f08f25 Author: Robert Lowery Date: Wed Jul 30 19:43:11 2008 -0300 V4L/DVB (8607): cxusb: fix OOPS and broken tuning regression on FusionHDTV Dual Digital 4 quoting Robert Lowery: I think I've found the cause of the oops. [...] BTW it appears I have fixed my tuning problems with the updated patch below. This reverts a change Mauro made a while back. All is good now :) [...] The good news is that I've got a better patch that definitely works this time and even better, makes use of the standard firmware (rather than the Australian specific one). ...based on an earlier patch by Hans-Frieder Vogt: http://www.linuxtv.org/pipermail/linux-dvb/2008-May/026280.html Signed-off-by: Robert Lowery Signed-off-by: Michael Krufky Signed-off-by: Mauro Carvalho Chehab commit 640fd818eaaf548ae4f1347acf39cb9dba32ca84 Author: Rabin Vincent Date: Sun Aug 3 07:58:54 2008 -0300 V4L/DVB (8605): gspca: Fix of gspca_zc3xx oops - 2.6.27-rc1 Bad mini/max check in setting control values (the gamma in zc3xx could be set to null). Signed-off-by: Rabin Vincent Signed-off-by: Jean-Francois Moine Signed-off-by: Mauro Carvalho Chehab commit e9e25e1593b32279495876f16468ed04e500d374 Author: Jean-Francois Moine Date: Sun Aug 3 07:52:53 2008 -0300 V4L/DVB (8604): gspca: Fix of "scheduling while atomic" crash. The crash is due to USB exchanges done at interrupt level. These exchanges, tied to autogain, are now done by the application. Also, there is a fix about autogain start. Concerned subdrivers: etoms, pac7311, sonixj and spca561. Signed-off-by: Jean-Francois Moine Signed-off-by: Mauro Carvalho Chehab commit 544fd6fabe49b297797b5f06787675f9916e2b64 Author: Jean-Francois Moine Date: Fri Aug 1 06:37:51 2008 -0300 V4L/DVB (8602): gspca: Fix small bugs, simplify and cleanup ov519. The hflip and vflip controls work for ov519 - ov7670 only. Signed-off-by: Jean-Francois Moine Signed-off-by: Mauro Carvalho Chehab commit 778d22a8903cb7af601fec96b12b7625d91fcaf7 Author: Eugeniy Meshcheryakov Date: Fri Aug 1 08:23:41 2008 -0300 V4L/DVB (8582): set mts_firmware for em2882 based Pinnacle Hybrid Pro Pinnacle Hybrid Pro (2304:0226) requires mts_firmware flag to have any sound. Without this flag it is useful only for watching silent movies. Signed-off-by: Eugeniy Meshcheryakov Signed-off-by: Mauro Carvalho Chehab commit 67128372d40bd93ba8fe02a0819a9164ee99aa56 Author: Jean-Francois Moine Date: Wed Jul 30 05:47:54 2008 -0300 V4L/DVB (8574): gspca: Bad bytesperlines of pixelformat in spca505/506/508 and vc023x. Signed-off-by: Jean-Francois Moine Signed-off-by: Mauro Carvalho Chehab commit a4d6d3256252c73010a8cea72e8096aab2b7db3a Author: Jean-Francois Moine Date: Wed Jul 30 05:33:11 2008 -0300 V4L/DVB (8573): gspca: Bad scan of frame in spca505/506/508. Bug introduced in changeset 6de914aaad86. Signed-off-by: Jean-Francois Moine Signed-off-by: Mauro Carvalho Chehab commit e5e5d88e0ea6d62510f11dca859cc57696da8e2d Author: Jean-Francois Moine Date: Wed Jul 30 05:14:38 2008 -0300 V4L/DVB (8572): gspca: Webcam 0c45:6143 in documentation. Signed-off-by: Jean-Francois Moine Signed-off-by: Mauro Carvalho Chehab commit b1705438f4a20df7be2831ba3b0c3ecbdadfaf19 Author: Jean-Francois Moine Date: Wed Jul 30 04:53:02 2008 -0300 V4L/DVB (8571): gspca: Don't use CONFIG_VIDEO_ADV_DEBUG as a compile option. This option is changed to GSPCA_DEBUG and it is set by default in gspca.h. Signed-off-by: Jean-Francois Moine Signed-off-by: Mauro Carvalho Chehab commit eb63fcf9f77844a3e225bf6c236aef0f8fcaff70 Author: Jean-Francois Moine Date: Tue Jul 29 14:14:04 2008 -0300 V4L/DVB (8569): gspca: Set back the old values of Sonix sn9c120 and cleanup source. The values from win traces do not seem to work while the webcams did work with gspca v1. Signed-off-by: Jean-Francois Moine Signed-off-by: Mauro Carvalho Chehab commit 878e760ed41148361d4a4b0f84ccd56e913ec5da Author: Jean-Francois Moine Date: Tue Jul 29 05:25:28 2008 -0300 V4L/DVB (8567): gspca: hflip and vflip controls added for ov519 - ov7670 plus init cleanup. The hflip and vflip controls work for ov7670 only. This bridge/sensor inverts blue and red - not fixed. Signed-off-by: Jean-Francois Moine Signed-off-by: Mauro Carvalho Chehab commit 003f50fa697f77cef99c8fc90b70bf9a940bbd75 Author: Rene Herman Date: Tue Jul 15 16:24:50 2008 +0200 ALSA: re-order AC97 codec ID table. Signed-off-by: Rene Herman Signed-off-by: Takashi Iwai commit 16e00b609aed439453d57b954b449f647466e0d7 Author: David Woodhouse Date: Mon Aug 4 11:25:23 2008 +0100 [MTD] Remove references to TI 'toto' platform. This was a reference board for which support never got merged upstream. Kill it off, at rmk's suggestion. Signed-off-by: David Woodhouse commit 525dc70209304952b5e9977e1abcb574a612ec98 Author: Lachlan McIlroy Date: Mon Aug 4 18:07:59 2008 +1000 [XFS] Merge up to 2.6.26 SGI-PV: 957103 SGI-Modid: xfs-linux-melb:xfs-kern:31804a Signed-off-by: Lachlan McIlroy commit 8f525b284a2d22c7d421f010f0ba1637a3d0d701 Author: Lachlan McIlroy Date: Mon Aug 4 17:44:55 2008 +1000 [XFS] Use the same btree_cur union member for alloc and inobt trees. The alloc and inobt btree use the same agbp/agno pair in the btree_cur union. Make them use the same bc_private.a union member so that code for these two short form btree implementations can be shared. SGI-PV: 981498 SGI-Modid: xfs-linux-melb:xfs-kern:31788a Signed-off-by: Christoph Hellwig Signed-off-by: Tim Shimmin Signed-off-by: David Chinner Signed-off-by: Lachlan McIlroy commit abf841a0e5421d9ce97fbdbc795ed7ab03d7331e Author: Christoph Hellwig Date: Mon Aug 4 17:41:45 2008 +1000 [XFS] small cleanups in xfs_btree.c Remove unneeded xfs_btree_get_block forward declaration. Move xfs_btree_firstrec next to xfs_btree_lastrec. SGI-PV: 981498 SGI-Modid: xfs-linux-melb:xfs-kern:31787a Signed-off-by: Christoph Hellwig Signed-off-by: Tim Shimmin Signed-off-by: David Chinner Signed-off-by: Lachlan McIlroy commit bd8a72d8b142c780cd2833564a5bf581403335af Author: Christoph Hellwig Date: Mon Aug 4 17:41:38 2008 +1000 [XFS] sanitize xfs_initialize_vnode Sanitize setting up the Linux indode. Setting up the xfs_inode <-> inode link is opencoded in xfs_iget_core now because that's the only place it needs to be done, xfs_initialize_vnode is renamed to xfs_setup_inode and loses all superflous paramaters. The check for I_NEW is removed because it always is true and the di_mode check moves into xfs_iget_core because it's only needed there. xfs_set_inodeops and xfs_revalidate_inode are merged into xfs_setup_inode and the whole things is moved into xfs_iops.c where it belongs. SGI-PV: 981498 SGI-Modid: xfs-linux-melb:xfs-kern:31782a Signed-off-by: Christoph Hellwig Signed-off-by: Niv Sardi Signed-off-by: Lachlan McIlroy commit 8e47c0b2427f0ea35984f02648163cc7a35d3592 Author: Christoph Hellwig Date: Mon Aug 4 17:41:30 2008 +1000 [XFS] kill bhv_vnode_t All remaining bhv_vnode_t instance are in code that's more or less Linux specific. (Well, for xfs_acl.c that could be argued, but that code is on the removal list, too). So just do an s/bhv_vnode_t/struct inode/ over the whole tree. We can clean up variable naming and some useless helpers later. SGI-PV: 981498 SGI-Modid: xfs-linux-melb:xfs-kern:31781a Signed-off-by: Christoph Hellwig Signed-off-by: Lachlan McIlroy commit b362cf8e1c6b9c2895b2e154ff48d63e8d6ed05e Author: Christoph Hellwig Date: Mon Aug 4 17:41:21 2008 +1000 [XFS] remove some easy bhv_vnode_t instances In various places we can just move a VFS_I call into the argument list of called functions/macros instead of having a local bhv_vnode_t. SGI-PV: 981498 SGI-Modid: xfs-linux-melb:xfs-kern:31776a Signed-off-by: Christoph Hellwig Signed-off-by: Lachlan McIlroy commit 4cb6a9aa791f235679808d579e1266362ca0eb30 Author: Niv Sardi Date: Mon Aug 4 17:41:12 2008 +1000 [XFS] Revert remove mounpoint UUID code As spotted by dchinner and hch, this touches on-disk format and log format, should be more carefully reviewed. SGI-PV: 981498 SGI-Modid: xfs-linux-melb:xfs-kern:31773a Signed-off-by: Niv Sardi Signed-off-by: Christoph Hellwig Signed-off-by: Lachlan McIlroy commit da3369242ba2eabca6c3689948d4c01766c4b214 Author: Christoph Hellwig Date: Mon Aug 4 17:41:02 2008 +1000 [XFS] kill xfs_lock_dir_and_entry When multiple inodes are locked in XFS it happens in order of the inode number, with the everything but the first inode trylocked if any of the previous inodes is in the AIL. Except for the sorting of the inodes this logic is implemented in xfs_lock_inodes, but also partially duplicated in xfs_lock_dir_and_entry in a particularly stupid way adds a lock roundtrip if the inode ordering is not optimal. This patch adds a new helper xfs_lock_two_inodes that takes two inodes and locks them in the most optimal way according to the above locking protocol and uses it for all places that want to lock two inodes. The only caller of xfs_lock_inodes is xfs_rename which might lock up to four inodes. SGI-PV: 981498 SGI-Modid: xfs-linux-melb:xfs-kern:31772a Signed-off-by: Christoph Hellwig Signed-off-by: Donald Douwsma Signed-off-by: Lachlan McIlroy commit 8660428d2d58c58aba5ab01b4f95106b1b6e16b2 Author: Christoph Hellwig Date: Mon Aug 4 17:40:54 2008 +1000 [XFS] kill INDUCE_IO_ERROR All the error injection is already enabled through ifdef DEBUG, so kill the never set second cpp symbol to activate it without the rest of the debugging infrastructure. SGI-PV: 981498 SGI-Modid: xfs-linux-melb:xfs-kern:31771a Signed-off-by: Christoph Hellwig Signed-off-by: Niv Sardi Signed-off-by: Lachlan McIlroy commit 427c691fe62e0550e805f22aa3e42aa3065df24b Author: Niv Sardi Date: Mon Aug 4 17:40:40 2008 +1000 [XFS] remove mounpoint UUID code It looks like all of the below is unused... and according to Nathan, "dont think it even got used/implemented anywhere, but i think it was meant to be an auto-mount kinda thing... such that when you look up at that point, it knows to mount the device with that uuid there, if its not already it was never really written anywhere ... just an idea in doug doucettes brain i think." Think it'll ever go anywhere, or should it get pruned? The below builds; not at all tested, until I get an idea if it's worth doing. Need to double check that some structures might not need padding out to keep things compatible/consistent... SGI-PV: 981498 SGI-Modid: xfs-linux-melb:xfs-kern:31766a Signed-off-by: Niv Sardi Signed-off-by: Christoph Hellwig Signed-off-by: Eric Sandeen Signed-off-by: Lachlan McIlroy commit e4ee01c93037e31958d4263ba7f6eb455129016b Author: Christoph Hellwig Date: Mon Aug 4 17:40:29 2008 +1000 [XFS] implement IHOLD/IRELE directly Now that all direct calls to VN_HOLD/VN_RELE are gone we can implement IHOLD/IRELE directly. For the IHOLD case also replace igrab with a direct increment of i_count because we are guaranteed to already have a live and referenced inode by the VFS. Also remove the vn_hold statistic because it's been rather meaningless for some time with most references done by other callers. SGI-PV: 981498 SGI-Modid: xfs-linux-melb:xfs-kern:31764a Signed-off-by: Christoph Hellwig Signed-off-by: Lachlan McIlroy commit 62cba80a6b8c24d1df91ae1f368d1e52b3b08e90 Author: Christoph Hellwig Date: Mon Aug 4 17:40:22 2008 +1000 [XFS] remove remaining VN_HOLD calls Use IHOLD(ip) instead of VN_HOLD(VFS_I(ip)). SGI-PV: 981498 SGI-Modid: xfs-linux-melb:xfs-kern:31765a Signed-off-by: Christoph Hellwig Signed-off-by: Lachlan McIlroy commit 111eca90edfa76b361aef986f377b6f76c0d96d9 Author: Christoph Hellwig Date: Mon Aug 4 17:40:14 2008 +1000 [XFS] remove spurious VN_HOLD/VN_RELE calls from xfs_acl.c All the ACL routines are called from inode operations which are guaranteed to have a referenced inode by the VFS, so there's no need for the ACL code to grab another temporary one. SGI-PV: 981498 SGI-Modid: xfs-linux-melb:xfs-kern:31763a Signed-off-by: Christoph Hellwig Signed-off-by: Lachlan McIlroy commit 38a8b732dc078a9059095d928a0eca72e5470af0 Author: Christoph Hellwig Date: Mon Aug 4 17:39:32 2008 +1000 [XFS] kill vn_to_inode bhv_vnode_t is just a typedef for struct inode, so there's no need for a helper to convert between the two. SGI-PV: 981498 SGI-Modid: xfs-linux-melb:xfs-kern:31761a Signed-off-by: Christoph Hellwig Signed-off-by: Lachlan McIlroy commit f3809c5da97b26475d4e18c4089ae78f74e5200e Author: Christoph Hellwig Date: Mon Aug 4 17:39:23 2008 +1000 [XFS] Remove vn_from_inode() bhv_vnode_t is just a typedef for struct inode, so there's no need for a helper to convert between the two. SGI-PV: 981498 SGI-Modid: xfs-linux-melb:xfs-kern:31760a Signed-off-by: Christoph Hellwig Signed-off-by: Lachlan McIlroy commit 1367be526779a44acbea0660c9ac8fbd24bd0211 Author: Eric Sandeen Date: Mon Aug 4 17:39:16 2008 +1000 [XFS] remove shouting-indirection macros from xfs_trans.h compile-tested, fairly easy to inspect with: quilt diff --diff="diff -iu" SGI-PV: 981498 SGI-Modid: xfs-linux-melb:xfs-kern:31758a Signed-off-by: Eric Sandeen Signed-off-by: Niv Sardi Signed-off-by: Lachlan McIlroy commit 31048586a1d967e855dce8a8d420b3acbcb7d879 Author: Eric Sandeen Date: Mon Aug 4 17:39:06 2008 +1000 [XFS] convert xfs to use ERR_CAST Looks like somehow xfs got missed in the conversion that took place in e231c2ee64eb1c5cd3c63c31da9dac7d888dcf7f, "Convert ERR_PTR(PTR_ERR(p)) instances to ERR_CAST(p) " SGI-PV: 981498 SGI-Modid: xfs-linux-melb:xfs-kern:31757a Signed-off-by: Eric Sandeen Acked-by: David Howells Signed-off-by: Niv Sardi Signed-off-by: Christoph Hellwig Signed-off-by: David Howells Signed-off-by: Lachlan McIlroy commit 9be98bcc84cbb6ab2d1bd39548fc95a144127688 Author: Lachlan McIlroy Date: Mon Aug 4 17:37:51 2008 +1000 [XFS] remove INT_GET and friends Thanks to hch's endian work, INT_GET etc are no longer used, and may as well be removed. INT_SET is still used in the acl code, though. SGI-PV: 981498 SGI-Modid: xfs-linux-melb:xfs-kern:31756a Signed-off-by: Eric Sandeen Signed-off-by: Niv Sardi Signed-off-by: Christoph Hellwig Signed-off-by: Lachlan McIlroy commit dd3d0369e5fba5a5fcf0099e34713839c855f023 Author: Niv Sardi Date: Mon Aug 4 17:30:09 2008 +1000 [XFS] Move xfs_attr_rolltrans to xfs_trans_roll Move it from the attr code to the transaction code and make the attr code call the new function. We rolltrans is really usefull whenever we want to use rolling transaction, should be generic, it isn't dependent on any part of the attr code anyway. We use this excuse to change all the: if ((error = xfs_attr_rolltrans())) calls into: error = xfs_trans_roll(); if (error) SGI-PV: 981498 SGI-Modid: xfs-linux-melb:xfs-kern:31729a Signed-off-by: Niv Sardi Signed-off-by: Christoph Hellwig Signed-off-by: Lachlan McIlroy commit 0fe8f37b4eb0b1f10c6be7e363bfff7d81f5c2d8 Author: Christoph Hellwig Date: Mon Aug 4 17:29:59 2008 +1000 [XFS] don't leak m_fsname/m_rtname/m_logname Add a helper to free the m_fsname/m_rtname/m_logname allocations and use it properly for all mount failure cases. Also switch the allocations for these to kstrdup while we're at it. SGI-PV: 981498 SGI-Modid: xfs-linux-melb:xfs-kern:31728a Signed-off-by: Christoph Hellwig Signed-off-by: Niv Sardi Signed-off-by: David Chinner Signed-off-by: Lachlan McIlroy commit cb654519f48bc0fbc3a76fb2a044cf600443f6a7 Author: Niv Sardi Date: Mon Aug 4 17:29:53 2008 +1000 [XFS] Move attr log alloc size calculator to another function. We will need that to be able to calculate the size of log we need for a specific attr (for Create+EA). The local flag is needed so that we can fail if we run into ENOSPC when trying to alloc blocks. SGI-PV: 981498 SGI-Modid: xfs-linux-melb:xfs-kern:31727a Signed-off-by: Niv Sardi Signed-off-by: Christoph Hellwig Signed-off-by: Tim Shimmin Signed-off-by: Lachlan McIlroy commit 8c6266658cb76e282c14cb92f8ba5a1c674f4928 Author: David Chinner Date: Mon Aug 4 17:29:46 2008 +1000 [XFS] Use KM_NOFS for incore inode extent tree allocation V2 If we allow incore extent tree allocations to recurse into the filesystem under memory pressure, new delayed allocations through xfs_iomap_write_delay() can deadlock on themselves if memory reclaim tries to write back dirty pages from that inode. It will deadlock in xfs_iomap_write_allocate() trying to take the ilock we already hold. This can also show up as complex ABBA deadlocks when multiple threads are triggering memory reclaim when trying to allocate extents. The main cause of this is the fact that delayed allocation is not done in a transaction, so KM_NOFS is not automatically added to the allocations to prevent this recursion. Mark all allocations done for the incore inode extent tree as KM_NOFS to ensure they never recurse back into the filesystem. Version 2: o KM_NOFS implies KM_SLEEP, so just use KM_NOFS SGI-PV: 981498 SGI-Modid: xfs-linux-melb:xfs-kern:31726a Signed-off-by: David Chinner Signed-off-by: Niv Sardi Signed-off-by: Christoph Hellwig Signed-off-by: David Chinner Signed-off-by: Lachlan McIlroy commit 6811235504abbeed42673cf70014759f39e12a9b Author: David Chinner Date: Mon Aug 4 17:29:39 2008 +1000 [XFS] XFS: Kill xfs_vtoi() xfs_vtoi() is redundant and only unsed in small sections of code. Replace them with widely used XFS_I() inline and kill xfs_vtoi(). SGI-PV: 981498 SGI-Modid: xfs-linux-melb:xfs-kern:31725a Signed-off-by: David Chinner Signed-off-by: Niv Sardi Signed-off-by: Christoph Hellwig Signed-off-by: David Chinner Signed-off-by: Lachlan McIlroy commit a1ae0144482202cbb5191571852c329a352f10e5 Author: David Chinner Date: Mon Aug 4 17:29:32 2008 +1000 [XFS] Kill shouty XFS_ITOV() macro Replace XFS_ITOV() with the new VFS_I() inline. SGI-PV: 981498 SGI-Modid: xfs-linux-melb:xfs-kern:31724a Signed-off-by: David Chinner Signed-off-by: Niv Sardi Signed-off-by: Christoph Hellwig Signed-off-by: David Chinner Signed-off-by: Lachlan McIlroy commit 20c1bd2cc6d9311fb7d7d0eb91b46dc4a42b5d11 Author: David Chinner Date: Mon Aug 4 17:29:23 2008 +1000 [XFS] Avoid directly referencing the VFS inode V2 In several places we directly convert from the XFS inode to the linux (VFS) inode by a simple deference of ip->i_vnode. We should not do this - a helper function should be used to extract the VFS inode from the XFS inode. Introduce the function VFS_I() to extract the VFS inode from the XFS inode. The name was chosen to match XFS_I() which is used to extract the XFS inode from the VFS inode. Version 2: o don't use vn_to_inode() and inode_to_vn() functions as they are not needed SGI-PV: 981498 SGI-Modid: xfs-linux-melb:xfs-kern:31722a Signed-off-by: David Chinner Signed-off-by: Niv Sardi Signed-off-by: Christoph Hellwig Signed-off-by: David Chinner Signed-off-by: Lachlan McIlroy commit 293a47c282254cbae1c96cfb2e242e57c050f5c7 Author: David Chinner Date: Mon Aug 4 17:29:15 2008 +1000 [XFS] In several places we directly convert from the XFS inode to the linux (VFS) inode by a simple deference of ip->i_vnode. We should not do this - a helper function should be used to extract the VFS inode from the XFS inode. Introduce the function VFS_I() to extract the VFS inode from the XFS inode. The name was chosen to match XFS_I() which is used to extract the XFS inode from the VFS inode. Version 2: o don't use vn_to_inode() and inode_to_vn() functions as they are not needed SGI-PV: 981498 SGI-Modid: xfs-linux-melb:xfs-kern:31720a Signed-off-by: David Chinner Signed-off-by: Niv Sardi Signed-off-by: Christoph Hellwig Signed-off-by: David Chinner Signed-off-by: Lachlan McIlroy commit 6878e6b0ea41de3040dba9453b24ce644c02088d Author: Lachlan McIlroy Date: Mon Aug 4 17:29:05 2008 +1000 [XFS] Do not access buffers after dropping reference count We should not access a buffer after dropping it's reference count otherwise we could race with another thread that releases the final reference count and frees the buffer causing us to access potentially unmapped memory. The bug this change fixes only occured on DEBUG XFS since the offending code was in an ASSERT. SGI-PV: 984429 SGI-Modid: xfs-linux-melb:xfs-kern:31715a Signed-off-by: Lachlan McIlroy Signed-off-by: David Chinner commit 83bd10f890a7b49c085b9a2554e3c27af3e107d1 Author: Julia Lawall Date: Sat Aug 2 17:13:09 2008 +0200 ieee1394: Use DIV_ROUND_UP Signed-off-by: Julia Lawall Signed-off-by: Stefan Richter commit c8872b069c536976b81bccfc95dda945594bc504 Author: Julia Lawall Date: Sat Aug 2 17:14:21 2008 +0200 [MTD] Use DIV_ROUND_UP The kernel.h macro DIV_ROUND_UP performs the computation (((n) + (d) - 1) / (d)) but is perhaps more readable. Signed-off-by: Julia Lawall Signed-off-by: David Woodhouse commit 53efec9513cfb1acff602c7ebdd945d677808e9e Author: Dominik Brodowski Date: Mon Jul 28 19:44:05 2008 +0200 pcmcia: only copy CIS override data once Instead of copying CIS override data in socket_sysfs.c or ds.c, and then again in cistpl.c, only do so once. Also, cisdump_t is now only used by the deprecated ioctl. Signed-off-by: Dominik Brodowski commit 9c20ac728f9608f6c70530d7d248b96a32978fa9 Author: Bjorn Helgaas Date: Fri Aug 1 15:58:17 2008 -0600 ACPI: bounds check IRQ to prevent memory corruption acpi_penalize_isa_irq() should validate irq before using it to index the acpi_irq_penalty[] table. Here's the path I'm concerned about: pnpacpi_parse_allocated_irqresource() { ... irq = acpi_register_gsi(gsi, triggering, polarity); if (irq >= 0) pcibios_penalize_isa_irq(irq, 1); There's no guarantee that acpi_register_gsi() will return an IRQ within the bounds of acpi_irq_penalty[]. I have not seen a failure I can attribute to this. However, ACPI_MAX_IRQS is only 256, and I'm pretty sure ia64 can have IRQs larger than that. I think this should go in 2.6.27. Signed-off-by: Bjorn Helgaas Signed-off-by: Andi Kleen commit c4308d1076830a72e05eb3e5f58b9ed851229399 Author: Kumar Gala Date: Fri Aug 1 11:44:20 2008 -0500 [MTD] remove code associated with !CONFIG_PPC_MERGE Now that arch/ppc is gone we don't need CONFIG_PPC_MERGE anymore remove the dead code associated with !CONFIG_PPC_MERGE. The mtd maps should be using the OF based mechanism. Signed-off-by: Kumar Gala Acked-by: Josh Boyer Signed-off-by: David Woodhouse commit feb2f55db45919aa80731f8877b60cab454b7b94 Author: Adrian Hunter Date: Fri Aug 1 11:53:29 2008 +0300 [MTD] [OneNAND] Add defines for HF and sync write Signed-off-by: Adrian Hunter Signed-off-by: David Woodhouse commit 34a82443b79dcda4304b229d555586296da40c16 Author: David Brownell Date: Wed Jul 30 12:35:05 2008 -0700 [MTD] dataflash OTP support Now that we can tell when we have one of the newer DataFlash chips, optionally expose the 128 bytes of OTP memory they provide. Tested on at45db642 revision B and D chips. Switch mtdchar over to a generic HAVE_MTD_OTP flag instead of adding another #ifdef for each type of chip whose driver has OTP support. Signed-off-by: David Brownell Cc: Bryan Wu Cc: Michael Hennerich Signed-off-by: Andrew Morton Signed-off-by: David Woodhouse commit ef0471220ff3ac314f9ee1c8533f2b5bd4bedd7f Author: Bjorn Helgaas Date: Fri Aug 1 10:01:12 2008 -0600 PNP: add Bjorn Helgaas as PNP co-maintainer Update Adam's email address and add myself as PNP co-maintainer. Signed-off-by: Bjorn Helgaas Signed-off-by: Andi Kleen commit bcca9a4a97b6e270793003d745d6f9439e1357a8 Author: Thomas Renninger Date: Fri Aug 1 17:38:03 2008 +0200 thinkpad_acpi: fingers off backlight if video.ko is serving this functionality Signed-off-by: Thomas Renninger Signed-off-by: Andi Kleen commit 1d38a0697573617e7f4d184207cced6cbe8d54d5 Author: Thomas Renninger Date: Fri Aug 1 17:38:02 2008 +0200 sony-laptop: fingers off backlight if video.ko is serving this functionality Signed-off-by: Thomas Renninger Signed-off-by: Andi Kleen commit a8c338259a436627d2427d70dc31fac67b86b9e6 Author: Thomas Renninger Date: Fri Aug 1 17:38:01 2008 +0200 msi-laptop: fingers off backlight if video.ko is serving this functionality Signed-off-by: Thomas Renninger Signed-off-by: Andi Kleen commit 44cce15b053d27477980e34b1086e0c3ce642afe Author: Thomas Renninger Date: Fri Aug 1 17:38:00 2008 +0200 fujitsu-laptop: fingers off backlight if video.ko is serving this functionality Signed-off-by: Thomas Renninger Signed-off-by: Andi Kleen commit bb7e1665304cba64b1178237c966308d06b33182 Author: Thomas Renninger Date: Fri Aug 1 17:37:59 2008 +0200 eeepc-laptop: fingers off backlight if video.ko is serving this functionality Signed-off-by: Thomas Renninger Signed-off-by: Andi Kleen commit efbc58e3236022d040e1c1f177ee5971d46b034f Author: Thomas Renninger Date: Fri Aug 1 17:37:58 2008 +0200 compal: fingers off backlight if video.ko is serving this functionality Signed-off-by: Thomas Renninger Signed-off-by: Andi Kleen commit aaa47082a287d66fad32e3289e01bb9419ab18da Author: Thomas Renninger Date: Fri Aug 1 17:37:57 2008 +0200 asus-acpi: fingers off backlight if video.ko is serving this functionality Signed-off-by: Thomas Renninger Signed-off-by: Andi Kleen commit 017f8ecd1cedb482392f0500ee3701b8c50a46f9 Author: Thomas Renninger Date: Fri Aug 1 17:37:56 2008 +0200 Acer-WMI: fingers off backlight if video.ko is serving this functionality Signed-off-by: Thomas Renninger Signed-off-by: Andi Kleen commit f43d728731c691772ddc29e50d25c68a859935b5 Author: Thomas Renninger Date: Fri Aug 1 17:37:55 2008 +0200 Check for ACPI backlight support otherwise use vendor ACPI drivers If an ACPI graphics device supports backlight brightness functions (cmp. with latest ACPI spec Appendix B), let the ACPI video driver control backlight and switch backlight control off in vendor specific ACPI drivers (asus_acpi, thinkpad_acpi, eeepc, fujitsu_laptop, msi_laptop, sony_laptop, acer-wmi). Currently it is possible to load above drivers and let both poke on the brightness HW registers, the video and vendor specific ACPI drivers -> bad. This patch provides the basic support to check for BIOS capabilities before driver loading time. Driver specific modifications are in separate follow up patches. acpi_backlight=vendor/video boot params forces video.ko or vendor specific drivers to keep its fingers off backlight control even it would find needed functions. The corresponding vendor specific driver be used then. Signed-off-by: Thomas Renninger Signed-off-by: Andi Kleen commit ad9ed8385ed6ec5be8da7094db911c824258ceec Author: Thomas Renninger Date: Fri Aug 1 17:37:54 2008 +0200 ACPI: video: Ignore devices that aren't present in hardware This is a reimplemention of commit 0119509c4fbc9adcef1472817fda295334612976 from Matthew Garrett This patch got removed because of a regression: ThinkPads with a Intel graphics card and an Integrated Graphics Device BIOS implementation stopped working. In fact, they only worked because the ACPI device of the discrete, the wrong one, got used (via int10). So ACPI functions were poking on the wrong hardware used which is a sever bug. The next patch provides support for above ThinkPads to be able to switch brightness via the legacy thinkpad_acpi driver and automatically detect when to use it. Original commit message from Matthew Garrett: Vendors often ship machines with a choice of integrated or discrete graphics, and use the same DSDT for both. As a result, the ACPI video module will locate devices that may not exist on this specific platform. Attempt to determine whether the device exists or not, and abort the device creation if it doesn't. http://bugzilla.kernel.org/show_bug.cgi?id=9614 Signed-off-by: Thomas Renninger Signed-off-by: Andi Kleen commit 4fa126f2527fe4da4a10a11054dc0805f25070e4 Author: Harald Welte Date: Fri Aug 1 00:02:04 2008 +0200 Add Panasonic Laptop ACPI extras driver This is a driver for ACPI extras such as hotkeys and backlight brightness control on various Panasonic "Let's Note" series laptop computers. It exports the backlight via the backlight class device API, and the hotkeys as input event device. Some more esoteric items like number of installed batteries are exported via sysfs device attributes. Hotkey events also generate old-style ACPI enents through /proc/acpi/event to interoperate with current versions of acpid. Signed-off-by: Harald Welte Acked-by: Henrique de Moraes Holschuh Acked-by: Matthew Garrett Signed-off-by: Andi Kleen commit 7ab6af7ab69df8c9c5fbc380004fb81187742096 Author: Hiroshi Shimamoto Date: Wed Jul 30 17:36:48 2008 -0700 x86_32: use apic_ops at print_local_APIC() Use apic_icr_read at print_local_APIC() in io_apic_32.c Signed-off-by: Hiroshi Shimamoto Cc: Suresh Siddha Cc: Yinghai Lu Signed-off-by: Ingo Molnar Cc: Suresh Siddha Cc: Yinghai Lu commit daa9c0fee1cbe1d49fbe29af3d4bb16312043b1e Author: Peter Oruba Date: Tue Jul 29 17:41:07 2008 +0200 x86: minor pointer type cast in AMD microcode patch loader Signed-off-by: Peter Oruba Cc: Peter Oruba Cc: Tigran Aivazian Signed-off-by: Ingo Molnar commit 831f9bd3151ebd22959a0cb2a20b44a06b26d4ed Author: Peter Oruba Date: Tue Jul 29 17:41:06 2008 +0200 x86: moved function declarations out from AMD microcode patch loader to heade file Signed-off-by: Peter Oruba Cc: Peter Oruba Cc: Tigran Aivazian Signed-off-by: Ingo Molnar commit f516526febb75500f280def2108688d388df4e1e Author: Peter Oruba Date: Tue Jul 29 17:41:05 2008 +0200 x86: Intel microcode patch loader style corrections Signed-off-by: Peter Oruba Cc: Tigran Aivazian Signed-off-by: Ingo Molnar commit a0ac87d61ba20932e54f08464d3f3439d78fa878 Author: Peter Oruba Date: Tue Jul 29 17:41:04 2008 +0200 x86: AMD microcode patch loader style corrections Signed-off-by: Peter Oruba Cc: Tigran Aivazian Signed-off-by: Ingo Molnar commit a677f58a8c8c541bf7d02c658545084040f3708d Author: Yinghai Lu Date: Tue Jul 29 00:37:10 2008 -0700 x86: print per_cpu data address to make sure per_cpu data on correct node. Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit f0bfc3b9ba1ab37d84171200045b0acf4d2de195 Author: Lin Ming Date: Thu Jul 31 23:02:28 2008 +0200 Delete an unwanted return statement at evgpe.c Len's tree branch release-2.6.27, found an unwanted return statement at evgpe.c. (git://git.kernel.org/pub/scm/linux/kernel/git/lenb/linux-acpi-2.6 release-2.6.27) Signed-of-by Lin Ming Signed-off-by: Andi Kleen commit 5eea0b9b20520895e14399f6bbfb5ddaa5be5d1b Author: Bjorn Helgaas Date: Wed Jul 30 12:14:30 2008 -0600 PNP: fix formatting of dbg_pnp_show_resources() output Each resource should be printed on its own line, so start snprintf'ing at the beginning of the buffer every time through the loop. Also, use scnprintf() rather than snprintf() when building up the buffer to print. scnprintf() returns the number of characters actually written into the buffer (not including the trailing NULL). snprintf() returns the number of characters that *would be* written, assuming everything would fit in the buffer. That's nice if we want to resize the buffer to make sure everything fits, but in this case, I just want to keep from overflowing the buffer, and it's OK if the output is truncated. Using snprintf() meant that my "len" could grow to be more than the the buffer size, which makes "sizeof(buf) - len" negative, which causes this alarming WARN_ON: http://marc.info/?l=linux-kernel&m=121736480005656&w=2 More useful snprintf/scnprintf discussion: http://lwn.net/Articles/69419/ Signed-off-by: Bjorn Helgaas Signed-off-by: Andi Kleen commit f7fdf2f35853be793b75381d3a117dfc559df5ae Author: Bjorn Helgaas Date: Tue Jul 29 15:43:56 2008 -0600 ACPI: update debug parameter documentation Reformat acpi.debug_layer and acpi.debug_level documentation so it's readable, add some clues about how to figure out the mask bits that enable a given ACPI_DEBUG_PRINT statement, and include a couple useful examples. Signed-off-by: Bjorn Helgaas Signed-off-by: Andi Kleen commit 69aa13a2c9b94ea99b3611e7a24ce4662f14e726 Author: Yinghai Lu Date: Fri Jul 18 16:22:15 2008 -0700 acpi: remove have_arch_parse_srat in acpi.h 32bit don't need that anymore Signed-off-by: Yinghai Lu Signed-off-by: Andi Kleen commit f92a789d259eb95afe7498ff5938fe2a93d39c82 Author: David Brownell Date: Thu Jul 31 12:59:56 2008 -0700 hpet: /dev/hpet - fixes and cleanup, fix fix: On Thursday 31 July 2008, Ingo Molnar wrote: >   drivers/built-in.o: In function `hpet_alloc': >   : undefined reference to `__udivdi3' >   drivers/built-in.o: In function `hpet_alloc': >   : undefined reference to `__umoddi3' Signed-off-by: David Brownell Signed-off-by: Ingo Molnar commit 64a76f667d987a559ad0726b4692c987800b22bc Author: David Brownell Date: Tue Jul 29 12:47:38 2008 -0700 hpet: /dev/hpet - fixes and cleanup Minor /dev/hpet updates and bugfixes: * Remove dead code, mostly remnants of an incomplete/unusable kernel interface ... noted when addressing "sparse" warnings: + hpet_unregister() and a routine it calls + hpet_task and all references, including hpet_task_lock + hpet_data.hd_flags (and HPET_DATA_PLATFORM) * Correct and improve boot message: + displays *counter* (shared between comparators) bit width, not *timer* bit widths (which are often mixed) + relabel "timers" as "comparators"; this is less confusing, they are not independent like normal timers are (sigh) + display MHz not Hz; it's never less than 10 MHz. * Tighten and correct the userspace interface code + don't accidentally program comparators in 64-bit mode using 32-bit values ... always force comparators into 32-bit mode + provide the correct bit definition flagging comparators with periodic capability ... the ABI is unchanged * Update Documentation/hpet.txt + be more correct and current + expand description a bit + don't mention that now-gone kernel interface Plus, add a FIXME comment for something that could cause big trouble on systems with more capable HPETs than at least Intel seems to ship. It seems that few folk use this userspace interface; it's not very usable given the general lack of HPET IRQ routing. I'm told that the only real point of it any more is to mmap for fast timestamps; IMO that's handled better through the gettimeofday() vsyscall. Signed-off-by: David Brownell Acked-by: Clemens Ladisch Signed-off-by: Ingo Molnar commit e9c8abb66cc37801bdb5d4360bb78d180c3bbb73 Author: Gustavo F. Padovan Date: Tue Jul 29 02:48:56 2008 -0300 x86: coding style fixes to arch/x86/kernel/sys_x86_64.c Fix all errors and many warnings reported by checkpatch.pl without change sys_x86_64.o arch/x86/kernel/sys_x86_64.o: text data bss dec hex filename 1567 0 0 1567 61f sys_x86_64.o.after 1567 0 0 1567 61f sys_x86_64.o.before md5: de28ffedcb5851dfd7ec87a03afec1fd sys_x86_64.o.after de28ffedcb5851dfd7ec87a03afec1fd sys_x86_64.o.before Signed-off-by: Gustavo F. Padovan Signed-off-by: Ingo Molnar commit 4df9e510a9fda29aca71d8acac853b98aa6884d1 Author: Gustavo F. Padovan Date: Tue Jul 29 02:48:55 2008 -0300 x86: coding style fixes to arch/x86/kernel/traps_64.c Fix all errors and many warnings reported by checkpath.pl. Except the change of include to the traps.o before and after changes are the same. Signed-off-by: Gustavo F. Padovan Signed-off-by: Ingo Molnar commit caa007dd3687d38a0252484d9d0a8f9d929ba932 Author: Gustavo F. Padovan Date: Tue Jul 29 02:48:54 2008 -0300 x86: coding style fixes to arch/x86/kernel/signal_64.c Fix all errors and many warnings reported by checkpatch.pl without change signal_64.o arch/x86/kernel/signal_64.o text data bss dec hex filename 5143 0 8 5151 141f signal_64.o.after 5143 0 8 5151 141f signal_64.o.before md5: e68718092b3641cb27e79e55ce57e3ad signal_64.o.after e68718092b3641cb27e79e55ce57e3ad signal_64.o.before Signed-off-by: Gustavo F. Padovan Signed-off-by: Ingo Molnar commit 08aadf069d0482ade033badefa8f03eb2fcddd9c Author: Gustavo F. Padovan Date: Tue Jul 29 02:48:53 2008 -0300 x86: coding style fixes to arch/x86/kernel/crash_dump_64.c Fix conding style without change crash_dump_64.o arch/x86/kernel/crash_dump_64.o text data bss dec hex filename 129 0 0 129 81 crash_dump_64.o.after 129 0 0 129 81 crash_dump_64.o.before md5: 885b52c1b92737e6b12e5107e90fc1f1 crash_dump_64.o.after 885b52c1b92737e6b12e5107e90fc1f1 crash_dump_64.o.before Signed-off-by: Gustavo F. Padovan Signed-off-by: Ingo Molnar commit 8092c654de9a964c14d89da56834f73a80548a58 Author: Gustavo F. Padovan Date: Tue Jul 29 02:48:52 2008 -0300 x86: add KERN_INFO to printks on process_64.c Fix many coding style warnings. Signed-off-by: Gustavo F. Padovan Signed-off-by: Ingo Molnar commit 7de08b4e1ed8d80e6086f71b7e99fc4b397aae39 Author: Gustavo F. Padovan Date: Tue Jul 29 02:48:51 2008 -0300 x86: coding styles fixes to arch/x86/kernel/process_64.c Fix about 50 errors and many warnings without change process_64.o arch/x86/kernel/process_64.o: text data bss dec hex filename 5236 8 24 5268 1494 process_64.o.after 5236 8 24 5268 1494 process_64.o.before md5: 9c35e9debdea4e471288c6e8ca267a75 process_64.o.after 9c35e9debdea4e471288c6e8ca267a75 process_64.o.before Signed-off-by: Gustavo F. Padovan Signed-off-by: Ingo Molnar commit 169ad16bb87c10a3f7c108bb7008ebc0270f617a Author: Eduardo Habkost Date: Mon Jul 28 18:32:09 2008 -0300 xen_alloc_ptpage: cast PFN_PHYS() argument to unsigned long Currently paravirt_ops alloc_p*() uses u32 for the pfn args. We should change that later, but while the pfn parameter is still u32, we need to cast the PFN_PHYS() argument at xen_alloc_ptpage() to unsigned long, otherwise it will lose bits on the shift. I think PFN_PHYS() should behave better when fed with smaller integers, but a cast to unsigned long won't be enough for all cases on 32-bit PAE, and a cast to u64 would be overkill for most users of PFN_PHYS(). We could have two different flavors of PFN_PHYS: one for low pages only (unsigned long) and another that works for any page (u64)), but while we don't have it, we will need the cast to unsigned long on xen_alloc_ptpage(). Signed-off-by: Eduardo Habkost Acked-by: Jeremy Fitzhardinge Signed-off-by: Ingo Molnar commit cef43bf6b3afd819f7cdcba356af0e8220fb3789 Author: Jeremy Fitzhardinge Date: Mon Jul 28 13:33:44 2008 -0700 xen: fix allocation and use of large ldts, cleanup Add a proper comment for set_aliased_prot() and fix an unsigned long/void * warning. Signed-off-by: Jeremy Fitzhardinge Signed-off-by: Ingo Molnar commit 1a23ed42e1baf0481cc70c2f71d97b0bf0f1be70 Author: Ingo Molnar Date: Thu Jul 31 12:52:29 2008 +0200 fastboot: fix typo in init/Kconfig text noticed by Randy Dunlap. Reported-by: Randy Dunlap Signed-off-by: Ingo Molnar commit fdf04ef6cae8215c511723c7e9c726d334f83863 Author: John Keller Date: Tue Jul 29 14:34:16 2008 -0500 x86: allow MMCONFIG above 4GB on x86_64 SGI UV will have MMCFG base addresses that are greater than 4GB (32 bits). v2: Use CONFIG_RESOURCES_64BIT instead of CONFIG_X86_64. v3: Create a flag, that is set by platform specific code, to disable the > 4GB check. Signed-off-by: John Keller Cc: jpk@sgi.com Signed-off-by: Ingo Molnar commit 0d1edf46ba229b46efacf75c0544b88c05a7b266 Author: Jeremy Fitzhardinge Date: Mon Jul 28 11:53:57 2008 -0700 xen: compile irq functions without -pg for ftrace For some reason I managed to miss a bunch of irq-related functions which also need to be compiled without -pg when using ftrace. This patch moves them into their own file, and starts a cleanup process I've been meaning to do anyway. Signed-off-by: Jeremy Fitzhardinge Cc: Sam Ravnborg Cc: "Alex Nixon (Intern)" Cc: Eduardo Habkost Signed-off-by: Ingo Molnar commit 771310c770214cd879d30d0825fb5e140cd74866 Author: Christian Borntraeger Date: Tue Jul 29 23:48:42 2008 +0200 KVM: s390: Fix kvm on IBM System z10 The z10 system supports large pages, kvm-s390 doesnt. Make sure that we dont advertise large pages to avoid the guest crashing as soon as the guest kernel activates DAT. Signed-off-by: Christian Borntraeger Signed-off-by: Avi Kivity commit 6e5e9d7ba8ab8aee39529c8b92e4ed2cf5e52d32 Author: Mark Fasheh Date: Tue Jul 29 18:29:18 2008 -0700 ocfs2: track local alloc state via debugfs A per-mount debugfs file, "local_alloc" is created which when read will expose live state of the nodes local alloc file. Performance impact is minimal, only a bit of memory overhead per mount point. Still, the code is hidden behind CONFIG_OCFS2_FS_STATS. This feature will help us debug local alloc performance problems on a live system. Signed-off-by: Mark Fasheh commit aac008326bc74c5a6075ec875bc0967f4fb12f47 Author: Mark Fasheh Date: Mon Jul 28 18:02:53 2008 -0700 ocfs2: throttle back local alloc when low on disk space Ocfs2's local allocator disables itself for the duration of a mount point when it has trouble allocating a large enough area from the primary bitmap. That can cause performance problems, especially for disks which were only temporarily full or fragmented. This patch allows for the allocator to shrink it's window first, before being disabled. Later, it can also be re-enabled so that any performance drop is minimized. To do this, we allow the value of osb->local_alloc_bits to be shrunk when needed. The default value is recorded in a mostly read-only variable so that we can re-initialize when required. Locking had to be updated so that we could protect changes to local_alloc_bits. Mostly this involves protecting various local alloc values with the osb spinlock. A new state is also added, OCFS2_LA_THROTTLED, which is used when the local allocator is has shrunk, but is not disabled. If the available space dips below 1 megabyte, the local alloc file is disabled. In either case, local alloc is re-enabled 30 seconds after the event, or when an appropriate amount of bits is seen in the primary bitmap. Signed-off-by: Mark Fasheh commit 74725c2af72440e964e6bf5c2e445f0b6480b6e9 Author: Mark Fasheh Date: Mon Jul 28 14:55:20 2008 -0700 ocfs2: Track local alloc bits internally Do this instead of tracking absolute local alloc size. This avoids needless re-calculatiion of bits from bytes in localalloc.c. Additionally, the value is now in a more natural unit for internal file system bitmap work. Signed-off-by: Mark Fasheh commit 6152e4b1c99a3689fc318d092cd144597f7dbd14 Author: H. Peter Anvin Date: Tue Jul 29 17:23:16 2008 -0700 x86, xsave: keep the XSAVE feature mask as an u64 The XSAVE feature mask is a 64-bit number; keep it that way, in order to avoid the mistake done with rdmsr/wrmsr. Use the xsetbv() function provided in the previous patch. Signed-off-by: H. Peter Anvin Signed-off-by: Ingo Molnar commit b4a091a62c8e91d6077e575600363cff73fa02ef Author: H. Peter Anvin Date: Tue Jul 29 17:30:29 2008 -0700 x86, xsave: add header file for XCR registers Add header file for the XCR registers and their access functions. Signed-off-by: H. Peter Anvin Signed-off-by: Ingo Molnar commit 42deec6f2c3688fdaf986225ac901b817cd91568 Author: Suresh Siddha Date: Tue Jul 29 10:29:26 2008 -0700 x86, xsave: update xsave header bits during ptrace fpregs set FP/SSE bits may be zero in the xsave header(representing the init state). Update these bits during the ptrace fpregs set operation, to indicate the non-init state. Signed-off-by: Suresh Siddha Signed-off-by: H. Peter Anvin Signed-off-by: Ingo Molnar commit c37b5efea43f9e500363f9973dd00e3d2cdcc685 Author: Suresh Siddha Date: Tue Jul 29 10:29:25 2008 -0700 x86, xsave: save/restore the extended state context in sigframe On cpu's supporting xsave/xrstor, fpstate pointer in the sigcontext, will include the extended state information along with fpstate information. Presence of extended state information is indicated by the presence of FP_XSTATE_MAGIC1 at fpstate.sw_reserved.magic1 and FP_XSTATE_MAGIC2 at fpstate + (fpstate.sw_reserved.extended_size - FP_XSTATE_MAGIC2_SIZE). Extended feature bit mask that is saved in the memory layout is represented by the fpstate.sw_reserved.xstate_bv For RT signal frames, UC_FP_XSTATE in the uc_flags also indicate the presence of extended state information in the sigcontext's fpstate pointer. Signed-off-by: Suresh Siddha Signed-off-by: H. Peter Anvin Signed-off-by: Ingo Molnar commit bdd8caba5ed5bb7ee21c9f061597284ffeb280bf Author: Suresh Siddha Date: Tue Jul 29 10:29:24 2008 -0700 x86, xsave: struct _fpstate extensions to include extended state information Bytes 464..511 in the current 512byte layout of fxsave/fxrstor frame, are reserved for SW usage. On cpu's supporting xsave/xrstor, these bytes are used to extended the fpstate pointer in the sigcontext, which now includes the extended state information along with fpstate information. Signed-off-by: Suresh Siddha Signed-off-by: H. Peter Anvin Signed-off-by: Ingo Molnar commit 9dc89c0f96a6ce6a1b7f9a47dd8bf6f17e2002c9 Author: Suresh Siddha Date: Tue Jul 29 10:29:23 2008 -0700 x86, xsave: xsave/xrstor specific routines Signed-off-by: Suresh Siddha Signed-off-by: H. Peter Anvin Signed-off-by: Ingo Molnar commit ab5137015fed9b948fe835a2d99a4cfbd50a0c40 Author: Suresh Siddha Date: Tue Jul 29 10:29:22 2008 -0700 x86, xsave: reorganization of signal save/restore fpstate code layout move 64bit routines that saves/restores fpstate in/from user stack from signal_64.c to xsave.c restore_i387_xstate() now handles the condition when user passes NULL fpstate. Other misc changes for prepartion of xsave/xrstor sigcontext support. Signed-off-by: Suresh Siddha Signed-off-by: H. Peter Anvin Signed-off-by: Ingo Molnar commit 3c1c7f101426cb2ecc79d817a8a65928965fc860 Author: Suresh Siddha Date: Tue Jul 29 10:29:21 2008 -0700 x86, xsave: dynamically allocate sigframes fpstate instead of static allocation dynamically allocate fpstate on the stack, instead of static allocation in the current sigframe layout on the user stack. This will allow the fpstate structure to grow in the future, which includes extended state information supporting xsave/xrstor. signal handlers will be able to access the fpstate pointer from the sigcontext structure asusual, with no change. For the non RT sigframe's (which are supported only for 32bit apps), current static fpstate layout in the sigframe will be unused(so that we don't change the extramask[] offset in the sigframe and thus prevent breaking app's which modify extramask[]). Signed-off-by: Suresh Siddha Signed-off-by: H. Peter Anvin Signed-off-by: Ingo Molnar commit b359e8a434cc3d09847010fc4aeccf48d69740e4 Author: Suresh Siddha Date: Tue Jul 29 10:29:20 2008 -0700 x86, xsave: context switch support using xsave/xrstor Uses xsave/xrstor (instead of traditional fxsave/fxrstor) in context switch when available. Introduces TS_XSAVE flag, which determine the need to use xsave/xrstor instructions during context switch instead of the legacy fxsave/fxrstor instructions. Thread-synchronous status word is already in L1 cache during this code patch and thus minimizes the performance penality compared to (cpu_has_xsave) checks. Signed-off-by: Suresh Siddha Signed-off-by: H. Peter Anvin Signed-off-by: Ingo Molnar commit dc1e35c6e95e8923cf1d3510438b63c600fee1e2 Author: Suresh Siddha Date: Tue Jul 29 10:29:19 2008 -0700 x86, xsave: enable xsave/xrstor on cpus with xsave support Enables xsave/xrstor by turning on cr4.osxsave on cpu's which have the xsave support. For now, features that OS supports/enabled are FP and SSE. Signed-off-by: Suresh Siddha Signed-off-by: H. Peter Anvin Signed-off-by: Ingo Molnar commit a648bf4632628c787abb0514277f2a231fca39ca Author: Suresh Siddha Date: Tue Jul 29 10:29:18 2008 -0700 x86, xsave: xsave cpuid feature bits Add xsave CPU feature bits. Signed-off-by: Suresh Siddha Signed-off-by: H. Peter Anvin Signed-off-by: Ingo Molnar commit a6a19661fc371c188b9cdeceba402b93de2b957f Author: Ben-Ami Yassour Date: Mon Jul 28 19:26:26 2008 +0300 KVM: pci device assignment Based on a patch from: Amit Shah This patch adds support for handling PCI devices that are assigned to the guest. The device to be assigned to the guest is registered in the host kernel and interrupt delivery is handled. If a device is already assigned, or the device driver for it is still loaded on the host, the device assignment is failed by conveying a -EBUSY reply to the userspace. Devices that share their interrupt line are not supported at the moment. By itself, this patch will not make devices work within the guest. The VT-d extension is required to enable the device to perform DMA. Another alternative is PVDMA. Signed-off-by: Amit Shah Signed-off-by: Ben-Ami Yassour Signed-off-by: Weidong Han Signed-off-by: Avi Kivity commit f0353dcd9e5b7d21616f73c71e456f746e9adc8d Author: Ben-Ami Yassour Date: Mon Jul 28 19:26:24 2008 +0300 KVM: direct mmio pfn check Userspace may specify memory slots that are backed by mmio pages rather than normal RAM. In some cases it is not enough to identify these mmio pages by pfn_valid(). This patch adds checking the PageReserved as well. Signed-off-by: Ben-Ami Yassour Signed-off-by: Muli Ben-Yehuda Signed-off-by: Avi Kivity commit 36d7b6f7fb24573a1b6cbd151b0e8afad5a6f9b2 Author: Takashi Iwai Date: Wed Jul 30 15:13:29 2008 +0200 ALSA: hda - set up HDMI channels Set up channel information for HDMI widgets. This will allow LPCM with multiple channels supported on some HDMI devices. TODO: It still doesn't check ELD and doesn't change PCM parameters dynamically. Signed-off-by: Takashi Iwai commit 09b57d71c065b641633b2b6ed3bc6b5095e859d8 Author: Takashi Iwai Date: Wed Jul 30 15:13:29 2008 +0200 ALSA: hda - print a few HDMI information in proc Signed-off-by: Takashi Iwai commit bbc0b95143d17b89ad7095ca14ac212a332da95f Author: Takashi Iwai Date: Wed Jul 30 15:13:28 2008 +0200 ALSA: hda - Add definitions of HDMI-related verbs Signed-off-by: Takashi Iwai commit 5a599a15182ed48e5bf54111feb3b21e425e194d Author: Aristeu Rozanski Date: Mon Jun 23 10:47:53 2008 -0400 Input: add keycodes for remote controls/phone keypads The new keys are separate from normal numeric keys and standard numeric keypads. The userspace should not attempt to apply modifiers like shift and NumLock to these so tey work properly regardless of the language mapping used. Signed-off-by: Dmitry Torokhov commit 03bac96fae0efdb25e2059e5accbe4f3ee6328dd Author: Dmitry Torokhov Date: Mon Jun 23 10:47:34 2008 -0400 Input: expand keycode space Expand the number of potential key codes from 512 to 768 since people are coming up with more and more keys. Signed-off-by: Dmitry Torokhov commit d6505ab9cd5672f99adeba86696499c2651a6e73 Author: Ville Syrjala Date: Thu Jul 3 10:45:37 2008 -0400 Input: ati_remote2 - add autosuspend support Signed-off-by: Ville Syrjala Signed-off-by: Dmitry Torokhov commit 1971b9d56fce9d8903e623b953c5e2fffe3a878e Author: Ville Syrjala Date: Thu Jul 3 10:45:37 2008 -0400 Input: ati_remote2 - add loadable keymap support Support for loadable keymaps. The driver now supports individual keymaps for each of the five modes (AUX1-AUX4 and PC) of the remote. To achieve this the keymap scancode is interpreted as a combination of the mode and actual button scancode. The original keycode patches were done by Peter Stokes but I modified it quite a lot. Signed-off-by: Ville Syrjala Signed-off-by: Dmitry Torokhov commit 8c4b3c29329eb7ffded3023e6d65bc415cb4e215 Author: Dmitry Torokhov Date: Fri Jun 6 01:33:51 2008 -0400 Input: gameport - mark gameport_register_driver() __must_check Signed-off-by: Dmitry Torokhov commit 2547203d583cc267b98f518d5d93e3a0469d8f62 Author: Dmitry Torokhov Date: Fri Jun 6 01:33:37 2008 -0400 Input: gameport - check return value of gameport_register_driver() Signed-off-by: Dmitry Torokhov commit 6902c0bead4ce266226fc0c5b3828b850bdc884a Author: Dmitry Torokhov Date: Fri Jun 6 01:33:22 2008 -0400 Input: gameport - make gameport_register_driver() return errors Perform actual driver registration right in gameport_register_driver() instead of offloading it to kgameportd and return proper error code to callers if driver registration fails. Note that driver <-> port matching is still done by kgameportd. Signed-off-by: Dmitry Torokhov commit ce5f8eaeffeadc42f5f159398bd0e19a789a5efb Author: Yoichi Yuasa Date: Tue Jul 29 05:30:58 2008 -0300 V4L/DVB (8564): fix vino driver build error The vino driver needs #include drivers/media/video/vino.c: In function 'vino_ioctl': drivers/media/video/vino.c:4364: error: implicit declaration of function 'video_usercopy' make[3]: *** [drivers/media/video/vino.o] Error 1 Signed-off-by: Yoichi Yuasa Signed-off-by: Mauro Carvalho Chehab commit b72d154444cc9da039b46f2131f146b435e68bed Author: Adrian Bunk Date: Mon Jul 28 16:58:19 2008 -0300 V4L/DVB (8563): fix drivers/media/video/arv.c compilation This patch fixes the following compile errors: <-- snip --> ... CC [M] drivers/media/video/arv.o /home/bunk/linux/kernel-2.6/git/linux-2.6/drivers/media/video/arv.c: In function 'ar_ioctl': /home/bunk/linux/kernel-2.6/git/linux-2.6/drivers/media/video/arv.c:544: error: implicit declaration of function 'video_usercopy' /home/bunk/linux/kernel-2.6/git/linux-2.6/drivers/media/video/arv.c: At top level: /home/bunk/linux/kernel-2.6/git/linux-2.6/drivers/media/video/arv.c:758: error: unknown field 'type' specified in initializer make[4]: *** [drivers/media/video/arv.o] Error 1 <-- snip --> Reported-by: Adrian Bunk Signed-off-by: Adrian Bunk Signed-off-by: Mauro Carvalho Chehab commit 91c09d60d3a92b2cba9308fb665e10a0447280f8 Author: Adrian Bunk Date: Mon Jul 28 16:58:05 2008 -0300 V4L/DVB (8562): DVB_DRX397XD: remove FW_LOADER select Also for the new DVB_DRX397XD driver the FW_LOADER select and the corresponding dependency on HOTPLUG can be removed. Signed-off-by: Adrian Bunk Signed-off-by: Mauro Carvalho Chehab commit da253f8dd1eb97360194bbae673a3251ee693c98 Author: Mauro Carvalho Chehab Date: Mon Jul 28 18:07:35 2008 -0300 V4L/DVB (8558): media/video/Kconfig: fix a typo Thanks to Hermann Gausterer for pointing this issue. Signed-off-by: Mauro Carvalho Chehab commit 57b56a86d79f15c5f666cf4a9541e7e61d79f040 Author: Jean-Francois Moine Date: Mon Jul 28 07:52:27 2008 -0300 V4L/DVB (8552): gspca: Bad pixel format in the spca508 subdriver. The pixel format should have been changed in changeset 6de914aaad86. Signed-off-by: Jean-Francois Moine Signed-off-by: Mauro Carvalho Chehab commit 727af57c9edd93f8b05f109dab59dec3ff253e84 Author: Jean-Francois Moine Date: Mon Jul 28 06:41:51 2008 -0300 V4L/DVB (8550): gspca: Change a bit the init of ov7660 and Sonix JPEG bridges. Set back some values of gspcav1 in init of sonixj sensor ov7660. Add some comments. Signed-off-by: Jean-Francois Moine Signed-off-by: Mauro Carvalho Chehab commit c9b1a9b0ec5cc30279fd51ea11f04432683961cc Author: Randy Dunlap Date: Mon Jul 28 15:39:38 2008 -0300 V4L/DVB (8549a): fix kernel-doc warning, function name, and docbook filename Change function name in kernel-doc and add kernel-doc for parameter @index: Warning(linhead//drivers/media/video/videodev.c:2090): No description found for parameter 'index' Also change source file name in DocBook/videobook.tmpl to match the new source file name. Signed-off-by: Randy Dunlap Signed-off-by: Mauro Carvalho Chehab commit 215b4576097e3cc290cc34c3ef4738e19d05a3f9 Author: Glauber Costa Date: Mon Jul 28 11:47:53 2008 -0300 x86: KVM guest: use paravirt function to calculate cpu khz We're currently facing timing problems in guests that do calibration under heavy load, and then the load vanishes. This means we'll have a much lower lpj than we actually should, and delays end up taking less time than they should, which is a nasty bug. Solution is to pass on the lpj value from host to guest, and have it preset. Signed-off-by: Glauber Costa Signed-off-by: Avi Kivity commit ba03518948d9af809a44fc1ab43e9e8c1638abaa Author: Glauber Costa Date: Mon Jul 28 11:47:52 2008 -0300 x86: paravirt: factor out cpu_khz to common code KVM intends to use paravirt code to calibrate khz. Xen current code will do just fine. So as a first step, factor out code to pvclock.c. Signed-off-by: Glauber Costa Signed-off-by: Avi Kivity commit 3dceed526eaab43af90bcec3476c4f534f98dd41 Author: Marcelo Tosatti Date: Sat Jul 26 17:01:01 2008 -0300 KVM: PIT: fix injection logic and count The PIT injection logic is problematic under the following cases: 1) If there is a higher priority vector to be delivered by the time kvm_pit_timer_intr_post is invoked ps->inject_pending won't be set. This opens the possibility for missing many PIT event injections (say if guest executes hlt at this point). 2) ps->inject_pending is racy with more than two vcpus. Since there's no locking around read/dec of pt->pending, two vcpu's can inject two interrupts for a single pt->pending count. Fix 1 by using an irq ack notifier: only reinject when the previous irq has been acked. Fix 2 with appropriate locking around manipulation of pending count and irq_ack by the injection / ack paths. Signed-off-by: Marcelo Tosatti Signed-off-by: Avi Kivity commit 4233cf141eeb8d6363e0fb78e2e2ea391c269200 Author: Marcelo Tosatti Date: Sat Jul 26 17:01:00 2008 -0300 KVM: irq ack notification Based on a patch from: Ben-Ami Yassour which was based on a patch from: Amit Shah Notify IRQ acking on PIC/APIC emulation. The previous patch missed two things: - Edge triggered interrupts on IOAPIC - PIC reset with IRR/ISR set should be equivalent to ack (LAPIC probably needs something similar). Signed-off-by: Marcelo Tosatti CC: Amit Shah CC: Ben-Ami Yassour Signed-off-by: Avi Kivity commit 0ee82cc61cc3e1e0c39cf6db431f73cfff2dcd72 Author: Avi Kivity Date: Sat Jul 26 17:00:59 2008 -0300 KVM: Add irq ack notifier list This can be used by kvm subsystems that are interested in when interrupts are acked, for example time drift compensation. Signed-off-by: Avi Kivity commit d9797818850593bcbf9f9c468bc0605d2a6022b0 Author: Ingo Molnar Date: Tue Jul 29 12:36:02 2008 +0200 ftrace: mark lapic_wd_event() notrace it can be called in the NMI path: [ 0.645999] calling ftrace_dynamic_init+0x0/0xd6 [ 0.647521] ------------[ cut here ]------------ [ 0.647521] WARNING: at kernel/trace/ftrace.c:348 ftrace_record_ip+0x4e/0x252() [ 0.647521] Modules linked in: [ 0.647521] Pid: 15, comm: kstop1 Not tainted 2.6.27-rc1-tip #22686 [ 0.647521] [ 0.647521] Call Trace: [ 0.647521] [] warn_on_slowpath+0x5d/0x84 [ 0.647521] [] ? lapic_wd_event+0xb/0x5c [ 0.647521] [] ftrace_record_ip+0x4e/0x252 [ 0.647521] [] mcount_call+0x5/0x31 [ 0.647521] [] ? lapic_wd_event+0x10/0x5c [ 0.647521] [] nmi_watchdog_tick+0x19d/0x1ad [ 0.647521] [] default_do_nmi+0x75/0x1e3 [ 0.647521] [] do_nmi+0x5d/0x94 [ 0.647521] [] nmi+0xa2/0xc2 [ 0.647521] [] ? check_bytes_and_report+0x11/0xcc [ 0.647521] <> [] ? mcount_call+0x5/0x31 [ 0.647521] [] check_object+0x61/0x1b0 [ 0.647521] [] __slab_free+0x169/0x2ae [ 0.647521] [] ? __cleanup_sighand+0x25/0x27 [ 0.647521] [] ? __cleanup_sighand+0x25/0x27 [ 0.647521] [] kmem_cache_free+0x85/0xb9 [ 0.647521] [] __cleanup_sighand+0x25/0x27 [ 0.647521] [] release_task+0x256/0x339 [ 0.647521] [] do_exit+0x764/0x7ef [ 0.647521] [] __xchg+0x0/0x38 [ 0.647521] [] ? stop_cpu+0x0/0xb2 [ 0.647521] [] ? stop_cpu+0x0/0xb2 [ 0.647521] [] kthread+0x4e/0x7b [ 0.647521] [] child_rip+0xa/0x11 [ 0.647521] [] ? restore_args+0x0/0x30 [ 0.647521] [] ? native_load_tls+0x14/0x2e [ 0.647521] [] ? kthread+0x0/0x7b [ 0.647521] [] ? child_rip+0x0/0x11 [ 0.647521] [ 0.647521] ---[ end trace 4eaa2a86a8e2da22 ]--- [ 0.672032] initcall ftrace_dynamic_init+0x0/0xd6 returned 0 after 19 msecs also mark it no-kprobes while at it. Signed-off-by: Ingo Molnar commit c2c27ba6b2e43c6f69b87fae0ba06e99982151f7 Author: Ingo Molnar Date: Tue Jul 29 12:00:59 2008 +0200 ftrace: ignore functions that cannot be kprobe-ed kprobes already has an extensive list of annotations for functions that should not be instrumented. Add notrace annotations to these functions as well. This is particularly useful for functions called by the NMI path. Signed-off-by: Ingo Molnar commit 431e94644bde07a327dea17ee9be297c3d44a876 Author: Steven Rostedt Date: Mon Jul 28 19:24:03 2008 -0400 ftrace: do not trace NMI contexts Dynamic ftrace can not trace the nmi code. The reason is that it is not safe to modify code text on an SMP system when the other CPUS are exectuting code. Unfortunately, there's no uniform API to disable NMIs on other CPUS - nor does one look easy (or even desirable). So warn about NMI entries. This warning can be used to mark functions notrace that can be called in an NMI context. Signed-off-by: Steven Rostedt Signed-off-by: Ingo Molnar commit 191a91ec1b6c92544e9e7a63e6d887e79ff267c1 Author: Avi Kivity Date: Tue Jul 29 11:30:57 2008 +0300 KVM: Advertise synchronized mmu support to userspace Signed-off-by: Avi Kivity commit 81df754ef3f9fc7f5d42f1979e1f37ef7231ffe0 Author: Andrea Arcangeli Date: Fri Jul 25 16:24:52 2008 +0200 KVM: Synchronize guest physical memory map to host virtual memory map Synchronize changes to host virtual addresses which are part of a KVM memory slot to the KVM shadow mmu. This allows pte operations like swapping, page migration, and madvise() to transparently work with KVM. Signed-off-by: Andrea Arcangeli Signed-off-by: Avi Kivity commit f71bd8b02e0ae1e29ac49bf5dd25189fb02d3902 Author: Andrea Arcangeli Date: Fri Jul 25 16:32:03 2008 +0200 KVM: Allow browsing memslots with mmu_lock This allows reading memslots with only the mmu_lock hold for mmu notifiers that runs in atomic context and with mmu_lock held. Signed-off-by: Andrea Arcangeli Signed-off-by: Avi Kivity commit bcbd8ae85a4b59ebedb734f6b3663dea4f8a84c8 Author: Andrea Arcangeli Date: Fri Jul 25 16:26:39 2008 +0200 KVM: Allow reading aliases with mmu_lock This allows the mmu notifier code to run unalias_gfn with only the mmu_lock held. Only alias writes need the mmu_lock held. Readers will either take the slots_lock in read mode or the mmu_lock. Signed-off-by: Andrea Arcangeli Signed-off-by: Avi Kivity commit 5d7b605245b1aa1a9cd6549b1f57d69273eb0c37 Author: Ingo Molnar Date: Tue Jul 29 10:07:36 2008 +0200 x86, microcode: fix module license string fix: FATAL: modpost: GPL-incompatible module microcode_amd.ko uses GPL-only symbol 'set_cpus_allowed_ptr' Signed-off-by: Ingo Molnar commit 224e946b81166d732f3e9b414cb69612072fb500 Author: Ingo Molnar Date: Tue Jul 29 09:52:55 2008 +0200 x86, microcode: fix symbol exports fix tons of build errors: arch/x86/kernel/built-in.o: In function `microcode_fini_cpu': microcode_intel.c:(.text+0x11598): undefined reference to `microcode_mutex' microcode_intel.c:(.text+0x115a4): undefined reference to `ucode_cpu_info' microcode_intel.c:(.text+0x115ae): undefined reference to `ucode_cpu_info' microcode_intel.c:(.text+0x115bc): undefined reference to `microcode_mutex' [...] Signed-off-by: Ingo Molnar commit 45b1e23eca1c53fa79a611a2bc8c93697ede6c97 Author: Ingo Molnar Date: Tue Jul 29 09:42:17 2008 +0200 x86, microcode support: fix build error fix: arch/x86/kernel/microcode.c:412: error: static declaration of ‘microcode_init’ follows non-static declaration include/asm/microcode.h:1: error: previous declaration of ‘microcode_init’ was here arch/x86/kernel/microcode.c:454: error: static declaration of ‘microcode_exit’ follows non-static declaration include/asm/microcode.h:2: error: previous declaration of ‘microcode_exit’ was here Signed-off-by: Ingo Molnar commit 07f3b22ee687d12ff20cb550125dec3640d31c2f Author: Kyle McMartin Date: Tue Jul 29 00:11:13 2008 -0400 parisc: hijack jump to start_kernel Bang in our own start_parisc call, which initializes the PDC width, and turns on the FPU. Previously, if CONFIG_PRINTK_TIME was on, we'd attempt to use the FPU before we had enabled it, resulting in a difficult to diagnose panic. This patch causes init_per_cpu to redundantly set these for cpu0, but this is harmless. commit 3a67067ec06d1ccc199ad340e3c8d038f4bd1ea3 Author: Kyle McMartin Date: Tue Jul 29 00:09:22 2008 -0400 parisc: add pdc_coproc_cfg_unlocked and set_firmware_width_unlocked These functions are called only when bringing up the monarch cpu, so it is safe to call them without taking the pdc spinlock. In the future, this may become relevant for lockdep, since these functions were taking spinlocks before start_kernel called the lockdep initializers. commit 1835f59279e7943bd246eec76ea981144426916f Author: Kyle McMartin Date: Mon Jul 28 23:02:13 2008 -0400 parisc: move include/asm-parisc to arch/parisc/include/asm commit 105928ed51c9963394d8c0f51309248a16de60d5 Author: Kyle McMartin Date: Mon Jul 28 22:52:18 2008 -0400 parisc: move pdc_result to real2.S commit b658f95509380640eb6cc31bfeb8a8cdbe137810 Author: Kyle McMartin Date: Mon Jul 28 21:17:23 2008 -0400 parisc: unify CCIO_COLLECT_STATS implementation Make it behave in the same manner as SBA_COLLECT_STATS, further clean ups pending. commit 18c94902f40ee97e00d54502ef67510cf5235c84 Author: Kyle McMartin Date: Mon Jul 28 21:14:50 2008 -0400 parisc: add arch/parisc/kernel/.gitignore commit 1aaa1d409e6bca3fbdb11f160f22417f266a66fd Author: Kyle McMartin Date: Mon Jul 28 16:22:34 2008 -0400 parisc: ropes.h - fix -> commit ae17a85f51e0009276dead06658e44cb4d578138 Author: Kyle McMartin Date: Mon Jul 28 16:21:19 2008 -0400 parisc: parisc-agp - fix -> commit 94a97a3018e55a27d1c29e011b3c38fee01a967f Author: Ananth N Mavinakayanahalli Date: Mon Jul 28 23:33:09 2008 +0530 Move backtrace selftests to tests/ Move backtrace selftests to tests/ Signed-off-by: Ananth N Mavinakayanahalli Signed-off-by: Sam Ravnborg commit 4fb97424637787ef193977cdd4ac95e9b18602e2 Author: Ananth N Mavinakayanahalli Date: Mon Jul 28 23:32:23 2008 +0530 Move kprobes smoke tests to tests/ Move kprobe smoke tests to tests/ Signed-off-by: Ananth N Mavinakayanahalli Signed-off-by: Sam Ravnborg commit 0f6add4bafdbff7a822e37dec0436e2392864d9a Author: Ananth N Mavinakayanahalli Date: Mon Jul 28 23:31:36 2008 +0530 Move lkdtm to tests/ Move the lkdtm infrastructure to tests/ Signed-off-by: Ananth N Mavinakayanahalli Acked-by: Ankita Garg Signed-off-by: Sam Ravnborg commit fd3d6bbd34fdcc799b20eae5233c0fca7e8c0957 Author: Ananth N Mavinakayanahalli Date: Mon Jul 28 23:31:02 2008 +0530 Move rtmutex tester to tests/ Move the rtmutex-tester infrastructure to tests/ Signed-off-by: Ananth N Mavinakayanahalli Signed-off-by: Sam Ravnborg commit 2b9b631dd2507b5480b752bcca946b9767b9bae1 Author: Ananth N Mavinakayanahalli Date: Mon Jul 28 23:29:57 2008 +0530 Move rcutorture to tests/ Move the rcutorture infrastructure to tests/ Signed-off-by: Ananth N Mavinakayanahalli Acked-by: Josh Triplett Acked-by: Paul E. McKenney Signed-off-by: Sam Ravnborg Date: Mon Jul 28 23:29:09 2008 +0530 Move locking selftests to tests/ Move the locking-selftest infrastructure to tests/ Signed-off-by: Ananth N Mavinakayanahalli Signed-off-by: Sam Ravnborg commit a4e7e33e50550d0f8b8f87487014527422a787af Author: Ananth N Mavinakayanahalli Date: Mon Jul 28 23:27:55 2008 +0530 Add tests/ directory Create a toplevel tests/ directory to house in-kernel subsystem specific tests. Thanks to Sam Ravnborg for the Makefile corrections. Signed-off-by: Ananth N Mavinakayanahalli Signed-off-by: Sam Ravnborg commit 80cc9f1020f49c9e5b50898c102fd444de70a0a3 Author: Peter Oruba Date: Mon Jul 28 18:44:22 2008 +0200 x86: AMD microcode patch loading support This patch introduces microcode patch loading for AMD processors. It is based on previous corresponding work for Intel processors. It hooks into the general patch loading module. Main difference is that a container file format is used to hold all patch data for multiple processors as well as an equivalent CPU table, which comes seperately, as opposed to Intel's microcode patching solution. Kconfig and Makefile have been changed provice config and build option for new source file. Signed-off-by: Peter Oruba Cc: Tigran Aivazian Signed-off-by: Ingo Molnar commit 8d86f390d9bb5b39f0a315838d1616de6363e1b9 Author: Peter Oruba Date: Mon Jul 28 18:44:21 2008 +0200 x86: major refactoring Refactored code by introducing a two-module solution. There is one general module in which vendor specific modules can hook into. However, that is exclusive, there is only one vendor specific module allowed at a time. A CPU vendor check makes sure only the correct module for the underlying system gets called. Functinally in terms of patch loading itself there are no changes. This refactoring provides a basis for future implementations of other vendors' patch loaders. Signed-off-by: Peter Oruba Cc: Tigran Aivazian Signed-off-by: Ingo Molnar commit 26bf7a48c33906cc3415a4492aa9ead7a75f1353 Author: Peter Oruba Date: Mon Jul 28 18:44:20 2008 +0200 x86: first step of refactoring, introducing microcode_ops Refactoring with the goal of having one general module and separate vendor specific modules that hook into the general one. Microcode_ops is a function pointer structure in which vendor specific modules will enter all functions that differ between vendors and that need to be accessed from the general module. Signed-off-by: Peter Oruba Cc: Tigran Aivazian Signed-off-by: Ingo Molnar commit 9835fd4ad9ee5fc6b909df72aa3e3dba04415f4b Author: Peter Oruba Date: Mon Jul 28 18:44:19 2008 +0200 x86: add AMD specific declarations Added AMD specific declarations to header file. Signed-off-by: Peter Oruba Cc: Tigran Aivazian Signed-off-by: Ingo Molnar commit d4ee36686853d5714437c4409f17ad42bfaf4211 Author: Peter Oruba Date: Mon Jul 28 18:44:18 2008 +0200 x86: structure declaration renaming Renamed common structures to vendor specific naming scheme so other vendors will be able to use the same naming convention. Signed-off-by: Peter Oruba Cc: Tigran Aivazian Signed-off-by: Ingo Molnar commit 3e135d887c973b525d43fbb67dfc5972694882f6 Author: Peter Oruba Date: Mon Jul 28 18:44:17 2008 +0200 x86: code split to two parts Split off existing code into two seperate files. One file holds general code, the other file vendor specific parts. No functional changes, only refactoring. Temporarily Introduced a new module name 'ucode' for result, due to already taken name 'microcode'. Signed-off-by: Peter Oruba Cc: Tigran Aivazian Signed-off-by: Ingo Molnar commit 1abae31096007cc993f67ae2576fe8f812270ad6 Author: Peter Oruba Date: Mon Jul 28 18:44:16 2008 +0200 x86: move microcode.c to microcode_intel.c Signed-off-by: Peter Oruba Cc: Tigran Aivazian Signed-off-by: Ingo Molnar commit c3b71bcec0380836caac9b524fa1585b469b7456 Author: Peter Oruba Date: Mon Jul 28 18:44:15 2008 +0200 x86: move per CPU microcode structure declaration to header file This structure will be later used by other modules as well and needs therfore to be moved out to a header file. Signed-off-by: Peter Oruba Cc: Tigran Aivazian Signed-off-by: Ingo Molnar commit 8e61028dfdc6b8ca996abfe8f9baef6792ea2904 Author: Peter Oruba Date: Mon Jul 28 18:44:14 2008 +0200 x86: typedef removal Removed typedefs. No functional changes to the code. Signed-off-by: Peter Oruba Cc: Tigran Aivazian Signed-off-by: Ingo Molnar commit 9a56a0f80b52cb41c5e0add47c7ce0bb2ef25eb0 Author: Peter Oruba Date: Mon Jul 28 18:44:13 2008 +0200 x86: moved Intel microcode patch loader declarations to seperate header file Intel specific microcode declarations have been moved to a seperate header file. There are no code changes to the code itself and no side effects to other parts. Signed-off-by: Peter Oruba Cc: Tigran Aivazian Signed-off-by: Ingo Molnar commit e7f5b309c9bd6142f395c4a36123ebac4bcdc1b0 Author: Peter Oruba Date: Mon Jul 28 18:44:11 2008 +0200 x86: AMD microcode patch loading support v2 Add an entry to the MAINTAINERS file for AMD CPU microcode patch loading support. Signed-off-by: Peter Oruba Cc: Tigran Aivazian Signed-off-by: Ingo Molnar commit 239bd83104ec6bcba90221d8b0973d2565142ef8 Author: Ingo Molnar Date: Mon Jul 28 16:45:49 2008 +0200 x86: L3 cache index disable for 2.6.26, fix #2 fix !PCI build failure: arch/x86/kernel/cpu/intel_cacheinfo.c: In function 'get_k8_northbridge': arch/x86/kernel/cpu/intel_cacheinfo.c:675: error: implicit declaration of function 'pci_match_id' Signed-off-by: Ingo Molnar commit d89961e2dc87b6e30b8e3f60bd2af5cd92cf4643 Author: Jeremy Fitzhardinge Date: Thu Jul 24 13:48:58 2008 -0700 xen: suppress known wrmsrs In general, Xen doesn't support wrmsr from an unprivileged domain; it just ends up ignoring the instruction and printing a message on the console. Given that there are sets of MSRs we know the kernel will try to write to, but we don't care, just eat them in xen_write_msr to cut down on console noise. Signed-off-by: Jeremy Fitzhardinge Signed-off-by: Ingo Molnar commit cdcf772ed163651cacac8098b4974aba7f9e1c73 Author: Ingo Molnar Date: Mon Jul 28 16:20:08 2008 +0200 x86 l3 cache index disable for 2 6 26 fix Signed-off-by: Ingo Molnar commit a24e8d36f5fc047dac9af6200322ed393f2e3175 Author: Mark Langsdorf Date: Tue Jul 22 13:06:02 2008 -0500 x86: L3 cache index disable for 2.6.26 On Monday 21 July 2008, Ingo Molnar wrote: > > applied to tip/x86/cpu, thanks Mark. > > > > I've done some coding style fixes for the new functions you've > > introduced, see that commit below. > > -tip testing found the following build failure: > > arch/x86/kernel/built-in.o: In function `show_cache_disable': > intel_cacheinfo.c:(.text+0xbbf2): undefined reference to `k8_northbridges' > arch/x86/kernel/built-in.o: In function `store_cache_disable': > intel_cacheinfo.c:(.text+0xbd91): undefined reference to `k8_northbridges' > > please send a delta fix patch against the tip/x86/cpu branch: > > http://people.redhat.com/mingo/tip.git/README > > which has your patch plus the cleanup applied. delta fix patch follows. It removes the dependency on k8_northbridges. -Mark Langsdorf Operating System Research Center AMD Signed-off-by: Mark Langsdorf Signed-off-by: Ingo Molnar commit 7a4983bb5f94f6521aa3236fe5c035cf9bef543f Author: Ingo Molnar Date: Mon Jul 21 13:34:21 2008 +0200 x86: L3 cache index disable for 2.6.26, cleanups No change in functionality. Signed-off-by: Ingo Molnar commit 8cb22bcb1f3ef70d4d48092e9b057175ad9ec78d Author: Mark Langsdorf Date: Fri Jul 18 16:03:52 2008 -0500 x86: L3 cache index disable for 2.6.26 New versions of AMD processors have support to disable parts of their L3 caches if too many MCEs are generated by the L3 cache. This patch provides a /sysfs interface under the cache hierarchy to display which caches indices are disabled (if any) and to monitoring applications to disable a cache index. This patch does not set an automatic policy to disable the L3 cache. Policy decisions would need to be made by a RAS handler. This patch merely makes it easier to see what indices are currently disabled. Signed-off-by: Mark Langsdorf Signed-off-by: Ingo Molnar commit fde28e8f49ed86e771667a3fe81fcc25c93ede8e Author: Jeremy Fitzhardinge Date: Thu Jul 24 16:28:00 2008 -0700 xen-balloon: clean up unused functions Remove some unused functions: balloon_update_driver_allowance balloon_release_driver_page only used on the (obsolete, removed) flip path in netfront alloc_empty_pages_and_pagevec free_empty_pages_and_pagevec only used in backend drivers; can be reintroduced when needed Signed-off-by: Jeremy Fitzhardinge Signed-off-by: Ingo Molnar commit 167e6cf62979df03513898966f9227847d192327 Author: Jeremy Fitzhardinge Date: Thu Jul 24 16:27:52 2008 -0700 xen-balloon: fix up sysfs issues 1. Set the class so it doesn't clash with the normal memory class 2. Fix up the sysfs show functions to match the new prototype 3. Clean up use of memparse Signed-off-by: Jeremy Fitzhardinge Cc: "viets@work.de" Cc: Andi Kleen Signed-off-by: Ingo Molnar commit d974ae379a2fbe8948f01eabbc6b19c0a80f09bc Author: Jeremy Fitzhardinge Date: Thu Jul 24 16:27:46 2008 -0700 generic, memparse(): constify argument memparse()'s first argument can be const, so it should be. Signed-off-by: Jeremy Fitzhardinge Cc: Andrew Morton Signed-off-by: Ingo Molnar commit 7225e75144b9718cbbe1820d9c011c809d5773fd Author: Randy Dunlap Date: Sat Jul 26 17:54:22 2008 -0700 documentation: move mtrr.txt to Doc/x86/ subdir Move mtrr.txt to the Documentation/x86/ subdirectory. Add 00-INDEX to the Documentation/x86/ subdirectory. Signed-off-by: Randy Dunlap Cc: Adrian Bunk Signed-off-by: Ingo Molnar commit a05d2ebab28011c2f3f520833f4bfdd2fd1b9c02 Author: Jeremy Fitzhardinge Date: Sun Jul 27 08:45:02 2008 -0700 xen: fix allocation and use of large ldts When the ldt gets to more than 1 page in size, the kernel uses vmalloc to allocate it. This means that: - when making the ldt RO, we must update the pages in both the vmalloc mapping and the linear mapping to make sure there are no RW aliases. - we need to use arbitrary_virt_to_machine to compute the machine addr for each update Signed-off-by: Jeremy Fitzhardinge Signed-off-by: Ingo Molnar commit 64f53a0492b4bc11868307990bb8f7c1e0764f89 Author: Jeremy Fitzhardinge Date: Sun Jul 27 08:42:32 2008 -0700 x86: fix initialization of 'l' bit in ldt descriptors Make sure that fill_ldt() initializes the 'l' bit in the descriptor. It always sets it to 0, ignoring 'lm' in user_desc, preserving original x86_64 behaviour. Previously it was leaving 'l' uninitialized. Signed-off-by: Jeremy Fitzhardinge Cc: Glauber de Oliveira Costa Signed-off-by: Ingo Molnar Cc: Glauber de Oliveira Costa commit 28a4f62d702312191a9bc94f041520576fafb60a Author: Mathieu Desnoyers Date: Thu Jul 24 16:37:23 2008 -0400 tracepoints: use TABLE_SIZE macro Steven Rostedt suggested: | Wouldn't it look nicer to have: (TRACEPOINT_TABLE_SIZE - 1) ? Signed-off-by: Mathieu Desnoyers Cc: Steven Rostedt Signed-off-by: Ingo Molnar commit af43dcee0572f0454294eb9032fb4a9fc9c89acb Author: Hollis Blanchard Date: Fri Jul 25 13:54:53 2008 -0500 KVM: powerpc: Map guest userspace with TID=0 mappings When we use TID=N userspace mappings, we must ensure that kernel mappings have been destroyed when entering userspace. Using TID=1/TID=0 for kernel/user mappings and running userspace with PID=0 means that userspace can't access the kernel mappings, but the kernel can directly access userspace. The net is that we don't need to flush the TLB on privilege switches, but we do on guest context switches (which are far more infrequent). Guest boot time performance improvement: about 30%. Signed-off-by: Hollis Blanchard Signed-off-by: Avi Kivity commit 7c0479229570cf0a9f286ce90a472f3ecaf55345 Author: Hollis Blanchard Date: Fri Jul 25 13:54:52 2008 -0500 KVM: ppc: Write only modified shadow entries into the TLB on exit Track which TLB entries need to be written, instead of overwriting everything below the high water mark. Typically only a single guest TLB entry will be modified in a single exit. Guest boot time performance improvement: about 15%. Signed-off-by: Hollis Blanchard Signed-off-by: Avi Kivity commit 75b15029174105f39c2811f34e22382cbcaf7afe Author: Hollis Blanchard Date: Fri Jul 25 13:54:51 2008 -0500 KVM: ppc: Stop saving host TLB state We're saving the host TLB state to memory on every exit, but never using it. Originally I had thought that we'd want to restore host TLB for heavyweight exits, but that could actually hurt when context switching to an unrelated host process (i.e. not qemu). Since this decreases the performance penalty of all exits, this patch improves guest boot time by about 15%. Signed-off-by: Hollis Blanchard Signed-off-by: Avi Kivity commit 5546d49404f7b34c05850394bd61c0fafaf91c4a Author: Hollis Blanchard Date: Fri Jul 25 13:54:50 2008 -0500 KVM: ppc: fix invalidation of large guest pages When guest invalidates a large tlb map, there may be more than one corresponding shadow tlb maps that need to be invalidated. Use eaddr and eend to find these shadow tlb maps. Signed-off-by: Liu Yu Signed-off-by: Hollis Blanchard Signed-off-by: Avi Kivity commit 37910b1d0212f27db1327dce2ffa260947557ab1 Author: Hollis Blanchard Date: Fri Jul 25 13:54:49 2008 -0500 KVM: ppc: guest breakpoint support Allow host userspace to program hardware debug registers to set breakpoints inside guests. Signed-off-by: Jerone Young Signed-off-by: Hollis Blanchard Signed-off-by: Avi Kivity commit 07b4e2a63b55696666c5c65c8d3fa493d1421529 Author: Christian Borntraeger Date: Fri Jul 25 15:53:12 2008 +0200 KVM: s390: Fix possible host kernel bug on lctl(g) handling The lctl(g) instructions require a specific alignment for the parameters. The architecture requires a specification program check if these alignments are not used. Enforcing this alignment also removes a possible host BUG, since the get_guest functions check for proper alignment and emits a BUG. Signed-off-by: Christian Borntraeger Signed-off-by: Avi Kivity commit 75cb6fb198991b1664b0a1050c3fbe4b2081c4ee Author: Christian Borntraeger Date: Fri Jul 25 15:52:44 2008 +0200 KVM: s390: Fix instruction naming for lctlg Lets fix the name for the lctlg instruction... Signed-off-by: Christian Borntraeger Signed-off-by: Avi Kivity commit 69ca586bb4db2b47952348cb3007bf85e829a1c7 Author: Christian Borntraeger Date: Fri Jul 25 15:51:54 2008 +0200 KVM: s390: Fix program check on interrupt delivery handling The current interrupt handling on s390 misbehaves on an error case. On s390 each cpu has the prefix area (lowcore) for interrupt delivery. This memory must always be available. If we fail to access the prefix area for a guest on interrupt delivery the configuration is completely unusable. There is no point in sending another program interrupt to an inaccessible lowcore. Furthermore, we should not bug the host kernel, because this can be triggered by userspace. I think the guest kernel itself can not trigger the problem, as SET PREFIX and SIGNAL PROCESSOR SET PREFIX both check that the memory is available and sane. As this is a userspace bug (e.g. setting the wrong guest offset, unmapping guest memory) we should kill the userspace process instead of BUGing the host kernel. In the long term we probably should notify the userspace process about this problem. Signed-off-by: Christian Borntraeger Signed-off-by: Avi Kivity commit a47089e6bd8d298d2b658114c683e804693d329b Author: Martin Schwidefsky Date: Fri Jul 25 15:51:00 2008 +0200 KVM: s390: Change guestaddr type in gaccess All registers are unsigned long types. This patch changes all occurences of guestaddr in gaccess from u64 to unsigned long. Signed-off-by: Martin Schwidefsky Signed-off-by: Christian Borntraeger Signed-off-by: Avi Kivity commit 4e1e8c68ca6aebe8ed4e9fd9d35eabf467ef5bae Author: Christian Borntraeger Date: Fri Jul 25 15:50:04 2008 +0200 KVM: s390: Fix guest kconfig Cornelia Huck noticed that a modular virtio without kvm guest support leads to a build error in the s390 virtio transport: CONFIG_VIRTIO=m leads to ERROR: "vmem_add_mapping" [drivers/s390/kvm/kvm_virtio.ko] undefined! ERROR: "max_pfn" [drivers/s390/kvm/kvm_virtio.ko] undefined! ERROR: "vmem_remove_mapping" [drivers/s390/kvm/kvm_virtio.ko] undefined! The virtio transport only works with kvm guest support and only as a builtin. Lets change the build process of drivers/s390/kvm/kvm_virtio.c to depend on kvm guest support, which is also a bool. CONFIG_S390_GUEST already selects CONFIG_VIRTIO, that should prevent CONFIG_S390_GUEST=y CONFIG_VIRTIO=n situations. CC: Cornelia Huck Signed-off-by: Christian Borntraeger Signed-off-by: Avi Kivity commit 52fb0c608db2653efafb0f05bfeb54e5b5f959c9 Author: Carsten Otte Date: Fri Jul 25 15:49:13 2008 +0200 KVM: s390: Advertise KVM_CAP_USER_MEMORY KVM_CAP_USER_MEMORY is used by s390, therefore, we should advertise it. Signed-off-by: Carsten Otte Signed-off-by: Christian Borntraeger Signed-off-by: Avi Kivity commit d25ae38b7e005af03843833bbd811ffe8c5f8cb4 Author: Yinghai Lu Date: Fri Jul 25 19:39:03 2008 -0700 x86: add apic probe for genapic 64bit - fix intr_remapping_enabled get assigned later, so need to check that in setup_apic_routing Signed-off-by: Yinghai Lu Cc: Jack Steiner Cc: Suresh Siddha Signed-off-by: Ingo Molnar commit 99bbc4b1e677ac695431e8d9c8e710ef391c567f Author: Roland McGrath Date: Sun Apr 20 14:35:12 2008 -0700 x86: tracehook: CONFIG_HAVE_ARCH_TRACEHOOK The x86 arch code has all the prerequisites, so set HAVE_ARCH_TRACEHOOK. Signed-off-by: Roland McGrath commit 59e52130f04537d2c80ea44bb007cadd1ad29543 Author: Roland McGrath Date: Sat Apr 19 19:10:57 2008 -0700 x86: tracehook: TIF_NOTIFY_RESUME This adds TIF_NOTIFY_RESUME support for x86, both 64-bit and 32-bit. When set, we call tracehook_notify_resume() on the way to user mode. Signed-off-by: Roland McGrath commit 4dfcbb997aa9f3a6a3ed8c192f0dac28b027e08f Author: Roland McGrath Date: Sat Apr 19 15:37:09 2008 -0700 x86 signals: use asm/syscall.h Replace local inlines with the asm/syscall.h interfaces that do the same things. Signed-off-by: Roland McGrath commit 68bd0f4ef7750fc277e1268bf40f443898382409 Author: Roland McGrath Date: Fri Apr 18 17:08:44 2008 -0700 x86: tracehook: asm/syscall.h Add asm/syscall.h for x86 with all the required entry points. This will allow arch-independent tracing code for system calls. Signed-off-by: Roland McGrath commit eeea3c3ff8af7f6960a0515d46dff6479bdb91f9 Author: Roland McGrath Date: Sun Mar 16 23:36:28 2008 -0700 x86: tracehook syscall This changes x86 syscall tracing to use the new tracehook.h entry points. There is no change, only cleanup. Signed-off-by: Roland McGrath commit 36a033082b5243d45d508c5ccd47a754edbc6821 Author: Roland McGrath Date: Fri Mar 14 17:46:38 2008 -0700 x86: tracehook_signal_handler This makes the x86 signal handling code use tracehook_signal_handler() in place of calling into ptrace guts. The call is moved after the sa_mask processing, but there is no other change. This cleanup doesn't matter to existing debuggers, but is the sensible thing: have all facets of the handler setup complete before the debugger inspects the task again. Signed-off-by: Roland McGrath commit 3964cd3a6721f18ef1dd67b9a0a89dc5b36683b9 Author: Ingo Molnar Date: Sat Jul 26 19:35:20 2008 +0200 x86: visws_quirks, fix build error fix: arch/x86/kernel/visws_quirks.c: In function ‘visws_early_detect’: arch/x86/kernel/visws_quirks.c:290: error: ‘skip_ioapic_setup’ undeclared (first use in this function) arch/x86/kernel/visws_quirks.c:290: error: (Each undeclared identifier is reported only once arch/x86/kernel/visws_quirks.c:290: error: for each function it appears in.) Signed-off-by: Ingo Molnar commit 2046ed5c14542652227896b16e67863aa171805f Author: Pekka Paalanen Date: Mon Jul 21 18:49:56 2008 +0300 x86: fix mmiotrace 8-bit register decoding When SIL, DIL, BPL or SPL registers were used in MMIO, the datum was extracted from AH, BH, CH, or DH, which are incorrect. Signed-off-by: Pekka Paalanen Cc: "Vegard Nossum" Cc: "Steven Rostedt" Cc: proski@gnu.org Cc: "Pekka Enberg" Signed-off-by: Ingo Molnar commit b56afe1d41653fb07ab1b5af5ccc12001c4dd5a0 Author: Eduardo Habkost Date: Thu Jul 24 12:15:45 2008 -0300 x86, xen: Use native_pte_flags instead of native_pte_val for .pte_flags Using native_pte_val triggers the BUG_ON() in the paravirt_ops version of pte_flags(). Signed-off-by: Eduardo Habkost Acked-by: Jeremy Fitzhardinge Signed-off-by: Ingo Molnar commit 12f50da2e1ad0cda2fb5754298bd03b3b02eb78b Author: Randy Dunlap Date: Thu Jul 24 16:09:32 2008 -0700 kmemcheck: include module.h to prevent warnings kmemcheck/shadow.c needs to include to prevent the following warnings: linux-next-20080724/arch/x86/mm/kmemcheck/shadow.c:64: warning : data definition has no type or storage class linux-next-20080724/arch/x86/mm/kmemcheck/shadow.c:64: warning : type defaults to 'int' in declaration of 'EXPORT_SYMBOL_GPL' linux-next-20080724/arch/x86/mm/kmemcheck/shadow.c:64: warning : parameter names (without types) in function declaration Signed-off-by: Randy Dunlap Cc: vegardno@ifi.uio.no Cc: penberg@cs.helsinki.fi Cc: akpm Signed-off-by: Ingo Molnar commit 9749986a878e91182ff027ff0010ab8e3211031a Author: Ingo Molnar Date: Sat Jul 26 17:28:11 2008 +0200 x86: usb debug port early console, fix fix: arch/x86/kernel/built-in.o: In function `nvidia_set_debug_port': early_printk.c:(.text+0xf8b1): undefined reference to `read_pci_config' early_printk.c:(.text+0xf8dc): undefined reference to `write_pci_config' arch/x86/kernel/built-in.o: In function `setup_early_printk': early_printk.c:(.init.text+0x5487): undefined reference to `early_pci_allowed' early_printk.c:(.init.text+0x54cb): undefined reference to `read_pci_config' early_printk.c:(.init.text+0x54ec): undefined reference to `read_pci_config_16' [...] Signed-off-by: Ingo Molnar commit 39eacc20f93614f7bab63eb1d45060503afc46d0 Author: Huang Weiyi Date: Fri Jul 25 23:30:13 2008 +0800 arch/x86/kernel/visws_quirks.c: Removed duplicated #include Removed duplicated #include in arch/x86/kernel/visws_quirks.c. asm/apic.h asm/arch_hooks.h asm/io.h asm/visws/cobalt.h asm/visws/lithium.h asm/visws/piix4.h linux/init.h linux/interrupt.h linux/smp.h Signed-off-by: Huang Weiyi Signed-off-by: Ingo Molnar commit edb181ac4b0c7c1240503da46349a3fb69af9ef6 Author: Yinghai Lu Date: Fri Jul 25 02:17:55 2008 -0700 x86: mach-numaq to numaq Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit e8c48efdb971cfb1b043076cf68be535d461a20b Author: Yinghai Lu Date: Fri Jul 25 02:17:44 2008 -0700 x86: mach_summit to summit Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit c7e7964c9828083aeb41c2664cbf5a32acbfa9d1 Author: Yinghai Lu Date: Fri Jul 25 02:17:33 2008 -0700 x86: mach_es7000 to es7000 Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit 1176fa919292887aa738d317d61fe2bba4d764f2 Author: Yinghai Lu Date: Fri Jul 25 02:17:21 2008 -0700 x86: mach-bigsmp to bigsmp Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit a4dbc34d181e87a0d724dee365921e9251f831d4 Author: Yinghai Lu Date: Fri Jul 25 02:14:28 2008 -0700 x86: add setup_ioapic_ids for numaq in x86_quirks Signed-off-by: Yinghai Lu Signed-off-by: Ingo Molnar commit 5c05917e7fe313a187ad6ebb94c1c6cf42862a0b Author: Yinghai Lu Date: Thu Jul 24 17:29:40 2008 -0700 x86: usb debug port early console, v4 based on work from Eric, and add some timeout so don't dead loop when debug device is not installed v2: fix checkpatch warning v3: move ehci struct def to linux/usrb/ehci_def.h from host/ehci.h also add CONFIG_EARLY_PRINTK_DBGP to disable it by default v4: address comments from Ingo, seperate ehci reg def moving to another patch also add auto detect port that connect to debug device for Nvidia southbridge Signed-off-by: Yinghai Lu Cc: Andrew Morton Cc: Andi Kleen Cc: "Arjan van de Ven" Cc: "Eric W. Biederman" Cc: "Greg KH" Signed-off-by: Ingo Molnar commit 0af36739af81f152cc24a0fdfa0754ef657afe3d Author: Yinghai Lu Date: Thu Jul 24 17:27:57 2008 -0700 usb: move ehci reg def prepare x86: usb debug port early console move ehci struct def to linux/usrb/ehci_def.h from host/ehci.h Signed-off-by: Yinghai Lu Acked-by: David Brownell Cc: Andrew Morton Cc: Andi Kleen Cc: "Arjan van de Ven" Cc: "Eric W. Biederman" Cc: "Greg KH" Signed-off-by: Ingo Molnar commit 17f3ab748e3ee8a0af069e53b93e1487cf44aecc Author: Joerg Roedel Date: Fri Jul 25 16:48:59 2008 +0200 x86: convert discontig_32.c from round_up to roundup Signed-off-by: Joerg Roedel Signed-off-by: Ingo Molnar commit be3e89ee6df8607356f705901dd90bcf3836c86e Author: Joerg Roedel Date: Fri Jul 25 16:48:58 2008 +0200 x86: convert numa_64.c from round_up to roundup Signed-off-by: Joerg Roedel Signed-off-by: Ingo Molnar commit d86bb0dac792c6a9c92944b6db2687980c808094 Author: Joerg Roedel Date: Fri Jul 25 16:48:57 2008 +0200 x86: convert init_64.c from round_up to roundup Signed-off-by: Joerg Roedel Signed-off-by: Ingo Molnar commit 15ae2d76ceb037a1e3fcd8fc9b4fe3177f9f3831 Author: Joerg Roedel Date: Fri Jul 25 16:48:56 2008 +0200 x86: convert pageattr.c from round_up to roundup Signed-off-by: Joerg Roedel Signed-off-by: Ingo Molnar commit 1ddb5518052e4e28ab489237443f7443b3fd69ca Author: Joerg Roedel Date: Fri Jul 25 16:48:55 2008 +0200 x86: convert pci-dma.c from round_up to roundup Signed-off-by: Joerg Roedel Signed-off-by: Ingo Molnar commit 7e7b43892b87b6be259479ef4de14029dcb4012f Author: Robert Richter Date: Thu Jul 24 16:00:16 2008 +0200 x86/oprofile: fix on_each_cpu build error Signed-off-by: Robert Richter Cc: oprofile-list Cc: Jason Yeh Signed-off-by: Ingo Molnar commit 1a960b402a51d80abf54e3f8e4972374ffe5f22d Author: Jason Yeh Date: Wed Jul 23 23:05:53 2008 +0200 Oprofile Multiplexing Patch This patch introduces multiplexing support for the Oprofile kernel module. It basically adds a new function pointer in oprofile_operator allowing each architecture to supply its callback to switch between different sets of event when the timer expires. Userspace tools can modify the time slice through /dev/oprofile/time_slice. It also modifies the number of counters exposed to the userspace through /dev/oprofile. For example, the number of counters for AMD CPUs are changed to 32 and multiplexed in the sets of 4. Signed-off-by: Jason Yeh Signed-off-by: Robert Richter Cc: oprofile-list Signed-off-by: Ingo Molnar commit 6852fd9b86d05063c6ef49d2e12e061cc7f6a105 Author: Robert Richter Date: Tue Jul 22 21:09:08 2008 +0200 x86/oprofile: reanaming op_model_athlon.c to op_model_amd.c Signed-off-by: Robert Richter Cc: oprofile-list Cc: Barry Kasindorf Signed-off-by: Ingo Molnar commit bd17b625c09d1ed14c4d98604186b0bbb314f6b2 Author: Robert Richter Date: Tue Jul 22 21:09:07 2008 +0200 oprofile: fix printk in cpu_buffer.c Signed-off-by: Robert Richter Cc: oprofile-list Cc: Robert Richter Cc: Barry Kasindorf Signed-off-by: Ingo Molnar commit 852402cc27bfa1200164e9e8dc7f6e5f0a4fbd46 Author: Robert Richter Date: Tue Jul 22 21:09:06 2008 +0200 x86/oprofile: add CONFIG_OPROFILE_IBS option Signed-off-by: Robert Richter Cc: oprofile-list Cc: Robert Richter Cc: Barry Kasindorf Signed-off-by: Ingo Molnar commit 6aa360e6c16c145edf1837690e0f7aaea6b86ef3 Author: Robert Richter Date: Wed Jul 23 15:28:14 2008 +0200 x86: apic: changing export symbols to *_GPL This fits better here. Signed-off-by: Robert Richter Cc: Arjan van de Ven Cc: Barry Kasindorf Cc: oprofile-list Signed-off-by: Ingo Molnar commit 09691616850b3614dfb44790e1e1419b6a7f5d13 Author: Robert Richter Date: Tue Jul 22 21:09:05 2008 +0200 x86: apic: export symbols for extended interrupt LVT functions This patch adds EXPORT_SYMBOLs to allow OProfile to be built as module. Cc: Arjan van de Ven Signed-off-by: Robert Richter Cc: oprofile-list Cc: Arjan van de Ven Cc: Barry Kasindorf Signed-off-by: Ingo Molnar commit 543a157bbdfae8eb997506031c3b2d4d17957098 Author: Robert Richter Date: Tue Jul 22 21:09:04 2008 +0200 x86/oprofile: op_model_athlon.c: fix counter reset when reenabling IBS OP Signed-off-by: Robert Richter Cc: oprofile-list Cc: Barry Kasindorf Signed-off-by: Ingo Molnar commit 87f0baccc2e4f194c931186d3c8499314494a484 Author: Robert Richter Date: Tue Jul 22 21:09:03 2008 +0200 x86/oprofile: macro definition cleanup in op_model_athlon.c Signed-off-by: Robert Richter Cc: oprofile-list Cc: Barry Kasindorf Signed-off-by: Ingo Molnar commit a4c408a41167949f820e2740e56a8f2f7bb6177c Author: Robert Richter Date: Tue Jul 22 21:09:02 2008 +0200 OProfile: fix IBS build error for UP Signed-off-by: Robert Richter Cc: oprofile-list Cc: Barry Kasindorf Signed-off-by: Ingo Molnar commit 270d3e1a10e6ef85d5a085377e01d91dbcbe3726 Author: Robert Richter Date: Tue Jul 22 21:09:01 2008 +0200 OProfile: enable IBS for AMD CPUs Signed-off-by: Robert Richter Cc: oprofile-list Cc: Barry Kasindorf Signed-off-by: Ingo Molnar commit fc2bd7345b4e006a34c2ea3711d8c6b83cba50f7 Author: Robert Richter Date: Tue Jul 22 21:09:00 2008 +0200 OProfile: fix setup_ibs_files() function interface Signed-off-by: Robert Richter Cc: oprofile-list Cc: Barry Kasindorf Signed-off-by: Ingo Molnar commit ebb535de267386f659e0348185b1e361dbba3b59 Author: Robert Richter Date: Tue Jul 22 21:08:59 2008 +0200 OProfile: on_each_cpu(): kill unused retry parameter Signed-off-by: Robert Richter Cc: oprofile-list Cc: Barry Kasindorf Signed-off-by: Ingo Molnar commit 90645700ef8393cd9cdc02d83da36726fc88f49e Author: Robert Richter Date: Tue Jul 22 21:08:58 2008 +0200 OProfile: Fix build error in op_model_athlon.c Signed-off-by: Robert Richter Cc: oprofile-list Cc: Barry Kasindorf Signed-off-by: Ingo Molnar commit 7d77f2dcae37cf232950cd0181fb0a2cddb18130 Author: Robert Richter Date: Tue Jul 22 21:08:57 2008 +0200 OProfile: change IBS interrupt initialization Signed-off-by: Robert Richter Cc: oprofile-list Cc: Barry Kasindorf Signed-off-by: Ingo Molnar commit 7939d2bf7e30353d40d14f967b7fe2b2a7be5bd9 Author: Robert Richter Date: Tue Jul 22 21:08:56 2008 +0200 x86/oprofile: separating the IBS handler Signed-off-by: Robert Richter Cc: oprofile-list Cc: Barry Kasindorf Signed-off-by: Ingo Molnar commit 56784f11df473b4c1d9d0e37777fd7c0b77b6bca Author: Barry Kasindorf Date: Tue Jul 22 21:08:55 2008 +0200 x86/oprofile: add IBS support for AMD CPUs, model specific code This patchset supports the new profiling hardware available in the latest AMD CPUs in the oProfile driver. Signed-off-by: Barry Kasindorf Signed-off-by: Robert Richter Cc: oprofile-list Signed-off-by: Ingo Molnar commit 345c25730d085c45622ac779da4dbd97dc3a10fe Author: Barry Kasindorf Date: Tue Jul 22 21:08:54 2008 +0200 x86/oprofile: add IBS support for AMD CPUs, IBS buffer handling routines This patchset supports the new profiling hardware available in the latest AMD CPUs in the oProfile driver. Signed-off-by: Barry Kasindorf Signed-off-by: Robert Richter Cc: oprofile-list Signed-off-by: Ingo Molnar commit ee648bc77f11b57d15a68d336fc30e343198f893 Author: Robert Richter Date: Tue Jul 22 21:08:53 2008 +0200 OProfile: add IBS code macros Signed-off-by: Robert Richter Cc: oprofile-list Cc: Barry Kasindorf Signed-off-by: Ingo Molnar commit 5e11f98dcebc40c9d67e8d21a5f47248444c17a8 Author: Robert Richter Date: Tue Jul 22 21:08:52 2008 +0200 OProfile: moving increment_tail() in buffer_sync.c Signed-off-by: Robert Richter Cc: oprofile-list Cc: Barry Kasindorf Signed-off-by: Ingo Molnar commit 73185e0a5d11d729d451692034fbe55a9eba7468 Author: Robert Richter Date: Tue Jul 22 21:08:51 2008 +0200 drivers/oprofile: coding style fixes in buffer_sync.c Signed-off-by: Robert Richter Cc: oprofile-list Cc: Barry Kasindorf Signed-off-by: Ingo Molnar commit 6657fe4f5650ff7174d418d4bfa50c4640e81a2b Author: Robert Richter Date: Tue Jul 22 21:08:50 2008 +0200 x86/oprofile: renaming athlon_*() into op_amd_*() These functions contain code for all AMD CPUs. The new names fit better. Signed-off-by: Robert Richter Cc: oprofile-list Cc: Barry Kasindorf Signed-off-by: Ingo Molnar commit dfa154289701ed315909b4e371a0381c52c8bdc9 Author: Robert Richter Date: Tue Jul 22 21:08:49 2008 +0200 x86/oprofile: Minor changes in op_model_athlon.c Signed-off-by: Robert Richter Cc: oprofile-list Cc: Barry Kasindorf Signed-off-by: Ingo Molnar commit adf5ec0bca553b763a6b9baed2677a4c7470025b Author: Robert Richter Date: Tue Jul 22 21:08:48 2008 +0200 x86/oprofile: introduce model specific init/exit functions This patch implements model specific OProfile init/exit functions for x86 CPUs. Though there is more rework needed at the initialization code, this new introduced functions allow it to keep model specific code in the corresponding op_model_*.c files. The function interface is the same as for oprofile_arch_init/exit(). Signed-off-by: Robert Richter Cc: oprofile-list Signed-off-by: Ingo Molnar commit 12f2b2610e812627acf338aaf043fef20bb726ca Author: Barry Kasindorf Date: Tue Jul 22 21:08:47 2008 +0200 oprofile: Add support for AMD Family 11h This patch add support for AMD Family 11h CPUs. Signed-off-by: Barry Kasindorf Signed-off-by: Robert Richter Cc: oprofile-list Signed-off-by: Ingo Molnar commit 286f571837ba9d67625afd015366d79345abb414 Author: Robert Richter Date: Tue Jul 22 21:08:46 2008 +0200 x86: apic_*.c: add description to AMD's extended LVT functions Signed-off-by: Robert Richter Cc: oprofile-list Cc: Barry Kasindorf Signed-off-by: Ingo Molnar commit 021f8b75e78f9da67421a2c2e320e8934a90914a Author: Robert Richter Date: Tue Jul 22 21:08:45 2008 +0200 x86: add PCI IDs for AMD Barcelona PCI devices Signed-off-by: Robert Richter Cc: oprofile-list Cc: Barry Kasindorf Signed-off-by: Ingo Molnar commit 7e9544a1bdbd7fa1b534aaedae76bd5839d27e22 Author: Julia Lawall Date: Tue Jul 22 21:38:18 2008 +0200 KVM: ia64: Fix irq disabling leak in error handling code There is a call to local_irq_restore in the normal exit case, so it would seem that there should be one on an error return as well. The semantic patch that finds this problem is as follows: (http://www.emn.fr/x-info/coccinelle/) // @@ expression l; expression E,E1,E2; @@ local_irq_save(l); ... when != local_irq_restore(l) when != spin_unlock_irqrestore(E,l) when any when strict ( if (...) { ... when != local_irq_restore(l) when != spin_unlock_irqrestore(E1,l) + local_irq_restore(l); return ...; } | if (...) + {local_irq_restore(l); return ...; + } | spin_unlock_irqrestore(E2,l); | local_irq_restore(l); ) // Signed-off-by: Julia Lawall Signed-off-by: Avi Kivity commit da8d2e97417b86d0b082db73227434fc9ab88248 Author: Jay Fenlason Date: Sun Jul 20 14:20:53 2008 +0200 firewire: fw_send_request_sync() Share code between fw_send_request + wait_for_completion callers. Signed-off-by: Jay Fenlason Addendum: Removes an unnecessary struct and an ununsed retry loop. Calls it fw_run_transaction() instead of fw_send_request_sync(). Signed-off-by: Stefan Richter Acked-by: Kristian Høgsberg commit b2139aa0eec330c711c5a279db361e5ef1178e78 Author: Jaswinder Singh Date: Fri Jul 25 11:32:38 2008 +0530 X86_SMP: tlb_XX.c declare smp_invalidate_interrupt before they get used declare smp_invalidate_interrupt in asm-x86/hw_irq.h for X86_32 and X86_64 Signed-off-by: Jaswinder Singh commit 2907829cd0ffdef69083985ba28cf1cf3857c681 Author: Jaswinder Singh Date: Fri Jul 25 11:05:56 2008 +0530 X86_SMP: ipi.c declare functions before they get used move upwards for __send_IPI_shortcut and send_IPI_mask_bitmask Signed-off-by: Jaswinder Singh commit f86c99853b22576ee8dc4fa27ff6f3c0c7ce0ef8 Author: Jaswinder Singh Date: Fri Jul 25 10:52:53 2008 +0530 X86_SMP: smpboot.c declare idle_thread_array and smp_b_stepping as static Signed-off-by: Jaswinder Singh commit e7f08dfdaa82def3d685d16fdb99203cbb67ec95 Author: Jaswinder Singh Date: Fri Jul 25 10:42:26 2008 +0530 X86_SMP: smp.c declare functions before they get used declared following smp interrupts in asm-x86/hw_irq.h: smp_reschedule_interrupt, smp_call_function_interrupt, smp_call_function_single_interrupt Signed-off-by: Jaswinder Singh commit 4fe702c7e401f912c0edd294af6e37c02f451bbb Author: Jaswinder Singh Date: Fri Jul 25 10:19:27 2008 +0530 X86_32: declare pt_regs_access as unsigned long Fixed pt_regs_access to unsigned long as per X86_64 Signed-off-by: Jaswinder Singh commit 461d159694d683c9e43ead07720a3a0f17f6f060 Author: Jaswinder Singh Date: Fri Jul 25 09:19:05 2008 +0530 x86_64: Declare new_utsname in asm-x86/syscalls.h Signed-off-by: Jaswinder Singh commit 9ac2f04936e1140d7a28a01b84e086458e191b49 Author: Matthew Wilcox Date: Fri Apr 25 12:38:41 2008 -0400 Convert board-nokia770 from semaphore to spinlock None of the operations done under the semaphore could sleep, so a spinlock is more appropriate to this case. Signed-off-by: Matthew Wilcox commit 744b27ce0dadfdb015f0cb12c54ee0b754ff4a60 Author: Matthew Wilcox Date: Fri Apr 25 12:09:25 2008 -0400 Convert ibmphp from semaphores One semaphore had mutex semantics, the other had completion semantics. Signed-off-by: Matthew Wilcox commit d8b90e4f869007792fa46d5b1b67122d0264149f Author: Matthew Wilcox Date: Fri Apr 25 11:58:30 2008 -0400 Convert ppp_async from semaphore to a completion This semaphore was being used with completion semantics. Signed-off-by: Matthew Wilcox commit 34218bbc23c1127505301483fbc008d31dc048f6 Author: Matthew Wilcox Date: Thu Jul 24 09:48:36 2008 -0400 Add mutex includes to ps3_gelic drivers The conversions from semaphore to mutex didn't add mutex includes. Signed-off-by: Matthew Wilcox commit 84268f8591ae1e3862d28612ead5f3575055fc4d Author: Matthew Wilcox Date: Sat May 31 09:39:45 2008 -0400 Convert bonding driver from rw_semaphore to mutex The semaphore was only taken for read for displaying the bonds in sysfs. The additional debuggability of mutexes far outweighs this minor loss of concurrency. Signed-off-by: Matthew Wilcox commit 2a0e26c90de6245213ac53390b1f125c749ebba9 Author: Matthew Wilcox Date: Sat May 31 09:10:29 2008 -0400 9p: Convert from mutex to spinlock The virtio_9p_lock is only held for very short periods of time and never does a blocking operation while it's held, so it really should be a spinlock. Signed-off-by: Matthew Wilcox commit 4735ad05143f7a4f3944522f1505ef3be77a2ce6 Author: Matthew Wilcox Date: Thu Jul 24 09:35:25 2008 -0400 qla2xxx: Remove semaphore.h Now that qla2xxx has been converted to mutexes, it no longer needs the semaphore include. Signed-off-by: Matthew Wilcox commit c42e074d276a3ac63827e3a05b7123e8bb112bd2 Author: Matthew Wilcox Date: Fri Apr 25 05:28:17 2008 -0400 Convert s3c2443-ac97 from semaphore to mutex The ac97_mutex semaphore is being used with mutex semantics, so change it to actually be a mutex. Signed-off-by: Matthew Wilcox commit 0ede10ed0bff4bdb866473cec524b5f7f1f9579d Author: Matthew Wilcox Date: Fri Apr 25 05:45:32 2008 -0400 Convert bluetooth's hci_core to mutexes The hci_req_lock is used with mutex semantics, so convert it to a mutex. Signed-off-by: Matthew Wilcox commit d4c63ec060f3315653c0ae5bc3a7fe2419a2282f Author: Cyrill Gorcunov Date: Thu Jul 24 13:52:29 2008 +0200 x86: apic unification - merge down enable_NMI_through_LVT0 No code change on binary level. Signed-off-by: Cyrill Gorcunov Cc: macro@linux-mips.org Signed-off-by: Ingo Molnar commit 36a028de785c6e6f15ac84f8b3b087b89137ea26 Author: Cyrill Gorcunov Date: Thu Jul 24 13:52:28 2008 +0200 x86: apic unification - merge down lapic_get_maxlvt No code change on binary level. Signed-off-by: Cyrill Gorcunov Cc: macro@linux-mips.org Signed-off-by: Ingo Molnar commit 510b37258dfd61693ca6c039865c78bd996e3718 Author: Yinghai Lu Date: Tue Jul 22 13:20:22 2008 -0700 x86: move declaring x2apic_extra_bits it is for uv only Signed-off-by: Yinghai Lu Cc: Jack Steiner Cc: Suresh Siddha Signed-off-by: Ingo Molnar commit 0791e13fbb1ea4e1808d055922c3f116b924bdc9 Author: Maciej W. Rozycki Date: Mon Jul 21 01:28:43 2008 +0100 x86: fix up a comment in ack_APIC_irq() Adjust a comment in ack_APIC_irq() according to the recent removal of CONFIG_X86_GOOD_APIC. Signed-off-by: Maciej W. Rozycki Signed-off-by: Ingo Molnar commit 32f71aff77b6470d272f80ac28f43f9601c4d140 Author: Maciej W. Rozycki Date: Mon Jul 21 00:52:49 2008 +0100 x86: PIC, L-APIC and I/O APIC debug information Dump all the PIC, local APIC and I/O APIC information at the fs_initcall() level, which is after ACPI (if used) has initialised PCI information, making the point of invocation consistent across MP-table and ACPI platforms. Remove explicit calls to print_IO_APIC() from elsewhere. Make the interface of all the functions involved consistent between 32-bit and 64-bit versions and make them all static by default by the means of a New-and-Improved(TM) __apicdebuginit() macro. Note that like print_IO_APIC() all these only output anything if "apic=debug" has been passed to the kernel through the command line. Signed-off-by: Maciej W. Rozycki Cc: Chuck Ebbert Signed-off-by: Ingo Molnar commit e0a5a5d9b006fd441e61685a051fa85d52fb172c Author: Alexander van Heukelum Date: Tue Jul 22 18:14:16 2008 +0200 x86, 64-bit, dwarf2: push pushes 8 bytes and popf pops 8 The CFI_ADJUST_CFA_OFFSET dwarf2 annotation of a push/popf pair in ret_from_fork wrongly used a value of 4. It should have been 8. Fix that. Signed-off-by: Alexander van Heukelum Cc: Andi Kleen Cc: heukelum@fastmail.fm Signed-off-by: Ingo Molnar commit d5de8841355a48f7f634a04507185eaf1f9755e3 Author: Jeremy Fitzhardinge Date: Wed Jul 23 13:28:58 2008 -0700 x86: split spinlock implementations out into their own files ftrace requires certain low-level code, like spinlocks and timestamps, to be compiled without -pg in order to avoid infinite recursion. This patch splits out the core paravirt spinlocks and the Xen spinlocks into separate files which can be compiled without -pg. Also do xen/time.c while we're about it. As a result, we can now use ftrace within a Xen domain. Signed-off-by: Jeremy Fitzhardinge Signed-off-by: Ingo Molnar commit 38ffbe66d59051fd9cfcfc8545f164700e2fa3bc Author: Jeremy Fitzhardinge Date: Wed Jul 23 14:21:18 2008 -0700 x86/paravirt/xen: properly fill out the ldt ops LTP testing showed that Xen does not properly implement sys_modify_ldt(). This patch does the final little bits needed to make the ldt work properly. Signed-off-by: Jeremy Fitzhardinge Signed-off-by: Ingo Molnar commit a300bec952127d9a15e666b391bb35c9aecb3002 Author: Randy Dunlap Date: Tue Jul 22 09:46:13 2008 -0700 documentation: move hpet.txt to timers/ subdirectory Move hpet.txt to Documentation/timers/ subdirectory. Add 00-INDEX to Documentation/timers/ subdirectory. Signed-off-by: Randy Dunlap Cc: tglx Signed-off-by: Thomas Gleixner commit fd60b39f845aa7462453af8aed4f059b162f181f Author: Huang Weiyi Date: Wed Jul 23 22:45:01 2008 +0800 arch/x86/kernel/genx2apic_uv_x.c: Removed duplicated include Removed duplicated include file in arch/x86/kernel/genx2apic_uv_x.c. Signed-off-by: Huang Weiyi Signed-off-by: Ingo Molnar commit 05d3ed0a1fe3ea05ab9f3b8d32576a0bc2e19660 Author: Prarit Bhargava Date: Mon Jul 21 10:15:22 2008 -0400 x86, pci: iommu fix potential overflow in alloc_iommu() It is possible that alloc_iommu()'s boundary_size overflows as dma_get_seg_boundary can return 0xffffffff. In that case, further usage of boundary_size triggers a BUG_ON() in the iommu code. Signed-off-by: Prarit Bhargava Signed-off-by: Ingo Molnar commit de89c750b29eb5b7357e0eeace0d43afa676fa02 Author: Ingo Molnar Date: Wed Jul 23 14:15:22 2008 +0200 tracing: clean up tracepoints kconfig structure do not expose users to CONFIG_TRACEPOINTS - tracers can select it just fine. update ftrace to select CONFIG_TRACEPOINTS. Signed-off-by: Ingo Molnar commit 71e3b818431957371c7f69fa1c576d4a403c1478 Author: Jaswinder Singh Date: Wed Jul 23 17:44:00 2008 +0530 x86: mach-default/setup.c declare no_broadcast before they get used included mach_ipi.h for no_broadcast declaration fixed minor spacing for no_broadcast Signed-off-by: Jaswinder Singh commit 01eb7858c017b1c63b962f8c2ad37133383ca560 Author: Jaswinder Singh Date: Wed Jul 23 17:41:59 2008 +0530 x86: mm/pgtable_32.c declare set_pmd_pfn before they get used Signed-off-by: Jaswinder Singh commit e0b7c8192ded4c2096388008d3ca6708caa8b601 Author: Jaswinder Singh Date: Wed Jul 23 17:40:34 2008 +0530 x86: mm/pageattr.c declare arch_report_meminfo before they get used declared arch_report_meminfo() in asm-x86/pgtable.h as it will be also accessible by fs/proc/proc_misc.c Signed-off-by: Jaswinder Singh commit 4b6e9f27d0034740e9cfa341b45c229ba30ec0c5 Author: Jaswinder Singh Date: Wed Jul 23 17:39:16 2008 +0530 x86: mm/ioremap.c declare early_ioremap_debug and early_ioremap_nested as static Signed-off-by: Jaswinder Singh commit 70ef56414ec7e01d787c8e959bb259845df4ee4f Author: Jaswinder Singh Date: Wed Jul 23 17:36:37 2008 +0530 x86: mm/fault.c declare do_page_fault before they get used declared do_page_fault() in asm-x86/trap.h for both X86_32 and X86_64 removed do_invalid_op declaration from mm/fault.c as it is already declared in asm-x86/trap.h Signed-off-by: Jaswinder Singh commit a80495ec927e8ec2b1ff085592bbe9bed77ffb3b Author: Jaswinder Singh Date: Wed Jul 23 17:33:57 2008 +0530 x86: mm/init_XX.c declare functions before they get used included in mm/init_32.c for zap_low_mappings() declared free_initmem() in asm-x86/page_XX.h Signed-off-by: Jaswinder Singh commit 8f7db5186cf126b56035d9a9735774d751090d66 Author: Jaswinder Singh Date: Wed Jul 23 17:31:02 2008 +0530 x86: vm86_32.c declare functions before they get used declared following syscalls in asm-x86/syscalls.h: sys_vm86old, sys_vm86 Signed-off-by: Jaswinder Singh commit f0572edb8bd2dccf5ee24d3323487cc679a61046 Author: Ingo Molnar Date: Wed Jul 23 13:48:22 2008 +0200 sched: clean up tracepoints make it a bit more structured hence more readable. Signed-off-by: Ingo Molnar commit 2b97df06ce44b1d145bd1299f50765803c2fabee Author: Jaswinder Singh Date: Wed Jul 23 17:13:14 2008 +0530 x86: apic_XX.c declare functions before they get used declared following smp interrupts in asm-x86/hw_irq.h: smp_apic_timer_interrupt, smp_spurious_interrupt, smp_error_interrupt Signed-off-by: Jaswinder Singh commit 19f9174396a8f94732252b1fa9eb9d6e45e15988 Author: Ingo Molnar Date: Wed Jul 23 13:38:00 2008 +0200 tracing: disable tracepoints by default while it's arguably low overhead, we dont enable new features by default. Signed-off-by: Ingo Molnar commit 758c7ff98c28b6ecaeb7f09ea8aa3028b676e063 Author: Mathieu Desnoyers Date: Fri Jul 18 12:16:17 2008 -0400 ftrace: port to tracepoints Porting the trace_mark() used by ftrace to tracepoints. (cleanup) Changelog : - Change error messages : marker -> tracepoint Signed-off-by: Mathieu Desnoyers Acked-by: 'Peter Zijlstra' Signed-off-by: Ingo Molnar commit 177a5f86ba5f60c783e24603bedf037d6c43a193 Author: Mathieu Desnoyers Date: Fri Jul 18 12:16:17 2008 -0400 tracing, sched: LTTng instrumentation - scheduler Instrument the scheduler activity (sched_switch, migration, wakeups, wait for a task, signal delivery) and process/thread creation/destruction (fork, exit, kthread stop). Actually, kthread creation is not instrumented in this patch because it is architecture dependent. It allows to connect tracers such as ftrace which detects scheduling latencies, good/bad scheduler decisions. Tools like LTTng can export this scheduler information along with instrumentation of the rest of the kernel activity to perform post-mortem analysis on the scheduler activity. About the performance impact of tracepoints (which is comparable to markers), even without immediate values optimizations, tests done by Hideo Aoki on ia64 show no regression. His test case was using hackbench on a kernel where scheduler instrumentation (about 5 events in code scheduler code) was added. See the "Tracepoints" patch header for performance result detail. Changelog : - Change instrumentation location and parameter to match ftrace instrumentation, previously done with kernel markers. Signed-off-by: Mathieu Desnoyers Acked-by: 'Peter Zijlstra' Signed-off-by: Ingo Molnar commit cea4cea9e6adc49529b2ac55338deb93cc11a594 Author: Mathieu Desnoyers Date: Fri Jul 18 12:16:16 2008 -0400 tracing: tracepoints, samples Tracepoint example code under samples/. Signed-off-by: Mathieu Desnoyers Acked-by: 'Peter Zijlstra' Signed-off-by: Ingo Molnar commit 5f63ce261e5974a617c291e0a5cd04842721c209 Author: Mathieu Desnoyers Date: Fri Jul 18 12:16:16 2008 -0400 tracing: tracepoints, documentation Documentation of tracepoint usage. Signed-off-by: Mathieu Desnoyers Acked-by: 'Peter Zijlstra' Signed-off-by: Ingo Molnar commit e543dff1468a55cdff9932dd3a806524790cf0b3 Author: Mathieu Desnoyers Date: Fri Jul 18 12:16:16 2008 -0400 tracing: Kernel Tracepoints Implementation of kernel tracepoints. Inspired from the Linux Kernel Markers. Allows complete typing verification by declaring both tracing statement inline functions and probe registration/unregistration static inline functions within the same macro "DEFINE_TRACE". No format string is required. See the tracepoint Documentation and Samples patches for usage examples. Taken from the documentation patch : "A tracepoint placed in code provides a hook to call a function (probe) that you can provide at runtime. A tracepoint can be "on" (a probe is connected to it) or "off" (no probe is attached). When a tracepoint is "off" it has no effect, except for adding a tiny time penalty (checking a condition for a branch) and space penalty (adding a few bytes for the function call at the end of the instrumented function and adds a data structure in a separate section). When a tracepoint is "on", the function you provide is called each time the tracepoint is executed, in the execution context of the caller. When the function provided ends its execution, it returns to the caller (continuing from the tracepoint site). You can put tracepoints at important locations in the code. They are lightweight hooks that can pass an arbitrary number of parameters, which prototypes are described in a tracepoint declaration placed in a header file." Addition and removal of tracepoints is synchronized by RCU using the scheduler (and preempt_disable) as guarantees to find a quiescent state (this is really RCU "classic"). The update side uses rcu_barrier_sched() with call_rcu_sched() and the read/execute side uses "preempt_disable()/preempt_enable()". We make sure the previous array containing probes, which has been scheduled for deletion by the rcu callback, is indeed freed before we proceed to the next update. It therefore limits the rate of modification of a single tracepoint to one update per RCU period. The objective here is to permit fast batch add/removal of probes on _different_ tracepoints. Changelog : - Use #name ":" #proto as string to identify the tracepoint in the tracepoint table. This will make sure not type mismatch happens due to connexion of a probe with the wrong type to a tracepoint declared with the same name in a different header. - Add tracepoint_entry_free_old. - Change __TO_TRACE to get rid of the 'i' iterator. Masami Hiramatsu : Tested on x86-64. Performance impact of a tracepoint : same as markers, except that it adds about 70 bytes of instructions in an unlikely branch of each instrumented function (the for loop, the stack setup and the function call). It currently adds a memory read, a test and a conditional branch at the instrumentation site (in the hot path). Immediate values will eventually change this into a load immediate, test and branch, which removes the memory read which will make the i-cache impact smaller (changing the memory read for a load immediate removes 3-4 bytes per site on x86_32 (depending on mov prefixes), or 7-8 bytes on x86_64, it also saves the d-cache hit). About the performance impact of tracepoints (which is comparable to markers), even without immediate values optimizations, tests done by Hideo Aoki on ia64 show no regression. His test case was using hackbench on a kernel where scheduler instrumentation (about 5 events in code scheduler code) was added. Quoting Hideo Aoki about Markers : I evaluated overhead of kernel marker using linux-2.6-sched-fixes git tree, which includes several markers for LTTng, using an ia64 server. While the immediate trace mark feature isn't implemented on ia64, there is no major performance regression. So, I think that we don't have any issues to propose merging marker point patches into Linus's tree from the viewpoint of performance impact. I prepared two kernels to evaluate. The first one was compiled without CONFIG_MARKERS. The second one was enabled CONFIG_MARKERS. I downloaded the original hackbench from the following URL: http://devresources.linux-foundation.org/craiger/hackbench/src/hackbench.c I ran hackbench 5 times in each condition and calculated the average and difference between the kernels. The parameter of hackbench: every 50 from 50 to 800 The number of CPUs of the server: 2, 4, and 8 Below is the results. As you can see, major performance regression wasn't found in any case. Even if number of processes increases, differences between marker-enabled kernel and marker- disabled kernel doesn't increase. Moreover, if number of CPUs increases, the differences doesn't increase either. Curiously, marker-enabled kernel is better than marker-disabled kernel in more than half cases, although I guess it comes from the difference of memory access pattern. * 2 CPUs Number of | without | with | diff | diff | processes | Marker [Sec] | Marker [Sec] | [Sec] | [%] | -------------------------------------------------------------- 50 | 4.811 | 4.872 | +0.061 | +1.27 | 100 | 9.854 | 10.309 | +0.454 | +4.61 | 150 | 15.602 | 15.040 | -0.562 | -3.6 | 200 | 20.489 | 20.380 | -0.109 | -0.53 | 250 | 25.798 | 25.652 | -0.146 | -0.56 | 300 | 31.260 | 30.797 | -0.463 | -1.48 | 350 | 36.121 | 35.770 | -0.351 | -0.97 | 400 | 42.288 | 42.102 | -0.186 | -0.44 | 450 | 47.778 | 47.253 | -0.526 | -1.1 | 500 | 51.953 | 52.278 | +0.325 | +0.63 | 550 | 58.401 | 57.700 | -0.701 | -1.2 | 600 | 63.334 | 63.222 | -0.112 | -0.18 | 650 | 68.816 | 68.511 | -0.306 | -0.44 | 700 | 74.667 | 74.088 | -0.579 | -0.78 | 750 | 78.612 | 79.582 | +0.970 | +1.23 | 800 | 85.431 | 85.263 | -0.168 | -0.2 | -------------------------------------------------------------- * 4 CPUs Number of | without | with | diff | diff | processes | Marker [Sec] | Marker [Sec] | [Sec] | [%] | -------------------------------------------------------------- 50 | 2.586 | 2.584 | -0.003 | -0.1 | 100 | 5.254 | 5.283 | +0.030 | +0.56 | 150 | 8.012 | 8.074 | +0.061 | +0.76 | 200 | 11.172 | 11.000 | -0.172 | -1.54 | 250 | 13.917 | 14.036 | +0.119 | +0.86 | 300 | 16.905 | 16.543 | -0.362 | -2.14 | 350 | 19.901 | 20.036 | +0.135 | +0.68 | 400 | 22.908 | 23.094 | +0.186 | +0.81 | 450 | 26.273 | 26.101 | -0.172 | -0.66 | 500 | 29.554 | 29.092 | -0.461 | -1.56 | 550 | 32.377 | 32.274 | -0.103 | -0.32 | 600 | 35.855 | 35.322 | -0.533 | -1.49 | 650 | 39.192 | 38.388 | -0.804 | -2.05 | 700 | 41.744 | 41.719 | -0.025 | -0.06 | 750 | 45.016 | 44.496 | -0.520 | -1.16 | 800 | 48.212 | 47.603 | -0.609 | -1.26 | -------------------------------------------------------------- * 8 CPUs Number of | without | with | diff | diff | processes | Marker [Sec] | Marker [Sec] | [Sec] | [%] | -------------------------------------------------------------- 50 | 2.094 | 2.072 | -0.022 | -1.07 | 100 | 4.162 | 4.273 | +0.111 | +2.66 | 150 | 6.485 | 6.540 | +0.055 | +0.84 | 200 | 8.556 | 8.478 | -0.078 | -0.91 | 250 | 10.458 | 10.258 | -0.200 | -1.91 | 300 | 12.425 | 12.750 | +0.325 | +2.62 | 350 | 14.807 | 14.839 | +0.032 | +0.22 | 400 | 16.801 | 16.959 | +0.158 | +0.94 | 450 | 19.478 | 19.009 | -0.470 | -2.41 | 500 | 21.296 | 21.504 | +0.208 | +0.98 | 550 | 23.842 | 23.979 | +0.137 | +0.57 | 600 | 26.309 | 26.111 | -0.198 | -0.75 | 650 | 28.705 | 28.446 | -0.259 | -0.9 | 700 | 31.233 | 31.394 | +0.161 | +0.52 | 750 | 34.064 | 33.720 | -0.344 | -1.01 | 800 | 36.320 | 36.114 | -0.206 | -0.57 | -------------------------------------------------------------- Signed-off-by: Mathieu Desnoyers Acked-by: Masami Hiramatsu Acked-by: 'Peter Zijlstra' Signed-off-by: Ingo Molnar commit aa4bf02cfca61ebe68e2a1861a903f6f05f50844 Author: Mathieu Desnoyers Date: Fri Jul 18 12:16:16 2008 -0400 rcu: add rcu_read_lock_sched() & rcu_read_unlock_sched() APIs Add rcu_read_lock_sched() and rcu_read_unlock_sched() to rcupdate.h to match the recently added write-side call_rcu_sched() and rcu_barrier_sched(). They also match the no-so-recently-added synchronize_sched(). It will help following matching use of the update/read lock primitives. Those new read lock will replace preempt_disable()/enable() used in pair with RCU-classic synchronization. Signed-off-by: Mathieu Desnoyers Acked-by: Peter Zijlstra CC: Paul E McKenney Signed-off-by: Ingo Molnar commit a31863168660c6b6f6c7ffe05bb6a38e97803326 Author: Vegard Nossum Date: Tue Jul 22 21:53:53 2008 +0200 x86: consolidate header guards This patch consolidates the header guard names which are also used externally, i.e. in .c files. Signed-off-by: Vegard Nossum commit a021e5124a6c57325ffb02a60cd1d5f40342f8aa Author: H. Peter Anvin Date: Tue Jul 22 15:33:57 2008 -0400 x86: doc: boot.txt: fix the size of the start_sys field The start_sys field is two bytes, not four. Signed-off-by: H. Peter Anvin commit 5616c23ad9cd3c50af674d408fef7b90abeee81c Author: H. Peter Anvin Date: Tue Jul 22 15:32:38 2008 -0400 x86: doc: move x86-generic documentation from Doc/x86/i386 The boot protocol, USB legacy support, and zero-page documentation is common to the x86 platform, not i386-specific. Signed-off-by: H. Peter Anvin commit 77ef50a522717fa040636ee1017179ceba12ff62 Author: Vegard Nossum Date: Wed Jun 18 17:08:48 2008 +0200 x86: consolidate header guards This patch is the result of an automatic script that consolidates the format of all the headers in include/asm-x86/. The format: 1. No leading underscore. Names with leading underscores are reserved. 2. Pathname components are separated by two underscores. So we can distinguish between mm_types.h and mm/types.h. 3. Everything except letters and numbers are turned into single underscores. Signed-off-by: Vegard Nossum commit a656c8efb40a8700046df20da2195f8aa39ce38a Author: Vegard Nossum Date: Tue Jul 22 21:27:11 2008 +0200 x86: fix spurious '#' in kvm header Signed-off-by: Vegard Nossum commit df1be4372eae5f104b7fb4991bc4b35f00b11a11 Author: Suresh Siddha Date: Tue Jul 22 10:13:11 2008 -0400 x64, apic: use generic apic_write() for ack_APIC_irq() I tested tip/master and found an issue (patch attached) for x2apic support. This is not because of the recent merges we had, but because of something(where we still access memory based interface after enabling x2apic mode) that slipped through my earlier tests. Probably it is a good idea to unmap the memory mapped interface, once we switch to x2apic mode. That will catch the issues much earlier. I will post another patch for this. ack_APIC_irq() is used at too many generic places (and not just during irq_chip handling!) to use the native_apic_mem_write(). For ex, this will break x2apic based systems. Fix ack_APIC_irq() to use the generic apic_write() even for 64-bit. Signed-off-by: Suresh Siddha Cc: suresh.b.siddha@intel.com Cc: yong.y.wang@linux.intel.com Signed-off-by: Ingo Molnar commit aa2ed2c1b5f020beace44ab7745d290d64cd6c89 Author: Avi Kivity Date: Tue Jul 22 17:43:45 2008 +0300 KVM: VMX: Fix fault-during-event-injection detection We now detect event injection using the interrupt and exception queues, not the IDT-Vectoring info field. Signed-off-by: Avi Kivity commit 1e84911c6c37fd1080ef07039e19c346628b31db Author: Jaswinder Singh Date: Mon Jul 21 22:58:29 2008 +0530 x86: mtrr/main.c declare range_state as static Signed-off-by: Jaswinder Singh commit 8fd329a1ac696973ba5467c510302ae1248cc11a Author: Jaswinder Singh Date: Mon Jul 21 22:54:56 2008 +0530 x86: common.c declare idle_regs before they get used Signed-off-by: Jaswinder Singh commit 1c6c727d9c12c84a612abe31b60948f06fc2ab2d Author: Jaswinder Singh Date: Mon Jul 21 22:40:37 2008 +0530 x86: proc.c declare cpuinfo_op before they get used Signed-off-by: Jaswinder Singh commit c1686aeaf0780055ffcd4b224b73d5ada77630e8 Author: Jaswinder Singh Date: Mon Jul 21 22:35:38 2008 +0530 x86: ptrace.c declare functions before they get used Signed-off-by: Jaswinder Singh commit 36454936c00c700ae86b5ff376d3c1c1a862c4f5 Author: Jaswinder Singh Date: Mon Jul 21 22:31:57 2008 +0530 x86: i387.c declare dump_fpu() before they get used Signed-off-by: Jaswinder Singh commit 791b897ccd1a2c6c184b88ca6d1aaf053499c3df Author: Jaswinder Singh Date: Mon Jul 21 22:28:22 2008 +0530 x86: pci-nommu.c declare nommu_dma_ops before they get used Signed-off-by: Jaswinder Singh commit 9321b8cbbbf3a8dbd4748e3722facaeb8401bd13 Author: Jaswinder Singh Date: Mon Jul 21 22:24:29 2008 +0530 x86: pci-dma.c declare iommu_bio_merge before they get used moved iommu_bio_merge from io_64.h to io.h because it is required for both. Signed-off-by: Jaswinder Singh commit a7b7511ac1404eaf0e7b6c445a7c61b48ccfcf0b Author: Jaswinder Singh Date: Mon Jul 21 22:19:29 2008 +0530 x86: e820.c declare pci_mem_start before they get used Signed-off-by: Jaswinder Singh commit 5314d48ed54c1a0111c597d1510f77850a1b3232 Author: Jaswinder Singh Date: Mon Jul 21 22:12:23 2008 +0530 x86: setup.c declare saved_video_mode before they get used Signed-off-by: Jaswinder Singh commit cc0384917bf69079088701a0725c5fc6b554bf35 Author: Jaswinder Singh Date: Mon Jul 21 21:52:51 2008 +0530 x86: time_XX.c declare functions before they get used Declare time_init() in asm-x86/time.h Also did cleanup in asm-x86/timer.h : timer_ack is only required for X86_32 int recalibrate_cpu_khz(void) is for X86_32 Signed-off-by: Jaswinder Singh commit b994b6c0332a5499b33880855dadad04d74cde54 Author: Jaswinder Singh Date: Mon Jul 21 21:37:52 2008 +0530 x86: signal_XX.c declare do_notify_resume before they get used Signed-off-by: Jaswinder Singh commit fb26132b441e75d6ba9996efc29b42081aee0abd Author: Jaswinder Singh Date: Mon Jul 21 21:36:40 2008 +0530 x86: process_32.c declare cpu_number before they get used Moved DECLARE_PER_CPU(int, cpu_number) from CONFIG_X86_32_SMP to CONFIG_X86_32 because cpu_number is required for both. And include asm/smp.h in process_32.c Signed-off-by: Jaswinder Singh commit bbc1f698a508927d21324b57500e863f9bd562b9 Author: Jaswinder Singh Date: Mon Jul 21 21:34:13 2008 +0530 x86: Introducing asm/syscalls.h Declaring arch-dependent syscalls for x86 architecture Signed-off-by: Jaswinder Singh commit 6409b3d382f8ec99c1ab312dd1e42f833465b9e6 Author: Ingo Molnar Date: Tue Jul 22 12:20:56 2008 +0200 kmemcheck: export kmemcheck_mark_initialized fix: Building modules, stage 2. MODPOST 345 modules ERROR: "kmemcheck_mark_initialized" [drivers/net/tokenring/3c359.ko] undefined! ERROR: "kmemcheck_mark_initialized" [drivers/net/sis900.ko] undefined! ERROR: "kmemcheck_mark_initialized" [drivers/net/sfc/sfc.ko] undefined! ERROR: "kmemcheck_mark_initialized" [drivers/net/s2io.ko] undefined! [...] Signed-off-by: Ingo Molnar commit 026e2c05ef58ef413e2d52696f125d5ea1aa8bce Author: Ingo Molnar Date: Tue Jul 22 11:58:14 2008 +0200 x86, cyrix: debug Signed-off-by: Ingo Molnar commit ea8b7f0542e0420240d057f7954808c65c4d13fc Author: Alexander Graf Date: Tue Jul 22 08:00:45 2008 +0200 KVM: Ignore DEBUGCTL MSRs with no effect Netware writes to DEBUGCTL and reads from the DEBUGCTL and LAST*IP MSRs without further checks and is really confused to receive a #GP during that. To make it happy we should just make them stubs, which is exactly what SVM already does. Writes to DEBUGCTL that are vendor-specific are resembled to behave as if the virtual CPU does not know them. Signed-off-by: Alexander Graf Signed-off-by: Avi Kivity commit 70bbede9825e34c997b1bc95cf2fd0a0a6272cf8 Author: Avi Kivity Date: Tue Jul 22 13:13:53 2008 +0300 KVM: MMU: Fix spte leak when freeing an invalid page An invalid page may still contain sptes, as the current vcpu may not have had the chance to unload its root after the page was marked invalid. Signed-off-by: Avi Kivity commit fe81c016a766261847540e90da9b1e66176dc356 Author: Avi Kivity Date: Tue Jul 22 11:32:57 2008 +0300 KVM: MMU: Avoid changing invalid shadow pages Recent changes to the page zapping code made it vulnerable to changes to invalid shadow ptes (which are nonsensical anyway). Detect those and skip them. Signed-off-by: Avi Kivity commit d31ec1c47b10e268794e7b739b2009ac6a19eb8b Author: Ingo Molnar Date: Tue Jul 22 09:40:43 2008 +0200 poison-pointers: clean up, add comments - remove stray 'L' (noticed by Andrew Morton) - add more comments about the purpose of this change - fix spelling (noticed by Andrew Morton) Signed-off-by: Ingo Molnar commit 1b9b89e7f163336ad84200b66a17284dbf26aced Author: Yinghai Lu Date: Mon Jul 21 22:08:21 2008 -0700 x86: add apic probe for genapic 64bit, v2 introducing an APIC handling probing abstraction: static struct genapic *apic_probe[] __initdata = { &apic_x2apic_uv_x, &apic_x2apic_phys, &apic_x2apic_cluster, &apic_physflat, NULL, }; This way we can remove UV, x2apic specific code from genapic_64.c and move them to their specific genapic files. [ v2: fix compiling when CONFIG_ACPI is not set ] Signed-off-by: Yinghai Lu Cc: Jack Steiner Cc: Suresh Siddha Signed-off-by: Ingo Molnar commit 8d00a6c8f6b08e7167bc03bf955cdc7e47c5132e Author: Thomas Gleixner Date: Tue Jul 22 08:39:57 2008 +0200 genirq: remove last NO_IDLE_HZ leftovers Signed-off-by: Thomas Gleixner commit 93aca2cf65ed57936f85cdeddfb04acccad4d76c Author: Mark Fasheh Date: Mon Jul 21 14:29:16 2008 -0700 ocfs2: POSIX file locks support This is actually pretty easy since fs/dlm already handles the bulk of the work. The Ocfs2 userspace cluster stack module already uses fs/dlm as the underlying lock manager, so I only had to add the right calls. Cluster-aware POSIX locks ("plocks") can be turned off by the same means at UNIX locks - mount with 'noflocks', or create a local-only Ocfs2 volume. Internally, the file system uses two sets of file_operations, depending on whether cluster aware plocks is required. This turns out to be easier than implementing local-only versions of ->lock. Signed-off-by: Mark Fasheh commit f9d906cbb385920c93baee6076d8304613f9badc Author: Ingo Molnar Date: Mon Jul 21 11:09:46 2008 +0200 KVM: fix exception entry / build bug, on 64-bit x86 -tip testing found this build bug: arch/x86/kvm/built-in.o:(.text.fixup+0x1): relocation truncated to fit: R_X86_64_32 against `.text' arch/x86/kvm/built-in.o:(.text.fixup+0xb): relocation truncated to fit: R_X86_64_32 against `.text' arch/x86/kvm/built-in.o:(.text.fixup+0x15): relocation truncated to fit: R_X86_64_32 against `.text' arch/x86/kvm/built-in.o:(.text.fixup+0x1f): relocation truncated to fit: R_X86_64_32 against `.text' arch/x86/kvm/built-in.o:(.text.fixup+0x29): relocation truncated to fit: R_X86_64_32 against `.text' Introduced by commit 540cd68. The problem is that 'push' will default to 32-bit, which is not wide enough as a fixup address. (and which would crash on any real fixup event even if it was wide enough) Introduce KVM_EX_PUSH to get the proper address push width on 64-bit too. Signed-off-by: Ingo Molnar Signed-off-by: Avi Kivity commit 14dc6aaab6b1ec53f412332566528c5b5168ce47 Author: Sheng Yang Date: Wed Jul 16 09:25:40 2008 +0800 KVM: VMX: Fix undefined beaviour of EPT after reload kvm-intel.ko As well as move set base/mask ptes to vmx_init(). Signed-off-by: Sheng Yang Signed-off-by: Avi Kivity commit eba776ed3116be782f6deeb8d84623e31bb7f4b0 Author: Sheng Yang Date: Wed Jul 16 09:21:22 2008 +0800 KVM: VMX: Fix bypass_guest_pf enabling when disable EPT in module parameter Signed-off-by: Sheng Yang Signed-off-by: Avi Kivity commit 974034dba55ee67f60cec1dd160009766d037994 Author: Christoph Hellwig Date: Mon Jul 21 16:16:15 2008 +1000 [XFS] Remove vn_revalidate calls in xfs. These days most of the attributes in struct inode are properly kept in sync by XFS. This patch removes the need for vn_revalidate completely by: - keeping inode.i_flags uptodate after any flags are updated in xfs_ioctl_setattr - keeping i_mode, i_uid and i_gid uptodate in xfs_setattr SGI-PV: 984566 SGI-Modid: xfs-linux-melb:xfs-kern:31679a Signed-off-by: Christoph Hellwig Signed-off-by: Tim Shimmin Signed-off-by: Lachlan McIlroy commit 799d0da9e645258b9d1ae11d4aac73c9474906e3 Author: Arjan van de Ven Date: Sun Jul 20 16:30:29 2008 -0700 fastboot: make the RAID autostart code print a message just before waiting As requested/suggested by Neil Brown: make the raid code print that it's about to wait for probing to be done as well as give a suggestion on how to disable the probing if the user doesn't use raid. Signed-off-by: Arjan van de Ven Date: Sun Jul 20 13:12:16 2008 -0700 fastboot: remove "wait for all devices before mounting root" delay In the non-initrd case, we wait for all devices to finish their probing before we try to mount the rootfs. In practice, this means that we end up waiting 2 extra seconds for the PS/2 mouse probing even though the root holding device has been ready since a long time. The previous two patches in this series made the RAID autodetect code do it's own "wait for probing to be done" code, and added "wait and retry" functionality in case the root device isn't actually available. These two changes should make it safe to remove the delay itself, and this patch does this. On my test laptop, this reduces the boot time by 2 seconds (kernel time goes from 3.9 to 1.9 seconds). Signed-off-by: Arjan van de Ven commit b52c36a95ed8026b6925fe8595ebcab6921ae62d Author: Arjan van de Ven Date: Sun Jul 20 13:07:09 2008 -0700 fastboot: make the raid autodetect code wait for all devices to init The raid autodetect code really needs to have all devices probed before it can detect raid arrays; not doing so would give rather messy situations where arrays would get detected as degraded while they shouldn't be etc. This is in preparation of removing the "wait for everything to init" code that makes everyone pay, not just raid users. Signed-off-by: Arjan van de Ven commit db62cd29f9b9142c19c574ca00916f66ff22ed4a Author: Arjan van de Ven Date: Sun Jul 20 13:01:28 2008 -0700 fastboot: retry mounting the root fs if we can't find init currently we wait until all device init is done before trying to mount the root fs, and to consequently execute init. In preparation for relaxing the first delay, this patch adds a retry attempt in case /sbin/init is not found. Before retrying, the code will wait for all device init to complete. While this patch by itself doesn't gain boot time yet (it needs follow on patches), the alternative already is to panic()... Signed-off-by: Arjan van de Ven commit a06e1c2b448b317bc141934879cbbbed8319b4d4 Author: Arjan van de Ven Date: Thu Jul 17 12:24:06 2008 -0700 modules: extend initcall_debug functionality to the module loader The kernel has this really nice facility where if you put "initcall_debug" on the kernel commandline, it'll print which function it's going to execute just before calling an initcall, and then after the call completes it will 1) print if it had an error code 2) checks for a few simple bugs (like leaving irqs off) and 3) print how long the init call took in milliseconds. While trying to optimize the boot speed of my laptop, I have been loving number 3 to figure out what to optimize... ... and then I wished that the same thing was done for module loading. This patch makes the module loader use this exact same functionality; it's a logical extension in my view (since modules are just sort of late binding initcalls anyway) and so far I've found it quite useful in finding where things are too slow in my boot. Signed-off-by: Arjan van de Ven Signed-off-by: Ingo Molnar commit 50b6962016b824dfac254b8f36fc6cac301c8a8d Author: Arjan van de Ven Date: Sun Jul 20 10:20:49 2008 -0700 fastboot: make fastboot a config option to mitigate the risks of async bootup, make fastboot a configuration option... Signed-off-by: Arjan van de Ven Signed-off-by: Ingo Molnar commit 660625fb93f2fc0e633da9cb71d13d895b385f64 Author: Arjan van de Ven Date: Sun Jul 20 09:00:41 2008 -0700 fastboot: sync the async execution before late_initcall and move level 6s (sync) first Rene Herman points out several cases where it's basically needed to have all level 6/6a/6s calls done before the level 7 (late_initcall) code runs. This patch adds a sync point in the transition from the 6's to the 7's. Second, this patch makes sure that level 6s (sync) happens before the async code starts, and puts a user in driver/pci in this category that needs to happen before device init. Signed-off-by: Arjan van de Ven Signed-off-by: Ingo Molnar commit 3e6558b693dd1e69e3177bc248977f067a769f14 Author: Arjan van de Ven Date: Sun Jul 20 08:59:24 2008 -0700 fastboot: hold the BKL over the async init call sequence Regular init calls are called with the BKL held; make sure the async init calls are also called with the BKL held. While this reduces parallelism a little, it does provide lock-for-lock compatibility. The hit to prallelism isn't too bad, most of the init calls are done immediately or actually block for their delays. Signed-off-by: Arjan van de Ven Signed-off-by: Ingo Molnar commit 7be42004065ce4df193aeef5befd26805267d0d9 Author: Ingo Molnar Date: Sun Jul 20 17:04:57 2008 +0200 x86, lguest: fix apic_ops build on UP fix: arch/x86/lguest/boot.c:816: error: variable ‘lguest_basic_apic_ops’ has initializer but incomplete type arch/x86/lguest/boot.c:817: error: unknown field ‘read’ specified in initializer [...] Signed-off-by: Ingo Molnar commit caf43bf7c6a55e89b6df5179df434d67e24aa32e Author: Ingo Molnar Date: Sun Jul 20 14:06:50 2008 +0200 x86, xen: fix apic_ops build on UP fix: arch/x86/xen/enlighten.c:615: error: variable ‘xen_basic_apic_ops’ has initializer but incomplete type arch/x86/xen/enlighten.c:616: error: unknown field ‘read’ specified in initializer [...] Signed-off-by: Ingo Molnar commit b12065dcbd851ef167cd7b60163886ed4c42c0aa Author: Avi Kivity Date: Sun Jul 20 14:24:22 2008 +0300 KVM: Adjust smp_call_function_mask() callers to new requirements smp_call_function_mask() now complains when called in a preemptible context; adjust its callers accordingly. Signed-off-by: Avi Kivity commit c706491d29c8c1e7d7d461ca13e8cceb82ad4222 Author: Marcelo Tosatti Date: Sat Jul 19 19:08:07 2008 -0300 KVM: task switch: translate guest segment limit to virt-extension byte granular field If 'g' is one then limit is 4kb granular. Signed-off-by: Marcelo Tosatti Signed-off-by: Avi Kivity commit 60ddc2e5c44b4b9f5fcb440065469eacbeabf5eb Author: Arjan van de Ven Date: Fri Jul 18 15:17:35 2008 -0700 fastboot: convert a few non-critical ACPI drivers to async initcalls This patch converts a few non-critical ACPI drivers to async initcalls; these initcalls (battery, button and thermal) tend to take quite a bit of time (100's of milliseconds) due to the hardware they need to talk to, but are otherwise clearly non-essential for the boot process. Signed-off-by: Arjan van de Ven Signed-off-by: Ingo Molnar commit d1a26186ee222329a797bb0b2c8e2b5bc7d94d42 Author: Arjan van de Ven Date: Fri Jul 18 15:16:53 2008 -0700 fastboot: turn the USB hostcontroller initcalls into async initcalls the USB host controller init calls take a long time, mostly due to a "minimally 100 msec" delay *per port* during initialization. These are prime candidates for going in parallel to everything else. The USB device ordering is not affected by this due to the serialized-within-eachother property of async initcalls. Signed-off-by: Arjan van de Ven Signed-off-by: Ingo Molnar commit ac9103dd8e4dc65c110d6cba9a3380c6c617ffa7 Author: Arjan van de Ven Date: Fri Jul 18 15:16:08 2008 -0700 fastboot: create a "asynchronous" initlevel This patch creates an asynchronous initlevel (6a) which is at the same level as the normal device initcalls, but with the difference that they are run asynchronous from all the other initcalls. The purpose of this *selective* level is that we can move long waiting inits that are not boot-critical to this level one at a time. To keep things not totally insane, the asynchronous initcalls are async to the other initcalls, but are still ordered to themselves; think of it as "bottom-half-not-softirq". This has the benefit that async drivers still have stable device ordering between them. Signed-off-by: Arjan van de Ven Signed-off-by: Ingo Molnar commit f586bf7df9acc26b68b0feefc0dd32fa63516d3a Author: Suresh Siddha Date: Fri Jul 18 15:58:35 2008 -0700 x86: APIC: Remove apic_write_around(); use alternatives, merge fix On Fri, Jul 18, 2008 at 02:03:48PM -0700, Ingo Molnar wrote: > > * Yinghai Lu wrote: > > > > git merge tip/x86/x2apic > > CONFLICT (content): Merge conflict in arch/x86/kernel/Makefile > > CONFLICT (content): Merge conflict in arch/x86/kernel/paravirt.c > > CONFLICT (content): Merge conflict in arch/x86/kernel/smpboot.c > > CONFLICT (content): Merge conflict in arch/x86/kernel/vmi_32.c > > CONFLICT (content): Merge conflict in arch/x86/xen/enlighten.c > > CONFLICT (content): Merge conflict in include/asm-x86/apic.h > > CONFLICT (content): Merge conflict in include/asm-x86/paravirt.h > > that's due to the changes in tip/x86/apic and in tip/x86/uv. > > ok, i've just merged x86/apic into x86/x2apic and x86/uv as well, and > pushed out the result. > > Note: it's a first raw merge and completely untested. It will now merge > cleanly into tip/master. There are probably a few details missing. Ingo, thanks for doing this. While I was testing my merge changes, you posted yours... anyhow we need this piece, which is missing from your merge. Signed-off-by: Suresh Siddha Cc: Yinghai Lu Cc: "Maciej W. Rozycki" Cc: Jeremy Fitzhardinge Cc: Zachary Amsden Signed-off-by: Ingo Molnar commit a654b9a9a357f353916ba56f751a667d9b13304a Author: Avi Kivity Date: Sat Jul 19 08:57:05 2008 +0300 KVM: Avoid instruction emulation when event delivery is pending When an event (such as an interrupt) is injected, and the stack is shadowed (and therefore write protected), the guest will exit. The current code will see that the stack is shadowed and emulate a few instructions, each time postponing the injection. Eventually the injection may succeed, but at that time the guest may be unwilling to accept the interrupt (for example, the TPR may have changed). This occurs every once in a while during a Windows 2008 boot. Fix by unshadowing the fault address if the fault was due to an event injection. Signed-off-by: Avi Kivity commit 17c60a8e44a7d5e82d7ea2e470591c4fdb9e05df Author: Chuck Lever Date: Mon Jun 30 18:45:37 2008 -0400 SUNRPC: Use proper INADDR_ANY when setting up RPC services on IPv6 Teach svc_create_xprt() to use the correct ANY address for AF_INET6 based RPC services. No caller uses AF_INET6 yet. Signed-off-by: Chuck Lever Signed-off-by: J. Bruce Fields commit 48b6d561af199656d9cb6077bb98cdc81678b79d Author: Chuck Lever Date: Mon Jun 30 18:45:30 2008 -0400 SUNRPC: Add address family field to svc_serv data structure Introduce and initialize an address family field in the svc_serv structure. This field will determine what family to use for the service's listener sockets and what families are advertised via the local rpcbind daemon. Signed-off-by: Chuck Lever Signed-off-by: J. Bruce Fields commit f84dbb912f344270f31d5cce974f12908a47798d Author: Eric W. Biederman Date: Thu Jul 10 14:48:54 2008 -0700 genirq: enable polling for disabled screaming irqs When we disable a screaming irq we never see it again. If the irq line is shared or if the driver half works this is a real pain. So periodically poll the handlers for screaming interrupts. I use a timer instead of the classic irq poll technique of working off the timer interrupt because when we use the local apic timers note_interrupt is never called (bug?). Further on a system with dynamic ticks the timer interrupt might not even fire unless there is a timer telling it it needs to. I forced this case on my test system with an e1000 nic and my ssh session remained responsive despite the interrupt handler only being called every 10th of a second. Signed-off-by: Eric W. Biederman Signed-off-by: Ingo Molnar commit 511d9d34183662aada3890883e860b151d707e22 Author: Suresh Siddha Date: Mon Jul 14 09:49:14 2008 -0700 x86: apic_ops for lguest apic_ops for lguest. Signed-off-by: Suresh Siddha Acked-by: Yinghai Lu Signed-off-by: Ingo Molnar commit 9a8f0e6b5dfe3b4f330fc82b16a4000f5688fce8 Author: Suresh Siddha Date: Fri Jul 18 09:59:40 2008 -0700 x86: let 32bit use apic_ops too - fix Fix VMI apic_ops. Signed-off-by: Suresh Siddha Acked-by: Yinghai Lu Signed-off-by: Ingo Molnar commit 5127bed588a2f8f3a1f732de2a8a190b7df5dce3 Author: Lai Jiangshan Date: Sun Jul 6 17:23:59 2008 +0800 rcu classic: new algorithm for callbacks-processing(v2) This is v2, it's a little deference from v1 that I had send to lkml. use ACCESS_ONCE use rcu_batch_after/rcu_batch_before for batch # comparison. rcutorture test result: (hotplugs: do cpu-online/offline once per second) No CONFIG_NO_HZ: OK, 12hours No CONFIG_NO_HZ, hotplugs: OK, 12hours CONFIG_NO_HZ=y: OK, 24hours CONFIG_NO_HZ=y, hotplugs: Failed. (Failed also without my patch applied, exactly the same bug occurred, http://lkml.org/lkml/2008/7/3/24) v1's email thread: http://lkml.org/lkml/2008/6/2/539 v1's description: The code/algorithm of the implement of current callbacks-processing is very efficient and technical. But when I studied it and I found a disadvantage: In multi-CPU systems, when a new RCU callback is being queued(call_rcu[_bh]), this callback will be invoked after the grace period for the batch with batch number = rcp->cur+2 has completed very very likely in current implement. Actually, this callback can be invoked after the grace period for the batch with batch number = rcp->cur+1 has completed. The delay of invocation means that latency of synchronize_rcu() is extended. But more important thing is that the callbacks usually free memory, and these works are delayed too! it's necessary for reclaimer to free memory as soon as possible when left memory is few. A very simple way can solve this problem: a field(struct rcu_head::batch) is added to record the batch number for the RCU callback. And when a new RCU callback is being queued, we determine the batch number for this callback(head->batch = rcp->cur+1) and we move this callback to rdp->donelist if we find that head->batch <= rcp->completed when we process callbacks. This simple way reduces the wait time for invocation a lot. (about 2.5Grace Period -> 1.5Grace Period in average in multi-CPU systems) This is my algorithm. But I do not add any field for struct rcu_head in my implement. We just need to memorize the last 2 batches and their batch number, because these 2 batches include all entries that for whom the grace period hasn't completed. So we use a special linked-list rather than add a field. Please see the comment of struct rcu_data. Signed-off-by: Lai Jiangshan Cc: "Paul E. McKenney" Cc: Dipankar Sarma Cc: Gautham Shenoy Cc: Dhaval Giani Cc: Peter Zijlstra Signed-off-by: Ingo Molnar commit 3cac97cbb14aed00d83eb33d4613b0fe3aaea863 Author: Lai Jiangshan Date: Sun Jul 6 17:23:55 2008 +0800 rcu classic: simplify the next pending batch use a batch number(rcp->pending) instead of a flag(rcp->next_pending) rcu_start_batch() need to change this flag, so mb()s is needed for memory-access safe. but(after this patch applied) rcu_start_batch() do not change this batch number(rcp->pending), rcp->pending is managed by __rcu_process_callbacks only, and troublesome mb()s are eliminated. And codes look simpler and clearer. Signed-off-by: Lai Jiangshan Cc: "Paul E. McKenney" Cc: Dipankar Sarma Cc: Gautham Shenoy Cc: Dhaval Giani Cc: Peter Zijlstra Signed-off-by: Ingo Molnar commit 1eda9307bb459d5d1f6aae18110054865abbde47 Author: Ingo Molnar Date: Fri Jul 18 12:25:42 2008 +0200 x86, tracing, nmisafe: fix threadinfo_ -> TI_ rename fallout Signed-off-by: Ingo Molnar commit 93f3fd0cad91c7587b539c5433932170109999e2 Author: Christoph Hellwig Date: Fri Jul 18 17:13:28 2008 +1000 [XFS] Now that xfs_setattr is only used for attributes set from ->setattr it can be switched to take struct iattr directly and thus simplify the implementation greatly. Also rename the ATTR_ flags to XFS_ATTR_ to not conflict with the ATTR_ flags used by the VFS. SGI-PV: 984565 SGI-Modid: xfs-linux-melb:xfs-kern:31678a Signed-off-by: Christoph Hellwig Signed-off-by: Tim Shimmin Signed-off-by: Lachlan McIlroy commit d9fcd6b7dedc53570e8d0095664040ff68d35de8 Author: Christoph Hellwig Date: Fri Jul 18 17:13:20 2008 +1000 [XFS] xfs_setattr currently doesn't just handle the attributes set through ->setattr but also addition XFS-specific attributes: project id, inode flags and extent size hint. Having these in a single function makes it more complicated and forces to have us a bhv_vattr intermediate structure eating up stackspace. This patch adds a new xfs_ioctl_setattr helper for the XFS ioctls that set these attributes and remove the code to set them through xfs_setattr. SGI-PV: 984564 SGI-Modid: xfs-linux-melb:xfs-kern:31677a Signed-off-by: Christoph Hellwig Signed-off-by: Tim Shimmin Signed-off-by: Lachlan McIlroy commit 3d5813c6fe069576d08a3810998bd9c65062c441 Author: Lachlan McIlroy Date: Fri Jul 18 17:13:12 2008 +1000 [XFS] fix use after free with external logs or real-time devices SGI-PV: 983806 SGI-Modid: xfs-linux-melb:xfs-kern:31666a Signed-off-by: Lachlan McIlroy Signed-off-by: Christoph Hellwig commit 51d8c5ecd5a062b242bc7a71d46f67be86f41101 Author: Tim Shimmin Date: Fri Jul 18 17:13:04 2008 +1000 [XFS] A bug was found in xfs_bmap_add_extent_unwritten_real(). In a particular case, the delta param which is supposed to describe the region where extents have changed was not updated appropriately. SGI-PV: 984030 SGI-Modid: xfs-linux-melb:xfs-kern:31663a Signed-off-by: Tim Shimmin Signed-off-by: Lachlan McIlroy Signed-off-by: Olaf Weber commit 96adf83f4f6ab62b61befa95eb9db86fb0200a1a Author: David Chinner Date: Fri Jul 18 17:12:57 2008 +1000 [XFS] Use the generic bitops rather than implementing them ourselves. This keeps xfs_lowbit64 as it was since there aren't good generic helpers there ... Patch inspired by Andi Kleen. SGI-PV: 981498 SGI-Modid: xfs-linux-melb:xfs-kern:31472a Signed-off-by: David Chinner Signed-off-by: Eric Sandeen Signed-off-by: Donald Douwsma Signed-off-by: Lachlan McIlroy commit 7ec6638bc45c7169c7b5ab54618a0ab7206f4717 Author: Christoph Hellwig Date: Fri Jul 18 17:12:50 2008 +1000 [XFS] fix compilation without CONFIG_PROC_FS SGI-PV: 984019 SGI-Modid: xfs-linux-melb:xfs-kern:31408a Signed-off-by: Christoph Hellwig Signed-off-by: Tim Shimmin Signed-off-by: Lachlan McIlroy commit 14f23ec1ed283d4e13948e0f42457857ea7371e6 Author: Christoph Hellwig Date: Fri Jul 18 17:12:43 2008 +1000 [XFS] s/XFS_PURGE_INODE/IRELE/g s/VN_HOLD(XFS_ITOV())/IHOLD()/ SGI-PV: 981498 SGI-Modid: xfs-linux-melb:xfs-kern:31405a Signed-off-by: Christoph Hellwig Signed-off-by: Tim Shimmin Signed-off-by: David Chinner Signed-off-by: Lachlan McIlroy commit 0327f9d799ebb96f67c80dd732b1fdb09527365e Author: Christoph Hellwig Date: Fri Jul 18 17:12:36 2008 +1000 [XFS] fix mount option parsing in remount Remount currently happily accept any option thrown at it, although the only filesystem specific option it actually handles is barrier/nobarrier. And it actually doesn't handle these correctly either because it only uses the value it parsed when we're doing a ro->rw transition. In addition to that there's also a bad bug in xfs_parseargs which doesn't touch the actual option in the mount point except for a single one, XFS_MOUNT_SMALL_INUMS and thus forced any filesystem that's every remounted in some way to not support 64bit inodes with no way to recover unless unmounted. This patch changes xfs_fs_remount to use it's own linux/parser.h based options parse instead of xfs_parseargs and reject all options except for barrier/nobarrier and to the right thing in general. Eventually I'd like to have a single big option table used for mount aswell but that can wait for a while. SGI-PV: 983964 SGI-Modid: xfs-linux-melb:xfs-kern:31382a Signed-off-by: Christoph Hellwig Signed-off-by: Tim Shimmin Signed-off-by: Lachlan McIlroy commit 576fc74815f18ce0d3e89edb3a95e85050ba5a74 Author: Eric Sandeen Date: Fri Jul 18 17:12:18 2008 +1000 [XFS] Disable queue flag test in barrier check. md raid1 can pass down barriers, but does not set an ordered flag on the queue, so xfs does not even attempt a barrier write, and will never use barriers on these block devices. Remove the flag check and just let the barrier write test determine barrier support. A possible risk here is that if something does not set an ordered flag and also does not properly return an error on a barrier write... but if it's any consolation jbd/ext3/reiserfs never test the flag, and don't even do a test write, they just disable barriers the first time an actual journal barrier write fails. SGI-PV: 983924 SGI-Modid: xfs-linux-melb:xfs-kern:31377a Signed-off-by: Eric Sandeen Signed-off-by: Tim Shimmin Signed-off-by: Lachlan McIlroy commit 8e37ca5950c24e64868ebb7609c93f2800b9f52e Author: Christoph Hellwig Date: Fri Jul 18 17:11:46 2008 +1000 [XFS] streamline init/exit path Currently the xfs module init/exit code is a mess. It's farmed out over a lot of function with very little error checking. This patch makes sure we propagate all initialization failures properly and clean up after them. Various runtime initializations are replaced with compile-time initializations where possible to make this easier. The exit path is similarly consolidated. There's now split out function to create/destroy the kmem zones and alloc/free the trace buffers. I've also changed the ktrace allocations to KM_MAYFAIL and handled errors resulting from that. And yes, we really should replace the XFS_*_TRACE ifdefs with a single XFS_TRACE.. SGI-PV: 976035 SGI-Modid: xfs-linux-melb:xfs-kern:31354a Signed-off-by: Christoph Hellwig Signed-off-by: Niv Sardi Signed-off-by: Lachlan McIlroy commit b01784c6852f93e44d7325d24683756bdef57ef1 Author: Avi Kivity Date: Thu Jul 17 18:04:30 2008 +0300 KVM: VMX: Avoid vmwrite(HOST_RSP) when possible Usually HOST_RSP retains its value across guest entries. Take advantage of this and avoid a vmwrite() when this is so. Signed-off-by: Avi Kivity commit ff2674ce50b8424c05bee6b289067d21f95b65fb Author: Marcelo Tosatti Date: Wed Jul 16 19:07:11 2008 -0300 KVM: task switch: use seg regs provided by subarch instead of reading from GDT There is no guarantee that the old TSS descriptor in the GDT contains the proper base address. This is the case for Windows installation's reboot-via-triplefault. Use guest registers instead. Also translate the address properly. Signed-off-by: Marcelo Tosatti Signed-off-by: Avi Kivity commit 4f6c4caa9a735d5ada70587a56ad75b55b6d8e75 Author: Marcelo Tosatti Date: Wed Jul 16 19:07:10 2008 -0300 KVM: task switch: segment base is linear address The segment base is always a linear address, so translate before accessing guest memory. Signed-off-by: Marcelo Tosatti Signed-off-by: Avi Kivity commit b7144ce99de3f9e0c92b68538e0f11539b418468 Author: Joerg Roedel Date: Mon Jul 14 20:36:36 2008 +0200 KVM: SVM: allow enabling/disabling NPT by reloading only the architecture module If NPT is enabled after loading both KVM modules on AMD and it should be disabled, both KVM modules must be reloaded. If only the architecture module is reloaded the behavior is undefined. With this patch it is possible to disable NPT only by reloading the kvm_amd module. Signed-off-by: Joerg Roedel Signed-off-by: Avi Kivity commit 6b20e3e7352bf9cca29936a69758ed8763266d10 Author: Avi Kivity Date: Mon Jul 14 19:53:33 2008 +0300 KVM: Avoid using ktime_t in an external header It's an internal name, and further the representation is not portable. Signed-off-by: Avi Kivity commit d23db9bbd91baaa1b22e7839e1e932bc6ae0582b Author: Ingo Molnar Date: Mon Jul 14 18:03:27 2008 +0200 x86: change LIST_POISON to 0xdead000000000000 Linus observed: | > + default 0xffffc10000000000 if X86_64 | | This looks like a singularly bad pointer value on x86-64. | | Why not pick something that is *guaranteed* to fault? The above looks like | any future setup that supports 41 bits of addressing and has extended the | page tables (yes, it will happen eventually) will find that to be a | perfectly valid address? | | It's also visually confusing, since it's visually very close to a real | kernel pointer too. Correct - so change the poison value to 0xdead000000000000. Acked-by: Linus Torvalds Signed-off-by: Ingo Molnar commit 17254a0b1955afc86b8f225980f91408432b5fae Author: Christian Ehrhardt Date: Mon Jul 14 14:00:04 2008 +0200 KVM: ppc: trace powerpc instruction emulation This patch adds a trace point for the instruction emulation on embedded powerpc utilizing the KVM_TRACE interface. Signed-off-by: Christian Ehrhardt Signed-off-by: Avi Kivity commit da7a31893b984187e091105e496e42ae0a3f3b04 Author: Jerone Young Date: Mon Jul 14 14:00:03 2008 +0200 KVM: ppc: adds trace points for ppc tlb activity This patch adds trace points to track powerpc TLB activities using the KVM_TRACE infrastructure. Signed-off-by: Jerone Young Signed-off-by: Christian Ehrhardt Signed-off-by: Avi Kivity commit ab778d332fc3052f25373655690af9a265e54e3c Author: Jerone Young Date: Mon Jul 14 14:00:02 2008 +0200 KVM: ppc: enable KVM_TRACE building for powerpc This patch enables KVM_TRACE to build for PowerPC arch. This means just adding sections to Kconfig and Makefile. Signed-off-by: Jerone Young Signed-off-by: Christian Ehrhardt Signed-off-by: Avi Kivity commit b8486fbae0046883437c91e9b475f1878888fe72 Author: Christian Ehrhardt Date: Mon Jul 14 14:00:01 2008 +0200 KVM: kvmtrace: replace get_cycles with ktime_get v3 The current kvmtrace code uses get_cycles() while the interpretation would be easier using using nanoseconds. ktime_get() should give at least the same accuracy as get_cycles on all architectures (even better on 32bit archs) but at a better unit (e.g. comparable between hosts with different frequencies. Signed-off-by: Christian Ehrhardt Acked-by: Christian Borntraeger Signed-off-by: Avi Kivity commit 30328a305413c0f4794c2e719bdc2ceeb9f36033 Author: Christian Ehrhardt Date: Mon Jul 14 14:00:00 2008 +0200 KVM: kvmtrace: Remove use of bit fields in kvm trace structure This patch fixes kvmtrace use on big endian systems. When using bit fields the compiler will lay data out in the wrong order expected when laid down into a file. This fixes it by using one variable instead of using bit fields. Signed-off-by: Jerone Young Signed-off-by: Christian Ehrhardt Signed-off-by: Avi Kivity commit 15b873e0f38182581ec7d5e9fbd65b7d243687c9 Author: Avi Kivity Date: Mon Jul 14 14:44:59 2008 +0300 KVM: SVM: Unify register save/restore across 32 and 64 bit hosts Signed-off-by: Avi Kivity commit 38b4bbee8384f5f13c46dcff9ba2d4878c11ad1a Author: Avi Kivity Date: Mon Jul 14 14:44:59 2008 +0300 KVM: VMX: Unify register save/restore across 32 and 64 bit hosts Signed-off-by: Avi Kivity commit 08de8e72d966bb267a4b4962ec92e9f68aa967d7 Author: Jan Kiszka Date: Mon Jul 14 12:28:51 2008 +0200 KVM: VMX: Reinject real mode exception As we execute real mode guests in VM86 mode, exception have to be reinjected appropriately when the guest triggered them. For this purpose the patch adopts the real-mode injection pattern used in vmx_inject_irq to vmx_queue_exception, additionally taking care that the IP is set correctly for #BP exceptions. Furthermore it extends handle_rmode_exception to reinject all those exceptions that can be raised in real mode. This fixes the execution of himem.exe from FreeDOS and also makes its debug.com work properly. Note that guest debugging in real mode is broken now. This has to be fixed by the scheduled debugging infrastructure rework (will be done once base patches for QEMU have been accepted). Signed-off-by: Jan Kiszka Signed-off-by: Avi Kivity commit 2fef3c8f85aef828312d84e670b3017f30babcbc Author: Jan Kiszka Date: Sun Jul 13 13:40:55 2008 +0200 KVM: Consolidate XX_VECTOR defines Signed-off-by: Jan Kiszka Signed-off-by: Avi Kivity commit 94a8c3c2437c8946f1b6c8e0b2c560a7db8ed3c6 Author: Yinghai Lu Date: Sun Jul 13 22:19:35 2008 -0700 x86: let 32bit use apic_ops too - fix fix for pv - clean up the namespace there too. Signed-off-by: Yinghai Lu Cc: Suresh Siddha Signed-off-by: Ingo Molnar commit 404571525db92bafeddb0cf9febb21aac6613dca Author: Jesper Nilsson Date: Mon Jul 14 08:59:48 2008 +0200 [CRIS] Rename boot-linkscripts and fix the path to them. This makes the CRIS-port directories follow the same naming convention as the rest of the kernel. Signed-off-by: Jesper Nilsson commit 4f962d4d65923d7b722192e729840cfb79af0a5a Author: Ingo Molnar Date: Sun Jul 13 21:42:44 2008 +0200 stackprotector: remove self-test turns out gcc generates such stackprotector-failure sequences in certain circumstances: movq -8(%rbp), %rax # D.16032, xorq %gs:40, %rax #, jne .L17 #, leave ret .L17: call __stack_chk_fail # .size __stack_chk_test_func, .-__stack_chk_test_func .section .init.text,"ax",@progbits .type panic_setup, @function panic_setup: pushq %rbp # note that there's no jump back to the failing context after the call to __stack_chk_fail - i.e. it has a ((noreturn)) attribute. Which is fair enough in the normal case but kills the self-test. (as we cannot reliably return in the self-test) Signed-off-by: Ingo Molnar commit af9ff7868f0f76d3364351b1641b9dfa99588e77 Author: Arjan van de Ven Date: Sat Jul 12 09:36:38 2008 -0700 x86: simplify stackprotector self-check Clean up the code by removing no longer needed code; make sure the pda is updated and kept in sync Signed-off-by: Arjan van de Ven Signed-off-by: Ingo Molnar commit a10cfebe86cf85a1d2ab02fccbc1e8c2b3eb92b5 Author: Avi Kivity Date: Mon Jul 7 14:45:39 2008 +0300 KVM: Consolidate PIC isr clearing into a function Signed-off-by: Avi Kivity commit 46e1bd891eab737bf5c517e8e981baff2a9fe648 Author: Avi Kivity Date: Sun Jul 13 11:33:54 2008 +0300 KVM: MMU: Fix potential race setting upper shadow ptes on nonpae hosts The direct mapped shadow code (used for real mode and two dimensional paging) sets upper-level ptes using direct assignment rather than calling set_shadow_pte(). A nonpae host will split this into two writes, which opens up a race if another vcpu accesses the same memory area. Fix by calling set_shadow_pte() instead of assigning directly. Noticed by Izik Eidus. Signed-off-by: Avi Kivity commit 6ba894d6ef4e01ded305d5a3243d9e3e57e3144c Author: Glauber Costa Date: Thu Jul 10 17:08:15 2008 -0300 KVM: x86 emulator: emulate clflush If the guest issues a clflush in a mmio address, the instruction can trap into the hypervisor. Currently, we do not decode clflush properly, causing the guest to hang. This patch fixes this emulating clflush (opcode 0f ae). Signed-off-by: Glauber Costa Signed-off-by: Avi Kivity commit 117a848348642fa9d45ba7591050262bbef99faf Author: Mohammed Gamal Date: Sat Jul 12 16:02:08 2008 +0300 KVM: VMX: Remove redundant check in handle_rmode_exception Since checking for vcpu->arch.rmode.active is already done whenever we call handle_rmode_exception(), checking it inside the function is redundant. Signed-off-by: Mohammed Gamal Signed-off-by: Avi Kivity commit d537cd48bde7d2c6f505fde5bf2cf27d45779227 Author: Vegard Nossum Date: Sat Jul 12 23:25:09 2008 +0200 kmemcheck: remove unnecessary tests in the slab allocator If the page is tracked, we don't need to check whether the cache supports tracking; it should never happen that a tracked page can belong to a non-tracked cache. Signed-off-by: Vegard Nossum Signed-off-by: Ingo Molnar commit a3ffadbe796c8b251ec602b621206f980eb1f0dd Author: Vegard Nossum Date: Sat Jul 12 23:18:43 2008 +0200 kmemcheck: use capital Y/N in kconfig help-texts This is consistent with other kconfig help-texts. Signed-off-by: Vegard Nossum Signed-off-by: Ingo Molnar commit 16984967d4849a3a850b52033df75d790a7b1ee9 Author: Vegard Nossum Date: Sat Jul 12 23:13:52 2008 +0200 kmemcheck: mark SMP support BROKEN It was recently discovered that our SMP support is in fact broken; if the NMI watchdog is enabled, the machine will hang at boot, with the message "Testing NMI watchdog". Most likely we're getting an extra NMI (or missing one) and as a result we might be waiting for a "phantom" CPU, i.e. one that doesn't exist in the first place, because we bumped the counter one time too many or one time too few. Signed-off-by: Vegard Nossum Signed-off-by: Ingo Molnar commit 872d08e2995ec8badd8eadc2b04967ba1bf9ed75 Author: Vegard Nossum Date: Sat Jul 12 23:10:47 2008 +0200 kmemcheck: constrain tracking to non-debugged caches kmemcheck really cannot be used in conjunction with SLAB debugging or SLUB debugging. SLAB debugging is controlled by a config option, so we can express the (inverse) dependency there, while SLAB debugging may be toggled for the different caches at run-time. Signed-off-by: Vegard Nossum Signed-off-by: Ingo Molnar commit fbd013adab160d9ee596647d41d7298a61e3f44d Author: Vegard Nossum Date: Sat Jul 12 14:11:33 2008 +0200 kmemcheck: fix use of uninitialized spinlock Without this, a "bad spinlock magic" message will appear quite early during boot (the first use of this spinlock). Signed-off-by: Vegard Nossum Signed-off-by: Ingo Molnar commit f910a9dc7c865896815e2a95fe33363e9522f277 Author: Yinghai Lu Date: Sat Jul 12 01:01:20 2008 -0700 x86: make 64bit have get_apic_id generalize the x2apic code some more. let read_apic_id become a macro (later on a function/inline) GET_APIC_ID(apic_read(APIC_ID)) +#define read_apic_id() (GET_APIC_ID(apic_read(APIC_ID))) instead of this weird construct: -#define read_apic_id (genapic->read_apic_id) Signed-off-by: Yinghai Lu Cc: Suresh Siddha Signed-off-by: Ingo Molnar commit 4c9961d56ec20c27ec5d02e49fd7427748312741 Author: Yinghai Lu Date: Fri Jul 11 18:44:16 2008 -0700 x86: make read_apic_id return final apicid also remove GET_APIC_ID when read_apic_id is used. need to apply after [PATCH] x86: mach_apicdef.h need to include before smp.h Signed-off-by: Yinghai Lu Cc: Suresh Siddha Signed-off-by: Ingo Molnar commit 4696ca5bfd2697f5686f96d59cf0b6de14869b4e Author: Yinghai Lu Date: Fri Jul 11 18:43:10 2008 -0700 x86: mach_apicdef.h need to include before smp.h smp.h internal has include, so need to include that at first when genericarch use them need to have different apicdef.h Signed-off-by: Yinghai Lu Cc: Suresh Siddha Signed-off-by: Ingo Molnar commit c535b6a1a685eb23f96e2c221777d6c1e05080d5 Author: Yinghai Lu Date: Fri Jul 11 18:41:54 2008 -0700 x86: let 32bit use apic_ops too Signed-off-by: Yinghai Lu Cc: Suresh Siddha Signed-off-by: Ingo Molnar commit af9d13887f9e3699bbc852c39b076d30bb9dff2f Author: Suresh Siddha Date: Fri Jul 11 13:11:57 2008 -0700 x2apic: kernel-parameter documentation for "x2apic_phys" Signed-off-by: Suresh Siddha Cc: akpm@linux-foundation.org Signed-off-by: Ingo Molnar commit ad66dd340f561bdde2285992314d9e4fd9b6191e Author: Suresh Siddha Date: Fri Jul 11 13:11:56 2008 -0700 x2apic: xen64 paravirt basic apic ops Define the Xen specific basic apic ops, in additon to paravirt apic ops, with some misc warning fixes. Signed-off-by: Suresh Siddha Cc: Jeremy Fitzhardinge Cc: akpm@linux-foundation.org Signed-off-by: Ingo Molnar commit 277d1f5846d84e16760131a93b7a67ebfa8eded4 Author: Suresh Siddha Date: Fri Jul 11 13:11:55 2008 -0700 x2apic: uninline uv_init_apic_ldr() Andrew says: > There's no point in declaring it inline if it's always called indirectly. And point taken! Signed-off-by: Suresh Siddha Cc: akpm@linux-foundation.org Signed-off-by: Ingo Molnar commit 372e92d8b3e433888bf76c36f1c7e1405eae1584 Author: Suresh Siddha Date: Thu Jul 10 14:56:18 2008 -0700 x64, x2apic/intr-remap: Interrupt-remapping and x2apic support On Thu, Jul 10, 2008 at 12:53:20PM -0700, Ingo Molnar wrote: > > Btw., i threw it at the -tip test-cluster and got back a quick build > bugreport: > > arch/x86/xen/enlighten.c: In function 'xen_patch': > arch/x86/xen/enlighten.c:1084: warning: label 'patch_site' defined but not used > arch/x86/xen/enlighten.c: At top level: > arch/x86/xen/enlighten.c:1272: error: expected identifier before '(' token > arch/x86/xen/enlighten.c:1273: error: expected '}' before '.' token > arch/x86/kernel/paravirt.c:376:2: error: invalid preprocessing directive > #ifndedarch/x86/kernel/paravirt.c:384:2: error: #endif without #if > > with this config: > > http://redhat.com/~mingo/misc/config-Thu_Jul_10_21_43_28_CEST_2008.bad fix the typo. Signed-off-by: Suresh Siddha Cc: "Siddha Cc: Suresh B" Cc: "akpm@linux-foundation.org" Cc: "arjan@linux.intel.com" Cc: "andi@firstfloor.org" Cc: "ebiederm@xmission.com" Cc: "jbarnes@virtuousgeek.org" Cc: "steiner@sgi.com" Cc: jeremy@goop.org Signed-off-by: Ingo Molnar commit 9fa8c481b55e80edd8c637573f87853bb6b600f5 Author: Suresh Siddha Date: Thu Jul 10 11:17:00 2008 -0700 x64, x2apic/intr-remap: introduce CONFIG_INTR_REMAP Signed-off-by: Suresh Siddha Cc: akpm@linux-foundation.org Cc: arjan@linux.intel.com Cc: andi@firstfloor.org Cc: ebiederm@xmission.com Cc: jbarnes@virtuousgeek.org Cc: steiner@sgi.com Signed-off-by: Ingo Molnar commit 2d9579a124d746a3e0e0ba45e57d80800ee80807 Author: Suresh Siddha Date: Thu Jul 10 11:16:59 2008 -0700 x64, x2apic/intr-remap: support for x2apic physical mode support x2apic Physical mode support. By default we will use x2apic cluster mode. x2apic physical mode can be selected using "x2apic_phys" boot parameter. Signed-off-by: Suresh Siddha Cc: akpm@linux-foundation.org Cc: arjan@linux.intel.com Cc: andi@firstfloor.org Cc: ebiederm@xmission.com Cc: jbarnes@virtuousgeek.org Cc: steiner@sgi.com Signed-off-by: Ingo Molnar commit 6e1cb38a2aef7680975e71f23de187859ee8b158 Author: Suresh Siddha Date: Thu Jul 10 11:16:58 2008 -0700 x64, x2apic/intr-remap: add x2apic support, including enabling interrupt-remapping x2apic support. Interrupt-remapping must be enabled before enabling x2apic, this is needed to ensure that IO interrupts continue to work properly after the cpu mode is changed to x2apic(which uses 32bit extended physical/cluster apic id). On systems where apicid's are > 255, BIOS can handover the control to OS in x2apic mode. Or if the OS handover was in legacy xapic mode, check if it is capable of x2apic mode. And if we succeed in enabling Interrupt-remapping, then we can enable x2apic mode in the CPU. Signed-off-by: Suresh Siddha Cc: akpm@linux-foundation.org Cc: arjan@linux.intel.com Cc: andi@firstfloor.org Cc: ebiederm@xmission.com Cc: jbarnes@virtuousgeek.org Cc: steiner@sgi.com Signed-off-by: Ingo Molnar commit 75c46fa61bc5b4ccd20a168ff325c58771248fcd Author: Suresh Siddha Date: Thu Jul 10 11:16:57 2008 -0700 x64, x2apic/intr-remap: MSI and MSI-X support for interrupt remapping infrastructure MSI and MSI-X support for interrupt remapping infrastructure. MSI address register will be programmed with interrupt-remapping table entry(IRTE) index and the IRTE will contain information about the vector, cpu destination, etc. For MSI-X, all the IRTE's will be consecutively allocated in the table, and the address registers will contain the starting index to the block and the data register will contain the subindex with in that block. This also introduces a new irq_chip for cleaner irq migration (in the process context as opposed to the current irq migration in the context of an interrupt. interrupt-remapping infrastructure will help us achieve this). As MSI is edge triggered, irq migration is a simple atomic update(of vector and cpu destination) of IRTE and flushing the hardware cache. Signed-off-by: Suresh Siddha Cc: akpm@linux-foundation.org Cc: arjan@linux.intel.com Cc: andi@firstfloor.org Cc: ebiederm@xmission.com Cc: jbarnes@virtuousgeek.org Cc: steiner@sgi.com Signed-off-by: Ingo Molnar commit 89027d35aa5b8f45ce0f7fa0911db85b46563da0 Author: Suresh Siddha Date: Thu Jul 10 11:16:56 2008 -0700 x64, x2apic/intr-remap: IO-APIC support for interrupt-remapping IO-APIC support in the presence of interrupt-remapping infrastructure. IO-APIC RTE will be programmed with interrupt-remapping table entry(IRTE) index and the IRTE will contain information about the vector, cpu destination, trigger mode etc, which traditionally was present in the IO-APIC RTE. Introduce a new irq_chip for cleaner irq migration (in the process context as opposed to the current irq migration in the context of an interrupt. interrupt-remapping infrastructure will help us achieve this cleanly). For edge triggered, irq migration is a simple atomic update(of vector and cpu destination) of IRTE and flush the hardware cache. For level triggered, we need to modify the io-apic RTE aswell with the update vector information, along with modifying IRTE with vector and cpu destination. So irq migration for level triggered is little bit more complex compared to edge triggered migration. But the good news is, we use the same algorithm for level triggered migration as we have today, only difference being, we now initiate the irq migration from process context instead of the interrupt context. In future, when we do a directed EOI (combined with cpu EOI broadcast suppression) to the IO-APIC, level triggered irq migration will also be as simple as edge triggered migration and we can do the irq migration with a simple atomic update to IO-APIC RTE. TBD: some tests/changes needed in the presence of fixup_irqs() for level triggered irq migration. Signed-off-by: Suresh Siddha Cc: akpm@linux-foundation.org Cc: arjan@linux.intel.com Cc: andi@firstfloor.org Cc: ebiederm@xmission.com Cc: jbarnes@virtuousgeek.org Cc: steiner@sgi.com Signed-off-by: Ingo Molnar commit 5c520a6724e912a7e6153b7597192edad6752750 Author: Suresh Siddha Date: Thu Jul 10 11:16:55 2008 -0700 x64, x2apic/intr-remap: setup init_apic_ldr for UV Signed-off-by: Suresh Siddha Signed-off-by: Jack Steiner Cc: akpm@linux-foundation.org Cc: arjan@linux.intel.com Cc: andi@firstfloor.org Cc: ebiederm@xmission.com Cc: jbarnes@virtuousgeek.org Cc: steiner@sgi.com Signed-off-by: Ingo Molnar commit 12a67cf6851871ca8df42025c94f140c303d0f7f Author: Suresh Siddha Date: Thu Jul 10 11:16:54 2008 -0700 x64, x2apic/intr-remap: x2apic cluster mode support x2apic cluster mode support. Signed-off-by: Suresh Siddha Cc: akpm@linux-foundation.org Cc: arjan@linux.intel.com Cc: andi@firstfloor.org Cc: ebiederm@xmission.com Cc: jbarnes@virtuousgeek.org Cc: steiner@sgi.com Signed-off-by: Ingo Molnar commit cff73a6ffaed726780b001937d2a42efde553922 Author: Suresh Siddha Date: Thu Jul 10 11:16:53 2008 -0700 x64, x2apic/intr-remap: introcude self IPI to genapic routines Introduce self IPI op for genapic. Signed-off-by: Suresh Siddha Cc: akpm@linux-foundation.org Cc: arjan@linux.intel.com Cc: andi@firstfloor.org Cc: ebiederm@xmission.com Cc: jbarnes@virtuousgeek.org Cc: steiner@sgi.com Signed-off-by: Ingo Molnar commit 13c88fb58d0112d47f7839f24a755715c6218822 Author: Suresh Siddha Date: Thu Jul 10 11:16:52 2008 -0700 x64, x2apic/intr-remap: x2apic ops for x2apic mode support x2apic ops for x2apic mode support. This uses MSR interface and differs slightly from the xapic register layout. Signed-off-by: Suresh Siddha Cc: akpm@linux-foundation.org Cc: arjan@linux.intel.com Cc: andi@firstfloor.org Cc: ebiederm@xmission.com Cc: jbarnes@virtuousgeek.org Cc: steiner@sgi.com Signed-off-by: Ingo Molnar commit 1cb11583a6c4ceda7426eb36f7bf0419da8dfbc2 Author: Suresh Siddha Date: Thu Jul 10 11:16:51 2008 -0700 x64, x2apic/intr-remap: disable DMA-remapping if Interrupt-remapping is detected (temporary quirk) Interrupt-remapping enables queued invalidation. And once queued invalidation is enabled, IOTLB invalidation also needs to use the queued invalidation mechanism and the register based IOTLB invalidation doesn't work. For now, Support for IOTLB invalidation using queued invalidation is missing. Meanwhile, disable DMA-remapping, if Interrupt-remapping support is detected. For the meanwhile, if someone wants to really enable DMA-remapping, they can use nox2apic, which will disable interrupt-remapping and as such doesn't enable queued invalidation. And given that none of the release platforms support intr-remapping yet, we should be ok for this temporary hack. Signed-off-by: Suresh Siddha Cc: akpm@linux-foundation.org Cc: arjan@linux.intel.com Cc: andi@firstfloor.org Cc: ebiederm@xmission.com Cc: jbarnes@virtuousgeek.org Cc: steiner@sgi.com Signed-off-by: Ingo Molnar commit 32e1d0a0651004f5fe47f85a2a5c725ad579a90c Author: Suresh Siddha Date: Thu Jul 10 11:16:50 2008 -0700 x64, x2apic/intr-remap: cpuid bits for x2apic feature cpuid feature for x2apic. Signed-off-by: Suresh Siddha Cc: akpm@linux-foundation.org Cc: arjan@linux.intel.com Cc: andi@firstfloor.org Cc: ebiederm@xmission.com Cc: jbarnes@virtuousgeek.org Cc: steiner@sgi.com Signed-off-by: Ingo Molnar commit 1b374e4d6f8b3eb2fcd034fcc24ea8ba1dfde7aa Author: Suresh Siddha Date: Thu Jul 10 11:16:49 2008 -0700 x64, x2apic/intr-remap: basic apic ops support Introduce basic apic operations which handle the apic programming. This will be used later to introduce another specific operations for x2apic. For the perfomance critial accesses like IPI's, EOI etc, we use the native operations as they are already referenced by different indirections like genapic, irq_chip etc. 64bit Paravirt ops can also define their apic operations accordingly. Signed-off-by: Suresh Siddha Cc: akpm@linux-foundation.org Cc: arjan@linux.intel.com Cc: andi@firstfloor.org Cc: ebiederm@xmission.com Cc: jbarnes@virtuousgeek.org Cc: steiner@sgi.com Signed-off-by: Ingo Molnar commit 2d7a66d02e11af9ab8e16c76d22767e622b4e3d7 Author: Suresh Siddha Date: Fri Jul 11 14:24:19 2008 -0700 x64, x2apic/intr-remap: Interrupt-remapping and x2apic support, fix Yinghai Lu wrote: > Setting APIC routing to physical flat > Kernel panic - not syncing: Boot APIC ID in local APIC unexpected (0 vs 4) > Pid: 1, comm: swapper Not tainted 2.6.26-rc9-tip-01763-g74f94b1-dirty #320 > > Call Trace: > [] ? set_cpu_sibling_map+0x38c/0x3bd > [] ? read_xapic_id+0x25/0x3e > [] ? verify_local_APIC+0x139/0x1b9 > [] ? read_xapic_id+0x25/0x3e > [] ? native_smp_prepare_cpus+0x224/0x2e9 > [] ? kernel_init+0x64/0x341 > [] ? child_rip+0xa/0x11 > [] ? kernel_init+0x0/0x341 > [] ? child_rip+0x0/0x11 > > > guess read_apic_id changing cuase some problem... genapic's read_apic_id() returns the actual apic id extracted from the APIC_ID register. And in some cases like UV, read_apic_id() returns completely different values from APIC ID register. Use the native apic register read, rather than genapic read_apic_id() in verify_local_APIC() And also, lapic_suspend() should also use native apic register read. Reported-by: Yinghai Lu Signed-off-by: Suresh Siddha Cc: "akpm@linux-foundation.org" Cc: "arjan@linux.intel.com" Cc: "andi@firstfloor.org" Cc: "ebiederm@xmission.com" Cc: "jbarnes@virtuousgeek.org" Cc: "steiner@sgi.com" Cc: "jeremy@goop.org" Signed-off-by: Ingo Molnar commit 0c81c746f9bdbfaafe64322d540c8b7b59c27314 Author: Suresh Siddha Date: Thu Jul 10 11:16:48 2008 -0700 x64, x2apic/intr-remap: introduce read_apic_id() to genapic routines Move the read_apic_id() to genapic routines. Signed-off-by: Suresh Siddha Cc: akpm@linux-foundation.org Cc: arjan@linux.intel.com Cc: andi@firstfloor.org Cc: ebiederm@xmission.com Cc: jbarnes@virtuousgeek.org Cc: steiner@sgi.com Signed-off-by: Ingo Molnar commit 4dc2f96cacd1e74c688f94348a3bfd0a980817d5 Author: Suresh Siddha Date: Thu Jul 10 11:16:47 2008 -0700 x64, x2apic/intr-remap: ioapic routines which deal with initial io-apic RTE setup Generic ioapic specific routines which be used later during enabling interrupt-remapping. Signed-off-by: Suresh Siddha Cc: akpm@linux-foundation.org Cc: arjan@linux.intel.com Cc: andi@firstfloor.org Cc: ebiederm@xmission.com Cc: jbarnes@virtuousgeek.org Cc: steiner@sgi.com Signed-off-by: Ingo Molnar commit d94d93ca5cc36cd78c532def62772c98fe8ba5d7 Author: Suresh Siddha Date: Thu Jul 10 11:16:46 2008 -0700 x64, x2apic/intr-remap: 8259 specific mask/unmask routines 8259 specific mask/unmask routines which be used later while enabling interrupt-remapping. Signed-off-by: Suresh Siddha Cc: akpm@linux-foundation.org Cc: arjan@linux.intel.com Cc: andi@firstfloor.org Cc: ebiederm@xmission.com Cc: jbarnes@virtuousgeek.org Cc: steiner@sgi.com Signed-off-by: Ingo Molnar commit 72b1e22dfcad1daca6906148fd956ffe404bb0bc Author: Suresh Siddha Date: Thu Jul 10 11:16:45 2008 -0700 x64, x2apic/intr-remap: generic irq migration support from process context Generic infrastructure for migrating the irq from the process context in the presence of CONFIG_GENERIC_PENDING_IRQ. This will be used later for migrating irq in the presence of interrupt-remapping. Signed-off-by: Suresh Siddha Cc: akpm@linux-foundation.org Cc: arjan@linux.intel.com Cc: andi@firstfloor.org Cc: ebiederm@xmission.com Cc: jbarnes@virtuousgeek.org Cc: steiner@sgi.com Signed-off-by: Ingo Molnar commit b6fcb33ad6c05f152a672f7c96c1fab006527b80 Author: Suresh Siddha Date: Thu Jul 10 11:16:44 2008 -0700 x64, x2apic/intr-remap: routines managing Interrupt remapping table entries. Routines handling the management of interrupt remapping table entries. Signed-off-by: Suresh Siddha Cc: akpm@linux-foundation.org Cc: arjan@linux.intel.com Cc: andi@firstfloor.org Cc: ebiederm@xmission.com Cc: jbarnes@virtuousgeek.org Cc: steiner@sgi.com Signed-off-by: Ingo Molnar commit 2ae21010694e56461a63bfc80e960090ce0a5ed9 Author: Suresh Siddha Date: Thu Jul 10 11:16:43 2008 -0700 x64, x2apic/intr-remap: Interrupt remapping infrastructure Interrupt remapping (part of Intel Virtualization Tech for directed I/O) infrastructure. Signed-off-by: Suresh Siddha Cc: akpm@linux-foundation.org Cc: arjan@linux.intel.com Cc: andi@firstfloor.org Cc: ebiederm@xmission.com Cc: jbarnes@virtuousgeek.org Cc: steiner@sgi.com Signed-off-by: Ingo Molnar commit fe962e90cb17a8426e144dee970e77ed789d98ee Author: Suresh Siddha Date: Thu Jul 10 11:16:42 2008 -0700 x64, x2apic/intr-remap: Queued invalidation infrastructure (part of VT-d) Queued invalidation (part of Intel Virtualization Technology for Directed I/O architecture) infrastructure. This will be used for invalidating the interrupt entry cache in the case of Interrupt-remapping and IOTLB invalidation in the case of DMA-remapping. Signed-off-by: Suresh Siddha Cc: akpm@linux-foundation.org Cc: arjan@linux.intel.com Cc: andi@firstfloor.org Cc: ebiederm@xmission.com Cc: jbarnes@virtuousgeek.org Cc: steiner@sgi.com Signed-off-by: Ingo Molnar commit cf1337f0447e5be8e66daa944f0ea3bcac2b6179 Author: Suresh Siddha Date: Thu Jul 10 11:16:41 2008 -0700 x64, x2apic/intr-remap: move IOMMU_WAIT_OP() macro to intel-iommu.h move IOMMU_WAIT_OP() macro to header file. This will be used by both DMA-remapping and Intr-remapping. Signed-off-by: Suresh Siddha Cc: akpm@linux-foundation.org Cc: arjan@linux.intel.com Cc: andi@firstfloor.org Cc: ebiederm@xmission.com Cc: jbarnes@virtuousgeek.org Cc: steiner@sgi.com Signed-off-by: Ingo Molnar commit ad3ad3f6a2caebf56869b83b69e23eb9fa5e0ab6 Author: Suresh Siddha Date: Thu Jul 10 11:16:40 2008 -0700 x64, x2apic/intr-remap: parse ioapic scope under vt-d structures Parse the vt-d device scope structures to find the mapping between IO-APICs and the interrupt remapping hardware units. This will be used later for enabling Interrupt-remapping for IOAPIC devices. Signed-off-by: Suresh Siddha Cc: akpm@linux-foundation.org Cc: arjan@linux.intel.com Cc: andi@firstfloor.org Cc: ebiederm@xmission.com Cc: jbarnes@virtuousgeek.org Cc: steiner@sgi.com Signed-off-by: Ingo Molnar commit 2d6b5f85bb4ca919d8ab0f30311309b53fb93bc3 Author: Suresh Siddha Date: Thu Jul 10 11:16:39 2008 -0700 x64, x2apic/intr-remap: Fix the need for RMRR in the DMA-remapping detection Presence of RMRR structures is not compulsory for enabling DMA-remapping. Signed-off-by: Suresh Siddha Signed-off-by: Yong Y Wang Cc: Yong Y Wang Cc: akpm@linux-foundation.org Cc: arjan@linux.intel.com Cc: andi@firstfloor.org Cc: ebiederm@xmission.com Cc: jbarnes@virtuousgeek.org Cc: steiner@sgi.com Signed-off-by: Ingo Molnar commit aaa9d1dd63bf89b62f4ea9f46de376ab1a3fbc6c Author: Suresh Siddha Date: Thu Jul 10 11:16:38 2008 -0700 x64, x2apic/intr-remap: use CONFIG_DMAR for DMA-remapping specific code DMA remapping specific code covered with CONFIG_DMAR in the generic code which will also be used later for enabling Interrupt-remapping. Signed-off-by: Suresh Siddha Cc: akpm@linux-foundation.org Cc: arjan@linux.intel.com Cc: andi@firstfloor.org Cc: ebiederm@xmission.com Cc: jbarnes@virtuousgeek.org Cc: steiner@sgi.com Signed-off-by: Ingo Molnar commit 1886e8a90a580f3ad343f2065c84c1b9e1dac9ef Author: Suresh Siddha Date: Thu Jul 10 11:16:37 2008 -0700 x64, x2apic/intr-remap: code re-structuring, to be used by both DMA and Interrupt remapping Allocate the iommu during the parse of DMA remapping hardware definition structures. And also, introduce routines for device scope initialization which will be explicitly called during dma-remapping initialization. These will be used for enabling interrupt remapping separately from the existing DMA-remapping enabling sequence. Signed-off-by: Suresh Siddha Cc: akpm@linux-foundation.org Cc: arjan@linux.intel.com Cc: andi@firstfloor.org Cc: ebiederm@xmission.com Cc: jbarnes@virtuousgeek.org Cc: steiner@sgi.com Signed-off-by: Ingo Molnar commit c42d9f32443397aed2d37d37df161392e6a5862f Author: Suresh Siddha Date: Thu Jul 10 11:16:36 2008 -0700 x64, x2apic/intr-remap: fix the need for sequential array allocation of iommus Clean up the intel-iommu code related to deferred iommu flush logic. There is no need to allocate all the iommu's as a sequential array. This will be used later in the interrupt-remapping patch series to allocate iommu much early and individually for each device remapping hardware unit. Signed-off-by: Suresh Siddha Cc: akpm@linux-foundation.org Cc: arjan@linux.intel.com Cc: andi@firstfloor.org Cc: ebiederm@xmission.com Cc: jbarnes@virtuousgeek.org Cc: steiner@sgi.com Signed-off-by: Ingo Molnar commit e61d98d8dad0048619bb138b0ff996422ffae53b Author: Suresh Siddha Date: Thu Jul 10 11:16:35 2008 -0700 x64, x2apic/intr-remap: Intel vt-d, IOMMU code reorganization code reorganization of the generic Intel vt-d parsing related routines and linux iommu routines specific to Intel vt-d. drivers/pci/dmar.c now contains the generic vt-d parsing related routines drivers/pci/intel_iommu.c contains the iommu routines specific to vt-d Signed-off-by: Suresh Siddha Cc: akpm@linux-foundation.org Cc: arjan@linux.intel.com Cc: andi@firstfloor.org Cc: ebiederm@xmission.com Cc: jbarnes@virtuousgeek.org Cc: steiner@sgi.com Signed-off-by: Ingo Molnar commit aa92db14270b79f0f91a9060b547a46f9e2639da Author: Arjan van de Ven Date: Fri Jul 11 05:09:55 2008 -0700 stackprotector: better self-test check stackprotector functionality by manipulating the canary briefly during bootup. far more robust than trying to overflow the stack. (which is architecture dependent, etc.) Signed-off-by: Ingo Molnar commit 1c0f4f5011829dac96347b5f84ba37c2252e1e08 Author: Avi Kivity Date: Thu Jul 3 16:14:28 2008 +0300 KVM: VMX: Move interrupt post-processing to vmx_complete_interrupts() Instead of looking at failed injections in the vm entry path, move processing to the exit path in vmx_complete_interrupts(). This simplifes the logic and removes any state that is hidden in vmx registers. Signed-off-by: Avi Kivity commit 5f070e623cfe1e3bf5901fc615423a2eec139744 Author: Avi Kivity Date: Thu Jul 3 15:17:01 2008 +0300 KVM: Add a pending interrupt queue Similar to the exception queue, this hold interrupts that have been accepted by the virtual processor core but not yet injected. Not yet used. Signed-off-by: Avi Kivity commit 192404cb647a6387a37975ce70955e2761dacfc6 Author: Avi Kivity Date: Thu Jul 3 14:50:12 2008 +0300 KVM: VMX: Fix pending exception processing The vmx code assumes that IDT-Vectoring can only be set when an exception is injected due to the exception in question. That's not true, however: if the exception is injected correctly, and later another exception occurs but its delivery is blocked due to a fault, then we will incorrectly assume the first exception was not delivered. Fix by unconditionally dequeuing the pending exception, and requeuing it (or the second exception) if we see it in the IDT-Vectoring field. Signed-off-by: Avi Kivity commit 42cc45ad55298e45b657583a1941c926c61e58de Author: Avi Kivity Date: Thu Jul 3 14:59:22 2008 +0300 KVM: Clear exception queue before emulating an instruction If we're emulating an instruction, either it will succeed, in which case any previously queued exception will be spurious, or we will requeue the same exception. Signed-off-by: Avi Kivity commit 57a9896174ab2d03d974bdf7748f7d24557f15ea Author: Avi Kivity Date: Wed Jul 2 09:28:55 2008 +0300 KVM: VMX: Move nmi injection failure processing to vm exit path Instead of processing nmi injection failure in the vm entry path, move it to the vm exit path (vm_complete_interrupts()). This separates nmi injection from nmi post-processing, and moves the nmi state from the VT state into vcpu state (new variable nmi_injected specifying an injection in progress). Signed-off-by: Avi Kivity commit bba1a6600882109be8f2cf1ffaf7b8a995666f1a Author: Avi Kivity Date: Tue Jul 1 16:20:21 2008 +0300 KVM: Move NMI IRET fault processing to new vmx_complete_interrupts() Currently most interrupt exit processing is handled on the entry path, which is confusing. Move the NMI IRET fault processing to a new function, vmx_complete_interrupts(), which is called on the vmexit path. Signed-off-by: Avi Kivity commit 85d1dd82ba98d5706f09c3b7daa146f4d758ef4e Author: Avi Kivity Date: Fri Jul 11 18:07:26 2008 +0300 KVM: MMU: Simplify kvm_mmu_zap_page() The twisty maze of conditionals can be reduced. Signed-off-by: Avi Kivity commit 5a00886b8f23799b8765542449dccfd5fea91be3 Author: Avi Kivity Date: Fri Jul 11 17:59:46 2008 +0300 KVM: MMU: Separate the code for unlinking a shadow page from its parents Place into own function, in preparation for further cleanups. Signed-off-by: Avi Kivity commit 6290157d908413650732d4836ca2277c44b75b64 Author: Marcelo Tosatti Date: Thu Jul 10 20:54:29 2008 -0300 KVM: MMU: improve invalid shadow root page handling Harden kvm_mmu_zap_page() against invalid root pages that had been shadowed from memslots that are gone. Signed-off-by: Marcelo Tosatti Signed-off-by: Avi Kivity commit cb82d4c4a1af596acb84fe253f086743a5a9de29 Author: Marcelo Tosatti Date: Thu Jul 10 20:49:31 2008 -0300 KVM: MMU: nuke shadowed pgtable pages and ptes on memslot destruction Flush the shadow mmu before removing regions to avoid stale entries. Signed-off-by: Marcelo Tosatti Signed-off-by: Avi Kivity commit cc453ceef31019dcddff453d35a608ca2c659fec Author: Avi Kivity Date: Thu Jul 10 16:53:33 2008 +0300 KVM: Prefix some x86 low level function with kvm_, to avoid namespace issues Fixes compilation with CONFIG_VMI enabled. Signed-off-by: Avi Kivity commit f8d90d947ad983d6f0788778b39eb3d32ce1320f Author: Heiko Carstens Date: Thu Jul 3 21:30:09 2008 +0200 percpu: zero based percpu build error on s390 The patch: "Zero based percpu: infrastructure to rebase the per cpu area to zero" causes this build error on !CONFIG_SMP on linux-next / s390: CC arch/s390/kernel/asm-offsets.s In file included from include/asm/percpu.h:35, from include/linux/percpu.h:9, from include/linux/rcupdate.h:39, from include/linux/pid.h:4, from include/linux/sched.h:74, from arch/s390/kernel/asm-offsets.c:7: include/asm-generic/percpu.h:78:1: warning: "SHIFT_PERCPU_PTR" redefined In file included from include/linux/percpu.h:9, from include/linux/rcupdate.h:39, from include/linux/pid.h:4, from include/linux/sched.h:74, from arch/s390/kernel/asm-offsets.c:7: include/asm/percpu.h:25:1: warning: this is the location of the previous definition Fix below. Please merge with original patch. Signed-off-by: Heiko Carstens Cc: Mike Travis Signed-off-by: Ingo Molnar commit a81a686682d6f04c842ebf9e084e30cd875f1048 Author: Amit Shah Date: Fri Jun 27 15:55:02 2008 +0300 KVM: Introduce kvm_set_irq to inject interrupts in guests This function injects an interrupt into the guest given the kvm struct, the (guest) irq number and the interrupt level. Signed-off-by: Amit Shah Signed-off-by: Avi Kivity commit 982af90ba64f01efce0dd23d1fcd32ec3f3ae29e Author: Ben-Ami Yassour Date: Sun Jul 6 17:15:07 2008 +0300 KVM: check injected pic irq within valid pic irqs Check that an injected pic irq is between 0 and 15. Signed-off-by: Ben-Ami Yassour Signed-off-by: Avi Kivity commit 214fc251236fd1d0e0f2b7c3b7b7ad5243928fa9 Author: Mohammed Gamal Date: Sun Jul 6 16:51:26 2008 +0300 KVM: x86 emulator: Fix HLT instruction This patch fixes issue encountered with HLT instruction under FreeDOS's HIMEM XMS Driver. The HLT instruction jumped directly to the done label and skips updating the EIP value, therefore causing the guest to spin endlessly on the same instruction. The patch changes the instruction so that it writes back the updated EIP value. Signed-off-by: Mohammed Gamal Signed-off-by: Avi Kivity commit 3ae2bf36c1db99d56ee413f13aaf1336121ef235 Author: Avi Kivity Date: Sun Jul 6 15:48:31 2008 +0300 KVM: Apply the kernel sigmask to vcpus blocked due to being uninitialized Signed-off-by: Avi Kivity commit b85e7fd7e03f73927190581ca1a8dd7ddfafdf49 Author: Sheng Yang Date: Sun Jul 6 19:16:51 2008 +0800 KVM: VMX: Add ept_sync_context in flush_tlb Fix a potention issue caused by kvm_mmu_slot_remove_write_access(). The old behavior don't sync EPT TLB with modified EPT entry, which result in inconsistent content of EPT TLB and EPT table. Signed-off-by: Sheng Yang Signed-off-by: Avi Kivity commit dfed967e2c690f1737b98940152e3e2655e6ab42 Author: Marcelo Tosatti Date: Thu Jul 3 18:33:02 2008 -0300 KVM: mmu_shrink: kvm_mmu_zap_page requires slots_lock to be held kvm_mmu_zap_page() needs slots lock held (rmap_remove->gfn_to_memslot, for example). Since kvm_lock spinlock is held in mmu_shrink(), do a non-blocking down_read_trylock(). Untested. Signed-off-by: Avi Kivity commit bb461f4a0354fc6690201e4d6ae7986472d74772 Author: Adrian Bunk Date: Tue Jul 1 01:19:19 2008 +0300 x86: KVM guest: make kvm_smp_prepare_boot_cpu() static This patch makes the needlessly global kvm_smp_prepare_boot_cpu() static. Signed-off-by: Adrian Bunk Signed-off-by: Avi Kivity commit ec7c27790e75397e1e91488a18beadc60926e818 Author: Joerg Roedel Date: Wed Jul 2 16:02:11 2008 +0200 KVM: SVM: fix suspend/resume support On suspend the svm_hardware_disable function is called which frees all svm_data variables. On resume they are not re-allocated. This patch removes the deallocation of svm_data from the hardware_disable function to the hardware_unsetup function which is not called on suspend. Signed-off-by: Joerg Roedel Signed-off-by: Avi Kivity commit caa03c6696f78684a8396c63518fc84ed5922d44 Author: Hollis Blanchard Date: Tue Jul 1 16:23:49 2008 -0500 KVM: Move KVM TRACE DEFINITIONS to common header Move KVM trace definitions from x86 specific kvm headers to common kvm headers to create a cross-architecture numbering scheme for trace events. This means the kvmtrace_format userspace tool won't need to know which architecture produced the log file being processed. Signed-off-by: Jerone Young Signed-off-by: Hollis Blanchard Signed-off-by: Avi Kivity commit 8c120fae053747d0d44e98f6bbb58c77baafe127 Author: Mark McLoughlin Date: Fri Jul 4 18:23:15 2008 +0100 KVM: IOAPIC: Fix level-triggered irq injection hang The "remote_irr" variable is used to indicate an interrupt which has been received by the LAPIC, but not acked. In our EOI handler, we unset remote_irr and re-inject the interrupt if the interrupt line is still asserted. However, we do not set remote_irr here, leading to a situation where if kvm_ioapic_set_irq() is called, then we go ahead and call ioapic_service(). This means that IRR is re-asserted even though the interrupt is currently in service (i.e. LAPIC IRR is cleared and ISR/TMR set) The issue with this is that when the currently executing interrupt handler finishes and writes LAPIC EOI, then TMR is unset and EOI sent to the IOAPIC. Since IRR is now asserted, but TMR is not, then when the second interrupt is handled, no EOI is sent and if there is any pending interrupt, it is not re-injected. This fixes a hang only seen while running mke2fs -j on an 8Gb virtio disk backed by a fully sparse raw file, with aliguori "avoid fragmented virtio-blk transfers by copying" changes. Signed-off-by: Mark McLoughlin Acked-by: Marcelo Tosatti Signed-off-by: Avi Kivity commit cefabe0a34919fded5dcc93f2857b0e2d666c53e Author: Anthony Liguori Date: Thu Jul 3 19:02:36 2008 +0300 x86: KVM guest: Add memory clobber to hypercalls Hypercalls can modify arbitrary regions of memory. Make sure to indicate this in the clobber list. This fixes a hang when using KVM_GUEST kernel built with GCC 4.3.0. This was originally spotted and analyzed by Marcelo. Signed-off-by: Anthony Liguori Signed-off-by: Avi Kivity commit 9154fb8731388041c448c3838c548f36b67ed9af Author: Avi Kivity Date: Wed Jul 2 16:41:50 2008 +0300 KVM: Fix bit accessor warnings in register accessor patch Signed-off-by: Avi Kivity commit ee53ed996bb2b50ed36471c160be2c9547f95052 Author: Vegard Nossum Date: Tue Jul 1 11:48:26 2008 +0200 kmemcheck: use the proper comment style Signed-off-by: Vegard Nossum commit 9ae6ef1ca46de6bfc35c7414b14efeac6c95c5e3 Author: Vegard Nossum Date: Tue Jul 1 10:47:02 2008 +0200 softirq: raise the right softirq Without this patch, tasklet_hi_schedule_first() would raise the wrong softirq and we relied upon somebody else using tasklet_hi_schedule() in order to get our tasklet scheduled. Signed-off-by: Vegard Nossum commit 1e85e220bd9cb79d9956ce71d5c197b260b3500a Author: Vegard Nossum Date: Tue Jul 1 10:45:51 2008 +0200 kmemcheck: fix sparse warnings This patch adds some missing header files (with declarations) and makes one function static. Signed-off-by: Vegard Nossum commit 23818459807a33697a89fca288c5a489d0f5e472 Author: Marcelo Tosatti Date: Fri Jun 27 14:58:02 2008 -0300 KVM: x86: accessors for guest registers As suggested by Avi, introduce accessors to read/write guest registers. This simplifies the ->cache_regs/->decache_regs interface, and improves register caching which is important for VMX, where the cost of vmcs_read/vmcs_write is significant. Signed-off-by: Marcelo Tosatti Signed-off-by: Avi Kivity commit bdfbf25220f7f601b762b3eea97721cb33baee98 Author: Christian Borntraeger Date: Fri Jun 27 15:05:40 2008 +0200 KVM: s390: rename private structures While doing some tests with our lcrash implementation I have seen a naming conflict with prefix_info in kvm_host.h vs. addrconf.h To avoid future conflicts lets rename private definitions in asm/kvm_host.h by adding the kvm_s390 prefix. Signed-off-by: Christian Borntraeger Signed-off-by: Carsten Otte Signed-off-by: Avi Kivity commit ab005a7d2e7b11f2424465c32ec631e07d3be954 Author: Christian Borntraeger Date: Fri Jun 27 15:05:38 2008 +0200 KVM: s390: Set guest storage limit and offset to sane values Some machines do not accept 16EB as guest storage limit. Lets change the default for the guest storage limit to a sane value. We also should set the guest_origin to what userspace thinks it is. This allows guests starting at an address != 0. Signed-off-by: Christian Borntraeger Signed-off-by: Carsten Otte Signed-off-by: Avi Kivity commit cb0d1248dc221f49acbb7cd10da6bc9c3c97a4b4 Author: Carsten Otte Date: Fri Jun 27 15:05:34 2008 +0200 KVM: Fix memory leak on guest exit This patch fixes a memory leak, we want to free the physmem when destroying the vm. Signed-off-by: Carsten Otte Signed-off-by: Avi Kivity commit df17183501a0ba63957cc88d065312a553415b8f Author: Carsten Otte Date: Fri Jun 27 15:05:31 2008 +0200 KVM: s390: dont allocate dirty bitmap This patch #ifdefs the bitmap array for dirty tracking. We don't have dirty tracking on s390 today, and we'd love to use our storage keys to store the dirty information for migration. Therefore, we won't need this array at all, and due to our limited amount of vmalloc space this limits the amount of guests we can run. Signed-off-by: Carsten Otte Signed-off-by: Avi Kivity commit 7d9c88f3cc121b8b82807dc0930d0363acc733ac Author: Marcelo Tosatti Date: Mon Jun 23 12:04:25 2008 -0300 KVM: move slots_lock acquision down to vapic_exit There is no need to grab slots_lock if the vapic_page will not be touched. Signed-off-by: Marcelo Tosatti Signed-off-by: Avi Kivity commit 0926128d15a7f1b82d30f1b228cc21adddf3ce0d Author: Chris Lalancette Date: Fri Jun 20 09:51:30 2008 +0200 KVM: VMX: Fake emulate Intel perfctr MSRs Older linux guests (in this case, 2.6.9) can attempt to access the performance counter MSRs without a fixup section, and injecting a GPF kills the guest. Work around by allowing the guest to write those MSRs. Tested by me on RHEL-4 i386 and x86_64 guests, as well as F-9 guests. Signed-off-by: Chris Lalancette Signed-off-by: Avi Kivity commit d7f942256c53bf4eb3daf139b4f6fdbd9e892f85 Author: Tim Shimmin Date: Fri Jun 27 13:34:42 2008 +1000 [XFS] Fix up problem when CONFIG_XFS_POSIX_ACL is not set and yet we still can use the _ACL_TYPE_* definitions in linux-2.6/xfs_xattr.c. The forthcoming generic acl code will also fix this problem. SGI-PV: 982343 SGI-Modid: xfs-linux-melb:xfs-kern:31369a Signed-off-by: Tim Shimmin Signed-off-by: Christoph Hellwig Signed-off-by: Lachlan McIlroy commit f84201c0acce582bb4df89d29b84e633d2112ece Author: Lachlan McIlroy Date: Fri Jun 27 13:34:34 2008 +1000 [XFS] Don't assert if trying to mount with blocksize > pagesize If we don't do the blocksize/PAGESIZE check before calling xfs_sb_validate_fsb_count() we can assert if we try to mount with a blocksize > pagesize. The assert is valid so leave it and just move the blocksize/pagesize check earlier. SGI-PV: 983734 SGI-Modid: xfs-linux-melb:xfs-kern:31365a Signed-off-by: Lachlan McIlroy Signed-off-by: David Chinner commit d2fabdce8fdbe67fa53a2f2c702da1a6af4db1e3 Author: Christoph Hellwig Date: Fri Jun 27 13:34:26 2008 +1000 [XFS] Don't update mtime on rename source As reported by Michael-John Turner XFS updates the mtime on the source inode of a rename call in case it's a directory and changes the parent. This doesn't make any sense, is not mentioned in the standards and not performed by any other Linux filesystems so remove it. SGI-PV: 983684 SGI-Modid: xfs-linux-melb:xfs-kern:31364a Signed-off-by: Christoph Hellwig Signed-off-by: Barry Naujok Signed-off-by: Lachlan McIlroy commit f2910a779d4736de7eb8ba9db3d033c32222ed32 Author: Lachlan McIlroy Date: Fri Jun 27 13:33:11 2008 +1000 [XFS] Allow xfs_bmbt_split() to fallback to the lowspace allocator algorithm If xfs_bmbt_split() cannot find an AG with sufficient free space to satisfy a full extent btree split then fall back to the lowspace allocator algorithm. SGI-PV: 983338 SGI-Modid: xfs-linux-melb:xfs-kern:31359a Signed-off-by: Lachlan McIlroy Signed-off-by: David Chinner commit d38bef30c01c81233b27cc24f1108b3fc30d913f Author: Lachlan McIlroy Date: Fri Jun 27 13:33:03 2008 +1000 [XFS] Restore the lowspace extent allocator algorithm When free space is running low the extent allocator may choose to allocate an extent from an AG without leaving sufficient space for a btree split when inserting the new extent (see where xfs_bmap_btalloc() sets minleft to 0). In this case the allocator will enable the lowspace algorithm which is supposed to allow further allocations (such as btree splits and newroots) to allocate from sequential AGs. This algorithm has been broken for a long time and this patch restores its behaviour. SGI-PV: 983338 SGI-Modid: xfs-linux-melb:xfs-kern:31358a Signed-off-by: Lachlan McIlroy Signed-off-by: David Chinner commit 00f54ea34725ccf82e7cd57a1a880582f8327419 Author: Lachlan McIlroy Date: Fri Jun 27 13:32:53 2008 +1000 [XFS] use minleft when allocating in xfs_bmbt_split() The bmap btree split code relies on a previous data extent allocation (from xfs_bmap_btalloc()) to find an AG that has sufficient space to perform a full btree split, when inserting the extent. When converting unwritten extents we don't allocate a data extent so a btree split will be the first allocation. In this case we need to set minleft so the allocator will pick an AG that has space to complete the split(s). SGI-PV: 983338 SGI-Modid: xfs-linux-melb:xfs-kern:31357a Signed-off-by: Lachlan McIlroy Signed-off-by: David Chinner commit 5a63654e8c01ba15b6e6a98ed84171676e00037d Author: Christoph Hellwig Date: Fri Jun 27 13:32:31 2008 +1000 [XFS] attrmulti cleanup xfs_attrmulti_by_handle currently request the size based on sizeof(attr_multiop_t) but should be using sizeof(xfs_attr_multiop_t) because that is what it is dealing with. Despite beeing wrong this actually harmless in practice because both structures are the same size on all platforms. But this sizeof was the only user of struct attr_multiop so we can just kill it. Also move the ATTR_OP_* defines xfs_attr.h into the struct xfs_attr_multiop defintion in xfs_fs.h because they are only used with that structure, and are part of the user ABI for the XFS_IOC_ATTRMULTI_BY_HANDLE ioctl. SGI-PV: 983508 SGI-Modid: xfs-linux-melb:xfs-kern:31352a Signed-off-by: Christoph Hellwig Signed-off-by: Tim Shimmin Signed-off-by: Lachlan McIlroy commit 82ba620c4dd6c52cfea85bdcc3940221a9d5d0e4 Author: Christoph Hellwig Date: Fri Jun 27 13:32:19 2008 +1000 [XFS] Check for invalid flags in xfs_attrlist_by_handle. xfs_attrlist_by_handle should only take the ATTR_ flags for the root namespaces. The ATTR_KERN* flags may change at anytime and expect special preconditions that can't be guaranteed for userspace-originating requests. For example passing down ATTR_KERNNOVAL through xfs_attrlist_by_handle will hit an assert in debug builds currently. SGI-PV: 983677 SGI-Modid: xfs-linux-melb:xfs-kern:31351a Signed-off-by: Christoph Hellwig Signed-off-by: Tim Shimmin Signed-off-by: Lachlan McIlroy commit 542954281cf22bf9ee59bcd1e4c70ae0294a1c84 Author: Barry Naujok Date: Fri Jun 27 13:32:11 2008 +1000 [XFS] Fix CI lookup in leaf-form directories Instead of comparing buffer pointers, compare buffer block numbers and don't keep buff SGI-PV: 983564 SGI-Modid: xfs-linux-melb:xfs-kern:31346a Signed-off-by: Barry Naujok Signed-off-by: Christoph Hellwig Signed-off-by: Lachlan McIlroy commit 4a25eba5fa68f90e84a596bc9b6bbb020f682b57 Author: Sheng Yang Date: Wed Jun 18 14:43:38 2008 +0800 KVM: VMX: Fix a wrong usage of vmcs_config The function ept_update_paging_mode_cr0() write to CPU_BASED_VM_EXEC_CONTROL based on vmcs_config.cpu_based_exec_ctrl. That's wrong because the variable may not consistent with the content in the CPU_BASE_VM_EXEC_CONTROL MSR. Signed-off-by: Sheng Yang Signed-off-by: Avi Kivity commit ec84e64290451062f64bfd1cf79ee524a1c455fc Author: Sheng Yang Date: Tue Jun 24 17:02:38 2008 +0800 KVM: VMX: Rename misnamed msr bits MSR_IA32_FEATURE_LOCKED is just a bit in fact, which shouldn't be prefixed with MSR_. So is MSR_IA32_FEATURE_VMXON_ENABLED. Signed-off-by: Sheng Yang Signed-off-by: Avi Kivity commit f89b2e92fe12e05b7ecfb37a12e6fa753f22dacd Author: Lachlan McIlroy Date: Wed Jun 25 13:37:05 2008 +1000 Revert "[XFS]" This reverts commit e0fe783155e4f1c7106f3579c258b9f995330c19. commit 275f3375bba3ac9da507450c1194d11fabb585eb Author: Gerd Hoffmann Date: Tue Jun 3 16:17:33 2008 +0200 KVM: Remove now unused structs from kvm_para.h The kvm_* structs are obsoleted by the pvclock_* ones. Now all users have been switched over and the old structs can be dropped. Signed-off-by: Gerd Hoffmann Signed-off-by: Avi Kivity commit 94a6f979b854ef7e7853579340b9f49999715821 Author: Gerd Hoffmann Date: Tue Jun 3 16:17:32 2008 +0200 x86: KVM guest: Use the paravirt clocksource structs and functions This patch updates the kvm host code to use the pvclock structs and functions, thereby making it compatible with Xen. The patch also fixes an initialization bug: on SMP systems the per-cpu has two different locations early at boot and after CPU bringup. kvmclock must take that in account when registering the physical address within the host. Signed-off-by: Gerd Hoffmann Signed-off-by: Avi Kivity commit 16981f3772042f00d0b137b9df3584b303232c80 Author: Gerd Hoffmann Date: Tue Jun 3 16:17:31 2008 +0200 KVM: Make kvm host use the paravirt clocksource structs This patch updates the kvm host code to use the pvclock structs. It also makes the paravirt clock compatible with Xen. Signed-off-by: Gerd Hoffmann Signed-off-by: Avi Kivity commit 38862e8b6a49597356ee100249ee2685246ee3d4 Author: Gerd Hoffmann Date: Tue Jun 3 16:17:30 2008 +0200 x86: Make xen use the paravirt clocksource structs and functions This patch updates the xen guest to use the pvclock structs and helper functions. Signed-off-by: Gerd Hoffmann Acked-by: Jeremy Fitzhardinge Signed-off-by: Avi Kivity commit 5cac89efc5ecaf964a97d9bdf6083a5caaab7cd2 Author: Gerd Hoffmann Date: Tue Jun 3 16:17:29 2008 +0200 x86: Add structs and functions for paravirt clocksource This patch adds structs for the paravirt clocksource ABI used by both xen and kvm (pvclock-abi.h). It also adds some helper functions to read system time and wall clock time from a paravirtual clocksource (pvclock.[ch]). They are based on the xen code. They are enabled using CONFIG_PARAVIRT_CLOCK. Subsequent patches of this series will put the code in use. Signed-off-by: Gerd Hoffmann Acked-by: Jeremy Fitzhardinge Signed-off-by: Avi Kivity commit 975b11af22c9256ba0cbe7aa94202d191575fdff Author: Avi Kivity Date: Tue Jun 24 11:48:49 2008 +0300 KVM: VMX: Fix host msr corruption with preemption enabled Switching msrs can occur either synchronously as a result of calls to the msr management functions (usually in response to the guest touching virtualized msrs), or asynchronously when preempting a kvm thread that has guest state loaded. If we're unlucky enough to have the two at the same time, host msrs are corrupted and the machine goes kaput on the next syscall. Most easily triggered by Windows Server 2008, as it does a lot of msr switching during bootup. Signed-off-by: Avi Kivity commit e78c00cfd5052b58a2f23a768d67ef06870a2c90 Author: Lachlan McIlroy Date: Mon Jun 23 13:34:09 2008 +1000 [XFS] Use the generic xattr methods. Add missing file fs/xfs/linux-2.6/xfs_xattr.c SGI-PV: 982343 SGI-Modid: xfs-linux-melb:xfs-kern:31234a Signed-off-by: Christoph Hellwig Signed-off-by: Tim Shimmin Signed-off-by: Lachlan McIlroy commit 447969b3df4e04574509186e1bde6e72ec766baf Author: Lachlan McIlroy Date: Mon Jun 23 13:25:53 2008 +1000 [XFS] Always reset btree cursor after an insert After a btree insert operation a cursor can be invalid due to block splits and a maybe a new root block. We reset the cursor in xfs_bmbt_insert() in the cases where we think we need to but it isn't enough as we still see assertions. Just do what we do elsewhere and reset the cursor unconditionally. Also remove the fix to revalidate the original cursor in xfs_bmbt_insert(). SGI-PV: 983336 SGI-Modid: xfs-linux-melb:xfs-kern:31342a Signed-off-by: Lachlan McIlroy Signed-off-by: David Chinner commit 0e19cabaa37d2801a848f3ce29eb29a700e30e1d Author: Lachlan McIlroy Date: Mon Jun 23 13:25:46 2008 +1000 [XFS] Convert ASSERTs to XFS_WANT_CORRUPTED_GOTOs ASSERTs are no good to us on a non-debug build so use XFS_WANT_CORRUPTED_GOTOs to report extent btree corruption ASAP. SGI-PV: 983500 SGI-Modid: xfs-linux-melb:xfs-kern:31338a Signed-off-by: Lachlan McIlroy Signed-off-by: Christoph Hellwig commit d02d76cd67e452938a3f286b282ff4f6add5cdf6 Author: Barry Naujok Date: Mon Jun 23 13:25:38 2008 +1000 [XFS] Fix returning case-preserved name with CI node form directories xfs_dir2_node_lookup() calls xfs_da_node_lookup_int() which iterates through leaf blocks containing the matching hash value for the name being looked up. Inside xfs_da_node_lookup_int(), it calls the xfs_dir2_leafn_lookup_for_entry() for each leaf block. xfs_dir2_leafn_lookup_for_entry() iterates through each matching hash/offset pair doing a name comparison to find the matching dirent. For CI mode, the state->extrablk retains the details of the block that has the CI match so xfs_dir2_node_lookup() can return the case-preserved name. The original implementation didn't retain the xfs_da_buf_t properly, so the lookup was returning a bogus name to be stored in the dentry. In the case of unlink, the bad name was passed and in debug mode, ASSERTed when it can't find the entry. SGI-PV: 983284 SGI-Modid: xfs-linux-melb:xfs-kern:31337a Signed-off-by: Barry Naujok Signed-off-by: Christoph Hellwig Signed-off-by: Lachlan McIlroy commit 22c4b48023f408bf3d62bca152cdcc838bbde0fa Author: Christoph Hellwig Date: Mon Jun 23 13:25:25 2008 +1000 [XFS] Don't update i_size for directories and special files The core kernel uses vfs_getattr to look at the inode size and similar attributes, so there is no need to keep i_size uptodate for directories or special files. This means we can remove xfs_validate_fields because the I/O path already keeps i_size uptodate for regular files. SGI-PV: 981498 SGI-Modid: xfs-linux-melb:xfs-kern:31336a Signed-off-by: Christoph Hellwig Signed-off-by: Barry Naujok Signed-off-by: Lachlan McIlroy commit 475f4d3fc047ea6d55faed3f229dc318ec79ead9 Author: Christoph Hellwig Date: Mon Jun 23 13:25:17 2008 +1000 [XFS] Merge xfs_rmdir into xfs_remove xfs_remove and xfs_rmdir are almost the same with a little more work performed in xfs_rmdir due to the . and .. entries. This patch merges xfs_rmdir into xfs_remove and performs these actions conditionally. Also clean up the error handling which was a nightmare in both versions before. SGI-PV: 981498 SGI-Modid: xfs-linux-melb:xfs-kern:31335a Signed-off-by: Christoph Hellwig Signed-off-by: Barry Naujok Signed-off-by: Lachlan McIlroy commit 277ad577640bf602d6c75cda07769caab4ed6d37 Author: Tim Shimmin Date: Mon Jun 23 13:25:09 2008 +1000 [XFS] Fix up warning for xfs_vn_listxatt's call of list_one_attr() with context count of ssize_t versus int. Change context count to be ssize_t. SGI-PV: 983395 SGI-Modid: xfs-linux-melb:xfs-kern:31333a Signed-off-by: Tim Shimmin Signed-off-by: Lachlan McIlroy commit 7197197719eb94b527c6a422bf3fb682cdf89954 Author: Lachlan McIlroy Date: Mon Jun 23 13:25:02 2008 +1000 [XFS] fix extent corruption in xfs_iext_irec_compact_full() This function is used to compact the indirect extent list by moving extents from one page to the previous to fill them up. After we move some extents to an earlier page we need to shuffle the remaining extents to the start of the page. The actual bug here is the second argument to memmove() needs to index past the extents, that were copied to the previous page, and move the remaining extents. For pages that are already full (ie ext_avail == 0) the compaction code has no net effect so don't do it. SGI-PV: 983337 SGI-Modid: xfs-linux-melb:xfs-kern:31332a Signed-off-by: Lachlan McIlroy Signed-off-by: Christoph Hellwig commit c0f47794ba870f0cd1dbe5c8fdbf56b86f5f2afa Author: Lachlan McIlroy Date: Mon Jun 23 13:23:57 2008 +1000 [XFS] make inode reclaim wait for log I/O to complete During a forced shutdown a xfs inode can be destroyed before log I/O involving that inode is complete. We need to wait for the inode to be unpinned before tearing it down. Version 2 cleans up the code a bit by relying on xfs_iflush() to do the unpinning and forced shutdown check. SGI-PV: 981240 SGI-Modid: xfs-linux-melb:xfs-kern:31326a Signed-off-by: Lachlan McIlroy Signed-off-by: David Chinner commit 35afc673a41114eb650c6ae766010160dd982a7b Author: Christoph Hellwig Date: Mon Jun 23 13:23:48 2008 +1000 [XFS] Switches xfs_vn_listxattr to set it's put_listent callback directly and not go through xfs_attr_list. SGI-PV: 983395 SGI-Modid: xfs-linux-melb:xfs-kern:31324a Signed-off-by: Christoph Hellwig Signed-off-by: Tim Shimmin Signed-off-by: Lachlan McIlroy commit a55c8e45381bcc5588a544ba73580719887372eb Author: Christoph Hellwig Date: Mon Jun 23 13:23:41 2008 +1000 [XFS] Factor out code for whether inode has attributes or not. SGI-PV: 983394 SGI-Modid: xfs-linux-melb:xfs-kern:31323a Signed-off-by: Christoph Hellwig Signed-off-by: Tim Shimmin Signed-off-by: Lachlan McIlroy commit 7a9ba9bb899933293604a2b3c5ca4f40ad5a92a8 Author: Eric Sandeen Date: Mon Jun 23 13:23:32 2008 +1000 [XFS] Pack some shortform dir2 structures for the ARM old ABI architecture. This should fix the longstanding issues with xfs and old ABI arm boxes, which lead to various asserts and xfs shutdowns, and for which an (incorrect) patch has been floating around for years. I've verified this patch by comparing the on-disk structure layouts using pahole from the dwarves package, as well as running through a bit of xfsqa under qemu-arm, modified so that the check/repair phase after each test actually executes check/repair from the x86 host, on the filesystem populated by the arm emulator. Thus far it all looks good. There are 2 other structures with extra padding at the end, but they don't seem to cause trouble. I suppose they could be packed as well: xfs_dir2_data_unused_t and xfs_dir2_sf_t. Note that userspace needs a similar treatment, and any filesystems which were running with the previous rogue "fix" will now see corruption (either in the kernel, or during xfs_repair) with this fix properly in place; it may be worth teaching xfs_repair to identify and fix that specific issue. SGI-PV: 982930 SGI-Modid: xfs-linux-melb:xfs-kern:31280a Signed-off-by: Eric Sandeen Signed-off-by: Tim Shimmin Signed-off-by: Lachlan McIlroy commit c02afc5fa7433fbbc0a045afbb472533de0758de Author: Lachlan McIlroy Date: Mon Jun 23 13:23:01 2008 +1000 [XFS] Use the generic xattr methods. Use the generic set, get and removexattr methods and supply the s_xattr array with fine-grained handlers. All XFS/Linux highlevel attr handling is rewritten from scratch and placed into fs/xfs/linux-2.6/xfs_xattr.c so that it's separated from the generic low-level code. SGI-PV: 982343 SGI-Modid: xfs-linux-melb:xfs-kern:31234a Signed-off-by: Christoph Hellwig Signed-off-by: Tim Shimmin Signed-off-by: Lachlan McIlroy commit e0fe783155e4f1c7106f3579c258b9f995330c19 Author: Lachlan McIlroy Date: Mon Jun 23 13:19:45 2008 +1000 [XFS] SGI-PV: 111111 SGI-Modid: xfs-linux-melb:xfs-kern:31210a Signed-off-by: Niv Sardi Signed-off-by: Lachlan McIlroy commit 5bafb999ca8f919b4824413c1f68990390426f70 Author: Avi Kivity Date: Sun Jun 22 16:46:22 2008 +0300 KVM: MMU: Fix printk format Signed-off-by: Avi Kivity commit 09f97990bdafbff8ace96ced5b86c31011227760 Author: Avi Kivity Date: Sun Jun 22 16:45:24 2008 +0300 KVM: MMU: When debug is enabled, make it a run-time parameter Signed-off-by: Avi Kivity commit d9a74b04adb5f733ab597b0a3e4a91b7eba732cf Author: Avi Kivity Date: Sun Jun 22 16:22:51 2008 +0300 KVM: x86 emulator: lazily evaluate segment registers Instead of prefetching all segment bases before emulation, read them at the last moment. Since most of them are unneeded, we save some cycles on Intel machines where this is a bit expensive. Signed-off-by: Avi Kivity commit f3561810b163aca5388ad550abbbc82ae5323189 Author: Joe Buehler Date: Mon Jun 9 08:55:20 2008 -0400 x86: add PCI ID for 6300ESB force hpet 00:1f.0 ISA bridge: Intel Corporation 6300ESB LPC Interface Controller (rev 02) 00:1f.0 Class 0601: 8086:25a1 (rev 02) kernel: pci 0000:00:1f.0: Force enabled HPET at 0xfed00000 kernel: hpet clockevent registered kernel: hpet0: at MMIO 0xfed00000, IRQs 2, 8, 0 kernel: hpet0: 3 64-bit timers, 14318180 Hz Signed-off-by: Ingo Molnar commit f94b733cce8d9a9bd5ed02ed5f42429ed1c15e30 Author: Akio Takebe Date: Tue Jun 17 16:22:30 2008 +0900 KVM: fix oops at guest shutdown freeing coalesced mmio page Signed-off-by: Akio Takebe Signed-off-by: Avi Kivity commit 3243b4ed817fad04e56e7b7dc78ec28dc8322ff2 Author: Krzysztof Oledzki Date: Wed Jun 4 03:40:17 2008 +0200 x86: add another PCI ID for ICH6 force-hpet Tested on Asus P5GDC-V $ lspci -n -n |grep ISA 00:1f.0 ISA bridge [0601]: Intel Corporation 82801FB/FR (ICH6/ICH6R) LPC Interface Bridge [8086:2640] (rev 03) Force enabled HPET at base address 0xfed00000 hpet clockevent registered hpet0: at MMIO 0xfed00000, IRQs 2, 8, 0 hpet0: 3 64-bit timers, 14318180 Hz Signed-off-by: Krzysztof Piotr Oledzki Signed-off-by: Ingo Molnar commit de53f0e48a1ec9880613a9bdbc5d1d3dcfada0f7 Author: Avi Kivity Date: Tue Jun 17 15:36:36 2008 -0700 KVM: ioapic: fix lost interrupt when changing a device's irq The ioapic acknowledge path translates interrupt vectors to irqs. It currently uses a first match algorithm, stopping when it finds the first redirection table entry containing the vector. That fails however if the guest changes the irq to a different line, leaving the old redirection table entry in place (though masked). Result is interrupts not making it to the guest. Fix by always scanning the entire redirection table. Signed-off-by: Avi Kivity commit a42da15b681a1fb66d9b8744f27927fb7fd23bc5 Author: Avi Kivity Date: Sun Jun 15 22:45:54 2008 -0700 KVM: x86 emulator: avoid segment base adjust for lea Signed-off-by: Avi Kivity commit 8e286983697d25ed2ef71b79b566149f63b94dd0 Author: Avi Kivity Date: Sun Jun 15 22:09:11 2008 -0700 KVM: x86 emulator: simplify rip relative decoding rip relative decoding is relative to the instruction pointer of the next instruction; by moving address adjustment until after decoding is complete, we remove the need to determine the instruction size. Signed-off-by: Avi Kivity commit 13e3d591a27c3b94a32dcc60fadaac3f48078077 Author: Avi Kivity Date: Sun Jun 15 21:53:26 2008 -0700 KVM: x86 emulator: simplify r/m decoding Consolidate the duplicated code when not in any special case. Signed-off-by: Avi Kivity commit 108bbca8a5745bd1e2d5fff8612e7c97b51cd949 Author: Avi Kivity Date: Sun Jun 15 21:23:17 2008 -0700 KVM: x86 emulator: simplify sib decoding Instead of using sparse switches, use simpler if/else sequences. Signed-off-by: Avi Kivity commit 041cda70799a3ab60011e7b463d6e7091b75b225 Author: Avi Kivity Date: Sun Jun 15 21:13:41 2008 -0700 KVM: x86 emulator: handle undecoded rex.b with r/m = 5 in certain cases x86_64 does not decode rex.b in certain cases, where the r/m field = 5. Signed-off-by: Avi Kivity commit 240b79cb97397304b90ef9b56d386a7588d3c871 Author: Mohammed Gamal Date: Sun Jun 15 19:37:38 2008 +0300 KVM: x86 emulator: emulate nop and xchg reg, acc (opcodes 0x90 - 0x97) Signed-off-by: Mohammed Gamal Signed-off-by: Avi Kivity commit 16472abdad5c179c79bf607ecd9ac54ce8bf8c84 Author: Barry Naujok Date: Mon Jun 16 12:07:41 2008 +1000 [XFS] Invalidate dentry in unlink/rmdir if in case-insensitive mode The vfs_unlink/d_delete functionality in the Linux VFS make the dentry negative if it is the only inode being referenced. Case-insensitive mode doesn't work with negative dentries, so if using CI-mode, invalidate the dentry on unlink/rmdir. SGI-PV: 983102 SGI-Modid: xfs-linux-melb:xfs-kern:31308a Signed-off-by: Barry Naujok Signed-off-by: Christoph Hellwig commit 233784e4a3a8f3a584787764dae677342138b31e Author: Vegard Nossum Date: Fri Apr 4 00:51:41 2008 +0200 kmemcheck: enable in the x86 Kconfig let it rip! Signed-off-by: Pekka Enberg Signed-off-by: Ingo Molnar Signed-off-by: Vegard Nossum commit 30532cb3c49a2a9fed94127aab26003c52398a51 Author: Pekka Enberg Date: Fri May 9 20:35:53 2008 +0200 slab: add hooks for kmemcheck We now have SLAB support for kmemcheck! This means that it doesn't matter whether one chooses SLAB or SLUB, or indeed whether Linus chooses to chuck SLAB or SLUB.. ;-) Cc: Ingo Molnar Cc: Christoph Lameter Cc: Andrew Morton Signed-off-by: Pekka Enberg Signed-off-by: Vegard Nossum commit 18fd427debcf37c06917b55295df682fd05fee76 Author: Vegard Nossum Date: Fri Apr 4 00:54:48 2008 +0200 slub: add hooks for kmemcheck Parts of this patch were contributed by Pekka Enberg but merged for atomicity. Cc: Christoph Lameter Signed-off-by: Vegard Nossum Signed-off-by: Pekka Enberg Signed-off-by: Ingo Molnar commit e6df1035b1b488cafde1e69f1a25f2706c3ac1f7 Author: Vegard Nossum Date: Sat May 31 15:56:17 2008 +0200 kmemcheck: add mm functions With kmemcheck enabled, the slab allocator needs to do this: 1. Tell kmemcheck to allocate the shadow memory which stores the status of each byte in the allocation proper, e.g. whether it is initialized or uninitialized. 2. Tell kmemcheck which parts of memory that should be marked uninitialized. There are actually a few more states, such as "not yet allocated" and "recently freed". If a slab cache is set up using the SLAB_NOTRACK flag, it will never return memory that can take page faults because of kmemcheck. If a slab cache is NOT set up using the SLAB_NOTRACK flag, callers can still request memory with the __GFP_NOTRACK flag. This does not prevent the page faults from occuring, however, but marks the object in question as being initialized so that no warnings will ever be produced for this object. Parts of this patch were contributed by Pekka Enberg but merged for atomicity. Signed-off-by: Vegard Nossum Signed-off-by: Pekka Enberg Signed-off-by: Ingo Molnar commit 862849a36e6087faac6349de0b1bcc66ff98411b Author: Pekka Enberg Date: Fri Apr 4 11:16:06 2008 +0300 x86: add hooks for kmemcheck on x86_64 This makes the necessary changes for kmemcheck to work on x86_64. Signed-off-by: Pekka Enberg Signed-off-by: Ingo Molnar Signed-off-by: Vegard Nossum commit 787ecfaa503dc63ff1831ddc74b15dad49bace1d Author: Vegard Nossum Date: Fri Apr 4 00:53:23 2008 +0200 x86: add hooks for kmemcheck The hooks that we modify are: - Page fault handler (to handle kmemcheck faults) - Debug exception handler (to hide pages after single-stepping the instruction that caused the page fault) Also redefine memset() to use the optimized version if kmemcheck is enabled. (Thanks to Pekka Enberg for minimizing the impact on the page fault handler.) Signed-off-by: Vegard Nossum Signed-off-by: Pekka Enberg Signed-off-by: Ingo Molnar commit 385e31b9eae0528bada07d16a189f3f40df23961 Author: Vegard Nossum Date: Fri Apr 4 00:51:41 2008 +0200 kmemcheck: add the kmemcheck core General description: kmemcheck is a patch to the linux kernel that detects use of uninitialized memory. It does this by trapping every read and write to memory that was allocated dynamically (e.g. using kmalloc()). If a memory address is read that has not previously been written to, a message is printed to the kernel log. (Thanks to Andi Kleen for the set_memory_4k() solution.) Signed-off-by: Vegard Nossum Signed-off-by: Pekka Enberg Signed-off-by: Ingo Molnar commit 3994d3f08b618f9c40af1d402c3e4ecec946b5dc Author: Pekka Enberg Date: Mon Apr 28 22:47:29 2008 +0300 kmemcheck: add Vegard and Pekka to MAINTAINERS Acked-by: Vegard Nossum Signed-off-by: Pekka Enberg Signed-off-by: Ingo Molnar commit 4b34d433198f97523756b267a236c803b13f3ae0 Author: Vegard Nossum Date: Wed May 21 22:53:13 2008 +0200 tasklets: new tasklet scheduling function Rationale: kmemcheck needs to be able to schedule a tasklet without touching any dynamically allocated memory _at_ _all_ (since that would lead to a recursive page fault). This tasklet is used for writing the error reports to the kernel log. The new scheduling function avoids touching any other tasklets by inserting the new tasklist as the head of the "tasklet_hi" list instead of on the tail. Also don't wake up the softirq thread lest the scheduler access some tracked memory and we go down with a recursive page fault. In this case, we'd better just wait for the maximum time of 1/HZ for the message to appear. Signed-off-by: Vegard Nossum commit c9506812f317bca0edcbc717c8fdabdd1d0a264b Author: Pekka Enberg Date: Fri May 9 20:32:44 2008 +0200 slab: move struct kmem_cache to headers Move the SLAB struct kmem_cache definition to like with SLUB so kmemcheck can access ->ctor and ->flags. Cc: Ingo Molnar Cc: Christoph Lameter Cc: Andrew Morton Signed-off-by: Pekka Enberg Signed-off-by: Vegard Nossum commit a2d8c355cab2599bd369aa30746442990b73d3f4 Author: Vegard Nossum Date: Fri Jun 13 15:31:11 2008 +0200 stacktrace: add forward-declaration struct task_struct This is needed if the header is to be free-standing. Signed-off-by: Vegard Nossum commit 5995e9b7ec563126bb93eec05cfca7b8d58f26d5 Author: Vegard Nossum Date: Tue May 20 11:15:43 2008 +0200 x86: add save_stack_trace_bp() for tracing from a specific stack frame This will help kmemcheck (and possibly other debugging tools) since we can now simply pass regs->bp to the stack tracer instead of specifying the number of stack frames to skip, which is unreliable if gcc decides to inline functions, etc. Note that this makes the API incomplete for other architectures, but I expect that those can be updated lazily, e.g. when they need it. Cc: Arjan van de Ven Signed-off-by: Vegard Nossum commit afdb7023b849cffda679fcec324ff592d7b24a51 Author: Pekka Enberg Date: Thu Apr 3 16:40:48 2008 +0300 x86: __show_registers() and __show_regs() API unification Currently the low-level function to dump user-passed registers on i386 is called __show_registers() whereas on x86-64 it's called __show_regs(). Unify the API to simplify porting of kmemcheck to x86-64. Cc: Vegard Nossum Signed-off-by: Pekka Enberg Signed-off-by: Ingo Molnar commit d660add61a69df36372c73e68d2532190ca6430c Author: Avi Kivity Date: Fri Jun 13 22:45:42 2008 +0300 KVM: Use printk_rlimit() instead of reporting emulation failures just once Emulation failure reports are useful, so allow more than one per the lifetime of the module. Signed-off-by: Avi Kivity commit c1b11ebee6bda13878562b894ee811141dd06198 Author: Avi Kivity Date: Thu Jun 12 16:54:41 2008 +0300 KVM: MMU: Fix oops on guest userspace access to guest pagetable KVM has a heuristic to unshadow guest pagetables when userspace accesses them, on the assumption that most guests do not allow userspace to access pagetables directly. Unfortunately, in addition to unshadowing the pagetables, it also oopses. This never triggers on ordinary guests since sane OSes will clear the pagetables before assigning them to userspace, which will trigger the flood heuristic, unshadowing the pagetables before the first userspace access. One particular guest, though (Xenner) will run the kernel in userspace, triggering the oops. Since the heuristic is incorrect in this case, we can simply remove it. Signed-off-by: Avi Kivity commit a6f0945d852e2038051949563349b43f3a4298e3 Author: Tan, Li Date: Fri May 23 14:54:09 2008 +0800 KVM: Support mixed endian machines Currently kvmtrace is not portable. This will prevent from copying a trace file from big-endian target to little-endian workstation for analysis. In the patch, kernel outputs metadata containing a magic number to trace log, and changes 64-bit words to be u64 instead of a pair of u32s. Signed-off-by: Tan Li Acked-by: Jerone Young Acked-by: Hollis Blanchard Signed-off-by: Avi Kivity commit a46cf8a8940ff98a5c8d8ec7d1758a22866df19b Author: Glauber Costa Date: Tue Jun 10 10:46:53 2008 -0300 KVM: Do not calculate linear rip in emulation failure report If we're not gonna do anything (case in which failure is already reported), we do not need to even bother with calculating the linear rip. Signed-off-by: Glauber Costa Signed-off-by: Avi Kivity commit b6be813ee3cc0c069cf7db0eaf0c482b235dcf64 Author: Marcelo Tosatti Date: Wed Jun 11 19:52:53 2008 -0300 KVM: only abort guest entry if timer count goes from 0->1 Only abort guest entry if the timer count went from 0->1, since for 1->2 or larger the bit will either be set already or a timer irq will have been injected. Using atomic_inc_and_test() for it also introduces an SMP barrier to the LAPIC version (thought it was unecessary because of timer migration, but guest can be scheduled to a different pCPU between exit and kvm_vcpu_block(), so there is the possibility for a race). Noticed by Avi. Signed-off-by: Marcelo Tosatti Signed-off-by: Avi Kivity commit 2167aba48285bca7d389c5a7cd2f44e6074894f9 Author: Marcelo Tosatti Date: Wed Jun 11 20:32:40 2008 -0300 KVM: MMU: large page update_pte issue with non-PAE 32-bit guests (resend) kvm_mmu_pte_write() does not handle 32-bit non-PAE large page backed guests properly. It will instantiate two 2MB sptes pointing to the same physical 2MB page when a guest large pte update is trapped. Instead of duplicating code to handle this, disallow directory level updates to happen through kvm_mmu_pte_write(), so the two 2MB sptes emulating one guest 4MB pte can be correctly created by the page fault handling path. Signed-off-by: Marcelo Tosatti Signed-off-by: Avi Kivity commit 0eba1b3c9ced926febe6ed342f05342f9cfd2471 Author: Avi Kivity Date: Thu Jun 12 14:55:23 2008 +0300 Revert "KVM: VMX: Add mechanism to detect VMentry failure" This reverts commit 36742c5470. Breaks guest rebooting. Signed-off-by: Avi Kivity commit fecf859b27a250d7dc622346a7e357b387534566 Author: Andrew Morton Date: Mon Jun 9 04:01:11 2008 -0700 KVM: ia64: fix compile error in coalesced mmio Cc: "Zhang, Xiantao" Cc: "Avi Kivity" Signed-off-by: Andrew Morton Signed-off-by: Avi Kivity commit 77764fc9db8e3a3fd456db45b2f77fed9d752be7 Author: Bernhard Walle Date: Sun Jun 8 15:46:29 2008 +0200 bootmem: add return value to reserve_bootmem_node() This patch changes the function reserve_bootmem_node() from void to int, returning -ENOMEM if the allocation fails. Signed-off-by: Bernhard Walle Signed-off-by: Ingo Molnar commit d3794979a8a80c222ce9d016a6dfc4bed36965d0 Author: Mike Travis Date: Tue Jun 3 17:30:19 2008 -0700 Zero based percpu: infrastructure to rebase the per cpu area to zero * Support an option CONFIG_HAVE_ZERO_BASED_PER_CPU to make offsets for per cpu variables to start at zero. If a percpu area starts at zero then: - We do not need RELOC_HIDE anymore - Provides for the future capability of architectures providing a per cpu allocator that returns offsets instead of pointers. The offsets would be independent of the processor so that address calculations can be done in a processor independent way. Per cpu instructions can then add the processor specific offset at the last minute possibly in an atomic instruction. The data the linker provides is different for zero based percpu segments: __per_cpu_load -> The address at which the percpu area was loaded __per_cpu_size -> The length of the per cpu area * Removes the &__per_cpu_x in lockdep. The __per_cpu_x are already pointers. There is no need to take the address. * Updates kernel/module.c to be able to deal with a percpu area that is loaded at __per_cpu_load but is accessed at __per_cpu_start. Signed-off-by: Christoph Lameter Signed-off-by: Mike Travis Signed-off-by: Ingo Molnar commit b3a0cb456d848e10b2f7b371ba05e44f1384520a Author: Mike Travis Date: Tue Jun 3 17:30:20 2008 -0700 x86: extend percpu ops to 64 bit * x86 percpu ops now will work on 64 bit too, so add the missing 8 byte cases. * Add a few atomic ops that will be useful in the future: x86_xchg_percpu() x86_cmpxchg_percpu(). x86_inc_percpu() - Increment by one can generate more efficient x86_dec_percpu() instructions and inc/dec will be supported by cpu ops later. * Use per_cpu_var() instead of per_cpu__##xxx. Signed-off-by: Christoph Lameter Signed-off-by: Mike Travis Signed-off-by: Ingo Molnar commit bb678f38b2ae91aa873576313b30acf2aab95292 Author: Oleg Nesterov Date: Sun Jun 8 21:20:43 2008 +0400 do_generic_file_read: s/EINTR/EIO/ if lock_page_killable() fails If lock_page_killable() fails because the task was killed by SIGKILL or any other fatal signal, do_generic_file_read() returns -EIO. This seems to be OK, because in fact the userspace won't see this error, the task will dequeue SIGKILL and exit. However, /sbin/init is different, it will dequeue SIGKILL, ignore it, and return to the user-space with the bogus -EIO. Change the code to return the error code from lock_page_killable(), -EINTR. This doesn't fix the bug, but perhaps makes sense anyway. Imho, with this change the code looks a bit more logical, and the "good" init should handle the spurious EINTR or short read. Afaics we can also change lock_page_killable() to return -ERESTARTNOINTR, but this can't prevent the short reads. Signed-off-by: Oleg Nesterov Signed-off-by: Ingo Molnar commit ab47a309a6afc8ecdec295df5df77daf3eb77e14 Author: Oleg Nesterov Date: Sun Jun 8 21:20:41 2008 +0400 sched: fix TASK_WAKEKILL vs SIGKILL race schedule() has the special "TASK_INTERRUPTIBLE && signal_pending()" case, this allows us to do current->state = TASK_INTERRUPTIBLE; schedule(); without fear to sleep with pending signal. However, the code like current->state = TASK_KILLABLE; schedule(); is not right, schedule() doesn't take TASK_WAKEKILL into account. This means that mutex_lock_killable(), wait_for_completion_killable(), down_killable(), schedule_timeout_killable() can miss SIGKILL (and btw the second SIGKILL has no effect). Introduce the new helper, signal_pending_state(), and change schedule() to use it. Hopefully it will have more users, that is why the task's state is passed separately. Note this "__TASK_STOPPED | __TASK_TRACED" check in signal_pending_state(). This is needed to preserve the current behaviour (ptrace_notify). I hope this check will be removed soon, but this (afaics good) change needs the separate discussion. The fast path is "(state & (INTERRUPTIBLE | WAKEKILL)) + signal_pending(p)", basically the same that schedule() does now. However, this patch of course bloats schedule(). Signed-off-by: Oleg Nesterov Signed-off-by: Ingo Molnar commit df4245dff396bd1671bdaf735b0529371b3b7112 Author: Marcelo Tosatti Date: Sun Jun 8 01:48:53 2008 -0300 KVM: MMU: Fix rmap_write_protect() hugepage iteration bug rmap_next() does not work correctly after rmap_remove(), as it expects the rmap chains not to change during iteration. Fix (for now) by restarting iteration from the beginning. Signed-off-by: Avi Kivity commit 7ead175a5278d1949f4cb856e5674f95fe1d5db6 Author: Marcelo Tosatti Date: Fri Jun 6 16:37:36 2008 -0300 KVM: close timer injection race window in __vcpu_run If a timer fires after kvm_inject_pending_timer_irqs() but before local_irq_disable() the code will enter guest mode and only inject such timer interrupt the next time an unrelated event causes an exit. It would be simpler if the timer->pending irq conversion could be done with IRQ's disabled, so that the above problem cannot happen. For now introduce a new vcpu requests bit to cancel guest entry. Signed-off-by: Marcelo Tosatti Signed-off-by: Avi Kivity commit 364964cbd78afafc0f310759ba724ce8215dcca0 Author: Marcelo Tosatti Date: Fri Jun 6 16:37:35 2008 -0300 KVM: Fix race between timer migration and vcpu migration A guest vcpu instance can be scheduled to a different physical CPU between the test for KVM_REQ_MIGRATE_TIMER and local_irq_disable(). If that happens, the timer will only be migrated to the current pCPU on the next exit, meaning that guest LAPIC timer event can be delayed until a host interrupt is triggered. Fix it by cancelling guest entry if any vcpu request is pending. This has the side effect of nicely consolidating vcpu->requests checks. Signed-off-by: Marcelo Tosatti Signed-off-by: Avi Kivity commit d57b0f1e7ff62207dc32bdd556e62ff7b5e4a831 Author: Andrea Arcangeli Date: Fri Jun 6 14:51:26 2008 +0200 KVM: VMX: Fix crash in resume from suspend to ram This avoids a reproducible crash after resume from suspend to ram with vmx. If cpu isn't set to -1 by suspend, vcpu_clear called by the first vmx_vcpu_load after resume will run __vcpu_clear again and that's forbidden as it'd double list_del. launched must be cleared as well by ->suspend as vcpu_clear wouldn't clear it after ->resume because vcpu is set to -1. Signed-off-by: Andrea Arcangeli Signed-off-by: Avi Kivity commit 84c2ca9934c4a1bbe9d28b313c0819515288a69e Author: Ingo Molnar Date: Mon May 12 21:21:14 2008 +0200 sched: sched_clock() improvement: use in_nmi() make sure we dont execute more complex sched_clock() code in NMI context. Signed-off-by: Ingo Molnar Signed-off-by: Thomas Gleixner commit ff5bdac4be0230e0bb33e4208ac0a91343c72929 Author: Marcelo Tosatti Date: Thu Jun 5 00:08:11 2008 -0300 KVM: IOAPIC: only set remote_irr if interrupt was injected There's a bug in the IOAPIC code for level-triggered interrupts. Its relatively easy to trigger by sharing (virtio-blk + usbtablet was the testcase, initially reported by Gerd von Egidy). The "remote_irr" variable is used to indicate accepted but not yet acked interrupts. Its cleared from the EOI handler. Problem is that the EOI handler clears remote_irr unconditionally, even if it reinjected another pending interrupt. In that case, kvm_ioapic_set_irq() proceeds to ioapic_service() which sets remote_irr even if it failed to inject (since the IRR was high due to EOI reinjection). Since the TMR bit has been cleared by the first EOI, the second one fails to clear remote_irr. End result is interrupt line dead. Fix it by setting remote_irr only if a new pending interrupt has been generated (and the TMR bit for vector in question set). Signed-off-by: Marcelo Tosatti Signed-off-by: Avi Kivity commit f5be088374ee543e14380b659b00e4cbe122091e Author: Avi Kivity Date: Wed Jun 4 18:42:24 2008 +0300 KVM: MMU: reschedule during shadow teardown Shadows for large guests can take a long time to tear down, so reschedule occasionally to avoid softlockup warnings. Signed-off-by: Avi Kivity commit 06611ee6f9a6330ffd6cd3c3dc7c7b1a09daab59 Author: Laurent Vivier Date: Fri May 30 16:05:57 2008 +0200 KVM: Add coalesced MMIO support (ia64 part) This patch enables coalesced MMIO for ia64 architecture. It defines KVM_MMIO_PAGE_OFFSET and KVM_CAP_COALESCED_MMIO. It enables the compilation of coalesced_mmio.c. Signed-off-by: Laurent Vivier Signed-off-by: Avi Kivity commit f34d1b5189c61f1076ab9551c3a5cc89bdc6279d Author: Laurent Vivier Date: Fri May 30 16:05:56 2008 +0200 KVM: Add coalesced MMIO support (powerpc part) This patch enables coalesced MMIO for powerpc architecture. It defines KVM_MMIO_PAGE_OFFSET and KVM_CAP_COALESCED_MMIO. It enables the compilation of coalesced_mmio.c. Signed-off-by: Laurent Vivier Signed-off-by: Avi Kivity commit 398996a4bef4c17fe664df2fcef3705353e3ad34 Author: Laurent Vivier Date: Fri May 30 16:05:55 2008 +0200 KVM: Add coalesced MMIO support (x86 part) This patch enables coalesced MMIO for x86 architecture. It defines KVM_MMIO_PAGE_OFFSET and KVM_CAP_COALESCED_MMIO. It enables the compilation of coalesced_mmio.c. Signed-off-by: Laurent Vivier Signed-off-by: Avi Kivity commit 0ca87ec4ded4e6568f235eff495a0552129d8ff4 Author: Laurent Vivier Date: Fri May 30 16:05:54 2008 +0200 KVM: Add coalesced MMIO support (common part) This patch adds all needed structures to coalesce MMIOs. Until an architecture uses it, it is not compiled. Coalesced MMIO introduces two ioctl() to define where are the MMIO zones that can be coalesced: - KVM_REGISTER_COALESCED_MMIO registers a coalesced MMIO zone. It requests one parameter (struct kvm_coalesced_mmio_zone) which defines a memory area where MMIOs can be coalesced until the next switch to user space. The maximum number of MMIO zones is KVM_COALESCED_MMIO_ZONE_MAX. - KVM_UNREGISTER_COALESCED_MMIO cancels all registered zones inside the given bounds (bounds are also given by struct kvm_coalesced_mmio_zone). The userspace client can check kernel coalesced MMIO availability by asking ioctl(KVM_CHECK_EXTENSION) for the KVM_CAP_COALESCED_MMIO capability. The ioctl() call to KVM_CAP_COALESCED_MMIO will return 0 if not supported, or the page offset where will be stored the ring buffer. The page offset depends on the architecture. After an ioctl(KVM_RUN), the first page of the KVM memory mapped points to a kvm_run structure. The offset given by KVM_CAP_COALESCED_MMIO is an offset to the coalesced MMIO ring expressed in PAGE_SIZE relatively to the address of the start of th kvm_run structure. The MMIO ring buffer is defined by the structure kvm_coalesced_mmio_ring. Signed-off-by: Laurent Vivier Signed-off-by: Avi Kivity commit b5779e39ed500c948858d64e90305b133a8e4a1b Author: Laurent Vivier Date: Fri May 30 16:05:53 2008 +0200 KVM: kvm_io_device: extend in_range() to manage len and write attribute Modify member in_range() of structure kvm_io_device to pass length and the type of the I/O (write or read). This modification allows to use kvm_io_device with coalesced MMIO. Signed-off-by: Laurent Vivier Signed-off-by: Avi Kivity commit 1f4e1d64122369d65d8a9c616112780019fb6188 Author: Eli Collins Date: Sun Jun 1 20:24:40 2008 -0700 KVM: VMX: Clear CR4.VMXE in hardware_disable Clear CR4.VMXE in hardware_disable. There's no reason to leave it set after doing a VMXOFF. VMware Workstation 6.5 checks CR4.VMXE as a proxy for whether the CPU is in VMX mode, so leaving VMXE set means we'll refuse to power on. With this change the user can power on after unloading the kvm-intel module. I tested on kvm-67 and kvm-69. Signed-off-by: Eli Collins Signed-off-by: Avi Kivity commit 3eec4911347c4e10b186415d70385353d2f6ccbc Author: Barry Naujok Date: Tue Jun 3 11:59:18 2008 +1000 [XFS] Zero uninitialised xfs_da_args structure in xfs_dir2.c Fixes a problem in the xfs_dir2_remove and xfs_dir2_replace paths which intenally call directory format specific lookup funtions that assume args->cmpresult is zeroed. SGI-PV: 982606 SGI-Modid: xfs-linux-melb:xfs-kern:31268a Signed-off-by: Barry Naujok Signed-off-by: Christoph Hellwig commit 70ef6d595b6e51618a0cbe44b848d8c9db11a010 Author: Kevin Hao Date: Thu May 29 18:41:04 2008 +0800 x86: get irq for hpet timer HPET timer's IRQ is 0 by default. So we have to select which irq will be used by these timers. We wait to set the timer's irq until we really open it in order to reduce the chance of conflicting with other device. Signed-off-by: Kevin Hao Signed-off-by: Ingo Molnar commit d939e935ecd5d57448c33c4c04dd08e92a780131 Author: Avi Kivity Date: Thu May 29 14:56:28 2008 +0300 KVM: MMU: Avoid page prefetch on SVM SVM cannot benefit from page prefetching since guest page fault bypass cannot by made to work there. Avoid accessing the guest page table in this case. Signed-off-by: Avi Kivity commit 320041e6882134011c67d9d689408f0108ab4e42 Author: Avi Kivity Date: Thu May 29 14:55:03 2008 +0300 KVM: MMU: Move nonpaging_prefetch_page() In preparation for next patch. No code change. Signed-off-by: Avi Kivity commit 877a5cef3d49f6dcf29f9f036ec4928f7d3b8e5b Author: Avi Kivity Date: Thu May 29 14:38:38 2008 +0300 KVM: x86 emulator: implement 'push imm' (opcode 0x68) Encountered in FC6 boot sequence, now that we don't force ss.rpl = 0 during the protected mode transition. Not really necessary, but nice to have. Signed-off-by: Avi Kivity commit fdc3c320b3284c211b899e50b8f7863926499765 Author: Avi Kivity Date: Thu May 29 14:26:29 2008 +0300 KVM: x86 emulator: simplify push imm8 emulation Instead of fetching the data explicitly, use SrcImmByte. Signed-off-by: Avi Kivity commit a9522ec88cfba457884dd086571f567aa9513462 Author: Avi Kivity Date: Thu May 29 14:20:16 2008 +0300 KVM: MMU: Optimize prefetch_page() Instead of reading each pte individually, read 256 bytes worth of ptes and batch process them. Signed-off-by: Avi Kivity commit 4b14fe2d3f2f0a66c27eef9ca59cb50a0825216c Author: Guillaume Thouvenin Date: Tue May 27 15:13:28 2008 +0200 KVM: x86 emulator: Add support for mov r, sreg (0x8c) instruction Add support for mov r, sreg (0x8c) instruction Signed-off-by: Guillaume Thouvenin Signed-off-by: Laurent Vivier Signed-off-by: Avi Kivity commit 2364863e95fa0a2e7b06fe3a891705f6e65d9623 Author: Guillaume Thouvenin Date: Tue May 27 14:49:15 2008 +0200 KVM: x86 emulator: Add support for mov seg, r (0x8e) instruction Add support for mov r, sreg (0x8c) instruction. [avi: drop the sreg decoding table in favor of 1:1 encoding] Signed-off-by: Guillaume Thouvenin Signed-off-by: Laurent Vivier Signed-off-by: Avi Kivity commit d736b0ec695dcd2f3e8a9150626132953e9e49e6 Author: Guillaume Thouvenin Date: Tue May 27 10:19:16 2008 +0200 KVM: x86 emulator: adds support to mov r,imm (opcode 0xb8) instruction Add support to mov r, imm (0xb8) instruction. Signed-off-by: Guillaume Thouvenin Signed-off-by: Laurent Vivier Signed-off-by: Avi Kivity commit 6780f25dcaab2620493bc62700ce653ec567aea2 Author: Guillaume Thouvenin Date: Tue May 27 10:19:08 2008 +0200 KVM: x86 emulator: add support for jmp far 0xea Add support for jmp far (opcode 0xea) instruction. Signed-off-by: Guillaume Thouvenin Signed-off-by: Laurent Vivier Signed-off-by: Avi Kivity commit 36742c5470f9717f31a8e3239831baf1e8d17f97 Author: Guillaume Thouvenin Date: Tue May 27 10:19:00 2008 +0200 KVM: VMX: Add mechanism to detect VMentry failure Adds mechanism to detect VMentry failure. When VMentry failure is detected we're trying to emulate the instruction that causes this failure. If emulation failed we modify the SS selector to pass VMX sanity tests and retry to execute the instruction (old behaviour). The good solution is to emulate the instruction that causes the failure. Signed-off-by: Guillaume Thouvenin Signed-off-by: Laurent Vivier Signed-off-by: Avi Kivity commit cb3935d0796e578b382fd20dff128148752127f8 Author: Guillaume Thouvenin Date: Tue May 27 10:22:20 2008 +0200 KVM: x86 emulator: Update c->dst.bytes in decode instruction Update c->dst.bytes in decode instruction instead of instruction itself. It's needed because if c->dst.bytes is equal to 0, the instruction is not emulated. Signed-off-by: Guillaume Thouvenin Signed-off-by: Laurent Vivier Signed-off-by: Avi Kivity commit 9544157913288e2cc88415544a2da6fb68542d48 Author: Guillaume Thouvenin Date: Tue May 27 10:18:46 2008 +0200 KVM: Prefixes segment functions that will be exported with "kvm_" Prefixes functions that will be exported with kvm_. We also prefixed set_segment() even if it still static to be coherent. signed-off-by: Guillaume Thouvenin Signed-off-by: Laurent Vivier Signed-off-by: Avi Kivity commit 7ea77438cc813a17f85236c2bed1db0bfbbd83ae Author: Marcelo Tosatti Date: Tue May 27 12:10:20 2008 -0300 KVM: migrate PIT timer Migrate the PIT timer to the physical CPU which vcpu0 is scheduled on, similarly to what is done for the LAPIC timers, otherwise PIT interrupts will be delayed until an unrelated event causes an exit. Signed-off-by: Marcelo Tosatti Signed-off-by: Avi Kivity commit 92d9acbf598427c88922344ae129774f1543bc6e Author: Avi Kivity Date: Mon May 26 20:06:35 2008 +0300 KVM: MTRR support Add emulation for the memory type range registers, needed by VMware esx 3.5, and by pci device assignment. Signed-off-by: Avi Kivity commit fc4e68afa1a2a8c1fb1b61a5b867052cfb17aa24 Author: Avi Kivity Date: Tue May 27 16:26:01 2008 +0300 KVM: Order segment register constants in the same way as cpu operand encoding This can be used to simplify the x86 instruction decoder. Signed-off-by: Avi Kivity commit 7c9f8861e6c9c839f913e49b98c3854daca18f27 Author: Eric Sandeen Date: Tue Apr 22 16:38:23 2008 -0500 stackprotector: use canary at end of stack to indicate overruns at oops time (Updated with a common max-stack-used checker that knows about the canary, as suggested by Joe Perches) Use a canary at the end of the stack to clearly indicate at oops time whether the stack has ever overflowed. This is a very simple implementation with a couple of drawbacks: 1) a thread may legitimately use exactly up to the last word on the stack -- but the chances of doing this and then oopsing later seem slim 2) it's possible that the stack usage isn't dense enough that the canary location could get skipped over -- but the worst that happens is that we don't flag the overrun -- though this happens fairly often in my testing :( With the code in place, an intentionally-bloated stack oops might do: BUG: unable to handle kernel paging request at ffff8103f84cc680 IP: [] update_curr+0x9a/0xa8 PGD 8063 PUD 0 Thread overran stack or stack corrupted Oops: 0000 [1] SMP CPU 0 ... ... unless the stack overrun is so bad that it corrupts some other thread. Signed-off-by: Eric Sandeen Signed-off-by: Ingo Molnar Signed-off-by: Thomas Gleixner commit b40a4392a3c262e0d1b5379b4e142a8eefa63439 Author: Arjan van de Ven Date: Fri Apr 18 06:16:45 2008 -0700 stackprotector: turn not having the right gcc into a #warning If the user selects the stack-protector config option, but does not have a gcc that has the right bits enabled (for example because it isn't build with a glibc that supports TLS, as is common for cross-compilers, but also because it may be too old), then the runtime test fails right now. This patch adds a warning message for this scenario. This warning accomplishes two goals 1) the user is informed that the security option he selective isn't available 2) the user is suggested to turn of the CONFIG option that won't work for him, and would make the runtime test fail anyway. Signed-off-by: Arjan van de Ven Signed-off-by: Ingo Molnar Signed-off-by: Thomas Gleixner commit b719ac56c0032bc1602914c6ea70b0f1581b08c7 Author: Daniel Walker Date: Mon Apr 14 10:03:50 2008 -0700 panic.c: fix whitespace additions trivial: remove white space addition in stack protector Signed-off-by: Ingo Molnar Signed-off-by: Thomas Gleixner commit 54371a43a66f4477889769b4fa00df936855dc8f Author: Arjan van de Ven Date: Fri Feb 15 15:33:12 2008 -0800 x86: add CONFIG_CC_STACKPROTECTOR self-test This patch adds a simple self-test capability to the stackprotector feature. The test deliberately overflows a stack buffer and then checks if the canary trap function gets called. Signed-off-by: Arjan van de Ven Signed-off-by: Ingo Molnar Signed-off-by: Thomas Gleixner commit 113c5413cf9051cc50b88befdc42e3402bb92115 Author: Ingo Molnar Date: Thu Feb 14 10:36:03 2008 +0100 x86: unify stackprotector features streamline the stackprotector features under a single option and make the stronger feature the one accessible. Signed-off-by: Ingo Molnar Signed-off-by: Thomas Gleixner commit 960a672bd9f1ec06e8f197cf81a50fd07ea02e7f Author: Ingo Molnar Date: Thu Feb 14 09:56:04 2008 +0100 x86: stackprotector: mix TSC to the boot canary mix the TSC to the boot canary. Signed-off-by: Ingo Molnar Signed-off-by: Thomas Gleixner commit 420594296838fdc9a674470d710cda7d1487f9f4 Author: Ingo Molnar Date: Thu Feb 14 09:44:08 2008 +0100 x86: fix the stackprotector canary of the boot CPU Signed-off-by: Ingo Molnar Signed-off-by: Thomas Gleixner commit 18aa8bb12dcb10adc3d7c9d69714d53667c0ab7f Author: Ingo Molnar Date: Thu Feb 14 09:42:02 2008 +0100 stackprotector: add boot_init_stack_canary() add the boot_init_stack_canary() and make the secondary idle threads use it. Signed-off-by: Ingo Molnar Signed-off-by: Thomas Gleixner commit 9b5609fd773e6ac0b1d6d6e1bf68f32cca64e06b Author: Ingo Molnar Date: Thu Feb 14 09:41:09 2008 +0100 stackprotector: include files create for core kernel files to include. Signed-off-by: Ingo Molnar Signed-off-by: Thomas Gleixner commit 72370f2a5b227bd3817593a6b15ea3f53f51dfcb Author: Ingo Molnar Date: Wed Feb 13 16:15:34 2008 +0100 x86: if stackprotector is enabled, thn use stack-protector-all by default also enable the rodata and nx tests. Signed-off-by: Ingo Molnar Signed-off-by: Thomas Gleixner commit 5cb273013e182a35e7db614d3e20a144cba71e53 Author: Ingo Molnar Date: Thu Feb 14 09:07:01 2008 +0100 panic: print out stacktrace if DEBUG_BUGVERBOSE if CONFIG_DEBUG_BUGVERBOSE is set then the user most definitely wanted to see as much information about kernel crashes as possible - so give them at least a stack dump. this is particularly useful for stackprotector related panics, where the stacktrace can give us the exact location of the (attempted) attack. Pointed out by pageexec@freemail.hu in the stackprotector breakage threads. Signed-off-by: Ingo Molnar Signed-off-by: Thomas Gleixner commit 517a92c4e19fcea815332d3155e9fb7723251274 Author: Ingo Molnar Date: Thu Feb 14 09:02:13 2008 +0100 panic: print more informative messages on stackprotect failure pointed out by pageexec@freemail.hu: we just simply panic() when there's a stackprotector attack - giving the attacked person no information about what kernel code the attack went against. print out the attacked function. Signed-off-by: Ingo Molnar Signed-off-by: Thomas Gleixner commit 7e09b2a02dae4616a5a26000169964b32f86cd35 Author: Ingo Molnar Date: Thu Feb 14 09:22:34 2008 +0100 x86: fix canary of the boot CPU's idle task the boot CPU's idle task has a zero stackprotector canary value. this is a special task that is never forked, so the fork code does not randomize its canary. Do it when we hit cpu_idle(). Academic sidenote: this means that the early init code runs with a zero canary and hence the canary becomes predictable for this short, boot-only amount of time. Although attack vectors against early init code are very rare, it might make sense to move this initialization to an earlier point. (to one of the early init functions that never return - such as start_kernel()) Signed-off-by: Ingo Molnar Signed-off-by: Thomas Gleixner commit ce22bd92cba0958e052cb1ce0f89f1d3a02b60a7 Author: Arjan van de Ven Date: Mon May 12 15:44:31 2008 +0200 x86: setup stack canary for the idle threads The idle threads for non-boot CPUs are a bit special in how they are created; the result is that these don't have the stack canary set up properly in their PDA. Easiest fix is to just always set the PDA up correctly when entering the idle thread; this is a NOP for the boot cpu. Signed-off-by: Arjan van de Ven Signed-off-by: Ingo Molnar Signed-off-by: Thomas Gleixner commit e00320875d0cc5f8099a7227b2f25fbb3231268d Author: Ingo Molnar Date: Thu Feb 14 08:48:23 2008 +0100 x86: fix stackprotector canary updates during context switches fix a bug noticed and fixed by pageexec@freemail.hu. if built with -fstack-protector-all then we'll have canary checks built into the __switch_to() function. That does not work well with the canary-switching code there: while we already use the %rsp of the new task, we still call __switch_to() whith the previous task's canary value in the PDA, hence the __switch_to() ssp prologue instructions will store the previous canary. Then we update the PDA and upon return from __switch_to() the canary check triggers and we panic. so update the canary after we have called __switch_to(), where we are at the same stackframe level as the last stackframe of the next (and now freshly current) task. Note: this means that we call __switch_to() [and its sub-functions] still with the old canary, but that is not a problem, both the previous and the next task has a high-quality canary. The only (mostly academic) disadvantage is that the canary of one task may leak onto the stack of another task, increasing the risk of information leaks, were an attacker able to read the stack of specific tasks (but not that of others). To solve this we'll have to reorganize the way we switch tasks, and move the PDA setting into the switch_to() assembly code. That will happen in another patch. Signed-off-by: Ingo Molnar Signed-off-by: Thomas Gleixner commit 4c7f8900f1d8a0e464e7092f132a7e93f7c20f2f Author: Ingo Molnar Date: Sat Feb 23 07:06:55 2008 +0100 x86: stackprotector & PARAVIRT fix on paravirt enabled 64-bit kernels the paravirt ops do function calls themselves - which is bad with the stackprotector - for example pda_init() loads 0 into %gs and then does MSR_GS_BASE write (which modifies gs.base) - but that MSR write is a function call on paravirt, which with stackprotector tries to read the stack canary from the PDA ... crashing the bootup. the solution was suggested by Arjan van de Ven: to exclude paravirt.c from stackprotector, too many lowlevel functionality is in it. It's not like we'll have paravirt functions with character arrays on their stack anyway... Signed-off-by: Arjan van de Ven Signed-off-by: Ingo Molnar Signed-off-by: Thomas Gleixner commit f6079145c6811a70ab6863779f41641fb733d15c Author: Avi Kivity Date: Sun May 25 14:38:15 2008 +0300 KVM: Remove unnecessary ->decache_regs() call Since we aren't modifying any register, there's no need to decache the register state. Signed-off-by: Avi Kivity commit c018f921a92baf1b32d943e8fc5232890be875f4 Author: Hollis Blanchard Date: Wed May 21 18:22:55 2008 -0500 KVM: ppc: Report bad GFNs This code shouldn't be hit anyways, but when it is, it's useful to have a little more information about the failure. Signed-off-by: Hollis Blanchard Signed-off-by: Avi Kivity commit b9d2d3c6184a0f89340751b9663b15b8cae5f2b8 Author: Hollis Blanchard Date: Wed May 21 18:22:54 2008 -0500 KVM: ppc: Use a read lock around MMU operations, and release it on error gfn_to_page() and kvm_release_page_clean() are called from other contexts with mmap_sem locked only for reading. Signed-off-by: Hollis Blanchard Signed-off-by: Avi Kivity commit c8ca7a3185b8dd73887fcbcafeeb90d0fec802b1 Author: Hollis Blanchard Date: Wed May 21 18:22:53 2008 -0500 KVM: ppc: Remove unmatched kunmap() call We're not calling kmap() now, so we shouldn't call kunmap() either. This has no practical effect in the non-highmem case, which is why it hasn't caused more obvious problems. Pointed out by Anthony Liguori. Signed-off-by: Hollis Blanchard Signed-off-by: Avi Kivity commit 00dee2e11f249f9fc0de2422feaec8c7a815798e Author: Hollis Blanchard Date: Wed May 21 18:22:52 2008 -0500 KVM: ppc: add lwzx/stwz emulation Somehow these load/store instructions got missed before, but weren't used by the guest so didn't break anything. Signed-off-by: Hollis Blanchard Signed-off-by: Christian Ehrhardt Signed-off-by: Avi Kivity commit 3e14667c0be3c0199f5a56a66a471d6089395845 Author: Hollis Blanchard Date: Wed May 21 18:22:51 2008 -0500 KVM: ppc: Remove duplicate function This was left behind from some code movement. Signed-off-by: Hollis Blanchard Signed-off-by: Avi Kivity commit 9ea8a453c90bf824b94492922bba2bd1078ffb6b Author: Avi Kivity Date: Sun May 25 12:06:44 2008 +0300 KVM: MMU: Fix set_bit() warning on i386 sptes are 64-bit, but set_bit() wants unsigned longs. Signed-off-by: Avi Kivity commit 9c17819696363ce832ce04f9566bc36443737350 Author: Avi Kivity Date: Sun May 25 12:02:57 2008 +0300 KVM: ia64: stub out NMI injection Fixes build breakage on ia64. Signed-off-by: Avi Kivity commit 63cc8c75156462d4b42cbdd76c293b7eee7ddbfe Author: Eric Dumazet Date: Mon May 12 15:44:40 2008 +0200 percpu: introduce DEFINE_PER_CPU_PAGE_ALIGNED() macro While examining holes in percpu section I found this : c05f5000 D per_cpu__current_task c05f5000 D __per_cpu_start c05f5004 D per_cpu__cpu_number c05f5008 D per_cpu__irq_regs c05f500c d per_cpu__cpu_devices c05f5040 D per_cpu__cyc2ns c05f6000 d per_cpu__cpuid4_info c05f6004 d per_cpu__cache_kobject c05f6008 d per_cpu__index_kobject c05f7000 D per_cpu__gdt_page This is because gdt_page is a percpu variable, defined with a page alignement, and linker is doing its job, two times because of .o nesting in the build process. I introduced a new macro DEFINE_PER_CPU_PAGE_ALIGNED() to avoid wasting this space. All page aligned variables (only one at this time) are put in a separate subsection .data.percpu.page_aligned, at the very begining of percpu zone. Before patch , on a x86_32 machine : .data.percpu 30232 3227471872 .data.percpu 22168 3227471872 Thats 8064 bytes saved for each CPU. Signed-off-by: Eric Dumazet Signed-off-by: Ingo Molnar Signed-off-by: Thomas Gleixner commit 11120b8850a5dd7b115540ea12a94b4020920850 Author: Ingo Molnar Date: Mon May 12 15:43:53 2008 +0200 nohz: reduce jiffies polling overhead Signed-off-by: Ingo Molnar Signed-off-by: Thomas Gleixner commit 0d84b78a606f1562532cd576ee8733caf5a4aed3 Author: Mathieu Desnoyers Date: Mon May 12 21:21:07 2008 +0200 x86 NMI-safe INT3 and Page Fault Implements an alternative iret with popf and return so trap and exception handlers can return to the NMI handler without issuing iret. iret would cause NMIs to be reenabled prematurely. x86_32 uses popf and far return. x86_64 has to copy the return instruction pointer to the top of the previous stack, issue a popf, loads the previous esp and issue a near return (ret). It allows placing immediate values (and therefore optimized trace_marks) in NMI code since returning from a breakpoint would be valid. Accessing vmalloc'd memory, which allows executing module code or accessing vmapped or vmalloc'd areas from NMI context, would also be valid. This is very useful to tracers like LTTng. This patch makes all faults, traps and exception safe to be called from NMI context *except* single-stepping, which requires iret to restore the TF (trap flag) and jump to the return address in a single instruction. Sorry, no kprobes support in NMI handlers because of this limitation. We cannot single-step an NMI handler, because iret must set the TF flag and return back to the instruction to single-step in a single instruction. This cannot be emulated with popf/lret, because lret would be single-stepped. It does not apply to immediate values because they do not use single-stepping. This code detects if the TF flag is set and uses the iret path for single-stepping, even if it reactivates NMIs prematurely. Test to detect if nested under a NMI handler is only done upon the return from trap/exception to kernel, which is not frequent. Other return paths (return from trap/exception to userspace, return from interrupt) keep the exact same behavior (no slowdown). Depends on : change-alpha-active-count-bit.patch change-avr32-active-count-bit.patch TODO : test with lguest, xen, kvm. ** This patch depends on the "Stringify support commas" patchset ** ** Also depends on fix-x86_64-page-fault-scheduler-race patch ** tested on x86_32 (tests implemented in a separate patch) : - instrumented the return path to export the EIP, CS and EFLAGS values when taken so we know the return path code has been executed. - trace_mark, using immediate values, with 10ms delay with the breakpoint activated. Runs well through the return path. - tested vmalloc faults in NMI handler by placing a non-optimized marker in the NMI handler (so no breakpoint is executed) and connecting a probe which touches every pages of a 20MB vmalloc'd buffer. It executes trough the return path without problem. - Tested with and without preemption tested on x86_64 - instrumented the return path to export the EIP, CS and EFLAGS values when taken so we know the return path code has been executed. - trace_mark, using immediate values, with 10ms delay with the breakpoint activated. Runs well through the return path. To test on x86_64 : - Test without preemption - Test vmalloc faults - Test on Intel 64 bits CPUs. (AMD64 was fine) Changelog since v1 : - x86_64 fixes. Changelog since v2 : - fix paravirt build Changelog since v3 : - Include modifications suggested by Jeremy Changelog since v4 : - including hardirq.h in entry_32/64.S is a bad idea (non ifndef'd C code), define HARDNMI_MASK in the .S files directly. Changelog since v5 : - Add HARDNMI_MASK to irq_count() and make die() more verbose for NMIs. Changelog since v7 : - Implement paravirtualized nmi_return. Changelog since v8 : - refreshed the patch for asm-offsets. Those were left out of v8. - now depends on "Stringify support commas" patch. Changelog since v9 : - Only test the nmi nested preempt count flag upon return from exceptions, not on return from interrupts. Only the kernel return path has this test. - Add Xen, VMI, lguest support. Use their iret pavavirt ops in lieu of nmi_return. -- Ported to sched-devel.git Signed-off-by: Mathieu Desnoyers CC: akpm@osdl.org CC: mingo@elte.hu CC: "H. Peter Anvin" CC: Jeremy Fitzhardinge CC: Steven Rostedt CC: "Frank Ch. Eigler" Signed-off-by: Ingo Molnar Signed-off-by: Thomas Gleixner commit a04464b773577d5084d96f159c59a1326e15b3e6 Author: Mathieu Desnoyers Date: Mon May 12 21:21:06 2008 +0200 x86_64 page fault NMI-safe > I think you're vastly overestimating what is sane to do from an NMI > context. It is utterly and totally insane to assume vmalloc is available > in NMI. > > -hpa > Ok, please tell me where I am wrong then.. by looking into arch/x86/mm/fault.c, I see that vmalloc_sync_all() touches pgd_list entries while the pgd_lock spinlock is taken, with interrupts disabled. So it's protected against concurrent pgd_list modification from a - vmalloc_sync_all() on other CPUs b - local interrupts However, a completely normal interrupt can come on a remote CPU, run vmalloc_fault() and issue a set_pgd concurrently. Therefore I conclude this interrupt disable is not there to insure any kind of protection against concurrent updates. Also, we see that vmalloc_fault has comments such as : (for x86_32) * Do _not_ use "current" here. We might be inside * an interrupt in the middle of a task switch.. So it takes the pgd_addr from cr3, not from current. Using only the stack/registers makes this NMI-safe even if "current" is invalid when the NMI comes. This is caused by the fact that __switch_to will update the registers before updating current_task without disabling interrupts. You are right in that x86_64 does not seems to play as safely as x86_32 on this matter; it uses current->mm. Probably it shouldn't assume "current" is valid. Actually, I don't see where x86_64 disables interrupts around __switch_to, so this would seem to be a race condition. Or have I missed something ? (Ingo) > > the scheduler disables interrupts around __switch_to(). (x86 does > > not set __ARCH_WANT_INTERRUPTS_ON_CTXSW) > (Mathieu) > Ok, so I guess it's only useful to NMIs then. However, it makes me > wonder why this comment was there in the first place on x86_32 > vmalloc_fault() and why it uses read_cr3() : > > * Do _not_ use "current" here. We might be inside > * an interrupt in the middle of a task switch.. (Ingo) hm, i guess it's still useful to keep the __ARCH_WANT_INTERRUPTS_ON_CTXSW case working too. On -rt we used to enable it to squeeze a tiny bit more latency out of the system. Signed-off-by: Mathieu Desnoyers CC: akpm@osdl.org CC: mingo@elte.hu CC: "H. Peter Anvin" CC: Jeremy Fitzhardinge CC: Steven Rostedt CC: "Frank Ch. Eigler" Signed-off-by: Ingo Molnar Signed-off-by: Thomas Gleixner commit b335389222820f662d969d89e6098ac661691519 Author: Mathieu Desnoyers Date: Mon May 12 21:21:07 2008 +0200 Change avr32 active count bit avr32 uses the active count bit 31. This patch moves it to 28 so 31 is freed for nmi count. Signed-off-by: Mathieu Desnoyers CC: hskinnemoen@atmel.com Signed-off-by: Ingo Molnar Signed-off-by: Thomas Gleixner commit a581cbddd64291eb06d1ac9ed429306324401d7b Author: Mathieu Desnoyers Date: Mon May 12 21:21:06 2008 +0200 Change Alpha active count bit alpha uses the active count bit 31. This patch moves it to 28 so 31 is freed for nmi count. Signed-off-by: Mathieu Desnoyers CC: rth@twiddle.net CC: ink@jurassic.park.msu.ru Signed-off-by: Ingo Molnar Signed-off-by: Thomas Gleixner commit eca09995fd79a7ac95e8ba936a0094acbe8e1506 Author: Mathieu Desnoyers Date: Mon May 12 21:21:06 2008 +0200 Stringify support commas __stringify(MYDEF) should be replaced by "a, b, c", but compilation fails because the __stringify macro expects only one argument. Fix it by using variable macro arguments in __stringify and __stringify_1. Needed in my current NMI safe iret paravirt support work so I can expand a macro containing assembly code into a string. Since some architectures still use -traditional, which does not support macros with variable arguments, keep the old stringify around. Test with __STDC__ to see if -traditional is used. Signed-off-by: Mathieu Desnoyers CC: akpm@osdl.org CC: Sam Ravnborg Signed-off-by: Ingo Molnar Signed-off-by: Thomas Gleixner commit 3adebb96906d4d5d5b09cf16d75e87318f6a118c Author: Carsten Otte Date: Wed May 21 13:37:44 2008 +0200 KVM: s390: Fix race condition in kvm_s390_handle_wait The call to add_timer was issued before local_int.lock was taken and before timer_due was set to 0. If the timer expires before the lock is being taken, the timer function will set timer_due to 1 and exit before the vcpu falls asleep. Depending on other external events, the vcpu might sleep forever. This fix pulls setting timer_due to the beginning of the function before add_timer, which ensures correct behavior. Signed-off-by: Carsten Otte Signed-off-by: Avi Kivity commit 11f5ba9ffd728a64598c9da3c9ee20bd7505d62c Author: Carsten Otte Date: Wed May 21 13:37:40 2008 +0200 KVM: s390: Send program check on access error If the guest accesses non-existing memory, the sie64a function returns -EFAULT. We must check the return value and send a program check to the guest if the sie instruction faulted, otherwise the guest will loop at the faulting code. Signed-off-by: Christian Borntraeger Signed-off-by: Carsten Otte Signed-off-by: Avi Kivity commit 6324afe82b1fc7114e71deaafea16dc21baadc40 Author: Carsten Otte Date: Wed May 21 13:37:37 2008 +0200 KVM: s390: fix interrupt delivery The current code delivers pending interrupts before it checks for need_resched. On a busy host, this can lead to a longer interrupt latency if the interrupt is injected while the process is scheduled away. This patch moves delivering the interrupt _after_ schedule(), which makes more sense. Signed-off-by: Carsten Otte Signed-off-by: Avi Kivity commit 48dff9f4becbb3b691784c78d32da115db13cf71 Author: Christian Borntraeger Date: Wed May 21 13:37:34 2008 +0200 KVM: s390: handle machine checks when guest is running The low-level interrupt handler on s390 checks for _TIF_WORK_INT and exits the guest context, if work is pending. TIF_WORK_INT is defined as_TIF_SIGPENDING | _TIF_NEED_RESCHED | _TIF_MCCK_PENDING. Currently the sie loop checks for signals and reschedule, but it does not check for machine checks. That means that we exit the guest context if a machine check is pending, but we do not handle the machine check. Signed-off-by: Christian Borntraeger CC: Heiko Carstens Signed-off-by: Carsten Otte Signed-off-by: Avi Kivity commit 51d1479c59182f42a596d4da688d6150593ef284 Author: Christian Borntraeger Date: Wed May 21 13:37:29 2008 +0200 KVM: s390: fix locking order problem in enable_sie There are potential locking problem in enable_sie. We take the task_lock and the mmap_sem. As exit_mm uses the same locks vice versa, this triggers a lockdep warning. The second problem is that dup_mm and mmput might sleep, so we must not hold the task_lock at that moment. The solution is to dup the mm unconditional and use the task_lock before and afterwards to check if we can use the new mm. dup_mm and mmput are called outside the task_lock, but we run update_mm while holding the task_lock, protection us against ptrace. Signed-off-by: Christian Borntraeger Signed-off-by: Carsten Otte Signed-off-by: Avi Kivity commit 4489278915f8c7bddb2bf427e2f47718a1d53f55 Author: Christian Borntraeger Date: Wed May 21 13:37:16 2008 +0200 KVM: s390: use yield instead of schedule to implement diag 0x44 diag 0x44 is the common way on s390 to yield the cpu to the hypervisor. It is called by the guest in cpu_relax and in the spinlock code to yield to other guest cpus. This semantic is similar to yield. Lets replace the call to schedule with yield to make sure that current is really yielding. Signed-off-by: Christian Borntraeger Signed-off-by: Carsten Otte Signed-off-by: Avi Kivity commit 4f91caab552fabc4184150955bf056f729e7fc03 Author: Barry Naujok Date: Thu May 22 17:21:40 2008 +1000 [XFS] Remove d_add call for an ENOENT lookup return code SGI-PV: 981521 SGI-Modid: xfs-linux-melb:xfs-kern:31214a Signed-off-by: Barry Naujok Signed-off-by: David Chinner commit b3e20c48ed4403eb3bdd9a870ec668753093d3ab Author: Avi Kivity Date: Wed May 21 15:34:25 2008 +0300 KVM: x86 emulator: fix hypercall return value on AMD The hypercall instructions on Intel and AMD are different. KVM allows the guest to choose one or the other (the default is Intel), and if the guest chooses incorrectly, KVM will patch it at runtime to select the correct instruction. This allows live migration between Intel and AMD machines. This patching occurs in the x86 emulator. The current code also executes the hypercall. Unfortunately, the tail end of the x86 emulator code also executes, overwriting the return value of the hypercall with the original contents of rax (which happens to be the hypercall number). Fix not by executing the hypercall in the emulator context; instead let the guest reissue the patched instruction and execute the hypercall via the normal path. Signed-off-by: Avi Kivity commit c958ff21b6cf5a6d6f842482b150a32fc45e93f1 Author: Jes Sorensen Date: Tue May 20 13:13:50 2008 +0200 KVM: ia64: fix zero extending for mmio ld1/2/4 emulation in KVM Only copy in the data actually requested by the instruction emulation and zero pad the destination register first. This avoids the problem where emulated mmio access got garbled data from ld2.acq instructions in the vga console driver. Signed-off-by: Jes Sorensen Acked-by: Xiantao Zhang Signed-off-by: Avi Kivity commit 4f956a990561a9e871a107ce6c6131fa2b9ea5d3 Author: Barry Naujok Date: Wed May 21 18:38:40 2008 +1000 [XFS] kmem_free and kmem_realloc to use const void * SGI-PV: 981498 SGI-Modid: xfs-linux-melb:xfs-kern:31212a Signed-off-by: Barry Naujok Signed-off-by: Christoph Hellwig commit 0a2ea7850fc6de2dbefbdc9a7e0eb2c57d9e95c1 Author: Barry Naujok Date: Wed May 21 16:58:55 2008 +1000 [XFS] XFS: ASCII case-insensitive support Implement ASCII case-insensitive support. It's primary purpose is for supporting existing filesystems that already use this case-insensitive mode migrated from IRIX. But, if you only need ASCII-only case-insensitive support (ie. English only) and will never use another language, then this mode is perfectly adequate. ASCII-CI is implemented by generating hashes based on lower-case letters and doing lower-case compares. It implements a new xfs_nameops vector for doing the hashes and comparisons for all filename operations. To create a filesystem with this CI mode, use: # mkfs.xfs -n version=ci SGI-PV: 981516 SGI-Modid: xfs-linux-melb:xfs-kern:31209a Signed-off-by: Barry Naujok Signed-off-by: Christoph Hellwig commit f0775a14cd11addb7f635904230701d73449c978 Author: Barry Naujok Date: Wed May 21 16:58:22 2008 +1000 [XFS] Return case-insensitive match for dentry cache This implements the code to store the actual filename found during a lookup in the dentry cache and to avoid multiple entries in the dcache pointing to the same inode. To avoid polluting the dcache, we implement a new directory inode operations for lookup. xfs_vn_ci_lookup() stores the correct case name in the dcache. The "actual name" is only allocated and returned for a case- insensitive match and not an actual match. Another unusual interaction with the dcache is not storing negative dentries like other filesystems doing a d_add(dentry, NULL) when an ENOENT is returned. During the VFS lookup, if a dentry returned has no inode, dput is called and ENOENT is returned. By not doing a d_add, this actually removes it completely from the dcache to be reused. create/rename have to be modified to support unhashed dentries being passed in. SGI-PV: 981521 SGI-Modid: xfs-linux-melb:xfs-kern:31208a Signed-off-by: Barry Naujok Signed-off-by: Christoph Hellwig commit 467ac40e70edf4bf088c3ffe72d44b6e6fceb5d0 Author: Barry Naujok Date: Wed May 21 16:50:46 2008 +1000 dcache: Add case-insensitive support d_ci_add() routine This add a dcache entry to the dcache for lookup, but changing the name that is associated with the entry rather than the one passed in to the lookup routine. First, it sees if the case-exact match already exists in the dcache and uses it if one exists. Otherwise, it allocates a new node with the new name and splices it into the dcache. Original code from ntfs_lookup in fs/ntfs/namei.c by Anton Altaparmakov. Signed-off-by: Barry Naujok Signed-off-by: Anton Altaparmakov Acked-by: Christoph Hellwig commit 48f1544f304670af81ba128e49c07649ab80b88f Author: Barry Naujok Date: Wed May 21 16:42:05 2008 +1000 [XFS] Add op_flags field and helpers to xfs_da_args The end of the xfs_da_args structure has 4 unsigned char fields for true/false information on directory and attr operations using the xfs_da_args structure. The following converts these 4 into a op_flags field that uses the first 4 bits for these fields and allows expansion for future operation information (eg. case-insensitive lookup request). SGI-PV: 981520 SGI-Modid: xfs-linux-melb:xfs-kern:31206a Signed-off-by: Barry Naujok Signed-off-by: Christoph Hellwig commit 6389a58cc3f6521248df526a852621fc08d94362 Author: Barry Naujok Date: Wed May 21 16:41:01 2008 +1000 [XFS] Name operation vector for hash and compare Adds two pieces of functionality for the basis of case-insensitive support in XFS: 1. A comparison result enumerated type: xfs_dacmp. It represents an exact match, case-insensitive match or no match at all. This patch only implements different and exact results. 2. xfs_nameops vector for specifying how to perform the hash generation of filenames and comparision methods. In this patch the hash vector points to the existing xfs_da_hashname function and the comparison method does a length compare, and if the same, does a memcmp and return the xfs_dacmp result. All filename functions that use the hash (create, lookup remove, rename, etc) now use the xfs_nameops.hashname function and all directory lookup functions also use the xfs_nameops.compname function. The lookup functions also handle case-insensitive results even though the default comparison function cannot return that. And important aspect of the lookup functions is that an exact match always has precedence over a case-insensitive. So while a case-insensitive match is found, we have to keep looking just in case there is an exact match. In the meantime, the info for the first case-insensitive match is retained if no exact match is found. SGI-PV: 981519 SGI-Modid: xfs-linux-melb:xfs-kern:31205a Signed-off-by: Barry Naujok Signed-off-by: Christoph Hellwig commit 654f978be7afa89af394c55f8c9dcb7ec6dc059d Author: Avi Kivity Date: Tue May 20 16:21:58 2008 +0300 KVM: MMU: Fix printk() format string Signed-off-by: Avi Kivity commit 717defb4117f154baf619c80de990fc7d6d4cb0d Author: Avi Kivity Date: Tue May 20 16:21:13 2008 +0300 KVM: MMU: Fix is_empty_shadow_page() check The check is only looking at one of two possible empty ptes. Signed-off-by: Avi Kivity commit 948f984df52511bb0efa5c026813b0c34de43aa0 Author: Avi Kivity Date: Tue May 20 14:39:25 2008 +0300 core, x86: make LIST_POISON less deadly The list macros use LIST_POISON1 and LIST_POISON2 as undereferencable pointers in order to trap erronous use of freed list_heads. Unfortunately userspace can arrange for those pointers to actually be dereferencable, potentially turning an oops to an expolit. To avoid this allow architectures (currently x86_64 only) to override the default values for these pointers with truly-undereferencable values. This is easy on x86_64 as the virtual address space is large and contains permanently unmapped ranges. Other 64-bit architectures will likely find similar unmapped ranges. Signed-off-by: Avi Kivity Signed-off-by: Ingo Molnar commit f97ff6fb842914005d09865830ff62c3a40fbc24 Author: Eric Sandeen Date: Tue May 20 15:11:17 2008 +1000 [XFS] de-duplicate calls to xfs_attr_trace_enter Every call to xfs_attr_trace_enter() shares the exact same 16 args in the middle... just send in the context pointer and let the next level down split it into the ktrace. Compile tested only. SGI-PV: 976035 SGI-Modid: xfs-linux-melb:xfs-kern:31200a Signed-off-by: Eric Sandeen Signed-off-by: Niv Sardi Signed-off-by: Josef 'Jeff' Sipek Signed-off-by: Lachlan McIlroy commit bc7ff76c528428d213cf72a0c44d527ac56cc013 Author: Christoph Hellwig Date: Tue May 20 15:11:11 2008 +1000 [XFS] add missing call to xfs_filestream_unmount on xfs_mountfs failure SGI-PV: 981951 SGI-Modid: xfs-linux-melb:xfs-kern:31199a Signed-off-by: Christoph Hellwig Signed-off-by: David Chinner Signed-off-by: Lachlan McIlroy commit 2bb6d31822096cd8997aebd954efac032e2ed9a7 Author: Christoph Hellwig Date: Tue May 20 15:11:05 2008 +1000 [XFS] rename error2 goto label in xfs_fs_fill_super SGI-PV: 981951 SGI-Modid: xfs-linux-melb:xfs-kern:31198a Signed-off-by: Christoph Hellwig Signed-off-by: David Chinner Signed-off-by: Lachlan McIlroy commit 58fc78f22015292c8d8ba1685437fed65b0dbce8 Author: Christoph Hellwig Date: Tue May 20 15:10:58 2008 +1000 [XFS] kill calls to xfs_binval in the mount error path xfs_binval aka xfs_flush_buftarg is the first thing done in xfs_free_buftarg, so there is no need to have duplicated calls just before xfs_free_buftarg in the mount failure path. SGI-PV: 981951 SGI-Modid: xfs-linux-melb:xfs-kern:31197a Signed-off-by: Christoph Hellwig Signed-off-by: David Chinner Signed-off-by: Lachlan McIlroy commit 858529ce8e73cd557ccb898b64fa7576108d00de Author: Christoph Hellwig Date: Tue May 20 15:10:52 2008 +1000 [XFS] kill xfs_mount_init xfs_mount_init is inlined into xfs_fs_fill_super and allocation switched to kzalloc. Plug a leak of the mount structure for most early mount failures. Move xfs_icsb_init_counters to as late as possible in the mount path and make sure to undo it so that no stale hotplug cpu notifiers are left around on mount failures. SGI-PV: 981951 SGI-Modid: xfs-linux-melb:xfs-kern:31196a Signed-off-by: Christoph Hellwig Signed-off-by: David Chinner Signed-off-by: Lachlan McIlroy commit fd9474214ccbee6e4232c4ff31f537b1f448a698 Author: Christoph Hellwig Date: Tue May 20 15:10:44 2008 +1000 [XFS] allow xfs_args_allocate to fail Switch xfs_args_allocate to kzalloc and handle failures. SGI-PV: 981951 SGI-Modid: xfs-linux-melb:xfs-kern:31195a Signed-off-by: Christoph Hellwig Signed-off-by: David Chinner Signed-off-by: Lachlan McIlroy commit 2a61380a124d53023db17cfcb069ced099fca272 Author: Christoph Hellwig Date: Tue May 20 15:10:36 2008 +1000 [XFS] add xfs_setup_devices helper Split setting the block and sector size out of xfs_fs_fill_super into a small helper to make xfs_fs_fill_super more readable. SGI-PV: 981951 SGI-Modid: xfs-linux-melb:xfs-kern:31194a Signed-off-by: Christoph Hellwig Signed-off-by: David Chinner Signed-off-by: Lachlan McIlroy commit 1aa67b63080f7d65be7db7ed73bf960271813283 Author: Christoph Hellwig Date: Tue May 20 11:31:13 2008 +1000 [XFS] sort out opening and closing of the block devices Currently closing the rt/log block device is done in the wrong spot, and far too early. So revampt it: - xfs_blkdev_put moved out of xfs_free_buftarg into the caller so that it is done after tearing down the buftarg completely. - call to xfs_unmountfs_close moved from xfs_mountfs into caller so that it's done after tearing down the filesystem completely. - xfs_unmountfs_close is renamed to xfs_close_devices and made static in xfs_super.c - opening of the block devices is split into a helper xfs_open_devices that is symetric in use to xfs_close_devices - xfs_unmountfs can now lose struct cred - error handling around device opening sanitized in xfs_fs_fill_super SGI-PV: 981951 SGI-Modid: xfs-linux-melb:xfs-kern:31193a Signed-off-by: Christoph Hellwig Signed-off-by: David Chinner Signed-off-by: Lachlan McIlroy commit 262aad010357c2ad5d171f5f9d6c6c3353fe0034 Author: Christoph Hellwig Date: Tue May 20 11:31:05 2008 +1000 [XFS] don't call xfs_freesb from xfs_mountfs failure case Freeing of the superblock is already handled in the caller, and that is more symmetric with the mount path, too. SGI-PV: 981951 SGI-Modid: xfs-linux-melb:xfs-kern:31192a Signed-off-by: Christoph Hellwig Signed-off-by: David Chinner Signed-off-by: Lachlan McIlroy commit 0ac0b711d037cf5be439859c0a1cdd4fddfdbf00 Author: Christoph Hellwig Date: Tue May 20 11:30:59 2008 +1000 [XFS] merge xfs_mount into xfs_fs_fill_super xfs_mount is already pretty linux-specific so merge it into xfs_fs_fill_super to allow for a more structured mount code in the next patches. xfs_start_flags and xfs_finish_flags also move to xfs_super.c. SGI-PV: 981951 SGI-Modid: xfs-linux-melb:xfs-kern:31189a Signed-off-by: Christoph Hellwig Signed-off-by: David Chinner Signed-off-by: Lachlan McIlroy commit 2b3388b09ab21ec297d6894136a9f601c39a0d8e Author: Christoph Hellwig Date: Tue May 20 11:30:52 2008 +1000 [XFS] merge xfs_unmount into xfs_fs_put_super / xfs_fs_fill_super xfs_unmount is small and already pretty Linux specific, so merge it into the callers. The real unmount path is simplified a little by doing a WARN_ON on the xfs_unmount_flush retval directly instead of propagating the error back to the caller, and the mout failure case in simplified significantly by removing the forced shutdown case and all the dmapi events that shouldn't be sent because the dmapi mount event hasn't been sent by that time either. SGI-PV: 981951 SGI-Modid: xfs-linux-melb:xfs-kern:31188a Signed-off-by: Christoph Hellwig Signed-off-by: David Chinner Signed-off-by: Lachlan McIlroy commit 55a62529a4d13f27071e64ba4fc6c3ebad997afd Author: Christoph Hellwig Date: Tue May 20 11:30:46 2008 +1000 [XFS] kill xfs_igrow_start and xfs_igrow_finish xfs_igrow_start just expands to xfs_zero_eof with two asserts that are useless in the context of the only caller and some rather confusing comments. xfs_igrow_finish is just a few lines of code decorated again with useless asserts and confusing comments. Just kill those two and merge them into xfs_setattr. SGI-PV: 981498 SGI-Modid: xfs-linux-melb:xfs-kern:31186a Signed-off-by: Christoph Hellwig Signed-off-by: David Chinner Signed-off-by: Lachlan McIlroy commit 396e65f2085103f4e5f29afe2739d51c3e2d00c5 Author: Christoph Hellwig Date: Tue May 20 11:30:39 2008 +1000 [XFS] merge xfs_mntupdate into xfs_fs_remount xfs_mntupdate already is completely Linux specific due to the VFS flags passed in, so it might aswell be merged into xfs_fs_remount. SGI-PV: 981498 SGI-Modid: xfs-linux-melb:xfs-kern:31185a Signed-off-by: Christoph Hellwig Signed-off-by: David Chinner Signed-off-by: Lachlan McIlroy commit bb2ef73613bd6bd0257167bfde2aaa65db1c8dcf Author: Christoph Hellwig Date: Tue May 20 11:30:33 2008 +1000 [XFS] kill xfs_uuid_unmount Quite useless wrapper that doesn't help making the code more readable. SGI-PV: 981498 SGI-Modid: xfs-linux-melb:xfs-kern:31184a Signed-off-by: Christoph Hellwig Signed-off-by: David Chinner Signed-off-by: Lachlan McIlroy commit 6a35933746d9463d75c68c916eefd6b58ae94d00 Author: David Chinner Date: Tue May 20 11:30:27 2008 +1000 [XFS] Update valid fields in xfs_mount_log_sb() Recent changes to update the version number during mount (attr2 stuff) failed to change the assert that checked for calid flags being changed on mount. Clearly this path hasn't been exercised by the test code.... SGI-PV: 981950 SGI-Modid: xfs-linux-melb:xfs-kern:31183a Signed-off-by: David Chinner Signed-off-by: Eric Sandeen Signed-off-by: Lachlan McIlroy commit 5528eb34e79fa1abe65405a227d7e8c0230a5d69 Author: David Chinner Date: Tue May 20 11:30:15 2008 +1000 [XFS] Fix inode list allocation size in writeback. We only need to allocate space for the number of inodes in the cluster when writing back inodes, not every byte in the inode cluster. This reduces the amount of memory needing to be allocated to 256 bytes instead of 64k. SGI-PV: 981949 SGI-Modid: xfs-linux-melb:xfs-kern:31182a Signed-off-by: David Chinner Signed-off-by: Christoph Hellwig Signed-off-by: Lachlan McIlroy commit 0bb08241ce68aaa70b7b804b4d6319d8bad3ae24 Author: Nick Andrew Date: Tue May 20 01:43:47 2008 +0200 Tighten up the use of loose 'Lose' is when you don't win or you've lost something, and 'loose' is when something isn't tight. I just want to tighten up the spelling a bit regarding some loose comments. Signed-off-by: Nick Andrew Signed-off-by: Jesper Juhl commit 7e6df0e639188968679471f1a2cc751f1da37014 Author: Uwe Kleine-König Date: Tue May 20 01:24:15 2008 +0200 Fix typo "kernal" -> "kernel" in fs/proc/nommu.c Signed-off-by: Uwe Kleine-König Signed-off-by: Jesper Juhl commit d308e938de0443851933e592172eddfacf4de308 Author: Uwe Kleine-König Date: Tue May 20 01:21:22 2008 +0200 fix typo "thier" -> "their" in drivers/base/sys.c Signed-off-by: Uwe Kleine-König Signed-off-by: Jesper Juhl commit 465e9575fef94afb574b77f4bc7cf58f60104dbb Author: Jesper Juhl Date: Tue May 20 01:19:14 2008 +0200 Update Trivial tree details in Chinese translation of SubmittingPatches. Signed-off-by: Jesper Juhl commit 9409d492a0f51498f6c471f7bda56ae1d74de2ea Author: Jesper Juhl Date: Tue May 20 01:18:32 2008 +0200 Update Trivial tree details in Japanese translation of SubmittingPatches. Signed-off-by: Jesper Juhl commit 97aea49c9a802207f4b48140461718c095772412 Author: Lachlan McIlroy Date: Mon May 19 16:34:49 2008 +1000 [XFS] xfs_dm_rdwr() needs to pass a vfsmount to dentry_open() We need a vfsmount pointer in xfs_dm_rdwr() but we are not provided with one and there's no way to get to it. So add a m_vfsmount field to the xfs_mount structure and set it up at mount time. We can then access it through the xfs inode. SGI-PV: 981875 SGI-Modid: xfs-linux-melb:xfs-kern:31176a Signed-off-by: Lachlan McIlroy Signed-off-by: David Chinner commit a7ddc9b2ce2a21fd7c764880e382eadf1ec7897b Author: Christoph Hellwig Date: Mon May 19 16:34:42 2008 +1000 [XFS] Fix memory corruption with small buffer reads When we have multiple buffers in a single page for a blocksize == pagesize filesystem we might overwrite the page contents if two callers hit it shortly after each other. To prevent that we need to keep the page locked until I/O is completed and the page marked uptodate. Thanks to Eric Sandeen for triaging this bug and finding a reproducible testcase and Dave Chinner for additional advice. This should fix kernel.org bz #10421. Tested-by: Eric Sandeen SGI-PV: 981813 SGI-Modid: xfs-linux-melb:xfs-kern:31173a Signed-off-by: Christoph Hellwig Signed-off-by: David Chinner Signed-off-by: Lachlan McIlroy commit e3e429d132f35853973986645ec3f317ee5e529b Author: Christoph Hellwig Date: Mon May 19 16:34:34 2008 +1000 [XFS] Kill attr_capable checks as already done in xattr_permission. No need for addition permission checks in the xattr handler, fs/xattr.c:xattr_permission() already does them, and in fact slightly more strict then what was in the attr_capable handlers. SGI-PV: 981809 SGI-Modid: xfs-linux-melb:xfs-kern:31164a Signed-off-by: Christoph Hellwig Signed-off-by: Tim Shimmin Signed-off-by: Lachlan McIlroy commit 5a875300cea98641be26186567d0849ae9a4e458 Author: Matthew Wilcox Date: Mon May 19 16:34:27 2008 +1000 [XFS] Convert l_flushsema to a sv_t The l_flushsema doesn't exactly have completion semantics, nor mutex semantics. It's used as a list of tasks which are waiting to be notified that a flush has completed. It was also being used in a way that was potentially racy, depending on the semaphore implementation. By using a sv_t instead of a semaphore we avoid the need for a separate counter, since we know we just need to wake everything on the queue. Original waitqueue implementation from Matthew Wilcox. Cleanup and conversion to sv_t by Christoph Hellwig. SGI-PV: 981507 SGI-Modid: xfs-linux-melb:xfs-kern:31059a Signed-off-by: Matthew Wilcox Signed-off-by: Christoph Hellwig Signed-off-by: David Chinner Signed-off-by: Lachlan McIlroy commit 9641d1a6027175b6e3b43580f62ab0a3e4a95e91 Author: Michael Nishimoto Date: Mon May 19 16:34:20 2008 +1000 [XFS] Ensure that 2 GiB xfs logs work properly. We found this while experimenting with 2GiB xfs logs. The previous code never assumed that xfs logs would ever get so large. SGI-PV: 981502 SGI-Modid: xfs-linux-melb:xfs-kern:31058a Signed-off-by: Michael Nishimoto Signed-off-by: David Chinner Signed-off-by: Lachlan McIlroy commit 4fec9a9ec9fff141f72c20abccea8c62bea0a55f Author: Denys Vlasenko Date: Mon May 19 16:34:11 2008 +1000 [XFS] Remove unused wbc parameter from xfs_start_page_writeback() SGI-PV: 981498 SGI-Modid: xfs-linux-melb:xfs-kern:31057a Signed-off-by: Denys Vlasenko Signed-off-by: David Chinner Signed-off-by: Lachlan McIlroy commit 63f6a276b44348fde4be3d6e2956303730f0462c Author: Denys Vlasenko Date: Mon May 19 16:34:04 2008 +1000 [XFS] Remove unused Falgs parameter from xfs_qm_dqpurge() SGI-PV: 981498 SGI-Modid: xfs-linux-melb:xfs-kern:31056a Signed-off-by: Denys Vlasenko Signed-off-by: David Chinner Signed-off-by: Lachlan McIlroy commit 85e221e6b1d0c4ccf9b17362eab440523bb3ae25 Author: Denys Vlasenko Date: Mon May 19 16:31:57 2008 +1000 [XFS] Remove unused arg from kmem_free() kmem_free() function takes (ptr, size) arguments but doesn't actually use second one. This patch removes size argument from all callsites. SGI-PV: 981498 SGI-Modid: xfs-linux-melb:xfs-kern:31050a Signed-off-by: Denys Vlasenko Signed-off-by: David Chinner Signed-off-by: Lachlan McIlroy commit 8d294a25e06677aba135846a68e3304ba2eeb12f Author: David Chinner Date: Mon May 19 16:29:46 2008 +1000 [XFS] Fix fsync() b0rkage. xfs_fsync() fails to wait for data I/O completion before checking if the inode is dirty or clean to decide whether to log the inode or not. This misses inode size updates when the data flushed by the fsync() is extending the file. Hence, like fdatasync(), we need to wait for I/o completion first, then check the inode for cleanliness. Doing so makes the behaviour of xfs_fsync() identical for fsync and fdatasync and we *always* use synchronous semantics if the inode is dirty. Therefore also kill the differences and remove the unused flags from the xfs_fsync function and callers. SGI-PV: 981296 SGI-Modid: xfs-linux-melb:xfs-kern:31033a Signed-off-by: David Chinner Signed-off-by: Christoph Hellwig Signed-off-by: Lachlan McIlroy commit 97027e0fea140ec4ead1c69b52413b267911f77e Author: David Chinner Date: Mon May 19 16:29:34 2008 +1000 [XFS] Don't allow memory reclaim to wait on the filesystem in inode writeback If we allow memory reclaim to wait on the pages under writeback in inode cluster writeback we could deadlock because we are currently holding the ILOCK on the initial writeback inode which is needed in data I/O completion to change the file size or do unwritten extent conversion before the pages are taken out of writeback state. SGI-PV: 981091 SGI-Modid: xfs-linux-melb:xfs-kern:31015a Signed-off-by: David Chinner Signed-off-by: Christoph Hellwig Signed-off-by: Lachlan McIlroy commit 600aace8b2398cab0b22ab9f46ce11ed7d6574d2 Author: Sheng Yang Date: Thu May 15 18:23:25 2008 +0800 KVM: VMX: Enable NMI with in-kernel irqchip Signed-off-by: Sheng Yang Signed-off-by: Avi Kivity commit 9455f6eb00f3d63273c757710adcc6c60affe9c0 Author: Sheng Yang Date: Thu May 15 09:52:48 2008 +0800 KVM: IOAPIC/LAPIC: Enable NMI support Signed-off-by: Sheng Yang Signed-off-by: Avi Kivity commit e719a3e13514fed2d2e52e44b9250097d7d6868f Author: Avi Kivity Date: Sun May 18 13:50:23 2008 +0300 KVM: Update MAINTAINERS for new mailing lists The KVM mailing lists are now hosted on vger.kernel.org. Also update the website URL. Signed-off-by: Avi Kivity commit 418c6952ba9fd379059ed325ea5a3efe904fb7fd Author: Avi Kivity Date: Thu May 15 13:51:35 2008 +0300 KVM: MMU: Fix false flooding when a pte points to page table The KVM MMU tries to detect when a speculative pte update is not actually used by demand fault, by checking the accessed bit of the shadow pte. If the shadow pte has not been accessed, we deem that page table flooded and remove the shadow page table, allowing further pte updates to proceed without emulation. However, if the pte itself points at a page table and only used for write operations, the accessed bit will never be set since all access will happen through the emulator. This is exactly what happens with kscand on old (2.4.x) HIGHMEM kernels. The kernel points a kmap_atomic() pte at a page table, and then proceeds with read-modify-write operations to look at the dirty and accessed bits. We get a false flood trigger on the kmap ptes, which results in the mmu spending all its time setting up and tearing down shadows. Fix by setting the shadow accessed bit on emulated accesses. Signed-off-by: Avi Kivity commit c1f47ba4a598c47636c894c4feb81fe4c0b6ecd5 Author: Xiantao Zhang Date: Wed May 14 19:44:57 2008 +0800 KVM: ia64: Set KVM_IOAPIC_NUM_PINS to 48 Guest's firmware needs an iosapic with 48 pins for ia64 guests. Needed to get networking going. Signed-off-by: Xiantao Zhang Signed-off-by: Avi Kivity commit 111184b65eb587fcbda7508f062bd8c788b09d23 Author: Marcelo Tosatti Date: Thu May 8 19:47:01 2008 -0300 KVM: Fix kvm_vcpu_block() task state race There's still a race in kvm_vcpu_block(), if a wake_up_interruptible() call happens before the task state is set to TASK_INTERRUPTIBLE: CPU0 CPU1 kvm_vcpu_block add_wait_queue kvm_cpu_has_interrupt = 0 set interrupt if (waitqueue_active()) wake_up_interruptible() kvm_cpu_has_pending_timer kvm_arch_vcpu_runnable signal_pending set_current_state(TASK_INTERRUPTIBLE) schedule() Can be fixed by using prepare_to_wait() which sets the task state before testing for the wait condition. Signed-off-by: Marcelo Tosatti Signed-off-by: Avi Kivity commit 206e06db85eeea26016a05e73e92dad0ea7cbb52 Author: Marcelo Tosatti Date: Wed May 14 02:29:06 2008 -0300 KVM: LAPIC: ignore pending timers if LVTT is disabled Only use the APIC pending timers count to break out of HLT emulation if the timer vector is enabled. Certain configurations of Windows simply mask out the vector without disabling the timer. Signed-off-by: Marcelo Tosatti Signed-off-by: Avi Kivity commit ef5b87c71e5b411ef916c0316d5f304ee4ea9787 Author: Avi Kivity Date: Tue May 13 16:29:20 2008 +0300 KVM: Remove decache_vcpus_on_cpu() and related callbacks Obsoleted by the vmx-specific per-cpu list. Signed-off-by: Avi Kivity commit 5817dcff85553593cd2db8a44ebfd7e066493789 Author: Avi Kivity Date: Tue May 13 16:22:47 2008 +0300 KVM: VMX: Add list of potentially locally cached vcpus VMX hardware can cache the contents of a vcpu's vmcs. This cache needs to be flushed when migrating a vcpu to another cpu, or (which is the case that interests us here) when disabling hardware virtualization on a cpu. The current implementation of decaching iterates over the list of all vcpus, picks the ones that are potentially cached on the cpu that is being offlined, and flushes the cache. The problem is that it uses mutex_trylock() to gain exclusive access to the vcpu, which fires off a (benign) warning about using the mutex in an interrupt context. To avoid this, and to make things generally nicer, add a new per-cpu list of potentially cached vcus. This makes the decaching code much simpler. The list is vmx-specific since other hardware doesn't have this issue. Signed-off-by: Avi Kivity commit 540cd688d1db3ac72baebd9b13558236eb3d29a0 Author: Avi Kivity Date: Tue May 13 13:23:38 2008 +0300 KVM: Handle virtualization instruction #UD faults during reboot KVM turns off hardware virtualization extensions during reboot, in order to disassociate the memory used by the virtualization extensions from the processor, and in order to have the system in a consistent state. Unfortunately virtual machines may still be running while this goes on, and once virtualization extensions are turned off, any virtulization instruction will #UD on execution. Fix by adding an exception handler to virtualization instructions; if we get an exception during reboot, we simply spin waiting for the reset to complete. If it's a true exception, BUG() so we can have our stack trace. Signed-off-by: Avi Kivity commit 92517d776c47206209cb556101dac0862d217c07 Author: Andrew Morton Date: Mon May 12 22:06:56 2008 -0700 KVM: ia64: don't delete files which we need.. Cc: "Zhang, Xiantao" Signed-off-by: Andrew Morton Signed-off-by: Avi Kivity commit d832218c28f2e12037017da8a691940c75aaab51 Author: Avi Kivity Date: Mon May 12 19:25:43 2008 +0300 KVM: VMX: Trivial vmcs_write64() code simplification Signed-off-by: Avi Kivity commit 9071a6c25634d037adb7129dc84814a7f5c7c34a Author: Xiantao Zhang Date: Wed May 7 17:34:52 2008 +0800 KVM: ia64: fix GVMM module including position-dependent objects The GVMM module is position independent since it is relocated to the guest address space. Commit ea696f9cf ("ia64 kvm fixes for O=... builds") broke this by linking GVMM with non-PIC objects. Fix by creating two files: memset.S and memcpy.S which just include the files under arch/ia64/lib/{memset.S, memcpy.S} respectively. Signed-off-by: Xiantao Zhang Signed-off-by: Avi Kivity commit dcf762907d9dd08b5feab6d975061e70f527449a Author: Xiantao Zhang Date: Wed May 7 17:37:32 2008 +0800 KVM: ia64: Define new kvm_fpreg struture to replace ia64_fpreg The kernel's ia64_fpreg structure conflicts with userspace headers, so define a new structure to replace it. Signed-off-by: Xiantao Zhang Signed-off-by: Avi Kivity commit 8ae6dc90ac84d9734e343210c8ec709f50cd9d89 Author: Marcelo Tosatti Date: Tue May 6 13:32:54 2008 -0300 KVM: PIT: take inject_pending into account when emulating hlt Otherwise hlt emulation fails if PIT is not injecting IRQ's. Signed-off-by: Marcelo Tosatti Signed-off-by: Avi Kivity commit eee4646877b748afbfd34d8dbe6ea9b454a65745 Author: Heiko Carstens Date: Tue May 6 17:38:30 2008 +0300 s390: KVM guest: fix compile error Fix kvm compile error: Commit c45a6816c19dee67b8f725e6646d428901a6dc24 (virtio: explicit advertisement of driver features) and commit e976a2b997fc4ad70ccc53acfe62811c4aaec851 (s390: KVM guest: virtio device support, and kvm hypercalls) don't like each other: CC drivers/s390/kvm/kvm_virtio.o drivers/s390/kvm/kvm_virtio.c:224: error: unknown field 'feature' specified in initializer drivers/s390/kvm/kvm_virtio.c:224: warning: initialization from incompatible pointer type make[3]: *** [drivers/s390/kvm/kvm_virtio.o] Error 1 Cc: Adrian Bunk Signed-off-by: Heiko Carstens Signed-off-by: Martin Schwidefsky Acked-by: Christian Borntraeger Acked-by: Carsten Otte Signed-off-by: Avi Kivity commit 854d17ee91e87903dc42e8b4506ffd9d023ed47a Author: Chris Lalancette Date: Mon May 5 13:05:16 2008 -0400 KVM: SVM: Fake MSR_K7 performance counters Attached is a patch that fixes a guest crash when booting older Linux kernels. The problem stems from the fact that we are currently emulating MSR_K7_EVNTSEL[0-3], but not emulating MSR_K7_PERFCTR[0-3]. Because of this, setup_k7_watchdog() in the Linux kernel receives a GPF when it attempts to write into MSR_K7_PERFCTR, which causes an OOPs. The patch fixes it by just "fake" emulating the appropriate MSRs, throwing away the data in the process. This causes the NMI watchdog to not actually work, but it's not such a big deal in a virtualized environment. When we get a write to one of these counters, we printk_ratelimit() a warning. I decided to print it out for all writes, even if the data is 0; it doesn't seem to make sense to me to special case when data == 0. Tested by myself on a RHEL-4 guest, and Joerg Roedel on a Windows XP 64-bit guest. Signed-off-by: Chris Lalancette Signed-off-by: Avi Kivity commit 630741928b4a7eeff27e134d7ba7bc2fc2c764c5 Author: Avi Kivity Date: Mon May 5 14:58:26 2008 +0300 KVM: x86 emulator: fix writes to registers with modrm encodings A register destination encoded with a mod=3 encoding left dst.ptr NULL. Normally we don't trap writes to registers, but in the case of smsw, we do. Fix by pointing dst.ptr at the destination register. Signed-off-by: Avi Kivity commit 38df5142b94ffa8f09681ca3ad6f141e3a9b0b8c Author: Aurelien Jarno Date: Fri May 2 17:02:23 2008 +0200 KVM: PIT: support mode 3 The in-kernel PIT emulation ignores pending timers if operating under mode 3, which for example Hurd uses. This mode should output a square wave, high for (N+1)/2 counts and low for (N-1)/2 counts. As we only care about the resulting interrupts, the period is N, and mode 3 is the same as mode 2 with regard to interrupts. Signed-off-by: Aurelien Jarno Signed-off-by: Avi Kivity commit a57baac8bef28ac19f4a8abe9c047e9c3e6d3b87 Author: Glauber Costa Date: Wed Apr 30 12:39:05 2008 -0300 x86: KVM geust: make setup_secondary_clock definition dependent on local apic Since the pv_apic_ops are only present if CONFIG_X86_LOCAL_APIC is compiled in, kvmclock failed to build without this option. This patch fixes this. Signed-off-by: Glauber Costa Signed-off-by: Avi Kivity commit 9cebc1e22d4413d0b3922b137e5603947bacb73f Author: Avi Kivity Date: Fri May 2 13:23:10 2008 +0300 KVM: MMU: Allow more than PAGES_PER_HPAGE write protections per large page nonpae guests can call rmap_write_protect twice per page (for page tables) or four times per page (for page directories), triggering a bogus warning. Remove the warning. Signed-off-by: Avi Kivity commit 33b20d12e4b2f247e255f3428aa28dd932e56973 Author: Anthony Liguori Date: Wed Apr 30 15:37:07 2008 -0500 KVM: Handle vma regions with no backing page This patch allows VMAs that contain no backing page to be used for guest memory. This is useful for assigning mmio regions to a guest. Signed-off-by: Anthony Liguori Signed-off-by: Avi Kivity commit ef53d8c0e67c9950ddb0cbaec8f5fe27eb92e47e Author: Anthony Liguori Date: Wed Apr 30 15:16:05 2008 -0500 KVM: VMX: Don't leak EPT identity page table In vmx.c:alloc_identity_pagetable() we grab a reference to the EPT identity page table via gfn_to_page(). We never release this reference though. This patch releases the reference to this page on VM destruction. Signed-off-by: Anthony Liguori Signed-off-by: Avi Kivity commit 686ee3dc16696c7afc8633dd031c82f2eef1b9ff Author: Andrea Arcangeli Date: Thu May 1 18:43:33 2008 +0200 KVM: avoid fx_init() schedule in atomic This make sure not to schedule in atomic during fx_init. I also changed the name of fpu_init to fx_finit to avoid duplicating the name with fpu_init that is already used in the kernel, this makes grep simpler if nothing else. Signed-off-by: Andrea Arcangeli Signed-off-by: Avi Kivity commit b4140609492c89520c5183eee3f6f5254340f5df Author: Joerg Roedel Date: Wed Apr 30 17:56:04 2008 +0200 KVM: SVM: add tracing support for TDP page faults To distinguish between real page faults and nested page faults they should be traced as different events. This is implemented by this patch. Signed-off-by: Joerg Roedel Signed-off-by: Avi Kivity commit d189fcfa05a495b6b62b0d8d6343e6dd6aec7ee4 Author: Joerg Roedel Date: Wed Apr 30 17:56:03 2008 +0200 KVM: SVM: add missing kvmtrace markers This patch adds the missing kvmtrace markers to the svm module of kvm. Signed-off-by: Joerg Roedel Signed-off-by: Avi Kivity commit 2d968edd741b1773f7696fcf291f26d95a2c59b3 Author: Joerg Roedel Date: Wed Apr 30 17:56:02 2008 +0200 KVM: add missing kvmtrace bits This patch adds some kvmtrace bits to the generic x86 code where it is instrumented from SVM. Signed-off-by: Joerg Roedel Signed-off-by: Avi Kivity commit 54687dac64b151d183bbf8d44c81b5b552ce057d Author: Joerg Roedel Date: Wed Apr 30 17:56:01 2008 +0200 KVM: SVM: implement dedicated INTR exit handler With an exit handler for INTR intercepts its possible to account them using kvmtrace. Signed-off-by: Joerg Roedel Signed-off-by: Avi Kivity commit 146b30979ce006b9a8dc88763434dc9b92189c5b Author: Joerg Roedel Date: Wed Apr 30 17:56:00 2008 +0200 KVM: SVM: implement dedicated NMI exit handler With an exit handler for NMI intercepts its possible to account them using kvmtrace. Signed-off-by: Joerg Roedel Signed-off-by: Avi Kivity commit a34f96cbf88029e94f35e33b4bb4b066ca748b10 Author: Joerg Roedel Date: Wed Apr 30 17:55:59 2008 +0200 KVM: VMX: move APIC_ACCESS trace entry to generic code This patch moves the trace entry for APIC accesses from the VMX code to the generic lapic code. This way APIC accesses from SVM will also be traced. Signed-off-by: Joerg Roedel Signed-off-by: Avi Kivity commit 83575bd887fa5176c5355217e44bbd8fa1c65321 Author: Jan Kiszka Date: Wed Apr 30 17:59:04 2008 +0200 KVM: Handle double and triple faults for every exception Clear pending exceptions when setting new register values. This avoids spurious exceptions after restoring a vcpu state or after reset-on-triple-fault. Signed-off-by: Jan Kiszka Signed-off-by: Avi Kivity commit aa10d0767a7a5ae3feec57b5a7c01668e2a8cccf Author: Marcelo Tosatti Date: Wed Apr 30 13:23:54 2008 -0300 KVM: PIT: support mode 4 The in-kernel PIT emulation ignores pending timers if operating under mode 4, which for example DragonFlyBSD uses (and Plan9 too, apparently). Mode 4 seems to be similar to one-shot mode, other than the fact that it starts counting after the next CLK pulse once programmed, while mode 1 starts counting immediately, so add a FIXME to enhance precision. Fixes sourceforge bug 1952988. Signed-off-by: Marcelo Tosatti Acked-by: Sheng Yang Signed-off-by: Avi Kivity commit d46f04f09255a0040a7eb57f91733ab9bfb3ac23 Author: Avi Kivity Date: Wed Apr 30 16:13:36 2008 +0300 KVM: x86 emulator: disable writeback on lmsw The recent changes allowing memory operands with lmsw and smsw left lmsw with writeback enabled. Since lmsw has no oridinary destination operand, the dst pointer was not initialized, resulting in an oops. Close the hole by disabling writeback for lmsw. Signed-off-by: Avi Kivity commit e20915f61e1d704cdb645ea12591b17f323474c0 Author: Christian Ehrhardt Date: Tue Apr 29 18:18:23 2008 +0200 KVM: ppc: deliver INTERRUPT_FP_UNAVAIL to the guest This patch adds the delivery of INTERRUPT_FP_UNAVAIL exceptions to the guest. It's needed if a guest uses ppc binaries using the Floating point instructions. Signed-off-by: Christian Ehrhardt Acked-by: Hollis Blanchard Signed-off-by: Avi Kivity commit 5f8d713e893206eba5b4a78e4dffb9f0664cb78d Author: David Chinner Date: Wed Apr 30 18:15:34 2008 +1000 [XFS] Include linux/random.h in all builds, not just debug builds. SGI-PV: 979416 SGI-Modid: xfs-linux-melb:xfs-kern:31008a Signed-off-by: David Chinner Signed-off-by: Lachlan McIlroy commit 84d29d4363f7fb0e26c014b35592c89306acfd0d Author: Tim Shimmin Date: Wed Apr 30 18:15:28 2008 +1000 [XFS] Fix up noattr2 so that it will properly update the versionnum and features2 fields. Previously, mounting with noattr2 failed to achieve anything because although it cleared the attr2 mount flag, it would set it again as soon as it processed the superblock fields. The fix now has an explicit noattr2 flag and uses it later to fix up the versionnum and features2 fields. SGI-PV: 980021 SGI-Modid: xfs-linux-melb:xfs-kern:31003a Signed-off-by: Tim Shimmin Signed-off-by: Christoph Hellwig Signed-off-by: Lachlan McIlroy commit 6309a0720469beb77e0ab75f403a98a0aba4140c Author: David Chinner Date: Tue Apr 29 12:53:32 2008 +1000 [XFS] Don't initialise new inode generation numbers to zero When we allocation new inode chunks, we initialise the generation numbers to zero. This works fine until we delete a chunk and then reallocate it, resulting in the same inode numbers but with a reset generation count. This can result in inode/generation pairs of different inodes occurring relatively close together. Given that the inode/gen pair makes up the "unique" portion of an NFS filehandle on XFS, this can result in file handles cached on clients being seen on the wire from the server but refer to a different file. This causes .... issues for NFS clients. Hence we need a unique generation number initialisation for each inode to prevent reuse of a small portion of the generation number space. Use a random number to initialise the generation number so we don't need to keep any new state on disk whilst making the new number difficult to guess from previous allocations. SGI-PV: 979416 SGI-Modid: xfs-linux-melb:xfs-kern:31001a Signed-off-by: David Chinner Signed-off-by: Christoph Hellwig Signed-off-by: Lachlan McIlroy commit 9c65aed49bd2d15df22af91b1b8983a55dbc2e0d Author: David Chinner Date: Tue Apr 29 12:53:21 2008 +1000 [XFS] Fix check for block zero access in xfs_write_iomap_allocate() The check for block zero access should be done on non-realtime inodes. Fix the logic error in xfs_write_iomap_allocate(), and simplify the logic on all checks for block zero access in xfs_iomap.c SGI-PV: 980888 SGI-Modid: xfs-linux-melb:xfs-kern:30998a Signed-off-by: David Chinner Signed-off-by: Lachlan McIlroy commit 2403656f6d41b9911911da7c6820f0de141d5c67 Author: David Chinner Date: Tue Apr 29 12:53:15 2008 +1000 [XFS] Don't double count reserved block changes on UP. On uniprocessor machines, the incore superblock is used for all in memory accounting of free blocks. in this situation, changes to the reserved block count are accounted twice; once directly and once via xfs_mod_incore_sb(). Seeing as the modification on SMP is done via xfs_mod_incore_sb(), make this the only update mechanism that UP uses as well. SGI-PV: 980654 SGI-Modid: xfs-linux-melb:xfs-kern:30997a Signed-off-by: David Chinner Signed-off-by: Lachlan McIlroy commit d8914b1aa67d8c5179a68cf7c603fbf074c89b63 Author: Alexey Dobriyan Date: Tue Apr 29 12:53:08 2008 +1000 [XFS] remove xfs_log_ticket_zone on rmmod Fix bug introduced in commit eb01c9cd87c7a9998c2edf209721ea069e3e3652 aka "[XFS] Remove the xlog_ticket allocator" SGI-PV: 980887 SGI-Modid: xfs-linux-melb:xfs-kern:30995a Signed-off-by: Alexey Dobriyan Signed-off-by: David Chinner Signed-off-by: Lachlan McIlroy commit cbdfc5141565c529d0d014eb7333b511f14133ab Author: Eric Sandeen Date: Tue Apr 29 12:53:00 2008 +1000 [XFS] fix non-smp xfs build xfs_reserve_blocks() calls xfs_icsb_sync_counters_locked(), which is not defined if !CONFIG_SMP/!HAVE_PERCPU_SB SGI-PV: 976035 SGI-Modid: xfs-linux-melb:xfs-kern:30991a Signed-off-by: Eric Sandeen Signed-off-by: Lachlan McIlroy commit 417e31946fcce20f01f268c25652a33a1964b25b Author: Hollis Blanchard Date: Fri Apr 25 17:55:49 2008 -0500 KVM: ppc: Handle guest idle by emulating MSR[WE] writes This reduces host CPU usage when the guest is idle. However, the guest must set MSR[WE] in its idle loop, which Linux did not do until 2.6.26. Signed-off-by: Hollis Blanchard Signed-off-by: Jerone Young Signed-off-by: Avi Kivity commit e9f5f5b55aa560968b7ffbad6757fb6b4779a229 Author: Izik Eidus Date: Mon Apr 28 18:23:52 2008 +0300 KVM: x86: task switch: fix wrong bit setting for the busy flag The busy bit is bit 1 of the type field, not bit 8. Signed-off-by: Izik Eidus Signed-off-by: Avi Kivity commit 49f60060c5e6b8c2974afe5b666bd3853bd0bdb0 Author: Harvey Harrison Date: Sun Apr 27 12:14:13 2008 -0700 KVM: add statics were possible, function definition in lapic.h Noticed by sparse: arch/x86/kvm/vmx.c:1583:6: warning: symbol 'vmx_disable_intercept_for_msr' was not declared. Should it be static? arch/x86/kvm/x86.c:3406:5: warning: symbol 'kvm_task_switch_16' was not declared. Should it be static? arch/x86/kvm/x86.c:3429:5: warning: symbol 'kvm_task_switch_32' was not declared. Should it be static? arch/x86/kvm/mmu.c:1968:6: warning: symbol 'kvm_mmu_remove_one_alloc_mmu_page' was not declared. Should it be static? arch/x86/kvm/mmu.c:2014:6: warning: symbol 'mmu_destroy_caches' was not declared. Should it be static? arch/x86/kvm/lapic.c:862:5: warning: symbol 'kvm_lapic_get_base' was not declared. Should it be static? arch/x86/kvm/i8254.c:94:5: warning: symbol 'pit_get_gate' was not declared. Should it be static? arch/x86/kvm/i8254.c:196:5: warning: symbol '__pit_timer_fn' was not declared. Should it be static? arch/x86/kvm/i8254.c:561:6: warning: symbol '__inject_pit_timer_intr' was not declared. Should it be static? Signed-off-by: Harvey Harrison Signed-off-by: Avi Kivity commit 8b4ddc81367887f669f106d935324e12c8f41580 Author: Sheng Yang Date: Mon Apr 28 12:24:45 2008 +0800 KVM: VMX: Enable EPT feature for KVM Signed-off-by: Sheng Yang Signed-off-by: Avi Kivity commit e8fbea220a75d4e9b58d51f84ac3bdbb9cbc020a Author: Sheng Yang Date: Fri Apr 25 21:44:52 2008 +0800 KVM: VMX: Prepare an identity page table for EPT in real mode Signed-off-by: Sheng Yang Signed-off-by: Avi Kivity commit a7a208549d572f7d45039af4ffc3c2c1a9b7f375 Author: Sheng Yang Date: Fri Apr 25 21:44:50 2008 +0800 KVM: Export necessary function for EPT Signed-off-by: Sheng Yang Signed-off-by: Avi Kivity commit 7eee0828035e1fb1eda75eb57e8c9ffb85a62a2f Author: Sheng Yang Date: Fri Apr 25 21:44:42 2008 +0800 KVM: MMU: Remove #ifdef CONFIG_X86_64 to support 4 level EPT Currently EPT level is 4 for both pae and x86_64. The patch remove the #ifdef for alloc root_hpa and free root_hpa to support EPT. Signed-off-by: Sheng Yang Signed-off-by: Avi Kivity commit a515d696ccfc8d54e460314894dd7d45aa9b4cf5 Author: Sheng Yang Date: Fri Apr 25 21:13:50 2008 +0800 KVM: MMU: Add EPT support Enable kvm_set_spte() to generate EPT entries. Signed-off-by: Sheng Yang Signed-off-by: Avi Kivity commit a6a35a8ee0be5dd4281e2876263679f0ec101b57 Author: Sheng Yang Date: Fri Apr 25 10:20:22 2008 +0800 KVM: Add kvm_x86_ops get_tdp_level() The function get_tdp_level() provided the number of tdp level for EPT and NPT rather than the NPT specific macro. Signed-off-by: Sheng Yang Signed-off-by: Avi Kivity commit 5fad90c5ba557f4a2a5f165419a4529eafbc66b7 Author: Sheng Yang Date: Fri Apr 25 10:17:08 2008 +0800 KVM: MMU: Move some definitions to a header file Move some definitions to mmu.h in order to allow building common table entries between EPT and non-EPT. Signed-off-by: Sheng Yang Signed-off-by: Avi Kivity commit 33b7481a781c71e5dc51454e79f8df43ae26f92d Author: Sheng Yang Date: Fri Apr 25 10:13:16 2008 +0800 KVM: VMX: EPT Feature Detection Signed-off-by: Sheng Yang Signed-off-by: Avi Kivity commit 8d6e265250137db168e1a052b30cf5c7e8a59528 Author: Avi Kivity Date: Thu Apr 24 19:44:17 2008 +0300 KVM: Partial revert of "KVM: PIT: make last_injected_time per-guest" (873c05f) The fix caused IPIs to be fired from interrupt context, which can cause hard hangs if they catch another IPI in progress. Signed-off-by: Avi Kivity commit 58db4c9141035200d6816181e60870319f79a2fa Author: Al Viro Date: Sat Apr 19 20:33:56 2008 +0100 KVM: kill file->f_count abuse in kvm Use kvm own refcounting instead of playing with ->filp->f_count. That will allow to get rid of a lot of crap in anon_inode_getfd() and kill a race in kvm_dev_ioctl_create_vm() (file might have been closed immediately by another thread, so ->filp might point to already freed struct file when we get around to setting it). Signed-off-by: Al Viro Signed-off-by: Avi Kivity commit 873c05fa7e6fea27090b1bf0f67a073eadb04782 Author: Marcelo Tosatti Date: Tue Apr 22 11:19:46 2008 -0300 KVM: PIT: make last_injected_time per-guest Otherwise multiple guests use the same variable and boom. Also use kvm_vcpu_kick() to make sure that if a timer triggers on a different CPU the event won't be missed. Signed-off-by: Marcelo Tosatti Tested-and-Acked-by: Alex Davis Signed-off-by: Avi Kivity commit 967b942637b249fb7709704786a966d2092ea722 Author: Christian Borntraeger Date: Mon Apr 21 13:48:24 2008 +0200 KVM: remove long -> void *user -> long cast kvm_dev_ioctl casts the arg value to void __user *, just to recast it again to long. This seems unnecessary. According to objdump the binary code on x86 is unchanged by this patch. Signed-off-by: Christian Borntraeger Signed-off-by: Avi Kivity commit 91417f4b495ad90bc3fb69105d3a55a334e1ced7 Author: Stephen Rothwell Date: Mon Apr 21 16:52:39 2008 +1000 KVM: Fix ppc build Signed-off-by: Stephen Rothwell Reviewed-by: Hollis Blanchard Signed-off-by: Avi Kivity commit d00792122d1d2aa524ad4db600aab6de6f8516c2 Author: Donald Douwsma Date: Tue Apr 22 17:34:56 2008 +1000 [XFS] Fix broken HAVE_SPLICE removal commit. Commit e687330b5ed1ea899fdaf0dea50aba196b6e019a was meant to remove the unused HAVE_SPLICE macro, instead an unrelated change was checked enabling QUOTADEBUG when building DEBUG XFS. Restore the intended changes. SGI-PV: 971046 SGI-Modid: xfs-linux-melb:xfs-kern:30924a Signed-off-by: Donald Douwsma Signed-off-by: Barry Naujok Signed-off-by: Lachlan McIlroy commit baba99461a6cc5b7a5c5347b521a4a4c45edbdfc Author: Christoph Hellwig Date: Tue Apr 22 17:34:50 2008 +1000 [XFS] kill XFS_ICSB_SB_LOCKED With the last two patches XFS_ICSB_SB_LOCKED is never checked and only superflously passed to xfs_icsb_count, so kill it. SGI-PV: 976035 SGI-Modid: xfs-linux-melb:xfs-kern:30920a Signed-off-by: Christoph Hellwig Signed-off-by: David Chinner Signed-off-by: Lachlan McIlroy commit 7cea6a12733b65f444791e0e6f17f0a91deec934 Author: Christoph Hellwig Date: Tue Apr 22 17:34:44 2008 +1000 [XFS] split xfs_icsb_balance_counter Add an xfs_icsb_balance_counter_locked for the case where mp->m_sb_lock is already locked. SGI-PV: 976035 SGI-Modid: xfs-linux-melb:xfs-kern:30918a Signed-off-by: Christoph Hellwig Signed-off-by: David Chinner Signed-off-by: Lachlan McIlroy commit a373394d963ab52f1a9b21f5ce56d13751aaf61b Author: Christoph Hellwig Date: Tue Apr 22 17:34:37 2008 +1000 [XFS] Add a new xfs_icsb_sync_counters_locked for the case where m_sb_lock is already taken and add a flags argument to xfs_icsb_sync_counters so that xfs_icsb_sync_counters_flags is not needed. SGI-PV: 976035 SGI-Modid: xfs-linux-melb:xfs-kern:30917a Signed-off-by: Christoph Hellwig Signed-off-by: David Chinner Signed-off-by: Lachlan McIlroy commit 9402f2900761ed45873117abdc4096c3e085a1bf Author: Barry Naujok Date: Tue Apr 22 17:34:31 2008 +1000 [XFS] Cleanup xfs_attr a bit with xfs_name and remove cred SGI-PV: 976035 SGI-Modid: xfs-linux-melb:xfs-kern:30913a Signed-off-by: Barry Naujok Signed-off-by: Christoph Hellwig Signed-off-by: Lachlan McIlroy commit 8ac17f6487873fba1ecef7d94d2f80eaff73f441 Author: Christoph Hellwig Date: Tue Apr 22 17:34:24 2008 +1000 [XFS] kill usesless IHOLD calls in xfs_remove and xfs_rmdir The VFS always has an inode reference when we call these functions. So we only need to grab a signle reference to each inode that's joined to a transaction - all the other bumping and dropping is as useless as the comments describing the IRIX semantics. SGI-PV: 976035 SGI-Modid: xfs-linux-melb:xfs-kern:30912a Signed-off-by: Christoph Hellwig Signed-off-by: Lachlan McIlroy commit 3074ab06656501681758d3ac32a21eb8965279a4 Author: Christoph Hellwig Date: Tue Apr 22 17:34:18 2008 +1000 [XFS] kill parent == child checks in xfs_remove and xfs_rmdir VFS guaranteed these can't happen. SGI-PV: 976035 SGI-Modid: xfs-linux-melb:xfs-kern:30911a Signed-off-by: Christoph Hellwig Signed-off-by: Lachlan McIlroy commit ebc105734553550d6b175be82bad055d4309a581 Author: Christoph Hellwig Date: Tue Apr 22 17:34:12 2008 +1000 [XFS] kill usesless IHOLD calls in xfs_rename Similar to to the previous patch for remove and rmdir only grab a reference to inodes when we join them to transaction to balance the decrement on transaction completion. Everything else it taken care of by the VFS. Note that the old case had leaks of inode count when src == target or src or target == one of the parent inodes, but these cases are fortunately already rejected by the VFS. SGI-PV: 976035 SGI-Modid: xfs-linux-melb:xfs-kern:30904a Signed-off-by: Christoph Hellwig Signed-off-by: Lachlan McIlroy commit 21ab06b7faede6ab6700a57c47d81733190bc7d9 Author: Christoph Hellwig Date: Tue Apr 22 17:34:06 2008 +1000 [XFS] remove manual lookup from xfs_rename and simplify locking ->rename already gets the target inode passed if it exits. Pass it down to xfs_rename so that we can avoid looking it up again. Also simplify locking as the first lock section in xfs_rename can go away now: the isdir is an invariant over the lifetime of the inode, and new_parent and the nlink check are namespace topology protected by i_mutex in the VFS. The projid check needs to move into the second lock section anyway to not be racy. Also kill the now unused xfs_dir_lookup_int and remove the now-unused first_locked argumet to xfs_lock_inodes. SGI-PV: 976035 SGI-Modid: xfs-linux-melb:xfs-kern:30903a Signed-off-by: Christoph Hellwig Signed-off-by: Lachlan McIlroy commit 045ec68d1569c4e8bc36c15b0f0e04cf009599b5 Author: Christoph Hellwig Date: Tue Apr 22 17:34:00 2008 +1000 [XFS] shrink mrlock_t The writer field is not needed for non_DEBU builds so remove it. While we're at i also clean up the interface for is locked asserts to go through and xfs_iget.c helper with an interface like the xfs_ilock routines to isolated the XFS codebase from mrlock internals. That way we can kill mrlock_t entirely once rw_semaphores grow an islocked facility. Also remove unused flags to the ilock family of functions. SGI-PV: 976035 SGI-Modid: xfs-linux-melb:xfs-kern:30902a Signed-off-by: Christoph Hellwig Signed-off-by: Lachlan McIlroy commit feec3061f79f1d8291db9d9537fb4b8349d38022 Author: Christoph Hellwig Date: Tue Apr 22 17:33:52 2008 +1000 [XFS] simplify xfs_lookup Opencode xfs-kill-xfs_dir_lookup_int here, which gets rid of a lock roundtrip, and lots of stack space. Also kill the di_mode == 0 check that has been done in xfs_iget for a few years now. SGI-PV: 976035 SGI-Modid: xfs-linux-melb:xfs-kern:30901a Signed-off-by: Christoph Hellwig Signed-off-by: Lachlan McIlroy commit 8690b0bb3e066319574aad5a4203787b7d990ed3 Author: Christoph Hellwig Date: Tue Apr 22 17:33:46 2008 +1000 [XFS] xfs_rename: pass resblks to xfs_dir_removename Similar to rmdir and remove - avoids a potential transaction reservation overrun. SGI-PV: 976035 SGI-Modid: xfs-linux-melb:xfs-kern:30900a Signed-off-by: Christoph Hellwig Signed-off-by: Lachlan McIlroy commit 582d7b35dcaad942fe60e0e80415a95329c967c6 Author: Christoph Hellwig Date: Tue Apr 22 17:33:40 2008 +1000 [XFS] kill di_mode checks after xfs_iget Unless XFS_IGET_CREATE is passed xfs_iget will return ENOENT if it encounters an inode with di_mode == 0. Remove the duplicated checks in the callers. (the log recovery case is not touched for now) SGI-PV: 976035 SGI-Modid: xfs-linux-melb:xfs-kern:30898a Signed-off-by: Christoph Hellwig Signed-off-by: Lachlan McIlroy commit 02dd99781db1c0d70aeb6421472afbe9227be47f Author: Christoph Hellwig Date: Tue Apr 22 17:33:33 2008 +1000 [XFS] kill xfs_getattr It's currently used by the ACL code to read di_mode/di_uid, but these are simple 32bit scalar values we can just read directly without locking. SGI-PV: 976035 SGI-Modid: xfs-linux-melb:xfs-kern:30897a Signed-off-by: Christoph Hellwig Signed-off-by: Lachlan McIlroy commit 2bc441c497a2e216c7d1f611e4b9db55918cd792 Author: Christoph Hellwig Date: Tue Apr 22 17:33:25 2008 +1000 [XFS] Remove VN_IS* macros and related cruft. We can just check i_mode / di_mode directly. SGI-PV: 976035 SGI-Modid: xfs-linux-melb:xfs-kern:30896a Signed-off-by: Christoph Hellwig Signed-off-by: Lachlan McIlroy commit 2e328614a2dd874db71911c101aee69c0d754112 Author: Stephen Rothwell Date: Tue Apr 22 15:26:13 2008 +1000 [XFS] Fix build failure after enabling CONFIG_XFS_DEBUG Signed-off-by: Stephen Rothwell Signed-off-by: Lachlan McIlroy commit 7b81ee365f7ad60b9f558b87e97106946d16628d Author: Christoph Hellwig Date: Mon Apr 21 18:11:13 2008 +1000 [XFS] remove dmapi cruft in xfs_file.c The dmapi cruft in xfs_file.c is totally out of date in mainline vs CVS, and at this point just removing this code which can't be used on mainline at all seems to be the best option to keep it maintainable. Signed-off-by: Christoph Hellwig Signed-off-by: Lachlan McIlroy commit 7a3e7d6bc732356fe47339e3bb9113097ae65111 Author: Christoph Hellwig Date: Mon Apr 21 17:25:35 2008 +1000 [XFS] remove sendfile leftovers Remove the last sendfile leftovers in mainline. This code is already gone in CVS. Signed-off-by: Christoph Hellwig Signed-off-by: Lachlan McIlroy commit d8fdb32932789284bb17bc1cb69e0f2da6452040 Author: Christoph Hellwig Date: Mon Apr 21 17:22:27 2008 +1000 [XFS] allow enabling CONFIG_XFS_DEBUG Back when I first submitted XFS for mainline inclusion we made the decision that the debug code is far to extensive to be accidentally enabled by users in mainline. But then again it's often quite useful to track problems down and hacking the makefile all the time is rather annoying. Given all the debug options with even more overhead like lockdep or DEBUG_PAGE_ALLOC users (or rather developers) should know by now what they're doing. Signed-off-by: Christoph Hellwig Signed-off-by: Lachlan McIlroy commit 6cf59734fc9bc89954d0157524eea156c2f9a5ab Author: Marcelo Tosatti Date: Wed Apr 16 17:19:06 2008 -0300 KVM: MMU: kvm_pv_mmu_op should not take mmap_sem kvm_pv_mmu_op should not take mmap_sem. All gfn_to_page() callers down in the MMU processing will take it if necessary, so as it is it can deadlock. Apparently a leftover from the days before slots_lock. Signed-off-by: Marcelo Tosatti Signed-off-by: Avi Kivity commit 1625158d0f89974dc6a235f6ee78c42bb09187ac Author: Hollis Blanchard Date: Thu Apr 17 10:43:36 2008 -0500 KVM: ppc: Kconfig fixes Don't allow building as a module (asm-offsets dependencies). Also, automatically select KVM_BOOKE_HOST until we better separate the guest and host layers. Signed-off-by: Hollis Blanchard Signed-off-by: Avi Kivity commit 0b8ccb17221be6ef343bffb8923e9137dc35d9d8 Author: Joerg Roedel Date: Wed Apr 16 17:01:05 2008 +0200 KVM: SVM: remove selective CR0 comment There is not selective cr0 intercept bug. The code in the comment sets the CR0.PG bit. But KVM sets the CR4.PG bit for SVM always to implement the paged real mode. So the 'mov %eax,%cr0' instruction does not change the CR0.PG bit. Selective CR0 intercepts only occur when a bit is actually changed. So its the right behavior that there is no intercept on this instruction. Signed-off-by: Joerg Roedel Signed-off-by: Avi Kivity commit bbc09c76aa98a58a7ac2849ecc0cd90625429f75 Author: Joerg Roedel Date: Wed Apr 16 16:51:19 2008 +0200 KVM: SVM: remove now obsolete FIXME comment With the usage of the V_TPR field this comment is now obsolete. Signed-off-by: Joerg Roedel Signed-off-by: Avi Kivity commit 229da4986d43a4262f7e19699cbb7fa43d61ad61 Author: Joerg Roedel Date: Wed Apr 16 16:51:18 2008 +0200 KVM: SVM: disable CR8 intercept when tpr is not masking interrupts This patch disables the intercept of CR8 writes if the TPR is not masking interrupts. This reduces the total number CR8 intercepts to below 1 percent of what we have without this patch using Windows 64 bit guests. Signed-off-by: Joerg Roedel Signed-off-by: Avi Kivity commit 4e2fe1fb4375d6bba7100ec0beef35b7ec11200a Author: Joerg Roedel Date: Wed Apr 16 16:51:17 2008 +0200 KVM: SVM: sync V_TPR with LAPIC.TPR if CR8 write intercept is disabled If the CR8 write intercept is disabled the V_TPR field of the VMCB needs to be synced with the TPR field in the local apic. Signed-off-by: Joerg Roedel Signed-off-by: Avi Kivity commit 6cfd8150b7695d7cf94a2b251ba8e817193fc6d9 Author: Joerg Roedel Date: Wed Apr 16 16:51:16 2008 +0200 KVM: export kvm_lapic_set_tpr() to modules This patch exports the kvm_lapic_set_tpr() function from the lapic code to modules. It is required in the kvm-amd module to optimize CR8 intercepts. Signed-off-by: Joerg Roedel Signed-off-by: Avi Kivity commit d55b907c0ab6da62d07a4392e4183c795a99e747 Author: Joerg Roedel Date: Wed Apr 16 16:51:15 2008 +0200 KVM: SVM: sync TPR value to V_TPR field in the VMCB This patch adds syncing of the lapic.tpr field to the V_TPR field of the VMCB. With this change we can safely remove the CR8 read intercept. Signed-off-by: Joerg Roedel Signed-off-by: Avi Kivity commit 98e54bf854274ca6485a85f4efd4f91b422711f1 Author: Hollis Blanchard Date: Wed Apr 16 23:28:09 2008 -0500 KVM: ppc: PowerPC 440 KVM implementation This functionality is definitely experimental, but is capable of running unmodified PowerPC 440 Linux kernels as guests on a PowerPC 440 host. (Only tested with 440EP "Bamboo" guests so far, but with appropriate userspace support other SoC/board combinations should work.) See Documentation/powerpc/kvm_440.txt for technical details. Signed-off-by: Hollis Blanchard Acked-by: Paul Mackerras Signed-off-by: Avi Kivity commit 14bcf17f5538da4cf7c400b3880ec8e8c2ae9f76 Author: Hollis Blanchard Date: Wed Apr 16 23:28:08 2008 -0500 KVM: Add MAINTAINERS entry for PowerPC KVM Signed-off-by: Hollis Blanchard Acked-by: Paul Mackerras Signed-off-by: Avi Kivity commit 402e8267e0667d11d88c7eba99a615cb64543b28 Author: Hollis Blanchard Date: Wed Apr 16 23:28:07 2008 -0500 KVM: ppc: Add DCR access information to struct kvm_run Device Control Registers are essentially another address space found on PowerPC 4xx processors, analogous to PIO on x86. DCRs are always 32 bits, and can be identified by a 32-bit number. We forward most DCR accesses to userspace for emulation (with the exception of CPR0 registers, which can be read directly for simplicity in timebase frequency determination). Signed-off-by: Hollis Blanchard Signed-off-by: Avi Kivity commit dbc0b98a9feb95a65275d9937d815a3bd4300103 Author: Hollis Blanchard Date: Wed Apr 16 23:28:06 2008 -0500 ppc: Export tlb_44x_hwater for KVM PowerPC 440 KVM needs to know how many TLB entries are used for the host kernel linear mapping (it does not modify these mappings when switching between guest and host execution). Signed-off-by: Hollis Blanchard Acked-by: Josh Boyer Acked-by: Paul Mackerras Signed-off-by: Avi Kivity commit 16711143409268e0e8dd343fa1fca8fa5ebafdd0 Author: Hollis Blanchard Date: Tue Apr 15 16:05:42 2008 -0500 KVM: Rename debugfs_dir to kvm_debugfs_dir It's a globally exported symbol now. Signed-off-by: Hollis Blanchard Signed-off-by: Avi Kivity commit 1ba320d3283c60e74f872ea569f639bc399e7ef9 Author: Christian Borntraeger Date: Wed Apr 16 16:06:34 2008 +0200 KVM: ia64: provide get/set_mp_state stubs to fix compile error Since commit ded6fb24fb694bcc5f308a02ec504d45fbc8aaa6 Author: Marcelo Tosatti Date: Fri Apr 11 13:24:45 2008 -0300 KVM: add ioctls to save/store mpstate kvm does not compile on ia64. This patch provides ioctl stubs for ia64 to make kvm.git compile again. Signed-off-by: Avi Kivity commit 90590cfddf74787673b21a190e43eb3d0419d785 Author: Christian Borntraeger Date: Wed Apr 16 16:06:37 2008 +0200 KVM: s390: Change virtio interrupt definitions to follow architecture This patch changes the interrupt defintions for virtio on s390. We now use the extint number 0x2603, which is used as a host interrupt already by z/VM for pfault and dasd_diag. We will use subcode 0x0D to distinguish virtio from dasd and pfault. Signed-off-by: Christian Borntraeger Signed-off-by: Carsten Otte Signed-off-by: Avi Kivity commit e62f6f4d552b5d74f9cfa61893b2e1c9ad0f4abf Author: Christian Borntraeger Date: Wed Apr 16 16:06:34 2008 +0200 KVM: s390: provide get/set_mp_state stubs to fix compile error Since commit ded6fb24fb694bcc5f308a02ec504d45fbc8aaa6 Author: Marcelo Tosatti Date: Fri Apr 11 13:24:45 2008 -0300 KVM: add ioctls to save/store mpstate kvm does not compile on s390. This patch provides ioctl stubs for s390 to make kvm.git compile again. Signed-off-by: Christian Borntraeger Signed-off-by: Carsten Otte Signed-off-by: Avi Kivity commit e12051a4fc46d0e2a1252bde6f3ca3f66b06f0d4 Author: Donald Douwsma Date: Thu Apr 17 16:50:28 2008 +1000 [XFS] Remove unused HAVE_SPLICE macro. HAVE_SPLICE was part of the infrastructure for building 2.4 and 2.6 kernels out of the same tree. Now we don't build 2.4 kernels this SGI-PV: 971046 SGI-Modid: xfs-linux-melb:xfs-kern:30878a Signed-off-by: Donald Douwsma Signed-off-by: Christoph Hellwig Signed-off-by: Lachlan McIlroy commit c0a5bb1e136fd4392733e7e660f183c0341273aa Author: Eric Sandeen Date: Thu Apr 17 16:50:22 2008 +1000 [XFS] Remove CONFIG_XFS_SECURITY. There is no point to the CONFIG_XFS_SECURITY option; it disables the ability to set security attributes at runtime, but it does not actually slim down or remove any code for runtime. Just remove it and always allow security attributes to be set. SGI-PV: 980310 SGI-Modid: xfs-linux-melb:xfs-kern:30877a Signed-off-by: Eric Sandeen Signed-off-by: Tim Shimmin Signed-off-by: Lachlan McIlroy commit a3b8ea42fb10895996040946ec072582da4ed5c0 Author: Tim Shimmin Date: Thu Apr 17 16:50:16 2008 +1000 [XFS] xfs_bmap_compute_maxlevels should be based on di_forkoff instead of m_attr_offset Fix up xfs_bmap_compute_maxlevels() to account for the case when we go from using attr2 to using attr1. In that case attr1 will no longer necessarily be at m_attr_offset>>3, but could be at a different value for di_forkoff. Therefore, we return the worst case scenario using MINDBTPTRS and MINABTPTRS, as this function is used for determining the maximum log space. SGI-PV: 979606 SGI-Modid: xfs-linux-melb:xfs-kern:30862a Signed-off-by: Tim Shimmin Signed-off-by: Eric Sandeen Signed-off-by: Lachlan McIlroy commit 8c64c14cac237b187d4cce2211aaa3b9dc35aa5d Author: Eric Sandeen Date: Thu Apr 17 16:50:09 2008 +1000 [XFS] Always use di_forkoff when checking for attr space. In the case where we mount a filesystem which was previously using the attr2 format as attr1, returning the default mp->m_attroffset instead of the per-inode di_forkoff for inline attribute fit calculations, may result in corruption, if for example, the data fork is already taking more space than the default fork offset and we try to add an extended attribute. Fix tested by xfstests/186. SGI-PV: 979606 SGI-Modid: xfs-linux-melb:xfs-kern:30861a Signed-off-by: Eric Sandeen Signed-off-by: Tim Shimmin Signed-off-by: Lachlan McIlroy commit 4508e853b3a1910a59dd29a4e0bd5240795fac52 Author: David Chinner Date: Thu Apr 17 16:50:04 2008 +1000 [XFS] Ensure the inode is joined in xfs_itruncate_finish On success, we still need to join the inode to the current transaction in xfs_itruncate_finish(). Fixes regression from error handling changes. SGI-PV: 980084 SGI-Modid: xfs-linux-melb:xfs-kern:30845a Signed-off-by: David Chinner Signed-off-by: Christoph Hellwig Signed-off-by: Lachlan McIlroy commit 8069f1d4a10fb8ce58a5eb9857c59671323e98be Author: David Chinner Date: Thu Apr 17 16:49:55 2008 +1000 [XFS] Remove periodic logging of in-core superblock counters. xfssyncd triggers the logging of superblock counters every 30s if the filesystem is made with lazy-count=1. This will prevent disks from idling and spinning down as there will be a log write every 30s. With the way counter recovery works for lazy-count=1, this code is unnecessary and provides no real benefit, so just remove it. SGI-PV: 980145 SGI-Modid: xfs-linux-melb:xfs-kern:30840a Signed-off-by: David Chinner Signed-off-by: Barry Naujok Signed-off-by: Lachlan McIlroy commit 6b356f4343e888260e24737c5e7413828c97afd8 Author: David Chinner Date: Thu Apr 17 16:49:49 2008 +1000 [XFS] 980084 fix logic error in xfs_alloc_ag_vextent_near() Fix a logic error in xfs_alloc_ag_vextent_near(). This is a regression introduced by the error handling changes. SGI-PV: 890084 SGI-Modid: xfs-linux-melb:xfs-kern:30838a Signed-off-by: David Chinner Signed-off-by: Barry Naujok Signed-off-by: Lachlan McIlroy commit ef1ac7f0b3c592d1b08085b637f44f12fb90a56b Author: Barry Naujok Date: Thu Apr 17 16:49:43 2008 +1000 [XFS] Split xfs_dir2_leafn_lookup_int into its two pieces of functionality SGI-PV: 976035 SGI-Modid: xfs-linux-melb:xfs-kern:30834a Signed-off-by: Barry Naujok Signed-off-by: Christoph Hellwig Signed-off-by: Lachlan McIlroy commit 70645759288973974bc4ca3d931f027a108c79b5 Author: David Chinner Date: Thu Apr 17 16:49:35 2008 +1000 [XFS] Don't error out on good I/Os. xfsbdstrat() made all I/Os error out, good or bad. Fix it. SGI-PV: 980084 SGI-Modid: xfs-linux-melb:xfs-kern:30836a Signed-off-by: David Chinner Signed-off-by: Donald Douwsma Signed-off-by: Lachlan McIlroy commit 8d3a833dc9d42f0967e57717f89c518375d6a417 Author: Avi Kivity Date: Mon Apr 14 23:46:37 2008 +0300 KVM: x86 emulator: fix lea to really get the effective address We never hit this, since there is currently no reason to emulate lea. Signed-off-by: Avi Kivity commit 8f2999b2379cd0da5ca81f1fac27931561818266 Author: Avi Kivity Date: Mon Apr 14 23:35:41 2008 +0300 KVM: SVM: Fix force_new_asid() compile warning Signed-off-by: Avi Kivity commit e072eb859fcbfdbc75ed8cf611441da7d89332a3 Author: Avi Kivity Date: Mon Apr 14 14:40:50 2008 +0300 KVM: x86 emulator: fix smsw and lmsw with a memory operand lmsw and smsw were implemented only with a register operand. Extend them to support a memory operand as well. Fixes Windows running some display compatibility test on AMD hosts. Signed-off-by: Avi Kivity commit fdc5d1d0cf97477984675c4a4738633eb6ec5c3b Author: Avi Kivity Date: Mon Apr 14 23:27:07 2008 +0300 KVM: x86 emulator: initialize src.val and dst.val for register operands This lets us treat the case where mod == 3 in the same manner as other cases. Signed-off-by: Avi Kivity commit fc6ac4faee88b6c8c12fb8c970246d0eaacd1aa2 Author: Avi Kivity Date: Mon Apr 14 13:10:21 2008 +0300 KVM: SVM: force a new asid when initializing the vmcb Shutdown interception clears the vmcb, leaving the asid at zero (which is illegal. so force a new asid on vmcb initialization. Signed-off-by: Avi Kivity commit 2e9283fb0ad0a3fe1580f2d95505022cce9c93a7 Author: Marcelo Tosatti Date: Fri Apr 11 15:01:22 2008 -0300 KVM: fix kvm_vcpu_kick vs __vcpu_run race There is a window open between testing of pending IRQ's and assignment of guest_mode in __vcpu_run. Injection of IRQ's can race with __vcpu_run as follows: CPU0 CPU1 kvm_x86_ops->run() vcpu->guest_mode = 0 SET_IRQ_LINE ioctl .. kvm_x86_ops->inject_pending_irq kvm_cpu_has_interrupt() apic_test_and_set_irr() kvm_vcpu_kick if (vcpu->guest_mode) send_ipi() vcpu->guest_mode = 1 So move guest_mode=1 assignment before ->inject_pending_irq, and make sure that it won't reorder after it. Signed-off-by: Marcelo Tosatti Signed-off-by: Avi Kivity commit 415379a31b5f4c17fdc754e1cf5b148f723335c0 Author: Avi Kivity Date: Sun Apr 13 18:55:48 2008 +0300 Revert "KVM: fix kvm_vcpu_kick vs __vcpu_run race" This reverts commit b40ad0133935717e714c8dc448916b0e6f4cf464. It causes virtual interrupts to be delivered with physical irqs disabled, which annoys smp_call_function_single(). Signed-off-by: Avi Kivity commit ded6fb24fb694bcc5f308a02ec504d45fbc8aaa6 Author: Marcelo Tosatti Date: Fri Apr 11 13:24:45 2008 -0300 KVM: add ioctls to save/store mpstate So userspace can save/restore the mpstate during migration. [avi: export the #define constants describing the value] Signed-off-by: Marcelo Tosatti Signed-off-by: Avi Kivity commit d88ba767d79cbb9106df73ba32b2ac429ac9fb0c Author: Avi Kivity Date: Sun Apr 13 17:54:35 2008 +0300 KVM: Rename VCPU_MP_STATE_* to KVM_MP_STATE_* We wish to export it to userspace, so move it into the kvm namespace. Signed-off-by: Avi Kivity commit b40ad0133935717e714c8dc448916b0e6f4cf464 Author: Marcelo Tosatti Date: Fri Apr 11 15:01:22 2008 -0300 KVM: fix kvm_vcpu_kick vs __vcpu_run race There is a window open between testing of pending IRQ's and assignment of guest_mode in __vcpu_run. Injection of IRQ's can race with __vcpu_run as follows: CPU0 CPU1 kvm_x86_ops->run() vcpu->guest_mode = 0 SET_IRQ_LINE ioctl .. kvm_x86_ops->inject_pending_irq kvm_cpu_has_interrupt() apic_test_and_set_irr() kvm_vcpu_kick if (vcpu->guest_mode) send_ipi() vcpu->guest_mode = 1 So move guest_mode=1 assignment before ->inject_pending_irq, and make sure that it won't reorder after it. Signed-off-by: Marcelo Tosatti Signed-off-by: Avi Kivity commit a0d22c57fbf0c67d73ab7ca3416841030e0bc22f Author: Marcelo Tosatti Date: Fri Apr 11 14:53:26 2008 -0300 KVM: hlt emulation should take in-kernel APIC/PIT timers into account Timers that fire between guest hlt and vcpu_block's add_wait_queue() are ignored, possibly resulting in hangs. Also make sure that atomic_inc and waitqueue_active tests happen in the specified order, otherwise the following race is open: CPU0 CPU1 if (waitqueue_active(wq)) add_wait_queue() if (!atomic_read(pit_timer->pending)) schedule() atomic_inc(pit_timer->pending) Signed-off-by: Marcelo Tosatti Signed-off-by: Avi Kivity commit 1c5f974ab7e82d0f3a28cd8fc72088a6e0a4b5fb Author: Joerg Roedel Date: Wed Apr 9 16:04:32 2008 +0200 KVM: SVM: do not intercept task switch with NPT When KVM uses NPT there is no reason to intercept task switches. This patch removes the intercept for it in that case. Signed-off-by: Joerg Roedel Signed-off-by: Avi Kivity commit aed84ca087d7b24d8dd7cf3130d53f22321dcc37 Author: Josef Sipek Date: Fri Apr 11 17:11:02 2008 +1000 [XFS] Update XFS documentation for noikeep/ikeep. Mention how DMAPI affects default for noikeep. Slightly modified since Josef's patch was based on an old xfs.txt prior to Dave's (dgc) checkin which missed going to oss. Signed-off-by: Josef Sipek Signed-off-by: Tim Shimmin commit 795cdcdc0a657c483e369e20c3e5f9bdf2467191 Author: David Chinner Date: Fri Apr 11 17:05:49 2008 +1000 [XFS] Update XFS Documentation for ikeep and ihashsize Update xfs docs for: * In memory inode hashes has been removed. * noikeep is now the default. SGI-PV: 969561 SGI-Modid: 2.6.x-xfs-melb:linux:29481b Signed-off-by: David Chinner Signed-off-by: Christoph Hellwig Signed-off-by: Tim Shimmin commit f57c84f0c5e76716a664b76b71efee19528b78ce Author: Feng(Eric) Liu Date: Thu Apr 10 08:47:53 2008 -0400 KVM: Add kvm trace userspace interface This interface allows user a space application to read the trace of kvm related events through relayfs. Signed-off-by: Feng (Eric) Liu Signed-off-by: Avi Kivity commit 2c4b836109b7e85faa919d6a62ea893e5ed3a69c Author: Avi Kivity Date: Fri Apr 11 02:51:52 2008 +0300 KVM: ia64: Stub out kvmtrace Signed-off-by: Avi Kivity commit adfbebefb5069a670b88996c389019db2e328286 Author: Avi Kivity Date: Fri Apr 11 02:50:40 2008 +0300 KVM: s390: Stub out kvmtrace Signed-off-by: Avi Kivity commit 02e1613b70e894c6c860a20f2168fca546e5a1e3 Author: Feng (Eric) Liu Date: Thu Apr 10 15:31:10 2008 -0400 KVM: Add trace markers Trace markers allow userspace to trace execution of a virtual machine in order to monitor its performance. Signed-off-by: Feng (Eric) Liu Signed-off-by: Avi Kivity commit 35fd5958749448cfa0118d0573c3cfe0ba9e6094 Author: Joerg Roedel Date: Wed Apr 9 14:15:30 2008 +0200 KVM: SVM: add intercept for machine check exception To properly forward a MCE occured while the guest is running to the host, we have to intercept this exception and call the host handler by hand. This is implemented by this patch. Signed-off-by: Joerg Roedel Signed-off-by: Avi Kivity commit 2b720783d4905596ddc64b2e9dcb139d5dce4f79 Author: Joerg Roedel Date: Wed Apr 9 14:15:29 2008 +0200 KVM: SVM: align shadow CR4.MCE with host This patch aligns the host version of the CR4.MCE bit with the CR4 active in the guest. This is necessary to get MCE exceptions when the guest is running. Signed-off-by: Joerg Roedel Signed-off-by: Avi Kivity commit a56ba992710f4e4f5d8432bbb784afcab3210c14 Author: Joerg Roedel Date: Wed Apr 9 14:15:28 2008 +0200 KVM: SVM: indent svm_set_cr4 with tabs instead of spaces The svm_set_cr4 function is indented with spaces. This patch replaces them with tabs. Signed-off-by: Joerg Roedel Signed-off-by: Avi Kivity commit 0c444a223f9d7847e607d57665bfbd0a057070a8 Author: David Chinner Date: Thu Apr 10 12:24:38 2008 +1000 [XFS] Catch log unmount failures. Unmounting the log can fail. unlikely, but it can. Catch all the error conditions an make sure it's propagated upwards. SGI-PV: 980084 SGI-Modid: xfs-linux-melb:xfs-kern:30833a Signed-off-by: David Chinner Signed-off-by: Niv Sardi Signed-off-by: Lachlan McIlroy commit f218cac9d7df57b93352e6730a255186bf0a6303 Author: David Chinner Date: Thu Apr 10 12:24:30 2008 +1000 [XFS] Sanitise xfs_log_force error checking. xfs_log_force() is declared to return an error, but we almost never check it. We don't need to check it in most cases; if there's a log I/O error then we'll be shutting down the filesystem anyway and that means we'll catch the error somewhere else. However, on certain calls we should be returning an error - sync transactions, fsync, sync writes, etc. so this isn't a pure black and white distinction. Hence make xfs_log_force() a void function that issues a warning to the syslog on error, and call _xfs_log_force() in all the places where we actually care about the error status returned. SGI-PV: 980084 SGI-Modid: xfs-linux-melb:xfs-kern:30832a Signed-off-by: David Chinner Signed-off-by: Niv Sardi Signed-off-by: Lachlan McIlroy commit 41ca6fa27f06e8de4408217871a9b2120401d98b Author: David Chinner Date: Thu Apr 10 12:24:24 2008 +1000 [XFS] Check for errors when changing buffer pointers. xfs_buf_associate_memory() can fail, but the return is never checked. Propagate the error through XFS_BUF_SET_PTR() so that failures are detected. SGI-PV: 980084 SGI-Modid: xfs-linux-melb:xfs-kern:30831a Signed-off-by: David Chinner Signed-off-by: Niv Sardi Signed-off-by: Lachlan McIlroy commit 037dffc79ec9369b6482b59c454c768e75487fe2 Author: David Chinner Date: Thu Apr 10 12:24:17 2008 +1000 [XFS] Don't allow silent errors in xfs_inactive(). xfs_inactive() fails to report errors when committing the inactive transaction. Hence we can get silent failures either finishing off the truncation or committing the transaction. Even if we get errors, we need to continue, so simply warn loudly to the system if we get errors here. SGI-PV: 980084 SGI-Modid: xfs-linux-melb:xfs-kern:30830a Signed-off-by: David Chinner Signed-off-by: Niv Sardi Signed-off-by: Lachlan McIlroy commit bf543453aa2eac9b7fcacdd2e260b48bfcaf8a2c Author: David Chinner Date: Thu Apr 10 12:24:10 2008 +1000 [XFS] Catch errors from xfs_imap(). Catch errors from xfs_imap() in log recovery when we might be trying to map an invalid inode number due to a corrupted log. SGI-PV: 980084 SGI-Modid: xfs-linux-melb:xfs-kern:30829a Signed-off-by: David Chinner Signed-off-by: Niv Sardi Signed-off-by: Lachlan McIlroy commit cdbe9067bc70f2fbe1e643ee6b9ee57294c29ac9 Author: David Chinner Date: Thu Apr 10 12:24:04 2008 +1000 [XFS] xaiki@sgi.com xfs_bulkstat_one_dinode() never returns an error. Mark it void. SGI-PV: 980084 SGI-Modid: xfs-linux-melb:xfs-kern:30828a Signed-off-by: David Chinner Signed-off-by: Niv Sardi Signed-off-by: Lachlan McIlroy commit 21e292ec7f9e6787067819f832bbde1bc2679263 Author: David Chinner Date: Thu Apr 10 12:23:58 2008 +1000 [XFS] xfs_iflush_fork() never returns an error. xfs_iflush_fork() never returns an error. Mark it void and clean up the code calling it that checks for errors. SGI-PV: 980084 SGI-Modid: xfs-linux-melb:xfs-kern:30827a Signed-off-by: David Chinner Signed-off-by: Niv Sardi Signed-off-by: Lachlan McIlroy commit c5d28c866f9b4825c184a941999ba2d5e6b8bba2 Author: David Chinner Date: Thu Apr 10 12:23:52 2008 +1000 [XFS] Catch unwritten extent conversion errors. On unwritten I/O completion, we fail to propagate an error when converting the extent to a written extent. This means that the I/O silently fails. propagate the error onto the ioend so that the inode is marked with an error appropriately. SGI-PV: 980084 SGI-Modid: xfs-linux-melb:xfs-kern:30826a Signed-off-by: David Chinner Signed-off-by: Niv Sardi Signed-off-by: Lachlan McIlroy commit 7842f22d02cf609ea1eb4f7ae4701e000129b10f Author: David Chinner Date: Thu Apr 10 12:23:46 2008 +1000 [XFS] xfs_bdwrite() does not return errors. xfs_bdwrite() cannot return an error; it only queues buffers to the delayed write list and as such never encounters anything that can fail. Mark it void. SGI-PV: 980084 SGI-Modid: xfs-linux-melb:xfs-kern:30825a Signed-off-by: David Chinner Signed-off-by: Niv Sardi Signed-off-by: Lachlan McIlroy commit 9a5933a7421aca2fea2d31fac9673d38b390f151 Author: David Chinner Date: Thu Apr 10 12:22:24 2008 +1000 [XFS] Ensure xfs_bawrite() errors are checked. xfs_bawrite() can return immediate error status on async writes. Unlike xfsbdstrat() we don't ever check the error on the buffer after the call, so we currently do not catch errors at all here. Ensure we catch and propagate or warn to the syslog about up-front async write errors. SGI-PV: 980084 SGI-Modid: xfs-linux-melb:xfs-kern:30824a Signed-off-by: David Chinner Signed-off-by: Niv Sardi Signed-off-by: Lachlan McIlroy commit fdebc17ef561e0b5118feaa7d89fd0c498d0278e Author: David Chinner Date: Thu Apr 10 12:22:17 2008 +1000 [XFS] Ensure errors from xfs_bdstrat() are correctly checked. xfsbdstrat() is declared to return an error. That is never checked because the error is propagated by the xfs_buf_t that is passed through the function. Mark xfsbdstrat() as returning void and comment the prototype on the methods needed for error checking. SGI-PV: 980084 SGI-Modid: xfs-linux-melb:xfs-kern:30823a Signed-off-by: David Chinner Signed-off-by: Niv Sardi Signed-off-by: Lachlan McIlroy commit 6c0cfb49c45d584ac89c2acd0a42fd96fba7e307 Author: Barry Naujok Date: Thu Apr 10 12:22:07 2008 +1000 [XFS] remove bhv_vname_t and xfs_rename code SGI-PV: 976035 SGI-Modid: xfs-linux-melb:xfs-kern:30804a Signed-off-by: Barry Naujok Signed-off-by: Christoph Hellwig Signed-off-by: Lachlan McIlroy commit ac742bd8df1b2f0dbd1862e646ddde474f42d3bc Author: David Chinner Date: Thu Apr 10 12:21:59 2008 +1000 [XFS] Catch errors returned from xfs_bmap_last_offset(). xfs_bmap_last_offset() can fail and return an error. xfs_iomap_write_allocate() fails to detect and propagate the error. SGI-PV: 980084 SGI-Modid: xfs-linux-melb:xfs-kern:30802a Signed-off-by: David Chinner Signed-off-by: Niv Sardi Signed-off-by: Lachlan McIlroy commit 039072adbdc5c2cb9e29bfbd27d43edc5146e2b4 Author: David Chinner Date: Thu Apr 10 12:21:53 2008 +1000 [XFS] Check for xfs_free_extent() failing. xfs_free_extent() can fail, but log recovery never bothers to check if it successfully free the extent it was supposed to. This could lead to silent corruption during log recovery. Abort log recovery if we fail to free an extent. SGI-PV: 980084 SGI-Modid: xfs-linux-melb:xfs-kern:30801a Signed-off-by: David Chinner Signed-off-by: Niv Sardi Signed-off-by: Lachlan McIlroy commit f8700a6c0a068490eda469fe4340c106fc3db1f2 Author: David Chinner Date: Thu Apr 10 12:21:46 2008 +1000 [XFS] Warn if errors come from block_truncate_page(). block_truncate_page() can return errors that we currently ignore and silently discard. We should not ever get errors reported here - an error indicates a bug somewhere else. Hence catch the error and issue a stack dump to the syslog because we cannot propagate the error any further up the call chain. SGI-PV: 980084 SGI-Modid: xfs-linux-melb:xfs-kern:30800a Signed-off-by: David Chinner Signed-off-by: Niv Sardi Signed-off-by: Lachlan McIlroy commit cd5a1f3da6036b7376dc7653da0874ba6bdba872 Author: David Chinner Date: Thu Apr 10 12:21:40 2008 +1000 [XFS] xfs_bmap_adjacent() never returns an error. Mark it void. SGI-PV: 980084 SGI-Modid: xfs-linux-melb:xfs-kern:30798a Signed-off-by: David Chinner Signed-off-by: Niv Sardi Signed-off-by: Lachlan McIlroy commit 82ee65179169621e3875939a11cc758f72cd414b Author: David Chinner Date: Thu Apr 10 12:21:32 2008 +1000 [XFS] Make xfs_alloc_compute_aligned() void. xfs_alloc_compute_aligned() returns a value based on a comparison of the computed extent length and the minimum length allowed. This is only used by some callers - the other four return parameters are used more often. Hence move the comparison to the code that actually needs to do it and make xfs_alloc_compute_aligned() a void function. SGI-PV: 980084 SGI-Modid: xfs-linux-melb:xfs-kern:30797a Signed-off-by: David Chinner Signed-off-by: Niv Sardi Signed-off-by: Lachlan McIlroy commit 3e6860868a21374a2fe8e3cac896f84b0b679423 Author: David Chinner Date: Thu Apr 10 12:21:25 2008 +1000 [XFS] Clean up xfs_alloc_search_busy() return values. xfs_alloc_search_busy() returns an index into the busy array if the extent was found in the array. This is never checked, and the xfs_alloc_search_busy() does a log force to prevent reuse of the extent before the free transaction hits the disk. Hence the return value is useless. Declare the function void and remove the slot number from the tracing as well. SGI-PV: 980084 SGI-Modid: xfs-linux-melb:xfs-kern:30796a Signed-off-by: David Chinner Signed-off-by: Niv Sardi Signed-off-by: Lachlan McIlroy commit 96ed8156967b75eaa9998de25ce8fade3518d200 Author: David Chinner Date: Thu Apr 10 12:21:18 2008 +1000 [XFS] Propagate errors from xfs_trans_commit(). xfs_trans_commit() can return errors when there are problems in the transaction subsystem. They are indicative that the entire transaction may be incomplete, and hence the error should be propagated as there is a good possibility that there is something fatally wrong in the filesystem. Catch and propagate or warn about commit errors in the places where they are currently ignored. SGI-PV: 980084 SGI-Modid: xfs-linux-melb:xfs-kern:30795a Signed-off-by: David Chinner Signed-off-by: Niv Sardi Signed-off-by: Lachlan McIlroy commit b72d08b99d36168c4df1884ca052585343cb2867 Author: David Chinner Date: Thu Apr 10 12:21:11 2008 +1000 [XFS] Propagate xfs_trans_reserve() errors. xfs_trans_reserve() reports errors that should not be ignored. For example, a shutdown filesystem will report errors through xfs_trans_reserve() to prevent further changes from being attempted on a damaged filesystem. Catch and propagate all error conditions from xfs_trans_reserve(). SGI-PV: 980084 SGI-Modid: xfs-linux-melb:xfs-kern:30794a Signed-off-by: David Chinner Signed-off-by: Niv Sardi Signed-off-by: Lachlan McIlroy commit a87458d47ee866843fc04aacf20d1251e01943e9 Author: David Chinner Date: Thu Apr 10 12:21:04 2008 +1000 [XFS] Catch errors from xfs_acl_vremove(). Removing an ACL can return an error. Propagate it. SGI-PV: 980084 SGI-Modid: xfs-linux-melb:xfs-kern:30793a Signed-off-by: David Chinner Signed-off-by: Niv Sardi Signed-off-by: Lachlan McIlroy commit 89826e0872ac077548395668da3e4c67526566a2 Author: David Chinner Date: Thu Apr 10 12:20:58 2008 +1000 [XFS] Catch errors from xfs_acl_setmode(). Propagate the error status from xfs_acl_setmode() so that callers know if the ACl was set correctly or not. SGI-PV: 980084 SGI-Modid: xfs-linux-melb:xfs-kern:30792a Signed-off-by: David Chinner Signed-off-by: Niv Sardi Signed-off-by: Lachlan McIlroy commit 8908d8f5cd7f5092f3082fdbf8eec9924b097f86 Author: David Chinner Date: Thu Apr 10 12:20:51 2008 +1000 [XFS] Propagate quota file truncation errors. Truncating the quota files can silently fail. Ensure that truncation errors are propagated to the callers. SGI-PV: 980084 SGI-Modid: xfs-linux-melb:xfs-kern:30791a Signed-off-by: David Chinner Signed-off-by: Niv Sardi Signed-off-by: Lachlan McIlroy commit 94217c0bc920ba3938121c3afcad8213541dd39b Author: David Chinner Date: Thu Apr 10 12:20:45 2008 +1000 [XFS] Catch errors when turning off quotas. When turning off quota, we need to write various transactions to the log to ensure that they are cleanly removed in the case of a crash. We need to check that the transactions hit the disk correctly. If we fail to write the final quota off transaction, we are corrupt in memory and so the only option is to shut the filesystem down at this point. SGI-PV: 980084 SGI-Modid: xfs-linux-melb:xfs-kern:30790a Signed-off-by: David Chinner Signed-off-by: Niv Sardi Signed-off-by: Lachlan McIlroy commit 530459ed5a1ca42a8a8fc4f05e066c502b771669 Author: David Chinner Date: Thu Apr 10 12:20:38 2008 +1000 [XFS] Catch errors resetting quota flags. Warn to the syslog if we fail to reset the quota flags in the superblock when a quota check fails. SGI-PV: 980084 SGI-Modid: xfs-linux-melb:xfs-kern:30789a Signed-off-by: David Chinner Signed-off-by: Niv Sardi Signed-off-by: Lachlan McIlroy commit 6ee5d5fb8904076066e27e153ef9fdfe45bc5404 Author: David Chinner Date: Thu Apr 10 12:20:31 2008 +1000 [XFS] Clean up quotamount error handling. xfs_qm_mount_quotas() returns an error status that is ignored. If we fail to mount quotas, we continue with quota's turned off, which is all handled inside xfs_qm_mount_quotas(). Mark it as void to indicate that errors need not be returned to the callers. SGI-PV: 980084 SGI-Modid: xfs-linux-melb:xfs-kern:30788a Signed-off-by: David Chinner Signed-off-by: Niv Sardi Signed-off-by: Lachlan McIlroy commit 9db4aa4d941d72dac8b67cd3a5550d70b57d59b4 Author: David Chinner Date: Thu Apr 10 12:20:24 2008 +1000 [XFS] Check for dquot flush errors xfs_qm_dqflush() can fail, but the return is not checked anywhere. Hence we never know if we've failed to flush a dquot to disk. Propagate the error and warn to the syslog if a flush ever fails. SGI-PV: 980084 SGI-Modid: xfs-linux-melb:xfs-kern:30787a Signed-off-by: David Chinner Signed-off-by: Niv Sardi Signed-off-by: Lachlan McIlroy commit 119b6b8182e4cadba91a72d3b216cf3e18acc46d Author: David Chinner Date: Thu Apr 10 12:20:17 2008 +1000 [XFS] Propagate xfs_qm_dqflush_all() errors. xfs_qm_dqflush_all() can return flush errors. Ensure they are propagated into the quotacheck code to determine if the quotacheck succeeded or not. SGI-PV: 980084 SGI-Modid: xfs-linux-melb:xfs-kern:30786a Signed-off-by: David Chinner Signed-off-by: Niv Sardi Signed-off-by: Lachlan McIlroy commit dae1502477a6e24ac59717083a18fcdf4164dfc8 Author: David Chinner Date: Thu Apr 10 12:20:10 2008 +1000 [XFS] xfs_qm_reset_dqcounts() does not return errors. Declare it void. SGI-PV: 980084 SGI-Modid: xfs-linux-melb:xfs-kern:30785a Signed-off-by: David Chinner Signed-off-by: Niv Sardi Signed-off-by: Lachlan McIlroy commit 8ae2768dfa78fdf300f54572829a3519a4029e82 Author: David Chinner Date: Thu Apr 10 12:20:03 2008 +1000 [XFS] Report errors from xfs_reserve_blocks(). xfs_reserve_blocks() can fail in interesting ways. In neither case is it a fatal error, but the result can lead to sub-optimal behaviour. Warn to the syslog if the call fails but otherwise continue. SGI-PV: 980084 SGI-Modid: xfs-linux-melb:xfs-kern:30784a Signed-off-by: David Chinner Signed-off-by: Niv Sardi Signed-off-by: Lachlan McIlroy commit 08bee6af68dd3a22861513e7736be83b98400b5b Author: David Chinner Date: Thu Apr 10 12:19:56 2008 +1000 [XFS] xfs_icsb_counter_disabled() never returns an error. Mark it void. SGI-PV: 980084 SGI-Modid: xfs-linux-melb:xfs-kern:30782a Signed-off-by: David Chinner Signed-off-by: Niv Sardi Signed-off-by: Lachlan McIlroy commit dfa14aa44bc1895d9bdbd5ccc06c9342546e4051 Author: David Chinner Date: Thu Apr 10 12:19:47 2008 +1000 [XFS] Remove useless whitespace in function prototypes Makes it simpler to annotate function prototypes with __must_check via sed scripts. SGI-PV: 980084 SGI-Modid: xfs-linux-melb:xfs-kern:30781a Signed-off-by: David Chinner Signed-off-by: Niv Sardi Signed-off-by: Lachlan McIlroy commit 9e440b5292fb9d65836105747594dc69dfaad06e Author: David Chinner Date: Thu Apr 10 12:19:40 2008 +1000 [XFS] xfs_quiesce_fs() never returns an error. Mark it void. SGI-PV: 980084 SGI-Modid: xfs-linux-melb:xfs-kern:30780a Signed-off-by: David Chinner Signed-off-by: Niv Sardi Signed-off-by: Lachlan McIlroy commit 1dba7e203d4de510d1082fc65d245fec541556c2 Author: Eric Sandeen Date: Thu Apr 10 12:19:34 2008 +1000 [XFS] Ensure "both" features2 slots are consistent Since older kernels may look in the sb_bad_features2 slot for flags, rather than zeroing it out on fixup, we should make it equal to the sb_features2 value. Also, if the ATTR2 flag was not found prior to features2 fixup, it was not set in the mount flags, so re-check after the fixup so that the current session will use the feature. Also fix up the comments to reflect these changes. SGI-PV: 980085 SGI-Modid: xfs-linux-melb:xfs-kern:30778a Signed-off-by: Eric Sandeen Signed-off-by: David Chinner Signed-off-by: Lachlan McIlroy commit 50dbfa5d8b9300993f3da3d17bdac15922032f3a Author: Christoph Hellwig Date: Thu Apr 10 12:19:27 2008 +1000 [XFS] Don't validate symlink target component length This target component validation is not POSIX conformant and it is not done by any other Linux filesystem so remove it from XFS. SGI-PV: 980080 SGI-Modid: xfs-linux-melb:xfs-kern:30776a Signed-off-by: Christoph Hellwig Signed-off-by: David Chinner Signed-off-by: Lachlan McIlroy commit cb473a842a2e8d226bd37502c18d3a73be1e3868 Author: Harvey Harrison Date: Thu Apr 10 12:19:21 2008 +1000 [XFS] replace remaining __FUNCTION__ occurrences __FUNCTION__ is gcc-specific, use __func__ SGI-PV: 976035 SGI-Modid: xfs-linux-melb:xfs-kern:30775a Signed-off-by: Harvey Harrison Signed-off-by: David Chinner Signed-off-by: Lachlan McIlroy commit 2f6997ae21d6279b357802cc0223bd6902a99ac3 Author: Harvey Harrison Date: Thu Apr 10 12:19:10 2008 +1000 [XFS] Replace __inline with inline Remove the remaining uses of __inline in the XFS code base. SGI-PV: 976035 SGI-Modid: xfs-linux-melb:xfs-kern:30774a Signed-off-by: Harvey Harrison Signed-off-by: David Chinner Signed-off-by: Lachlan McIlroy commit db2423e28010e0def1c99fbe2928fee34b252c35 Author: David Chinner Date: Thu Apr 10 12:19:02 2008 +1000 [XFS] Fix lock inversion in forced shutdown. Recent changes to xlog_state_release_iclog() placed the grant_lock inside the icloglock. forced unmount of the log does this the opposite way around, but does not depend on the order for correct working. Fix the inversion by changing the order locks are gained in xfs_log_force_umount(). SGI-PV: 979661 SGI-Modid: xfs-linux-melb:xfs-kern:30773a Signed-off-by: David Chinner Signed-off-by: Christoph Hellwig Signed-off-by: Lachlan McIlroy commit 0699ef5e35a81ce30733fbd5419f4b19957bb2fe Author: David Chinner Date: Thu Apr 10 12:18:54 2008 +1000 [XFS] Reorganise xlog_t for better cacheline isolation of contention To reduce contention on the log in large CPU count, separate out different parts of the xlog_t structure onto different cachelines. Move each lock onto a different cacheline along with all the members that are accessed/modified while that lock is held. Also, move the debugging code into debug code. SGI-PV: 978729 SGI-Modid: xfs-linux-melb:xfs-kern:30772a Signed-off-by: David Chinner Signed-off-by: Lachlan McIlroy commit ebf384baf60434eb3e7b5653ca267e0c76f65145 Author: David Chinner Date: Thu Apr 10 12:18:46 2008 +1000 [XFS] Remove the xlog_ticket allocator The ticket allocator is just a simple slab implementation internal to the log. It requires the icloglock to be held when manipulating it and this contributes to contention on that lock. Just kill the entire allocator and use a memory zone instead. While there, allow us to gracefully fail allocation with ENOMEM. SGI-PV: 978729 SGI-Modid: xfs-linux-melb:xfs-kern:30771a Signed-off-by: David Chinner Signed-off-by: Christoph Hellwig Signed-off-by: Lachlan McIlroy commit 86308015dfc99c4eecc6d9de96cc189b75067478 Author: David Chinner Date: Thu Apr 10 12:18:39 2008 +1000 [XFS] Per iclog callback chain lock Rather than use the icloglock for protecting the iclog completion callback chain, use a new per-iclog lock so that walking the callback chain doesn't require holding a global lock. This reduces contention on the icloglock during transaction commit and log I/O completion by reducing the number of times we need to hold the global icloglock during these operations. SGI-PV: 978729 SGI-Modid: xfs-linux-melb:xfs-kern:30770a Signed-off-by: David Chinner Signed-off-by: Christoph Hellwig Signed-off-by: Lachlan McIlroy commit b1afe0f37aeaa8af6240bf2bf444de1809fe06cc Author: Izik Eidus Date: Fri Apr 4 10:11:47 2008 +0300 KVM: fix errors in the task switching support Signed-off-by: Izik Eidus Signed-off-by: Avi Kivity commit a6690e259ce2d808d0fc74ce4bebd0ae25d63588 Author: Avi Kivity Date: Sun Apr 6 14:25:46 2008 +0300 KVM: Register ioctl range Signed-off-by: Avi Kivity commit 451e2877b1b96e4dd63bb466263c3b77b75693a6 Author: Anthony Liguori Date: Wed Apr 2 14:46:56 2008 -0500 KVM: MMU: Don't assume struct page for x86 This patch introduces a gfn_to_pfn() function and corresponding functions like kvm_release_pfn_dirty(). Using these new functions, we can modify the x86 MMU to no longer assume that it can always get a struct page for any given gfn. We don't want to eliminate gfn_to_page() entirely because a number of places assume they can do gfn_to_page() and then kmap() the results. When we support IO memory, gfn_to_page() will fail for IO pages although gfn_to_pfn() will succeed. This does not implement support for avoiding reference counting for reserved RAM or for IO memory. However, it should make those things pretty straight forward. Since we're only introducing new common symbols, I don't think it will break the non-x86 architectures but I haven't tested those. I've tested Intel, AMD, NPT, and hugetlbfs with Windows and Linux guests. [avi: fix overflow when shifting left pfns by adding casts] Signed-off-by: Anthony Liguori Signed-off-by: Avi Kivity commit 6d0016f027020ede2cf72bf3b4604c8d64b46ff5 Author: Xiantao Zhang Date: Tue Apr 1 15:08:29 2008 +0800 KVM: ia64: Add a guide about how to create kvm guests on ia64 Guide for creating virtual machine on kvm/ia64. Signed-off-by: Xiantao Zhang Signed-off-by: Avi Kivity commit 592f9f05061afe2143839fc55e2fa316b44bba24 Author: Xiantao Zhang Date: Fri Mar 28 14:58:47 2008 +0800 KVM: ia64: Enable kvm build for ia64 Update the related Makefile and KConfig for kvm build Signed-off-by: Xiantao Zhang Signed-off-by: Avi Kivity commit 210667533cd54e256466702ce11ffc9d6474e4e8 Author: Xiantao Zhang Date: Tue Apr 1 14:59:30 2008 +0800 KVM: ia64: Add kvm sal/pal virtulization support Some sal/pal calls would be traped to kvm for virtulization from guest firmware. Signed-off-by: Xiantao Zhang Signed-off-by: Avi Kivity commit 72615bdc20434accd9e1a4e8a76e489709267937 Author: Xiantao Zhang Date: Tue Apr 1 14:58:42 2008 +0800 KVM: ia64: Add guest interruption injection support process.c mainly handle interruption injection, and some faults handling. Signed-off-by: Anthony Xu Signed-off-by: Xiantao Zhang Signed-off-by: Avi Kivity commit dee120d7a5b8f924b4ac94d0da15f6c89a254f21 Author: Xiantao Zhang Date: Tue Apr 1 14:57:53 2008 +0800 KVM: ia64: Generate offset values for assembly code use asm-offsets.c will generate offset values used for assembly code for some fileds of special structures. Signed-off-by: Anthony Xu Signed-off-by: Xiantao Zhang Signed-off-by: Avi Kivity commit 95f578198d51b2f3399928ce31057f0827213170 Author: Xiantao Zhang Date: Tue Apr 1 14:57:09 2008 +0800 KVM: ia64: Add optimization for some virtulization faults optvfault.S Add optimization for some performance-critical virtualization faults. Signed-off-by: Anthony Xu Signed-off-by: Xiantao Zhang Signed-off-by: Avi Kivity commit d08786e6e514c2f042ce50a91f86b8c84ed9b97c Author: Xiantao Zhang Date: Tue Apr 1 16:14:28 2008 +0800 KVM: ia64: Add processor virtulization support vcpu.c provides processor virtualization logic for kvm. Signed-off-by: Anthony Xu Signed-off-by: Xiantao Zhang Signed-off-by: Avi Kivity commit 0fa607f334de0e13633dd730ae2337ed6504bb42 Author: Xiantao Zhang Date: Tue Apr 1 14:54:42 2008 +0800 KVM: ia64: Add trampoline for guest/host mode switch trampoline code targets for guest/host world switch. Signed-off-by: Xiantao Zhang Signed-off-by: Avi Kivity commit b712a2254d6d529c27dcdeb6b405ae04d87dc91c Author: Xiantao Zhang Date: Tue Apr 1 14:53:32 2008 +0800 KVM: ia64: Add mmio decoder for kvm/ia64 mmio.c includes mmio decoder, and related mmio logics. Signed-off-by: Anthony Xu Signed-off-by: Xiantao Zhang Signed-off-by: Avi Kivity commit ef126baa266b2ad3001dd02f690bc06c42d465cf Author: Xiantao Zhang Date: Tue Apr 1 14:52:19 2008 +0800 KVM: ia64: Add interruption vector table for vmm vmm_ivt.S includes an ivt for vmm use. Signed-off-by: Anthony Xu Signed-off-by: Xiantao Zhang Signed-off-by: Avi Kivity commit 7394cac69d8ceb3031612899eb95560771ee602a Author: Xiantao Zhang Date: Tue Apr 1 14:50:59 2008 +0800 KVM: ia64: Add TLB virtulization support vtlb.c includes tlb/VHPT virtulization. Signed-off-by: Anthony Xu Signed-off-by: Xiantao Zhang Signed-off-by: Avi Kivity commit 61897077f93957752edfa7eb22ec612087244326 Author: Xiantao Zhang Date: Tue Apr 1 14:49:24 2008 +0800 KVM: ia64: VMM module interfaces vmm.c adds the interfaces with kvm/module, and initialize global data area. Signed-off-by: Xiantao Zhang Signed-off-by: Avi Kivity commit 3a7a7fb662405979192c16a5984ddf8872cefde6 Author: Xiantao Zhang Date: Tue Apr 1 16:00:24 2008 +0800 KVM: ia64: Add header files for kvm/ia64 kvm_minstate.h : Marcos about Min save routines. lapic.h: apic structure definition. vcpu.h : routions related to vcpu virtualization. vti.h : Some macros or routines for VT support on Itanium. Signed-off-by: Xiantao Zhang Signed-off-by: Avi Kivity commit 45a17d2a1a1dbdb5411c6a350f90f14c50d30ade Author: Xiantao Zhang Date: Tue Apr 1 15:29:29 2008 +0800 KVM: ia64: Add kvm arch-specific core code for kvm/ia64 kvm_ia64.c is created to handle kvm ia64-specific core logic. Signed-off-by: Xiantao Zhang Signed-off-by: Avi Kivity commit fdcf624ab5b00dcf5a0430cdfd87c58a77c09cda Author: Xiantao Zhang Date: Tue Apr 1 14:45:06 2008 +0800 KVM: ia64: Add header files for kvm/ia64 Three header files are added: asm-ia64/kvm.h asm-ia64/kvm_host.h asm-ia64/kvm_para.h Signed-off-by: Xiantao Zhang Signed-off-by: Avi Kivity commit 9ddc4c66ad60a835d444b0fe4636fd1dd67708a9 Author: Xiantao Zhang Date: Tue Apr 1 14:42:00 2008 +0800 KVM: ia64: Prepare some structure and routines for kvm use Register structures are defined per SDM. Add three small routines for kernel: ia64_ttag, ia64_loadrs, ia64_flushrs Signed-off-by: Xiantao Zhang Signed-off-by: Avi Kivity commit 6cf0e51910528e862b497c9e5884f993f50df9b0 Author: Xiantao Zhang Date: Tue Apr 1 14:38:21 2008 +0800 ia64: Implement smp_call_function_mask for ia64 This interface provides more flexible functionality for smp infrastructure. Signed-off-by: Xiantao Zhang Signed-off-by: Avi Kivity commit 866298b75903d9313fa4f08ccdff34bcb846d6ea Author: Xiantao Zhang Date: Tue Apr 1 14:34:50 2008 +0800 ia64: Add API for allocating Dynamic TR resource Dynamic TR resource should be managed in the uniform way. Add two interfaces for kernel: ia64_itr_entry: Allocate a (pair of) TR for caller. ia64_ptr_entry: Purge a (pair of ) TR by caller. Signed-off-by: Xiantao Zhang Signed-off-by: Anthony Xu Signed-off-by: Avi Kivity commit 3743888cafbada95d9907a1b5fb001993b1ee03e Author: Marcelo Tosatti Date: Fri Apr 4 17:21:22 2008 -0300 KVM: MMU: account for start offset on largepage aligned-sized memslots Account for the case where memslot size is largepage aligned, but does not start on largepage aligned offset. Otherwise it allocates one lpage_info struct less than what the memslot spans, possibly resulting in memory corruption. Signed-off-by: Marcelo Tosatti Signed-off-by: Avi Kivity commit fafac27bad9f4d8fd9f0b50e41c5591eb0805cd7 Author: Heiko Carstens Date: Fri Apr 4 16:03:34 2008 +0200 KVM: s390: Improve pgste accesses There is no need to use interlocked updates when the rcp lock is held. Therefore the simple bitops variants can be used. This should improve performance. Signed-off-by: Heiko Carstens Signed-off-by: Carsten Otte Signed-off-by: Avi Kivity commit d17db823b65d6d215193f4ad2ba517dcaa2a4c54 Author: Heiko Carstens Date: Fri Apr 4 15:12:40 2008 +0200 KVM: s390: rename stfl to kvm_stfl Temporarily rename this function to avoid merge conflicts and/or dependencies. This function will be removed as soon as git-s390 and kvm.git are finally upstream. Signed-off-by: Heiko Carstens Signed-off-by: Carsten Otte Signed-off-by: Avi Kivity commit bcb0dd888c478e229aa6c60d7ab81e81bde47aef Author: Heiko Carstens Date: Fri Apr 4 15:12:35 2008 +0200 KVM: s390: Fix incorrect return value kvm_arch_vcpu_ioctl_run currently incorrectly always returns 0. Signed-off-by: Heiko Carstens Signed-off-by: Carsten Otte Signed-off-by: Avi Kivity commit a02bb9e2793e906022885eb49d5a58a212e8953a Author: Heiko Carstens Date: Fri Apr 4 15:12:32 2008 +0200 KVM: s390: Some codingstyle issues. Just a few codingstyle issues that have already been commented on but that somehow got forgotten. Signed-off-by: Heiko Carstens Signed-off-by: Carsten Otte Signed-off-by: Avi Kivity commit c415209f8a62eb3987b16c16b7f800d44ec6acda Author: Marcelo Tosatti Date: Fri Apr 4 14:56:44 2008 -0300 KVM: MMU: prepopulate guest pages after write-protecting Zdenek reported a bug where a looping "dmsetup status" eventually hangs on SMP guests. The problem is that kvm_mmu_get_page() prepopulates the shadow MMU before write protecting the guest page tables. By doing so, it leaves a window open where the guest can mark a pte as present while the host has shadow cached such pte as "notrap". Accesses to such address will fault in the guest without the host having a chance to fix the situation. Fix by moving the write protection before the pte prefetch. Signed-off-by: Marcelo Tosatti Signed-off-by: Avi Kivity commit cdc022c58ef17e874520a9d4a85040ea1fb12a66 Author: Avi Kivity Date: Thu Apr 3 18:17:58 2008 +0300 KVM: Drop slots_lock while in guest mode As we can be in guest mode for indefinite periods, we need to drop slots_lock so that it can be taken for write by other operations (like the reading the dirty log). Signed-off-by: Avi Kivity commit 1963a30bd9d8588f967316298ff1df13f41200e7 Author: Avi Kivity Date: Thu Apr 3 12:02:21 2008 +0300 KVM: MMU: Only mark_page_accessed() if the page was accessed by the guest If the accessed bit is not set, the guest has never accessed this page (at least through this spte), so there's no need to mark the page accessed. This provides more accurate data for the eviction algortithm. Noted by Andrea Arcangeli. Signed-off-by: Avi Kivity commit 07b863c8a78d4d22327856d3141fe6e757b59bce Author: Izik Eidus Date: Sun Mar 30 16:01:25 2008 +0300 KVM: add vm refcounting the main purpose of adding this functions is the abilaty to release the spinlock that protect the kvm list while still be able to do operations on a specific kvm in a safe way. Signed-off-by: Izik Eidus Signed-off-by: Avi Kivity commit b00e4d5e0189f1b66988f96706e8935facde6574 Author: Joerg Roedel Date: Tue Apr 1 16:44:56 2008 +0200 KVM: function declaration parameter name cleanup The kvm_host.h file for x86 declares the functions kvm_set_cr[0348]. In the header file their second parameter is named cr0 in all cases. This patch renames the parameters so that they match the function name. Signed-off-by: Joerg Roedel Signed-off-by: Avi Kivity commit 78e00160c30ce75c07b8ec93ae8d99a062ffb347 Author: Avi Kivity Date: Mon Mar 31 14:48:35 2008 +0300 KVM: MMU: Add printk() when setting a pte replaces an existing page Signed-off-by: Avi Kivity commit 2ac530fcd40ad730d4cc7961768e412eaf9b7caa Author: Izik Eidus Date: Sun Mar 30 15:17:21 2008 +0300 KVM: MMU: allow the vm to shrink the kvm mmu shadow caches Allow the Linux memory manager to reclaim memory in the kvm shadow cache. Signed-off-by: Izik Eidus Signed-off-by: Avi Kivity commit c3071eae069e407d067a98c22ab2d1973b68785b Author: Marcelo Tosatti Date: Sat Mar 29 20:17:59 2008 -0300 KVM: MMU: unify slots_lock usage Unify slots_lock acquision around vcpu_run(). This is simpler and less error-prone. Also fix some callsites that were not grabbing the lock properly. Signed-off-by: Marcelo Tosatti Signed-off-by: Avi Kivity commit 6d159c4892cd673e85ee77ada2767320cd9f8142 Author: Sheng Yang Date: Fri Mar 28 13:18:56 2008 +0800 KVM: VMX: Enable MSR Bitmap feature MSR Bitmap controls whether the accessing of an MSR causes VM Exit. Eliminating exits on automatically saved and restored MSRs yields a small performance gain. Signed-off-by: Sheng Yang Signed-off-by: Avi Kivity commit 0f541a84d0e93fc927a55196a1a0a1ef539c71a7 Author: Marcelo Tosatti Date: Thu Mar 27 19:05:03 2008 -0300 KVM: MMU: fix large page breakage commit 15aaa819e20cb183f26392ed8ea16020630ef142 broke large page handling. With large pages it is valid to enter mmu_set_spte() with a gfn different than what current shadow pte contains, when overwritting a PTE page pointer. Signed-off-by: Marcelo Tosatti Signed-off-by: Avi Kivity commit 2d3898859c4eafc8e67f805f38acae8f31bd24a4 Author: Christian Borntraeger Date: Tue Mar 25 18:47:46 2008 +0100 s390: KVM guest: virtio device support, and kvm hypercalls This patch implements kvm guest kernel support for paravirtualized devices and contains two parts: o a basic virtio stub using virtio_ring and external interrupts and hypercalls o full hypercall implementation in kvm_para.h Currently we dont have PCI on s390. Making virtio_pci usable for s390 seems more complicated that providing an own stub. This virtio stub is similar to the lguest one, the memory for the descriptors and the device detection is made via additional mapped memory on top of the guest storage. We use an external interrupt with extint code 1237 for host->guest notification. The hypercall definition uses the diag instruction for issuing a hypercall. The parameters are written in R2-R7, the hypercall number is written in R1. This is similar to the system call ABI (svc) which can use R1 for the number and R2-R6 for the parameters. Signed-off-by: Christian Borntraeger Acked-by: Martin Schwidefsky Signed-off-by: Carsten Otte Signed-off-by: Avi Kivity commit 25213c3e02d4799c4d8e4b924ab995fd35b32927 Author: Christian Borntraeger Date: Tue Mar 25 18:47:44 2008 +0100 s390: KVM guest: detect when running on kvm From: Christian Borntraeger From: Carsten Otte This patch adds functionality to detect if the kernel runs under the KVM hypervisor. A macro MACHINE_IS_KVM is exported for device drivers. This allows drivers to skip device detection if the systems runs non-virtualized. We also define a preferred console to avoid having the ttyS0, which is a line mode only console. Signed-off-by: Christian Borntraeger Acked-by: Martin Schwidefsky Signed-off-by: Carsten Otte Signed-off-by: Avi Kivity commit 7ba4d65483ca39853ae3784fe1d5022ce15ad4ea Author: Christian Borntraeger Date: Tue Mar 25 18:47:41 2008 +0100 KVM: s390: update maintainers This patch adds an entry for kvm on s390 to the MAINTAINERS file :-). We intend to push all patches regarding this via Avi's kvm.git. Signed-off-by: Christian Borntraeger Signed-off-by: Carsten Otte Signed-off-by: Avi Kivity commit 6b62dd26beedd71db27cd1f307263e73c1cfa751 Author: Carsten Otte Date: Tue Mar 25 18:47:38 2008 +0100 KVM: s390: API documentation This patch adds Documentation/s390/kvm.txt, which describes specifics of kvm's user interface that are unique to s390 architecture. Signed-off-by: Carsten Otte Signed-off-by: Avi Kivity commit e1eb84250c9693300366367a411b2a8037411bfe Author: Carsten Otte Date: Tue Mar 25 18:47:36 2008 +0100 KVM: s390: add kvm to kconfig on s390 From: Carsten Otte From: Christian Borntraeger This patch adds the virtualization submenu and the kvm option to the kernel config. It also defines HAVE_KVM for 64bit kernels. Acked-by: Martin Schwidefsky Signed-off-by: Christian Borntraeger Signed-off-by: Carsten Otte Signed-off-by: Avi Kivity commit 9e83465580d5f09e9d3d98f65aa049d755d96af0 Author: Carsten Otte Date: Tue Mar 25 18:47:34 2008 +0100 KVM: s390: intercepts for diagnose instructions From: Carsten Otte From: Christian Borntraeger This patch introduces interpretation of some diagnose instruction intercepts. Diagnose is our classic architected way of doing a hypercall. This patch features the following diagnose codes: - vm storage size, that tells the guest about its memory layout - time slice end, which is used by the guest to indicate that it waits for a lock and thus cannot use up its time slice in a useful way - ipl functions, which a guest can use to reset and reboot itself In order to implement ipl functions, we also introduce an exit reason that causes userspace to perform various resets on the virtual machine. All resets are described in the principles of operation book, except KVM_S390_RESET_IPL which causes a reboot of the machine. Acked-by: Martin Schwidefsky Signed-off-by: Christian Borntraeger Signed-off-by: Carsten Otte Signed-off-by: Avi Kivity commit f97da5843e02f1892395e34550c020965f366ef6 Author: Carsten Otte Date: Tue Mar 25 18:47:31 2008 +0100 KVM: s390: interprocessor communication via sigp From: Carsten Otte From: Christian Borntraeger This patch introduces in-kernel handling of _some_ sigp interprocessor signals (similar to ipi). kvm_s390_handle_sigp() decodes the sigp instruction and calls individual handlers depending on the operation requested: - sigp sense tries to retrieve information such as existence or running state of the remote cpu - sigp emergency sends an external interrupt to the remove cpu - sigp stop stops a remove cpu - sigp stop store status stops a remote cpu, and stores its entire internal state to the cpus lowcore - sigp set arch sets the architecture mode of the remote cpu. setting to ESAME (s390x 64bit) is accepted, setting to ESA/S390 (s390, 31 or 24 bit) is denied, all others are passed to userland - sigp set prefix sets the prefix register of a remote cpu For implementation of this, the stop intercept indication starts to get reused on purpose: a set of action bits defines what to do once a cpu gets stopped: ACTION_STOP_ON_STOP really stops the cpu when a stop intercept is recognized ACTION_STORE_ON_STOP stores the cpu status to lowcore when a stop intercept is recognized Acked-by: Martin Schwidefsky Signed-off-by: Christian Borntraeger Signed-off-by: Carsten Otte Signed-off-by: Avi Kivity commit 2901e41f93f9c2ac53f5e2ed251017dd3da9dccb Author: Carsten Otte Date: Tue Mar 25 18:47:29 2008 +0100 KVM: s390: intercepts for privileged instructions From: Carsten Otte From: Christian Borntraeger This patch introduces in-kernel handling of some intercepts for privileged instructions: handle_set_prefix() sets the prefix register of the local cpu handle_store_prefix() stores the content of the prefix register to memory handle_store_cpu_address() stores the cpu number of the current cpu to memory handle_skey() just decrements the instruction address and retries handle_stsch() delivers condition code 3 "operation not supported" handle_chsc() same here handle_stfl() stores the facility list which contains the capabilities of the cpu handle_stidp() stores cpu type/model/revision and such handle_stsi() stores information about the system topology Acked-by: Martin Schwidefsky Signed-off-by: Christian Borntraeger Signed-off-by: Carsten Otte Signed-off-by: Avi Kivity commit 79906268c3ea304f72b8a9c384f19f9eac2a5c8f Author: Carsten Otte Date: Tue Mar 25 18:47:26 2008 +0100 KVM: s390: interrupt subsystem, cpu timer, waitpsw This patch contains the s390 interrupt subsystem (similar to in kernel apic) including timer interrupts (similar to in-kernel-pit) and enabled wait (similar to in kernel hlt). In order to achieve that, this patch also introduces intercept handling for instruction intercepts, and it implements load control instructions. This patch introduces an ioctl KVM_S390_INTERRUPT which is valid for both the vm file descriptors and the vcpu file descriptors. In case this ioctl is issued against a vm file descriptor, the interrupt is considered floating. Floating interrupts may be delivered to any virtual cpu in the configuration. The following interrupts are supported: SIGP STOP - interprocessor signal that stops a remote cpu SIGP SET PREFIX - interprocessor signal that sets the prefix register of a (stopped) remote cpu INT EMERGENCY - interprocessor interrupt, usually used to signal need_reshed and for smp_call_function() in the guest. PROGRAM INT - exception during program execution such as page fault, illegal instruction and friends RESTART - interprocessor signal that starts a stopped cpu INT VIRTIO - floating interrupt for virtio signalisation INT SERVICE - floating interrupt for signalisations from the system service processor struct kvm_s390_interrupt, which is submitted as ioctl parameter when injecting an interrupt, also carrys parameter data for interrupts along with the interrupt type. Interrupts on s390 usually have a state that represents the current operation, or identifies which device has caused the interruption on s390. kvm_s390_handle_wait() does handle waitpsw in two flavors: in case of a disabled wait (that is, disabled for interrupts), we exit to userspace. In case of an enabled wait we set up a timer that equals the cpu clock comparator value and sleep on a wait queue. Acked-by: Martin Schwidefsky Signed-off-by: Carsten Otte Signed-off-by: Avi Kivity commit 13d449639825912c0cf0aa3fb1bf4ead8f6d76b5 Author: Carsten Otte Date: Tue Mar 25 18:47:23 2008 +0100 KVM: s390: sie intercept handling From: Carsten Otte From: Christian Borntraeger This path introduces handling of sie intercepts in three flavors: Intercepts are either handled completely in-kernel by kvm_handle_sie_intercept(), or passed to userspace with corresponding data in struct kvm_run in case kvm_handle_sie_intercept() returns -ENOTSUPP. In case of partial execution in kernel with the need of userspace support, kvm_handle_sie_intercept() may choose to set up struct kvm_run and return -EREMOTE. The trivial intercept reasons are handled in this patch: handle_noop() just does nothing for intercepts that don't require our support at all handle_stop() is called when a cpu enters stopped state, and it drops out to userland after updating our vcpu state handle_validity() faults in the cpu lowcore if needed, or passes the request to userland Acked-by: Martin Schwidefsky Signed-off-by: Christian Borntraeger Signed-off-by: Carsten Otte Signed-off-by: Avi Kivity commit 5ef1efd73460024446cc50469e08372de69966c8 Author: Carsten Otte Date: Tue Mar 25 18:47:20 2008 +0100 KVM: s390: arch backend for the kvm kernel module From: Carsten Otte From: Christian Borntraeger From: Heiko Carstens This patch contains the port of Qumranet's kvm kernel module to IBM zSeries (aka s390x, mainframe) architecture. It uses the mainframe's virtualization instruction SIE to run virtual machines with up to 64 virtual CPUs each. This port is only usable on 64bit host kernels, and can only run 64bit guest kernels. However, running 31bit applications in guest userspace is possible. The following source files are introduced by this patch arch/s390/kvm/kvm-s390.c similar to arch/x86/kvm/x86.c, this implements all arch callbacks for kvm. __vcpu_run calls back into sie64a to enter the guest machine context arch/s390/kvm/sie64a.S assembler function sie64a, which enters guest context via SIE, and switches world before and after that include/asm-s390/kvm_host.h contains all vital data structures needed to run virtual machines on the mainframe include/asm-s390/kvm.h defines kvm_regs and friends for user access to guest register content arch/s390/kvm/gaccess.h functions similar to uaccess to access guest memory arch/s390/kvm/kvm-s390.h header file for kvm-s390 internals, extended by later patches Acked-by: Martin Schwidefsky Signed-off-by: Christian Borntraeger Signed-off-by: Heiko Carstens Signed-off-by: Carsten Otte Signed-off-by: Avi Kivity commit 2c362ff1cadd1ae90c8dbc5e87c1e8a8f745d8d6 Author: Christian Borntraeger Date: Tue Mar 25 18:47:18 2008 +0100 s390: KVM preparation: split sysinfo defintions for kvm use drivers/s390/sysinfo.c uses the store system information intruction to query the system about information of the machine, the LPAR and additional hypervisors. KVM has to implement the host part for this instruction. To avoid code duplication, this patch splits the common definitions from sysinfo.c into a separate header file include/asm-s390/sysinfo.h for KVM use. Acked-by: Martin Schwidefsky Signed-off-by: Christian Borntraeger Signed-off-by: Carsten Otte Signed-off-by: Avi Kivity commit 6d15529a96b8f66b4e816508f86cb2fe02b0b126 Author: Christian Borntraeger Date: Tue Mar 25 18:47:15 2008 +0100 s390: KVM preparation: address of the 64bit extint parm in lowcore The address 0x11b8 is used by z/VM for pfault and diag 250 I/O to provide a 64 bit extint parameter. virtio uses the same address, so its time to update the lowcore structure. Acked-by: Martin Schwidefsky Signed-off-by: Christian Borntraeger Signed-off-by: Carsten Otte Signed-off-by: Avi Kivity commit 72a1eb2b4ec09f7290eec6323495723b90a510a3 Author: Heiko Carstens Date: Tue Mar 25 18:47:12 2008 +0100 s390: KVM preparation: host memory management changes for s390 kvm From: Heiko Carstens From: Christian Borntraeger This patch changes the s390 memory management defintions to use the pgste field for dirty and reference bit tracking of host and guest code. Usually on s390, dirty and referenced are tracked in storage keys, which belong to the physical page. This changes with virtualization: The guest and host dirty/reference bits are defined to be the logical OR of the values for the mapping and the physical page. This patch implements the necessary changes in pgtable.h for s390. There is a common code change in mm/rmap.c, the call to page_test_and_clear_young must be moved. This is a no-op for all architecture but s390. page_referenced checks the referenced bits for the physiscal page and for all mappings: o The physical page is checked with page_test_and_clear_young. o The mappings are checked with ptep_test_and_clear_young and friends. Without pgstes (the current implementation on Linux s390) the physical page check is implemented but the mapping callbacks are no-ops because dirty and referenced are not tracked in the s390 page tables. The pgstes introduces guest and host dirty and reference bits for s390 in the host mapping. These mapping must be checked before page_test_and_clear_young resets the reference bit. Signed-off-by: Heiko Carstens Signed-off-by: Christian Borntraeger Acked-by: Martin Schwidefsky Acked-by: Andrew Morton Signed-off-by: Carsten Otte Signed-off-by: Avi Kivity commit 42fdc18edf553162617f9b8691b51bd92e7902f7 Author: Martin Schwidefsky Date: Tue Mar 25 18:47:10 2008 +0100 s390: KVM preparation: provide hook to enable pgstes in user pagetable From: Martin Schwidefsky From: Carsten Otte The SIE instruction on s390 uses the 2nd half of the page table page to virtualize the storage keys of a guest. This patch offers the s390_enable_sie function, which reorganizes the page tables of a single-threaded process to reserve space in the page table: s390_enable_sie makes sure that the process is single threaded and then uses dup_mm to create a new mm with reorganized page tables. The old mm is freed and the process has now a page status extended field after every page table. Code that wants to exploit pgstes should SELECT CONFIG_PGSTE. This patch has a small common code hit, namely making dup_mm non-static. Edit (Carsten): I've modified Martin's patch, following Jeremy Fitzhardinge's review feedback. Now we do have the prototype for dup_mm in include/linux/sched.h. Following Martin's suggestion, s390_enable_sie() does now call task_lock() to prevent race against ptrace modification of mm_users. Signed-off-by: Martin Schwidefsky Signed-off-by: Carsten Otte Acked-by: Andrew Morton Signed-off-by: Avi Kivity commit a856ae26ea192996b2c6eea22ccd9c53c27d2647 Author: Carsten Otte Date: Wed Mar 26 13:20:16 2008 +0100 s390: fixup for kvm Temporary commit, should appear in mainline shortly. Signed-off-by: Avi Kivity commit 4b8bfa4cc9d47d1607471314f4bb0db10de7c0ec Author: Randy Dunlap Date: Tue Mar 25 16:08:46 2008 -0700 x86: KVM guest: don't allow KVM_CLOCK on Voyager or Visual WS Prevent failed randconfig builds with KVM_CLOCK being enabled on Voyager or VISWS. build-rand9.out: Using /local/linsrc/next-20080325 as source for kernel build-rand9.out: from /local/linsrc/next-20080325/include/linux/irqflags.h:46, build-rand9.out: from include2/asm/system.h:11, build-rand9.out: from include2/asm/processor.h:21, build-rand9.out: from include2/asm/atomic_32.h:5, build-rand9.out: from include2/asm/atomic.h:2, build-rand9.out: from /local/linsrc/next-20080325/include/linux/crypto.h:20, build-rand9.out: from /local/linsrc/next-20080325/arch/x86/kernel/asm-offsets_32.c:7, build-rand9.out: from /local/linsrc/next-20080325/arch/x86/kernel/asm-offsets.c:2: build-rand9.out:include2/asm/paravirt.h:856: error: 'struct pv_apic_ops' has no member named 'startup_ipi_hook' build-rand9.out:include2/asm/paravirt.h:856: error: 'struct pv_apic_ops' has no member named 'startup_ipi_hook' build-rand9.out:include2/asm/paravirt.h:856: error: memory input 4 is not directly addressable build-rand9.out:make[2]: *** [arch/x86/kernel/asm-offsets.s] Error 1 Signed-off-by: Randy Dunlap Signed-off-by: Avi Kivity commit 329e0dcd2f78ba3eeccd9b55fc4df439d96b86c2 Author: Lachlan McIlroy Date: Thu Mar 27 18:01:14 2008 +1100 [XFS] Prevent xfs_bmap_check_leaf_extents() from referencing unmapped memory. While investigating the extent corruption bug I ran into this bug in debug only code. xfs_bmap_check_leaf_extents() loops through the leaf blocks of the extent btree checking that every extent is entirely before the next extent. It also compares the last extent in the previous block to the first extent in the current block when the previous block has been released and potentially unmapped. So take a copy of the last extent instead of a pointer. Also move the last extent check out of the loop because we only need to do it once. SGI-PV: 976035 SGI-Modid: xfs-linux-melb:xfs-kern:30718a Signed-off-by: Lachlan McIlroy Signed-off-by: Christoph Hellwig commit 8407a618c4f51ee8d32615a76fbc4f4c735253fd Author: Christoph Hellwig Date: Thu Mar 27 18:01:08 2008 +1100 [XFS] remove most calls to VN_RELE Most VN_RELE calls either directly contain a XFS_ITOV or have the corresponding xfs_inode already in scope. Use the IRELE helper instead of VN_RELE to clarify the code. With a little more work we can kill VN_RELE altogether and define IRELE in terms of iput directly. SGI-PV: 976035 SGI-Modid: xfs-linux-melb:xfs-kern:30710a Signed-off-by: Christoph Hellwig Signed-off-by: Lachlan McIlroy commit 0889402b05623fa1d1d3bf929dd0b0527d40870c Author: Christoph Hellwig Date: Thu Mar 27 18:01:00 2008 +1100 [XFS] split xfs_ioc_xattr The three subcases of xfs_ioc_xattr don't share any semantics and almost no code, so split it into three separate helpers. SGI-PV: 976035 SGI-Modid: xfs-linux-melb:xfs-kern:30709a Signed-off-by: Christoph Hellwig Signed-off-by: Lachlan McIlroy commit 6181b36ac2ee883289bcfbfd0a4419fc5258c208 Author: Christoph Hellwig Date: Thu Mar 27 18:00:54 2008 +1100 [XFS] cleanup root inode handling in xfs_fs_fill_super - rename rootvp to root for clarify - remove useless vn_to_inode call - check is_bad_inode before calling d_alloc_root - use iput instead of VN_RELE in the error case SGI-PV: 976035 SGI-Modid: xfs-linux-melb:xfs-kern:30708a Signed-off-by: Christoph Hellwig Signed-off-by: Lachlan McIlroy commit c9532b3b9f7e0101fa849211746e41d827009e88 Author: David Chinner Date: Thu Mar 27 18:00:45 2008 +1100 [XFS] Ensure a btree insert returns a valid cursor. When writing into preallocated regions there is a case where XFS can oops or hang doing the unwritten extent conversion on I/O completion. It turns out that the problem is related to the btree cursor being invalid. When we do an insert into the tree, we may need to split blocks in the tree. When we only split at the leaf level (i.e. level 0), everything works just fine. However, if we have a multi-level split in the btreee, the cursor passed to the insert function is no longer valid once the insert is complete. The leaf level split is handled correctly because all the operations at level 0 are done using the original cursor, hence it is updated correctly. However, when we need to update the next level up the tree, we don't use that cursor - we use a cloned cursor that points to the index in the next level up where we need to do the insert. Hence if we need to split a second level, the changes to the tree are reflected in the cloned cursor and not the original cursor. This clone-and-move-up-a-level-on-split behaviour recurses all the way to the top of the tree. The complexity here is that these cloned cursors do not point to the original index that was inserted - they point to the newly allocated block (the right block) and the original cursor pointer to that level may still point to the left block. Hence, without deep examination of the cloned cursor and buffers, we cannot update the original cursor with the new path from the cloned cursor. In these cases the original cursor could be pointing to the wrong block(s) and hence a subsequent modification to the tree using that cursor will lead to corruption of the tree. The crash case occurs when the tree changes height - we insert a new level in the tree, and the cursor does not have a buffer in it's path for that level. Hence any attempt to walk back up the cursor to the root block will result in a null pointer dereference. To make matters even more complex, the BMAP BT is rooted in an inode, so we can have a change of height in the btree *without a root split*. That is, if the root block in the inode is full when we split a leaf node, we cannot fit the pointer to the new block in the root, so we allocate a new block, migrate all the ptrs out of the inode into the new block and point the inode root block at the newly allocated block. This changes the height of the tree without a root split having occurred and hence invalidates the path in the original cursor. The patch below prevents xfs_bmbt_insert() from returning with an invalid cursor by detecting the cases that invalidate the original cursor and refresh it by do a lookup into the btree for the original index we were inserting at. Note that the INOBT, AGFBNO and AGFCNT btree implementations also have this bug, but the cursor is currently always destroyed or revalidated after an insert for those trees. Hence this patch only address the problem in the BMBT code. SGI-PV: 979339 SGI-Modid: xfs-linux-melb:xfs-kern:30701a Signed-off-by: David Chinner Signed-off-by: Lachlan McIlroy commit 57b4d888458bd259eb0d334158511b6cb05496e0 Author: David Chinner Date: Thu Mar 27 18:00:38 2008 +1100 [XFS] Account for inode cluster alignment in all allocations At ENOSPC, we can get a filesystem shutdown due to a cancelling a dirty transaction in xfs_mkdir or xfs_create. This is due to the initial allocation attempt not taking into account inode alignment and hence we can prepare the AGF freelist for allocation when it's not actually possible to do an allocation. This results in inode allocation returning ENOSPC with a dirty transaction, and hence we shut down the filesystem. Because the first allocation is an exact allocation attempt, we must tell the allocator that the alignment does not affect the allocation attempt. i.e. we will accept any extent alignment as long as the extent starts at the block we want. Unfortunately, this means that if the longest free extent is less than the length + alignment necessary for fallback allocation attempts but is long enough to attempt a non-aligned allocation, we will modify the free list. If we then have the exact allocation fail, all other allocation attempts will also fail due to the alignment constraint being taken into account. Hence the initial attempt needs to set the "alignment slop" field so that alignment, while not required, must be taken into account when determining if there is enough space left in the AG to do the allocation. That means if the exact allocation fails, we will not dirty the freelist if there is not enough space available fo a subsequent allocation to succeed. Hence we get an ENOSPC error back to userspace without shutting down the filesystem. SGI-PV: 978886 SGI-Modid: xfs-linux-melb:xfs-kern:30699a Signed-off-by: David Chinner Signed-off-by: Christoph Hellwig Signed-off-by: Lachlan McIlroy commit e99d595d4ccd74e2dc442423469d9d175c3656cd Author: Josef 'Jeff' Sipek Date: Thu Mar 27 17:58:27 2008 +1100 [XFS] Replace custom AIL linked-list code with struct list_head Replace the xfs_ail_entry_t with a struct list_head and clean the surrounding code up. Also fixes a livelock in xfs_trans_first_push_ail() by terminating the loop at the head of the list correctly. SGI-PV: 978682 SGI-Modid: xfs-linux-melb:xfs-kern:30636a Signed-off-by: Josef 'Jeff' Sipek Signed-off-by: David Chinner Signed-off-by: Lachlan McIlroy commit c0af88e9014019f6392b06c11e836ca58acc7ede Author: Avi Kivity Date: Wed Mar 26 11:39:12 2008 +0200 Revert "KVM: use get_task_mm() instead of atomic_inc the mm_count" This reverts commit 202761268a29d4cd3a3fec35e6d6f2f239374635. The change caused a cycle that wouldn't let virtual machines to be deallocated (due to the mm holding a ref to the file table, which holds a ref to kvm). Signed-off-by: Avi Kivity commit 680615e31ee986b6a5d64783c536ed9fae67c010 Author: Izik Eidus Date: Mon Mar 24 23:14:53 2008 +0200 KVM: x86: hardware task switching support This emulates the x86 hardware task switch mechanism in software, as it is unsupported by either vmx or svm. It allows operating systems which use it, like freedos, to run as kvm guests. Signed-off-by: Izik Eidus Signed-off-by: Avi Kivity commit dc55ffed23380ec0aaf53ebd04e99298c8a46514 Author: Izik Eidus Date: Mon Mar 24 19:38:34 2008 +0200 KVM: x86: add functions to get the cpl of vcpu Signed-off-by: Izik Eidus Signed-off-by: Avi Kivity commit 8995c473bdd29e900cdec9aca1a0d60c5dd61507 Author: Avi Kivity Date: Tue Mar 25 11:26:13 2008 +0200 KVM: Free apic access page on vm destruction Noticed by Marcelo Tosatti. Signed-off-by: Avi Kivity commit 8dac14eb4014eb861eee7619e8df351163ca2bf3 Author: Avi Kivity Date: Mon Mar 24 18:15:14 2008 +0200 KVM: VMX: Add module option to disable flexpriority Useful for debugging. Signed-off-by: Avi Kivity commit de9babf30ad7c73626308beae6062bc60e48d714 Author: Avi Kivity Date: Sun Mar 23 18:36:30 2008 +0200 KVM: no longer EXPERIMENTAL Long overdue. Signed-off-by: Avi Kivity commit 202761268a29d4cd3a3fec35e6d6f2f239374635 Author: Izik Eidus Date: Thu Mar 20 15:19:40 2008 +0200 KVM: use get_task_mm() instead of atomic_inc the mm_count Signed-off-by: Izik Eidus Signed-off-by: Avi Kivity commit 019e2e8bb7e89b2479f867050f4961d1c4461403 Author: Avi Kivity Date: Sun Mar 23 15:06:23 2008 +0200 KVM: MMU: Introduce and use spte_to_page() Encapsulate the command mask'n'shift in a function. Signed-off-by: Avi Kivity commit 075a32dab40bbd330f997fb5b1c9b540d22d073d Author: Izik Eidus Date: Thu Mar 20 18:17:24 2008 +0200 KVM: MMU: fix dirty bit setting when removing write permissions When mmu_set_spte() checks if a page related to spte should be release as dirty or clean, it check if the shadow pte was writeble, but in case rmap_write_protect() is called called it is possible for shadow ptes that were writeble to become readonly and therefor mmu_set_spte will release the pages as clean. This patch fix this issue by marking the page as dirty inside rmap_write_protect(). Signed-off-by: Izik Eidus Signed-off-by: Avi Kivity commit 361be34b5222fef558c4d0f5d956c1ea3d299f76 Author: Avi Kivity Date: Fri Mar 21 12:38:23 2008 +0200 KVM: Move some x86 specific constants and structures to include/asm-x86 Signed-off-by: Avi Kivity commit 914bd662fe1374f4a7f92b1665d75274aef8a95e Author: Marcelo Tosatti Date: Tue Mar 18 17:42:34 2008 -0300 KVM: VMX: convert init_rmode_tss() to slots_lock init_rmode_tss was forgotten during the conversion from mmap_sem to slots_lock. INFO: task qemu-system-x86:3748 blocked for more than 120 seconds. Call Trace: [] __down_read+0x86/0x9e [] do_page_fault+0x346/0x78e [] trace_hardirqs_on_thunk+0x35/0x3a [] error_exit+0x0/0xa9 [] copy_user_generic_string+0x17/0x40 [] :kvm:kvm_write_guest_page+0x3e/0x5f [] :kvm_intel:init_rmode_tss+0xa7/0xf9 [] :kvm_intel:vmx_vcpu_reset+0x10/0x38a [] :kvm:kvm_arch_vcpu_setup+0x20/0x53 [] :kvm:kvm_vm_ioctl+0xad/0x1cf [] __lock_acquire+0x4f7/0xc28 [] vfs_ioctl+0x21/0x6b [] do_vfs_ioctl+0x252/0x26b [] sys_ioctl+0x3c/0x5e [] system_call_after_swapgs+0x7b/0x80 Signed-off-by: Marcelo Tosatti Signed-off-by: Avi Kivity commit e0a570bb7acff2109a5b3c2d59ba3b177962d430 Author: Andrew Morton Date: Tue Mar 18 18:42:35 2008 -0700 KVM: warning fix arch/x86/kvm/mmu.c: In function 'kvm_pv_mmu_op': arch/x86/kvm/mmu.c:2119: warning: comparison of distinct pointer types lacks a cast Cc: Avi Kivity Signed-off-by: Andrew Morton Signed-off-by: Avi Kivity commit f1080a0045631777a0a9c80533f833c76c5be4c8 Author: Glauber Costa Date: Tue Mar 18 07:30:06 2008 -0300 x86: KVM guest: disable clock before rebooting (!CONFIG_KEXEC fixes) Signed-off-by: Glauber Costa Signed-off-by: Avi Kivity commit 898518e2557629399ec33b1784fca1ebec2b8a63 Author: Glauber Costa Date: Tue Mar 18 07:30:04 2008 -0300 x86: allow machine_crash_shutdown to be replaced (fixes for !CONFIG_KEXEC) Signed-off-by: Glauber Costa Signed-off-by: Avi Kivity commit 4c95a0abcc113cdffe4e8981e343f9da1d27a641 Author: Avi Kivity Date: Tue Mar 18 11:05:52 2008 +0200 KVM: MMU: Set the accessed bit on non-speculative shadow ptes If we populate a shadow pte due to a fault (and not speculatively due to a pte write) then we can set the accessed bit on it, as we know it will be set immediately on the next guest instruction. This saves a read-modify-write operation. Signed-off-by: Avi Kivity commit 2585fb6f8f8ead2be4c1e5416b7aa95f2cc7c64c Author: Christian Borntraeger Date: Wed Mar 12 18:10:45 2008 +0100 KVM: kvm.h: __user requires compiler.h include/linux/kvm.h defines struct kvm_dirty_log to [...] union { void __user *dirty_bitmap; /* one bit per page */ __u64 padding; }; __user requires compiler.h to compile. Currently, this works on x86 only coincidentally due to other include files. This patch makes kvm.h compile in all cases. Signed-off-by: Christian Borntraeger Signed-off-by: Avi Kivity commit 8b55bc5a2b44c643e3927b71587fb724acc2361c Author: Glauber Costa Date: Mon Mar 17 16:08:40 2008 -0300 x86: KVM guest: disable clock before rebooting. This patch writes 0 (actually, what really matters is that the LSB is cleared) to the system time msr before shutting down the machine for kexec. Without it, we can have a random memory location being written when the guest comes back It overrides the functions shutdown, used in the path of kernel_kexec() (sys.c) and crash_shutdown, used in the path of crash_kexec() (kexec.c) Signed-off-by: Glauber Costa Signed-off-by: Avi Kivity commit 0c7f95e535a02caba52f944f067fbc05a0608cc1 Author: Glauber Costa Date: Mon Mar 17 16:08:39 2008 -0300 x86: make native_machine_shutdown non-static it will allow external users to call it. It is mainly useful for routines that will override its machine_ops field for its own special purposes, but want to call the normal shutdown routine after they're done Signed-off-by: Glauber Costa Signed-off-by: Avi Kivity commit 602ac559a208ba44d5879a8e6381a379b376a8b7 Author: Glauber Costa Date: Mon Mar 17 16:08:38 2008 -0300 x86: allow machine_crash_shutdown to be replaced This patch a llows machine_crash_shutdown to be replaced, just like any of the other functions in machine_ops Signed-off-by: Glauber Costa Signed-off-by: Avi Kivity commit 20d1b4e59c58f69f908c231e642329b265a9bc2b Author: Glauber Costa Date: Mon Mar 17 17:10:15 2008 -0300 KVM: use slots_lock to protect writes to the wall clock As Marcelo pointed out, we need slots_lock to protect against slots changing under our nose during wall clock writing. This patch address this issue. Signed-off-by: Glauber Costa CC: Marcelo Tosatti Signed-off-by: Avi Kivity commit ac1cd26007b7904043b8d4fc802b82aac076030a Author: Marcelo Tosatti Date: Mon Mar 17 10:08:18 2008 -0300 KVM: MMU: handle page removal with shadow mapping Do not assume that a shadow mapping will always point to the same host frame number. Fixes crash with madvise(MADV_DONTNEED). Signed-off-by: Marcelo Tosatti Signed-off-by: Avi Kivity commit 5d784772e95e49a6ed14b9f26b3d238ebea2be18 Author: Marcelo Tosatti Date: Fri Feb 22 12:21:38 2008 -0500 x86: KVM guest: hypercall batching Batch pte updates and tlb flushes in lazy MMU mode. [avi: - adjust to mmu_op - helper for getting para_state without debug warnings] Signed-off-by: Marcelo Tosatti Signed-off-by: Avi Kivity commit 3492d80e1d063f1b48f92922546ec12fde138267 Author: Marcelo Tosatti Date: Fri Feb 22 12:21:37 2008 -0500 x86: KVM guest: hypercall based pte updates and TLB flushes Hypercall based pte updates are faster than faults, and also allow use of the lazy MMU mode to batch operations. Don't report the feature if two dimensional paging is enabled. [avi: - guest/host split - fix 32-bit truncation issues - adjust to mmu_op] Signed-off-by: Marcelo Tosatti Signed-off-by: Avi Kivity commit e611c5b90e362f9f6d8cb15d1c4dce30120871d6 Author: Marcelo Tosatti Date: Fri Feb 22 12:21:37 2008 -0500 KVM: MMU: hypercall based pte updates and TLB flushes Hypercall based pte updates are faster than faults, and also allow use of the lazy MMU mode to batch operations. Don't report the feature if two dimensional paging is enabled. [avi: - one mmu_op hypercall instead of one per op - allow 64-bit gpa on hypercall - don't pass host errors (-ENOMEM) to guest] Signed-off-by: Marcelo Tosatti Signed-off-by: Avi Kivity commit 653bd220aa68fe27ed9bcbffb76578e143844030 Author: Avi Kivity Date: Sun Mar 2 14:06:05 2008 +0200 KVM: Provide unlocked version of emulator_write_phys() Signed-off-by: Avi Kivity commit e93efb1af9725728d260ee3700ba0318e25fd127 Author: Marcelo Tosatti Date: Fri Feb 22 12:21:36 2008 -0500 x86: KVM guest: add basic paravirt support Add basic KVM paravirt support. Avoid vm-exits on IO delays. Signed-off-by: Marcelo Tosatti Signed-off-by: Avi Kivity commit 3ab572bde6d4788efa5d07e24a589a3e049b5298 Author: Marcelo Tosatti Date: Fri Feb 22 12:21:36 2008 -0500 KVM: add basic paravirt support Add basic KVM paravirt support. Avoid vm-exits on IO delays. Signed-off-by: Marcelo Tosatti Signed-off-by: Avi Kivity commit d7f190bada15ae6c775f4ee47d1eb3f2952f62ae Author: Avi Kivity Date: Sun Mar 16 18:48:26 2008 +0200 KVM: VMX: Restore tss even on x86_64 The vmx hardware state restore restores the tss selector and base address, but not its length. Usually, this does not matter since most of the tss contents is within the default length of 0x67. However, if a process is using ioperm() to grant itself I/O port permissions, an additional bitmap within the tss, but outside the default length is consulted. The effect is that the process will receive a SIGSEGV instead of transparently accessing the port. Fix by restoring the tss length. Note that i386 had this working already. Closes bugzilla 10246. Signed-off-by: Avi Kivity commit f363b5782ebf999bed721bc151bbfc0d392a7565 Author: Sheng Yang Date: Thu Mar 13 10:22:26 2008 +0800 KVM: Add reset support for in kernel PIT Separate the reset part and prepare for reset support. Signed-off-by: Sheng Yang Signed-off-by: Avi Kivity commit 9251e14dc5e7542c8756e7be4ee4fb07b52e1257 Author: Avi Kivity Date: Sun Mar 16 17:00:09 2008 +0200 KVM: Fix inconsistency in setting MSR_KVM_SYSTEM_TIME - save the full value of the msr, even if the enable bit is clear - clear previous value of time_page Signed-off-by: Avi Kivity commit 78fb13c06a4b05af6b742c20feed2c0da2999e6e Author: Randy Dunlap Date: Fri Mar 14 15:20:58 2008 -0700 x86: KVM guest: kvmclock needs to include apic.h kvmclock needs to #include apic.h to prevent a build error: next-20080314/arch/x86/kernel/kvmclock.c:142: error: implicit declaration of function 'setup_secondary_APIC_clock' elan1.out:make[2]: *** [arch/x86/kernel/kvmclock.o] Error 1 Signed-off-by: Randy Dunlap Cc: Avi Kivity Cc: Ingo Molnar Cc: Thomas Gleixner Signed-off-by: Andrew Morton Signed-off-by: Avi Kivity commit a16664b59065b8ae877b213e68a6f962ac359ca4 Author: Sheng Yang Date: Tue Mar 4 00:50:59 2008 +0800 KVM: Add save/restore supporting of in kernel PIT Signed-off-by: Sheng Yang Signed-off-by: Avi Kivity commit 756d0c242c4454743ff1cacd800e3f0ac6b95db1 Author: Sheng Yang Date: Mon Jan 28 05:10:22 2008 +0800 KVM: In kernel PIT model The patch moved PIT from userspace to kernel, and increase the timer accuracy greatly. Signed-off-by: Sheng Yang Signed-off-by: Avi Kivity commit 4c8341d3c2d757e0a2cd4e0ee85e79efecbe925c Author: Glauber Costa Date: Thu Mar 6 11:45:44 2008 -0300 x86: KVM guest: adjust clock to have an enable/disable bit Use LSB of the address passed through the msr to enable/disable the clock. Setting it to 1 enables it, setting it to 0 disables it. Signed-off-by: Glauber Costa Signed-off-by: Avi Kivity commit c49645ea2fd79676d9191392d144791d1fd1919c Author: Glauber Costa Date: Thu Mar 6 11:45:44 2008 -0300 KVM: clock: disable kvm clock unless addr's LSB is set. Use LSB of the address passed through the msr to enable/disable the clock. Setting it to 1 enables it, setting it to 0 disables it. As the guest data structures are aligned anyway, this won't be a problem, as this bit is free. Signed-off-by: Glauber Costa Signed-off-by: Avi Kivity commit 3e7a02f55b49c872175078c84cd20aa82b7020d9 Author: Glauber Costa Date: Thu Mar 6 11:45:43 2008 -0300 x86: KVM guest: use per cpu variables instead of a vector replace hv_clock vector in kvmclock with a percpu variable that is cacheline aligned. Signed-off-by: Glauber Costa Signed-off-by: Avi Kivity commit 62b41c176d2e33a8fb06a96cf7cccad069d9f280 Author: Glauber Costa Date: Wed Mar 5 15:41:32 2008 -0300 x86: KVM guest: cleanup clock leftovers clean this leftover in kvmclock.c Signed-off-by: Glauber Costa Signed-off-by: Avi Kivity commit 774920305764a9b07891c1b16ec4cf6d4e3ab749 Author: Glauber Costa Date: Wed Mar 5 15:41:29 2008 -0300 KVM: kvmclock: release time_page if msr is rewritten If the calling cpu rewrites the system clock msr for any reason, release the page we allocated in the last time. Signed-off-by: Glauber Costa Signed-off-by: Avi Kivity commit 61c9fcd198238730db891af69027e733a7588ab6 Author: David Chinner Date: Thu Mar 6 13:49:43 2008 +1100 [XFS] fix inode leak in xfs_iget_core() If the radix_tree_preload() fails, we need to destroy the inode we just read in before trying again. This could leak xfs_vnode structures when there is memory pressure. Noticed by Christoph Hellwig. SGI-PV: 977823 SGI-Modid: xfs-linux-melb:xfs-kern:30606a Signed-off-by: David Chinner Signed-off-by: Lachlan McIlroy Signed-off-by: Christoph Hellwig commit 24c281e89ecf546dd69e65b74ccb90c5e3850228 Author: Christoph Hellwig Date: Thu Mar 6 13:49:36 2008 +1100 [XFS] Remove superflous xfs_readsb call in xfs_mountfs. When xfs_mountfs is called by xfs_mount xfs_readsb was called 35 lines above unconditionally, so there is no need to try to read the superblock if it's not present. If any other port doesn't have the superblock read at this point it should just call it directly from it's xfs_mount equivalent. SGI-PV: 976035 SGI-Modid: xfs-linux-melb:xfs-kern:30603a Signed-off-by: Christoph Hellwig Signed-off-by: Donald Douwsma Signed-off-by: Lachlan McIlroy commit fd5150834e292efb5367314f7dc9f8ba01d4b19e Author: Niv Sardi Date: Thu Mar 6 13:49:26 2008 +1100 [XFS] kill t_sema member of struct xfs_trans It's completely unused so we might aswell kill it. Note that there is another t_sema in struct xlog_ticket, which is used and actually an sv_t despite the name. That one is left untouched by this patch. SGI-PV: 971186 SGI-Modid: xfs-linux-melb:xfs-kern:30591a Signed-off-by: Niv Sardi Signed-off-by: Christoph Hellwig Signed-off-by: Lachlan McIlroy commit ce500c06bd5d242a3b0878839669296f33bf5e29 Author: Christoph Hellwig Date: Thu Mar 6 13:46:49 2008 +1100 [XFS] cleanup vnode use in xfs_bmap.c SGI-PV: 976035 SGI-Modid: xfs-linux-melb:xfs-kern:30553a Signed-off-by: Christoph Hellwig Signed-off-by: Lachlan McIlroy commit e1c03a89f15d98a90fd691dafba8d0a628734a77 Author: Christoph Hellwig Date: Thu Mar 6 13:46:43 2008 +1100 [XFS] cleanup vnode use in xfs_iops.c SGI-PV: 976035 SGI-Modid: xfs-linux-melb:xfs-kern:30552a Signed-off-by: Christoph Hellwig Signed-off-by: Lachlan McIlroy commit e57c749cb9242aa508feed64f524dd6d44eab90f Author: Christoph Hellwig Date: Thu Mar 6 13:46:37 2008 +1100 [XFS] cleanup vnode use in xfs_lrw.c SGI-PV: 976035 SGI-Modid: xfs-linux-melb:xfs-kern:30551a Signed-off-by: Christoph Hellwig Signed-off-by: Lachlan McIlroy commit ce535a9f2bf4539260aeef394e88804e916ac6a9 Author: Christoph Hellwig Date: Thu Mar 6 13:46:25 2008 +1100 [XFS] cleanup vnode use in xfs_lookup SGI-PV: 976035 SGI-Modid: xfs-linux-melb:xfs-kern:30550a Signed-off-by: Christoph Hellwig Signed-off-by: Lachlan McIlroy commit b0481a0217985fdcfdd9e3f2254db59c4b90372c Author: Christoph Hellwig Date: Thu Mar 6 13:46:19 2008 +1100 [XFS] cleanup vnode use in xfs_symlink and xfs_rename SGI-PV: 976035 SGI-Modid: xfs-linux-melb:xfs-kern:30548a Signed-off-by: Christoph Hellwig Signed-off-by: Lachlan McIlroy commit 628dc8c106b0c6202ae4627c189f7c12e194a7a2 Author: Christoph Hellwig Date: Thu Mar 6 13:46:12 2008 +1100 [XFS] cleanup vnode use in xfs_link SGI-PV: 976035 SGI-Modid: xfs-linux-melb:xfs-kern:30547a Signed-off-by: Christoph Hellwig Signed-off-by: Lachlan McIlroy commit f0cc891093489cf2c29e89b2677ddc6af7ab58a4 Author: Christoph Hellwig Date: Thu Mar 6 13:46:05 2008 +1100 [XFS] cleanup vnode use in xfs_create/mknod/mkdir SGI-PV: 976035 SGI-Modid: xfs-linux-melb:xfs-kern:30546a Signed-off-by: Christoph Hellwig Signed-off-by: Lachlan McIlroy commit 5b3334aca915e7b8bba977273ee89cdff0d6eeed Author: Christoph Hellwig Date: Thu Mar 6 13:45:58 2008 +1100 [XFS] cleanup vnode use in dmapi calls SGI-PV: 976035 SGI-Modid: xfs-linux-melb:xfs-kern:30545a Signed-off-by: Christoph Hellwig Signed-off-by: Lachlan McIlroy commit f5fc8e8dd68da02295c54c99a4b4d08870e50b7a Author: David Chinner Date: Thu Mar 6 13:45:50 2008 +1100 [XFS] Fix superblock features2 field alignment problem Due to the xfs_dsb_t structure not being 64 bit aligned, the last field of the on-disk superblock can vary in location This causes problems when the filesystem gets moved to a different platform, or there is a 32 bit userspace and 64 bit kernel. This patch detects the defect at mount time, logs a warning such as: XFS: correcting sb_features alignment problem in dmesg and corrects the problem so that everything is OK. it also blacklists the bad field in the superblock so it does not get used for something else later on. SGI-PV: 977636 SGI-Modid: xfs-linux-melb:xfs-kern:30539a Signed-off-by: David Chinner Signed-off-by: Christoph Hellwig Signed-off-by: Eric Sandeen Signed-off-by: Lachlan McIlroy commit ef11434e04b7553372cc99322c5aedb59f8fe5be Author: David Chinner Date: Thu Mar 6 13:45:43 2008 +1100 [XFS] Use power-of-2 sized buffers to reduce overhead Now that the ktrace_enter() code is using atomics, the non-power-of-2 buffer sizes - which require modulus operations to get the index - are showing up as using substantial CPU in the profiles. Force the buffer sizes to be rounded up to the nearest power of two and use masking rather than modulus operations to convert the index counter to the buffer index. This reduces ktrace_enter overhead to 8% of a CPU time, and again almost halves the trace intensive test runtime. SGI-PV: 977546 SGI-Modid: xfs-linux-melb:xfs-kern:30538a Signed-off-by: David Chinner Signed-off-by: Christoph Hellwig Signed-off-by: Lachlan McIlroy commit 2d2f30e3ef953141d756e07c1d8cc0d7cc652557 Author: David Chinner Date: Thu Mar 6 13:45:35 2008 +1100 [XFS] Use atomic counters for ktrace buffer indexes ktrace_enter() is consuming vast amounts of CPU time due to the use of a single global lock for protecting buffer index increments. Change it to use per-buffer atomic counters - this reduces ktrace_enter() overhead during a trace intensive test on a 4p machine from 58% of all CPU time to 12% and halves test runtime. SGI-PV: 977546 SGI-Modid: xfs-linux-melb:xfs-kern:30537a Signed-off-by: David Chinner Signed-off-by: Christoph Hellwig Signed-off-by: Lachlan McIlroy commit 170c815e88c41859c9d79c9454c92dd9dd455bbe Author: David Chinner Date: Thu Mar 6 13:45:29 2008 +1100 [XFS] Update c/mtime correctly on truncates XFS changes the c/mtime of an inode when truncating it to the same size. The c/mtime is only supposed to change if the size is changed. Not to be confused with ftruncate, where the c/mtime is supposed to be changed even if the size is not changed. The Linux VFS encodes this semantic difference in the flags it sends down to ->setattr, which XFS currently ignores. We need to make XFS pay attention to the VFS flags and hence Do The Right Thing. SGI-PV: 977547 SGI-Modid: xfs-linux-melb:xfs-kern:30536a Signed-off-by: David Chinner Signed-off-by: Christoph Hellwig Signed-off-by: Lachlan McIlroy commit c657925dc0057ed2ec0db845a1a4f56651adfe39 Author: Eric Sandeen Date: Thu Mar 6 13:45:22 2008 +1100 [XFS] The forward declarations for the xfs_ioctl() helpers and the associated comment about gcc behavior really aren't needed; all of these functions are marked STATIC which includes noinline, and the stack usage won't be a problem. This effectively just removes the forward declarations and moves xfs_ioctl() back to the end of the file. SGI-PV: 971186 SGI-Modid: xfs-linux-melb:xfs-kern:30534a Signed-off-by: Eric Sandeen Signed-off-by: Niv Sardi Signed-off-by: Lachlan McIlroy commit c8911a1e34a4c3d858a4a6c176175c168da91256 Author: Christoph Hellwig Date: Thu Mar 6 13:45:16 2008 +1100 [XFS] don't encode parent in nfs filehandles unless nessecary As Dave pointed out after the export ops changes we now always encode the parent into the filehandle for regular files, but it's not actually needed when the filesystem is export with no_subtree_check. This one-liner fixes xfs_fs_encode_fh to skip encoding the parent unless nessecary. SGI-PV: 976035 SGI-Modid: xfs-linux-melb:xfs-kern:30535a Signed-off-by: Christoph Hellwig Signed-off-by: Lachlan McIlroy commit 08d618d64e9f77e89b50ae55c19e29ac9af8d6d9 Author: David Chinner Date: Thu Mar 6 13:45:10 2008 +1100 [XFS] 977545 977545 977545 977545 977545 977545 xfsaild causing too many wakeups Idle state is not being detected properly by the xfsaild push code. The current idle state is detected by an empty list which may never happen with mostly idle filesystem or one using lazy superblock counters. A single dirty item in the list that exists beyond the push target can result repeated looping attempting to push up to the target because it fails to check if the push target has been acheived or not. Fix by considering a dirty list with everything past the target as an idle state and set the timeout appropriately. SGI-PV: 977545 SGI-Modid: xfs-linux-melb:xfs-kern:30532a Signed-off-by: David Chinner Signed-off-by: Christoph Hellwig Signed-off-by: Lachlan McIlroy commit 95a8d08938c941ec5b955b019cbe0205029b1088 Author: Christoph Hellwig Date: Thu Mar 6 13:44:57 2008 +1100 [XFS] kill xfs_rwlock/xfs_rwunlock We can just use xfs_ilock/xfs_iunlock instead and get rid of the ugly bhv_vrwlock_t. SGI-PV: 976035 SGI-Modid: xfs-linux-melb:xfs-kern:30533a Signed-off-by: Christoph Hellwig Signed-off-by: Lachlan McIlroy commit ce1824a8ee563c36474b3346e3f5898229f5a5df Author: Christoph Hellwig Date: Thu Mar 6 13:44:50 2008 +1100 [XFS] kill xfs_get_dir_entry Instead of of xfs_get_dir_entry use a macro to get the xfs_inode from the dentry in the callers and grab the reference manually. Only grab the reference once as it's fine to keep it over the dmapi calls. (And even that reference is actually superflous in Linux but I'll leave that for another patch) SGI-PV: 976035 SGI-Modid: xfs-linux-melb:xfs-kern:30531a Signed-off-by: Christoph Hellwig Signed-off-by: Lachlan McIlroy commit 265eef775f891d5a4114fc888e4e99a6f9957819 Author: Christoph Hellwig Date: Thu Mar 6 13:44:41 2008 +1100 [XFS] vnode cleanup in xfs_fs_subr.c Cleanup the unneeded intermediate vnode step in the flushing helpers and go directly from the xfs_inode to the struct address_space. SGI-PV: 976035 SGI-Modid: xfs-linux-melb:xfs-kern:30530a Signed-off-by: Christoph Hellwig Signed-off-by: Lachlan McIlroy commit 2eecc359daed82612ff72b0dbe51407fa2018d9b Author: Christoph Hellwig Date: Thu Mar 6 13:44:35 2008 +1100 [XFS] cleanup xfs_vn_mknod - use proper goto based unwinding instead of the current mess of multiple conditionals - rename ip to inode because that's the normal convention for Linux inodes while ip is the convention for xfs_inodes - remove unlikely checks for the default_acl - branches marked unlikely might lead to extreme branch bredictor slowdons if taken and for some workloads a default acl is quite common - properly indent the switch statements - remove xfs_has_fs_struct as nfsd has a fs_struct in any semi-recent kernel SGI-PV: 976035 SGI-Modid: xfs-linux-melb:xfs-kern:30529a Signed-off-by: Christoph Hellwig Signed-off-by: Lachlan McIlroy commit 50ed1cf6950b5787d7cad811055b7fe2bf47de01 Author: Eric Sandeen Date: Thu Mar 6 13:44:28 2008 +1100 [XFS] remove shouting-indirection macros from xfs_sb.h Remove macro-to-small-function indirection from xfs_sb.h, and remove some which are completely unused. SGI-PV: 976035 SGI-Modid: xfs-linux-melb:xfs-kern:30528a Signed-off-by: Eric Sandeen Signed-off-by: Donald Douwsma Signed-off-by: Lachlan McIlroy commit 04f7551c9dc0e8c7cf98f3b31e3121fa427d96ff Author: David Chinner Date: Thu Mar 6 13:44:14 2008 +1100 [XFS] Use atomics for iclog reference counting Now that we update the log tail LSN less frequently on transaction completion, we pass the contention straight to the global log state lock (l_iclog_lock) during transaction completion. We currently have to take this lock to decrement the iclog reference count. there is a reference count on each iclog, so we need to take þhe global lock for all refcount changes. When large numbers of processes are all doing small trnasctions, the iclog reference counts will be quite high, and the state change that absolutely requires the l_iclog_lock is the except rather than the norm. Change the reference counting on the iclogs to use atomic_inc/dec so that we can use atomic_dec_and_lock during transaction completion and avoid the need for grabbing the l_iclog_lock for every reference count decrement except the one that matters - the last. SGI-PV: 975671 SGI-Modid: xfs-linux-melb:xfs-kern:30505a Signed-off-by: David Chinner Signed-off-by: Tim Shimmin Signed-off-by: Lachlan McIlroy commit f81d5fa628d0891b128fe9ddb6593e25b3f78ff3 Author: David Chinner Date: Thu Mar 6 13:44:06 2008 +1100 [XFS] Prevent AIL lock contention during transaction completion When hundreds of processors attempt to commit transactions at the same time, they can contend on the AIL lock when updating the tail LSN held in the in-core log structure. At the moment, the tail LSN is only needed when actually writing out an iclog, so it really does not need to be updated on every single transaction completion - only those that result in switching iclogs and flushing them to disk. The result is that we reduce the number of times we need to grab the AIL lock and the log grant lock by up to two orders of magnitude on large processor count machines. The problem has previously been hidden by AIL lock contention walking the AIL list which was recently solved and uncovered this issue. SGI-PV: 975671 SGI-Modid: xfs-linux-melb:xfs-kern:30504a Signed-off-by: David Chinner Signed-off-by: Tim Shimmin Signed-off-by: Lachlan McIlroy commit 73fd8efbc7f407291a5136ba2c945b48b816244c Author: David Chinner Date: Thu Mar 6 13:43:59 2008 +1100 [XFS] Use xfs_inode_clean() in more places Remove open coded checks for the whether the inode is clean and replace them with an inlined function. SGI-PV: 977461 SGI-Modid: xfs-linux-melb:xfs-kern:30503a Signed-off-by: David Chinner Signed-off-by: Christoph Hellwig Signed-off-by: Lachlan McIlroy commit 0b63ab688acec9b55b59efbc67987f245074c2a6 Author: David Chinner Date: Thu Mar 6 13:43:49 2008 +1100 [XFS] Remove the xfs_icluster structure Remove the xfs_icluster structure and replace with a radix tree lookup. We don't need to keep a list of inodes in each cluster around anymore as we can look them up quickly when we need to. The only time we need to do this now is during inode writeback. Factor the inode cluster writeback code out of xfs_iflush and convert it to use radix_tree_gang_lookup() instead of walking a list of inodes built when we first read in the inodes. This remove 3 pointers from each xfs_inode structure and the xfs_icluster structure per inode cluster. Hence we reduce the cache footprint of the xfs_inodes by between 5-10% depending on cluster sparseness. To be truly efficient we need a radix_tree_gang_lookup_range() call to stop searching once we are past the end of the cluster instead of trying to find a full cluster's worth of inodes. Before (ia64): $ cat /sys/slab/xfs_inode/object_size 536 After: $ cat /sys/slab/xfs_inode/object_size 512 SGI-PV: 977460 SGI-Modid: xfs-linux-melb:xfs-kern:30502a Signed-off-by: David Chinner Signed-off-by: Christoph Hellwig Signed-off-by: Lachlan McIlroy commit 1d53d23f1fd43baee04418a20dc4fa13e620a582 Author: David Chinner Date: Thu Mar 6 13:43:42 2008 +1100 [XFS] Don't block pdflush when writing back inodes When pdflush is writing back inodes, it can get stuck on inode cluster buffers that are currently under I/O. This occurs when we write data to multiple inodes in the same inode cluster at the same time. Effectively, delayed allocation marks the inode dirty during the data writeback. Hence if the inode cluster was flushed during the writeback of the first inode, the writeback of the second inode will block waiting for the inode cluster write to complete before writing it again for the newly dirtied inode. Basically, we want to avoid this from happening so we don't block pdflush and slow down all of writeback. Hence we introduce a non-blocking async inode flush flag that pdflush uses. If this flag is set, we use non-blocking operations (e.g. try locks) whereever we can to avoid blocking or extra I/O being issued. SGI-PV: 970925 SGI-Modid: xfs-linux-melb:xfs-kern:30501a Signed-off-by: David Chinner Signed-off-by: Lachlan McIlroy commit c228466268bc28bac1bb59306c0c3b5515e308f9 Author: David Chinner Date: Thu Mar 6 13:43:34 2008 +1100 [XFS] Factor xfs_itobp() and xfs_inotobp(). The only difference between the functions is one passes an inode for the lookup, the other passes an inode number. However, they don't do the same validity checking or set all the same state on the buffer that is returned yet they should. Factor the functions into a common implementation. SGI-PV: 970925 SGI-Modid: xfs-linux-melb:xfs-kern:30500a Signed-off-by: David Chinner Signed-off-by: Lachlan McIlroy commit ccc6812e4da9c0a9d45f9c21a45dc9a24a598845 Author: Lachlan McIlroy Date: Thu Mar 6 13:43:27 2008 +1100 [XFS] Fix regression due to refcache removal SGI-PV: 971186 SGI-Modid: xfs-linux-melb:xfs-kern:30490a Signed-off-by: Lachlan McIlroy Signed-off-by: Donald Douwsma commit 53c1cb8d6852aa34a09b14241944a7806ab8f341 Author: Donald Douwsma Date: Thu Mar 6 13:43:20 2008 +1100 [XFS] Remove the xfs_refcache, it was only needed while we were still building for 2.4 kernels. SGI-PV: 971186 SGI-Modid: xfs-linux-melb:xfs-kern:30472a Signed-off-by: Donald Douwsma Signed-off-by: Christoph Hellwig Signed-off-by: Lachlan McIlroy commit a818f7ddf92088d9edf5fdc1f846c7c0147c6337 Author: Lachlan McIlroy Date: Thu Mar 6 13:43:11 2008 +1100 [XFS] make inode reclaim synchronise with xfs_iflush_done() On a forced shutdown, xfs_finish_reclaim() will skip flushing the inode. If the inode flush lock is not already held and there is an outstanding xfs_iflush_done() then we might free the inode prematurely. By acquiring and releasing the flush lock we will synchronise with xfs_iflush_done(). SGI-PV: 909874 SGI-Modid: xfs-linux-melb:xfs-kern:30468a Signed-off-by: Lachlan McIlroy Signed-off-by: David Chinner commit e999831223874108192b9b72fff329af3934c821 Author: Niv Sardi Date: Thu Mar 6 13:43:03 2008 +1100 [XFS] actually check error returned by xfs_flush_pages, clean up and bailout if fails. SGI-PV: 973041 SGI-Modid: xfs-linux-melb:xfs-kern:30462a Signed-off-by: Niv Sardi Signed-off-by: Lachlan McIlroy commit 8b8c9f4a52550a50401fa76f63d8577af143aae2 Author: Avi Kivity Date: Wed Mar 5 09:33:44 2008 +0200 KVM: Remove pointless desc_ptr #ifdef The desc_struct changes left an unnecessary #ifdef; remove it. Signed-off-by: Avi Kivity commit 75b85122cce48e9a762ab8cd04cfc37080cae601 Author: Avi Kivity Date: Wed Mar 5 09:19:21 2008 +0200 KVM: Merge generic x86 name usage from upstream Signed-off-by: Avi Kivity commit 5e23049e86dd298b72e206b420513dbc3a240cd9 Author: Avi Kivity Date: Tue Mar 4 13:26:55 2008 +0200 Revert "KVM: is_long_mode() should check for EFER.LMA" This reverts commit 3a001629eea909b2aa97f001a9db4700f15d986b. It kills Windows Vista SMP install. Signed-off-by: Avi Kivity commit d451a2c03f78c306049da9fecd95316f368641cf Author: Avi Kivity Date: Tue Mar 4 10:44:51 2008 +0200 KVM: VMX: Don't adjust tsc offset forward Most Intel hosts have a stable tsc, and playing with the offset only reduces accuracy. By limiting tsc offset adjustment only to forward updates, we effectively disable tsc offset adjustment on these hosts. Signed-off-by: Avi Kivity commit f2c0457351b0ffbe9d97a095474eab2bac2b496b Author: Harvey Harrison Date: Mon Mar 3 12:59:56 2008 -0800 KVM: replace remaining __FUNCTION__ occurances __FUNCTION__ is gcc-specific, use __func__ Signed-off-by: Harvey Harrison Signed-off-by: Avi Kivity commit 3a001629eea909b2aa97f001a9db4700f15d986b Author: Amit Shah Date: Thu Feb 28 16:06:15 2008 +0530 KVM: is_long_mode() should check for EFER.LMA is_long_mode currently checks the LongModeEnable bit in EFER instead of the LongModeActive bit. This is wrong, but we survived this till now since it wasn't triggered. This breaks guests that go from long mode to compatibility mode. This is noticed on a solaris guest and fixes bug #1842160 Signed-off-by: Amit Shah Signed-off-by: Avi Kivity commit 4a7f582a07e14763ee4714b681e98b3b134d1d46 Author: Avi Kivity Date: Wed Feb 27 16:06:57 2008 +0200 KVM: VMX: Avoid rearranging switched guest msrs while they are loaded KVM tries to run as much as possible with the guest msrs loaded instead of host msrs, since switching msrs is very expensive. It also tries to minimize the number of msrs switched according to the guest mode; for example, MSR_LSTAR is needed only by long mode guests. This optimization is done by setup_msrs(). However, we must not change which msrs are switched while we are running with guest msr state: - switch to guest msr state - call setup_msrs(), removing some msrs from the list - switch to host msr state, leaving a few guest msrs loaded An easy way to trigger this is to kexec an x86_64 linux guest. Early during setup, the guest will switch EFER to not include SCE. KVM will stop saving MSR_LSTAR, and on the next msr switch it will leave the guest LSTAR loaded. The next host syscall will end up in a random location in the kernel. Fix by reloading the host msrs before changing the msr list. Signed-off-by: Avi Kivity commit fe5d62ebfc077da1e9a9748bcc2dd696c1026584 Author: Avi Kivity Date: Wed Feb 27 07:55:38 2008 +0200 KVM: MMU: Fix fallout from last patch Some x86_64-only calls to kvm_mmu_get_page() escaped being changed. Signed-off-by: Avi Kivity commit d8d1cb05c5fa5ca2cd99acae0884e263e6f3a9be Author: Avi Kivity Date: Tue Feb 26 22:12:10 2008 +0200 KVM: MMU: Fix race when instantiating a shadow pte For improved concurrency, the guest walk is performed concurrently with other vcpus. This means that we need to revalidate the guest ptes once we have write-protected the guest page tables, at which point they can no longer be modified. The current code attempts to avoid this check if the shadow page table is not new, on the assumption that if it has existed before, the guest could not have modified the pte without the shadow lock. However the assumption is incorrect, as the racing vcpu could have modified the pte, then instantiated the shadow page, before our vcpu regains control: vcpu0 vcpu1 fault walk pte modify pte fault in same pagetable instantiate shadow page lookup shadow page conclude it is old instantiate spte based on stale guest pte We could do something clever with generation counters, but a test run by Marcelo suggests this is unnecessary and we can just do the revalidation unconditionally. The pte will be in the processor cache and the check can be quite fast. Signed-off-by: Avi Kivity commit 434de00974230e41cbf1882f2d325452300d241e Author: Joerg Roedel Date: Tue Feb 26 16:49:16 2008 +0100 KVM: detect if VCPU triple faults In the current inject_page_fault path KVM only checks if there is another PF pending and injects a DF then. But it has to check for a pending DF too to detect a shutdown condition in the VCPU. If this is not detected the VCPU goes to a PF -> DF -> PF loop when it should triple fault. This patch detects this condition and handles it with an KVM_SHUTDOWN exit to userspace. Signed-off-by: Joerg Roedel Signed-off-by: Avi Kivity commit fbba6a550c73fbc7578ecefd3ebd39db91f54c3a Author: Marcelo Tosatti Date: Mon Feb 25 10:36:05 2008 -0300 KVM: release bad page on MSR_KVM_SYSTEM_TIME Subject says it all. Signed-off-by: Marcelo Tosatti Signed-off-by: Avi Kivity commit 7bcbbed481df1e6fb3bffd6e90f640a1a2e13e75 Author: Xiantao Zhang Date: Mon Feb 25 18:52:20 2008 +0800 KVM: Use kzalloc to avoid allocating kvm_regs from kernel stack Since the size of kvm_regs is too big to allocate from kernel stack on ia64, use kzalloc to allocate it. Signed-off-by: Xiantao Zhang Signed-off-by: Avi Kivity commit d602a5d8d74980a3c0b097c35c04036a04286018 Author: Avi Kivity Date: Mon Feb 25 10:28:31 2008 +0200 KVM: Route irq 0 to vcpu 0 exclusively Some Linux versions allow the timer interrupt to be processed by more than one cpu, leading to hangs due to tsc instability. Work around the issue by only disaptching the interrupt to vcpu 0. Problem analyzed (and patch tested) by Sheng Yang. Signed-off-by: Avi Kivity commit 81e4400b4df4e597a81c19c1161aa03c73613710 Author: Avi Kivity Date: Sun Feb 24 14:37:50 2008 +0200 KVM: Avoid infinite-frequency local apic timer If the local apic initial count is zero, don't start a an hrtimer with infinite frequency, locking up the host. Signed-off-by: Avi Kivity commit 86774a47f71bd84f124dd8d6062a2d6c91e1bc65 Author: Avi Kivity Date: Sun Feb 24 11:20:43 2008 +0200 KVM: Prefix control register accessors with kvm_ to avoid namespace pollution Names like 'set_cr3()' look dangerously close to affecting the host. Signed-off-by: Avi Kivity commit c5ed4516ef4ebf10de8bcb006676b67daea1b683 Author: Marcelo Tosatti Date: Sat Feb 23 11:44:30 2008 -0300 KVM: MMU: large page support Create large pages mappings if the guest PTE's are marked as such and the underlying memory is hugetlbfs backed. If the largepage contains write-protected pages, a large pte is not used. Gives a consistent 2% improvement for data copies on ram mounted filesystem, without NPT/EPT. Anthony measures a 4% improvement on 4-way kernbench, with NPT. Signed-off-by: Marcelo Tosatti Signed-off-by: Avi Kivity commit a92ecfcb8c31e173982c0119ff792dc707633479 Author: Glauber Costa Date: Thu Feb 21 18:04:14 2008 -0300 KVM: call write_guest_time as soon as we register the paravirt clock In situations, like, cpu hotplugging, a cpu can arrive later on the game and register its paravirt clock while everything else is already running, which will lead to breakage, since the time readings will return bogus values. To prevent this, we write system time as soon as the guest registers its clock. Signed-off-by: Glauber Costa Signed-off-by: Avi Kivity commit d6dfa24b3ac47784a214a8facc153b389b8c8bc1 Author: Marcelo Tosatti Date: Wed Feb 20 14:47:24 2008 -0500 KVM: MMU: ignore zapped root pagetables Mark zapped root pagetables as invalid and ignore such pages during lookup. This is a problem with the cr3-target feature, where a zapped root table fools the faulting code into creating a read-only mapping. The result is a lockup if the instruction can't be emulated. Signed-off-by: Marcelo Tosatti Cc: Anthony Liguori Signed-off-by: Avi Kivity commit 131c7cbe6154ce34f5db796ce3d1494f6c648300 Author: Alexander Graf Date: Thu Feb 21 12:11:01 2008 +0100 KVM: Implement dummy values for MSR_PERF_STATUS Darwin relies on this and ceases to work without. Signed-off-by: Alexander Graf Signed-off-by: Avi Kivity commit 5e99f27fa140b7b1b586eb95be6d9abc44c98d33 Author: Harvey Harrison Date: Tue Feb 19 10:25:50 2008 -0800 KVM: sparse fixes for kvm/x86.c In two case statements, use the ever popular 'i' instead of index: arch/x86/kvm/x86.c:1063:7: warning: symbol 'index' shadows an earlier one arch/x86/kvm/x86.c:1000:9: originally declared here arch/x86/kvm/x86.c:1079:7: warning: symbol 'index' shadows an earlier one arch/x86/kvm/x86.c:1000:9: originally declared here Make it static. arch/x86/kvm/x86.c:1945:24: warning: symbol 'emulate_ops' was not declared. Should it be static? Drop the return statements. arch/x86/kvm/x86.c:2878:2: warning: returning void-valued expression arch/x86/kvm/x86.c:2944:2: warning: returning void-valued expression Signed-off-by: Harvey Harrison Signed-off-by: Avi Kivity commit 89a5a065c12d910a5b9de0f515e96e05a12e03eb Author: Harvey Harrison Date: Tue Feb 19 10:32:02 2008 -0800 KVM: SVM: make iopm_base static Fixes sparse warning as well. arch/x86/kvm/svm.c:69:15: warning: symbol 'iopm_base' was not declared. Should it be static? Signed-off-by: Harvey Harrison Signed-off-by: Avi Kivity commit 96b54a441cf09ea03b673f0f1fdc56781006fc9c Author: Harvey Harrison Date: Tue Feb 19 10:43:11 2008 -0800 KVM: x86 emulator: fix sparse warnings in x86_emulate.c Nesting __emulate_2op_nobyte inside__emulate_2op produces many shadowed variable warnings on the internal variable _tmp used by both macros. Change the outer macro to use __tmp. Avoids a sparse warning like the following at every call site of __emulate_2op arch/x86/kvm/x86_emulate.c:1091:3: warning: symbol '_tmp' shadows an earlier one arch/x86/kvm/x86_emulate.c:1091:3: originally declared here [18 more warnings suppressed] Signed-off-by: Harvey Harrison Signed-off-by: Avi Kivity commit a7feb918e1a5ba13dbfb8584a10cdf5d1174a0f7 Author: Amit Shah Date: Thu Feb 21 01:00:30 2008 +0530 KVM: Add stat counter for hypercalls Signed-off-by: Amit Shah Signed-off-by: Avi Kivity commit 03c96d38f62c5baa05bb0f890410f88bf96806af Author: Avi Kivity Date: Wed Feb 20 17:57:21 2008 +0200 KVM: Use x86's segment descriptor struct instead of private definition The x86 desc_struct unification allows us to remove segment_descriptor.h. Signed-off-by: Avi Kivity commit d6f633e2fc1931de330962c2c0f1bcf8036c5f8a Author: Avi Kivity Date: Wed Feb 20 14:55:05 2008 +0200 KVM: VMX: Handle machines without EFER Signed-off-by: Avi Kivity commit 24994a75d87235a12087d0669f95145b3a77785d Author: Avi Kivity Date: Wed Feb 20 12:04:47 2008 +0200 KVM: Increase the number of user memory slots per vm Signed-off-by: Avi Kivity commit 5d625525ce1281b7f08af94cd5f977fee3be2a13 Author: Avi Kivity Date: Wed Feb 20 11:59:20 2008 +0200 KVM: Add API for determining the number of supported memory slots Signed-off-by: Avi Kivity commit 318438f6662e92b83d9509eb47b74ffb7ffcfb59 Author: Avi Kivity Date: Wed Feb 20 11:56:51 2008 +0200 KVM: Increase vcpu count to 16 With NPT support, scalability is much improved. Signed-off-by: Avi Kivity commit 44fd69bae2e588f2cf9df73ab2ccbd1db4446e50 Author: Avi Kivity Date: Wed Feb 20 11:53:16 2008 +0200 KVM: Add API to retrieve the number of supported vcpus per vm Signed-off-by: Avi Kivity commit 47e13e4e4bcc4f0e5da2931af79239ddbd72aacc Author: Harvey Harrison Date: Tue Feb 19 07:40:41 2008 -0800 KVM: x86 emulator: make register_address_increment and JMP_REL static inlines Change jmp_rel() to a function as well. Signed-off-by: Harvey Harrison Signed-off-by: Avi Kivity commit 83b3caa5a9142d132eeaa59d6580ea31a90d54e1 Author: Harvey Harrison Date: Tue Feb 19 07:40:38 2008 -0800 KVM: x86 emulator: make register_address, address_mask static inlines Signed-off-by: Harvey Harrison Signed-off-by: Avi Kivity commit 3c1002ca9b60140fcace61c21af8d417061dd8d3 Author: Harvey Harrison Date: Mon Feb 18 11:12:48 2008 -0800 KVM: x86 emulator: add ad_mask static inline Replaces open-coded mask calculation in macros. Signed-off-by: Harvey Harrison Signed-off-by: Avi Kivity commit 6c87c4157ed6fe54f4b25463668f696e73f3695a Author: Avi Kivity Date: Mon Feb 18 18:25:14 2008 +0200 KVM: Add missing semicolon Signed-off-by: Avi Kivity commit 497e3206d70707731acf89ae57a30916433f7abd Author: Glauber de Oliveira Costa Date: Fri Feb 15 17:52:48 2008 -0200 KVM: paravirtualized clocksource: guest part This is the guest part of kvm clock implementation It does not do tsc-only timing, as tsc can have deltas between cpus, and it did not seem worthy to me to keep adjusting them. We do use it, however, for fine-grained adjustment. Other than that, time comes from the host. Signed-off-by: Glauber de Oliveira Costa Signed-off-by: Avi Kivity commit 58ec320754007ae73dd2a2a050cc98aed9492b68 Author: Glauber de Oliveira Costa Date: Fri Feb 15 17:52:47 2008 -0200 KVM: paravirtualized clocksource: host part This is the host part of kvm clocksource implementation. As it does not include clockevents, it is a fairly simple implementation. We only have to register a per-vcpu area, and start writing to it periodically. The area is binary compatible with xen, as we use the same shadow_info structure. Signed-off-by: Glauber de Oliveira Costa Signed-off-by: Avi Kivity commit 08bb7f949a94cd53d4fb1db4eb84d30a0710fb72 Author: Marcelo Tosatti Date: Thu Feb 14 21:25:39 2008 -0200 KVM: make MMU_DEBUG compile again the cr3 variable is now inside the vcpu->arch structure. Signed-off-by: Marcelo Tosatti Signed-off-by: Avi Kivity commit a39c8d8589081a80367b42041e9e42daccc9a17b Author: Marcelo Tosatti Date: Thu Feb 14 21:21:43 2008 -0200 KVM: move alloc_apic_access_page() outside of non-preemptable region alloc_apic_access_page() can sleep, while vmx_vcpu_setup is called inside a non preemptable region. Move it after put_cpu(). Signed-off-by: Marcelo Tosatti Signed-off-by: Avi Kivity commit 7ab1174b8c8bd0b1f6ef7cdd692261cef4b6173f Author: Joerg Roedel Date: Wed Feb 13 18:58:47 2008 +0100 KVM: SVM: enable LBR virtualization This patch implements the Last Branch Record Virtualization (LBRV) feature of the AMD Barcelona and Phenom processors into the kvm-amd module. It will only be enabled if the guest enables last branch recording in the DEBUG_CTL MSR. So there is no increased world switch overhead when the guest doesn't use these MSRs. Signed-off-by: Joerg Roedel Signed-off-by: Markus Rechberger Signed-off-by: Avi Kivity commit fe3b460580c595d21045dc935ebc0ba11fe52c9b Author: Joerg Roedel Date: Wed Feb 13 18:58:46 2008 +0100 KVM: SVM: allocate the MSR permission map per VCPU This patch changes the kvm-amd module to allocate the SVM MSR permission map per VCPU instead of a global map for all VCPUs. With this we have more flexibility allowing specific guests to access virtualized MSRs. This is required for LBR virtualization. Signed-off-by: Joerg Roedel Signed-off-by: Markus Rechberger Signed-off-by: Avi Kivity commit 2fe78025ef70748afc52106b764062e236984220 Author: Joerg Roedel Date: Wed Feb 13 18:58:45 2008 +0100 KVM: SVM: let init_vmcb() take struct vcpu_svm as parameter Change the parameter of the init_vmcb() function in the kvm-amd module from struct vmcb to struct vcpu_svm. Signed-off-by: Joerg Roedel Signed-off-by: Markus Rechberger Signed-off-by: Avi Kivity commit c2d0c60a00245874d3d615129f35284ba6b7adbe Author: Joerg Roedel Date: Wed Feb 13 16:30:28 2008 +0100 KVM: SVM: fix Windows XP 64 bit installation crash While installing Windows XP 64 bit wants to access the DEBUGCTL and the last branch record (LBR) MSRs. Don't allowing this in KVM causes the installation to crash. This patch allow the access to these MSRs and fixes the issue. Signed-off-by: Joerg Roedel Signed-off-by: Markus Rechberger Signed-off-by: Avi Kivity commit 9ef1f35a7665b2190ae42542d2d8b6624ec227df Author: Izik Eidus Date: Sun Feb 10 18:04:15 2008 +0200 KVM: remove the usage of the mmap_sem for the protection of the memory slots. This patch replaces the mmap_sem lock for the memory slots with a new kvm private lock, it is needed beacuse untill now there were cases where kvm accesses user memory while holding the mmap semaphore. Signed-off-by: Izik Eidus Signed-off-by: Avi Kivity commit e7861364d06434a0ce1a363cc6c1da2023be4375 Author: Ryan Harper Date: Mon Feb 11 10:26:38 2008 -0600 KVM: VMX: fix typo in VMX header define Looking at Intel Volume 3b, page 148, table 20-11 and noticed that the field name is 'Deliver' not 'Deliever'. Attached patch changes the define name and its user in vmx.c Signed-off-by: Ryan Harper Signed-off-by: Avi Kivity commit 7bf579b95ef1c7b6490ae5be183f0035665ce6f4 Author: Joerg Roedel Date: Mon Feb 11 20:28:27 2008 +0100 KVM: emulate access to MSR_IA32_MCG_CTL Injecting an GP when accessing this MSR lets Windows crash when running some stress test tools in KVM. So this patch emulates access to this MSR. Signed-off-by: Joerg Roedel Signed-off-by: Markus Rechberger Signed-off-by: Avi Kivity commit d3581426e289fb84c661c92c72bb84a907c175d6 Author: Avi Kivity Date: Mon Feb 11 18:37:23 2008 +0200 KVM: Make the supported cpuid list a host property rather than a vm property One of the use cases for the supported cpuid list is to create a "greatest common denominator" of cpu capabilities in a server farm. As such, it is useful to be able to get the list without creating a virtual machine first. Since the code does not depend on the vm in any way, all that is needed is to move it to the device ioctl handler. The capability identifier is also changed so that binaries made against -rc1 will fail gracefully. Signed-off-by: Avi Kivity commit 660229476e0b735048c99139f8ee53fdd1da25a9 Author: Paul Knowles Date: Wed Feb 6 11:02:35 2008 +0000 KVM: Fix kvm_arch_vcpu_ioctl_set_sregs so that set_cr0 works properly Whilst working on getting a VM to initialize in to IA32e mode I found this issue. set_cr0 relies on comparing the old cr0 to the new one to work correctly. Move the assignment below so the compare can work. Signed-off-by: Paul Knowles Signed-off-by: Avi Kivity commit 63f53075ea87ff02541dc67bb7cccbfd5f68d6e9 Author: Avi Kivity Date: Sun Feb 10 19:46:29 2008 +0200 KVM: x86 emulator: fix group 5 decoding Commit 9686f6d5bed04b489947cecc2554a49f0769d365 failed to add the ModRM marker to a few group 5 instructions, causing Windows install failures. Signed-off-by: Avi Kivity commit 4b4c4e5de3e6ae4209d15abbd559847a785e035a Author: Avi Kivity Date: Sun Feb 10 19:44:10 2008 +0200 KVM: x86 emulator: Fix 'jmp abs' The group decoding changes (9686f6d5bed04b489947cecc2554a49f0769d365) changed the jump target to be a source operand instead of a target operand. Adjust the code accordingly. Signed-off-by: Avi Kivity commit 6ae2f81215514a62ae12e5ea4520e1041a54c597 Author: Joerg Roedel Date: Thu Feb 7 13:47:45 2008 +0100 KVM: SVM: add support for Nested Paging This patch contains the SVM architecture dependent changes for KVM to enable support for the Nested Paging feature of AMD Barcelona and Phenom processors. Signed-off-by: Joerg Roedel Signed-off-by: Avi Kivity commit 84fed657c49862eb39b8cb9f66b0a70feaf7ec6e Author: Joerg Roedel Date: Thu Feb 7 13:47:44 2008 +0100 KVM: MMU: add TDP support to the KVM MMU This patch contains the changes to the KVM MMU necessary for support of the Nested Paging feature in AMD Barcelona and Phenom Processors. Signed-off-by: Joerg Roedel Signed-off-by: Avi Kivity commit e3cf42a83679c80800166ad01b30ff9595c61cd4 Author: Joerg Roedel Date: Thu Feb 7 13:47:43 2008 +0100 KVM: export the load_pdptrs() function to modules The load_pdptrs() function is required in the SVM module for NPT support. Signed-off-by: Joerg Roedel Signed-off-by: Avi Kivity commit 926d75dd44c47fad657d7db7a0ae898db30b0627 Author: Joerg Roedel Date: Thu Feb 7 13:47:42 2008 +0100 KVM: MMU: make the __nonpaging_map function generic The mapping function for the nonpaging case in the softmmu does basically the same as required for Nested Paging. Make this function generic so it can be used for both. Signed-off-by: Joerg Roedel Signed-off-by: Avi Kivity commit 150f377485bc2cbc06b53b586f21f61f9dc055ad Author: Joerg Roedel Date: Thu Feb 7 13:47:41 2008 +0100 KVM: export information about NPT to generic x86 code The generic x86 code has to know if the specific implementation uses Nested Paging. In the generic code Nested Paging is called Two Dimensional Paging (TDP) to avoid confusion with (future) TDP implementations of other vendors. This patch exports the availability of TDP to the generic x86 code. Signed-off-by: Joerg Roedel Signed-off-by: Avi Kivity commit 927f4f904044c202b88a284db87833585cb9ab10 Author: Joerg Roedel Date: Thu Feb 7 13:47:40 2008 +0100 KVM: SVM: add module parameter to disable Nested Paging To disable the use of the Nested Paging feature even if it is available in hardware this patch adds a module parameter. Nested Paging can be disabled by passing npt=0 to the kvm_amd module. Signed-off-by: Joerg Roedel Signed-off-by: Avi Kivity commit 23b602a35f91c7720555aed3a46e9646d8ce6aed Author: Joerg Roedel Date: Thu Feb 7 13:47:39 2008 +0100 KVM: SVM: add detection of Nested Paging feature Let SVM detect if the Nested Paging feature is available on the hardware. Disable it to keep this patch series bisectable. Signed-off-by: Joerg Roedel Signed-off-by: Avi Kivity commit e9b3b167d8554283fac3c099546342180609113b Author: Joerg Roedel Date: Thu Feb 7 13:47:38 2008 +0100 KVM: SVM: move feature detection to hardware setup code By moving the SVM feature detection from the each_cpu code to the hardware setup code it runs only once. As an additional advance the feature check is now available earlier in the module setup process. Signed-off-by: Joerg Roedel Signed-off-by: Avi Kivity commit 8de389b7c62ec345dc6e88b6d6d5610cda3bbdf6 Author: Balbir Singh Date: Sun Feb 10 12:46:28 2008 +0530 KVM: fix Kconfig on i386 The KVM configuration is no longer visible in the latest git tree. It looks like it is selected by HAVE_SETUP_PER_CPU_AREA. I've moved HAVE_KVM to under CONFIG_X86. Hopefully, this is the right fix. Signed-off-by: Balbir Singh Signed-off-by: Avi Kivity commit b475283d7688169261a91d95bd636a6ab584f2b8 Author: Joerg Roedel Date: Thu Jan 31 14:57:40 2008 +0100 KVM: allow access to EFER in 32bit KVM This patch makes the EFER register accessible on a 32bit KVM host. This is necessary to boot 32 bit PAE guests under SVM. Signed-off-by: Joerg Roedel Signed-off-by: Avi Kivity commit 778ff2130dd6ab9ee9e3706b5826f2c8d41615df Author: Joerg Roedel Date: Thu Jan 31 14:57:39 2008 +0100 KVM: VMX: unifdef the EFER specific code To allow access to the EFER register in 32bit KVM the EFER specific code has to be exported to the x86 generic code. This patch does this in a backwards compatible manner. Signed-off-by: Joerg Roedel Signed-off-by: Avi Kivity commit 0b8ab0022998c6607da96ef907ecb3dad614b178 Author: Joerg Roedel Date: Thu Jan 31 14:57:38 2008 +0100 KVM: align valid EFER bits with the features of the host system This patch aligns the bits the guest can set in the EFER register with the features in the host processor. Currently it lets EFER.NX disabled if the processor does not support it and enables EFER.LME and EFER.LMA only for KVM on 64 bit hosts. Signed-off-by: Joerg Roedel Signed-off-by: Avi Kivity commit cdab4954a00da8c427dc03eb7f5e630eecd22c68 Author: Joerg Roedel Date: Thu Jan 31 14:57:37 2008 +0100 KVM: make EFER_RESERVED_BITS configurable for architecture code This patch give the SVM and VMX implementations the ability to add some bits the guest can set in its EFER register. Signed-off-by: Joerg Roedel Signed-off-by: Avi Kivity commit 6ac0eb9e4614ddaf459d054434a4752167d904d5 Author: Andrea Arcangeli Date: Wed Jan 30 19:57:35 2008 +0100 KVM: Disable pagefaults during copy_from_user_inatomic() With CONFIG_PREEMPT=n, this is needed in order to disable the fault-in code from sleeping. Signed-off-by: Andrea Arcangeli Signed-off-by: Avi Kivity commit 1d59f5a241eee56ca761a3e8f87b8603c49a3dc8 Author: Joerg Roedel Date: Tue Jan 29 13:01:27 2008 +0100 KVM: SVM: set NM intercept when enabling CR0.TS in the guest Explicitly enable the NM intercept in svm_set_cr0 if we enable TS in the guest copy of CR0 for lazy FPU switching. This fixes guest SMP with Linux under SVM. Without that patch Linux deadlocks or panics right after trying to boot the other CPUs. Signed-off-by: Joerg Roedel Signed-off-by: Markus Rechberger Signed-off-by: Avi Kivity commit 4db952288bb60c94940bb6484952616fa840b009 Author: Hollis Blanchard Date: Mon Jan 28 17:42:34 2008 -0600 KVM: Use CONFIG_PREEMPT_NOTIFIERS around struct preempt_notifier This allows kvm_host.h to be #included even when struct preempt_notifier is undefined. This is needed to build ppc asm-offsets.h. Signed-off-by: Hollis Blanchard Signed-off-by: Avi Kivity commit b2110b6affc2571b0974292567196f3eba8a304f Author: Sheng Yang Date: Tue Jan 29 08:17:57 2008 +0800 KVM: VMX: Fix invalid opcode of VPID Add the missing "memory" in VPID clobber list, otherwise it would cause invalid opcode on host. Signed-off-by: Sheng Yang Signed-off-by: Avi Kivity commit b90a99cf8e03e96a4e3347d9e9ee3750e53d07fd Author: Sheng Yang Date: Thu Jan 17 15:14:33 2008 +0800 KVM: VMX: Enable Virtual Processor Identification (VPID) To allow TLB entries to be retained across VM entry and VM exit, the VMM can now identify distinct address spaces through a new virtual-processor ID (VPID) field of the VMCS. [avi: drop vpid_sync_all()] [avi: add "cc" to asm constraints] Signed-off-by: Sheng Yang Signed-off-by: Avi Kivity commit 933400f42599aeec7765e128cf383e7f0e86b457 Author: Avi Kivity Date: Thu Jan 24 15:13:08 2008 +0200 KVM: Limit vcpu mmap size to one page on non-x86 The second page is only needed on archs that support pio. Noted by Carsten Otte. Signed-off-by: Avi Kivity commit ad3fefd6f9da9e12834b693d24ad95963b243dc9 Author: Avi Kivity Date: Thu Jan 24 11:44:11 2008 +0200 KVM: MMU: Decouple mmio from shadow page tables Currently an mmio guest pte is encoded in the shadow pagetable as a not-present trapping pte, with the SHADOW_IO_MARK bit set. However nothing is ever done with this information, so maintaining it is a useless complication. This patch moves the check for mmio to before shadow ptes are instantiated, so the shadow code is never invoked for ptes that reference mmio. The code is simpler, and with future work, can be made to handle mmio concurrently. Signed-off-by: Avi Kivity commit cdad27870dc2b8de7503346c66d4ef7c0b0d5690 Author: Avi Kivity Date: Wed Jan 23 22:26:09 2008 +0200 KVM: x86 emulator: group decoding for group 1 instructions Opcodes 0x80-0x83 Signed-off-by: Avi Kivity commit 26b95ed248648c686ff6537822f8e46662de6de6 Author: Avi Kivity Date: Wed Jan 23 18:14:23 2008 +0200 KVM: Only x86 has pio Signed-off-by: Avi Kivity commit 3abf467ddceca15ea9188068e711d284619e07e5 Author: Jan Engelhardt Date: Tue Jan 22 20:46:14 2008 +0100 KVM: constify function pointer tables Signed-off-by: Jan Engelhardt Signed-off-by: Avi Kivity commit 3d12af8d03b98644df72c9ac59416d37ea000303 Author: Avi Kivity Date: Fri Jan 18 13:36:50 2008 +0200 KVM: x86 emulator: add group 7 decoding This adds group decoding for opcode 0x0f 0x01 (group 7). Signed-off-by: Avi Kivity commit 9686f6d5bed04b489947cecc2554a49f0769d365 Author: Avi Kivity Date: Fri Jan 18 13:12:26 2008 +0200 KVM: x86 emulator: Group decoding for groups 4 and 5 Add group decoding support for opcode 0xfe (group 4) and 0xff (group 5). Signed-off-by: Avi Kivity commit e17c176005534ed6cf1cf88b0c5a2dc2d318b228 Author: Avi Kivity Date: Fri Jan 18 12:58:04 2008 +0200 KVM: x86 emulator: Group decoding for group 3 This adds group decoding support for opcodes 0xf6, 0xf7 (group 3). Signed-off-by: Avi Kivity commit cecd640eb846f2af6be560892bdc26b775cb71ef Author: Avi Kivity Date: Fri Jan 18 12:46:50 2008 +0200 KVM: x86 emulator: group decoding for group 1A This adds group decode support for opcode 0x8f. Signed-off-by: Avi Kivity commit e5ecefe4f9a58509099279939c1b389896bbc55a Author: Avi Kivity Date: Fri Jan 18 12:38:59 2008 +0200 KVM: x86 emulator: add support for group decoding Certain x86 instructions use bits 3:5 of the byte following the opcode as an opcode extension, with the decode sometimes depending on bits 6:7 as well. Add support for this in the main decoding table rather than an ad-hock adaptation per opcode. Signed-off-by: Avi Kivity commit 29ae41a859a12aa71baacd35a9648511f335848e Author: Feng(Eric) Liu Date: Tue Jan 22 18:01:08 2008 -0500 KVM: MMU: Fix gpa truncation when reading a pte Since the type of gpa is u64, so extend pte_size to u64. Otherwise, gpa may be truncated to u32. Signed-off-by: Feng (Eric) Liu Signed-off-by: Avi Kivity commit 67704e250e558f937c25fa44b6dd0e4fb9f12341 Author: Joerg Roedel Date: Mon Jan 21 13:09:33 2008 +0100 KVM: SVM: Fix lazy FPU switching If the guest writes to cr0 and leaves the TS flag at 0 while vcpu->fpu_active is also 0, the TS flag in the guest's cr0 gets lost. This leads to corrupt FPU state an causes Windows Vista 64bit to crash very soon after boot. This patch fixes this bug. Signed-off-by: Joerg Roedel Signed-off-by: Markus Rechberger Signed-off-by: Avi Kivity commit 5b644f6246905396f05ebe0f570c50bd81fce850 Author: Avi Kivity Date: Wed Jan 16 12:49:30 2008 +0200 KVM: Move apic timer migration away from critical section Migrating the apic timer in the critical section is not very nice, and is absolutely horrible with the real-time port. Move migration to the regular vcpu execution path, triggered by a new bitflag. Cc: Thomas Gleixner Signed-off-by: Avi Kivity commit cf953c92a6a89b2256d92cb969df34e00f5d78df Author: Glauber de Oliveira Costa Date: Tue Jan 15 13:10:15 2008 -0200 KVM: Put kvm_para.h include outside __KERNEL__ kvm_para.h potentially contains definitions that are to be used by userspace, so it should not be included inside the __KERNEL__ block. To protect its own data structures, kvm_para.h already includes its own __KERNEL__ block. Signed-off-by: Glauber de Oliveira Costa Acked-by: Amit Shah Signed-off-by: Avi Kivity commit e523e00f4e2fe71b123bb102a8847f86b5b4bd8b Author: Avi Kivity Date: Tue Jan 15 18:27:32 2008 +0200 KVM: Fix unbounded preemption latency When preparing to enter the guest, if an interrupt comes in while preemption is disabled but interrupts are still enabled, we miss a preemption point. Fix by explicitly checking whether we need to reschedule. Signed-off-by: Thomas Gleixner Signed-off-by: Avi Kivity commit 9e007c2364364e4243870a61c7e8ed9f8527fa5b Author: Avi Kivity Date: Sun Jan 13 13:23:56 2008 +0200 KVM: Initialize the mmu caches only after verifying cpu support Otherwise we re-initialize the mmu caches, which will fail since the caches are already registered, which will cause us to deinitialize said caches. Signed-off-by: Avi Kivity commit b790d90bb55c3733ec9de6bf60c84ec15e10362e Author: Izik Eidus Date: Sat Jan 12 23:49:09 2008 +0200 KVM: MMU: Fix dirty page setting for pages removed from rmap Right now rmap_remove won't set the page as dirty if the shadow pte pointed to this page had write access and then it became readonly. This patches fixes that, by setting the page as dirty for spte changes from write to readonly access. Signed-off-by: Izik Eidus Signed-off-by: Avi Kivity commit ae544b92020577f556c5f7dd18e6a652f6f03a53 Author: Christian Ehrhardt Date: Tue Jan 8 08:04:50 2008 +0100 KVM: Portability: Move kvm_fpu to asm-x86/kvm.h This patch moves kvm_fpu asm-x86/kvm.h to allow every architecture to define an own representation used for KVM_GET_FPU/KVM_SET_FPU. Signed-off-by: Christian Ehrhardt Acked-by: Carsten Otte Acked-by: Zhang Xiantao Signed-off-by: Avi Kivity commit 4ce97c46387e0ea72dfe0b52fd63345f2805a785 Author: Dong, Eddie Date: Mon Jan 7 13:20:25 2008 +0200 KVM: MMU: Simplify hash table indexing Signed-off-by: Yaozu (Eddie) Dong Signed-off-by: Avi Kivity commit 94ed639ccce45f3233d30c84a2b136736e0e216b Author: Dong, Eddie Date: Mon Jan 7 11:14:20 2008 +0200 KVM: MMU: Update shadow ptes on partial guest pte writes A guest partial guest pte write will leave shadow_trap_nonpresent_pte in spte, which generates a vmexit at the next guest access through that pte. This patch improves this by reading the full guest pte in advance and thus being able to update the spte and eliminate the vmexit. This helps pae guests which use two 32-bit writes to set a single 64-bit pte. Signed-off-by: Yaozu (Eddie) Dong Signed-off-by: Avi Kivity commit 5ed49953ef3749de1198bc07cdf11339d8f74432 Author: Sheng Yang Date: Wed Jan 2 14:49:22 2008 +0800 KVM: x86 emulator: Only allow VMCALL/VMMCALL trapped by #UD When executing a test program called "crashme", we found the KVM guest cannot survive more than ten seconds, then encounterd kernel panic. The basic concept of "crashme" is generating random assembly code and trying to execute it. After some fixes on emulator insn validity judgment, we found it's hard to get the current emulator handle the invalid instructions correctly, for the #UD trap for hypercall patching caused troubles. The problem is, if the opcode itself was OK, but combination of opcode and modrm_reg was invalid, and one operand of the opcode was memory (SrcMem or DstMem), the emulator will fetch the memory operand first rather than checking the validity, and may encounter an error there. For example, ".byte 0xfe, 0x34, 0xcd" has this problem. In the patch, we simply check that if the invalid opcode wasn't vmcall/vmmcall, then return from emulate_instruction() and inject a #UD to guest. With the patch, the guest had been running for more than 12 hours. Signed-off-by: Feng (Eric) Liu Signed-off-by: Sheng Yang Signed-off-by: Avi Kivity commit 749e8e0460335f6699984cd7ba041320a9ba3c56 Author: Avi Kivity Date: Thu Jan 3 18:30:30 2008 +0200 KVM: Mark vapic page as dirty for save/restore/migrate Signed-off-by: Avi Kivity commit e7706133a12f0172b1a5ce4467277abd598155b6 Author: Dong, Eddie Date: Wed Jan 2 14:29:08 2008 +0800 KVM: MMU: Merge shadow level check in FNAME(fetch) Remove the redundant level check when fetching shadow pte for present & non-present spte. Signed-off-by: Yaozu (Eddie) Dong Signed-off-by: Avi Kivity commit 91051a4955255317cab0d09d8849ec12db85f924 Author: Avi Kivity Date: Tue Jan 1 14:19:48 2008 +0200 KVM: Fix unbalanced mmap_sem operations in cmpxchg8b emulation Signed-off-by: Avi Kivity commit dcfbe05b0a370341c2ef72ee314eacfb924b6de6 Author: Avi Kivity Date: Tue Jan 1 14:19:00 2008 +0200 KVM: MMU: Fix recursive locking of mmap_sem() Can cause nasty deadlocks. Signed-off-by: Avi Kivity commit a089279c866ddf3a69c4fa13fb9935b143853f97 Author: Avi Kivity Date: Mon Dec 31 17:10:22 2007 +0200 KVM: MMU: Broaden scope of mmap_sem to include actual mapping Signed-off-by: Avi Kivity commit 91f0ad972111addf2d694b1f2237e5eae72ca454 Author: Avi Kivity Date: Mon Dec 31 15:27:49 2007 +0200 KVM: MMU: Move kvm_free_some_pages() into critical section If some other cpu steals mmu pages between our check and an attempt to allocate, we can run out of mmu pages. Fix by moving the check into the same critical section as the allocation. Signed-off-by: Avi Kivity commit 03f6646f123b7afa1dc8595a6dc96f01d71c765b Author: Marcelo Tosatti Date: Thu Dec 20 19:18:26 2007 -0500 KVM: MMU: Switch to mmu spinlock Convert the synchronization of the shadow handling to a separate mmu_lock spinlock. Also guard fetch() by mmap_sem in read-mode to protect against alias and memslot changes. Signed-off-by: Marcelo Tosatti Signed-off-by: Avi Kivity commit 6e44a9063005c435bf62da3bf3c131ed4e54bced Author: Avi Kivity Date: Sun Dec 30 12:29:05 2007 +0200 KVM: MMU: Avoid calling gfn_to_page() in mmu_set_spte() Since gfn_to_page() is a sleeping function, and we want to make the core mmu spinlocked, we need to pass the page from the walker context (which can sleep) to the shadow context (which cannot). [marcelo: avoid recursive locking of mmap_sem] Signed-off-by: Avi Kivity commit a23041c096c4c024351bc1f758807d66471b283f Author: Marcelo Tosatti Date: Thu Dec 20 19:18:23 2007 -0500 KVM: Add kvm_read_guest_atomic() In preparation for a mmu spinlock, add kvm_read_guest_atomic() and use it in fetch() and prefetch_page(). Signed-off-by: Marcelo Tosatti Signed-off-by: Avi Kivity commit 9bad222c14f721daa7e0bc2863cf62caaecf14e6 Author: Marcelo Tosatti Date: Thu Dec 20 19:18:22 2007 -0500 KVM: MMU: Concurrent guest walkers Do not hold kvm->lock mutex across the entire pagefault code, only acquire it in places where it is necessary, such as mmu hash list, active list, rmap and parent pte handling. Allow concurrent guest walkers by switching walk_addr() to use mmap_sem in read-mode. And get rid of the lockless __gfn_to_page. [avi: move kvm_mmu_pte_write() locking inside the function] [avi: add locking for real mode] Signed-off-by: Marcelo Tosatti Signed-off-by: Avi Kivity commit 1477b89f565e78edbcd5d195fb72ab4682f63b2a Author: Avi Kivity Date: Wed Dec 26 13:57:04 2007 +0200 KVM: Disable vapic support on Intel machines with FlexPriority FlexPriority accelerates the tpr without any patching. Signed-off-by: Avi Kivity commit 1d536bc26aec043a102f0fd02899985fd5f77653 Author: Avi Kivity Date: Thu Oct 25 16:52:32 2007 +0200 KVM: Accelerated apic support This adds a mechanism for exposing the virtual apic tpr to the guest, and a protocol for letting the guest update the tpr without causing a vmexit if conditions allow (e.g. there is no interrupt pending with a higher priority than the new tpr). Signed-off-by: Avi Kivity commit b7a5f24a96a5501f59caa165428a928ee2652af6 Author: Avi Kivity Date: Mon Oct 22 16:50:39 2007 +0200 KVM: local APIC TPR access reporting facility Add a facility to report on accesses to the local apic tpr even if the local apic is emulated in the kernel. This is basically a hack that allows userspace to patch Windows which tends to bang on the tpr a lot. Signed-off-by: Avi Kivity commit 7885a4fbebcbae1f8594445a46aefb9d97353594 Author: Izik Eidus Date: Thu Dec 20 10:41:39 2007 +0200 KVM: Ensure pages are copied on write Fix userspace memory handling bug related to cow the previous way we called get_user_pages, was without the force flag and therefore it didnt break COW shared pages. This caused host memory corruption when host userspace fork()ed. Signed-off-by: Izik Eidus Signed-off-by: Avi Kivity commit 567f9bfa0a7461945dcd6a50d0b3efb44714400d Author: Avi Kivity Date: Wed Dec 19 12:02:40 2007 +0200 KVM: Print data for unimplemented wrmsr This can help diagnosing what the guest is trying to do. In many cases we can get away with partial emulation of msrs. Signed-off-by: Avi Kivity commit ed918da99a1377481cf8d40b75b2cbb35b802f3e Author: Avi Kivity Date: Tue Dec 18 19:47:18 2007 +0200 KVM: MMU: Add cache miss statistic Signed-off-by: Avi Kivity commit 0350cb07b74834bce356d0a819be2b239b94d080 Author: Eddie Dong Date: Tue Dec 18 06:08:27 2007 +0800 KVM: MMU: Coalesce remote tlb flushes Host side TLB flush can be merged together if multiple spte need to be write-protected. Signed-off-by: Yaozu (Eddie) Dong Signed-off-by: Avi Kivity commit 4d95c0f3eea3b89221f3b35a7e01119973ae7190 Author: Zhang Xiantao Date: Mon Dec 17 20:27:27 2007 +0800 KVM: Expose ioapic to ia64 save/restore APIs IA64 also needs to see ioapic structure in irqchip. Signed-off-by: xiantao.zhang@intel.com Signed-off-by: Avi Kivity commit 2042dde72d5f8663237efb5e8a2797ba9e1c42e4 Author: Zhang Xiantao Date: Mon Dec 17 14:21:40 2007 +0800 KVM: Move kvm_vcpu_kick() to x86.c Moving kvm_vcpu_kick() to x86.c. Since it should be common for all archs, put its declarations in Signed-off-by: Zhang Xiantao Signed-off-by: Avi Kivity commit 50d50e54371d313a8bb1827a05ccca41ab6761aa Author: Zhang Xiantao Date: Mon Dec 17 14:16:14 2007 +0800 KVM: Move ioapic code to common directory. Move ioapic code to common, since IA64 also needs it. Signed-off-by: Zhang Xiantao Signed-off-by: Avi Kivity commit d924af23f843578480c35d6e2dd7cf61f63187b2 Author: Zhang Xiantao Date: Mon Dec 17 13:59:56 2007 +0800 KVM: Move irqchip declarations into new ioapic.h and lapic.h This allows reuse of ioapic in ia64. Signed-off-by: Zhang Xiantao Signed-off-by: Avi Kivity commit c366747d21ea71d89f32b530037285f7bbfabaa3 Author: Avi Kivity Date: Sun Dec 16 11:13:16 2007 +0200 KVM: Move drivers/kvm/* to virt/kvm/ Signed-off-by: Avi Kivity commit 85c6290a3c5345016358e4e604fba470a62fc392 Author: Avi Kivity Date: Sun Dec 16 11:02:48 2007 +0200 KVM: Move arch dependent files to new directory arch/x86/kvm/ This paves the way for multiple architecture support. Note that while ioapic.c could potentially be shared with ia64, it is also moved. Signed-off-by: Avi Kivity commit a3848478c4b265d6b9789a891cefc8dce4ed9c69 Author: Ryan Harper Date: Thu Dec 13 10:21:10 2007 -0600 KVM: VMX: Add printk_ratelimit in vmx_intr_assist Add printk_ratelimit check in front of printk. This prevents spamming of the message during 32-bit ubuntu 6.06server install. Previously, it would hang during the partition formatting stage. Signed-off-by: Ryan Harper Signed-off-by: Avi Kivity commit 58bb8349b808e2ac08bf9aa0580330bcb461e696 Author: Zhang Xiantao Date: Fri Dec 14 10:23:23 2007 +0800 KVM: Portability: Move kvm_vm_stat to x86.h This patch moves kvm_vm_stat to x86.h, and every arch can define its own kvm_vm_stat in $arch.h Signed-off-by: Zhang Xiantao Acked-by: Carsten Otte Signed-off-by: Avi Kivity commit f51835e0d03b8cd97eaad80dece87e32f7896ed6 Author: Zhang Xiantao Date: Fri Dec 14 10:20:16 2007 +0800 KVM: Portability: Move round_robin_prev_vcpu and tss_addr to kvm_arch This patches moves two fields round_robin_prev_vcpu and tss to kvm_arch. Signed-off-by: Zhang Xiantao Acked-by: Carsten Otte Signed-off-by: Avi Kivity commit 024c0d7cd4348dcb412e4b49a4dc3bcdbb46bb5d Author: Zhang Xiantao Date: Fri Dec 14 10:17:34 2007 +0800 KVM: Portability: move vpic and vioapic to kvm_arch This patches moves two fields vpid and vioapic to kvm_arch Signed-off-by: Zhang Xiantao Acked-by: Carsten Otte Signed-off-by: Avi Kivity commit 6a021262861ac4957bc6f558a7221e5127cd4cf7 Author: Zhang Xiantao Date: Fri Dec 14 10:01:48 2007 +0800 KVM: Portability: Move mmu-related fields to kvm_arch This patches moves mmu-related fields to kvm_arch. Signed-off-by: Zhang Xiantao Acked-by: Carsten Otte Signed-off-by: Avi Kivity commit 06087dc10debe5a74eaf7a6a37464c504973dd45 Author: Zhang Xiantao Date: Fri Dec 14 09:54:20 2007 +0800 KVM: Portability: Move memslot aliases to new struct kvm_arch This patches create kvm_arch to hold arch-specific kvm fileds and moves fields naliases and aliases to kvm_arch. Signed-off-by: Zhang Xiantao Acked-by: Carsten Otte Signed-off-by: Avi Kivity commit c63eee73881d2db2ee7d2255dc2a0350d528e594 Author: Zhang Xiantao Date: Fri Dec 14 09:49:26 2007 +0800 KVM: Portability: Move kvm_vcpu_stat to x86.h This patches moves kvm_vcpu_stat to x86.h, so every arch can define its own kvm_vcpu_stat structure. Signed-off-by: Zhang Xiantao Acked-by: Carsten Otte Signed-off-by: Avi Kivity commit 6ed5f1928c66462ba81da72defb3d705feb73a86 Author: Zhang Xiantao Date: Fri Dec 14 09:45:31 2007 +0800 KVM: Portability: Expand the KVM_VCPU_COMM in kvm_vcpu structure. This patches removes KVM_COMM macro, original it is hold kvm_vcpu common fields. Signed-off-by: Zhang Xiantao Acked-by: Carsten Otte Signed-off-by: Avi Kivity commit f6f92b4c782102cb0162613902b1513f9e7adf3f Author: Zhang Xiantao Date: Fri Dec 14 09:41:22 2007 +0800 KVM: Portability: Move kvm_vcpu definition back to kvm.h This patches moves kvm_vcpu definition to kvm.h, and finally kvm.h includes x86.h. Signed-off-by: Zhang Xiantao Acked-by: Carsten Otte Signed-off-by: Avi Kivity commit b560069d516402f8cfc6c7f003454956953bcfb5 Author: Zhang Xiantao Date: Fri Dec 14 09:35:10 2007 +0800 KVM: Portability: Split mmu-related static inline functions to mmu.h Since these functions need to know the details of kvm or kvm_vcpu structure, it can't be put in x86.h. Create mmu.h to hold them. Signed-off-by: Zhang Xiantao Acked-by: Carsten Otte Signed-off-by: Avi Kivity commit f7888ffeef8ee06ef16c665733cd5f324056f014 Author: Zhang Xiantao Date: Thu Dec 13 23:50:52 2007 +0800 KVM: Portability: Introduce kvm_vcpu_arch Move all the architecture-specific fields in kvm_vcpu into a new struct kvm_vcpu_arch. Signed-off-by: Zhang Xiantao Acked-by: Carsten Otte Signed-off-by: Avi Kivity commit a0ef3bd9b3bfb21400b8109db5423c6610145dfe Author: Zhang Xiantao Date: Tue Dec 11 20:36:00 2007 +0800 KVM: Portability: Move kvm{pic,ioapic} accesors to x86 specific code Signed-off-by: Zhang Xiantao Signed-off-by: Avi Kivity commit 0d2480f47ae5c357049eb7a49b48fe9ee5b05953 Author: Marcelo Tosatti Date: Wed Dec 12 10:46:12 2007 -0500 KVM: MMU: emulated cmpxchg8b should be atomic on i386 Emulate cmpxchg8b atomically on i386. This is required to avoid a guest pte walker from seeing a splitted write. [avi: make it compile] Signed-off-by: Marcelo Tosatti Signed-off-by: Avi Kivity commit cd8f3145348de3087607195cd221780f5da4f030 Author: Joerg Roedel Date: Tue Dec 11 15:36:57 2007 +0100 KVM: SVM: support writing 0 to K8 performance counter control registers This lets SVM ignore writes of the value 0 to the performance counter control registers. Thus enabling them will still fail in the guest, but a write of 0 which keeps them disabled is accepted. This is required to boot Windows Vista 64bit. [avi: avoid fall-thru in switch statement] Signed-off-by: Joerg Roedel Signed-off-by: Markus Rechberger Signed-off-by: Avi Kivity commit a30c90b493eec3e118d95e8057776b1c34bd9da8 Author: Joerg Roedel Date: Wed Dec 12 12:37:24 2007 +0100 KVM: LAPIC: minor debugging compile fix This patch fixes a compile error of the LAPIC code with APIC debugging enabled. Signed-off-by: Joerg Roedel Signed-off-by: Markus Rechberger Signed-off-by: Avi Kivity commit 58a96eecc801a6570264d5c66d26531d82470c33 Author: Marcelo Tosatti Date: Tue Dec 11 19:12:27 2007 -0500 KVM: MMU: Fix SMP shadow instantiation race There is a race where VCPU0 is shadowing a pagetable entry while VCPU1 is updating it, which results in a stale shadow copy. Fix that by comparing the contents of the cached guest pte with the current guest pte after write-protecting the guest pagetable. Signed-off-by: Marcelo Tosatti Signed-off-by: Avi Kivity commit 957ff6b0d9822fd24b294b0e2a66b6a48135b269 Author: Joerg Roedel Date: Thu Dec 6 21:02:25 2007 +0100 KVM: SVM: Exit to userspace if write to cr8 and not using in-kernel apic With this patch KVM on SVM will exit to userspace if the guest writes to CR8 and the in-kernel APIC is disabled. Signed-off-by: Joerg Roedel Signed-off-by: Markus Rechberger Signed-off-by: Avi Kivity commit 0210661321f78f69f98c593625f18a9ea686fdc1 Author: Avi Kivity Date: Sun Dec 9 18:43:00 2007 +0200 KVM: MMU: Use mmu_set_spte() for real-mode shadows In addition to removing some duplicated code, this also handles the unlikely case of real-mode code updating a guest page table. This can happen when one vcpu (in real mode) touches a second vcpu's (in protected mode) page tables, or if a vcpu switches to real mode, touches page tables, and switches back. Signed-off-by: Avi Kivity commit be3aea0724666dcfd0b9b4c7a571a7f1fb2e0357 Author: Avi Kivity Date: Sun Dec 9 18:39:41 2007 +0200 KVM: MMU: Adjust mmu_set_spte() debug code for gpte removal Signed-off-by: Avi Kivity commit 8c88b9de814d698c0b4ae37fea84bd32b70f786b Author: Avi Kivity Date: Sun Dec 9 17:40:31 2007 +0200 KVM: MMU: Move set_pte() into guest paging mode independent code As set_pte() no longer references either a gpte or the guest walker, we can move it out of paging mode dependent code (which compiles twice and is generally nasty). Signed-off-by: Avi Kivity commit dc9f6110cf35805ed4e8c0a95c1be267c907e884 Author: Avi Kivity Date: Sun Dec 9 17:33:46 2007 +0200 KVM: MMU: Remove walker argument to set_pte() Unused. Signed-off-by: Avi Kivity commit 33e0e3a2d4920eb2dce19c1e1a796ff6e0762457 Author: Avi Kivity Date: Sun Dec 9 17:32:30 2007 +0200 KVM: MMU: Pass pte dirty flag to set_pte() instead of calculating it on-site This allows us to remove its dependency on pt_element_t. Signed-off-by: Avi Kivity commit ea8dea713f57429db7ff2fc647f1dd3c479a1498 Author: Avi Kivity Date: Sun Dec 9 17:27:52 2007 +0200 KVM: MMU: No need to pick up nx bit from guest pte We already set it according to cumulative access permissions. Signed-off-by: Avi Kivity commit aab175e49c49324310d7223be9a78ab2c199e74f Author: Avi Kivity Date: Sun Dec 9 17:00:02 2007 +0200 KVM: MMU: Fix inherited permissions for emulated guest pte updates When we emulate a guest pte write, we fail to apply the correct inherited permissions from the parent ptes. Now that we store inherited permissions in the shadow page, we can use that to update the pte permissions correctly. Signed-off-by: Avi Kivity commit 36f96df050f80f2632cfb6b4732d839a7977113a Author: Avi Kivity Date: Sun Dec 9 16:52:56 2007 +0200 KVM: MMU: Move pte access calculation into a helper function Signed-off-by: Avi Kivity commit 2472c041e66c73c9ad754f6b8d19c7fba374cb27 Author: Avi Kivity Date: Sun Dec 9 16:37:36 2007 +0200 KVM: MMU: Set nx bit correctly on shadow ptes While the page table walker correctly generates a guest page fault if a guest tries to execute a non-executable page, the shadow code does not mark it non-executable. This means that if a guest accesses an nx page first with a read access, then subsequent code fetch accesses will succeed. Fix by setting the nx bit on shadow ptes. Signed-off-by: Avi Kivity commit c05635b462e90c381420667cffd025bcc87a081f Author: Avi Kivity Date: Sun Dec 9 16:15:46 2007 +0200 KVM: MMU: Simplify calculation of pte access The nx bit is awkwardly placed in the 63rd bit position; furthermore it has a reversed meaning compared to the other bits, which means we can't use a bitwise and to calculate compounded access masks. So, we simplify things by creating a new 3-bit exec/write/user access word, and doing all calculations in that. Signed-off-by: Avi Kivity commit eab1de2b85dcbc23f9fe7332623dffbbf6ddb419 Author: Marcelo Tosatti Date: Fri Dec 7 07:56:58 2007 -0500 KVM: MMU: Use cmpxchg for pte updates on walk_addr() In preparation for multi-threaded guest pte walking, use cmpxchg() when updating guest pte's. This guarantees that the assignment of the dirty bit can't be lost if two CPU's are faulting the same address simultaneously. [avi: fix kunmap_atomic() parameters] Signed-off-by: Marcelo Tosatti Signed-off-by: Avi Kivity commit e3366a8a9cf43bc6a6f1d5b473cb6e58e80b7d5e Author: Avi Kivity Date: Thu Dec 6 21:11:31 2007 +0200 KVM: VMX: Fix cr8 exit optimization Signed-off-by: Avi Kivity commit 620208ae8864882e4e5dd7f1b5996820caa575a6 Author: Avi Kivity Date: Thu Dec 6 19:50:00 2007 +0200 KVM: SVM: Trap access to the cr8 register Later we may be able to use the virtual tpr feature, but for now, just trap it. Signed-off-by: Avi Kivity commit c1185a68804451d912719e9b03716a909aeef6bc Author: Avi Kivity Date: Thu Dec 6 18:14:14 2007 +0200 KVM: x86 emulator: Fix stack instructions on 64-bit mode Stack instructions are always 64-bit on 64-bit mode; many of the emulated stack instructions did not take that into account. Fix by adding a 'Stack' bitflag and setting the operand size appropriately during the decode stage (except for 'push r/m', which is in a group with a few other instructions, so it gets its own treatment). This fixes random crashes on Vista x64. Signed-off-by: Avi Kivity commit 495fdd4724fca0ccb0915816aefe693dd02fd034 Author: Joerg Roedel Date: Thu Dec 6 15:46:52 2007 +0100 KVM: SVM: Emulate read/write access to cr8 This patch adds code to emulate the access to the cr8 register to the x86 instruction emulator in kvm. This is needed on svm, where there is no hardware decode for control register access. Signed-off-by: Joerg Roedel Signed-off-by: Markus Rechberger Signed-off-by: Avi Kivity commit 1a306332c4e88c8eaa6bb26a23965864e6e78bbb Author: Avi Kivity Date: Thu Dec 6 16:32:45 2007 +0200 KVM: VMX: Avoid exit when setting cr8 if the local apic is in the kernel With apic in userspace, we must exit to userspace after a cr8 write in order to update the tpr. But if the apic is in the kernel, the exit is unnecessary. Noticed by Joerg Roedel. Signed-off-by: Avi Kivity commit 1b15a0f3cc6c9ca6bfb6fe468156ed3603092878 Author: Avi Kivity Date: Thu Dec 6 16:15:02 2007 +0200 KVM: x86 emulator: fix eflags preparation for emulation We prepare eflags for the emulated instruction, then clobber it with an 'andl'. Fix by popping eflags as the last thing in the sequence. Patch taken from Xen (16143:959b4b92b6bf) Signed-off-by: Avi Kivity commit a95acbf60ba74e82ffa450a3c1de314ed10ea52d Author: Avi Kivity Date: Sun Nov 25 15:22:50 2007 +0200 KVM: Use generalized exception queue for injecting #UD Signed-off-by: Avi Kivity commit 7826d5f9510b29eac2fda1f16a410d85cda28c57 Author: Avi Kivity Date: Sun Nov 25 14:12:03 2007 +0200 KVM: Replace #GP injection by the generalized exception queue Signed-off-by: Avi Kivity commit 508945960872689acee683c2baec87b00d6af788 Author: Avi Kivity Date: Sun Nov 25 14:04:58 2007 +0200 KVM: Replace page fault injection by the generalized exception queue Signed-off-by: Avi Kivity commit 9baf60dafabd46151b1be0ca9b787300a14870cd Author: Avi Kivity Date: Sun Nov 25 13:41:11 2007 +0200 KVM: Generalize exception injection mechanism Instead of each subarch doing its own thing, add an API for queuing an injection, and manage failed exception injection centerally (i.e., if an inject failed due to a shadow page fault, we need to requeue it). Signed-off-by: Avi Kivity commit 0132b078ce22386d7a42714e2dde2c712a5c4207 Author: Marcelo Tosatti Date: Tue Dec 4 13:42:16 2007 -0500 KVM: MMU: Remove unused prev_shadow_ent variable from fetch() Signed-off-by: Marcelo Tosatti Signed-off-by: Avi Kivity commit 312aaca14f07c92fc3d04825968b2cd7122d0508 Author: npiggin@suse.de Date: Wed Dec 5 18:15:52 2007 +1100 KVM: Convert KVM from ->nopage() to ->fault() Signed-off-by: Nick Piggin Cc: kvm-devel@lists.sourceforge.net Cc: avi@qumranet.com Cc: linux-kernel@vger.kernel.org Signed-off-by: Avi Kivity commit c4b2fe88ab89aa9a3d6d6248751806073c61ee22 Author: Hollis Blanchard Date: Mon Dec 3 16:15:26 2007 -0600 KVM: Portability: Create kvm_arch_vcpu_runnable() function This abstracts the detail of x86 hlt and INIT modes into a function. Signed-off-by: Hollis Blanchard Acked-by: Carsten Otte Signed-off-by: Avi Kivity commit d32f10db9060b2f5ba643008d70ea3e2604557f0 Author: Hollis Blanchard Date: Mon Dec 3 15:30:25 2007 -0600 KVM: Portability: Stop including x86-specific headers in kvm_main.c Signed-off-by: Hollis Blanchard Signed-off-by: Avi Kivity commit 5059097a8f86bc0a4e63451e9a4bd390bd5840b3 Author: Hollis Blanchard Date: Mon Dec 3 15:30:24 2007 -0600 KVM: Portability: Move IO device definitions to its own header file Signed-off-by: Hollis Blanchard Acked-by: Carsten Otte Signed-off-by: Avi Kivity commit c2aa443f394d90ab3b7b1e4236a1bf0dd070d41e Author: Hollis Blanchard Date: Mon Dec 3 15:30:23 2007 -0600 KVM: Portability: Move address types to their own header file Signed-off-by: Hollis Blanchard Acked-by: Carsten Otte Signed-off-by: Avi Kivity commit 6d1d70bb6121e10a84c394fd29af320e8625f0d6 Author: Zhang Xiantao Date: Sun Dec 2 22:53:07 2007 +0800 KVM: Extend ioapic code to support iosapic iosapic supports an additional mmio EOI register compared to ioapic. Signed-off-by: Zhang Xiantao Signed-off-by: Avi Kivity commit 11f4471ed4f5438439e041cbf66c7ed07d62cfa2 Author: Zhang Xiantao Date: Sun Dec 2 22:49:09 2007 +0800 KVM: Replace dest_Lowest_Prio and dest_Fixed with self-defined macros Change dest_Loest_Prio -> IOAPIC_LOWEST_PRIORITY dest_Fixed -> IOAPIC_FIXED the original names are x86 specific, while the ioapic code will be reused for ia64. Signed-off-by: Zhang Xiantao Signed-off-by: Avi Kivity commit b627248e01ab212ecfdab822248b24db6e93e5ae Author: Zhang Xiantao Date: Sun Dec 2 22:35:57 2007 +0800 KVM: Replace kvm_lapic with kvm_vcpu in ioapic/lapic interface This patch replaces lapic structure with kvm_vcpu in ioapic.c, making ioapic independent of the local apic, as required by ia64. Signed-off-by: Zhang Xiantao Signed-off-by: Avi Kivity commit a5d72858e076d865223900ddce084ab04a2907f9 Author: Carlo Marcelo Arenas Belon Date: Sat Dec 1 06:17:11 2007 -0600 KVM: SVM: Remove KVM specific defines for MSR_EFER This patch removes the KVM specific defines for MSR_EFER that were being used in the svm support file and migrates all references to use instead the ones from the kernel headers that are used everywhere else and that have the same values. Signed-off-by: Carlo Marcelo Arenas Belon Signed-off-by: Avi Kivity commit 30f68f12b371e4105897fe2f2acbaaab667e8293 Author: Avi Kivity Date: Sun Dec 2 10:50:06 2007 +0200 KVM: Export include/linux/kvm.h only if $ARCH actually supports KVM Currently, make headers_check barfs due to , which includes, not existing. Rather than add a zillion s, export kvm.h only if the arch actually supports it. Signed-off-by: Avi Kivity commit 248b1cea3a9ed4e997409dbc0d0397cc601eeb28 Author: Zhang Xiantao Date: Thu Nov 29 15:35:39 2007 +0800 KVM: Correct kvm_init() error paths not freeing bad_pge. Signed-off-by: Zhang Xiantao Signed-off-by: Avi Kivity commit 872b5d79d10518f90814ea8de95e5b4a2ef678cd Author: Zhang Xiantao Date: Wed Nov 21 04:36:41 2007 +0800 KVM: Portability: Move KVM_INTERRUPT vcpu ioctl to x86.c Other archs doesn't need it. Signed-off-by: Zhang Xiantao Signed-off-by: Avi Kivity commit 8f13a26579abdae8fc09bfaaeb778d5c66383648 Author: Avi Kivity Date: Tue Nov 27 19:30:56 2007 +0200 KVM: x86 emulator: unify four switch statements into two Unify the special instruction switch with the regular instruction switch, and the two byte special instruction switch with the regular two byte instruction switch. That makes it much easier to find an instruction or the place an instruction needs to be added in. Signed-off-by: Avi Kivity commit 52fb6a8bbfd208976296ec1c42ecf3c707df6693 Author: Avi Kivity Date: Tue Nov 27 19:14:21 2007 +0200 KVM: x86 emulator: unify two switches The rep prefix cleanup left two switch () statements next to each other. Unify them. Signed-off-by: Avi Kivity commit 9c4da7ae8602d4a3c6558efcb1a5f5d0c1aedae3 Author: Avi Kivity Date: Tue Nov 27 19:05:37 2007 +0200 KVM: x86 emulator: Move rep processing before instruction execution Currently rep processing is handled somewhere in the middle of instruction processing. Move it to a sensible place. Signed-off-by: Avi Kivity commit 334df02ff6c75a9a740838fbacebc9c590587617 Author: Avi Kivity Date: Mon Nov 26 18:30:07 2007 +0200 KVM: Fix cpuid2 killing 32-bit guests on non-NX machines KVM_SET_CPUID fails to remove NX when the host doesn't support it, as previous versions do. On the other hand, KVM_SET_CPUID2 removes the feature even though, since we tell userspace about it, it shouldn't be necessary. Swap the two cases. Signed-off-by: Avi Kivity commit 04546994156d8cee5417bd6a9b180476a405c20d Author: Jerone Young Date: Mon Nov 26 08:33:53 2007 -0600 KVM: Add ifdef in irqchip struct for x86 only structures This patch fixes a small issue where sturctures: kvm_pic_state kvm_ioapic_state are defined inside x86 specific code and may or may not be defined in anyway for other architectures. The problem caused is one cannot compile userspace apps (ex. libkvm) for other archs since a size cannot be determined for these structures. Signed-off-by: Jerone Young Signed-off-by: Avi Kivity commit ce63e51b866391404de2b7361146355b731ee5fb Author: Guillaume Thouvenin Date: Mon Nov 26 13:49:09 2007 +0100 KVM: x86 emulator: cmps instruction Add emulation for the cmps instruction. This lets OpenBSD boot on kvm. Signed-off-by: Guillaume Thouvenin Signed-off-by: Avi Kivity commit b961c7a777e68aa16e26b415b93fdb3ad74743a7 Author: Sheng Yang Date: Fri Nov 16 16:29:15 2007 +0800 KVM: x86 emulator: Rename 'cr2' to 'memop' Previous patches have removed the dependency on cr2; we can now stop passing it to the emulator and rename uses to 'memop'. Signed-off-by: Sheng Yang Signed-off-by: Avi Kivity commit a90bcadc507d1507a6ad29ef87a22f311e542fb2 Author: Avi Kivity Date: Mon Nov 26 16:10:43 2007 +0200 KVM: x86 emulator: rename REP_REPE_PREFIX Signed-off-by: Avi Kivity commit fb90cbc3977a94bbd2b4e496de7afd3ce6d977d7 Author: Izik Eidus Date: Mon Nov 26 14:08:14 2007 +0200 KVM: MMU: mark pages that were inserted to the shadow pages table as accessed Mark guest pages as accessed when removed from the shadow page tables for better lru processing. Signed-off-by: Izik Eidus Signed-off-by: Avi Kivity commit d0cf28925a13945072ec05574d7b94f9fb95984e Author: Avi Kivity Date: Sun Nov 25 17:45:31 2007 +0200 KVM: Remove misleading check for mmio during event injection mmio was already handled in kvm_arch_vcpu_ioctl_run(), so no need to check again. Signed-off-by: Avi Kivity commit f77171a55097f13656aea7ea7dfbc84c2afff918 Author: Avi Kivity Date: Thu Nov 22 14:16:12 2007 +0200 KVM: x86 emulator: address size and operand size overrides are sticky Current implementation is to toggle, which is incorrect. Patch ported from corresponding Xen code. Signed-off-by: Avi Kivity commit c8ba048f1a82c79276ef9146140bd5ed0dd6cd85 Author: Guillaume Thouvenin Date: Thu Nov 22 11:32:09 2007 +0100 KVM: x86 emulator: Make a distinction between repeat prefixes F3 and F2 cmps and scas instructions accept repeat prefixes F3 and F2. So in order to emulate those prefixed instructions we need to be able to know if prefixes are REP/REPE/REPZ or REPNE/REPNZ. Currently kvm doesn't make this distinction. This patch introduces this distinction. Signed-off-by: Guillaume Thouvenin Signed-off-by: Avi Kivity commit 97cf6a86e25f3cdf1f61a55e659d2e3df1c5ff8e Author: Zhang Xiantao Date: Thu Nov 22 11:20:33 2007 +0800 KVM: Portability: Move unalias_gfn to arch dependent file Non-x86 archs don't need this mechanism. Move it to arch, and keep its interface in common. Signed-off-by: Zhang Xiantao Acked-by: Carsten Otte Signed-off-by: Avi Kivity commit f442770e25f19e17a39f715dbd4328d77b68b2f7 Author: Sheng Yang Date: Wed Nov 21 14:33:25 2007 +0800 KVM: VMX: Remove the secondary execute control dependency on irqchip The state of SECONDARY_VM_EXEC_CONTROL shouldn't depend on in-kernel IRQ chip, this patch fix this. Signed-off-by: Sheng Yang Signed-off-by: Avi Kivity commit a140b2cc4877b204c2e1548e6b66a9903813ac14 Author: Dan Kenigsberg Date: Wed Nov 21 17:10:04 2007 +0200 KVM: Enhance guest cpuid management The current cpuid management suffers from several problems, which inhibit passing through the host feature set to the guest: - No way to tell which features the host supports While some features can be supported with no changes to kvm, others need explicit support. That means kvm needs to vet the feature set before it is passed to the guest. - No support for indexed or stateful cpuid entries Some cpuid entries depend on ecx as well as on eax, or on internal state in the processor (running cpuid multiple times with the same input returns different output). The current cpuid machinery only supports keying on eax. - No support for save/restore/migrate The internal state above needs to be exposed to userspace so it can be saved or migrated. This patch adds extended cpuid support by means of three new ioctls: - KVM_GET_SUPPORTED_CPUID: get all cpuid entries the host (and kvm) supports - KVM_SET_CPUID2: sets the vcpu's cpuid table - KVM_GET_CPUID2: gets the vcpu's cpuid table, including hidden state Signed-off-by: Dan Kenigsberg Signed-off-by: Avi Kivity commit 1a4c6de93b1c39030475a61d02e4df7f74f51e37 Author: Avi Kivity Date: Wed Nov 21 16:41:05 2007 +0200 KVM: Disallow fork() and similar games when using a VM We don't want the meaning of guest userspace changing under our feet. Signed-off-by: Avi Kivity commit 718e1c897684f1362ce7c8a9b209e7e2c78e4c4c Author: Avi Kivity Date: Wed Nov 21 15:32:41 2007 +0200 KVM: MMU: Rename 'release_page' Rename the awkwardly named variable. Signed-off-by: Avi Kivity commit fb3dc55a5bdadd47a293c46620bef3032ff48426 Author: Avi Kivity Date: Wed Nov 21 15:28:32 2007 +0200 KVM: MMU: Rename variables of type 'struct kvm_mmu_page *' These are traditionally named 'page', but even more traditionally, that name is reserved for variables that point to a 'struct page'. Rename them to 'sp' (for "shadow page"). Signed-off-by: Avi Kivity commit f02512044420fe8e91f3cb0e2e56f189e74066a9 Author: Avi Kivity Date: Wed Nov 21 15:01:44 2007 +0200 KVM: Remove gpa_to_hpa() Converting last uses along the way. Signed-off-by: Avi Kivity commit 8aac4447a875e1f11d3543c039f09f825a4fa359 Author: Avi Kivity Date: Wed Nov 21 14:57:44 2007 +0200 KVM: MMU: Remove gva_to_hpa() No longer used. Signed-off-by: Avi Kivity commit f1ce9a1d9c1ea0f68c6b894c992d633207b664ea Author: Avi Kivity Date: Wed Nov 21 14:54:16 2007 +0200 KVM: MMU: Simplify nonpaging_map() Instead of passing an hpa, pass a regular struct page. Signed-off-by: Avi Kivity commit b57925a773d4fc2a88184f4b31eb7aae4d9b7e2c Author: Avi Kivity Date: Wed Nov 21 14:44:45 2007 +0200 KVM: MMU: Introduce gfn_to_gpa() Converting a frame number to an address is tricky since the data type changes size. Introduce a function to do it. This fixes an actual bug when accessing guest ptes. Signed-off-by: Avi Kivity commit 5c3cbf2d407a80644241e6af9fcca51b3ed0aa5c Author: Avi Kivity Date: Wed Nov 21 14:20:22 2007 +0200 KVM: MMU: Adjust page_header_update_slot() to accept a gfn instead of a gpa Signed-off-by: Avi Kivity commit ba8720265892f853b802198c47682bce89719f8c Author: Avi Kivity Date: Wed Nov 21 14:16:30 2007 +0200 KVM: MMU: Merge set_pte() and set_pte_common() Since set_pte() is now the only caller of set_pte_common(), merge the two functions. Signed-off-by: Avi Kivity commit 12879fd11c07ae060c5ec918eaf8cc5c5e0bf5c8 Author: Avi Kivity Date: Wed Nov 21 14:11:49 2007 +0200 KVM: MMU: Remove set_pde() It is now identical to set_pte(). Signed-off-by: Avi Kivity commit 98d462d22b18d9433ee40bb0e7b9bfc2a4839d55 Author: Avi Kivity Date: Wed Nov 21 14:08:40 2007 +0200 KVM: MMU: Remove extra gaddr parameter from set_pte_common() Similar information is available in the gfn parameter, so use that. Signed-off-by: Avi Kivity commit 194d7f3ad1e26815bfc1b934a73a4b74f9d5d018 Author: Avi Kivity Date: Wed Nov 21 13:54:47 2007 +0200 KVM: MMU: Move pse36 handling to the guest walker Signed-off-by: Avi Kivity commit 904b2b78058edc3abee7f0ea543ed107a580d6e7 Author: Avi Kivity Date: Wed Nov 21 12:35:07 2007 +0200 KVM: MMU: Introduce and use gpte_to_gfn() Instead of repretitively open-coding this. Signed-off-by: Avi Kivity commit b6b934f10416dc5e2ee59442b564264492885b25 Author: Izik Eidus Date: Tue Nov 20 12:02:12 2007 +0200 KVM: MMU: Code cleanup Signed-off-by: Izik Eidus Signed-off-by: Avi Kivity commit 481af46d479b09a0a56606af7efc6a0a9368a43d Author: Avi Kivity Date: Wed Nov 21 02:57:59 2007 +0200 KVM: Don't bother the mmu if cr3 load doesn't change cr3 If the guest requests just a tlb flush, don't take the vm lock and drop the mmu context pointlessly. Signed-off-by: Avi Kivity commit 9dd1731684fdfe4b07374b28c383e97c21ccd97a Author: Avi Kivity Date: Wed Nov 21 02:06:21 2007 +0200 KVM: MMU: Avoid unnecessary remote tlb flushes when guest updates a pte If all we're doing is increasing permissions on a pte (typical for demand paging), then there's not need to flush remote tlbs. Worst case they'll get a spurious page fault. Signed-off-by: Avi Kivity commit 1c6d0c2de6c8f5b57971d554215a5991bb948884 Author: Avi Kivity Date: Tue Nov 20 23:01:14 2007 +0200 KVM: Add statistic for remote tlb flushes Signed-off-by: Avi Kivity commit 772086964f8aa002f57f61044a336aac667386d3 Author: Avi Kivity Date: Tue Nov 20 21:39:54 2007 +0200 KVM: MMU: Implement guest page fault bypass for nonpae I spent an hour worrying why I see so many guest page faults on FC6 i386. Turns out bypass wasn't implemented for nonpae. Implement it so it doesn't happen again. Signed-off-by: Avi Kivity commit 91eb2376ace13756a5eb9068093bdaed1320e949 Author: Avi Kivity Date: Tue Nov 20 15:30:24 2007 +0200 KVM: Split vcpu creation to avoid vcpu_load() before preemption setup Split kvm_arch_vcpu_create() into kvm_arch_vcpu_create() and kvm_arch_vcpu_setup(), enabling preemption notification between the two. This mean that we can now do vcpu_load() within kvm_arch_vcpu_setup(). Signed-off-by: Avi Kivity commit 821afccb303e4a5761b9b07a1e599dd99feecfe1 Author: Zhang Xiantao Date: Tue Nov 20 16:25:04 2007 +0800 KVM: Portability: Split kvm_set_memory_region() to have an arch callout Moving !user_alloc case to kvm_arch to avoid unnecessary code logic in non-x86 platform. Signed-off-by: Zhang Xiantao Signed-off-by: Avi Kivity commit e2d8cbc6b4589ae4c06cad9dcc29a5da58a0d761 Author: Zhang Xiantao Date: Tue Nov 20 13:11:38 2007 +0800 KVM: Recalculate mmu pages needed for every memory region change Instead of incrementally changing the mmu cache size for every memory slot operation, recalculate it from scratch. This is simpler and safer. Signed-off-by: Zhang Xiantao Signed-off-by: Avi Kivity commit 8c62725b40aceb3d8004954d221215f8e1a4656f Author: Avi Kivity Date: Tue Nov 20 13:15:52 2007 +0200 KVM: x86 emulator: prefetch up to 15 bytes of the instruction executed Instead of fetching one byte at a time, prefetch 15 bytes (or until the next page boundary) to avoid guest page table walks. Signed-off-by: Avi Kivity commit 31c5dcecace6d0eed31d13e9d6e525a1d1b0d741 Author: Avi Kivity Date: Tue Nov 20 12:49:31 2007 +0200 KVM: x86 emulator: retire ->write_std() Theoretically used to acccess memory known to be ordinary RAM, it was never implemented. It is questionable whether it is possible to implement it correctly. Signed-off-by: Avi Kivity commit c4cfa3cad0a5b24d6c09daf2b9837d60191af177 Author: Izik Eidus Date: Tue Nov 20 11:49:33 2007 +0200 KVM: MMU: Selectively set PageDirty when releasing guest memory Improve dirty bit setting for pages that kvm release, until now every page that we released we marked dirty, from now only pages that have potential to get dirty we mark dirty. Signed-off-by: Izik Eidus Signed-off-by: Avi Kivity commit c68426d13b5ee3607b40c9eb4db55bd46448c315 Author: Izik Eidus Date: Tue Nov 20 11:30:04 2007 +0200 KVM: MMU: Fix potential memory leak with smp real-mode When we map a page, we check whether some other vcpu mapped it for us and if so, bail out. But we should decrease the refcount on the page as we do so. Signed-off-by: Izik Eidus Signed-off-by: Avi Kivity commit 9500583c5938b83134114f925f933813e8d0ee1a Author: Avi Kivity Date: Tue Nov 20 11:45:14 2007 +0200 KVM: Export include/asm-x86/kvm.h Signed-off-by: Avi Kivity commit 29f516db0b9baf019b1c93a154244fbedd81d2ac Author: Jerone Young Date: Mon Nov 19 17:06:37 2007 -0600 KVM: Portability: Move cpuid structures to This patch moves structures: kvm_cpuid_entry kvm_cpuid from include/linux/kvm.h to include/asm-x86/kvm.h Signed-off-by: Jerone Young Signed-off-by: Avi Kivity commit 8d8c2c60388c3e98e4386e086357f4e1b51bca1e Author: Jerone Young Date: Mon Nov 19 17:06:36 2007 -0600 KVM: Portability: Move kvm_sregs and msr structures to Move structures: kvm_sregs kvm_msr_entry kvm_msrs kvm_msr_list from include/linux/kvm.h to include/asm-x86/kvm.h Signed-off-by: Avi Kivity commit e7841ac816a436cc71107ed3d91496b45c86a00f Author: Jerone Young Date: Mon Nov 19 17:06:35 2007 -0600 KVM: Portability: Move kvm_segment & kvm_dtable structure to This patch moves structures: kvm_segment kvm_dtable from include/linux/kvm.h to include/asm-x86/kvm.h Signed-off-by: Jerone Young Signed-off-by: Avi Kivity commit 6b9fef5a4eb55e4da3cd39f720de76294bcd029c Author: Jerone Young Date: Mon Nov 19 17:06:34 2007 -0600 KVM: Portability: Move structure lapic_state to This patch moves structure lapic_state from include/linux/kvm.h to include/asm-x86/kvm.h Signed-off-by: Jerone Young Signed-off-by: Avi Kivity commit 93f93de2ff85e2fd20b2223415827499e5d5a05a Author: Jerone Young Date: Mon Nov 19 17:06:33 2007 -0600 KVM: Portability: Move kvm_regs to This patch moves structure kvm_regs to include/asm-x86/kvm.h. Each architecture will need to create there own version of this structure. Signed-off-by: Jerone Young Signed-off-by: Avi Kivity commit 9470242e09e9bc4cab3b516dc2d46632b62446ae Author: Jerone Young Date: Mon Nov 19 17:06:32 2007 -0600 KVM: Portability: Move x86 pic strutctures This patch moves structures: kvm_pic_state kvm_ioapic_state to inclue/asm-x86/kvm.h. Signed-off-by: Jerone Young Signed-off-by: Avi Kivity commit 12e8f8d9a762f055ef4a8a58ebf4a2d68b1c9db6 Author: Jerone Young Date: Mon Nov 19 17:06:31 2007 -0600 KVM: Portability: Move kvm_memory_alias to asm/kvm.h This patch moves sturct kvm_memory_alias from include/linux/kvm.h to include/asm-x86/kvm.h. Also have include/linux/kvm.h include include/asm/kvm.h. Signed-off-by: Jerone Young Signed-off-by: Avi Kivity commit d06cde663eaef859bafeb4cb63cf78bc0cd2fe87 Author: Hollis Blanchard Date: Mon Nov 19 14:04:44 2007 -0600 KVM: Move misplaced comment Signed-off-by: Hollis Blanchard Signed-off-by: Avi Kivity commit c477869e9394cde6806adf277f1bcfbf99a853b9 Author: Hollis Blanchard Date: Mon Nov 19 14:04:43 2007 -0600 KVM: Correct consistent typo: "destory" -> "destroy" Signed-off-by: Hollis Blanchard Signed-off-by: Avi Kivity commit ff24fe8b7bb10d101bc0f919ac7363ff1151cf22 Author: Hollis Blanchard Date: Mon Nov 19 14:04:45 2007 -0600 KVM: Remove unused "rmap_overflow" variable Signed-off-by: Hollis Blanchard Signed-off-by: Avi Kivity commit 1dd5587d4d986704098e1b3e5fcb3b6c4fa214b9 Author: Avi Kivity Date: Mon Nov 19 18:44:15 2007 +0200 KVM: MMU: Remove unused variable Signed-off-by: Avi Kivity commit c246677e2d16f91d82b2eaab1a0da04853c68d9e Author: Avi Kivity Date: Mon Nov 19 18:28:09 2007 +0200 KVM: Add missing #include Needed for empty_zero_page. Signed-off-by: Avi Kivity commit 3075271017054557698bd40c72759cf2fdfbdc5d Author: Izik Eidus Date: Mon Nov 19 11:16:57 2007 +0200 KVM: Simplify kvm_clear_guest_page() Use kvm_write_guest_page() with empty_zero_page, instead of doing kmap and memset. Signed-off-by: Izik Eidus Signed-off-by: Avi Kivity commit adc877cd04966fe7fa71b6e8204594c231db4877 Author: Izik Eidus Date: Mon Nov 19 11:28:19 2007 +0200 KVM: MMU: Change guest pte access to kvm_{read,write}_guest() Things are simpler and more regular this way. Signed-off-by: Izik Eidus Signed-off-by: Avi Kivity commit 28d8a8f15da3f54aec537ccb08330d9afac915f4 Author: Jan Kiszka Date: Mon Nov 19 10:21:45 2007 +0100 KVM: VMX: Force seg.base == (seg.sel << 4) in real mode Ensure that segment.base == segment.selector << 4 when entering the real mode on Intel so that the CPU will not bark at us. This fixes some old protected mode demo from http://www.x86.org/articles/pmbasics/tspec_a1_doc.htm. Signed-off-by: Jan Kiszka Signed-off-by: Avi Kivity commit afe6fba05620eacbebd533ef88903d27db5d4731 Author: Zhang Xiantao Date: Mon Nov 19 15:24:28 2007 +0800 KVM: Portability: Move some function declarations to x86.h Signed-off-by: Zhang Xiantao Signed-off-by: Avi Kivity commit 1765bb911a30b3ca2b186797b467ef1d921eb7a7 Author: Zhang Xiantao Date: Mon Nov 19 15:08:31 2007 +0800 KVM: Move some static inline functions out from kvm.h into x86.h Signed-off-by: Zhang Xiantao Signed-off-by: Avi Kivity commit 611a09879f95ba17968dc7072db40ae29b58831a Author: Zhang Xiantao Date: Mon Nov 19 14:56:05 2007 +0800 KVM: Portability: Move vcpu regs enumeration definition to x86.h Signed-off-by: Zhang Xiantao Signed-off-by: Avi Kivity commit 3a1fa229b664bc5c157e19bc7ae0dab9fc2ddb98 Author: Zhang Xiantao Date: Mon Nov 19 14:40:47 2007 +0800 KVM: Portability: Move struct kvm_x86_ops definition to x86.h Signed-off-by: Zhang Xiantao Signed-off-by: Avi Kivity commit 36c726e56c7bc40667ac5dcd21e517222da2b90d Author: Zhang Xiantao Date: Mon Nov 19 14:33:37 2007 +0800 KVM: Portability: Move some macro definitions from kvm.h to x86.h Signed-off-by: Zhang Xiantao Signed-off-by: Avi Kivity commit 843c367908fe8e9d6b9d1c1625e710537ce028f7 Author: Zhang Xiantao Date: Sun Nov 18 20:43:21 2007 +0800 KVM: Portability: MMU initialization and teardown split Move out kvm_mmu init and exit functionality from kvm_main.c Signed-off-by: Zhang Xiantao Signed-off-by: Avi Kivity commit b2dafaa9527ae6845c8bb2d85eee79dd759d5c42 Author: Zhang Xiantao Date: Sun Nov 18 20:29:43 2007 +0800 KVM: Portability: Move kvm_vcpu_ioctl_get_dirty_log to arch-specific file Meanwhile keep the interface in common, and leave as more logic in common as possible. Signed-off-by: Zhang Xiantao Signed-off-by: Avi Kivity commit 2171fec7f9df6cbd0f7793cf89d9ee3848ad6cd9 Author: Amit Shah Date: Thu Nov 15 18:38:46 2007 +0200 KVM: Make unloading of FPU state when putting vcpu arch-independent Instead of having each architecture do it individually, we do this in the arch-independent code (just x86 as of now). [avi: add svm to the mix, which was added to mainline during the 2.6.24-rc process] Signed-off-by: Amit Shah Signed-off-by: Avi Kivity commit 9eb6db84384c50eba85eea360e921b314669b211 Author: Avi Kivity Date: Sun Nov 18 16:37:07 2007 +0200 KVM: MMU: Add some mmu statistics Signed-off-by: Avi Kivity commit 94551089d411b2ba50293210ef785ddbd8b14026 Author: Avi Kivity Date: Sun Nov 18 16:24:12 2007 +0200 KVM: Extend stats support for VM stats This is in addition to the current virtual cpu statistics. Signed-off-by: Avi Kivity commit 4f749da9e68b5ade494d68597ecf045c73cb4ec0 Author: Avi Kivity Date: Sun Nov 18 15:17:51 2007 +0200 KVM: Add instruction emulation statistics commit 26c36eca453443016f70ea85af46c6109eeea400 Author: Avi Kivity Date: Sun Nov 18 13:54:33 2007 +0200 KVM: Add fpu_reload counter Measure the number of times we switch the fpu state. Signed-off-by: Avi Kivity commit 8355eb8e0bd02de51f4d36fc4f3e4df1572584e3 Author: Avi Kivity Date: Sun Nov 18 13:50:24 2007 +0200 KVM: Replace 'light_exits' stat with 'host_state_reload' This is a little more accurate (since it counts actual reloads, not potential reloads), and reverses the sense of the statistic to measure a bad event like most of the other stats (e.g. we want to minimize all counters). Signed-off-by: Avi Kivity commit 4289f27f40412271daf71ae62be478b535a6836d Author: Zhang Xiantao Date: Sun Nov 18 18:43:45 2007 +0800 KVM: Portability: Add two hooks to handle kvm_create and destroy vm Add two arch hooks to handle kvm_create_vm and kvm destroy_vm. Now, just put io_bus init and destory in common. Signed-off-by: Zhang Xiantao Signed-off-by: Avi Kivity commit c4e513d12d14cf64612211f8d06af996cc5019a7 Author: Zhang Xiantao Date: Fri Nov 16 14:38:21 2007 +0800 KVM: Remove __init attributes for kvm_init_debug and kvm_init_msr_list Since their callers are not declared with __init. Signed-off-by: Zhang Xiantao Signed-off-by: Avi Kivity commit cee77328482e5770d6df48212ecaece4d1750060 Author: Joe Perches Date: Mon Nov 12 20:06:51 2007 -0800 KVM: Remove ptr comparisons to 0 Fix sparse warnings "Using plain integer as NULL pointer" Signed-off-by: Joe Perches Signed-off-by: Avi Kivity commit 822e8a654b3ffd19b7bdcee3cb86498ac49e73f7 Author: Zhang Xiantao Date: Fri Nov 16 13:05:55 2007 +0800 KVM: Portability: Make kvm_vcpu_ioctl_translate arch dependent Move kvm_vcpu_ioctl_translate to arch, since mmu would be put under arch. Signed-off-by: Zhang Xiantao Signed-off-by: Avi Kivity commit da5b7f9653452b29c1389ed7c291422cd37c3312 Author: Avi Kivity Date: Thu Nov 15 18:06:18 2007 +0200 KVM: VMX: Consolidate register usage in vmx_vcpu_run() We pass vcpu, vmx->fail, and vmx->launched to assembly code, but all three are fields within vmx. Consolidate by only passing in vmx and offsets for the rest. Signed-off-by: Avi Kivity commit e1392d7931e0092dd1a03a108ca77c63b6083ffb Author: Zhang Xiantao Date: Thu Nov 15 23:07:47 2007 +0800 KVM: Portability: move KVM_CHECK_EXTENSION Make KVM_CHECK_EXTENSION code into a function, all archs can define its capability independently. Signed-off-by: Zhang Xiantao Acked-by: Carsten Otte Signed-off-by: Avi Kivity commit 7830eebf97a949620a0eb85a6d2d75eacc7e5df8 Author: Sheng Yang Date: Thu Nov 15 14:52:28 2007 +0800 KVM: x86 emulator: modify 'lods', and 'stos' not to depend on CR2 The current 'lods' and 'stos' is depending on incoming CR2 rather than decode memory address from registers. Signed-off-by: Sheng Yang Signed-off-by: Avi Kivity commit fee712e28103841adb5d4e3884f39f8859ec3005 Author: Zhang Xiantao Date: Wed Nov 14 20:40:21 2007 +0800 KVM: Portability: Move x86 specific code from kvm_init() to kvm_arch() Signed-off-by: Zhang Xiantao Acked-by: Carsten Otte Signed-off-by: Avi Kivity commit 97d05f12b4c2949210d671bab3168ed0055131ff Author: Zhang Xiantao Date: Wed Nov 14 20:39:31 2007 +0800 KVM: Portability: Combine kvm_init and kvm_init_x86 Will be called once arch module registers itself. Signed-off-by: Zhang Xiantao Acked-by: Carsten Otte Signed-off-by: Avi Kivity commit 3f9df31d3108ba0ffc587f163e66abb9ad8eb61a Author: Zhang Xiantao Date: Wed Nov 14 20:38:21 2007 +0800 KVM: Portability: Add vcpu and hardware management arch hooks Add the following hooks: void decache_vcpus_on_cpu(int cpu); int kvm_arch_vcpu_init(struct kvm_vcpu *vcpu); void kvm_arch_vcpu_uninit(struct kvm_vcpu *vcpu); void kvm_arch_vcpu_free(struct kvm_vcpu *vcpu); void kvm_arch_vcpu_load(struct kvm_vcpu *vcpu, int cpu); void kvm_arch_vcpu_put(struct kvm_vcpu *vcpu); struct kvm_vcpu *kvm_arch_vcpu_create(struct kvm *kvm, unsigned int id); void kvm_arch_vcpu_destory(struct kvm_vcpu *vcpu); int kvm_arch_vcpu_reset(struct kvm_vcpu *vcpu); void kvm_arch_hardware_enable(void *garbage); void kvm_arch_hardware_disable(void *garbage); int kvm_arch_hardware_setup(void); void kvm_arch_hardware_unsetup(void); void kvm_arch_check_processor_compat(void *rtn); Signed-off-by: Zhang Xiantao Signed-off-by: Avi Kivity commit 42ebda70312ee76ad23b90bbf02ddb480e511f63 Author: Zhang Xiantao Date: Wed Nov 14 20:09:30 2007 +0800 KVM: Portability: Move kvm_x86_ops to x86.c Signed-off-by: Zhang Xiantao Acked-by: Carsten Otte Signed-off-by: Avi Kivity commit 1698b42863745205c29fc17dcc685a30dcd46fa0 Author: Zhang Xiantao Date: Wed Nov 14 20:08:51 2007 +0800 KVM: Portability: Move some includes to x86.c Move some includes to x86.c from kvm_main.c, since the related functions have been moved to x86.c Signed-off-by: Zhang Xiantao Acked-by: Carsten Otte Signed-off-by: Avi Kivity commit e76e5514079fb399197599c1b00dc7d5fa9fd9bf Author: Izik Eidus Date: Sun Nov 11 22:10:22 2007 +0200 KVM: Change kvm_{read,write}_guest() to use copy_{from,to}_user() This changes kvm_write_guest_page/kvm_read_guest_page to use copy_to_user/read_from_user, as a result we get better speed and better dirty bit tracking. Signed-off-by: Izik Eidus Signed-off-by: Avi Kivity commit 2de9dba3097ebff65cc25496c32c0653b18dcf83 Author: Izik Eidus Date: Sun Nov 11 22:05:04 2007 +0200 KVM: introduce gfn_to_hva() Convert a guest frame number to the corresponding host virtual address. Signed-off-by: Izik Eidus Signed-off-by: Avi Kivity commit 0893321f0d8ab0e87b71b13c07e50cba1f423464 Author: Izik Eidus Date: Sun Nov 11 22:02:22 2007 +0200 KVM: add kvm_is_error_hva() Check for the "error hva", an address outside the user address space that signals a bad gfn. Signed-off-by: Izik Eidus Signed-off-by: Avi Kivity commit b420a3a903f258a993bc5b33bc54a49126a8dbbf Author: Avi Kivity Date: Sun Nov 11 18:37:32 2007 +0200 KVM: Simplify CPU_TASKS_FROZEN cpu notifier handling Signed-off-by: Avi Kivity commit e53135d7f031d90c9d470837937984b0cd8b7989 Author: Izik Eidus Date: Sun Nov 11 14:48:17 2007 +0200 KVM: x86 emulator: remove 8 bytes operands emulator for call near instruction it is removed beacuse it isnt supported on a real host Signed-off-by: Izik Eidus Signed-off-by: Avi Kivity commit c3ea2d8855148888f26bbfd71b530eb7396f2645 Author: Eddie Dong Date: Sun Nov 11 12:28:35 2007 +0200 KVM: VMX: wbinvd exiting Add wbinvd VM Exit support to prepare for pass-through device cache emulation and also enhance real time responsiveness. Signed-off-by: Yaozu (Eddie) Dong Signed-off-by: Avi Kivity commit 5dd65ebd34d0dcfe5db11ef0f43c262a9fc2a625 Author: Eddie Dong Date: Sun Nov 11 12:27:20 2007 +0200 KVM: VMX: Comment VMX primary/secondary exec ctl definitions Add comments for secondary/primary Processor-Based VM-execution controls. Signed-off-by: Yaozu (Eddie) Dong Signed-off-by: Avi Kivity commit 65987f623c17e58096470092b800db660691c27e Author: Avi Kivity Date: Thu Nov 22 11:42:59 2007 +0200 KVM: Fix faults during injection of real-mode interrupts If vmx fails to inject a real-mode interrupt while fetching the interrupt redirection table, it fails to record this in the vectoring information field. So we detect this condition and do it ourselves. Signed-off-by: Avi Kivity commit 313589267465b2521fcb9c72491c10b161f9b6c0 Author: Avi Kivity Date: Thu Nov 22 11:30:47 2007 +0200 KVM: VMX: Read & store IDT_VECTORING_INFO_FIELD We'll want to write to it in order to fix real-mode irq injection problems, but it is a read-only field. Storing it in a variable solves that issue. Signed-off-by: Avi Kivity commit 69d7c705a0c9bef0b21e2899ba86160804a900f2 Author: Avi Kivity Date: Thu Nov 8 18:19:20 2007 +0200 KVM: VMX: Use vmx to inject real-mode interrupts Instead of injecting real-mode interrupts by writing the interrupt frame into guest memory, abuse vmx by injecting a software interrupt. We need to pretend the software interrupt instruction had a length > 0, so we have to adjust rip backward. This lets us not to mess with writing guest memory, which is complex and also sleeps. Signed-off-by: Avi Kivity commit a7acc3f15961003585476e56c97aac12931db7ba Author: Dor Laor Date: Wed Nov 7 16:20:06 2007 +0200 KVM: Add make_page_dirty() to kvm_clear_guest_page() Every write access to guest pages should be tracked. Signed-off-by: Dor Laor Signed-off-by: Izik Eidus Signed-off-by: Avi Kivity commit e485187cb758cbe6c4172ac1c6cf1a02033640c2 Author: Hollis Blanchard Date: Thu Nov 1 14:16:10 2007 -0500 KVM: Portability: Move x86 vcpu ioctl handlers to x86.c Signed-off-by: Hollis Blanchard Signed-off-by: Avi Kivity commit bd80a35a904c82d5e3eb85483c59a4fcebcc0345 Author: Hollis Blanchard Date: Wed Oct 31 17:24:25 2007 -0500 KVM: Portability: Move x86 FPU handling to x86.c Signed-off-by: Hollis Blanchard Signed-off-by: Avi Kivity commit 96e9b0f7b0edf08c5b8b0de47d48826032677535 Author: Hollis Blanchard Date: Wed Oct 31 17:24:24 2007 -0500 KVM: Portability: Move x86 instruction emulation code to x86.c Signed-off-by: Hollis Blanchard Signed-off-by: Avi Kivity commit 291efa8f29b50660763daf712408289100a7f963 Author: Hollis Blanchard Date: Wed Oct 31 17:24:23 2007 -0500 KVM: Portability: Make exported debugfs data architecture-specific Signed-off-by: Hollis Blanchard Signed-off-by: Avi Kivity commit b44df9ec4796d569bc8edf47619bdcfccf675ebf Author: Avi Kivity Date: Thu Nov 1 06:31:28 2007 +0200 KVM: x86 emulator: Hoist modrm and abs decoding into separate functions Signed-off-by: Avi Kivity commit 99bcd32e7a046d42dab4a3bed03fc46f167cf0b6 Author: Uri Lublin Date: Tue Oct 30 10:42:09 2007 +0200 KVM: Make mark_page_dirty() work for aliased pages too. Recommended by Izik Eidus. Signed-off-by: Uri Lublin Signed-off-by: Avi Kivity commit 498a5bf184d75d7aad2af8e2f18ef57640980b15 Author: Avi Kivity Date: Wed Oct 31 11:21:06 2007 +0200 KVM: Simplify decode_register_operand() calling convention Now that rex_prefix is part of the decode cache, there is no need to pass it along. Signed-off-by: Avi Kivity commit d24c2abd708a5e354197fc40f6562328ec0171e3 Author: Avi Kivity Date: Wed Oct 31 11:15:56 2007 +0200 KVM: x86 emulator: centralize decoding of one-byte register access insns Instructions like 'inc reg' that have the register operand encoded in the opcode are currently specially decoded. Extend decode_register_operand() to handle that case, indicated by having DstReg or SrcReg without ModRM. Signed-off-by: Avi Kivity commit 90128492364c458040934c1e0a4e69d986b8ce17 Author: Avi Kivity Date: Wed Oct 31 10:27:04 2007 +0200 KVM: x86 emulator: Extract the common code of SrcReg and DstReg Share the common parts of SrcReg and DstReg decoding. Signed-off-by: Avi Kivity commit f065eb1c86c8f66252fb83e938c909301f107b02 Author: Carsten Otte Date: Tue Oct 30 18:44:25 2007 +0100 KVM: Portability: Move pio emulation functions to x86.c This patch moves implementation of the following functions from kvm_main.c to x86.c: free_pio_guest_pages, vcpu_find_pio_dev, pio_copy_data, complete_pio, kernel_pio, pio_string_write, kvm_emulate_pio, kvm_emulate_pio_string The function inject_gp, which was duplicated by yesterday's patch series, is removed from kvm_main.c now because it is not needed anymore. Signed-off-by: Carsten Otte Acked-by: Hollis Blanchard Signed-off-by: Avi Kivity commit f2b682cefecc497e101372386a98705567362acc Author: Carsten Otte Date: Tue Oct 30 18:44:21 2007 +0100 KVM: Portability: Move x86 emulation and mmio device hook to x86.c This patch moves the following functions to from kvm_main.c to x86.c: emulator_read/write_std, vcpu_find_pervcpu_dev, vcpu_find_mmio_dev, emulator_read/write_emulated, emulator_write_phys, emulator_write_emulated_onepage, emulator_cmpxchg_emulated, get_setment_base, emulate_invlpg, emulate_clts, emulator_get/set_dr, kvm_report_emulation_failure, emulate_instruction The following data type is moved to x86.c: struct x86_emulate_ops emulate_ops Signed-off-by: Carsten Otte Acked-by: Hollis Blanchard Signed-off-by: Avi Kivity commit 49153e58bf8f07d6a9c8766f2da8c91805f83f82 Author: Carsten Otte Date: Tue Oct 30 18:44:17 2007 +0100 KVM: Portability: Move kvm_get/set_msr[_common] to x86.c This patch moves the implementation of the functions of kvm_get/set_msr, kvm_get/set_msr_common, and set_efer from kvm_main.c to x86.c. The definition of EFER_RESERVED_BITS is moved too. Signed-off-by: Carsten Otte Acked-by: Hollis Blanchard Signed-off-by: Avi Kivity commit a5ade20c8056c92db199fc6515be7edb4fa7e63e Author: Anthony Liguori Date: Mon Oct 29 15:15:20 2007 -0500 KVM: Fix gfn_to_page() acquiring mmap_sem twice KVM's nopage handler calls gfn_to_page() which acquires the mmap_sem when calling out to get_user_pages(). nopage handlers are already invoked with the mmap_sem held though. Introduce a __gfn_to_page() for use by the nopage handler which requires the lock to already be held. This was noticed by tglx. Signed-off-by: Anthony Liguori Signed-off-by: Avi Kivity commit 451287231375e512574477693ad310c981e7d922 Author: Sheng Yang Date: Mon Oct 29 09:40:42 2007 +0800 KVM: VMX: Enable memory mapped TPR shadow (FlexPriority) This patch based on CR8/TPR patch, and enable the TPR shadow (FlexPriority) for 32bit Windows. Since TPR is accessed very frequently by 32bit Windows, especially SMP guest, with FlexPriority enabled, we saw significant performance gain. Signed-off-by: Sheng Yang Signed-off-by: Avi Kivity commit 8348f5ecbfb3c8f5688a8c5cf04f120fe5ef4f68 Author: Carsten Otte Date: Mon Oct 29 16:09:35 2007 +0100 KVM: Portability: Move control register helper functions to x86.c This patch moves the definitions of CR0_RESERVED_BITS, CR4_RESERVED_BITS, and CR8_RESERVED_BITS along with the following functions from kvm_main.c to x86.c: set_cr0(), set_cr3(), set_cr4(), set_cr8(), get_cr8(), lmsw(), load_pdptrs() The static function wrapper inject_gp is duplicated in kvm_main.c and x86.c for now, the version in kvm_main.c should disappear once the last user of it is gone too. The function load_pdptrs is no longer static, and now defined in x86.h for the time being, until the last user of it is gone from kvm_main.c. Signed-off-by: Carsten Otte Reviewed-by: Christian Borntraeger Acked-by: Hollis Blanchard Signed-off-by: Avi Kivity commit 210301268dc7ce8aae9898f00a6cb498c2535ceb Author: Carsten Otte Date: Mon Oct 29 16:09:10 2007 +0100 KVM: Portability: move get/set_apic_base to x86.c This patch moves the implementation of get_apic_base and set_apic_base from kvm_main.c to x86.c Signed-off-by: Carsten Otte Reviewed-by: Christian Borntraeger Acked-by: Hollis Blanchard Signed-off-by: Avi Kivity commit eec9635aa34d88c986f37613408bb25b0da39d67 Author: Carsten Otte Date: Mon Oct 29 16:08:51 2007 +0100 KVM: Portability: Move memory segmentation to x86.c This patch moves the definition of segment_descriptor_64 for AMD64 and EM64T from kvm_main.c to segment_descriptor.h. It also adds a proper #ifndef...#define...#endif around that header file. The implementation of segment_base is moved from kvm_main.c to x86.c. Signed-off-by: Carsten Otte Reviewed-by: Christian Borntraeger Acked-by: Hollis Blanchard Signed-off-by: Avi Kivity commit 68486294e54c8c3ea3cc20818a2ffc258ae79064 Author: Carsten Otte Date: Mon Oct 29 16:08:35 2007 +0100 KVM: Portability: Split kvm_vm_ioctl v3 This patch splits kvm_vm_ioctl into archtecture independent parts, and x86 specific parts which go to kvm_arch_vcpu_ioctl in x86.c. The patch is unchanged since last submission. Common ioctls for all architectures are: KVM_CREATE_VCPU, KVM_GET_DIRTY_LOG, KVM_SET_USER_MEMORY_REGION x86 specific ioctls are: KVM_SET_MEMORY_REGION, KVM_GET/SET_NR_MMU_PAGES, KVM_SET_MEMORY_ALIAS, KVM_CREATE_IRQCHIP, KVM_CREATE_IRQ_LINE, KVM_GET/SET_IRQCHIP KVM_SET_TSS_ADDR Signed-off-by: Carsten Otte Reviewed-by: Christian Borntraeger Acked-by: Hollis Blanchard Signed-off-by: Avi Kivity commit 7e34e4d66cbbc04cc7a549da826e936860f9dcb2 Author: Avi Kivity Date: Sun Oct 28 18:52:05 2007 +0200 KVM: MMU: Topup the mmu memory preallocation caches before emulating an insn Emulation may cause a shadow pte to be instantiated, which requires memory resources. Make sure the caches are filled to avoid an oops. Signed-off-by: Avi Kivity commit 415ce32aab70971a6ec794605012a0bd451d03af Author: Avi Kivity Date: Sun Oct 28 18:48:59 2007 +0200 KVM: Move page fault processing to common code The code that dispatches the page fault and emulates if we failed to map is duplicated across vmx and svm. Merge it to simplify further bugfixing. Signed-off-by: Avi Kivity commit e7facf3d1ac177110e431c7021111d7c10acf5e2 Author: Avi Kivity Date: Sun Oct 28 16:34:25 2007 +0200 KVM: x86 emulator: don't depend on cr2 for mov abs emulation The 'mov abs' instruction family (opcodes 0xa0 - 0xa3) still depends on cr2 provided by the page fault handler. This is wrong for several reasons: - if an instruction accessed misaligned data that crosses a page boundary, and if the fault happened on the second page, cr2 will point at the second page, not the data itself. - if we're emulating in real mode, or due to a FlexPriority exit, there is no cr2 generated. So, this change adds decoding for this instruction form and drops reliance on cr2. Signed-off-by: Avi Kivity commit 39c06a59bf7ce412179c8d2ee681f7e6eae34c4c Author: Laurent Vivier Date: Thu Oct 25 14:18:54 2007 +0200 KVM: SVM: Let gcc to choose which registers to save (i386) This patch lets GCC to determine which registers to save when we switch to/from a VCPU in the case of AMD i386 * Original code saves following registers: ebx, ecx, edx, esi, edi, ebp * Patched code: - informs GCC that we modify following registers using the clobber description: ebx, ecx, edx, esi, edi - rbp is saved (pop/push) because GCC seems to ignore its use in the clobber description. Signed-off-by: Laurent Vivier Signed-off-by: Avi Kivity commit 75e7957bcd1ff7d86878f6104662d7aaeb1895f4 Author: Laurent Vivier Date: Thu Oct 25 14:18:53 2007 +0200 KVM: SVM: Let gcc to choose which registers to save (x86_64) This patch lets GCC to determine which registers to save when we switch to/from a VCPU in the case of AMD x86_64. * Original code saves following registers: rbx, rcx, rdx, rsi, rdi, rbp, r8, r9, r10, r11, r12, r13, r14, r15 * Patched code: - informs GCC that we modify following registers using the clobber description: rbx, rcx, rdx, rsi, rdi r8, r9, r10, r11, r12, r13, r14, r15 - rbp is saved (pop/push) because GCC seems to ignore its use in the clobber description. Signed-off-by: Laurent Vivier Signed-off-by: Avi Kivity commit 795533755652ddd1d60cd1a451337116a956539b Author: Laurent Vivier Date: Thu Oct 25 14:18:55 2007 +0200 KVM: VMX: Let gcc to choose which registers to save (i386) This patch lets GCC to determine which registers to save when we switch to/from a VCPU in the case of intel i386. * Original code saves following registers: eax, ebx, ecx, edx, edi, esi, ebp (using popa) * Patched code: - informs GCC that we modify following registers using the clobber description: ebx, edi, rsi - doesn't save eax because it is an output operand (vmx->fail) - cannot put ecx in clobber description because it is an input operand, but as we modify it and we want to keep its value (vcpu), we must save it (pop/push) - ebp is saved (pop/push) because GCC seems to ignore its use the clobber description. - edx is saved (pop/push) because it is reserved by GCC (REGPARM) and cannot be put in the clobber description. - line "mov (%%esp), %3 \n\t" has been removed because %3 is ecx and ecx is restored just after. Signed-off-by: Laurent Vivier Signed-off-by: Avi Kivity commit 41141bde788afe7eb407e4ac46dee13f0bc30cac Author: Laurent Vivier Date: Thu Oct 25 14:18:52 2007 +0200 KVM: VMX: Let gcc to choose which registers to save (x86_64) This patch lets GCC to determine which registers to save when we switch to/from a VCPU in the case of intel x86_64. * Original code saves following registers: rax, rbx, rcx, rdx, rsi, rdi, rbp, r8, r9, r10, r11, r12, r13, r14, r15 * Patched code: - informs GCC that we modify following registers using the clobber description: rbx, rdi, rsi, r8, r9, r10, r11, r12, r13, r14, r15 - doesn't save rax because it is an output operand (vmx->fail) - cannot put rcx in clobber description because it is an input operand, but as we modify it and we want to keep its value (vcpu), we must save it (pop/push) - rbp is saved (pop/push) because GCC seems to ignore its use in the clobber description. - rdx is saved (pop/push) because it is reserved by GCC (REGPARM) and cannot be put in the clobber description. - line "mov (%%rsp), %3 \n\t" has been removed because %3 is rcx and rcx is restored just after. - line ASM_VMX_VMWRITE_RSP_RDX() is moved out of the ifdef/else/endif Signed-off-by: Laurent Vivier Signed-off-by: Avi Kivity commit 430dbe8a56da6b45d7ceb03ca71cc474a0620c4f Author: Izik Eidus Date: Thu Oct 25 00:29:55 2007 +0200 KVM: Add ioctl to tss address from userspace, Currently kvm has a wart in that it requires three extra pages for use as a tss when emulating real mode on Intel. This patch moves the allocation internally, only requiring userspace to tell us where in the physical address space we can place the tss. Signed-off-by: Izik Eidus Signed-off-by: Avi Kivity commit 6fb1e0b2a1e1a2b5b9729b187b13c870d58bf4b6 Author: Izik Eidus Date: Wed Oct 24 23:57:46 2007 +0200 KVM: Add kernel-internal memory slots Reserve a few memory slots for kernel internal use. This is good for case you have to register memory region and you want to be sure it was not registered from userspace, and for case you want to register a memory region that won't be seen from userspace. Signed-off-by: Izik Eidus Signed-off-by: Avi Kivity commit 733f6415f3975478ed8fa383d89c7ae86b938cde Author: Izik Eidus Date: Wed Oct 24 23:52:57 2007 +0200 KVM: Export memory slot allocation mechanism Remove kvm memory slot allocation mechanism from the ioctl and put it to exported function. Signed-off-by: Izik Eidus Signed-off-by: Avi Kivity commit cb1a650958d37b941f6517adaa6e600b82978f91 Author: Izik Eidus Date: Thu Oct 25 11:54:04 2007 +0200 KVM: Unmap kernel-allocated memory on slot destruction kvm_vm_ioctl_set_memory_region() is able to remove memory in addition to adding it. Therefore when using kernel swapping support for old userspaces, we need to munmap the memory if the user request to remove it Signed-off-by: Izik Eidus Signed-off-by: Avi Kivity commit 11fbdcc2357e502f1db984398580f3e5f7b22ce1 Author: Christian Borntraeger Date: Thu Oct 11 15:34:17 2007 +0200 KVM: Per-architecture hypercall definitions Currently kvm provides hypercalls only for x86* architectures. To provide hypercall infrastructure for other kvm architectures I split kvm_para.h into a generic header file and architecture specific definitions. Signed-off-by: Christian Borntraeger Signed-off-by: Avi Kivity commit 882b84e0e7d033fdaf553bc5cdf535dfcd99ec18 Author: Eddie Dong Date: Wed Oct 10 12:15:54 2007 +0200 KVM: Split IOAPIC reset function and export for kernel RESET Signed-off-by: Yaozu (Eddie) Dong Signed-off-by: Avi Kivity commit 221aabc8a9ddc0d6b1c5f35f556410ee5b4549c3 Author: Eddie Dong Date: Wed Oct 10 12:14:25 2007 +0200 KVM: Export PIC reset for kernel device reset Signed-off-by: Yaozu (Eddie) Dong Signed-off-by: Avi Kivity commit 51a29f6879429e999ca7e40b4ee35c264102bcc6 Author: Avi Kivity Date: Sun Oct 21 11:03:36 2007 +0200 KVM: Add a might_sleep() annotation to gfn_to_page() This will help trap accesses to guest memory in atomic context. Signed-off-by: Avi Kivity commit 38376823b92c1496c851464abc751a2d12ff5192 Author: Avi Kivity Date: Sun Oct 21 11:00:39 2007 +0200 KVM: Move vmx_vcpu_reset() out of vmx_vcpu_setup() Split guest reset code out of vmx_vcpu_setup(). Besides being cleaner, this moves the realmode tss setup (which can sleep) outside vmx_vcpu_setup() (which is executed with preemption enabled). [izik: remove unused variable] Signed-off-by: Avi Kivity commit 130452e6577d52fed09bbc3e0fd23d4e01dc6145 Author: Zhang Xiantao Date: Sat Oct 20 15:34:38 2007 +0800 KVM: Portability: Split kvm_vcpu into arch dependent and independent parts (part 1) First step to split kvm_vcpu. Currently, we just use an macro to define the common fields in kvm_vcpu for all archs, and all archs need to define its own kvm_vcpu struct. Signed-off-by: Zhang Xiantao Signed-off-by: Avi Kivity commit b25d84aa1de2a0259e54415faef1c5bdef15cec3 Author: Anthony Liguori Date: Thu Oct 18 09:59:34 2007 -0500 KVM: Allocate userspace memory for older userspace Allocate a userspace buffer for older userspaces. Also eliminate phys_mem buffer. The memset() in kvmctl really kills initial memory usage but swapping works even with old userspaces. A side effect is that maximum guest side is reduced for older userspace on i386. Signed-off-by: Anthony Liguori Signed-off-by: Avi Kivity commit e6a9547518fdab65640a9f77bd285472dc26beb9 Author: Christian Borntraeger Date: Thu Oct 18 14:39:10 2007 +0200 KVM: Use virtual cpu accounting if available for guest times. ppc and s390 offer the possibility to track process times precisely by looking at cpu timer on every context switch, irq, softirq etc. We can use that infrastructure as well for guest time accounting. We need to account the used time before we change the state. This patch adds a call to account_system_vtime to kvm_guest_enter and kvm_guest exit. If CONFIG_VIRT_CPU_ACCOUNTING is not set, account_system_vtime is defined in hardirq.h as an empty function, which means this patch does not change the behaviour on other platforms. I compile tested this patch on x86 and function tested the patch on s390. Signed-off-by: Christian Borntraeger Signed-off-by: Avi Kivity commit e0534e37e90b89331e0eb03cd4f3fa7a4164dcea Author: Izik Eidus Date: Thu Oct 18 11:09:33 2007 +0200 KVM: MMU: Partial swapping of guest memory This allows guest memory to be swapped. Pages which are currently mapped via shadow page tables are pinned into memory, but all other pages can be freely swapped. The patch makes gfn_to_page() elevate the page's reference count, and introduces kvm_release_page() that pairs with it. Signed-off-by: Izik Eidus Signed-off-by: Avi Kivity commit 91775c12b13346db968b990b5c38dca83ebbd0c1 Author: Izik Eidus Date: Wed Oct 17 19:17:48 2007 +0200 KVM: MMU: Make gfn_to_page() always safe In case the page is not present in the guest memory map, return a dummy page the guest can scribble on. This simplifies error checking in its users. Signed-off-by: Izik Eidus Signed-off-by: Avi Kivity commit c28b628fbe789e3cf279c53157eca599b3308a78 Author: Izik Eidus Date: Tue Oct 16 14:43:46 2007 +0200 KVM: MMU: Keep a reverse mapping of non-writable translations The current kvm mmu only reverse maps writable translation. This is used to write-protect a page in case it becomes a pagetable. But with swapping support, we need a reverse mapping of read-only pages as well: when we evict a page, we need to remove any mapping to it, whether writable or not. Signed-off-by: Izik Eidus Signed-off-by: Avi Kivity commit 13e17d387b510ee4d2ae7220c36d46a53d04b99d Author: Izik Eidus Date: Tue Oct 16 14:42:30 2007 +0200 KVM: MMU: Add rmap_next(), a helper for walking kvm rmaps Signed-off-by: Izik Eidus Signed-off-by: Avi Kivity commit 6565476fe6a56189c6f7144b7be915be3579292a Author: Nitin A Kamble Date: Tue Oct 16 18:23:27 2007 -0700 KVM: x86 emulator: cmc, clc, cli, sti Instruction: cmc, clc, cli, sti opcodes: 0xf5, 0xf8, 0xfa, 0xfb respectively. [avi: fix reference to EFLG_IF which is not defined anywhere] Signed-off-by: Nitin A Kamble Signed-off-by: Avi Kivity commit a30fcdc59c5a93457338fe4de27108543389106d Author: Avi Kivity Date: Wed Oct 17 12:18:47 2007 +0200 KVM: MMU: Simplify page table walker Simplify the walker level loop not to carry so much information from one loop to the next. In addition to being complex, this made kmap_atomic() critical sections difficult to manage. As a result of this change, kmap_atomic() sections are limited to actually touching the guest pte, which allows the other functions called from the walker to do sleepy operations. This will happen when we enable swapping. Signed-off-by: Avi Kivity commit cf386590baf3111a17f5a64e10328dbe8a60bcf7 Author: Nitin A Kamble Date: Fri Oct 12 17:40:33 2007 -0700 KVM: x86 emulator: Implement emulation of instruction: inc & dec Instructions: inc r16/r32 (opcode 0x40-0x47) dec r16/r32 (opcode 0x48-0x4f) Signed-off-by: Nitin A Kamble Signed-off-by: Avi Kivity commit bba43153582493fef707335cf1de525d12dbeeec Author: Avi Kivity Date: Tue Oct 16 17:22:08 2007 +0200 KVM: Rename KVM_TLB_FLUSH to KVM_REQ_TLB_FLUSH We now have a new namespace, KVM_REQ_*, for bits in vcpu->requests. Signed-off-by: Avi Kivity commit daf24e56a39ce57002da560f6144065ce7c18450 Author: Avi Kivity Date: Tue Oct 16 16:23:22 2007 +0200 KVM: Move apic timer interrupt backlog processing to common code Beside the obvious goodness of making code more common, this prevents a livelock with the next patch which moves interrupt injection out of the critical section. Signed-off-by: Avi Kivity commit 1ac4f23de15bdcc8375a2ed67f54d63322746123 Author: Laurent Vivier Date: Fri Oct 12 11:01:59 2007 +0200 KVM: Add some \n in ioapic_debug() Add new-line at end of debug strings. Signed-off-by: Laurent Vivier Signed-off-by: Avi Kivity commit 32bc111f729a49d67f425568f1ac573b4577aa45 Author: Qing He Date: Mon Sep 24 17:39:41 2007 +0800 KVM: apic round robin cleanup If no apic is enabled in the bitmap of an interrupt delivery with delivery mode of lowest priority, a warning should be reported rather than select a fallback vcpu Signed-off-by: Qing He Signed-off-by: Eddie (Yaozu) Dong Signed-off-by: Avi Kivity commit b2bd95573b0efa3ddbeb41d52fe5ddc140529324 Author: Carsten Otte Date: Thu Oct 11 19:16:52 2007 +0200 KVM: Portability: split kvm_vcpu_ioctl This patch splits kvm_vcpu_ioctl into archtecture independent parts, and x86 specific parts which go to kvm_arch_vcpu_ioctl in x86.c. Common ioctls for all architectures are: KVM_RUN, KVM_GET/SET_(S-)REGS, KVM_TRANSLATE, KVM_INTERRUPT, KVM_DEBUG_GUEST, KVM_SET_SIGNAL_MASK, KVM_GET/SET_FPU Note that some PPC chips don't have an FPU, so we might need an #ifdef around KVM_GET/SET_FPU one day. x86 specific ioctls are: KVM_GET/SET_LAPIC, KVM_SET_CPUID, KVM_GET/SET_MSRS An interresting aspect is vcpu_load/vcpu_put. We now have a common vcpu_load/put which does the preemption stuff, and an architecture specific kvm_arch_vcpu_load/put. In the x86 case, this one calls the vmx/svm function defined in kvm_x86_ops. Signed-off-by: Carsten Otte Reviewed-by: Christian Borntraeger Reviewed-by: Christian Ehrhardt Signed-off-by: Avi Kivity commit 73b3b30fe93fd5923c101311a79e18404bad7e8c Author: Avi Kivity Date: Thu Oct 11 15:30:21 2007 +0200 KVM: MMU: When updating the dirty bit, inform the mmu about it Since the mmu uses different shadow pages for dirty large pages and clean large pages, this allows the mmu to drop ptes that are now invalid. Signed-off-by: Avi Kivity commit 99920ba10b1d5bb51d273e42c58f8767e5a5bde4 Author: Avi Kivity Date: Thu Oct 11 15:22:59 2007 +0200 KVM: MMU: Move dirty bit updates to a separate function Signed-off-by: Avi Kivity commit b1e01be00832901cb70690b468f3819b76ef8473 Author: Avi Kivity Date: Thu Oct 11 15:13:49 2007 +0200 KVM: MMU: Instantiate real-mode shadows as user writable shadows This is consistent with real-mode permissions. Signed-off-by: Avi Kivity commit 85399c5e0e8d2e6c5330dfb66a16aee59978fc52 Author: Avi Kivity Date: Thu Oct 11 15:12:24 2007 +0200 KVM: MMU: Disable write access on clean large pages By forcing clean huge pages to be read-only, we have separate roles for the shadow of a clean large page and the shadow of a dirty large page. This is necessary because different ptes will be instantiated for the two cases, even for read faults. Signed-off-by: Avi Kivity commit 8635624404040a9565033bf26bb70a278e85652a Author: Avi Kivity Date: Thu Oct 11 15:08:41 2007 +0200 KVM: MMU: Fix nx access bit for huge pages We must set the bit before the shift, otherwise the wrong bit gets set. Signed-off-by: Avi Kivity commit 8e31a1895e0821947d4d1e7a533400481875eed5 Author: Avi Kivity Date: Thu Oct 11 12:32:30 2007 +0200 KVM: Move guest pte dirty bit management to the guest pagetable walker This is more consistent with the accessed bit management, and makes the dirty bit available earlier for other purposes. Signed-off-by: Avi Kivity commit c58d4160facaf0730cc548d6c18cf4250b70d960 Author: Anthony Liguori Date: Wed Oct 10 20:08:41 2007 -0500 KVM: MMU: More struct kvm_vcpu -> struct kvm cleanups This time, the biggest change is gpa_to_hpa. The translation of GPA to HPA does not depend on the VCPU state unlike GVA to GPA so there's no need to pass in the kvm_vcpu. Signed-off-by: Anthony Liguori Signed-off-by: Avi Kivity commit 55d32ac35e946d641573a5bc0ebc99e8644897e7 Author: Anthony Liguori Date: Wed Oct 10 19:25:50 2007 -0500 KVM: MMU: Clean up MMU functions to take struct kvm when appropriate Some of the MMU functions take a struct kvm_vcpu even though they affect all VCPUs. This patch cleans up some of them to instead take a struct kvm. This makes things a bit more clear. The main thing that was confusing me was whether certain functions need to be called on all VCPUs. Signed-off-by: Anthony Liguori Signed-off-by: Avi Kivity commit d45e5fa2beb3afbab77a1d63b335bc79ea624347 Author: Carsten Otte Date: Wed Oct 10 17:16:19 2007 +0200 KVM: Move x86 msr handling to new files x86.[ch] Signed-off-by: Carsten Otte Signed-off-by: Avi Kivity commit d8c9c8421106deed341737833f7b1fe09ed8eae0 Author: Izik Eidus Date: Tue Oct 9 19:20:39 2007 +0200 KVM: Support assigning userspace memory to the guest Instead of having the kernel allocate memory to the guest, let userspace allocate it and pass the address to the kernel. This is required for s390 support, but also enables features like memory sharing and using hugetlbfs backed memory. Signed-off-by: Izik Eidus Signed-off-by: Avi Kivity commit 42db4f37fc99106f31db4ff1bebe4602aa01d436 Author: Mike Day Date: Mon Oct 8 09:02:08 2007 -0400 KVM: CodingStyle cleanup Signed-off-by: Mike D. Day Signed-off-by: Avi Kivity commit b764fc6a6988905196cada4a2cc8b8d249a88182 Author: Rusty Russell Date: Mon Oct 8 10:55:29 2007 +1000 KVM: Remove gratuitous casts from lapic.c Since vcpu->apic is of the correct type, there's not need to cast. Signed-off-by: Rusty Russell Signed-off-by: Avi Kivity commit ed6929cf8066cbdf0e9576237d6665fe07b9f719 Author: Rusty Russell Date: Mon Oct 8 10:50:48 2007 +1000 KVM: Hoist kvm_create_lapic() into kvm_vcpu_init() Move kvm_create_lapic() into kvm_vcpu_init(), rather than having svm and vmx do it. And make it return the error rather than a fairly random -ENOMEM. This also solves the problem that neither svm.c nor vmx.c actually handles the error path properly. Signed-off-by: Rusty Russell Signed-off-by: Avi Kivity commit 179576337126bd75c3937fc3ba9ecdbf40206ec1 Author: Rusty Russell Date: Mon Oct 8 10:48:30 2007 +1000 KVM: Add kvm_free_lapic() to pair with kvm_create_lapic() Instead of the asymetry of kvm_free_apic, implement kvm_free_lapic(). And guess what? I found a minor bug: we don't need to hrtimer_cancel() from kvm_main.c, because we do that in kvm_free_apic(). Also: 1) kvm_vcpu_uninit should be the reverse order from kvm_vcpu_init. 2) Don't set apic->regs_page to zero before freeing apic. Signed-off-by: Rusty Russell Signed-off-by: Avi Kivity commit f98bb805217e9f51356fe91e3b1a3675636b7b91 Author: Izik Eidus Date: Tue Oct 2 18:52:55 2007 +0200 KVM: Allow dynamic allocation of the mmu shadow cache size The user is now able to set how many mmu pages will be allocated to the guest. Signed-off-by: Izik Eidus Signed-off-by: Avi Kivity commit a3aa9d5f129928fbe12dac8d18a425cf7ddeb9b6 Author: Izik Eidus Date: Mon Oct 1 22:14:18 2007 +0200 KVM: Add general accessors to read and write guest memory Signed-off-by: Izik Eidus Signed-off-by: Avi Kivity commit 1721129db9eb57da3526d5c35f0a3f4751092fbb Author: Izik Eidus Date: Thu Sep 27 14:11:22 2007 +0200 KVM: Remove the usage of page->private field by rmap When kvm uses user-allocated pages in the future for the guest, we won't be able to use page->private for rmap, since page->rmap is reserved for the filesystem. So we move the rmap base pointers to the memory slot. A side effect of this is that we need to store the gfn of each gpte in the shadow pages, since the memory slot is addressed by gfn, instead of hfn like struct page. Signed-off-by: Izik Eidus Signed-off-by: Avi Kivity commit cdd86a3587294db88cf38087ef86d8a8bd4078b4 Author: Avi Kivity Date: Sun Sep 30 11:02:53 2007 +0200 KVM: VMX: Simplify vcpu_clear() Now that smp_call_function_single() knows how to call a function on the current cpu, there's no need to check explicitly. Signed-off-by: Avi Kivity commit 8d094b4b639ef0d1f13efc4087e2cf7eed18b829 Author: Avi Kivity Date: Sun Sep 30 10:50:12 2007 +0200 KVM: VMX: Don't clear the vmcs if the vcpu is not loaded on any processor Noted by Eddie Dong. Signed-off-by: Avi Kivity commit 9baa931ce679cd86e6f4df65eafe75a624f462e6 Author: Laurent Vivier Date: Tue Sep 25 13:36:40 2007 +0200 KVM: x86 emulator: Any legacy prefix after a REX prefix nullifies its effect This patch modifies the management of REX prefix according behavior I saw in Xen 3.1. In Xen, this modification has been introduced by Jan Beulich. http://lists.xensource.com/archives/html/xen-changelog/2007-01/msg00081.html Signed-off-by: Laurent Vivier Signed-off-by: Avi Kivity commit 356706e476c0c070ab0136d82de40d7f2d5334b0 Author: Laurent Vivier Date: Mon Sep 24 17:00:58 2007 +0200 KVM: Purify x86_decode_insn() error case management The only valid case is on protected page access, other cases are errors. Signed-off-by: Laurent Vivier Signed-off-by: Avi Kivity commit cefc532968a7dda45f3f77a5e9c668d4fbb522e0 Author: Qing He Date: Mon Sep 24 17:22:13 2007 +0800 KVM: x86_emulator: no writeback for bt Signed-off-by: Qing He Signed-off-by: Avi Kivity commit b2a7e15b33e396b90714542ff9da6a2e69faa1ca Author: Laurent Vivier Date: Mon Sep 24 11:10:56 2007 +0200 KVM: x86 emulator: Remove no_wb, use dst.type = OP_NONE instead Remove no_wb, use dst.type = OP_NONE instead, idea stollen from xen-3.1 Signed-off-by: Laurent Vivier Signed-off-by: Avi Kivity commit b9b6d84d9d4e49ce3745114cfceb08169cc0d049 Author: Laurent Vivier Date: Mon Sep 24 11:10:55 2007 +0200 KVM: x86 emulator: remove _eflags and use directly ctxt->eflags. Remove _eflags and use directly ctxt->eflags. Caching eflags is not needed as it is restored to vcpu by kvm_main.c:emulate_instruction() from ctxt->eflags only if emulation doesn't fail. Signed-off-by: Laurent Vivier Signed-off-by: Avi Kivity commit a1d2a0157d8921eef92cbdb932619dc37b8a992b Author: Laurent Vivier Date: Mon Sep 24 11:10:54 2007 +0200 KVM: x86 emulator: split some decoding into functions for readability To improve readability, move push, writeback, and grp 1a/2/3/4/5/9 emulation parts into functions. Signed-off-by: Laurent Vivier Signed-off-by: Avi Kivity commit 076e313e2e111b5fc3aa9f1f419d6344a5d4a6c6 Author: Ryan Harper Date: Tue Sep 18 14:05:16 2007 -0500 KVM: MMU: Ignore reserved bits in cr3 in non-pae mode This patch removes the fault injected when the guest attempts to set reserved bits in cr3. X86 hardware doesn't generate a fault when setting reserved bits. The result of this patch is that vmware-server, running within a kvm guest, boots and runs memtest from an iso. Signed-off-by: Ryan Harper Signed-off-by: Avi Kivity commit 8fb4094e6c7715f7c1bf7c900cdc10c9544790db Author: Avi Kivity Date: Sun Sep 23 14:10:49 2007 +0200 KVM: MMU: Make flooding detection work when guest page faults are bypassed When we allow guest page faults to reach the guests directly, we lose the fault tracking which allows us to detect demand paging. So we provide an alternate mechnism by clearing the accessed bit when we set a pte, and checking it later to see if the guest actually used it. Signed-off-by: Avi Kivity commit 42105992041fbb1420e70440564e737d9217e5c8 Author: Avi Kivity Date: Sun Sep 16 18:58:32 2007 +0200 KVM: Allow not-present guest page faults to bypass kvm There are two classes of page faults trapped by kvm: - host page faults, where the fault is needed to allow kvm to install the shadow pte or update the guest accessed and dirty bits - guest page faults, where the guest has faulted and kvm simply injects the fault back into the guest to handle The second class, guest page faults, is pure overhead. We can eliminate some of it on vmx using the following evil trick: - when we set up a shadow page table entry, if the corresponding guest pte is not present, set up the shadow pte as not present - if the guest pte _is_ present, mark the shadow pte as present but also set one of the reserved bits in the shadow pte - tell the vmx hardware not to trap faults which have the present bit clear With this, normal page-not-present faults go directly to the guest, bypassing kvm entirely. Unfortunately, this trick only works on Intel hardware, as AMD lacks a way to discriminate among page faults based on error code. It is also a little risky since it uses reserved bits which might become unreserved in the future, so a module parameter is provided to disable it. Signed-off-by: Avi Kivity commit c7af157c7c3afb5b7ed9b90fa62f896b7348c7b4 Author: Avi Kivity Date: Wed Aug 29 03:48:05 2007 +0300 KVM: VMX: Further reduce efer reloads KVM avoids reloading the efer msr when the difference between the guest and host values consist of the long mode bits (which are switched by hardware) and the NX bit (which is emulated by the KVM MMU). This patch also allows KVM to ignore SCE (syscall enable) when the guest is running in 32-bit mode. This is because the syscall instruction is not available in 32-bit mode on Intel processors, so the SCE bit is effectively meaningless. Signed-off-by: Avi Kivity commit a7a21db3747f42f0800fc9b36f593ded764eeb31 Author: Laurent Vivier Date: Tue Sep 18 11:27:37 2007 +0200 KVM: Call x86_decode_insn() only when needed Move emulate_ctxt to kvm_vcpu to keep emulate context when we exit from kvm module. Call x86_decode_insn() only when needed. Modify x86_emulate_insn() to not modify the context if it must be re-entered. Signed-off-by: Laurent Vivier Signed-off-by: Avi Kivity commit 4b04b506860b2c93974cfecc1b42966dba9d40c9 Author: Laurent Vivier Date: Tue Sep 18 11:27:27 2007 +0200 KVM: emulate_instruction() calls now x86_decode_insn() and x86_emulate_insn() emulate_instruction() calls now x86_decode_insn() and x86_emulate_insn(). x86_emulate_insn() is x86_emulate_memop() without the decoding part. Signed-off-by: Laurent Vivier Signed-off-by: Avi Kivity commit 768d86be259b4a27d6729bfae8687299b9482b85 Author: Laurent Vivier Date: Tue Sep 18 11:27:19 2007 +0200 KVM: x86 emulator: move all decoding process to function x86_decode_insn() Split the decoding process into a new function x86_decode_insn(). Signed-off-by: Laurent Vivier Signed-off-by: Avi Kivity commit 1186b126c4b2dd19c4cafaf2fed0cf719f70e514 Author: Laurent Vivier Date: Tue Sep 18 11:52:50 2007 +0200 KVM: x86 emulator: move all x86_emulate_memop() to a structure Move all x86_emulate_memop() common variables between decode and execute to a structure decode_cache. This will help in later separating decode and emulate. struct decode_cache { u8 twobyte; u8 b; u8 lock_prefix; u8 rep_prefix; u8 op_bytes; u8 ad_bytes; struct operand src; struct operand dst; unsigned long *override_base; unsigned int d; unsigned long regs[NR_VCPU_REGS]; unsigned long eip; /* modrm */ u8 modrm; u8 modrm_mod; u8 modrm_reg; u8 modrm_rm; u8 use_modrm_ea; unsigned long modrm_ea; unsigned long modrm_val; }; Signed-off-by: Laurent Vivier Signed-off-by: Avi Kivity commit b9faf10e0648cd7aef88e66d514fb25f539c752f Author: Laurent Vivier Date: Tue Sep 18 11:26:38 2007 +0200 KVM: x86 emulator: remove unused functions Remove #ifdef functions never used Signed-off-by: Laurent Vivier Signed-off-by: Avi Kivity commit eccc7af16b268302089c302da84f2f7d99c13164 Author: Anthony Liguori Date: Mon Sep 17 14:57:50 2007 -0500 KVM: Refactor hypercall infrastructure (v3) This patch refactors the current hypercall infrastructure to better support live migration and SMP. It eliminates the hypercall page by trapping the UD exception that would occur if you used the wrong hypercall instruction for the underlying architecture and replacing it with the right one lazily. A fall-out of this patch is that the unhandled hypercalls no longer trap to userspace. There is very little reason though to use a hypercall to communicate with userspace as PIO or MMIO can be used. There is no code in tree that uses userspace hypercalls. [avi: fix #ud injection on vmx] Signed-off-by: Anthony Liguori Signed-off-by: Avi Kivity commit 32b9abd5cfe444dc5ebee1d5d0a560b72f7d17fe Author: Anthony Liguori Date: Mon Sep 17 14:57:49 2007 -0500 KVM: x86 emulator: Add vmmcall/vmcall to x86_emulate (v3) Add vmmcall/vmcall to x86_emulate. Future patch will implement functionality for these instructions. Signed-off-by: Anthony Liguori Signed-off-by: Avi Kivity commit 9bfdd08f0a65e67d0842ca35516669bec523fbe0 Author: Avi Kivity Date: Sat Dec 22 22:14:10 2007 +0200 KVM: MMU: Fix cmpxchg8b emulation on i386 (again) Signed-off-by: Avi Kivity commit 433be519ccd864b860385a03a864b4024b5d2f40 Author: Izik Eidus Date: Thu Dec 20 10:41:39 2007 +0200 KVM: Ensure pages are copied on write Fix userspace memory handling bug related to cow the previous way we called get_user_pages, was without the force flag and therefore it didnt break COW shared pages. This caused host memory corruption when host userspace fork()ed. Signed-off-by: Izik Eidus Signed-off-by: Avi Kivity commit 6fd19d01a523fd82db3867402ed1774589bcf6c1 Author: Avi Kivity Date: Wed Dec 19 12:02:40 2007 +0200 KVM: Print data for unimplemented wrmsr This can help diagnosing what the guest is trying to do. In many cases we can get away with partial emulation of msrs. Signed-off-by: Avi Kivity commit 97dd1569ab4ba6844a08a65cd3bc4e79dc533d38 Author: Avi Kivity Date: Tue Dec 18 19:47:18 2007 +0200 KVM: MMU: Add cache miss statistic Signed-off-by: Avi Kivity commit 89075253714a299236b8debfbfdcb670a3932a1b Author: Eddie Dong Date: Tue Dec 18 06:08:27 2007 +0800 KVM: MMU: Coalesce remote tlb flushes Host side TLB flush can be merged together if multiple spte need to be write-protected. Signed-off-by: Yaozu (Eddie) Dong Signed-off-by: Avi Kivity commit 04e6202e30ecd89c8e48802b64397ebaa55363e9 Author: xiantao.zhang@intel.com Date: Mon Dec 17 20:27:27 2007 +0800 KVM: Expose ioapic to ia64 save/restore APIs IA64 also needs to see ioapic structure in irqchip. Signed-off-by: xiantao.zhang@intel.com Signed-off-by: Avi Kivity commit e4f8524a630ca33c3000263d29acb5c619ee94f0 Author: Zhang Xiantao Date: Mon Dec 17 14:21:40 2007 +0800 KVM: Move kvm_vcpu_kick() to x86.c Moving kvm_vcpu_kick() to x86.c. Since it should be common for all archs, put its declarations in Signed-off-by: Zhang Xiantao Signed-off-by: Avi Kivity commit e9d06906038878357658d316b897d3105cec704e Author: Zhang Xiantao Date: Mon Dec 17 14:16:14 2007 +0800 KVM: Move ioapic code to common directory. Move ioapic code to common, since IA64 also needs it. Signed-off-by: Zhang Xiantao Signed-off-by: Avi Kivity commit 8d4b72100521699e0d2c4295b7ec8fb53f3131c9 Author: Zhang Xiantao Date: Mon Dec 17 13:59:56 2007 +0800 KVM: Move irqchip declarations into new ioapic.h and lapic.h This allows reuse of ioapic in ia64. Signed-off-by: Zhang Xiantao Signed-off-by: Avi Kivity commit 5ca24d96dbc31d7018bc71e355f824f25b70316e Author: Avi Kivity Date: Sun Dec 16 14:09:36 2007 +0200 KVM: Fix compile error in asm/kvm_host.h "types.h" refers to the wrong file. Signed-off-by: Avi Kivity commit 276db3794711c5aff691c75495d6a5327773271f Author: Avi Kivity Date: Sun Dec 16 11:13:16 2007 +0200 KVM: Move drivers/kvm/* to virt/kvm/ Signed-off-by: Avi Kivity commit 327f5d208b042f5228ff2d57054a32f57ab37c2c Author: Avi Kivity Date: Sun Dec 16 11:02:48 2007 +0200 KVM: Move arch dependent files to new directory arch/x86/kvm/ This paves the way for multiple architecture support. Note that while ioapic.c could potentially be shared with ia64, it is also moved. Signed-off-by: Avi Kivity commit 1ca8b98d60891eea9e5083cd40db99bb3715a918 Author: Ryan Harper Date: Thu Dec 13 10:21:10 2007 -0600 KVM: VMX: Add printk_ratelimit in vmx_intr_assist Add printk_ratelimit check in front of printk. This prevents spamming of the message during 32-bit ubuntu 6.06server install. Previously, it would hang during the partition formatting stage. Signed-off-by: Ryan Harper Signed-off-by: Avi Kivity commit c272edd56fd1201238dfe9b29f027249067ed318 Author: Zhang Xiantao Date: Fri Dec 14 10:23:23 2007 +0800 KVM: Portability: Move kvm_vm_stat to x86.h This patch moves kvm_vm_stat to x86.h, and every arch can define its own kvm_vm_stat in $arch.h Signed-off-by: Zhang Xiantao Acked-by: Carsten Otte Signed-off-by: Avi Kivity commit f0950596e4e420583b3b3e6bb168793a5cb483bd Author: Zhang Xiantao Date: Fri Dec 14 10:20:16 2007 +0800 KVM: Portability: Move round_robin_prev_vcpu and tss_addr to kvm_arch This patches moves two fields round_robin_prev_vcpu and tss to kvm_arch. Signed-off-by: Zhang Xiantao Acked-by: Carsten Otte Signed-off-by: Avi Kivity commit e1ff111628bb1cf49ddcaca105304e1cd83e577c Author: Zhang Xiantao Date: Fri Dec 14 10:17:34 2007 +0800 KVM: Portability: move vpic and vioapic to kvm_arch This patches moves two fields vpid and vioapic to kvm_arch Signed-off-by: Zhang Xiantao Acked-by: Carsten Otte Signed-off-by: Avi Kivity commit 4bfe8599b11664e041ff1733cbe43aedf53e054d Author: Zhang Xiantao Date: Fri Dec 14 10:01:48 2007 +0800 KVM: Portability: Move mmu-related fields to kvm_arch This patches moves mmu-related fields to kvm_arch. Signed-off-by: Zhang Xiantao Acked-by: Carsten Otte Signed-off-by: Avi Kivity commit f18af6836ed727e79873cf868a47cbec18e18914 Author: Zhang Xiantao Date: Fri Dec 14 09:54:20 2007 +0800 KVM: Portability: Move memslot aliases to new struct kvm_arch This patches create kvm_arch to hold arch-specific kvm fileds and moves fields naliases and aliases to kvm_arch. Signed-off-by: Zhang Xiantao Acked-by: Carsten Otte Signed-off-by: Avi Kivity commit 5104cf2ffdd47854a00e48fb3a089f107e7f30da Author: Zhang Xiantao Date: Fri Dec 14 09:49:26 2007 +0800 KVM: Portability: Move kvm_vcpu_stat to x86.h This patches moves kvm_vcpu_stat to x86.h, so every arch can define its own kvm_vcpu_stat structure. Signed-off-by: Zhang Xiantao Acked-by: Carsten Otte Signed-off-by: Avi Kivity commit 9edf53496ee757f2c090ba73d49cfd18de3b5b14 Author: Zhang Xiantao Date: Fri Dec 14 09:45:31 2007 +0800 KVM: Portability: Expand the KVM_VCPU_COMM in kvm_vcpu structure. This patches removes KVM_COMM macro, original it is hold kvm_vcpu common fields. Signed-off-by: Zhang Xiantao Acked-by: Carsten Otte Signed-off-by: Avi Kivity commit acd488e9febb97780eab35d5af85fa59a72a295d Author: Zhang Xiantao Date: Fri Dec 14 09:41:22 2007 +0800 KVM: Portability: Move kvm_vcpu definition back to kvm.h This patches moves kvm_vcpu definition to kvm.h, and finally kvm.h includes x86.h. Signed-off-by: Zhang Xiantao Acked-by: Carsten Otte Signed-off-by: Avi Kivity commit 689ab57bf3245a685845f6906f4b47364f11af84 Author: Zhang Xiantao Date: Fri Dec 14 09:35:10 2007 +0800 KVM: Portability: Split mmu-related static inline functions to mmu.h Since these functions need to know the details of kvm or kvm_vcpu structure, it can't be put in x86.h. Create mmu.h to hold them. Signed-off-by: Zhang Xiantao Acked-by: Carsten Otte Signed-off-by: Avi Kivity commit 5b30a22d7c2ced107410de7b912916976e8d951d Author: Zhang Xiantao Date: Thu Dec 13 23:50:52 2007 +0800 KVM: Portability: Introduce kvm_vcpu_arch Move all the architecture-specific fields in kvm_vcpu into a new struct kvm_vcpu_arch. Signed-off-by: Zhang Xiantao Acked-by: Carsten Otte Signed-off-by: Avi Kivity commit e315a28bf3e1e0f3d31231b106198009a152f499 Author: Zhang Xiantao Date: Tue Dec 11 20:36:00 2007 +0800 KVM: Portability: Move kvm{pic,ioapic} accesors to x86 specific code Signed-off-by: Zhang Xiantao Signed-off-by: Avi Kivity commit d5855a0ec163afd591f272e13e1f2c366794306f Author: Avi Kivity Date: Thu Dec 13 14:44:12 2007 +0200 KVM: Another cmpxchg emulation compile fix Signed-off-by: Avi Kivity commit eeb8852f8e8588e77bde5dfbb20808e7ba70105f Author: Avi Kivity Date: Thu Dec 13 14:44:12 2007 +0200 KVM: Another cmpxchg emulation compile fix Signed-off-by: Avi Kivity commit a5e8e8a4f7ddb211d856eb30e93e70af9d51b735 Author: Avi Kivity Date: Thu Dec 13 14:30:28 2007 +0200 KVM: Another cmpxchg i386 compile fix Signed-off-by: Avi Kivity commit eb9270cee7061e5a985eb9eac559270292b1d7ec Author: Avi Kivity Date: Thu Dec 13 14:14:17 2007 +0200 KVM: Make cmpxchg emulation compile on i386 Signed-off-by: Avi Kivity commit 24a673eb377069509e8dad5ff7fa146e363df739 Author: Avi Kivity Date: Thu Dec 13 13:19:04 2007 +0200 KVM: Fix bad kunmap_atomic() paramerter inm cmpxchg emulation Noticed by Uri Lublin Signed-off-by: Avi Kivity commit 9a5ee611ca79bec98e9d97e93f11df8083b8af6e Author: Marcelo Tosatti Date: Wed Dec 12 10:46:12 2007 -0500 KVM: MMU: emulated cmpxchg8b should be atomic on i386 Emulate cmpxchg8b atomically on i386. This is required to avoid a guest pte walker from seeing a splitted write. Signed-off-by: Marcelo Tosatti Signed-off-by: Avi Kivity commit 158be9e5f1af9b04da7b7349328dc466e2220047 Author: Joerg Roedel Date: Wed Dec 12 12:37:24 2007 +0100 KVM: LAPIC: minor debugging compile fix This patch fixes a compile error of the LAPIC code with APIC debugging enabled. Signed-off-by: Joerg Roedel Signed-off-by: Markus Rechberger Signed-off-by: Avi Kivity commit d3a1ec98fe24e8693b794397e533a3d4770f8b09 Author: Marcelo Tosatti Date: Tue Dec 11 19:12:27 2007 -0500 KVM: MMU: Fix SMP shadow instantiation race There is a race where VCPU0 is shadowing a pagetable entry while VCPU1 is updating it, which results in a stale shadow copy. Fix that by comparing the contents of the cached guest pte with the current guest pte after write-protecting the guest pagetable. Signed-off-by: Marcelo Tosatti Signed-off-by: Avi Kivity commit 2018f67db6923910e135b6a8aaf1c9167cfa7f5d Author: Avi Kivity Date: Tue Dec 11 19:23:11 2007 +0200 KVM: MMU: Fix kunmap_atomic() call in cmpxchg_gpte() Signed-off-by: Avi Kivity commit 51ef1ac7b23ee32bfcc61c229d634fdc1c68b38a Author: Joerg Roedel Date: Tue Dec 11 15:36:57 2007 +0100 KVM: SVM: support writing 0 to K8 performance counter control registers This lets SVM ignore writes of the value 0 to the performance counter control registers. Thus enabling them will still fail in the guest, but a write of 0 which keeps them disabled is accepted. This is required to boot Windows Vista 64bit. [avi: avoid fall-thru in switch statement] Signed-off-by: Joerg Roedel Signed-off-by: Markus Rechberger Signed-off-by: Avi Kivity commit ced316df1d44ed441d6268e13500fef2b7ad9bfb Author: Joerg Roedel Date: Thu Dec 6 21:02:25 2007 +0100 KVM: SVM: Exit to userspace if write to cr8 and not using in-kernel apic With this patch KVM on SVM will exit to userspace if the guest writes to CR8 and the in-kernel APIC is disabled. Signed-off-by: Joerg Roedel Signed-off-by: Markus Rechberger Signed-off-by: Avi Kivity commit 3ef4e62ae2a1c0109e20da39e7b42570c59cb3cc Author: Avi Kivity Date: Sun Dec 9 18:43:00 2007 +0200 KVM: MMU: Use mmu_set_spte() for real-mode shadows In addition to removing some duplicated code, this also handles the unlikely case of real-mode code updating a guest page table. This can happen when one vcpu (in real mode) touches a second vcpu's (in protected mode) page tables, or if a vcpu switches to real mode, touches page tables, and switches back. Signed-off-by: Avi Kivity commit d1d1b5649e7e531fe5eac5e218c99289ce5a1a1d Author: Avi Kivity Date: Sun Dec 9 18:39:41 2007 +0200 KVM: MMU: Adjust mmu_set_spte() debug code for gpte removal Signed-off-by: Avi Kivity commit 86a3d6593e8942de664d9999402f3fc28e83c4cd Author: Avi Kivity Date: Sun Dec 9 17:40:31 2007 +0200 KVM: MMU: Move set_pte() into guest paging mode independent code As set_pte() no longer references either a gpte or the guest walker, we can move it out of paging mode dependent code (which compiles twice and is generally nasty). Signed-off-by: Avi Kivity commit 2deb9afd26d79c868f88ff9019f32e1498f1fe6c Author: Avi Kivity Date: Sun Dec 9 17:33:46 2007 +0200 KVM: MMU: Remove walker argument to set_pte() Unused. Signed-off-by: Avi Kivity commit 65d8730b56fc407c26ad725313f8c3acfc16d804 Author: Avi Kivity Date: Sun Dec 9 17:32:30 2007 +0200 KVM: MMU: Pass pte dirty flag to set_pte() instead of calculating it on-site This allows us to remove its dependency on pt_element_t. Signed-off-by: Avi Kivity commit 49b2ab6e5ca086c3e3fa4abc922b296d38e59fb5 Author: Avi Kivity Date: Sun Dec 9 17:27:52 2007 +0200 KVM: MMU: No need to pick up nx bit from guest pte We already set it according to cumulative access permissions. Signed-off-by: Avi Kivity commit ddac3bf3e282a13d74cf61863ea100803cda671d Author: Avi Kivity Date: Sun Dec 9 17:00:02 2007 +0200 KVM: MMU: Fix inherited permissions for emulated guest pte updates When we emulate a guest pte write, we fail to apply the correct inherited permissions from the parent ptes. Now that we store inherited permissions in the shadow page, we can use that to update the pte permissions correctly. Signed-off-by: Avi Kivity commit 10b29d09ceec124d145977ae1e207931825fd755 Author: Avi Kivity Date: Sun Dec 9 16:52:56 2007 +0200 KVM: MMU: Move pte access calculation into a helper function Signed-off-by: Avi Kivity commit 4e2cddf1e56ba13bb44fd035a669f2d7ce1874f7 Author: Avi Kivity Date: Sun Dec 9 16:37:36 2007 +0200 KVM: MMU: Set nx bit correctly on shadow ptes While the page table walker correctly generates a guest page fault if a guest tries to execute a non-executable page, the shadow code does not mark it non-executable. This means that if a guest accesses an nx page first with a read access, then subsequent code fetch accesses will succeed. Fix by setting the nx bit on shadow ptes. Signed-off-by: Avi Kivity commit 4347f30eaf3debcfd2b0d90573930b1b8a7de389 Author: Avi Kivity Date: Sun Dec 9 16:15:46 2007 +0200 KVM: MMU: Simplify calculation of pte access The nx bit is awkwardly placed in the 63rd bit position; furthermore it has a reversed meaning compared to the other bits, which means we can't use a bitwise and to calculate compounded access masks. So, we simplify things by creating a new 3-bit exec/write/user access word, and doing all calculations in that. Signed-off-by: Avi Kivity commit 979158adc73ea573897a1d43f9a6cd4dc13e95d6 Author: Marcelo Tosatti Date: Fri Dec 7 07:56:58 2007 -0500 KVM: MMU: Use cmpxchg for pte updates on walk_addr() In preparation for multi-threaded guest pte walking, use cmpxchg() when updating guest pte's. This guarantees that the assignment of the dirty bit can't be lost if two CPU's are faulting the same address simultaneously. Signed-off-by: Marcelo Tosatti Signed-off-by: Avi Kivity commit 2066ea592f45f4bd2ad2cc0d78b7694b48976105 Author: Avi Kivity Date: Thu Dec 6 21:11:31 2007 +0200 KVM: VMX: Fix cr8 exit optimization Signed-off-by: Avi Kivity commit 9581bd821d8ffe6c5cd4605e8c97e4bce352f1af Author: Avi Kivity Date: Thu Dec 6 19:50:00 2007 +0200 KVM: SVM: Trap access to the cr8 register Later we may be able to use the virtual tpr feature, but for now, just trap it. Signed-off-by: Avi Kivity commit 8893b9252a3256910c184153522cf77940f85cac Author: Avi Kivity Date: Thu Dec 6 18:14:14 2007 +0200 KVM: x86 emulator: Fix stack instructions on 64-bit mode Stack instructions are always 64-bit on 64-bit mode; many of the emulated stack instructions did not take that into account. Fix by adding a 'Stack' bitflag and setting the operand size appropriately during the decode stage (except for 'push r/m', which is in a group with a few other instructions, so it gets its own treatment). This fixes random crashes on Vista x64. Signed-off-by: Avi Kivity commit c8926698e4ee6c5d7661a73aaf92e00d8c1c8d66 Author: Joerg Roedel Date: Thu Dec 6 15:46:52 2007 +0100 KVM: SVM: Emulate read/write access to cr8 This patch adds code to emulate the access to the cr8 register to the x86 instruction emulator in kvm. This is needed on svm, where there is no hardware decode for control register access. Signed-off-by: Joerg Roedel Signed-off-by: Markus Rechberger Signed-off-by: Avi Kivity commit 3224ccab2ad15aa096fa4195a2d0f30722eb6c8c Author: Avi Kivity Date: Thu Dec 6 16:32:45 2007 +0200 KVM: VMX: Avoid exit when setting cr8 if the local apic is in the kernel With apic in userspace, we must exit to userspace after a cr8 write in order to update the tpr. But if the apic is in the kernel, the exit is unnecessary. Noticed by Joerg Roedel. Signed-off-by: Avi Kivity commit 297a0bef8fbad4367abac85d1a976a1cc8d3c8bf Author: Avi Kivity Date: Thu Dec 6 16:15:02 2007 +0200 KVM: x86 emulator: fix eflags preparation for emulation We prepare eflags for the emulated instruction, then clobber it with an 'andl'. Fix by popping eflags as the last thing in the sequence. Patch taken from Xen (16143:959b4b92b6bf) Signed-off-by: Avi Kivity commit ac319e6300d31ccfe0b2a7767c5fcd9385028954 Author: Avi Kivity Date: Sun Nov 25 15:22:50 2007 +0200 KVM: Use generalized exception queue for injecting #UD Signed-off-by: Avi Kivity commit a78abaa8f90d60274ca818f45d4e1abe19da7bc4 Author: Avi Kivity Date: Sun Nov 25 14:12:03 2007 +0200 KVM: Replace #GP injection by the generalized exception queue Signed-off-by: Avi Kivity commit f93ec37e9625b2d60e2f58d0bcc123878b695260 Author: Avi Kivity Date: Sun Nov 25 14:04:58 2007 +0200 KVM: Replace page fault injection by the generalized exception queue Signed-off-by: Avi Kivity commit 39aaaf61fb37a66120928ad4a5b03393f5b8ffe1 Author: Avi Kivity Date: Sun Nov 25 13:41:11 2007 +0200 KVM: Generalize exception injection mechanism Instead of each subarch doing its own thing, add an API for queuing an injection, and manage failed exception injection centerally (i.e., if an inject failed due to a shadow page fault, we need to requeue it). Signed-off-by: Avi Kivity commit d8bb219b4d69baa8f65e934ef830dd742f69c001 Author: Marcelo Tosatti Date: Tue Dec 4 13:42:16 2007 -0500 KVM: MMU: Remove unused prev_shadow_ent variable from fetch() Signed-off-by: Marcelo Tosatti Signed-off-by: Avi Kivity commit 83f9425dc148dbe0d373b7e07f221affff9e91cb Author: npiggin@suse.de Date: Wed Dec 5 18:15:52 2007 +1100 KVM: Convert KVM from ->nopage() to ->fault() Signed-off-by: Nick Piggin Cc: kvm-devel@lists.sourceforge.net Cc: avi@qumranet.com Cc: linux-kernel@vger.kernel.org Signed-off-by: Avi Kivity commit fc424a7c4280adc9335ed92f31772b7df3f85745 Author: Hollis Blanchard Date: Mon Dec 3 16:15:26 2007 -0600 KVM: Portability: Create kvm_arch_vcpu_runnable() function This abstracts the detail of x86 hlt and INIT modes into a function. Signed-off-by: Hollis Blanchard Acked-by: Carsten Otte Signed-off-by: Avi Kivity commit 359306765f53cdc7736e0303c31658239f6df825 Author: Hollis Blanchard Date: Mon Dec 3 15:30:25 2007 -0600 KVM: Portability: Stop including x86-specific headers in kvm_main.c Signed-off-by: Hollis Blanchard Signed-off-by: Avi Kivity commit 3f3c54ebf4d6f3423571be332f7965a7efb327cc Author: Hollis Blanchard Date: Mon Dec 3 15:30:24 2007 -0600 KVM: Portability: Move IO device definitions to its own header file Signed-off-by: Hollis Blanchard Acked-by: Carsten Otte Signed-off-by: Avi Kivity commit 871bc1ede128496f82409b34d94a9e8e977c3cf7 Author: Hollis Blanchard Date: Mon Dec 3 15:30:23 2007 -0600 KVM: Portability: Move address types to their own header file Signed-off-by: Hollis Blanchard Acked-by: Carsten Otte Signed-off-by: Avi Kivity commit efdeac066fbc73cbb4cc2d8c8975192454ea2a50 Author: Zhang Xiantao Date: Sun Dec 2 22:53:07 2007 +0800 KVM: Extend ioapic code to support iosapic iosapic supports an additional mmio EOI register compared to ioapic. Signed-off-by: Zhang Xiantao Signed-off-by: Avi Kivity commit f2601fd2874b94d14dfcb21a3e1b84d7f3262b17 Author: Zhang Xiantao Date: Sun Dec 2 22:49:09 2007 +0800 KVM: Replace dest_Lowest_Prio and dest_Fixed with self-defined macros Change dest_Loest_Prio -> IOAPIC_LOWEST_PRIORITY dest_Fixed -> IOAPIC_FIXED the original names are x86 specific, while the ioapic code will be reused for ia64. Signed-off-by: Zhang Xiantao Signed-off-by: Avi Kivity commit 9a771bb114c3e37b232ed0e798c5c7a59e4f0c4b Author: Zhang Xiantao Date: Sun Dec 2 22:35:57 2007 +0800 KVM: Replace kvm_lapic with kvm_vcpu in ioapic/lapic interface This patch replaces lapic structure with kvm_vcpu in ioapic.c, making ioapic independent of the local apic, as required by ia64. Signed-off-by: Zhang Xiantao Signed-off-by: Avi Kivity commit e8d3621f9f0c209bdb888811a94168e25ea731cd Author: Carlo Marcelo Arenas Belon Date: Sat Dec 1 06:17:11 2007 -0600 KVM: SVM: Remove KVM specific defines for MSR_EFER This patch removes the KVM specific defines for MSR_EFER that were being used in the svm support file and migrates all references to use instead the ones from the kernel headers that are used everywhere else and that have the same values. Signed-off-by: Carlo Marcelo Arenas Belon Signed-off-by: Avi Kivity commit a393444c97f6d7355a6d7d6d7aeb80f1e72472b1 Author: Avi Kivity Date: Sun Dec 2 10:50:06 2007 +0200 KVM: Export include/linux/kvm.h only if $ARCH actually supports KVM Currently, make headers_check barfs due to , which includes, not existing. Rather than add a zillion s, export kvm.h only if the arch actually supports it. Signed-off-by: Avi Kivity commit d535dd00b9fc5b7aadc4229dac9e68fd36381c34 Author: Zhang Xiantao Date: Thu Nov 29 15:35:39 2007 +0800 KVM: Correct kvm_init() error paths not freeing bad_pge. Signed-off-by: Zhang Xiantao Signed-off-by: Avi Kivity commit 16d0ba47ac043733d756e299d7c17b4e1ea72203 Author: Zhang Xiantao Date: Wed Nov 21 04:36:41 2007 +0800 KVM: Portability: Move KVM_INTERRUPT vcpu ioctl to x86.c Other archs doesn't need it. Signed-off-by: Zhang Xiantao Signed-off-by: Avi Kivity commit 71be592a14aa8d127315b2c47bf83cc0d810a341 Author: Avi Kivity Date: Wed Nov 28 18:14:43 2007 +0200 KVM: Don't bypass the mmu if in pae and pdptrs changed Relading cr3 with unchanged values usually means just a tlb flush, but if in pae mode and the pdptrs have changed, we have to reload them. This fixes a Solaris x86 regression. Signed-off-by: Avi Kivity commit ff378422888a8b3ff296e30297fcabf1c831ff83 Author: Avi Kivity Date: Tue Nov 27 19:30:56 2007 +0200 KVM: x86 emulator: unify four switch statements into two Unify the special instruction switch with the regular instruction switch, and the two byte special instruction switch with the regular two byte instruction switch. That makes it much easier to find an instruction or the place an instruction needs to be added in. Signed-off-by: Avi Kivity commit 924894fc582925140ed0648b3ca54af6df69d02e Author: Avi Kivity Date: Tue Nov 27 19:14:21 2007 +0200 KVM: x86 emulator: unify two switches The rep prefix cleanup left two switch () statements next to each other. Unify them. Signed-off-by: Avi Kivity commit 55915c4ddc358f4199f7c14650da1ec998832db8 Author: Avi Kivity Date: Tue Nov 27 19:05:37 2007 +0200 KVM: x86 emulator: Move rep processing before instruction execution Currently rep processing is handled somewhere in the middle of instruction processing. Move it to a sensible place. Signed-off-by: Avi Kivity commit 0d84c92a54aff9ca6f9e25f4551d1af34eb59a8c Author: Avi Kivity Date: Mon Nov 26 18:30:07 2007 +0200 KVM: Fix cpuid2 killing 32-bit guests on non-NX machines KVM_SET_CPUID fails to remove NX when the host doesn't support it, as previous versions do. On the other hand, KVM_SET_CPUID2 removes the feature even though, since we tell userspace about it, it shouldn't be necessary. Swap the two cases. Signed-off-by: Avi Kivity commit d1923b98c89ec7d5fbcd852d07bd987e16aea02a Author: Jerone Young Date: Mon Nov 26 08:33:53 2007 -0600 KVM: Add ifdef in irqchip struct for x86 only structures This patch fixes a small issue where sturctures: kvm_pic_state kvm_ioapic_state are defined inside x86 specific code and may or may not be defined in anyway for other architectures. The problem caused is one cannot compile userspace apps (ex. libkvm) for other archs since a size cannot be determined for these structures. Signed-off-by: Jerone Young Signed-off-by: Avi Kivity commit 282cb7a36798ae74de609538354d92ee9b704ca2 Author: Guillaume Thouvenin Date: Mon Nov 26 13:49:09 2007 +0100 KVM: x86 emulator: cmps instruction Add emulation for the cmps instruction. This lets OpenBSD boot on kvm. Signed-off-by: Guillaume Thouvenin Signed-off-by: Avi Kivity commit 8fc822737d95c85ea1db8a71fd835db11c0bdaa7 Author: Avi Kivity Date: Mon Nov 26 16:10:43 2007 +0200 KVM: x86 emulator: rename REP_REPE_PREFIX Signed-off-by: Avi Kivity commit 259ad7f05da1720f7bf88a00bec795dd7b517810 Author: Izik Eidus Date: Mon Nov 26 14:08:14 2007 +0200 KVM: MMU: mark pages that were inserted to the shadow pages table as accessed Mark guest pages as accessed when removed from the shadow page tables for better lru processing. Signed-off-by: Izik Eidus Signed-off-by: Avi Kivity commit 8a29e7fd6400c8c14f4d8f7650c00a7e514d2829 Author: Avi Kivity Date: Sun Nov 25 17:45:31 2007 +0200 KVM: Remove misleading check for mmio during event injection mmio was already handled in kvm_arch_vcpu_ioctl_run(), so no need to check again. Signed-off-by: Avi Kivity commit 694401697ccd822bb08019731c3ee1bb34323d8e Author: Avi Kivity Date: Fri Nov 23 09:29:11 2007 +0200 KVM: Revert segment_descriptor.h removal Mainline isn't ready for it yet. This reverts commits 9f9d8a265d28fc36cfc4f08af0210d4f8da5b147, 51727a110220681f6f43b005d069e28c58f5d151, 7a819d50439ec2801d9aad5850e76f183360a37a, and d24618db16bd6d6d7ea6129e2de8433416f81823. Reported by Xiantao Zhang. Signed-off-by: Avi Kivity commit 9f9d8a265d28fc36cfc4f08af0210d4f8da5b147 Author: Carsten Otte Date: Thu Nov 22 17:24:01 2007 +0100 KVM: Remove desc.h include in kvm_main.c This patch removes the include of asm/desc.h in kvm_main.c, which is only available for x86 and not needed anymore. Signed-off-by: Carsten Otte Signed-off-by: Avi Kivity commit 8df313eea0f1db990da6798d86b60fc2c2f1b57a Author: Avi Kivity Date: Thu Nov 22 14:16:12 2007 +0200 KVM: x86 emulator: address size and operand size overrides are sticky Current implementation is to toggle, which is incorrect. Patch ported from corresponding Xen code. Signed-off-by: Avi Kivity commit 06ac686984864851df4556dcfe184238a66e71c2 Author: Guillaume Thouvenin Date: Thu Nov 22 11:32:09 2007 +0100 KVM: x86 emulator: Make a distinction between repeat prefixes F3 and F2 cmps and scas instructions accept repeat prefixes F3 and F2. So in order to emulate those prefixed instructions we need to be able to know if prefixes are REP/REPE/REPZ or REPNE/REPNZ. Currently kvm doesn't make this distinction. This patch introduces this distinction. Signed-off-by: Guillaume Thouvenin Signed-off-by: Avi Kivity commit 368170736f3fa12d2c4846f01c5c2aaac19a22d6 Author: Zhang Xiantao Date: Thu Nov 22 11:20:33 2007 +0800 KVM: Portability: Move unalias_gfn to arch dependent file Non-x86 archs don't need this mechanism. Move it to arch, and keep its interface in common. Signed-off-by: Zhang Xiantao Acked-by: Carsten Otte Signed-off-by: Avi Kivity commit cad4dbe630b663d1d21f928984fd170595aef498 Author: Sheng Yang Date: Wed Nov 21 14:33:25 2007 +0800 KVM: VMX: Remove the secondary execute control dependency on irqchip The state of SECONDARY_VM_EXEC_CONTROL shouldn't depend on in-kernel IRQ chip, this patch fix this. Signed-off-by: Sheng Yang Signed-off-by: Avi Kivity commit bf3cee1783e143e4d24423bea59caa5f874cfc92 Author: Avi Kivity Date: Thu Nov 22 12:18:10 2007 +0200 KVM: x86 emulator: Fix instruction fetch cache hit check Signed-off-by: Avi Kivity commit 316bd49570ab7b1812bdd954ccd59ad8bc9e9ddc Author: Avi Kivity Date: Thu Nov 22 11:42:59 2007 +0200 KVM: Fix faults during injection of real-mode interrupts If vmx fails to inject a real-mode interrupt while fetching the interrupt redirection table, it fails to record this in the vectoring information field. So we detect this condition and do it ourselves. Signed-off-by: Avi Kivity commit 8fd969cf9a7fca9d4599b839e1995a6403d5a69e Author: Avi Kivity Date: Thu Nov 22 11:30:47 2007 +0200 KVM: VMX: Read & store IDT_VECTORING_INFO_FIELD We'll want to write to it in order to fix real-mode irq injection problems, but it is a read-only field. Storing it in a variable solves that issue. Signed-off-by: Avi Kivity commit 51727a110220681f6f43b005d069e28c58f5d151 Author: Avi Kivity Date: Wed Nov 21 19:17:33 2007 +0200 KVM: Fix compile error on i386 Signed-off-by: Avi Kivity commit 7a819d50439ec2801d9aad5850e76f183360a37a Author: Avi Kivity Date: Wed Nov 21 18:35:55 2007 +0200 KVM: Remove segment_descriptor, part 2 Turns out there was another definition somewhere else. Signed-off-by: Avi Kivity commit d24618db16bd6d6d7ea6129e2de8433416f81823 Author: Avi Kivity Date: Wed Nov 21 17:34:40 2007 +0200 KVM: Replace private 'struct segment descriptor' by x86's desc_struct Signed-off-by: Avi Kivity commit 57d03e8414672b5730ef7e11bfc8412219ec1553 Author: Dan Kenigsberg Date: Wed Nov 21 17:10:04 2007 +0200 KVM: Enhance guest cpuid management The current cpuid management suffers from several problems, which inhibit passing through the host feature set to the guest: - No way to tell which features the host supports While some features can be supported with no changes to kvm, others need explicit support. That means kvm needs to vet the feature set before it is passed to the guest. - No support for indexed or stateful cpuid entries Some cpuid entries depend on ecx as well as on eax, or on internal state in the processor (running cpuid multiple times with the same input returns different output). The current cpuid machinery only supports keying on eax. - No support for save/restore/migrate The internal state above needs to be exposed to userspace so it can be saved or migrated. This patch adds extended cpuid support by means of three new ioctls: - KVM_GET_SUPPORTED_CPUID: get all cpuid entries the host (and kvm) supports - KVM_SET_CPUID2: sets the vcpu's cpuid table - KVM_GET_CPUID2: gets the vcpu's cpuid table, including hidden state Signed-off-by: Dan Kenigsberg Signed-off-by: Avi Kivity commit 2a4922c0219e85b2acd92b69644864baa20b2e96 Author: Avi Kivity Date: Wed Nov 21 16:41:05 2007 +0200 KVM: Disallow fork() and similar games when using a VM We don't want the meaning of guest userspace changing under our feet. Signed-off-by: Avi Kivity commit a96b251aa077206f06481c94f8a0791b3cebf3a8 Author: Avi Kivity Date: Wed Nov 21 15:32:41 2007 +0200 KVM: MMU: Rename 'release_page' Rename the awkwardly named variable. Signed-off-by: Avi Kivity commit 000e8b3948c9e3eebc133e585381ec6819d545c5 Author: Avi Kivity Date: Wed Nov 21 15:28:32 2007 +0200 KVM: MMU: Rename variable of type 'struct kvm_mmu_page *' These are traditionally named 'page', but even more traditionally, that name is reserved for variables that point to a 'struct page'. Rename them to 'sp' (for "shadow page"). Signed-off-by: Avi Kivity commit eff7b4c194c24bea98d1f3460ea99b57ffcd7708 Author: Avi Kivity Date: Wed Nov 21 15:01:44 2007 +0200 KVM: Remove gpa_to_hpa() Converting last uses along the way. Signed-off-by: Avi Kivity commit ee4d8423330ef532cad2f7eb08e1c756eb8ba1c6 Author: Avi Kivity Date: Wed Nov 21 14:57:44 2007 +0200 KVM: MMU: Remove gva_to_hpa() No longer used. Signed-off-by: Avi Kivity commit 4a5a77187742a411111394d0ad4ddf463e8eb5f7 Author: Avi Kivity Date: Wed Nov 21 14:54:16 2007 +0200 KVM: MMU: Simplify nonpaging_map() Instead of passing an hpa, pass a regular struct page. Signed-off-by: Avi Kivity commit 2847f40d0f9ca46ce5a6e090f6ba73cec51082cf Author: Avi Kivity Date: Wed Nov 21 14:44:45 2007 +0200 KVM: MMU: Introduce gfn_to_gpa() Converting a frame number to an address is tricky since the data type changes size. Introduce a function to do it. This fixes an actual bug when accessing guest ptes. Signed-off-by: Avi Kivity commit 0c621b19fab7f7dcd859ec4f159accd5145461df Author: Avi Kivity Date: Wed Nov 21 14:20:22 2007 +0200 KVM: MMU: Adjust page_header_update_slot() to accept a gfn instead of a gpa Signed-off-by: Avi Kivity commit 0a2c38f403b2be6cfb1bd63eff7baa4004463c0f Author: Avi Kivity Date: Wed Nov 21 14:16:30 2007 +0200 KVM: MMU: Merge set_pte() and set_pte_common() Since set_pte() is now the only caller of set_pte_common(), merge the two functions. Signed-off-by: Avi Kivity commit f1336a6a39c8afb430e7673c31bf279186c12910 Author: Avi Kivity Date: Wed Nov 21 14:11:49 2007 +0200 KVM: MMU: Remove set_pde() It is now identical to set_pte(). Signed-off-by: Avi Kivity commit 3aafe8270b660e947d6f7d5feba6f706bca96140 Author: Avi Kivity Date: Wed Nov 21 14:08:40 2007 +0200 KVM: MMU: Remove extra gaddr parameter from set_pte_common() Similar information is available in the gfn parameter, so use that. Signed-off-by: Avi Kivity commit ef44f09e80ff7d68b0dbe2d58b210079fe8990a0 Author: Avi Kivity Date: Wed Nov 21 13:54:47 2007 +0200 KVM: MMU: Move pse36 handling to the guest walker Signed-off-by: Avi Kivity commit 1916b5e84c3dfa5fd085f4c3e98a4a700693c4e4 Author: Avi Kivity Date: Wed Nov 21 12:35:07 2007 +0200 KVM: MMU: Introduce and use gpte_to_gfn() Instead of repretitively open-coding this. Signed-off-by: Avi Kivity commit 45b905fe748de97264edf476b011fece80e3f343 Author: Izik Eidus Date: Tue Nov 20 12:02:12 2007 +0200 KVM: MMU: Code cleanup Signed-off-by: Izik Eidus Signed-off-by: Avi Kivity commit 76559d9ad5324f466289c493d473259cd095fea0 Author: Avi Kivity Date: Wed Nov 21 02:57:59 2007 +0200 KVM: Don't bother the mmu if cr3 load doesn't change cr3 If the guest requests just a tlb flush, don't take the vm lock and drop the mmu context pointlessly. Signed-off-by: Avi Kivity commit 798d6e84e6936206bfd9db9426ffb3687673b3c3 Author: Avi Kivity Date: Wed Nov 21 02:07:27 2007 +0200 KVM: Add parentheses to silence gcc Signed-off-by: Avi Kivity commit d07badf24aea04516a84676c08d5e0d4073363e8 Author: Avi Kivity Date: Wed Nov 21 02:06:21 2007 +0200 KVM: MMU: Avoid unnecessary remote tlb flushes when guest updates a pte If all we're doing is increasing permissions on a pte (typical for demand paging), then there's not need to flush remote tlbs. Worst case they'll get a spurious page fault. Signed-off-by: Avi Kivity commit 277eec7b001e006fcc21058d9b54dd5eda5c6d06 Author: Avi Kivity Date: Tue Nov 20 23:01:14 2007 +0200 KVM: Add statistic for remote tlb flushes Signed-off-by: Avi Kivity commit c91b40158f97160c5595a9c3a8829e49c298e7dd Author: Avi Kivity Date: Tue Nov 20 21:39:54 2007 +0200 KVM: MMU: Implement guest page fault bypass for nonpae I spent an hour worrying why I see so many guest page faults on FC6 i386. Turns out bypass wasn't implemented for nonpae. Implement it so it doesn't happen again. Signed-off-by: Avi Kivity commit 99040d8a4d9e4e6a49263e71d1832d360561a4e6 Author: Avi Kivity Date: Tue Nov 20 15:30:24 2007 +0200 KVM: Split vcpu creation to avoid vcpu_load() before preemption setup Split kvm_arch_vcpu_create() into kvm_arch_vcpu_create() and kvm_arch_vcpu_setup(), enabling preemption notification between the two. This mean that we can now do vcpu_load() within kvm_arch_vcpu_setup(). Signed-off-by: Avi Kivity commit fed1ca74c178299ab544795064d1c2636cbe78a9 Author: Zhang Xiantao Date: Tue Nov 20 16:25:04 2007 +0800 KVM: Portability: Split kvm_set_memory_region() to have an arch callout Moving !user_alloc case to kvm_arch to avoid unnecessary code logic in non-x86 platform. Signed-off-by: Zhang Xiantao Signed-off-by: Avi Kivity commit 3e2a2eca6961927778bb69d559a40183a85910c3 Author: Zhang Xiantao Date: Tue Nov 20 13:11:38 2007 +0800 KVM: Recalculate mmu pages needed for every memory region change Instead of incrementally changing the mmu cache size for every memory slot operation, recalculate it from scratch. This is simpler and safer. Signed-off-by: Zhang Xiantao Signed-off-by: Avi Kivity commit 90557b67ec617449792f4ca4181d874edce14bea Author: Amit Shah Date: Mon Nov 19 17:57:35 2007 +0200 KVM: SVM: Fix FPU leak and re-enable lazy FPU switching The clts code didn't use set_cr0 properly, so our lazy FPU processing wasn't being done by the clts instruction at all. This fixes all the FPU leaks, so re-enabling lazy FPU optimization. Signed-off-by: Amit Shah Signed-off-by: Avi Kivity commit 20046029f8b71bf0ed949542e5eecb3607619511 Author: Avi Kivity Date: Tue Nov 20 13:15:52 2007 +0200 KVM: x86 emulator: prefetch up to 15 bytes of the instruction executed Instead of fetching one byte at a time, prefetch 15 bytes (or until the next page boundary) to avoid guest page table walks. Signed-off-by: Avi Kivity commit 4df10721942bbdf93e4c7c168e775000a66fce00 Author: Avi Kivity Date: Tue Nov 20 12:49:31 2007 +0200 KVM: x86 emulator: retire ->write_std() Theoretically used to acccess memory known to be ordinary RAM, it was never implemented. It is questionable whether it is possible to implement it correctly. Signed-off-by: Avi Kivity commit 8afc7a0f22d7c5d8f5cbc3f0cfb0cd3d2bc66605 Author: Izik Eidus Date: Tue Nov 20 11:49:33 2007 +0200 KVM: MMU: Selectively set PageDirty when releasing guest memory Improve dirty bit setting for pages that kvm release, until now every page that we released we marked dirty, from now only pages that have potential to get dirty we mark dirty. Signed-off-by: Izik Eidus Signed-off-by: Avi Kivity commit 86faf46a83fdf65c90aa87ff3e27509436db97ed Author: Izik Eidus Date: Tue Nov 20 11:30:04 2007 +0200 KVM: MMU: Fix potential memory leak with smp real-mode When we map a page, we check whether some other vcpu mapped it for us and if so, bail out. But we should decrease the refcount on the page as we do so. Signed-off-by: Izik Eidus Signed-off-by: Avi Kivity commit cc02b6a48c18507ab445000cfd2ef17724c39a7b Author: Avi Kivity Date: Tue Nov 20 11:45:14 2007 +0200 KVM: Export include/asm-x86/kvm.h Signed-off-by: Avi Kivity commit b92527793d12ce0f412cfe67aff959b1047ff255 Author: Jerone Young Date: Mon Nov 19 17:06:37 2007 -0600 KVM: Portability: Move cpuid structures to This patch moves structures: kvm_cpuid_entry kvm_cpuid from include/linux/kvm.h to include/asm-x86/kvm.h Signed-off-by: Jerone Young Signed-off-by: Avi Kivity commit ea36fb9556c5cf3121fd8cfb30f273c384a44cb4 Author: Jerone Young Date: Mon Nov 19 17:06:36 2007 -0600 KVM: Portability: Move kvm_sregs and msr structures to Move structures: kvm_sregs kvm_msr_entry kvm_msrs kvm_msr_list from include/linux/kvm.h to include/asm-x86/kvm.h Signed-off-by: Avi Kivity commit 7cf1d50b5293d7b505e2c4ecae4c52e42d08383e Author: Jerone Young Date: Mon Nov 19 17:06:35 2007 -0600 KVM: Portability: Move kvm_segment & kvm_dtable structure to This patch moves structures: kvm_segment kvm_dtable from include/linux/kvm.h to include/asm-x86/kvm.h Signed-off-by: Jerone Young Signed-off-by: Avi Kivity commit bf1b9719c3cd2744e8e1c61c9f710339062e82b1 Author: Jerone Young Date: Mon Nov 19 17:06:34 2007 -0600 KVM: Portability: Move structure lapic_state to This patch moves structure lapic_state from include/linux/kvm.h to include/asm-x86/kvm.h Signed-off-by: Jerone Young Signed-off-by: Avi Kivity commit 139a72a019300db50cc0bbff3f08fae182ad5295 Author: Jerone Young Date: Mon Nov 19 17:06:33 2007 -0600 KVM: Portability: Move kvm_regs to This patch moves structure kvm_regs to include/asm-x86/kvm.h. Each architecture will need to create there own version of this structure. Signed-off-by: Jerone Young Signed-off-by: Avi Kivity commit 6d441a253607c9d753c002fa8384ab864d15493d Author: Jerone Young Date: Mon Nov 19 17:06:32 2007 -0600 KVM: Portability: Move x86 pic strutctures This patch moves structures: kvm_pic_state kvm_ioapic_state to inclue/asm-x86/kvm.h. Signed-off-by: Jerone Young Signed-off-by: Avi Kivity commit 7bb420c0b02bff8a555a55cf8f0c181f80ece640 Author: Jerone Young Date: Mon Nov 19 17:06:31 2007 -0600 KVM: Portability: Move kvm_memory_alias to asm/kvm.h This patch moves sturct kvm_memory_alias from include/linux/kvm.h to include/asm-x86/kvm.h. Also have include/linux/kvm.h include include/asm/kvm.h. Signed-off-by: Jerone Young Signed-off-by: Avi Kivity commit 2f89106aa04dbc1ea5128734e5851eafb599570b Author: Hollis Blanchard Date: Mon Nov 19 14:04:44 2007 -0600 KVM: Move misplaced comment Signed-off-by: Hollis Blanchard Signed-off-by: Avi Kivity commit 1ac3d1e5a5d87d0f92b324ae8e4022d1a79e5342 Author: Hollis Blanchard Date: Mon Nov 19 14:04:43 2007 -0600 KVM: Correct consistent typo: "destory" -> "destroy" Signed-off-by: Hollis Blanchard Signed-off-by: Avi Kivity commit 15aab1f1b230180fa281861f4f3f502f97ec4ac1 Author: Hollis Blanchard Date: Mon Nov 19 14:04:45 2007 -0600 KVM: Remove unused "rmap_overflow" variable Signed-off-by: Hollis Blanchard Signed-off-by: Avi Kivity commit e724f7e84ce40f4284f428e1766cc49b2712be4e Author: Avi Kivity Date: Mon Nov 19 18:44:15 2007 +0200 KVM: MMU: Remove unused variable Signed-off-by: Avi Kivity commit 1f4870283a5a27992a48a831bf4efcfea0f12c3f Author: Avi Kivity Date: Mon Nov 19 18:28:09 2007 +0200 KVM: Add missing #include Needed for empty_zero_page. Signed-off-by: Avi Kivity commit aa79833baa1491d6f8ed0158045eb92736194672 Author: Izik Eidus Date: Mon Nov 19 11:16:57 2007 +0200 kvm: simplify kvm_clear_guest_page() Use kvm_write_guest_page() with empty_zero_page, instead of doing kmap and memset. Signed-off-by: Izik Eidus Signed-off-by: Avi Kivity commit 6589612b279ac8fc98dc32c2beaccaf73a123db3 Author: Izik Eidus Date: Mon Nov 19 11:28:19 2007 +0200 KVM: MMU: Change guest pte access to kvm_{read,write}_guest() Things are simpler and more regular this way. Signed-off-by: Izik Eidus Signed-off-by: Avi Kivity commit 9fbcc4a1b7cf873a5aa1a357320fb82d588aa316 Author: Jan Kiszka Date: Mon Nov 19 10:21:45 2007 +0100 KVM: VMX: Force seg.base == (seg.sel << 4) in real mode Ensure that segment.base == segment.selector << 4 when entering the real mode on Intel so that the CPU will not bark at us. This fixes some old protected mode demo from http://www.x86.org/articles/pmbasics/tspec_a1_doc.htm. Signed-off-by: Jan Kiszka Signed-off-by: Avi Kivity commit 3f3b5523cbea87a7f5fb956d6d9934db8906c720 Author: Zhang Xiantao Date: Mon Nov 19 15:24:28 2007 +0800 KVM: Portability: Move some function declarations to x86.h Signed-off-by: Zhang Xiantao Signed-off-by: Avi Kivity commit 52377f9e6e1b698819778db98c0c849becefacaa Author: Zhang Xiantao Date: Mon Nov 19 15:08:31 2007 +0800 KVM: Move some static inline functions out from kvm.h into x86.h Signed-off-by: Zhang Xiantao Signed-off-by: Avi Kivity commit f71f7978a42662d1334eab5e4247dd62f801c627 Author: Zhang Xiantao Date: Mon Nov 19 14:56:05 2007 +0800 KVM: Portability: Move vcpu regs enumeration definition to x86.h Signed-off-by: Zhang Xiantao Signed-off-by: Avi Kivity commit e165cb34cb45b847a091037d8063e215f0aab839 Author: Zhang Xiantao Date: Mon Nov 19 14:40:47 2007 +0800 KVM: Portability: Move struct kvm_x86_ops definition to x86.h Signed-off-by: Zhang Xiantao Signed-off-by: Avi Kivity commit 5f45b1657504e8bc4c2a75ed4a320bb6ef230722 Author: Zhang Xiantao Date: Mon Nov 19 14:33:37 2007 +0800 KVM: Portability: Move some macro definitions from kvm.h to x86.h Signed-off-by: Zhang Xiantao Signed-off-by: Avi Kivity commit 67935bd1f29066d71fcc90b95ca80317d4a61114 Author: Zhang Xiantao Date: Sun Nov 18 20:43:21 2007 +0800 KVM: Portability: MMU initialization and teardown split Move out kvm_mmu init and exit functionality from kvm_main.c Signed-off-by: Zhang Xiantao Signed-off-by: Avi Kivity commit 655f2b2de26803d94285ca632dbb7a65939a52e9 Author: Zhang Xiantao Date: Sun Nov 18 20:29:43 2007 +0800 KVM: Portability: Move kvm_vcpu_ioctl_get_dirty_log to arch-specific file Meanwhile keep the interface in common, and leave as more logic in common as possible. Signed-off-by: Zhang Xiantao Signed-off-by: Avi Kivity commit 3fbf24b10ff70174876626caf67090a8b82d1c3d Author: Amit Shah Date: Sun Nov 18 22:42:47 2007 +0530 KVM: SVM: Disable Lazy FPU optimization Host FPU state is leaked into the guest FPU state. This happens because of the lazy FPU optimization, so just reload the FPU each time there's a VM exit/entry. The real fix should follow soon. This is observed in cases where fonts in a guest aren't rendered correctly (bug 1807560). The test program, courtesy Avi is: double test_fpu_once() { int i; double f = 0; for (i = 0; i < 10000000; ++i) f += 1 / (1.0 + i); return f; } void test_fpu() { double a, b; int runs; runs = 0; a = test_fpu_once(); while (1) { b = test_fpu_once(); if (fabs(a - b) > 1e-9) printf("error: %20.16f -> %20.16f\n", a, b); a = b; if (++runs % 100 == 0) printf("runs: %8d\n", runs); } } int main(int ac, char **av) { test_fpu(); return 0; } Run this on the host and the guest, both pinned to the same host CPU. Signed-off-by: Amit Shah Signed-off-by: Avi Kivity commit 15aa6fbcd5908038d328eea250c282b2224cff1d Author: Amit Shah Date: Thu Nov 15 18:38:46 2007 +0200 KVM: Make unloading of FPU state when putting vcpu arch-independent Instead of having each architecture do it individually, we do this in the arch-independent code (just x86 as of now). Turns out SVM did not do this at all. Signed-off-by: Amit Shah Signed-off-by: Avi Kivity commit 3fefa5b661688e3f82179047047b98a27b1255ac Author: Amit Shah Date: Sun Nov 18 22:25:40 2007 +0530 KVM: x86 emulator: Use emulator_write_emulated and not emulator_write_std emulator_write_std() is not implemented, and calling write_emulated should work just as well in place of write_std. Fixes emulator failures with the push r/m instruction. Signed-off-by: Amit Shah Signed-off-by: Avi Kivity commit 90af65e22b7ef28aa0dc6d16ff42dee1b5329a82 Author: Avi Kivity Date: Sun Nov 18 16:37:07 2007 +0200 KVM: MMU: Add some mmu statistics Signed-off-by: Avi Kivity commit 65bee3dea12864c90e59985802b38b5d1726e411 Author: Avi Kivity Date: Sun Nov 18 16:24:12 2007 +0200 KVM: Extend stats support for VM stats This is in addition to the current virtual cpu statistics. Signed-off-by: Avi Kivity commit d600e85f82c9da9641dfd593c70706dc398a6a35 Author: Avi Kivity Date: Sun Nov 18 15:17:51 2007 +0200 KVM: Add instruction emulation statistics commit 5b355c536b29219696ebd62c05ed6b62a209e19d Author: Avi Kivity Date: Sun Nov 18 13:54:33 2007 +0200 KVM: Add fpu_reload counter Measure the number of times we switch the fpu state. Signed-off-by: Avi Kivity commit 3ceafc84da4130359f38a6c9870e8d434eca75cb Author: Avi Kivity Date: Sun Nov 18 13:50:24 2007 +0200 KVM: Replace 'light_exits' stat with 'host_state_reload' This is a little more accurate (since it counts actual reloads, not potential reloads), and reverses the sense of the statistic to measure a bad event like most of the other stats (e.g. we want to minimize all counters). Signed-off-by: Avi Kivity commit 070b3d6d8c2d62af9331d64a26a7abb0bc215329 Author: Zhang Xiantao Date: Sun Nov 18 18:43:45 2007 +0800 KVM: Portability: Add two hooks to handle kvm_create and destroy vm Add two arch hooks to handle kvm_create_vm and kvm destroy_vm. Now, just put io_bus init and destory in common. Signed-off-by: Zhang Xiantao Signed-off-by: Avi Kivity commit b99467ab695205c63a0614dc3a33559a9dc98c60 Author: Zhang Xiantao Date: Fri Nov 16 14:38:21 2007 +0800 KVM: Remove __init attributes for kvm_init_debug and kvm_init_msr_list Since their callers are not declared with __init. Signed-off-by: Zhang Xiantao Signed-off-by: Avi Kivity commit d0399b219b6ded177f7ddef7cf69ba3c0a94e5af Author: Joe Perches Date: Mon Nov 12 20:06:51 2007 -0800 KVM: Remove ptr comparisons to 0 Fix sparse warnings "Using plain integer as NULL pointer" Signed-off-by: Joe Perches Signed-off-by: Avi Kivity commit ebc1a8eca279a2387248d1950cc66fff9f6f6e67 Author: Sheng Yang Date: Fri Nov 16 16:29:15 2007 +0800 KVM: x86 emulator: Rename 'cr2' to 'memop' Previous patches have removed the dependency on cr2; we can now stop passing it to the emulator and rename uses to 'memop'. Signed-off-by: Sheng Yang Signed-off-by: Avi Kivity commit c3763adbd51d15ac1a158c4d51314237ee5be6ff Author: Zhang Xiantao Date: Fri Nov 16 13:05:55 2007 +0800 KVM: Portability: Make kvm_vcpu_ioctl_translate arch dependent Move kvm_vcpu_ioctl_translate to arch, since mmu would be put under arch. Signed-off-by: Zhang Xiantao Signed-off-by: Avi Kivity commit aed946861467c0ded1e10c6f18a0b39f503addf2 Author: Avi Kivity Date: Thu Nov 15 18:06:18 2007 +0200 KVM: VMX: Consolidate register usage in vmx_vcpu_run() We pass vcpu, vmx->fail, and vmx->launched to assembly code, but all three are fields within vmx. Consolidate by only passing in vmx and offsets for the rest. Signed-off-by: Avi Kivity commit e42ff0b65e30b0b2f8c022e113d0c6fd607d4eef Author: Zhang Xiantao Date: Thu Nov 15 23:07:47 2007 +0800 KVM: Portability: move KVM_CHECK_EXTENSION Make KVM_CHECK_EXTENSION code into a function, all archs can define its capability independently. Signed-off-by: Zhang Xiantao Acked-by: Carsten Otte Signed-off-by: Avi Kivity commit 8cdbd1f3f0b5d9599fd834de2000d2286ee05931 Author: Sheng Yang Date: Thu Nov 15 14:52:28 2007 +0800 KVM: x86 emulator: modify 'lods', and 'stos' not to depend on CR2 The current 'lods' and 'stos' is depending on incoming CR2 rather than decode memory address from registers. Signed-off-by: Sheng Yang Signed-off-by: Avi Kivity commit e29c6434dcc64992a84e1a34a16ccfc9fd623621 Author: Zhang Xiantao Date: Wed Nov 14 20:40:21 2007 +0800 KVM: Portability: Move x86 specific code from kvm_init() to kvm_arch() Signed-off-by: Zhang Xiantao Acked-by: Carsten Otte Signed-off-by: Avi Kivity commit 5b6ea43200c02c08b60123a5478a981e0ede7b99 Author: Zhang Xiantao Date: Wed Nov 14 20:39:31 2007 +0800 KVM: Portability: Combine kvm_init and kvm_init_x86 Will be called once arch module registers itself. Signed-off-by: Zhang Xiantao Acked-by: Carsten Otte Signed-off-by: Avi Kivity commit c981fc179788d3bd7e6ccdc285774f5fee569045 Author: Zhang Xiantao Date: Wed Nov 14 20:38:21 2007 +0800 KVM: Portability: Add vcpu and hardware management arch hooks Add the following hooks: void decache_vcpus_on_cpu(int cpu); int kvm_arch_vcpu_init(struct kvm_vcpu *vcpu); void kvm_arch_vcpu_uninit(struct kvm_vcpu *vcpu); void kvm_arch_vcpu_free(struct kvm_vcpu *vcpu); void kvm_arch_vcpu_load(struct kvm_vcpu *vcpu, int cpu); void kvm_arch_vcpu_put(struct kvm_vcpu *vcpu); struct kvm_vcpu *kvm_arch_vcpu_create(struct kvm *kvm, unsigned int id); void kvm_arch_vcpu_destory(struct kvm_vcpu *vcpu); int kvm_arch_vcpu_reset(struct kvm_vcpu *vcpu); void kvm_arch_hardware_enable(void *garbage); void kvm_arch_hardware_disable(void *garbage); int kvm_arch_hardware_setup(void); void kvm_arch_hardware_unsetup(void); void kvm_arch_check_processor_compat(void *rtn); Signed-off-by: Zhang Xiantao Signed-off-by: Avi Kivity commit e402df0a544e9160ab68b1c666789f7007c66327 Author: Zhang Xiantao Date: Wed Nov 14 20:09:30 2007 +0800 KVM: Portability: Move kvm_x86_ops to x86.c Signed-off-by: Zhang Xiantao Acked-by: Carsten Otte Signed-off-by: Avi Kivity commit 744060c59e5ad694721a8503c9416cdeb5411cdc Author: Zhang Xiantao Date: Wed Nov 14 20:08:51 2007 +0800 KVM: Portability: Move some includes to x86.c Move some includes to x86.c from kvm_main.c, since the related functions have been moved to x86.c Signed-off-by: Zhang Xiantao Acked-by: Carsten Otte Signed-off-by: Avi Kivity commit 7ee0b303e266990a54a26804d94bc24f649efcf9 Author: Izik Eidus Date: Sun Nov 11 22:10:22 2007 +0200 KVM: Change kvm_{read,write}_guest() to use copy_{from,to}_user() This changes kvm_write_guest_page/kvm_read_guest_page to use copy_to_user/read_from_user, as a result we get better speed and better dirty bit tracking. Signed-off-by: Izik Eidus Signed-off-by: Avi Kivity commit e8906e9fe7bc376f7d89ad089a19339fe83838a4 Author: Izik Eidus Date: Sun Nov 11 22:05:04 2007 +0200 KVM: introduce gfn_to_hva() Convert a guest frame number to the corresponding host virtual address. Signed-off-by: Izik Eidus Signed-off-by: Avi Kivity commit c94fd678cc5aaa7ef62051e42199576c563c0118 Author: Izik Eidus Date: Sun Nov 11 22:02:22 2007 +0200 KVM: add kvm_is_error_hva() Check for the "error hva", an address outside the user address space that signals a bad gfn. Signed-off-by: Izik Eidus Signed-off-by: Avi Kivity commit f81fa4f8c6759d70f70cb93f802e8b5b7ee3b31c Author: Avi Kivity Date: Sun Nov 11 18:37:32 2007 +0200 KVM: Simplify CPU_TASKS_FROZEN cpu notifier handling Signed-off-by: Avi Kivity commit a798c61d96780e45f8489f9b0dce93c313edb814 Author: Izik Eidus Date: Sun Nov 11 14:48:17 2007 +0200 KVM: x86 emulator: remove 8 bytes operands emulator for call near instruction it is removed beacuse it isnt supported on a real host Signed-off-by: Izik Eidus Signed-off-by: Avi Kivity commit d452efc6f43bbc9e945720ac8ea36461c514001a Author: Izik Eidus Date: Sun Nov 11 14:46:34 2007 +0200 KVM: x86 emulator: fix the saving of of the eip value this make sure that no matter what is the operand size, all the value of the eip will be saved Signed-off-by: Izik Eidus Signed-off-by: Avi Kivity commit f4e63bc2d9a7e0bad6209fe6ec95fda4ad2f3e9c Author: Izik Eidus Date: Sun Nov 11 14:40:48 2007 +0200 KVM: x86 emulator: fix JMP_REL Change JMP_REL to call to register_address_increment(): the operands size should not effect the calculation of the eip, instead the ad_bytes should affect it. Signed-off-by: Izik Eidus Signed-off-by: Avi Kivity commit 495dcb4309e309d9ec42dc471b1548c09a359ed8 Author: Eddie Dong Date: Sun Nov 11 12:28:35 2007 +0200 KVM: VMX: wbinvd exiting Add wbinvd VM Exit support to prepare for pass-through device cache emulation and also enhance real time responsiveness. Signed-off-by: Yaozu (Eddie) Dong Signed-off-by: Avi Kivity commit a5cfeab46e439b2610f264eaf200e3b01f3adf04 Author: Eddie Dong Date: Sun Nov 11 12:27:20 2007 +0200 KVM: VMX: Comment VMX primary/secondary exec ctl definitions Add comments for secondary/primary Processor-Based VM-execution controls. Signed-off-by: Yaozu (Eddie) Dong Signed-off-by: Avi Kivity commit 64276997bc49442e0cfb6a8d857274cca5ad2d39 Author: Avi Kivity Date: Sun Nov 11 11:29:26 2007 +0200 KVM: Go back to atomically injecting interrupts Revert b622204087b5dbdc76b39cbfa288a41d325e3e9a and 817b54a86b0a3e0e5955714b84577101ffff9c59, and inject interrupts atomically in the guest switch path. There are unresolved issues with injecting interrupts while sleeping is enabled. Signed-off-by: Avi Kivity commit ab4e018dc95e1b32b7f25746eb9b2c1385aec93e Author: Avi Kivity Date: Thu Nov 8 18:19:20 2007 +0200 KVM: VMX: Use vmx to inject real interrupts Instead of injecting real-mode interrupts by writing the interrupt frame into guest memory, abuse vmx by injecting a software interrupt. We need to pretend the software interrupt instruction had a length > 0, so we have to adjust rip backward. This lets us not to mess with writing guest memory, which is complex and also sleeps. Signed-off-by: Avi Kivity commit 1805646bfeeea2365d49c46abcd61f2c0d21e677 Author: Avi Kivity Date: Tue Nov 6 11:29:56 2007 +0200 KVM: VMX: Avoid reloading host efer on cpus that don't have it Some VT-capable processors (like the T2600) don't have an efer, so don't try to reload it. Signed-off-by: Avi Kivity commit f3cb18371632dd89d4158319baaa4137cb0f1bbd Author: Avi Kivity Date: Wed Nov 7 17:14:18 2007 +0200 KVM: SVM: Defer nmi processing until switch to host state is complete If we stgi() too soon, nmis can reach the processor even though interrupts are disabled, catching it in a half-switched state. Delay the stgi() until we're done switching. Signed-off-by: Avi Kivity commit 94ef4576bb78d429e4f25cdc09e348434c76c1a3 Author: Dor Laor Date: Wed Nov 7 16:20:06 2007 +0200 KVM: Add make_page_dirty() to kvm_clear_guest_page() Every write access to guest pages should be tracked. Signed-off-by: Dor Laor Signed-off-by: Izik Eidus Signed-off-by: Avi Kivity commit 157117844e1d228db58dfe7fbd51c5a225ceafe4 Author: Avi Kivity Date: Wed Nov 7 12:57:23 2007 +0200 KVM: SVM: Fix SMP with kernel apic AP processor needs to reset to the SIPI vector, not normal INIT. Signed-off-by: Avi Kivity commit 35e0154eeb0ace014ecf4cc2bdb93a42ee762aca Author: Sheng Yang Date: Tue Nov 6 11:37:44 2007 +0800 KVM: VMX: Fix repeated allocation of apic access page on smp For SMP guest, alloc_apic_access_page() would be called more than once. So only the last one works, causing SMP guest can't benifit from FlexPriority. This patch fixed this issue. Signed-off-by: Sheng Yang Signed-off-by: Avi Kivity commit 9c86738fc9c62e5e801720a1cea3d982f9e66ec1 Author: Avi Kivity Date: Tue Nov 6 12:01:44 2007 +0200 KVM: x86 emulator: Move one-byte insns with reg operand into one-byte section Previously, they were decoded as 'ImplicitOps', but after now that we decode them as SrcReg or DstReg, they should be in the regular section. Thanks to Alexey Eremenko for a good bisect. Signed-off-by: Avi Kivity commit c388ba81841a1ed30a5dd4f6029db2263ad1aca3 Author: Hollis Blanchard Date: Thu Nov 1 14:16:10 2007 -0500 KVM: Portability: Move x86 vcpu ioctl handlers to x86.c Signed-off-by: Hollis Blanchard Signed-off-by: Avi Kivity commit a9acc2800d8676d8a9a91aeaedd16ae4f75c05df Author: Hollis Blanchard Date: Wed Oct 31 17:24:25 2007 -0500 KVM: Portability: Move x86 FPU handling to x86.c Signed-off-by: Hollis Blanchard Signed-off-by: Avi Kivity commit f0bed919cd92ebc5f6456061c2a1e3936a9cf4bb Author: Hollis Blanchard Date: Wed Oct 31 17:24:24 2007 -0500 KVM: Portability: Move x86 instruction emulation code to x86.c Signed-off-by: Hollis Blanchard Signed-off-by: Avi Kivity commit 24c5e5dfaafbb5fe3fbb35f456dc5293c7efa2f9 Author: Hollis Blanchard Date: Wed Oct 31 17:24:23 2007 -0500 KVM: Portability: Make exported debugfs data architecture-specific Signed-off-by: Hollis Blanchard Signed-off-by: Avi Kivity commit 92f0fc32feb5ed773272ca0a4275f9c3d91666b6 Author: Avi Kivity Date: Thu Nov 1 06:31:28 2007 +0200 KVM: x86 emulator: Hoist modrm and abs decoding into separate functions Signed-off-by: Avi Kivity commit aadea67210c8b9e7a57744a1c2845501d2cdbac7 Author: Uri Lublin Date: Tue Oct 30 10:42:09 2007 +0200 KVM: Make mark_page_dirty() work for aliased pages too. Recommended by Izik Eidus. Signed-off-by: Uri Lublin Signed-off-by: Avi Kivity commit d49f75b8587e4078013124b76e89986201e31bd2 Author: Avi Kivity Date: Wed Oct 31 11:21:06 2007 +0200 KVM: Simplify decode_register_operand() calling convention Now that rex_prefix is part of the decode cache, there is no need to pass it along. Signed-off-by: Avi Kivity commit e49ba82c02da109f272da66a7b11d07da24146e4 Author: Avi Kivity Date: Wed Oct 31 11:15:56 2007 +0200 KVM: x86 emulator: centralize decoding of one-byte register access insns Instructions like 'inc reg' that have the register operand encoded in the opcode are currently specially decoded. Extend decode_register_operand() to handle that case, indicated by having DstReg or SrcReg without ModRM. Signed-off-by: Avi Kivity commit cc528786cfc5567c8478f57e9ba27abbe899cfe1 Author: Avi Kivity Date: Wed Oct 31 10:27:04 2007 +0200 KVM: x86 emulator: Extract the common code of SrcReg and DstReg Share the common parts of SrcReg and DstReg decoding. Signed-off-by: Avi Kivity commit baade4336b89881dfde8664339c888cbad749e21 Author: Carsten Otte Date: Tue Oct 30 18:44:25 2007 +0100 KVM: Portability: Move pio emulation functions to x86.c This patch moves implementation of the following functions from kvm_main.c to x86.c: free_pio_guest_pages, vcpu_find_pio_dev, pio_copy_data, complete_pio, kernel_pio, pio_string_write, kvm_emulate_pio, kvm_emulate_pio_string The function inject_gp, which was duplicated by yesterday's patch series, is removed from kvm_main.c now because it is not needed anymore. Signed-off-by: Carsten Otte Acked-by: Hollis Blanchard Signed-off-by: Avi Kivity commit e20bd3021d1709638c08ce946e7fe0f21a78107d Author: Carsten Otte Date: Tue Oct 30 18:44:21 2007 +0100 KVM: Portability: Move x86 emulation and mmio device hook to x86.c This patch moves the following functions to from kvm_main.c to x86.c: emulator_read/write_std, vcpu_find_pervcpu_dev, vcpu_find_mmio_dev, emulator_read/write_emulated, emulator_write_phys, emulator_write_emulated_onepage, emulator_cmpxchg_emulated, get_setment_base, emulate_invlpg, emulate_clts, emulator_get/set_dr, kvm_report_emulation_failure, emulate_instruction The following data type is moved to x86.c: struct x86_emulate_ops emulate_ops Signed-off-by: Carsten Otte Acked-by: Hollis Blanchard Signed-off-by: Avi Kivity commit d465b5f219d61e68f523dbe42f99fe7ec6787e2e Author: Carsten Otte Date: Tue Oct 30 18:44:17 2007 +0100 KVM: Portability: Move kvm_get/set_msr[_common] to x86.c This patch moves the implementation of the functions of kvm_get/set_msr, kvm_get/set_msr_common, and set_efer from kvm_main.c to x86.c. The definition of EFER_RESERVED_BITS is moved too. Signed-off-by: Carsten Otte Acked-by: Hollis Blanchard Signed-off-by: Avi Kivity commit 84397028b8a819ad3c102d0e55f9010e8a43875f Author: Anthony Liguori Date: Mon Oct 29 15:15:20 2007 -0500 KVM: Fix gfn_to_page() acquiring mmap_sem twice KVM's nopage handler calls gfn_to_page() which acquires the mmap_sem when calling out to get_user_pages(). nopage handlers are already invoked with the mmap_sem held though. Introduce a __gfn_to_page() for use by the nopage handler which requires the lock to already be held. This was noticed by tglx. Signed-off-by: Anthony Liguori Signed-off-by: Avi Kivity commit a1ac91208be54463677c391b678f82a10b8f6b43 Author: Sheng Yang Date: Mon Oct 29 09:40:42 2007 +0800 KVM: VMX: Enable memory mapped TPR shadow (FlexPriority) This patch based on CR8/TPR patch, and enable the TPR shadow (FlexPriority) for 32bit Windows. Since TPR is accessed very frequently by 32bit Windows, especially SMP guest, with FlexPriority enabled, we saw significant performance gain. Signed-off-by: Sheng Yang Signed-off-by: Avi Kivity commit 650d273133f478c40d1a5c720676d8a5687cbf7d Author: Carsten Otte Date: Mon Oct 29 16:09:35 2007 +0100 KVM: Portability: Move control register helper functions to x86.c This patch moves the definitions of CR0_RESERVED_BITS, CR4_RESERVED_BITS, and CR8_RESERVED_BITS along with the following functions from kvm_main.c to x86.c: set_cr0(), set_cr3(), set_cr4(), set_cr8(), get_cr8(), lmsw(), load_pdptrs() The static function wrapper inject_gp is duplicated in kvm_main.c and x86.c for now, the version in kvm_main.c should disappear once the last user of it is gone too. The function load_pdptrs is no longer static, and now defined in x86.h for the time being, until the last user of it is gone from kvm_main.c. Signed-off-by: Carsten Otte Reviewed-by: Christian Borntraeger Acked-by: Hollis Blanchard Signed-off-by: Avi Kivity commit 77c9dcf8e969f79483a8fef6eee35a462b013954 Author: Carsten Otte Date: Mon Oct 29 16:09:10 2007 +0100 KVM: Portability: move get/set_apic_base to x86.c This patch moves the implementation of get_apic_base and set_apic_base from kvm_main.c to x86.c Signed-off-by: Carsten Otte Reviewed-by: Christian Borntraeger Acked-by: Hollis Blanchard Signed-off-by: Avi Kivity commit fba9a282a95211407af2a00f500868ae9846c75e Author: Carsten Otte Date: Mon Oct 29 16:08:51 2007 +0100 KVM: Portability: Move memory segmentation to x86.c This patch moves the definition of segment_descriptor_64 for AMD64 and EM64T from kvm_main.c to segment_descriptor.h. It also adds a proper #ifndef...#define...#endif around that header file. The implementation of segment_base is moved from kvm_main.c to x86.c. Signed-off-by: Carsten Otte Reviewed-by: Christian Borntraeger Acked-by: Hollis Blanchard Signed-off-by: Avi Kivity commit 13974a5a9c61c0c1732dfe42c02d703830b5db3a Author: Carsten Otte Date: Mon Oct 29 16:08:35 2007 +0100 KVM: Portability: Split kvm_vm_ioctl v3 This patch splits kvm_vm_ioctl into archtecture independent parts, and x86 specific parts which go to kvm_arch_vcpu_ioctl in x86.c. The patch is unchanged since last submission. Common ioctls for all architectures are: KVM_CREATE_VCPU, KVM_GET_DIRTY_LOG, KVM_SET_USER_MEMORY_REGION x86 specific ioctls are: KVM_SET_MEMORY_REGION, KVM_GET/SET_NR_MMU_PAGES, KVM_SET_MEMORY_ALIAS, KVM_CREATE_IRQCHIP, KVM_CREATE_IRQ_LINE, KVM_GET/SET_IRQCHIP KVM_SET_TSS_ADDR Signed-off-by: Carsten Otte Reviewed-by: Christian Borntraeger Acked-by: Hollis Blanchard Signed-off-by: Avi Kivity commit b95061aec006bc4c44e4b244e4ec15c009ab880a Author: Avi Kivity Date: Sun Oct 28 18:52:05 2007 +0200 KVM: MMU: Topup the mmu memory preallocation caches before emulating an insn Emulation may cause a shadow pte to be instantiated, which requires memory resources. Make sure the caches are filled to avoid an oops. Signed-off-by: Avi Kivity commit e9e1741b896e474238422b3954eb05ff06075d61 Author: Avi Kivity Date: Sun Oct 28 18:48:59 2007 +0200 KVM: Move page fault processing to common code The code that dispatches the page fault and emulates if we failed to map is duplicated across vmx and svm. Merge it to simplify further bugfixing. Signed-off-by: Avi Kivity commit 302db0cf4a8a9eb286190abfec5d654cf61d6883 Author: Avi Kivity Date: Sun Oct 28 16:34:25 2007 +0200 KVM: x86 emulator: don't depend on cr2 for mov abs emulation The 'mov abs' instruction family (opcodes 0xa0 - 0xa3) still depends on cr2 provided by the page fault handler. This is wrong for several reasons: - if an instruction accessed misaligned data that crosses a page boundary, and if the fault happened on the second page, cr2 will point at the second page, not the data itself. - if we're emulating in real mode, or due to a FlexPriority exit, there is no cr2 generated. So, this change adds decoding for this instruction form and drops reliance on cr2. Signed-off-by: Avi Kivity commit 9471ec5bb21c235d14bbcd4ae244b838793c513f Author: Avi Kivity Date: Sun Oct 28 16:11:58 2007 +0200 KVM: SVM: Intercept the 'invd' and 'wbinvd' instructions 'invd' can destroy host data, and 'wbinvd' allows the guest to induce long (milliseconds) latencies. Noted by Ben Serebrin. Signed-off-by: Avi Kivity commit b5a23e7d1161f1182188c462353c3314010dcb6a Author: Avi Kivity Date: Sun Oct 28 16:09:18 2007 +0200 KVM: x86 emulator: invd instruction Emulate the 'invd' instruction (opcode 0f 08). Signed-off-by: Avi Kivity commit 8d2d0414d8203a3598fe403c18f7f612e69128fa Author: Laurent Vivier Date: Thu Oct 25 14:18:54 2007 +0200 KVM: SVM: Let gcc to choose which registers to save (i386) This patch lets GCC to determine which registers to save when we switch to/from a VCPU in the case of AMD i386 * Original code saves following registers: ebx, ecx, edx, esi, edi, ebp * Patched code: - informs GCC that we modify following registers using the clobber description: ebx, ecx, edx, esi, edi - rbp is saved (pop/push) because GCC seems to ignore its use in the clobber description. Signed-off-by: Laurent Vivier Signed-off-by: Avi Kivity commit b8a500de75585cd6989d175b40421c04ea6b1f16 Author: Laurent Vivier Date: Thu Oct 25 14:18:53 2007 +0200 KVM: SVM: Let gcc to choose which registers to save (x86_64) This patch lets GCC to determine which registers to save when we switch to/from a VCPU in the case of AMD x86_64. * Original code saves following registers: rbx, rcx, rdx, rsi, rdi, rbp, r8, r9, r10, r11, r12, r13, r14, r15 * Patched code: - informs GCC that we modify following registers using the clobber description: rbx, rcx, rdx, rsi, rdi r8, r9, r10, r11, r12, r13, r14, r15 - rbp is saved (pop/push) because GCC seems to ignore its use in the clobber description. Signed-off-by: Laurent Vivier Signed-off-by: Avi Kivity commit 203ebca1065ff925cc35b31c85d160b2a3ebc473 Author: Laurent Vivier Date: Thu Oct 25 14:18:55 2007 +0200 KVM: VMX: Let gcc to choose which registers to save (i386) This patch lets GCC to determine which registers to save when we switch to/from a VCPU in the case of intel i386. * Original code saves following registers: eax, ebx, ecx, edx, edi, esi, ebp (using popa) * Patched code: - informs GCC that we modify following registers using the clobber description: ebx, edi, rsi - doesn't save eax because it is an output operand (vmx->fail) - cannot put ecx in clobber description because it is an input operand, but as we modify it and we want to keep its value (vcpu), we must save it (pop/push) - ebp is saved (pop/push) because GCC seems to ignore its use the clobber description. - edx is saved (pop/push) because it is reserved by GCC (REGPARM) and cannot be put in the clobber description. - line "mov (%%esp), %3 \n\t" has been removed because %3 is ecx and ecx is restored just after. Signed-off-by: Laurent Vivier Signed-off-by: Avi Kivity commit acc3a1756feee379b35a913da2e7fd8e1deaeb98 Author: Laurent Vivier Date: Thu Oct 25 14:18:52 2007 +0200 KVM: VMX: Let gcc to choose which registers to save (x86_64) This patch lets GCC to determine which registers to save when we switch to/from a VCPU in the case of intel x86_64. * Original code saves following registers: rax, rbx, rcx, rdx, rsi, rdi, rbp, r8, r9, r10, r11, r12, r13, r14, r15 * Patched code: - informs GCC that we modify following registers using the clobber description: rbx, rdi, rsi, r8, r9, r10, r11, r12, r13, r14, r15 - doesn't save rax because it is an output operand (vmx->fail) - cannot put rcx in clobber description because it is an input operand, but as we modify it and we want to keep its value (vcpu), we must save it (pop/push) - rbp is saved (pop/push) because GCC seems to ignore its use in the clobber description. - rdx is saved (pop/push) because it is reserved by GCC (REGPARM) and cannot be put in the clobber description. - line "mov (%%rsp), %3 \n\t" has been removed because %3 is rcx and rcx is restored just after. - line ASM_VMX_VMWRITE_RSP_RDX() is moved out of the ifdef/else/endif Signed-off-by: Laurent Vivier Signed-off-by: Avi Kivity commit ac484b81d644721fbdfe0f6203ea18d3d23ff060 Author: Avi Kivity Date: Fri Oct 26 14:16:56 2007 +0200 KVM: x86 emulator: fix 'push imm8' emulation 'push imm8' found itself in the wrong switch somehow, so it is never executed. This fixes Windows 2003 installation. Signed-off-by: Avi Kivity commit 70ac85846fc8c818dd6ca0513954edeab8ef90d0 Author: Izik Eidus Date: Thu Oct 25 00:29:55 2007 +0200 KVM: Add ioctl to tss address from userspace, Currently kvm has a wart in that it requires three extra pages for use as a tss when emulating real mode on Intel. This patch moves the allocation internally, only requiring userspace to tell us where in the physical address space we can place the tss. Signed-off-by: Izik Eidus Signed-off-by: Avi Kivity commit 12360bf90e1bd1e4780ab8903eab675b458ceb16 Author: Izik Eidus Date: Wed Oct 24 23:57:46 2007 +0200 KVM: Add kernel-internal memory slots Reserve a few memory slots for kernel internal use. This is good for case you have to register memory region and you want to be sure it was not registered from userspace, and for case you want to register a memory region that won't be seen from userspace. Signed-off-by: Izik Eidus Signed-off-by: Avi Kivity commit 7de757f14b3e2e90a830ab0f2e42518ea1231c6c Author: Izik Eidus Date: Wed Oct 24 23:52:57 2007 +0200 KVM: Export memory slot allocation mechanism Remove kvm memory slot allocation mechanism from the ioctl and put it to exported function. Signed-off-by: Izik Eidus Signed-off-by: Avi Kivity commit 2ddb29ee7761a7415b1172b77007dccb0cf49e39 Author: Izik Eidus Date: Thu Oct 25 11:54:04 2007 +0200 KVM: Unmap kernel-allocated memory on slot destruction kvm_vm_ioctl_set_memory_region() is able to remove memory in addition to adding it. Therefore when using kernel swapping support for old userspaces, we need to munmap the memory if the user request to remove it Signed-off-by: Izik Eidus Signed-off-by: Avi Kivity commit 031b69bbd4fabbd3cc4e93fe88cca3122498070a Author: Laurent Vivier Date: Mon Oct 22 16:33:07 2007 +0200 KVM: Use new smp_call_function_mask() in kvm_flush_remote_tlbs() In kvm_flush_remote_tlbs(), replace a loop using smp_call_function_single() by a single call to smp_call_function_mask() (which is new for x86_64). Signed-off-by: Laurent Vivier Signed-off-by: Avi Kivity commit 0d878c5ce8309856b2aff32783601b761db96dec Author: Christian Borntraeger Date: Thu Oct 11 15:34:17 2007 +0200 KVM: Per-architecture hypercall definitions Currently kvm provides hypercalls only for x86* architectures. To provide hypercall infrastructure for other kvm architectures I split kvm_para.h into a generic header file and architecture specific definitions. Signed-off-by: Christian Borntraeger Signed-off-by: Avi Kivity commit b6afc446d80005ca125a58042a3a63e665f14110 Author: Avi Kivity Date: Sun Oct 21 18:34:54 2007 +0200 KVM: VMX: vmx_vcpu_setup(): remove unused variable. Noticed by Izik Eidus. Signed-off-by: Avi Kivity commit a785ddf7b0c9dd5367aed014eab3819be0214d0e Author: Avi Kivity Date: Sun Oct 21 11:03:36 2007 +0200 KVM: Add a might_sleep() annotation to gfn_to_page() This will help trap accesses to guest memory in atomic context. Signed-off-by: Avi Kivity commit d9f17a13c2180569f82acb85d93970c85a42a855 Author: Avi Kivity Date: Sun Oct 21 11:00:39 2007 +0200 KVM: Move vmx_vcpu_reset() out of vmx_vcpu_setup() Split guest reset code out of vmx_vcpu_setup(). Besides being cleaner, this moves the realmode tss setup (which can sleep) outside vmx_vcpu_setup() (which is executed with preemption enabled). Signed-off-by: Avi Kivity commit 3b06c8ee1e0710c99c2b34a3c34c9758256a6248 Author: Avi Kivity Date: Sun Oct 21 09:45:12 2007 +0200 Revert "KVM: VMX: Initialize vcpu with preemption enabled" This reverts commit 341131670f028f8bec97db6121c018f53129b9c3. It executes vcpu_load() before installing the preemption notifier, which leeds to oopses. Signed-off-by: Avi Kivity commit aa89acdb280d63973b255b9cb4d11c73f195fd15 Author: Kevin Pedretti Date: Sun Oct 21 08:55:50 2007 +0200 KVM: Improve local apic timer wraparound handling Better handle wrap-around cases when reading the APIC CCR (current count register). Also, if ICR is 0, CCR should also be 0... previously reading CCR before setting ICR would result in a large kinda-random number. Signed-off-by: Kevin Pedretti Signed-off-by: Avi Kivity commit 654f22693683aff28c006eceb15eb16cd0b25ec8 Author: Kevin Pedretti Date: Sun Oct 21 08:54:53 2007 +0200 KVM: Fix local apic timer divide by zero kvm_lapic_reset() was initializing apic->timer.divide_count to 0, which could potentially lead to a divide by zero error in apic_get_tmcct(). Any guest that reads the APIC's CCR (current count) register before setting DCR (divide configuration) would trigger a divide by zero exception in the host kernel, leading to a host-OS crash. This patch results in apic->timer.divide_count being initialized to 2 at reset, eliminating the bug (DCR=0 at reset, meaning divide by 2). Signed-off-by: Kevin Pedretti Signed-off-by: Avi Kivity commit 933a3f772d28b532cd09098257e482694a795dfb Author: Zhang Xiantao Date: Sat Oct 20 15:34:38 2007 +0800 KVM: Portability: Split kvm_vcpu into arch dependent and independent parts (part 1) First step to split kvm_vcpu. Currently, we just use an macro to define the common fields in kvm_vcpu for all archs, and all archs need to define its own kvm_vcpu struct. Signed-off-by: Zhang Xiantao Signed-off-by: Avi Kivity commit 648fc91671f57b818d9501aab30765df75165fbf Author: Anthony Liguori Date: Thu Oct 18 09:59:34 2007 -0500 KVM: Allocate userspace memory for older userspace Allocate a userspace buffer for older userspaces. Also eliminate phys_mem buffer. The memset() in kvmctl really kills initial memory usage but swapping works even with old userspaces. A side effect is that maximum guest side is reduced for older userspace on i386. Signed-off-by: Anthony Liguori Signed-off-by: Avi Kivity commit bb1d1fee77d97efba72dccec85d857378e3abea5 Author: Avi Kivity Date: Thu Oct 18 17:35:57 2007 +0200 KVM: MMU: Fix dirty bit pte gpa calculation The host physical address has no business in there. Noticed by Izik Eidus. Signed-off-by: Avi Kivity commit e735785caa9c0a9134e1246bc8d5c5f73c2a3e65 Author: Laurent Vivier Date: Thu Oct 18 15:19:01 2007 +0200 KVM: Move kvm_guest_exit() after local_irq_enable() We need to make sure that the timer interrupt happens before we clear PF_VCPU, so the accounting code actually sees guest mode. http://lkml.org/lkml/2007/10/15/114 Signed-off-by: Laurent Vivier Signed-off-by: Avi Kivity commit 1de6a8de93320521092aa237156fd5a6ed0d0ef5 Author: Christian Borntraeger Date: Thu Oct 18 14:39:10 2007 +0200 KVM: Use virtual cpu accounting if available for guest times. ppc and s390 offer the possibility to track process times precisely by looking at cpu timer on every context switch, irq, softirq etc. We can use that infrastructure as well for guest time accounting. We need to account the used time before we change the state. This patch adds a call to account_system_vtime to kvm_guest_enter and kvm_guest exit. If CONFIG_VIRT_CPU_ACCOUNTING is not set, account_system_vtime is defined in hardirq.h as an empty function, which means this patch does not change the behaviour on other platforms. I compile tested this patch on x86 and function tested the patch on s390. Signed-off-by: Christian Borntraeger Signed-off-by: Avi Kivity commit 341131670f028f8bec97db6121c018f53129b9c3 Author: Avi Kivity Date: Thu Oct 18 12:38:52 2007 +0200 KVM: VMX: Initialize vcpu with preemption enabled vcpu initialization require writes to memory (for the real mode tss), which is now a sleeping operation. Signed-off-by: Avi Kivity commit 1253f76f37189f0bfda7e4a46bfe537f329dc0db Author: Izik Eidus Date: Thu Oct 18 11:09:33 2007 +0200 KVM: Partial swapping of guest memory This allows guest memory to be swapped. Pages which are currently mapped via shadow page tables are pinned into memory, but all other pages can be freely swapped. The patch make gfn_to_page() elevate the page's reference count, and introduces kvm_release_page() that pairs with it. Signed-off-by: Izik Eidus Signed-off-by: Avi Kivity commit 283c5eefd628c754df85434ed2aca079d35aa2aa Author: Izik Eidus Date: Wed Oct 17 19:17:48 2007 +0200 KVM: MMU: Make gfn_to_page() always safe In case the page is not present in the guest memory map, return a dummy page the guest can scribble on. This simplifies error checking in its users. Signed-off-by: Izik Eidus Signed-off-by: Avi Kivity commit ca335c8f08d88b4bb978afa02b86c206ecfd21d1 Author: Izik Eidus Date: Tue Oct 16 14:43:46 2007 +0200 KVM: MMU: Keep a reverse mapping of non-writable translations The current kvm mmu only reverse maps writable translation. This is used to write-protect a page in case it becomes a pagetable. But with swapping support, we need a reverse mapping of read-only pages as well: when we evict a page, we need to remove any mapping to it, whether writable or not. Signed-off-by: Izik Eidus Signed-off-by: Avi Kivity commit 751e23de45cd219956036db6d55b8685e74a7090 Author: Izik Eidus Date: Tue Oct 16 14:42:30 2007 +0200 KVM: MMU: Add rmap_next(), a helper for walking kvm rmaps Signed-off-by: Izik Eidus Signed-off-by: Avi Kivity commit f83562246921d6a8a7de8b76853a6835ace3699d Author: Aurelien Jarno Date: Wed Oct 17 19:30:41 2007 +0200 KVM: x86 emulator: fix access registers for instructions with ModR/M byte and Mod = 3 The patch belows changes the access type to register from memory for instructions that are declared as SrcMem or DstMem, but have a ModR/M byte with Mod = 3. It fixes (at least) the lmsw and smsw instructions on an AMD64 CPU, which are needed for FreeBSD. Signed-off-by: Aurelien Jarno Signed-off-by: Avi Kivity commit 0863fb5961a612a5d930c5796b7b0188082f4b14 Author: Avi Kivity Date: Thu Oct 18 10:46:02 2007 +0200 KVM: x86 emulator: use a defined flag definition EFLG_IF is not defined anywhere. Signed-off-by: Avi Kivity commit ad6c935c4963ee5577210ba47434c7c59aec81fa Author: Nitin A Kamble Date: Tue Oct 16 18:23:27 2007 -0700 KVM: x86 emulator: cmc, clc, cli, sti Instruction: cmc, clc, cli, sti opcodes: 0xf5, 0xf8, 0xfa, 0xfb respectively. Signed-off-by: Nitin A Kamble Signed-off-by: Avi Kivity commit b622204087b5dbdc76b39cbfa288a41d325e3e9a Author: Avi Kivity Date: Wed Oct 17 12:20:21 2007 +0200 KVM: Actually move the interrupt injection code out of the critical section Commit 817b54a86b0a3e0e5955714b84577101ffff9c59 claimed to do this, but actually didn't (despite laying all the infrastructure for it). This completes the movement. Noticed by Eddie Dong. Signed-off-by: Avi Kivity commit f3a00bac6038e0a6ee519a6454ca2efc11805639 Author: Avi Kivity Date: Wed Oct 17 12:18:47 2007 +0200 KVM: MMU: Simplify page table walker Simplify the walker level loop not to carry so much information from one loop to the next. In addition to being complex, this made kmap_atomic() critical sections difficult to manage. As a result of this change, kmap_atomic() sections are limited to actually touching the guest pte, which allows the other functions called from the walker to do sleepy operations. This will happen when we enable swapping. Signed-off-by: Avi Kivity commit 9b6895d0e4bb62f46bdd05c7e4b4e99709462385 Author: Avi Kivity Date: Wed Oct 17 11:03:06 2007 +0200 Revert "KVM: MMU: Call update_dirty_bit() without disabling preemption" This reverts commit 5a691bafbc79643d60f1925a581d1af5a9f0f60d. It unmaps walker->table while leaving ptep pointing into it. Fails spectacularly on i386. Signed-off-by: Avi Kivity commit d8a0c28def19005173b0e4edcaa120b865eaac6d Author: Nitin A Kamble Date: Fri Oct 12 17:40:33 2007 -0700 KVM: x86 emulator: Implement emulation of instruction: inc & dec Instructions: inc r16/r32 (opcode 0x40-0x47) dec r16/r32 (opcode 0x48-0x4f) Signed-off-by: Nitin A Kamble Signed-off-by: Avi Kivity commit f2d7854fd4932dec136dec5115a6d8e6d4a8a5a5 Author: Avi Kivity Date: Tue Oct 16 19:06:15 2007 +0200 KVM: VMX: Force vm86 mode if setting flags during real mode When resetting from userspace, we need to handle the flags being cleared even after we are in real mode. Signed-off-by: Avi Kivity commit 32262da4c1f9268a9c271360342821c114a8a8e7 Author: Avi Kivity Date: Tue Oct 16 17:22:08 2007 +0200 KVM: Rename KVM_TLB_FLUSH to KVM_REQ_TLB_FLUSH We now have a new namespace, KVM_REQ_*, for bits in vcpu->requests. Signed-off-by: Avi Kivity commit 817b54a86b0a3e0e5955714b84577101ffff9c59 Author: Avi Kivity Date: Tue Oct 16 16:29:39 2007 +0200 KVM: Move interrupt injection out of interrupt disabled section Instead of injecting interrupts while we're in the critical section during the guest switch, inject them earlier. In case we had an irq raised between the injection point and the switch, we check a bit during guest switch and if needed we go back and redo the injection. This improves system latency, and allows sleeping during injection (which is needed when injecting real-mode interrupts on Intel). Signed-off-by: Avi Kivity commit 1c37fdc33da77df7fbb0affe5c3896d15f6f2702 Author: Avi Kivity Date: Tue Oct 16 16:23:22 2007 +0200 KVM: Move apic timer interrupt backlog processing to common code Beside the obvious goodness of making code more common, this prevents a livelock with the next patch which moves interrupt injection out of the critical section. Signed-off-by: Avi Kivity commit 5a691bafbc79643d60f1925a581d1af5a9f0f60d Author: Izik Eidus Date: Mon Oct 15 19:24:52 2007 +0200 KVM: MMU: Call update_dirty_bit() without disabling preemption update_dirty_bit() will want to touch memory, which will one day invoke sleeping operations. Signed-off-by: Izik Eidus Signed-off-by: Avi Kivity commit 0f4a1103e329eda5741eb548bc5746653471ce86 Author: Sheng Yang Date: Mon Oct 15 14:24:20 2007 +0800 KVM: x86 emulator: implement 'movnti mem, reg' Implement emulation of instruction: movnti m32/m64, r32/r64 opcode: 0x0f 0xc3 Signed-off-by: Sheng Yang Signed-off-by: Avi Kivity commit 3923231f506fb4e83f9fc5f8efce3607d696b33f Author: Laurent Vivier Date: Fri Oct 12 11:01:59 2007 +0200 KVM: Add some \n in ioapic_debug() Add new-line at end of debug strings. Signed-off-by: Laurent Vivier Signed-off-by: Avi Kivity commit a279c26a8ad12130c347eddfd92de6f4a1c3b53b Author: Avi Kivity Date: Thu Oct 11 19:46:26 2007 +0200 KVM: Restore missing #include commit 33aafecf3f106ba6aa8847dfdae033a73e5d1b50 Author: Carsten Otte Date: Thu Oct 11 19:16:52 2007 +0200 KVM: Portability: split kvm_vcpu_ioctl This patch splits kvm_vcpu_ioctl into archtecture independent parts, and x86 specific parts which go to kvm_arch_vcpu_ioctl in x86.c. Common ioctls for all architectures are: KVM_RUN, KVM_GET/SET_(S-)REGS, KVM_TRANSLATE, KVM_INTERRUPT, KVM_DEBUG_GUEST, KVM_SET_SIGNAL_MASK, KVM_GET/SET_FPU Note that some PPC chips don't have an FPU, so we might need an #ifdef around KVM_GET/SET_FPU one day. x86 specific ioctls are: KVM_GET/SET_LAPIC, KVM_SET_CPUID, KVM_GET/SET_MSRS An interresting aspect is vcpu_load/vcpu_put. We now have a common vcpu_load/put which does the preemption stuff, and an architecture specific kvm_arch_vcpu_load/put. In the x86 case, this one calls the vmx/svm function defined in kvm_x86_ops. Signed-off-by: Carsten Otte Reviewed-by: Christian Borntraeger Reviewed-by: Christian Ehrhardt Signed-off-by: Avi Kivity commit 56161cd30f573c7aa24440df1f9f848c80c203da Author: Avi Kivity Date: Thu Oct 11 15:30:21 2007 +0200 KVM: MMU: When updating the dirty bit, inform the mmu about it Since the mmu uses different shadow pages for dirty large pages and clean large pages, this allows the mmu to drop ptes that are now invalid. Signed-off-by: Avi Kivity commit c507f33a3e7053fe31a9352b61e7bc76e4640c2f Author: Avi Kivity Date: Thu Oct 11 15:22:59 2007 +0200 KVM: MMU: Move dirty bit updates to a separate function Signed-off-by: Avi Kivity commit 7ccf679da43960a30336c5fcede3378f972763fb Author: Avi Kivity Date: Thu Oct 11 15:13:49 2007 +0200 KVM: MMU: Instatiate real-mode shadows as user writable shadows This is consistent with real-mode permissions. Signed-off-by: Avi Kivity commit 636a2d88e5b03699095dcafbf754fd2b3d6c7f17 Author: Avi Kivity Date: Thu Oct 11 15:12:24 2007 +0200 KVM: MMU: Disable write access on clean large pages By forcing clean huge pages to be read-only, we have separate roles for the shadow of a clean large page and the shadow of a dirty large page. This is necessary because different ptes will be instantiated for the two cases, even for read faults. Signed-off-by: Avi Kivity commit 154833765b9edde8fbc40cd30b2f0270bd6734d2 Author: Avi Kivity Date: Thu Oct 11 15:08:41 2007 +0200 KVM: MMU: Fix nx access bit for huge pages We must set the bit before the shift, otherwise the wrong bit gets set. Signed-off-by: Avi Kivity commit 14fe74643102320001eeb52f4fb940cc56eeea3a Author: Avi Kivity Date: Thu Oct 11 12:32:30 2007 +0200 KVM: Move guest pte dirty bit management to the guest pagetable walker This is more consistent with the accessed bit management, and makes the dirty bit available earlier for other purposes. Signed-off-by: Avi Kivity commit 4d7767d5d025a9ba5e230fd121aca7e1a064f969 Author: Anthony Liguori Date: Wed Oct 10 20:08:41 2007 -0500 KVM: MMU: More struct kvm_vcpu -> struct kvm cleanups This time, the biggest change is gpa_to_hpa. The translation of GPA to HPA does not depend on the VCPU state unlike GVA to GPA so there's no need to pass in the kvm_vcpu. Signed-off-by: Anthony Liguori Signed-off-by: Avi Kivity commit 35e19206b7601a5a7c922f6c2932a01de15a5cb3 Author: Anthony Liguori Date: Wed Oct 10 19:25:50 2007 -0500 KVM: MMU: Clean up MMU functions to take struct kvm when appropriate Some of the MMU functions take a struct kvm_vcpu even though they affect all VCPUs. This patch cleans up some of them to instead take a struct kvm. This makes things a bit more clear. The main thing that was confusing me was whether certain functions need to be called on all VCPUs. Signed-off-by: Anthony Liguori Signed-off-by: Avi Kivity commit ac413bb5e5ca60a3e12a99593d184577ff7518c4 Author: cotte@de.ibm.com Date: Wed Oct 10 17:16:19 2007 +0200 KVM: Move x86 msr handling to new files x86.[ch] Signed-off-by: Carsten Otte Signed-off-by: Avi Kivity commit 2a96e86bf672a4c056483de24f4f25c3a19b4c11 Author: Avi Kivity Date: Wed Oct 10 14:03:16 2007 +0200 KVM: Replace enum by #define Easier for existence test (#ifdef) in userspace. Signed-off-by: Avi Kivity commit ad23abbeab86af3156467163b01b25237f99e9cb Author: Dong, Eddie Date: Wed Oct 10 14:26:45 2007 +0800 KVM: VMX: Reset mmu context when entering real mode Resetting an SMP guest will force AP enter real mode (RESET) with paging enabled in protected mode. While current enter_rmode() can only handle mode switch from nonpaging mode to real mode which leads to SMP reboot failure. Fix by reloading the mmu context on entering real mode. Signed-off-by: Yaozu (Eddie) Dong Signed-off-by: Qing He Signed-off-by: Avi Kivity commit 342a6bf85cd40a70fd382324085dc3b0a901c865 Author: Eddie Dong Date: Wed Oct 10 12:15:54 2007 +0200 KVM: Split IOAPIC reset function and export for kernel RESET Signed-off-by: Yaozu (Eddie) Dong Signed-off-by: Avi Kivity commit ebac07d56f961752e209b662e2341aad3e85b408 Author: Eddie Dong Date: Wed Oct 10 12:14:25 2007 +0200 KVM: Export PIC reset for kernel device reset Signed-off-by: Yaozu (Eddie) Dong Signed-off-by: Avi Kivity commit 7faf3e45cc45eb2b5b0db3e3f4412b15784a38cc Author: Izik Eidus Date: Tue Oct 9 19:20:39 2007 +0200 KVM: Support assigning userspace memory to the guest Instead of having the kernel allocate memory to the guest, let userspace allocate it and pass the address to the kernel. This is required for s390 support, but also enables features like memory sharing and using hugetlbfs backed memory. Signed-off-by: Izik Eidus Signed-off-by: Avi Kivity commit 49c32b24524c0b929bcf93ebcc3acc9c7edc87e9 Author: Avi Kivity Date: Tue Oct 9 12:12:19 2007 +0200 KVM: VMX: Handle NMIs before enabling interrupts and preemption This makes sure we handle NMI on the current cpu, and that we don't service maskable interrupts before non-maskable ones. Signed-off-by: Avi Kivity commit 7060e1c92b504ac725e2ffbc91053c1dc684e685 Author: Mike Day Date: Mon Oct 8 09:02:08 2007 -0400 KVM: CodingStyle cleanup Signed-off-by: Mike D. Day Signed-off-by: Avi Kivity commit 82da48c29aabfb4941154e399e2a781d6eb786ca Author: Rusty Russell Date: Mon Oct 8 10:55:29 2007 +1000 KVM: Remove gratuitous casts from lapic.c Since vcpu->apic is of the correct type, there's not need to cast. Signed-off-by: Rusty Russell Signed-off-by: Avi Kivity commit a2230360fb019b080119126a9706c017a5cc96a4 Author: Rusty Russell Date: Mon Oct 8 10:50:48 2007 +1000 KVM: Hoist kvm_create_lapic() into kvm_vcpu_init() Move kvm_create_lapic() into kvm_vcpu_init(), rather than having svm and vmx do it. And make it return the error rather than a fairly random -ENOMEM. This also solves the problem that neither svm.c nor vmx.c actually handles the error path properly. Signed-off-by: Rusty Russell Signed-off-by: Avi Kivity commit 3bbc5ebb64c17319970ef283c35aba79ed7fa915 Author: Rusty Russell Date: Mon Oct 8 10:48:30 2007 +1000 KVM: Add kvm_free_lapic() to pair with kvm_create_lapic() Instead of the asymetry of kvm_free_apic, implement kvm_free_lapic(). And guess what? I found a minor bug: we don't need to hrtimer_cancel() from kvm_main.c, because we do that in kvm_free_apic(). Also: 1) kvm_vcpu_uninit should be the reverse order from kvm_vcpu_init. 2) Don't set apic->regs_page to zero before freeing apic. Signed-off-by: Rusty Russell Signed-off-by: Avi Kivity commit f1b8c28f1886c9375361d7f2ebca1f742ea6bc5f Author: Avi Kivity Date: Mon Oct 8 10:01:45 2007 +0200 KVM: Check I/O APIC indirect index before writing Signed-off-by: Avi Kivity commit d2cfd9a5359db3b0fa8af0d07cf5801c3b22d9ae Author: Izik Eidus Date: Tue Oct 2 18:52:55 2007 +0200 KVM: Allow dynamic allocation of the mmu shadow cache size The user is now able to set how many mmu pages will be allocated to the guest. Signed-off-by: Izik Eidus Signed-off-by: Avi Kivity commit 1842a5c0bf840e1a4f251f344136dd8ebc7c7974 Author: Izik Eidus Date: Mon Oct 1 22:14:18 2007 +0200 KVM: Add general accessors to read and write guest memory Signed-off-by: Izik Eidus Signed-off-by: Avi Kivity commit 06ba8d55ba4052ded08eea5bed9519c6f6780d8c Author: Laurent Vivier Date: Mon Oct 1 11:01:06 2007 +0200 KVM: x86 emulator: Correct management of REP prefix This patch corrects some errors appearing when we have an emulation failure on an operation using REP prefix. When x86_emulate_insn() fails, saving EIP and ECX is not enough as emulation should have modified other registers like RSI or RDI. Moreover, the emulation can fail on the writeback, and in this case we are not able to restore registers. At beginning of x86_emulate_insn(), we restore registers from vcpu as they were not modified by x86d_decode_insn() and we save EIP to be able to restore it in case of failure. Signed-off-by: Laurent Vivier Signed-off-by: Avi Kivity commit c78fc6fb953bbbd9e0b931759b03162768991132 Author: Izik Eidus Date: Thu Sep 27 14:11:22 2007 +0200 KVM: Remove the usage of paeg->private field by rmap When kvm uses user-allocated pages in the future for the guest, we won't be able to use page->private for rmap, since page->rmap is reserved for the filesystem. So we move the rmap base pointers to the memory slot. A side effect of this is that we need to store the gfn of each gpte in the shadow pages, since the memory slot is addressed by gfn, instead of hfn like struct page. Signed-off-by: Izik Eidus Signed-off-by: Avi Kivity commit 08079fa606400c5594e91ac26dcfbabe63940507 Author: Avi Kivity Date: Sun Sep 30 11:02:53 2007 +0200 KVM: VMX: Simplify vcpu_clear() Now that smp_call_function_single() knows how to call a function on the current cpu, there's no need to check explicitly. Signed-off-by: Avi Kivity commit b595c624ca08b063ee5397a5cc881126a6570654 Author: Avi Kivity Date: Sun Sep 30 10:50:12 2007 +0200 KVM: VMX: Don't clear the vmcs if the vcpu is not loaded on any processor Noted by Eddie Dong. Signed-off-by: Avi Kivity commit c0c8b920137e988bb4cde1bb41e0e409c8abb844 Author: Laurent Vivier Date: Tue Sep 25 15:36:35 2007 +0200 KVM: x86 emulator: remove unused variable Remove unused variable introduced by commit 5ed6627ee96f0a6802d99e71879d98610ba17e01 (I missed it, sorry) Signed-off-by: Laurent Vivier Signed-off-by: Avi Kivity commit 9889cbb1bb752615ba1f2f533f7e1386ffeb29c3 Author: Laurent Vivier Date: Thu Sep 27 10:45:34 2007 +0200 KVM: x86 emulator: On a pop instruction, don't restore ECX and EIP on error This patch corrects a mistake introduced by commit 5d9b36eec8ca6abe03da91efdfc7b5861525bd43 and reported by Nitin A Kamble. The pop instruction restores ECX and EIP if read_std() fails and if we have a REP prefix, but at this level ECX and EIP are not saved (and not modified). We don't have to restore it. Signed-off-by: Laurent Vivier Signed-off-by: Avi Kivity commit ba483db9d1e6bf59501c5751399e8b7f966c01d6 Author: Avi Kivity Date: Thu Sep 27 10:07:04 2007 +0200 i386: Expose IOAPIC register definitions even if CONFIG_X86_IO_APIC is not set KVM reuses the IOAPIC register definitions, and needs them even if the host is not compiled with IOAPIC support. Move the #ifdef below so that only the IOAPIC variables and functions are protected, and the register definitions are available to all. Signed-off-by: Avi Kivity commit 5ed6627ee96f0a6802d99e71879d98610ba17e01 Author: Laurent Vivier Date: Tue Sep 25 13:36:40 2007 +0200 KVM: x86 emulator: Any legacy prefix after a REX prefix nullifies its effect This patch modifies the management of REX prefix according behavior I saw in Xen 3.1. In Xen, this modification has been introduced by Jan Beulich. http://lists.xensource.com/archives/html/xen-changelog/2007-01/msg00081.html Signed-off-by: Laurent Vivier Signed-off-by: Avi Kivity commit 6972c9253725255034d0f8d83f5bdbf70430a95b Author: Laurent Vivier Date: Mon Sep 24 17:00:58 2007 +0200 KVM: Purify x86_decode_insn() error case management The only valid case is on protected page access, other cases are errors. Signed-off-by: Laurent Vivier Signed-off-by: Avi Kivity commit 2cd2d1d11d1f67c4d660c0cf6758dd6e588c4dd6 Author: Qing He Date: Mon Sep 24 17:39:41 2007 +0800 KVM: apic round robin cleanup If no apic is enabled in the bitmap of an interrupt delivery with delivery mode of lowest priority, a warning should be reported rather than select a fallback vcpu Signed-off-by: Qing He Signed-off-by: Eddie (Yaozu) Dong Signed-off-by: Avi Kivity commit 04817088a0e8d96587e4fb954d104d62f71df58d Author: Qing He Date: Mon Sep 24 17:22:13 2007 +0800 KVM: x86_emulator: no writeback for bt Signed-off-by: Qing He Signed-off-by: Avi Kivity commit a21855c2ed30a7a01468558bfc12a05722ef3771 Author: Laurent Vivier Date: Mon Sep 24 11:10:56 2007 +0200 KVM: x86 emulator: Remove no_wb, use dst.type = OP_NONE instead Remove no_wb, use dst.type = OP_NONE instead, idea stollen from xen-3.1 Signed-off-by: Laurent Vivier Signed-off-by: Avi Kivity commit d7f0f98414e3ab5259d54aa6ebd86a825af76980 Author: Laurent Vivier Date: Mon Sep 24 11:10:55 2007 +0200 KVM: x86 emulator: remove _eflags and use directly ctxt->eflags. Remove _eflags and use directly ctxt->eflags. Caching eflags is not needed as it is restored to vcpu by kvm_main.c:emulate_instruction() from ctxt->eflags only if emulation doesn't fail. Signed-off-by: Laurent Vivier Signed-off-by: Avi Kivity commit d98df34cc539942d8d5540ffa2425ca91056a7d3 Author: Laurent Vivier Date: Mon Sep 24 11:10:54 2007 +0200 KVM: x86 emulator: split some decoding into functions for readability To improve readability, move push, writeback, and grp 1a/2/3/4/5/9 emulation parts into functions. Signed-off-by: Laurent Vivier Signed-off-by: Avi Kivity commit 62d1ea7fdcdb905072198e4cec8f724c8ad33092 Author: Ryan Harper Date: Tue Sep 18 14:05:16 2007 -0500 KVM: MMU: Ignore reserved bits in cr3 in non-pae mode This patch removes the fault injected when the guest attempts to set reserved bits in cr3. X86 hardware doesn't generate a fault when setting reserved bits. The result of this patch is that vmware-server, running within a kvm guest, boots and runs memtest from an iso. Signed-off-by: Ryan Harper Signed-off-by: Avi Kivity commit 4acc535e64696fb09da6d2f41a5a8b8f60739c03 Author: Avi Kivity Date: Sun Sep 23 14:10:49 2007 +0200 KVM: MMU: Make flooding detection work when guest page faults are bypassed When we allow guest page faults to reach the guests directly, we lose the fault tracking which allows us to detect demand paging. So we provide an alternate mechnism by clearing the accessed bit when we set a pte, and checking it later to see if the guest actually used it. Signed-off-by: Avi Kivity commit 30649900566e8e8785b814f4a40e6660d8086873 Author: Avi Kivity Date: Sun Sep 16 18:58:32 2007 +0200 KVM: Allow not-present guest page faults to bypass kvm There are two classes of page faults trapped by kvm: - host page faults, where the fault is needed to allow kvm to install the shadow pte or update the guest accessed and dirty bits - guest page faults, where the guest has faulted and kvm simply injects the fault back into the guest to handle The second class, guest page faults, is pure overhead. We can eliminate some of it on vmx using the following evil trick: - when we set up a shadow page table entry, if the corresponding guest pte is not present, set up the shadow pte as not present - if the guest pte _is_ present, mark the shadow pte as present but also set one of the reserved bits in the shadow pte - tell the vmx hardware not to trap faults which have the present bit clear With this, normal page-not-present faults go directly to the guest, bypassing kvm entirely. Unfortunately, this trick only works on Intel hardware, as AMD lacks a way to discriminate among page faults based on error code. It is also a little risky since it uses reserved bits which might become unreserved in the future, so a module parameter is provided to disable it. Signed-off-by: Avi Kivity commit afa232aeb1676c63c5c4000a6d865cdc9455b2b5 Author: Izik Eidus Date: Sun Sep 23 12:30:19 2007 +0200 KVM: MMU: Set shadow pte atomically in mmu_pte_write_zap_pte() Setting shadow page table entry should be set atomicly using set_shadow_pte(). Signed-off-by: Izik Eidus Signed-off-by: Avi Kivity commit 99f6c824362215f3038cfe54ddcd3c940281e9cd Author: Avi Kivity Date: Fri Sep 21 05:29:13 2007 +0200 KVM: Fix ioapic edge-triggered interrupts - clear irr after service - do not service after unmasking; wait for a new edge Signed-off-by: Avi Kivity commit 5fdd2a196e7975d446fedf6973cbb20708f1359c Author: Avi Kivity Date: Thu Sep 20 12:27:28 2007 +0200 KVM: Fix host oops due to guest changing efer If the guest changes efer from long mode with sce disabled to legacy mode, then load_transition_efer() zeros vmx->host_state.guest_efer_loaded, but the SCE-disabled efer remains in effect. So when we return to the host, we disable SCE and syscalls no longer work. Fix by (a) not touching vmx->host_state.guest_efer_loaded if we're not setting it, and instead (b) clearing it explicitly when we switch back. Also switch back when the guest writes to efer so we start from a clean slate. Signed-off-by: Avi Kivity commit e8ebaa91f96407a90c1cb81708a87a25f40ba8ab Author: Laurent Vivier Date: Thu Sep 20 11:17:24 2007 +0200 KVM: x86 emulator: fix repne/repnz decoding The repnz/repne instructions must set rep_prefix to 1 like rep/repe/repz. This patch correct the disk probe problem met with OpenBSD. This issue appears with commit 091b206f6c56f2329e11bac2fa40d6f236ab0bc2 because before it, the decoding was done internally to kvm and after it is done by x86_emulate.c (which doesn't do it correctly). Signed-off-by: Laurent Vivier Signed-off-by: Avi Kivity commit 0203e2d5d0d0cea6eed6e437d9456aad71135913 Author: Avi Kivity Date: Wed Sep 19 16:08:53 2007 +0200 KVM: Implement ioapic irq polarity bit Reverse the sense of the irq level if the polarity bit is set. Signed-off-by: Avi Kivity commit faba110779451794f764a4802e740146e8efb93f Author: Avi Kivity Date: Wed Sep 19 15:48:58 2007 +0200 KVM: Avoid redelivery of edge-triggered irq if it is already in service Noticed by Eddie Dong. Signed-off-by: Avi Kivity commit 3ddc321087b0083fec2eff1bc613410fdc2e8388 Author: Laurent Vivier Date: Wed Sep 19 13:41:55 2007 +0200 KVM: x85 emulator: Correct inconcistency in between cr2 and ctxt->cr2. This patch corrects an inconcistency of cr2 introduced by the x86 emulator split. Signed-off-by: Laurent Vivier Signed-off-by: Avi Kivity commit 37d266e7330baedc52fab5cc699cff2c8cc2947e Author: Nitin A Kamble Date: Tue Sep 18 16:34:25 2007 -0700 KVM: x86 emulator: fix merge screwup due to emulator split This code has gone to wrong place in the file. Moving it back to right location. Signed-off-by: Nitin A Kamble Signed-off-by: Avi Kivity commit 1196dd4e2e6f09053335b0a91e3cc793808c00a7 Author: Avi Kivity Date: Wed Sep 19 10:52:18 2007 +0200 KVM: Fix ioapic.c compilation failure due to missing include Signed-off-by: Avi Kivity commit 44a0469583ff93240acb76085a993a1d30202679 Author: Avi Kivity Date: Wed Sep 19 10:44:58 2007 +0200 KVM: VMX: Fix build on i386 due to EFER_LMA not defined commit caba4b5c24f24bf003dd385e5658f0b682bdf0ac Author: Avi Kivity Date: Wed Aug 29 03:48:05 2007 +0300 KVM: VMX: Further reduce efer reloads KVM avoids reloading the efer msr when the difference between the guest and host values consist of the long mode bits (which are switched by hardware) and the NX bit (which is emulated by the KVM MMU). This patch also allows KVM to ignore SCE (syscall enable) when the guest is running in 32-bit mode. This is because the syscall instruction is not available in 32-bit mode on Intel processors, so the SCE bit is effectively meaningless. Signed-off-by: Avi Kivity commit 97594d420a09db38e3f2c8aa2c8481dc51c11e82 Author: Avi Kivity Date: Tue Sep 18 15:26:30 2007 +0200 KVM: Fix #UD exception delivery It doesn't have an error code, and it uses the #UD vector. Signed-off-by: Avi Kivity commit 5e7a195fc4b1c0df577658e01a25b91d49bc68ee Author: Avi Kivity Date: Tue Sep 18 14:19:00 2007 +0200 KVM: Fix ioapic level-triggered interrupt redelivery The ioapic failed to set the irr bit if a previous interrupt was already being serviced. This caused interrupt loss fairly soon, leading to loss of level-triggered devices like pic networking. This patch fixes the problem by always setting irr when an irq is asserted. Signed-off-by: Avi Kivity commit 5d9b36eec8ca6abe03da91efdfc7b5861525bd43 Author: Laurent Vivier Date: Tue Sep 18 11:27:37 2007 +0200 KVM: Call x86_decode_insn() only when needed Move emulate_ctxt to kvm_vcpu to keep emulate context when we exit from kvm module. Call x86_decode_insn() only when needed. Modify x86_emulate_insn() to not modify the context if it must be re-entered. Signed-off-by: Laurent Vivier Signed-off-by: Avi Kivity commit a00840cfcc2c18662e04ac94fcbe12266c403cad Author: Laurent Vivier Date: Tue Sep 18 11:27:27 2007 +0200 KVM: emulate_instruction() calls now x86_decode_insn() and x86_emulate_insn() emulate_instruction() calls now x86_decode_insn() and x86_emulate_insn(). x86_emulate_insn() is x86_emulate_memop() without the decoding part. Signed-off-by: Laurent Vivier Signed-off-by: Avi Kivity commit a40bf553563276cf3aff293b6ec36373bf3dc968 Author: Laurent Vivier Date: Tue Sep 18 11:27:19 2007 +0200 KVM: x86 emulator: move all decoding process to function x86_decode_insn() Split the decoding process into a new function x86_decode_insn(). Signed-off-by: Laurent Vivier Signed-off-by: Avi Kivity commit c18617e89f3a94fd74d55dde36b54c8ca23072f9 Author: Laurent Vivier Date: Tue Sep 18 11:52:50 2007 +0200 KVM: x86 emulator: move all x86_emulate_memop() to a structure Move all x86_emulate_memop() common variables between decode and execute to a structure decode_cache. This will help in later separating decode and emulate. struct decode_cache { u8 twobyte; u8 b; u8 lock_prefix; u8 rep_prefix; u8 op_bytes; u8 ad_bytes; struct operand src; struct operand dst; unsigned long *override_base; unsigned int d; unsigned long regs[NR_VCPU_REGS]; unsigned long eip; /* modrm */ u8 modrm; u8 modrm_mod; u8 modrm_reg; u8 modrm_rm; u8 use_modrm_ea; unsigned long modrm_ea; unsigned long modrm_val; }; Signed-off-by: Laurent Vivier Signed-off-by: Avi Kivity commit d6a754e5ec1ae429e7bd22a2b54e0fea1d64e1d9 Author: Laurent Vivier Date: Tue Sep 18 11:26:38 2007 +0200 KVM: x86 emulator: remove unused functions Remove #ifdef functions never used Signed-off-by: Laurent Vivier Signed-off-by: Avi Kivity commit 8db6e3d54971e76019b02a6ad860c9df35218dfc Author: Anthony Liguori Date: Mon Sep 17 14:57:50 2007 -0500 KVM: Refactor hypercall infrastructure (v3) This patch refactors the current hypercall infrastructure to better support live migration and SMP. It eliminates the hypercall page by trapping the UD exception that would occur if you used the wrong hypercall instruction for the underlying architecture and replacing it with the right one lazily. A fall-out of this patch is that the unhandled hypercalls no longer trap to userspace. There is very little reason though to use a hypercall to communicate with userspace as PIO or MMIO can be used. There is no code in tree that uses userspace hypercalls. Signed-off-by: Anthony Liguori Signed-off-by: Avi Kivity commit cd132dabf169ce61b5be58d42d9bd08984cba429 Author: Anthony Liguori Date: Mon Sep 17 14:57:49 2007 -0500 KVM: x86 emulator: Add vmmcall/vmcall to x86_emulate (v3) Add vmmcall/vmcall to x86_emulate. Future patch will implement functionality for these instructions. Signed-off-by: Anthony Liguori Signed-off-by: Avi Kivity commit 17f668f73876cb0a67404db12b843850a9426bbb Author: Avi Kivity Date: Mon Sep 17 11:02:51 2007 +0200 KVM: Fix virtualization menu help text What guest drivers? Signed-off-by: Avi Kivity commit 23263a086e85f0065f95e3cb676dd96434da98d8 Author: Avi Kivity Date: Mon Sep 17 10:59:31 2007 +0200 KVM: Remove errant printk() in kvm_vcpu_ioctl_get_sregs() Signed-off-by: Avi Kivity commit 718a3339a903ea1935148eb095c2f8ce741a54a2 Author: Avi Kivity Date: Mon Sep 17 10:58:27 2007 +0200 KVM: Fix kvm_vcpu_ioctl_get_sregs() warning on i386 Signed-off-by: Avi Kivity commit 37fa44d29fb9d9c47126e40bfe266f8bf74de43d Author: Qing He Date: Mon Sep 17 14:47:13 2007 +0800 KVM: fix PIC interrupt delivery on different APIC conditions This patch changes the PIC interrupts delivery. Now it is only deliverd to vcpu0 when either condition is met (on vcpu0): 1. local APIC is hardware disabled 2. LVT0 is unmasked and configured to delivery mode ExtInt It fixes the 2x faster wall clock on x86_64 and SMP i386 Linux guests Signed-off-by: Qing He Signed-off-by: Avi Kivity commit c408e4e8d9045d53c1d82c622a5756febd051ef9 Author: Avi Kivity Date: Sat Sep 15 17:34:36 2007 +0300 KVM: Skip pio instruction when it is emulated, not executed If we defer updating rip until pio instructions are executed, we have a problem with reset: a pio reset updates rip, and when the instruction completes we skip the emulated instruction, pointing rip somewhere completely unrelated. Fix by updating rip when we see decode the instruction, not after emulation. Signed-off-by: Avi Kivity commit 340bcebdee0382c3b1dd9f963e21e4217594467b Author: Nitin A Kamble Date: Sat Sep 15 10:45:05 2007 +0300 KVM: x86 emulator: popf Implement emulation of instruction: popf opcode: 0x9d Signed-off-by: Nitin A Kamble Signed-off-by: Avi Kivity commit 338be073d760fde05ee2f78ace4e9576dc3e6909 Author: Nitin A Kamble Date: Sat Sep 15 10:43:33 2007 +0300 KVM: x86 emulator: fix src, dst value initialization Some operand fetches are less than the machine word size and can result in stale bits if used together with operands of different sizes. Signed-off-by: Nitin A Kamble Signed-off-by: Avi Kivity commit a5f988993b5b167d007c8c33d45ad8e0f849d22a Author: Nitin A Kamble Date: Sat Sep 15 10:41:26 2007 +0300 KVM: x86 emulator: jmp abs Implement emulation of instruction: jump absolute r/m opcode: 0xff /4 Signed-off-by: Nitin A Kamble Signed-off-by: Avi Kivity commit c6aeb4632919c37317213c9b5a41bedbcc8b3416 Author: Nitin A Kamble Date: Sat Sep 15 10:35:36 2007 +0300 KVM: x86 emulator: lea Implement emulation of instruction lea r16/r32, m opcode: 0x8d: Signed-off-by: Nitin A Kamble Signed-off-by: Avi Kivity commit c9aa71c7901df4fcf1eb33721bea8b581188f2bf Author: Nitin A Kamble Date: Sat Sep 15 10:25:41 2007 +0300 KVM: X86 emulator: jump conditional short Implement emulation of more jump conditional instructions jcc shortrel opcodes: 0x70 - 0x7f Signed-off-by: Nitin A Kamble Signed-off-by: Avi Kivity commit ef70803677eec7ab37d61e48b0d1cb628c3f991b Author: Nitin A Kamble Date: Sat Sep 15 10:23:07 2007 +0300 KVM: x86 emulator: imlpement jump conditional relative Implement emulation of instruction: jump conditional rel opcodes: 0x0f 0x80 - 0x0f 0x8f Signed-off-by: Nitin A Kamble Signed-off-by: Avi Kivity commit 021854e6f9566e2990c1dfee474d4d509f84e3fd Author: Nitin A Kamble Date: Sat Sep 15 10:13:07 2007 +0300 KVM: x86 emulator: sort opcodes into ascending order Signed-off-by: Nitin A Kamble Signed-off-by: Avi Kivity commit 28621bdce24324e1f8b33fa25595cc0609153be6 Author: Sheng Yang Date: Wed Sep 12 18:03:11 2007 +0800 KVM: VMX: Prevent setting CPU_BASED_TPR_SHADOW on i386 host Though tpr shadow feature can be used on i386 host, but it needs support from virtual apic access feature which hasn't been implemented yet, otherwise it will cause trouble on i386 machine which supports this feature. This patch disables tpr shadow feature for i386 host now. Signed-off-by: Sheng Yang Signed-off-by: Qing He Signed-off-by: Avi Kivity commit 58d8159c7264eee015ad0656afd018aecbb3c69f Author: Avi Kivity Date: Wed Sep 12 13:21:09 2007 +0300 KVM: Improve emulation failure reporting Report failed opcodes from all locations. Signed-off-by: Avi Kivity commit 0fe149eb04e5e67f4d3ebc2ab9f2426356a308ba Author: Nitin A Kamble Date: Tue Aug 28 18:22:47 2007 -0700 KVM: x86 emulator: pushf Implement emulation of instruction pushf opcode: 0x9c Signed-off-by: Nitin A Kamble Signed-off-by: Avi Kivity commit 917fca3116605cfa2db01d390ba94b0412c88eb3 Author: Nitin A Kamble Date: Tue Aug 28 18:08:37 2007 -0700 KVM: x86 emulator: call near Implement emulation of instruction opcode: 0xe8 call (near) Signed-off-by: Nitin A Kamble Signed-off-by: Avi Kivity commit 2b15dbf376872112c832576cc3b3f618e0b85e2d Author: Nitin A Kamble Date: Tue Aug 28 17:58:52 2007 -0700 KVM: x86 emulator: push imm8 Implement the instruction push imm8 opcode: 0x6a Signed-off-by: Nitin A Kamble Signed-off-by: Avi Kivity commit c7c2eaa2c305ed106da78afd7b95f42cec8d6dc8 Author: He, Qing Date: Wed Sep 12 14:18:28 2007 +0800 KVM: VMX: Fix exit qualification width on i386 According to Intel Software Developer's Manual, Vol. 3B, Appendix H.4.2, exit qualification should be of natural width. However, current code uses u64 as the data type for this register, which occasionally introduces invalid value to VMExit handling logics. This patch fixes this bug. I have tested Windows and Linux guest on i386 host, and they can boot successfully with this patch. Signed-off-by: Qing He Signed-off-by: Avi Kivity commit de60b339983ae64920b1bc58bb5c2c6b10db5d93 Author: Eddie Dong Date: Wed Sep 12 10:58:04 2007 +0300 KVM: Fix link error to "genapic" GET_APIC_ID may use genapic instance for some machine configuration in i386 architecture, but it is not exported for outside usage. This patch remove this reference. Signed-off-by: Yaozu (Eddie) Dong Signed-off-by: Avi Kivity commit 0663a73e366dd1df52c0ce4fec32f47455575324 Author: Avi Kivity Date: Mon Sep 10 18:10:54 2007 +0300 KVM: Move main vcpu loop into subarch independent code This simplifies adding new code as well as reducing overall code size. Signed-off-by: Avi Kivity commit ec1ff57323b7ce5022cae99e27ff8297ce2aaa27 Author: Avi Kivity Date: Mon Sep 10 17:27:03 2007 +0300 KVM: VMX: Move vm entry failure handling to the exit handler This will help moving the main loop to subarch independent code. Signed-off-by: Avi Kivity commit 2f6ad5e1fb93c0392e6cfaf2ef2bee3aaaa19244 Author: Avi Kivity Date: Mon Sep 10 15:20:59 2007 +0300 KVM: Remove smp_processor_id() in kvm_vcpu_kick() The value is meaningless since it can change; instead call the function unconditionally. It is a no-op on the same cpu anyway. This removes annoying warning on runtime. Signed-off-by: Avi Kivity commit a40fa4c30f0883a3a4a1560e0174540d6594e0ca Author: Avi Kivity Date: Mon Sep 10 11:28:17 2007 +0300 KVM: MMU: Don't do GFP_NOWAIT allocations Before preempt notifiers, kvm needed to allocate memory with GFP_NOWAIT so as not to have to enable preemption and take a heavyweight exit. On oom, we'd fall back to a GFP_KERNEL allocation. With preemption notifiers, we can do a GFP_KERNEL allocation, and perform the heavyweight exit only if the kernel decides to put us to sleep. Signed-off-by: Avi Kivity commit 5b25a47c1edb6ba9ac23e745260e7533be371c1d Author: He, Qing Date: Mon Sep 10 11:01:52 2007 +0300 KVM: fix apic timer migration when inactive When local apic timer is inactive or is expired in one shot mode, it should not be restarted on vcpu and hrtimer migration. This patch fixes this. Signed-off-by: Qing He Signed-off-by: Avi Kivity commit e44af0f4ee99974ce40102e23784bc3cae7f4466 Author: Jindrich Makovicka Date: Sun Sep 9 18:45:01 2007 +0300 KVM: Fix lapic 64-bit division on 32-bit hosts Signed-off-by: Avi Kivity commit c54c215e7e71b99c0a3270d7fc85668179bea67a Author: Christian Ehrhardt Date: Sun Sep 9 15:41:59 2007 +0300 KVM: Rename kvm_arch_ops to kvm_x86_ops This patch just renames the current (misnamed) _arch namings to _x86 to ensure better readability when a real arch layer takes place. Signed-off-by: Christian Ehrhardt Signed-off-by: Avi Kivity commit beec957bd8205ebbd9dc2eecb166fe4ae06e31e4 Author: Laurent Vivier Date: Thu Aug 30 14:56:21 2007 +0200 KVM: Simplify memory allocation The mutex->splinlock convertion alllows us to make some code simplifications. As we can keep the lock longer, we don't have to release it and then have to check if the environment has not been modified before re-taking it. We can remove kvm->busy and kvm->memory_config_version. Signed-off-by: Laurent Vivier Signed-off-by: Avi Kivity commit f71c862171a7265085798d1aa8c43eadb6d85520 Author: Rusty Russell Date: Thu Sep 6 01:21:32 2007 +1000 KVM: Hoist SVM's get_cs_db_l_bits into core code. SVM gets the DB and L bits for the cs by decoding the segment. This is in fact the completely generic code, so hoist it for kvm-lite to use. Signed-off-by: Rusty Russell Signed-off-by: Avi Kivity commit 1cfd09dd0492b50376ed703f4252c489d91d1597 Author: Rusty Russell Date: Thu Sep 6 01:20:38 2007 +1000 KVM: Keep control regs in sync We don't update the vcpu control registers in various places. We should do so. Signed-off-by: Rusty Russell Signed-off-by: Avi Kivity commit aa38840d3d2e0a804e628077df8d8879b496d741 Author: Rusty Russell Date: Sun Sep 9 14:12:54 2007 +0300 KVM: Clean up unloved invlpg emulation invlpg shouldn't fetch the "src" address, since it may not be valid, however SVM's "solution" which neuters emulation of all group 7 instruction is horrible and breaks kvm-lite. The simplest fix is to put a special check in for invlpg. Signed-off-by: Rusty Russell Signed-off-by: Avi Kivity commit 8fa7178a4f0c96662bab31ff46e3bff1995ff14a Author: Rusty Russell Date: Sun Sep 9 14:10:57 2007 +0300 KVM: Remove the unused invlpg member of struct kvm_arch_ops. Signed-off-by: Rusty Russell Signed-off-by: Avi Kivity commit f4ed61146e11e6f42500385feee51eb30ed324d0 Author: Amit Shah Date: Sat Aug 25 11:35:52 2007 +0300 KVM: Set the ET flag in CR0 after initializing FX This was missed when moving stuff around in fbc4f2e Fixes Solaris guests and bug #1773613 Signed-off-by: Amit Shah Signed-off-by: Avi Kivity commit fe3f479c1a1564b3612a955f037a1905b85c9f6f Author: He, Qing Date: Mon Sep 3 17:07:41 2007 +0300 KVM: enable in-kernel APIC INIT/SIPI handling This patch enables INIT/SIPI handling using in-kernel APIC by introducing a ->mp_state field to emulate the SMP state transition. Signed-off-by: Qing He Signed-off-by: Xin Li commit a0c1343ffdac844fe659678928d1eb6c88e8aeb4 Author: He, Qing Date: Mon Sep 3 17:01:36 2007 +0300 KVM: round robin for APIC lowest priority delivery mode Signed-off-by: Qing He Signed-off-by: Avi Kivity commit ca7d5e3ddce0d1483fbb28ba59d7677c8935d785 Author: Eddie Dong Date: Mon Sep 3 17:00:24 2007 +0300 KVM: deliver PIC interrupt only to vcpu0 Signed-off-by: Eddie (Yaozu) Dong Signed-off-by: Avi Kivity commit 1fef0a7c83cc8ce89c6ea25225898da57ea68a63 Author: Eddie Dong Date: Mon Sep 3 16:56:58 2007 +0300 KVM: VMX: Fix tpr threshold updating The TPR threshold must be updated only after any irqs are injected. Signed-off-by: Eddie (Yaozu) Dong Signed-off-by: Avi Kivity commit 43803341a9873c3955f10352b30f5d449aae70b5 Author: He, Qing Date: Thu Aug 30 17:04:26 2007 +0800 KVM: disable tpr/cr8 sync when in-kernel APIC is used Signed-off-by: Qing He Signed-off-by: Avi Kivity commit 966b840d0d7f52fdf2062772a1477f4d2536ab8f Author: Eddie Dong Date: Mon Sep 3 16:15:12 2007 +0300 KVM: Migrate lapic hrtimer when vcpu moves to another cpu This reduces overhead by accessing cachelines from the wrong node, as well as simplifying locking. Signed-off-by: Yaozu (Eddie) Dong Signed-off-by: Avi Kivity commit 50587b4ba6352cb87212b581f3e6a4b21ee5ff7f Author: Eddie Dong Date: Sat Aug 25 18:00:41 2007 +0300 KVM: Keep track of missed timer irq injections APIC timer IRQ is set every time when a certain period expires at host time, but the guest may be descheduled at that time and thus the irq be overwritten by later fire. This patch keep track of firing irq numbers and decrease only when the IRQ is injected to guest or buffered in APIC. Signed-off-by: Yaozu (Eddie) Dong Signed-off-by: Qing He Signed-off-by: Avi Kivity commit 09fe5ff51331cc089d9d02b33ef0fc512dcd8f69 Author: Yang, Sheng Date: Mon Sep 3 16:37:44 2007 +0300 KVM: VMX: Use shadow TPR/cr8 for 64-bits guests This patch enables TPR shadow of VMX on CR8 access. 64bit Windows using CR8 access TPR frequently. The TPR shadow can improve the performance of access TPR by not causing vmexit. Signed-off-by: Sheng Yang Signed-off-by: Yaozu (Eddie) Dong Signed-off-by: Avi Kivity commit b2954a203243fa837c8c867163b00d2dee278048 Author: Eddie Dong Date: Mon Aug 6 16:29:07 2007 +0300 KVM: pending irq save/restore Add in kernel irqchip save/restore support for pending vectors. Signed-off-by: Yaozu (Eddie) Dong Signed-off-by: Qing He Signed-off-by: Avi Kivity commit 6546954a502dedf79401c7e5f564573df78e2f61 Author: Eddie Dong Date: Thu Sep 6 12:22:56 2007 +0300 KVM: in-kernel LAPIC save and restore support This patch adds a new vcpu-based IOCTL to save and restore the local apic registers for a single vcpu. The kernel only copies the apic page as a whole, extraction of registers is left to userspace side. On restore, the APIC timer is restarted from the initial count, this introduces a little delay, but works fine. Signed-off-by: Yaozu (Eddie) Dong Signed-off-by: Qing He Signed-off-by: Avi Kivity commit 3ae9777fe4c0fdc9688a8976ed105f537b5e2aea Author: He, Qing Date: Sun Aug 5 10:49:16 2007 +0300 KVM: in-kernel IOAPIC save and restore support This patch adds support for in-kernel ioapic save and restore (to and from userspace). It uses the same get/set_irqchip ioctl as in-kernel PIC. Signed-off-by: Qing He Signed-off-by: Yaozu (Eddie) Dong Signed-off-by: Avi Kivity commit 8002f6c199d9c8535ee7848f55c35d012433e75a Author: He, Qing Date: Thu Aug 2 14:03:07 2007 +0300 KVM: Bypass irq_pending get/set when using in kernel irqchip vcpu->irq_pending is saved in get/set_sreg IOCTL, but when in-kernel local APIC is used, doing this may occasionally overwrite vcpu->apic to an invalid value, as in the vm restore path. Signed-off-by: Qing He commit aae5fefba1de58a016d5c49c92c79a58ed989721 Author: He, Qing Date: Thu Jul 26 11:05:18 2007 +0300 KVM: Add get/set irqchip ioctls for in-kernel PIC live migration support This patch adds two new ioctls to dump and write kernel irqchips for save/restore and live migration. PIC s/r and l/m is implemented in this patch. Signed-off-by: Yaozu (Eddie) Dong Signed-off-by: Qing He Signed-off-by: Avi Kivity commit 6e031384c47b825dd70a6c412f214d3379ed1f83 Author: Eddie Dong Date: Sun Jul 22 10:36:31 2007 +0300 KVM: Protect in-kernel pio using kvm->lock pio operation and IRQ_LINE kvm_vm_ioctl is not kvm->lock protected. Add lock to same with IOAPIC MMIO operations. Signed-off-by: Yaozu (Eddie) Dong Signed-off-by: Avi Kivity commit 38557cfd5156f87f7f75623600b6b8c30e4e1ace Author: Eddie Dong Date: Wed Jul 18 12:15:21 2007 +0300 KVM: Emulate hlt in the kernel By sleeping in the kernel when hlt is executed, we simplify the in-kernel guest interrupt path considerably. Signed-off-by: Gregory Haskins Signed-off-by: Yaozu (Eddie) Dong Signed-off-by: Avi Kivity commit 1fd2279b67369669c95e4474a9a1e0b0b6fbb060 Author: Eddie Dong Date: Wed Jul 18 12:03:39 2007 +0300 KVM: In-kernel I/O APIC model This allows in-kernel host-side device drivers to raise guest interrupts without going to userspace. Signed-off-by: Yaozu (Eddie) Dong Signed-off-by: Avi Kivity commit d69018f178ceb0cbb93fdb4795b1b503c6899162 Author: Eddie Dong Date: Thu Sep 6 12:22:56 2007 +0300 KVM: Emulate local APIC in kernel Because lightweight exits (exits which don't involve userspace) are many times faster than heavyweight exits, it makes sense to emulate high usage devices in the kernel. The local APIC is one such device, especially for Windows and for SMP, so we add an APIC model to kvm. It also allows in-kernel host-side drivers to inject interrupts without going through userspace. Signed-off-by: Yaozu (Eddie) Dong Signed-off-by: Qing He Signed-off-by: Avi Kivity commit 7ae590c3ab0dab8a6e94965ccc2e77f9c6309a8d Author: Eddie Dong Date: Wed Jul 18 11:34:57 2007 +0300 KVM: Define and use cr8 access functions This patch is to wrap APIC base register and CR8 operation which can provide a unique API for user level irqchip and kernel irqchip. This is a preparation of merging lapic/ioapic patch. Signed-off-by: Yaozu (Eddie) Dong Signed-off-by: Avi Kivity commit 127992c791d57fa7646e5ee8de60360ea3c0bd59 Author: Eddie Dong Date: Fri Jul 6 12:20:49 2007 +0300 KVM: Add support for in-kernel PIC emulation Signed-off-by: Yaozu (Eddie) Dong Signed-off-by: Avi Kivity commit 263773f7a6606efda85f7b184a067b5f560ed39b Author: Laurent Vivier Date: Thu Aug 23 16:33:11 2007 +0200 KVM: VMX: Split segments reload in vmx_load_host_state() vmx_load_host_state() bundles fs, gs, ldt, and tss reloading into one in the hope that it is infrequent. With smp guests, fs reloading is frequent due to fs being used by threads. Unbundle the reloads so reduce expensive gs reloads. Signed-off-by: Laurent Vivier Signed-off-by: Avi Kivity commit f3e0aa2b4593e7d5dd064a3c56c919f85ef0d9eb Author: Avi Kivity Date: Wed Aug 22 18:09:29 2007 +0300 KVM: X86 emulator: fix 'push reg' writeback Pointed out by Rusty Russell. Signed-off-by: Avi Kivity commit 46a948d80db725870da4ebdf5893d8efc426446d Author: Izik Eidus Date: Mon Aug 20 18:11:00 2007 +0300 KVM: Support more memory slots Needed for mapping memory at 4GB. Signed-off-by: Izik Eidus Signed-off-by: Avi Kivity commit a88bbc1699461bab7479fdcef3ea1c12069acd1f Author: Avi Kivity Date: Mon Aug 20 15:44:39 2007 +0300 KVM: MMU: Fix rare oops on guest context switch A guest context switch to an uncached cr3 can require allocation of shadow pages, but we only recycle shadow pages in kvm_mmu_page_fault(). Move shadow page recycling to mmu_topup_memory_caches(), which is called from both the page fault handler and from guest cr3 reload. Signed-off-by: Avi Kivity commit feeb915ce6cd7a5f51b2e56b6ff8dffb959a9594 Author: Avi Kivity Date: Sun Aug 19 13:51:00 2007 +0300 KVM: Avoid calling smp_call_function_single() with interrupts disabled When taking a cpu down, we need to hardware_disable() it. Unfortunately, the CPU_DYING notifier is called with interrupts disabled, which means we can't use smp_call_function_single(). Fortunately, the CPU_DYING notifier is always called on the dying cpu, so we don't need to use the function at all and can simply call hardware_disable() directly. Tested-by: Paolo Ornati Signed-off-by: Avi Kivity commit 086f2ee50db8a1f39b0e17ab17d9c79b5964f0d7 Author: Izik Eidus Date: Sun Aug 19 22:24:58 2007 +0300 KVM: VMX: allow rmode_tss_base() to work with >2G of guest memory Signed-off-by: Izik Eidus Signed-off-by: Avi Kivity commit a843332b0445c9d60e4c9bda965b10cbe632a088 Author: Nitin A Kamble Date: Sun Aug 19 11:07:06 2007 +0300 KVM: x86 emulator: implement 'push reg' (opcodes 0x50-0x57) Signed-off-by: Nitin A Kamble Signed-off-by: Avi Kivity commit b23f94e52c4cec9e5ad404ac1426c49d64902dbf Author: Nitin A Kamble Date: Sun Aug 19 11:03:13 2007 +0300 KVM: x86 emulator: Implement 'jmp rel short' instruction (opcode 0xeb) Signed-off-by: Nitin A Kamble Signed-off-by: Avi Kivity commit 1bee2245738d473f57dcc973e16a497ff800c026 Author: Nitin A Kamble Date: Sun Aug 19 11:00:36 2007 +0300 KVM: x86 emulator: implement 'jmp rel' instruction (opcode 0xe9) Signed-off-by: Nitin A Kamble Signed-off-by: Avi Kivity commit 1757c2eb9f4a6b3b3aac1026dd15f26eb5dea041 Author: Nitin A Kamble Date: Fri Aug 17 15:17:41 2007 +0300 KVM: x86 emulator: implement 'and $imm, %{al|ax|eax}' Implement emulation of instruction and al imm8 (opcode 0x24) and ax/eax imm16/imm32 (opcode 0x25) Signed-off-by: Nitin A Kamble Signed-off-by: Avi Kivity commit 9bcbb7df435e154b148662df3721f71847a9342c Author: Sheng Yang Date: Thu Aug 16 13:01:00 2007 +0300 KVM: Communicate cr8 changes to userspace This allows running 64-bit Windows. Signed-off-by: Sheng Yang Signed-off-by: Avi Kivity commit 93d097821cce141b3c74bbf20735c6dde443715f Author: Avi Kivity Date: Wed Aug 15 15:23:34 2007 +0300 KVM: Close minor race in signal handling We need to check for signals inside the critical section, otherwise a signal can be sent which we will not notice. Also move the check before entry, so that if the signal happens before the first entry, we exit immediately instead of waiting for something to happen to the guest. Signed-off-by: Avi Kivity commit 83aecfbf44f3ba92abde47957a3c9175f1ec7165 Author: Glauber de Oliveira Costa Date: Wed Aug 15 05:36:45 2007 +0300 KVM: VMX: Don't require cr8 load/store exit capability when running on 32-bit This is because cr8 is not available on IA-32. It is just used in 64-bit mode. The rdmsr will then report this as not present, and it will lead us to return an -EIO. Signed-off-by: Glauber de Oliveira Costa Signed-off-by: Avi Kivity commit 7a3773c7d8a0b488e86b98571e5b858a222b12a5 Author: Laurent Vivier Date: Sun Aug 5 10:43:32 2007 +0300 KVM: Clean up kvm_setup_pio() Split kvm_setup_pio() into two functions, one to setup in/out pio (kvm_emulate_pio()) and one to setup ins/outs pio (kvm_emulate_pio_string()). Signed-off-by: Laurent Vivier Signed-off-by: Avi Kivity commit 091b206f6c56f2329e11bac2fa40d6f236ab0bc2 Author: Laurent Vivier Date: Sun Aug 5 10:36:40 2007 +0300 KVM: Cleanup string I/O instruction emulation Both vmx and svm decode the I/O instructions, and both botch the job, requiring the instruction prefixes to be fetched in order to completely decode the instruction. So, if we see a string I/O instruction, use the x86 emulator to decode it, as it already has all the prefix decoding machinery. This patch defines ins/outs opcodes in x86_emulate.c and calls emulate_instruction() from io_interception() (svm.c) and from handle_io() (vmx.c). It removes all vmx/svm prefix instruction decoders (get_addr_size(), io_get_override(), io_address(), get_io_count()) Signed-off-by: Laurent Vivier Signed-off-by: Avi Kivity commit 3415130f97a18f354853cab694d392553aa51af8 Author: Laurent Vivier Date: Wed Aug 1 21:51:09 2007 +0300 KVM: Remove useless assignment Line 1809 of kvm_main.c is useless, value is overwritten in line 1815: 1809 now = min(count, PAGE_SIZE / size); 1810 1811 if (!down) 1812 in_page = PAGE_SIZE - offset_in_page(address); 1813 else 1814 in_page = offset_in_page(address) + size; 1815 now = min(count, (unsigned long)in_page / size); 1816 if (!now) { Signed-off-by: Laurent Vivier Signed-off-by: Avi Kivity commit 777d55128214491c48efa4b88355c3fa38c3b057 Author: Li, Xin B Date: Wed Aug 1 21:49:10 2007 +0300 KVM: VMX: Remove a duplicated ia32e mode vm entry control Remove a duplicated ia32e mode VM Entry control definition and use the proper one. Signed-off-by: Xin Li Signed-off-by: Avi Kivity commit b6d8a8dd56ee037b64af90085dd4bd54cbf16ac5 Author: Rusty Russell Date: Wed Aug 1 14:46:11 2007 +1000 KVM: Use kmem_cache_free for kmem_cache_zalloc'ed objects We use kfree in svm.c and vmx.c, and this works, but it could break at any time. kfree() is supposed to match up with kmalloc(). Signed-off-by: Rusty Russell Signed-off-by: Avi Kivity commit c4a026d15eecb4ec9769210aa31d7992f2b87c74 Author: Rusty Russell Date: Wed Aug 1 10:48:02 2007 +1000 KVM: Add and use pr_unimpl for standard formatting of unimplemented features All guest-invokable printks should be ratelimited to prevent malicious guests from flooding logs. This is a start. Signed-off-by: Rusty Russell Signed-off-by: Avi Kivity commit 07b7ac315dfb33f8e56a3c19572a96318b8cbc43 Author: Rusty Russell Date: Wed Aug 1 10:17:06 2007 +1000 KVM: Remove unneeded kvm_dev_open and kvm_dev_release functions. Devices don't need open or release functions. Signed-off-by: Rusty Russell Signed-off-by: Avi Kivity commit 71cda75733ec3020a5ce57a31eaf300f007c67b2 Author: Rusty Russell Date: Wed Aug 1 10:12:22 2007 +1000 KVM: Remove stat_set from debugfs We shouldn't define stat_set on the debug attributes, since that will cause silent failure on writing: without a set argument, userspace will get -EACCESS. Signed-off-by: Rusty Russell Signed-off-by: Avi Kivity commit 6e0bfce30aa37a7fd5dd9c041296dfa237dae728 Author: Gabriel C Date: Wed Aug 1 16:23:10 2007 +0200 KVM: Fix defined but not used warning in drivers/kvm/vmx.c move_msr_up() is used only on X86_64 and generates a warning on !X86_64 Signed-off-by: Gabriel Craciunescu Signed-off-by: Avi Kivity commit e203ad4bcf11981df6fc1677fedbdb29f6fa38e8 Author: Rusty Russell Date: Tue Jul 31 20:46:12 2007 +1000 KVM: Remove redundant alloc_vmcs_cpu declaration alloc_vmcs_cpu is already declared (static) above, no need to redeclare. Signed-off-by: Rusty Russell Signed-off-by: Avi Kivity commit 8716bbed1f90ec805ca20a0c3264e181278c08cd Author: Rusty Russell Date: Tue Jul 31 20:42:42 2007 +1000 KVM: SVM: Make set_msr_interception more reliable set_msr_interception() is used by svm to set up which MSRs should be intercepted. It can only fail if someone has changed the code to try to intercept an MSR without updating the array of ranges. The return value is ignored anyway: it should just BUG() if it doesn't work. (A build-time failure would be better, but that's tricky). Signed-off-by: Rusty Russell Signed-off-by: Avi Kivity commit a3573510c9b6a93fffaa118e58494d439c37a17a Author: Rusty Russell Date: Tue Jul 31 20:41:14 2007 +1000 KVM: Cleanup mark_page_dirty For some reason, mark_page_dirty open-codes __gfn_to_memslot(). Signed-off-by: Rusty Russell Signed-off-by: Avi Kivity commit 087ba994ef1267032319ff2ec2d8addb8bc5a567 Author: Rusty Russell Date: Tue Jul 31 20:45:03 2007 +1000 KVM: Don't assign vcpu->cr3 if it's invalid: check first, set last sSigned-off-by: Rusty Russell Signed-off-by: Avi Kivity commit c53b35b292e58cf234aa7ca08fc679e61d4b291b Author: Yang, Sheng Date: Tue Jul 31 14:23:01 2007 +0300 KVM: VMX: Add cpu consistency check All the physical CPUs on the board should support the same VMX feature set. Add check_processor_compatibility to kvm_arch_ops for the consistency check. Signed-off-by: Sheng Yang Signed-off-by: Avi Kivity commit 2e3bac2a9a2d52b6f349296812c5b752249e3e30 Author: Rusty Russell Date: Tue Jul 31 19:57:47 2007 +1000 KVM: kvm_vm_ioctl_get_dirty_log restore "nothing dirty" optimization kvm_vm_ioctl_get_dirty_log scans bitmap to see it it's all zero, but doesn't use that information. Avi says: Looks like it was used to guard kvm_mmu_slot_remove_write_access(); optimizing the case where the guest just leaves the screen alone (which it usually does, especially in benchmarks). I'd rather reinstate that optimization. See 90cb0529dd230548a7f0d6b315997be854caea1b where the damage was done. It's pretty simple: if the bitmap is all zero, we don't need to do anything to clean it. Signed-off-by: Rusty Russell Signed-off-by: Avi Kivity commit 68fa04ca20fb8cf79e171c37bffd74466f12ad2b Author: Rusty Russell Date: Mon Jul 30 21:13:43 2007 +1000 KVM: Use alignment properties of vcpu to simplify FPU ops Now we use a kmem cache for allocating vcpus, we can get the 16-byte alignment required by fxsave & fxrstor instructions, and avoid manually aligning the buffer. Signed-off-by: Rusty Russell Signed-off-by: Avi Kivity commit 0ce565a6fc253c87f26d51c506cd13554889a598 Author: Rusty Russell Date: Mon Jul 30 21:12:19 2007 +1000 KVM: Use kmem cache for allocating vcpus Avi wants the allocations of vcpus centralized again. The easiest way is to add a "size" arg to kvm_init_arch, and expose the thus-prepared cache to the modules. Signed-off-by: Rusty Russell Signed-off-by: Avi Kivity commit 29b8a493b293639ae509c44386dc6a8ff79debd0 Author: Laurent Vivier Date: Mon Jul 30 13:41:19 2007 +0300 KVM: Remove kvm_{read,write}_guest() ... in favor of the more general emulator_{read,write}_*. Signed-off-by: Laurent Vivier Signed-off-by: Avi Kivity commit 6d2b86f131a3cbf370b4a65f6a6db63081cb6efb Author: Laurent Vivier Date: Mon Jul 30 13:35:24 2007 +0300 KVM: Change the emulator_{read,write,cmpxchg}_* functions to take a vcpu ... instead of a x86_emulate_ctxt, so that other callers can use it easily. Signed-off-by: Laurent Vivier Signed-off-by: Avi Kivity commit 80917728e43e248155c019f743655806b582b099 Author: Avi Kivity Date: Mon Jul 30 15:56:36 2007 +0300 KVM: x86 emulator: disable writeback for debug register instructions These are handled internally by the instruction. Signed-off-by: Avi Kivity commit 1c23728a5acd3a1fe5d628e23e3e4c27ee77118f Author: Rusty Russell Date: Mon Jul 30 20:08:05 2007 +1000 KVM: SVM: internal function name cleanup Changes some svm.c internal function names: 1) io_adress -> io_address (de-germanify the spelling) 2) kvm_reput_irq -> reput_irq (it's not a generic kvm function) 3) kvm_do_inject_irq -> (it's not a generic kvm function) Signed-off-by: Rusty Russell Signed-off-by: Avi Kivity commit 61736efb5398154eceafcce0337fe0621d7eeeb0 Author: Rusty Russell Date: Mon Jul 30 20:07:08 2007 +1000 KVM: SVM: de-containization container_of is wonderful, but not casting at all is better. This patch changes svm.c's internal functions to pass "struct vcpu_svm" instead of "struct kvm_vcpu" and using container_of. Signed-off-by: Rusty Russell Signed-off-by: Avi Kivity commit b15c5febefc05f04b5db04552bef18a6902e657c Author: Rusty Russell Date: Mon Jul 30 16:41:57 2007 +1000 KVM: Remove three magic numbers There are several places where hardcoded numbers are used in place of the easily-available constant, which is poor form. Signed-off-by: Rusty Russell Signed-off-by: Avi Kivity commit b21514dab8c88570bf2078249881a8210e50bafa Author: Rusty Russell Date: Mon Jul 30 16:31:43 2007 +1000 KVM: VMX: pass vcpu_vmx internally container_of is wonderful, but not casting at all is better. This patch changes vmx.c's internal functions to pass "struct vcpu_vmx" instead of "struct kvm_vcpu" and using container_of. Signed-off-by: Rusty Russell Signed-off-by: Avi Kivity commit 7d3fd03221bb8352a263249e6adb1232064e4341 Author: Rusty Russell Date: Mon Jul 30 16:29:56 2007 +1000 KVM: fx_init() needs preemption disabled while it plays with the FPU state Now that kvm generally runs with preemption enabled, we need to protect the fpu intialization sequence. Signed-off-by: Rusty Russell Signed-off-by: Avi Kivity commit 985bc8087daf3719d89e5ed28fe59eecd58fae71 Author: Shaohua Li Date: Mon Jul 23 14:51:37 2007 +0800 KVM: Convert vm lock to a mutex This allows the kvm mmu to perform sleepy operations, such as memory allocation. Signed-off-by: Shaohua Li Signed-off-by: Avi Kivity commit 8928fb48c7a7f9053a55f1d0023cbc533f2b3663 Author: Avi Kivity Date: Wed Jul 11 18:17:21 2007 +0300 KVM: Use the scheduler preemption notifiers to make kvm preemptible Current kvm disables preemption while the new virtualization registers are in use. This of course is not very good for latency sensitive workloads (one use of virtualization is to offload user interface and other latency insensitive stuff to a container, so that it is easier to analyze the remaining workload). This patch re-enables preemption for kvm; preemption is now only disabled when switching the registers in and out, and during the switch to guest mode and back. Contains fixes from Shaohua Li . Signed-off-by: Avi Kivity commit 510144c386fb650a5530311721ae9d90bf12eaee Author: Yang, Sheng Date: Sun Jul 29 11:07:42 2007 +0300 KVM: VMX: Improve the method of writing vmcs control Put cpu feature detecting part in hardware_setup, and stored the vmcs condition in global variable for further check. Signed-off-by: Sheng Yang Signed-off-by: Avi Kivity commit fbc4f2e23aa26a8537f8f147c75a632e498c39c7 Author: Rusty Russell Date: Fri Jul 27 17:16:56 2007 +1000 KVM: Dynamically allocate vcpus This patch converts the vcpus array in "struct kvm" to a pointer array, and changes the "vcpu_create" and "vcpu_setup" hooks into one "vcpu_create" call which does the allocation and initialization of the vcpu (calling back into the kvm_vcpu_init core helper). Signed-off-by: Rusty Russell Signed-off-by: Avi Kivity commit 6532f26b4f39a409475918da47844eaff219f50b Author: Gregory Haskins Date: Fri Jul 27 08:13:10 2007 -0400 KVM: Remove arch specific components from the general code struct kvm_vcpu has vmx-specific members; remove them to a private structure. Signed-off-by: Gregory Haskins Signed-off-by: Rusty Russell Signed-off-by: Avi Kivity commit 35b8e2b29b372ab285819c3b84d6db1d0165998b Author: Rusty Russell Date: Wed Jul 25 13:29:51 2007 +1000 KVM: load_pdptrs() cleanups load_pdptrs can be handed an invalid cr3, and it should not oops. This can happen because we injected #gp in set_cr3() after we set vcpu->cr3 to the invalid value, or from kvm_vcpu_ioctl_set_sregs(), or memory configuration changes after the guest did set_cr3(). We should also copy the pdpte array once, before checking and assigning, otherwise an SMP guest can potentially alter the values between the check and the set. Finally one nitpick: ret = 1 should be done as late as possible: this allows GCC to check for unset "ret" should the function change in future. Signed-off-by: Rusty Russell Signed-off-by: Avi Kivity commit 9cb698bd020974a7e950eca6285254b50b0b64d5 Author: Aurelien Jarno Date: Wed Jul 25 11:41:57 2007 +0200 KVM: Remove dead code in the cmpxchg instruction emulation The writeback fixes (02c03a326a5df825cc01de426f72e160db2b9538) let some dead code in the cmpxchg instruction emulation. Remove it. Signed-off-by: Aurelien Jarno Signed-off-by: Avi Kivity commit d9cbd1d77543d731f31e8ea5d1738d4aad81694a Author: Sheng Yang Date: Wed Jul 25 12:17:06 2007 +0300 KVM: VMX: Import some constants of vmcs from IA32 SDM This patch mainly imports some constants and rename two exist constants of vmcs according to IA32 SDM. It also adds two constants to indicate Lock bit and Enable bit in MSR_IA32_FEATURE_CONTROL, and replace the hardcode _5_ with these two bits. Signed-off-by: Sheng Yang Signed-off-by: Avi Kivity -- commit bfa6c62f98bd0602025d7b48e267d817082f5d07 Author: Aurelien Jarno Date: Wed Jul 25 10:19:54 2007 +0200 KVM: disable writeback for 0x0f 0x01 instructions. 0x0f 0x01 instructions (ie lgdt, lidt, smsw, lmsw and invlpg) does not use writeback. This patch set no_wb=1 when emulating those instructions. This fixes a regression booting the FreeBSD kernel on AMD. Signed-off-by: Aurelien Jarno Signed-off-by: Avi Kivity commit 24beb1e24843f05c3acfd20fc2fbcf4f5ab18ec7 Author: Shaohua Li Date: Mon Jul 23 14:51:39 2007 +0800 KVM: Move gfn_to_page out of kmap/unmap pairs gfn_to_page might sleep with swap support. Move it out of the kmap calls. Signed-off-by: Shaohua Li Signed-off-by: Avi Kivity commit 33c5dfed96a8cb19ccc2e08073ef97e5c731dae3 Author: Avi Kivity Date: Wed Jul 25 09:22:12 2007 +0300 KVM: Fix removal of nx capability from guest cpuid Testing the wrong bit caused kvm not to disable nx on the guest when it is disabled on the host (an mmu optimization relies on the nx bits being the same in the guest and host). This allows Windows to boot when nx is disabled on te host (e.g. when host pae is disabled). Signed-off-by: Avi Kivity commit 8d4faaba7b1ac40b96709dc244e7d81058918a08 Author: Shaohua Li Date: Mon Jul 23 14:51:32 2007 +0800 KVM: Hoist kvm_mmu_reload() out of the critical section vmx_cpu_run doesn't handle error correctly and kvm_mmu_reload might sleep with mutex changes, so I move it above. Signed-off-by: Shaohua Li Signed-off-by: Avi Kivity commit b41e5014dd8712e8de2b656617f7a7a158cd992a Author: Avi Kivity Date: Mon Jul 23 18:33:14 2007 +0300 Revert "KVM: Avoid useless memory write when possible" This reverts commit 8a1449563b3e5ede56b28cc977c8da22a17cdf51. While it does save useless updates, it (probably) defeats the fork detector, causing a massive performance loss. Signed-off-by: Avi Kivity commit 4d69bc0c78587849583d63ada004c82dc6277829 Author: Rusty Russell Date: Mon Jul 23 17:11:02 2007 +1000 KVM: Return if the pdptrs are invalid when the guest turns on PAE. Don't fall through and turn on PAE in this case. Signed-off-by: Rusty Russell Signed-off-by: Avi Kivity commit e8c2eb98b58dd135b14d87e6dd1d621bc630d919 Author: Rusty Russell Date: Mon Jul 23 17:08:21 2007 +1000 KVM: Fix unlikely kvm_create vs decache_vcpus_on_cpu race We add the kvm to the vm_list before initializing the vcpu mutexes, which can be mutex_trylock()'ed by decache_vcpus_on_cpu(). Signed-off-by: Rusty Russell Signed-off-by: Avi Kivity commit aae0954ed6ac2a00ee76fd209aa2a39bb2f43a0c Author: Avi Kivity Date: Sun Jul 22 18:48:54 2007 +0300 KVM: Correctly handle writes crossing a page boundary Writes that are contiguous in virtual memory may not be contiguous in physical memory; so split writes that straddle a page boundary. Thanks to Aurelien for reporting the bug, patient testing, and a fix to this very patch. Signed-off-by: Aurelien Jarno Signed-off-by: Avi Kivity commit 76f0301b5e4d2603d8e1ee5295db29faea660b49 Author: Avi Kivity Date: Sun Jul 22 15:51:58 2007 +0300 KVM: x86 emulator: fix faulty check for two-byte opcode Right now, the bug is harmless as we never emulate one-byte 0xb6 or 0xb7. But things may change. Noted by the mysterious Gabriel C. Signed-off-by: Avi Kivity commit 86ba3093d785da1d2d1c5ecbf060d91edd7a5092 Author: Avi Kivity Date: Sun Jul 22 12:32:57 2007 +0300 KVM: Require CONFIG_ANON_INODES Found by Sebastian Siewior and randconfig. Signed-off-by: Avi Kivity commit 6da018860ce19321e25b685b72f3836d243c2137 Author: Avi Kivity Date: Sat Jul 21 09:00:21 2007 +0300 KVM: MMU: Fix cleaning up the shadow page allocation cache __free_page() wants a struct page, not a virtual address. Signed-off-by: Avi Kivity commit 29530eb22ba3b0baf260e2767cb125b61151ed25 Author: Avi Kivity Date: Fri Jul 20 12:30:58 2007 +0300 KVM: x86 emulator: fix cmov for writeback changes The writeback fixes (02c03a326a5df825cc01de426f72e160db2b9538) broke cmov emulation. Fix. Signed-off-by: Avi Kivity commit 92bd26eb2a199716ceeb5604b8f9f5ed7e69ac3d Author: Avi Kivity Date: Fri Jul 20 08:18:27 2007 +0300 KVM: MMU: Fix oopses with SLUB The kvm mmu uses page->private on shadow page tables; so does slub, and an oops result. Fix by allocating regular pages for shadows instead of using slub. Signed-off-by: Avi Kivity commit 860852357a6590299a273f1141dbf1871df0b491 Author: Rusty Russell Date: Tue Jul 17 23:37:17 2007 +1000 KVM: Use standard CR8 flags, and fix TPR definition Intel manual (and KVM definition) say the TPR is 4 bits wide. Also fix CR8_RESEVED_BITS typo. Signed-off-by: Rusty Russell Acked-by: H. Peter Anvin Signed-off-by: Avi Kivity commit 56282e5368afbc8ec6eebb6413bbb2ec0733d0ed Author: Jeff Dike Date: Tue Jul 17 12:26:59 2007 -0400 KVM: Set exit_reason to KVM_EXIT_MMIO where run->mmio is initialized. Signed-off-by: Jeff Dike Signed-off-by: Avi Kivity commit 7e5437f39897a09e79e69bd0c8d4641f13715cc4 Author: Rusty Russell Date: Wed Jul 18 13:05:58 2007 +1000 KVM: Trivial: Use standard BITMAP macros, open-code userspace-exposed header Creating one's own BITMAP macro seems suboptimal: if we use manual arithmetic in the one place exposed to userspace, we can use standard macros elsewhere. Signed-off-by: Rusty Russell Signed-off-by: Avi Kivity commit 0dfb860def58bfb2daa000af490ed1986373fea5 Author: Rusty Russell Date: Tue Jul 17 23:34:16 2007 +1000 Use standard CR4 flags, tighten checking On this machine (Intel), writing to the CR4 bits 0x00000800 and 0x00001000 cause a GPF. The Intel manual is a little unclear, but AFIACT they're reserved, too. Also fix spelling of CR4_RESEVED_BITS. Signed-off-by: Rusty Russell Signed-off-by: Avi Kivity commit 2aee2b5274884f40475fe9ad6a7f7a3d608e0ea4 Author: Rusty Russell Date: Tue Jul 17 23:32:55 2007 +1000 Use standard CR3 flags, tighten checking The kernel now has asm/cpu-features.h: use those macros instead of inventing our own. Also spell out definition of CR3_RESEVED_BITS, fix spelling and tighten it for the non-PAE case. Signed-off-by: Rusty Russell Signed-off-by: Avi Kivity commit 688e14654b3ffb0292a209c052e7579948b17f27 Author: Rusty Russell Date: Tue Jul 17 23:19:08 2007 +1000 KVM: Trivial: Use standard CR0 flags macros from asm/cpu-features.h The kernel now has asm/cpu-features.h: use those macros instead of inventing our own. Also spell out definition of CR0_RESEVED_BITS (no code change) and fix typo. Signed-off-by: Rusty Russell Signed-off-by: Avi Kivity commit 0da5e37f4dc3df7a941ddba8863b289863e8dd40 Author: Rusty Russell Date: Tue Jul 17 23:17:55 2007 +1000 KVM: Trivial: Avoid hardware_disable predeclaration Don't pre-declare hardware_disable: shuffle the reboot hook down. Signed-off-by: Rusty Russell Signed-off-by: Avi Kivity commit 24356bfad9c4b8ba70920153aec00e78698ccb9a Author: Rusty Russell Date: Tue Jul 17 23:16:56 2007 +1000 KVM: Trivial: Comment spelling may escape grep Speling error in comment. Signed-off-by: Rusty Russell Signed-off-by: Avi Kivity commit 793551cce1b90fac232e0a38269247815fb0d02a Author: Rusty Russell Date: Tue Jul 17 23:16:11 2007 +1000 KVM: Trivial: Make decode_register() static I have shied away from touching x86_emulate.c (it could definitely use some love, but it is forked from the Xen code, and it would be more productive to cross-merge fixes). Signed-off-by: Rusty Russell Signed-off-by: Avi Kivity commit 53df15a3cae92d4528dc8de21132bed3aa929ca1 Author: Rusty Russell Date: Tue Jul 17 23:15:29 2007 +1000 KVM: Trivial: Remove unused struct cpu_user_regs declaration Signed-off-by: Rusty Russell Signed-off-by: Avi Kivity commit a9531af471c86779d28ba973cf5f54f82cfbdb8d Author: Rusty Russell Date: Tue Jul 17 23:12:26 2007 +1000 KVM: Trivial: /dev/kvm interface is no longer experimental. KVM interface is no longer experimental. Signed-off-by: Rusty Russell Signed-off-by: Avi Kivity commit 817d90b391f6c51d07bf9d6a94778a5957d46f65 Author: Avi Kivity Date: Tue Jul 17 14:20:30 2007 +0300 KVM: x86 emulator: implement rdmsr and wrmsr Allow real-mode emulation of rdmsr and wrmsr. This allows smp Windows to boot, presumably for its sipi trampoline. Signed-off-by: Avi Kivity commit 66d8a4e4d4bd470216028daabb9d887b73259c96 Author: Avi Kivity Date: Tue Jul 17 13:04:56 2007 +0300 KVM: Fix memory slot management functions for guest smp The memory slot management functions were oriented against vcpu 0, where they should be kvm-wide. This causes hangs starting X on guest smp. Fix by making the functions (and resultant tail in the mmu) non-vcpu-specific. Unfortunately this reduces the efficiency of the mmu object cache a bit. We may have to revisit this later. Signed-off-by: Avi Kivity commit 4dd0d9a876db49da29185c868cbea6c77c09c600 Author: Eddie Dong Date: Tue Jul 17 11:52:33 2007 +0300 KVM: In-kernel string pio write support Add string pio write support to support some version of Windows. Signed-off-by: Yaozu (Eddie) Dong Signed-off-by: Avi Kivity commit 7bb566d5c8661a179106579978c0c606e7fa8a93 Author: Avi Kivity Date: Tue Jul 17 11:45:55 2007 +0300 KVM:: Future-proof the exit information union ABI Note that as the size of struct kvm_run is not part of the ABI, we can add things at the end. Signed-off-by: Avi Kivity commit f2973ff11f9f8ef4b90413cea9cedd7f20639e3e Author: Jeff Dike Date: Mon Jul 16 15:24:47 2007 -0400 KVM - add hypercall nr to kvm_run Add the hypercall number to kvm_run and initialize it. This changes the ABI, but as this particular ABI was unusable before this no users are affected. Signed-off-by: Jeff Dike Signed-off-by: Avi Kivity commit 973ae594c1a65936fc09acab412be51d97b703b9 Author: Qing He Date: Thu Jul 12 12:33:56 2007 +0300 KVM: SMP: Add vcpu_id field in struct vcpu This patch adds a `vcpu_id' field in `struct vcpu', so we can differentiate BSP and APs without pointer comparison or arithmetic. Signed-off-by: Qing He Signed-off-by: Avi Kivity commit 9f5aa99d6256aa14b64683283ba1c4be910bc67e Author: Nguyen Anh Quynh Date: Wed Jul 11 14:30:54 2007 +0300 KVM: Fix *nopage() in kvm_main.c *nopage() in kvm_main.c should only store the type of mmap() fault if the pointers are not NULL. This patch fixes the problem. Signed-off-by: Nguyen Anh Quynh Signed-off-by: Avi Kivity commit 6287464e41b2b520d78d417f3d1b37aca9202a04 Author: Avi Kivity Date: Tue Jul 10 17:50:55 2007 +0300 KVM: MMU: Store nx bit for large page shadows We need to distinguish between large page shadows which have the nx bit set and those which don't. The problem shows up when booting a newer smp Linux kernel, where the trampoline page (which is in real mode, which uses the same shadow pages as large pages) is using the same mapping as a kernel data page, which is mapped using nx, causing kvm to spin on that page. Signed-off-by: Avi Kivity commit a737ba627a98f2ae66c308148c9c967c73f13f5d Author: Avi Kivity Date: Thu May 24 13:11:41 2007 +0300 KVM: Use CPU_DYING for disabling virtualization Only at the CPU_DYING stage can we be sure that no user process will be scheduled onto the cpu and oops when trying to use virtualization extensions. Signed-off-by: Avi Kivity commit 4fba051d7ec9ec1961f477d9a20311d8432738b7 Author: Avi Kivity Date: Thu May 24 13:09:41 2007 +0300 KVM: Tune hotplug/suspend IPIs The hotplug IPIs can be called from the cpu on which we are currently running on, so use on_cpu(). Similarly, drop on_each_cpu() for the suspend/resume callbacks, as we're in atomic context here and only one cpu is up anyway. Signed-off-by: Avi Kivity commit 63e8e638342401a5fd04ec310c5d0695c645e444 Author: Avi Kivity Date: Thu May 24 13:03:52 2007 +0300 KVM: Keep track of which cpus have virtualization enabled By keeping track of which cpus have virtualization enabled, we prevent double-enable or double-disable during hotplug, which is a very fatal oops. Signed-off-by: Avi Kivity commit 9b6f4dedfeb83190b6196fe201e2f33c97de1c73 Author: Avi Kivity Date: Thu May 24 12:42:10 2007 +0300 SMP: Implement on_cpu() This defines on_cpu() which is similar to smp_call_function_single() except that it works if cpu happens to be the current cpu. Can also be seen as a complement to on_each_cpu() (which also doesn't treat the current cpu specially). Signed-off-by: Avi Kivity commit 55971a0f3faab6ecdce1e17dafc6d968f3236ade Author: Avi Kivity Date: Thu May 24 12:37:34 2007 +0300 HOTPLUG: Adapt thermal throttle to CPU_DYING CPU_DYING is notified in atomic context, so no taking mutexes here. Signed-off-by: Avi Kivity commit 529bd39d193eeae66a7c0fc3b12169ea566dc0e5 Author: Avi Kivity Date: Thu May 24 12:33:15 2007 +0300 HOTPLUG: Adapt cpuset hotplug callback to CPU_DYING CPU_DYING is called in atomic context, so don't try to take any locks. Signed-off-by: Avi Kivity commit 33e6f5c2bd102cb43a1e9ae5fe210b0d5f9ac69f Author: Avi Kivity Date: Thu May 24 12:23:10 2007 +0300 HOTPLUG: Add CPU_DYING notifier KVM wants a notification when a cpu is about to die, so it can disable hardware extensions, but at a time when user processes cannot be scheduled on the cpu, so it doesn't try to use virtualization extensions after they have been disabled. This adds a CPU_DYING notification. The notification is called in atomic context on the doomed cpu. Signed-off-by: Avi Kivity commit 0d9c57e0a7ee426096af3d79114d23e50ed6d42b Author: Avi Kivity Date: Sun Jul 8 11:15:32 2007 +0300 KVM: Fix svm availability check miscompile on i386 Signed-off-by: Avi Kivity commit 222a35d12ad9ef4f4a97da496f0e038e94681d3b Author: Avi Kivity Date: Thu Jun 28 14:15:57 2007 -0400 KVM: Clean up #includes Remove unnecessary ones, and rearange the remaining in the standard order. Signed-off-by: Avi Kivity commit 41ac4b23696b12fec15191969bc18da42359861d Author: Avi Kivity Date: Thu Jun 28 08:38:16 2007 -0400 KVM: Remove kvmfs in favor of the anonymous inodes source kvm uses a pseudo filesystem, kvmfs, to generate inodes, a job that the new anonymous inodes source does much better. Cc: Davide Libenzi Signed-off-by: Avi Kivity commit cfc329b216bc3e54fe1107e8f714c7b3bc133224 Author: Joerg Roedel Date: Fri Jun 22 12:29:50 2007 +0300 KVM: SVM: Reliably detect if SVM was disabled by BIOS This patch adds an implementation to the svm is_disabled function to detect reliably if the BIOS disabled the SVM feature in the CPU. This fixes the issues with kernel panics when loading the kvm-amd module on machines where SVM is available but disabled. Signed-off-by: Joerg Roedel Signed-off-by: Avi Kivity commit a2a8a256f8d4ff1595900b810fea90e5e5911b6d Author: Avi Kivity Date: Thu Jun 21 11:54:45 2007 +0300 KVM: VMX: Remove unnecessary code in vmx_tlb_flush() A vmexit implicitly flushes the tlb; the code is bogus. Noted by Shaohua Li. Signed-off-by: Avi Kivity commit 37ebbf17fbf71ec261c57c1404ac7c50ade97c13 Author: Shaohua Li Date: Wed Jun 20 17:13:26 2007 +0800 KVM: MMU: Fix Wrong tlb flush order Need to flush the tlb after updating a pte, not before. Signed-off-by: Shaohua Li Signed-off-by: Avi Kivity commit 030421334ae91b7f6302a1cfe9c971a8991b4870 Author: Avi Kivity Date: Wed Jun 20 11:20:04 2007 +0300 KVM: VMX: Reinitialize the real-mode tss when entering real mode Protected mode code may have corrupted the real-mode tss, so re-initialize it when switching to real mode. Signed-off-by: Avi Kivity commit 8a1449563b3e5ede56b28cc977c8da22a17cdf51 Author: Luca Tettamanti Date: Tue Jun 19 22:41:38 2007 +0200 KVM: Avoid useless memory write when possible When writing to normal memory and the memory area is unchanged the write can be safely skipped, avoiding the costly kvm_mmu_pte_write. Signed-Off-By: Luca Tettamanti Signed-off-by: Avi Kivity commit ba9c20c048726037664d303362b688759fdf6e9d Author: Luca Tettamanti Date: Tue Jun 19 22:41:20 2007 +0200 KVM: Fix x86 emulator writeback When the old value and new one are the same the emulator skips the write; this is undesirable when the destination is a MMIO area and the write shall be performed regardless of the previous value. This optimization breaks e.g. a Linux guest APIC compiled without X86_GOOD_APIC. Remove the check and perform the writeback stage in the emulation unless it's explicitly disabled (currently push and some 2 bytes instructions may disable the writeback). Signed-Off-By: Luca Tettamanti Signed-off-by: Avi Kivity commit 8e770bbe8651e8d13e1d09d426657fbed0fe052a Author: Eddie Dong Date: Tue Jun 19 18:05:03 2007 +0300 KVM: Add support for in-kernel pio handlers Useful for the PIC and PIT. Signed-off-by: Yaozu (Eddie) Dong Signed-off-by: Avi Kivity commit ecd01fac443e69a574cb064d44e78ff783a1e1a4 Author: Gregory Haskins Date: Thu May 31 14:08:58 2007 -0400 KVM: VMX: Fix interrupt checking on lightweight exit With kernel-injected interrupts, we need to check for interrupts on lightweight exits too. Signed-off-by: Gregory Haskins Signed-off-by: Avi Kivity commit af93971fab7729229a45ecd64c72f56421bbcd0f Author: Gregory Haskins Date: Thu May 31 14:08:53 2007 -0400 KVM: Adds support for in-kernel mmio handlers Signed-off-by: Gregory Haskins Signed-off-by: Avi Kivity commit e0d1fb847d117124da53145b2d9b7f4d3da8e82c Author: Nitin A Kamble Date: Tue Jun 19 11:21:15 2007 +0300 KVM: Implement emulation of instruction "ret" (opcode 0xc3) Signed-off-by: Nitin A Kamble Signed-off-by: Avi Kivity commit 246e9cd14121973b3c653b990d80bcd1c2163dd5 Author: Nitin A Kamble Date: Tue Jun 19 11:16:04 2007 +0300 KVM: Implement emulation of "pop reg" instruction (opcode 0x58-0x5f) For use in real mode. Signed-off-by: Nitin A Kamble Signed-off-by: Avi Kivity commit b0c4137315fc6f711fd3a0fc82aedb61a2536ac9 Author: Avi Kivity Date: Sun Jun 17 12:24:23 2007 +0300 KVM: Bring local tree in line with origin Signed-off-by: Avi Kivity commit 6685637b211ad67bdce21bfd9f91bc888b3acb4f Author: Avi Kivity Date: Wed Jun 13 19:55:28 2007 +0300 KVM: VMX: Ensure vcpu time stamp counter is monotonous If the time stamp counter goes backwards, a guest delay loop can become infinite. This can happen if a vcpu is migrated to another cpu, where the counter has a lower value than the first cpu. Since we're doing an IPI to the first cpu anyway, we can use that to pick up the old tsc, and use that to calculate the adjustment we need to make to the tsc offset. Signed-off-by: Avi Kivity commit 8aefa5d7ac55d487af62755545ecc02bc53678af Author: Avi Kivity Date: Wed Jun 13 19:43:19 2007 +0300 KVM: Initialize the BSP bit in the APIC_BASE msr correctly Needs to be set on vcpu 0 only. Signed-off-by: Avi Kivity commit 218179e7978af0308bcbd08f6c43bd5b3607a909 Author: Avi Kivity Date: Tue Jun 12 08:58:13 2007 +0300 KVM: Require a cpu which can set 64-bit values atomically set_64bit() is not available on 80386 and i486. Noticed by Adrian Bunk. Signed-off-by: Avi Kivity commit 74a54c5cfe3a1ea3777964a9e8e7bef119ca549b Author: Shani Moideen Date: Mon Jun 11 09:31:33 2007 +0530 KVM: VMX: Replace memset(, 0, PAGESIZE) with clear_page() Signed-off-by: Shani Moideen Signed-off-by: Avi Kivity commit ff4d2f93a9459aa820b56a59e9dbd3967aa407ce Author: Shani Moideen Date: Mon Jun 11 09:28:26 2007 +0530 KVM: SVM: Replace memset(, 0, PAGESIZE) with clear_page() Signed-off-by: Shani Moideen Signed-off-by: Avi Kivity commit 3105c9a9a2d5f64c9e67745120b8ee5c205847a3 Author: Avi Kivity Date: Thu Jun 7 19:18:30 2007 +0300 KVM: Flush remote tlbs when reducing shadow pte permissions When a vcpu causes a shadow tlb entry to have reduced permissions, it must also clear the tlb on remote vcpus. We do that by: - setting a bit on the vcpu that requests a tlb flush before the next entry - if the vcpu is currently executing, we send an ipi to make sure it exits before we continue Signed-off-by: Avi Kivity commit 2c3ac418d752e7f73ca0d9081a4377278432d565 Author: Avi Kivity Date: Thu Jun 7 19:11:53 2007 +0300 KVM: Keep an upper bound of initialized vcpus That way, we don't need to loop for KVM_MAX_VCPUS for a single vcpu vm. Signed-off-by: Avi Kivity commit 7ca30c3f2efbf9ab5ab595d9bc3e0bd3b705aba1 Author: Avi Kivity Date: Tue Jun 5 16:15:51 2007 +0300 KVM: Emulate hlt on real mode for Intel This has two use cases: the bios can't boot from disk, and guest smp bootstrap. Signed-off-by: Avi Kivity commit e7ebb74dbacc100cfd621157ac63b95e63e3292d Author: Avi Kivity Date: Tue Jun 5 15:53:05 2007 +0300 KVM: Move duplicate halt handling code into kvm_main.c Will soon have a thid user. Signed-off-by: Avi Kivity commit a80408da7a05e0be2ae99ad47dafd4bb4bc847cd Author: Avi Kivity Date: Tue Jun 5 14:37:09 2007 +0300 KVM: Enable guest smp As we don't support guest tlb shootdown yet, this is only reliable for real-mode guests. Signed-off-by: Avi Kivity commit 80b70c068ce4333e5e1242f32f538835a4e5d896 Author: Avi Kivity Date: Tue Jun 5 14:36:10 2007 +0300 KVM: Fix adding an smp virtual machine to the vm list If we add the vm once per vcpu, we corrupt the list if the guest has multiple vcpus. Signed-off-by: Avi Kivity commit 16fb83998b62717831dca3d913455091c855b3cd Author: Avi Kivity Date: Tue Jun 5 12:17:03 2007 +0300 KVM: Fix vcpu freeing for guest smp A vcpu can pin up to four mmu shadow pages, which means the freeing loop will never terminate. Fix by first unpinning shadow pages on all vcpus, then freeing shadow pages. Signed-off-by: Avi Kivity commit 55ae364d6a882c94511db17e8023c8976d44cd2d Author: Nguyen Anh Quynh Date: Tue Jun 5 10:35:19 2007 +0300 KVM: Remove unnecessary initialization and checks in mark_page_dirty() Signed-off-by: Avi Kivity commit 0ae1aebcc9825fba4d115c197e9c099fd9644caf Author: Robert P. J. Day Date: Sun Jun 3 13:35:29 2007 -0400 KVM: Replace C code with call to ARRAY_SIZE() macro. Signed-off-by: Robert P. J. Day Signed-off-by: Avi Kivity commit 4b82b37a35a085a07d9ed84efee06c69655fd3d1 Author: Avi Kivity Date: Mon Jun 4 15:58:30 2007 +0300 KVM: Lazy guest cr3 switching Switch guest paging context may require us to allocate memory, which might fail. Instead of wiring up error paths everywhere, make context switching lazy and actually do the switch before the next guest entry, where we can return an error if allocation fails. Signed-off-by: Avi Kivity commit fa8cfb020b0ef0acef94ddc9035b932308840314 Author: Avi Kivity Date: Mon Jun 4 11:11:23 2007 +0300 KVM: VMX: Fix asm constraint "g" can select a memory location, in which case size information is lost and gas needs an instruction suffix. Since the suffix is different for i386 and x86_64, we simply change the constraint to "r". Signed-off-by: Avi Kivity commit 63275ba244275719d6fd4d77c10d6b15586aa727 Author: Avi Kivity Date: Thu May 31 18:28:51 2007 +0300 KVM: MMU: Remove unused large page marker This has not been used for some time, as the same information is available in the page header. Signed-off-by: Avi Kivity commit 21e3670e57c34809d4c141ce1dde4fd8b23a4d60 Author: Avi Kivity Date: Thu May 31 18:24:09 2007 +0300 KVM: MMU: Don't cache guest access bits in the shadow page table This was once used to avoid accessing the guest pte when upgrading the shadow pte from read-only to read-write. But usually we need to set the guest pte dirty or accessed bits anyway, so this wasn't really exploited. Signed-off-by: Avi Kivity commit 319d035ef290b510edb7f848d41098c31ceaace0 Author: Avi Kivity Date: Thu May 31 18:20:14 2007 +0300 KVM: MMU: Simpify accessed/dirty/present/nx bit handling Always set the accessed and dirty bit (since having them cleared causes a read-modify-write cycle), always set the present bit, and copy the nx bit from the guest. Signed-off-by: Avi Kivity commit 080e7fd753ec60140ea89ebb0ea94625ae541534 Author: Avi Kivity Date: Thu May 31 17:17:06 2007 +0300 KVM: MMU: Remove cr0.wp tricks No longer needed as we do everything in one place. Signed-off-by: Avi Kivity commit cc9d465c7a9ef3a109814fa866676f876ff42133 Author: Avi Kivity Date: Thu May 31 15:46:04 2007 +0300 KVM: MMU: Make setting shadow ptes atomic on i386 Signed-off-by: Avi Kivity commit 823c30e8740ad71bd9556f3cd235231ad00bfa55 Author: Avi Kivity Date: Thu May 31 15:23:35 2007 +0300 KVM: Make shadow pte updates atomic With guest smp, a second vcpu might see partial updates when the first vcpu services a page fault. So delay all updates until we have figured out what the pte should look like. Note that on i386, this is still not completely atomic as a 64-bit write will be split into two on a 32-bit machine. Signed-off-by: Avi Kivity commit b7bd6888968e797f2deaa4aa9f98466a2371392b Author: Avi Kivity Date: Thu May 31 15:14:09 2007 +0300 KVM: Move shadow pte modifications from set_pte/set_pde to set_pde_common() We want all shadow pte modifications in one place. Signed-off-by: Avi Kivity commit b70ccb0b3fd4ac02c0f6cf5153008c736fa27710 Author: Avi Kivity Date: Thu May 31 15:08:29 2007 +0300 KVM: MMU: Fold fix_write_pf() into set_pte_common() This prevents some work from being performed twice, and, more importantly, reduces the number of places where we modify shadow ptes. Signed-off-by: Avi Kivity commit ad5555224aa01b2ddcc45ab9f0172b5497a7cd5d Author: Avi Kivity Date: Thu May 31 11:56:54 2007 +0300 KVM: MMU: Fold fix_read_pf() into set_pte_common() Signed-off-by: Avi Kivity commit 3f1380d422cbd5b9231c3e997e4cbec000e3a08f Author: Avi Kivity Date: Thu May 31 11:45:18 2007 +0300 KVM: MMU: Pass the guest pde to set_pte_common We will need the accessed bit (in addition to the dirty bit) and also write access (for setting the dirty bit) in a future patch. Signed-off-by: Avi Kivity commit 5fe13ee0e2b404dd34dea17ec0849b4a940a5755 Author: Avi Kivity Date: Wed May 30 19:31:17 2007 +0300 KVM: MMU: Move set_pte_common() to pte width dependent code In preparation of some modifications. Signed-off-by: Avi Kivity commit 5ada0f87635fa10a40a22b8b249c3d1fedb79840 Author: Avi Kivity Date: Wed May 30 14:21:51 2007 +0300 KVM: MMU: Simplify fetch() a little bit Signed-off-by: Avi Kivity commit 67310badceaed0519cb8efbe6054d790563ea136 Author: Avi Kivity Date: Wed May 30 12:34:53 2007 +0300 KVM: MMU: Use slab caches for shadow pages and their headers Use slab caches instead of a simple custom list. Signed-off-by: Avi Kivity commit 6d9d80f421f77da043b8b6898e01327763adecd2 Author: Eddie Dong Date: Tue May 29 15:07:21 2007 +0300 KVM: Use symbolic constants instead of magic numbers Signed-off-by: Avi Kivity commit 4eaa906699812e2e28c3237cfedd8c21cbd17c4b Author: Markus Rechberger Date: Sun May 27 10:46:52 2007 +0300 KVM: Fix includes KVM compilation fails for some .configs. This fixes it. Signed-off-by: Markus Rechberger Signed-off-by: Avi Kivity commit d67c455e06a1eaf8ab20b5c4e51f4ae8271b2637 Author: Avi Kivity Date: Thu May 24 11:17:33 2007 +0300 KVM: x86 emulator: implement wbinvd Vista seems to trigger it. Signed-off-by: Avi Kivity commit fc1193d546ec21c279a8e4e3e9eaf999275b2223 Author: Jan Engelhardt Date: Wed May 23 14:22:11 2007 -0700 Use menuconfig objects II - KVM/Virt Make a "menuconfig" out of the Kconfig objects "menu, ..., endmenu", so that the user can disable all the options in that menu at once instead of having to disable each option separately. Signed-off-by: Jan Engelhardt Signed-off-by: Andrew Morton Signed-off-by: Avi Kivity commit a6935dbdaa7278d5e4a4d7478f29462f2a5db7fe Author: Avi Kivity Date: Mon May 21 09:15:47 2007 +0300 KVM: VMX: Remove warnings on i386 Signed-off-by: Avi Kivity commit 1ab29f3fb765b08e65de563d9053d4d05cc95f52 Author: Eddie Dong Date: Mon May 21 07:28:09 2007 +0300 KVM: VMX: Avoid saving and restoring msr_efer on lightweight vmexit MSR_EFER.LME/LMA bits are automatically save/restored by VMX hardware, KVM only needs to save NX/SCE bits at time of heavy weight VM Exit. But clearing NX bits in host envirnment may cause system hang if the host page table is using EXB bits, thus we leave NX bits as it is. If Host NX=1 and guest NX=0, we can do guest page table EXB bits check before inserting a shadow pte (though no guest is expecting to see this kind of gp fault). If host NX=0, we present guest no Execute-Disable feature to guest, thus no host NX=0, guest NX=1 combination. This patch reduces raw vmexit time by ~27%. Signed-off-by: Yaozu (Eddie) Dong Signed-off-by: Avi Kivity commit 64ce9a0cf0960f9a029e54d1bffc06123d3b5893 Author: Eddie Dong Date: Sun May 20 16:28:59 2007 +0300 KVM: VMX: Fix a typo which mixes X86_64 and CONFIG_X86_64 This prevents compilation on 64-bits. Signed-off-by: Yaozu (Eddie) Dong Signed-off-by: Avi Kivity commit cc1d717e078464a049cf8364417ec44267cd6143 Author: Eddie Dong Date: Sun May 20 10:50:08 2007 +0300 KVM: VMX: Cleanup redundant code in MSR set Signed-off-by: Yaozu (Eddie) Dong Signed-off-by: Avi Kivity commit 8bf50c5c6b2af81355412ec1696a7e2c8ad940f2 Author: Daniel Hecken Date: Sun May 20 10:32:14 2007 +0300 KVM: VMX: Compile-fix for 32-bit hosts Signed-off-by: Avi Kivity commit f552bf62c86b383dd74030c5830c8043bf41e0bd Author: Eddie Dong Date: Thu May 17 18:55:15 2007 +0300 KVM: VMX: Avoid saving and restoring msrs on lightweight vmexit In a lightweight exit (where we exit and reenter the guest without scheduling or exiting to userspace in between), we don't need various msrs on the host, and avoiding shuffling them around reduces raw exit time by 8%. Signed-off-by: Yaozu (Eddie) Dong Signed-off-by: Avi Kivity commit 8edb11391b763357734cc5fd293d788d8591e6d7 Author: Nitin A Kamble Date: Thu May 17 15:50:34 2007 +0300 KVM: VMX: Handle #SS faults from real mode Instructions with address size override prefix opcode 0x67 Cause the #SS fault with 0 error code in VM86 mode. Forward them to the emulator. Signed-Off-By: Nitin A Kamble Signed-off-by: Avi Kivity commit bdf3f418471ba3c65aa78a1943da179d8320fdf8 Author: Avi Kivity Date: Mon May 14 20:41:13 2007 +0300 KVM: VMX: Use local labels in inline assembly This makes oprofile dumps and disassebly easier to read. Signed-off-by: Avi Kivity commit ca76d209b88c344fc6a8eac17057c0088a3d6940 Author: Avi Kivity Date: Sun May 13 20:18:14 2007 +0300 KVM: Remove merge artifact Signed-off-by: Avi Kivity commit 52916bb7c142b5cf8a81da225bf51c2ea60c5b49 Author: Avi Kivity Date: Tue May 8 11:34:07 2007 +0300 KVM: Fix vmx I/O bitmap initialization on highmem systems kunmap() expects a struct page, not a virtual address. Fixes an oops loading kvm-intel.ko on i386 with CONFIG_HIGHMEM. Thanks to Michael Ivanov for reporting. Signed-off-by: Avi Kivity commit facc2faaf471ca539ddd96fdbdf2e147421468a6 Author: Avi Kivity Date: Mon May 7 10:55:37 2007 +0300 KVM: Avoid corrupting tr in real mode The real mode tr needs to be set to a specific tss so that I/O instructions can function. Divert the new tr values to the real mode save area from where they will be restored on transition to protected mode. This fixes some crashes on reboot when the bios accesses an I/O instruction. Signed-off-by: Avi Kivity commit 05eb943c9b547ecc4de850f04ed4c09356440528 Author: Avi Kivity Date: Sun May 6 16:10:01 2007 +0300 KVM: VMX: Only reload guest msrs if they are already loaded If we set an msr via an ioctl() instead of by handling a guest exit, we have the host state loaded, so reloading the msrs would clobber host state instead of guest state. This fixes a host oops (and loss of a cpu) on a guest reboot. Signed-off-by: Avi Kivity commit 242b0f9ae76651226fb42d9ec3ecb1a9d8d7b263 Author: Avi Kivity Date: Sun May 6 15:50:58 2007 +0300 KVM: MMU: Store shadow page tables as kernel virtual addresses, not physical Simpifies things a bit. Signed-off-by: Avi Kivity commit 03aeb06a4440265777ae4ed62e8431955cbea865 Author: Avi Kivity Date: Sun May 6 15:36:30 2007 +0300 KVM: MMU: Simplify kvm_mmu_free_page() a tiny bit Signed-off-by: Avi Kivity commit f66b4a983d460d68ef5cc392285190065b0617e5 Author: Matthew Gregan Date: Sun May 6 10:59:46 2007 +0300 KVM: Implement IA32_EBL_CR_POWERON msr Attempting to boot the default 'bsd' kernel of OpenBSD 4.1 i386 in a guest fails early in the kernel init inside p3_get_bus_clock while trying to read the IA32_EBL_CR_POWERON MSR. KVM logs an 'unhandled MSR' message and the guest kernel faults. This patch is sufficient to allow OpenBSD to boot, after which it seems to run fine. I'm not sure if this is the correct solution for dealing with this particular MSR, but it works for me. Signed-off-by: Matthew Gregan Signed-off-by: Avi Kivity commit 7a57011a5e7c4082fdfd204115a8212298ef723f Author: Avi Kivity Date: Wed May 2 23:06:22 2007 +0300 KVM: Set cr0.mp for guests This allows fwait instructions to be trapped when the guest fpu is not loaded. Signed-off-by: Avi Kivity commit 90fb720a59dafb11d591a8e53a4a65bfa6fcfea9 Author: Avi Kivity Date: Wed May 2 22:57:13 2007 +0300 KVM: Ensure host cr0.ts is saved Otherwise, host fpu state may be corrupted after an exit. Signed-off-by: Avi Kivity commit 7616f59b208b088afd85d40aa06ca6d4d4a6ca1a Author: Avi Kivity Date: Wed May 2 20:40:00 2007 +0300 KVM: Consolidate guest fpu activation and deactivation Easier to keep track of where the fpu is this way. Signed-off-by: Avi Kivity commit 7ca14868fd7f3c0dc21450e61cca5b77a47daf0d Author: Avi Kivity Date: Wed May 2 17:57:40 2007 +0300 KVM: Rationalize exception bitmap usage Everyone owns a piece of the exception bitmap, but they happily write to the entire thing like there's no tomorrow. Centralize handling in update_exception_bitmap() and have everyone call that. Signed-off-by: Avi Kivity commit de32f820227fbe3e159ec42ce8fd55057155edca Author: Avi Kivity Date: Wed May 2 17:33:43 2007 +0300 KVM: Move some more msr mangling into vmx_save_host_state() Signed-off-by: Avi Kivity commit fa580ecc53536620546659740ae2dfcea763d17c Author: Avi Kivity Date: Wed May 2 17:30:48 2007 +0300 KVM: Prevent guest fpu state from leaking into the host The lazy fpu changes did not take into account that some vmexit handlers can sleep. Move loading the guest state into the inner loop so that it can be reloaded if necessary, and move loading the host state into vmx_vcpu_put() so it can be performed whenever we relinquish the vcpu. Signed-off-by: Avi Kivity commit bc8dcc2107de0ba8f25fc910c4559ebe3df33045 Author: Avi Kivity Date: Wed May 2 16:54:03 2007 +0300 KVM: Fix potential guest state leak into host The lightweight vmexit path avoids saving and reloading certain host state. However in certain cases lightweight vmexit handling can schedule() which requires reloading the host state. So we store the host state in the vcpu structure, and reloaded it if we relinquish the vcpu. Signed-off-by: Avi Kivity commit 11bdaf6e26c0cbabd9b6c8f2e9de60190815d348 Author: Avi Kivity Date: Tue May 1 18:24:38 2007 +0300 KVM: Increase mmu shadow cache to 1024 pages This improves kbuild times by about 10%, bringing it within a respectable 25% of native. Signed-off-by: Avi Kivity commit d6540cdffea466f1ee17a52ef530d40577b476b2 Author: Avi Kivity Date: Tue May 1 16:53:31 2007 +0300 KVM: Update shadow pte on write to guest pte A typical demand page/copy on write pattern is: - page fault on vaddr - kvm propagates fault to guest - guest handles fault, updates pte - kvm traps write, clears shadow pte, resumes guest - guest returns to userspace, re-faults on same vaddr - kvm installs shadow pte, resumes guest - guest continues So, three vmexits for a single guest page fault. But if instead of clearing the page table entry, we update to correspond to the value that the guest has just written, we eliminate the third vmexit. This patch does exactly that, reducing kbuild time by about 10%. Signed-off-by: Avi Kivity commit 807762acc40f7cc16aefcfaef8a596a4af988b20 Author: Avi Kivity Date: Tue May 1 16:44:05 2007 +0300 KVM: MMU: Respect nonpae pagetable quadrant when zapping ptes When a guest writes to a page that has an mmu shadow, we have to clear the shadow pte corresponding to the memory location touched by the guest. Now, in nonpae mode, a single guest page may have two or four shadow pages (because a nonpae page maps 4MB or 4GB, whereas the pae shadow maps 2MB or 1GB), so we when we look up the page we find up to three additional aliases for the page. Since we _clear_ the shadow pte, it doesn't matter except for a slight performance penalty, but if we want to _update_ the shadow pte instead of clearing it, it is vital that we don't modify the aliases. Fortunately, exactly which page is needed (the "quadrant") is easily computed, and is accessible in the shadow page header. All we need is to ignore shadow pages from the wrong quadrants. Signed-off-by: Avi Kivity commit 4a5c1655c9f6df8c668428d3c5d2ad4f67dce08d Author: Avi Kivity Date: Tue May 1 14:16:52 2007 +0300 KVM: Unify kvm_mmu_pre_write() and kvm_mmu_post_write() Instead of calling two functions and repeating expensive checks, call one function and provide it with before/after information. Signed-off-by: Avi Kivity commit ff31cf26ff8e17c2f7164c39dc03fe309ed36506 Author: Avi Kivity Date: Tue May 1 11:32:28 2007 +0300 KVM: Be more careful restoring fs on lightweight vmexit i386 wants fs for accessing the pda even on a lightweight exit, so ensure we can always restore it. This fixes a regression on i386 introduced by the lightweight vmexit patch. Signed-off-by: Avi Kivity commit e6d2f6292194c931b2fa11373a66d640245e1b14 Author: Avi Kivity Date: Mon Apr 30 17:05:38 2007 +0300 KVM: Reduce misfirings of the fork detector The kvm mmu tries to detects forks by looking for repeated writes to a page table. If it sees a fork, it unshadows the page table so the page table copying can proceed at native speed instead of being emulated. However, the detector also triggered on simple demand paging access patterns: a linear walk of memory would of course cause repeated writes to the same pagetable page, causing it to unshadow prematurely. Fix by resetting the fork detector if we detect a demand fault. Signed-off-by: Avi Kivity commit f908e27039ab637013ad17c64e4ef77c4c0a24b8 Author: Avi Kivity Date: Mon Apr 30 16:15:58 2007 +0300 KVM: Unindent some code Signed-off-by: Avi Kivity commit 5cf48c367dec74ba8553c53ed332cd075fa38b88 Author: Avi Kivity Date: Mon Apr 30 16:07:54 2007 +0300 KVM: Avoid saving and restoring some host CPU state on lightweight vmexit Many msrs and the like will only be used by the host if we schedule() or return to userspace. Therefore, we avoid saving them if we handle the exit within the kernel, and if a reschedule is not requested. Based on a patch from Eddie Dong with a couple of fixes by me. Signed-off-by: Yaozu(Eddie) Dong Signed-off-by: Avi Kivity commit 2d8d6944a2249f642420bbc70b199182c70ebc9a Author: Avi Kivity Date: Mon Apr 30 14:47:02 2007 +0300 KVM: Assume that writes smaller than 4 bytes are to non-pagetable pages This allows us to remove write protection earlier than otherwise. Should some mad OS choose to use byte writes to update pagetables, it will suffer a performance hit, but still work correctly. Signed-off-by: Avi Kivity commit 7d0e7eed6200c54462e884abc8dd6681df2f5e7d Author: Avi Kivity Date: Mon Apr 30 12:42:43 2007 +0300 KVM: Fix RMW mmio handling Commit 9bf671a47ed6af3164524a31dbef9360f1b66fb5 optimized the mmio read path by returning to the emulator directly after an mmio read request. But we may also need to return back to userspace in case the instruction was a read-modify-write instruction, which means we need to issue a write after completion of the read instead of returning to the guest. Signed-off-by: Avi Kivity commit f05f41f9bb1cf72a13caf61c2931dbbf4bff51eb Author: Anthony Liguori Date: Mon Apr 30 09:48:11 2007 +0300 KVM: SVM: Allow direct guest access to PC debug port The PC debug port is used for IO delay and does not require emulation. Signed-off-by: Anthony Liguori Signed-off-by: Avi Kivity commit 99c7b51d71c0b0062b752c5f0a4b3498d3d165db Author: He, Qing Date: Mon Apr 30 09:45:24 2007 +0300 KVM: VMX: Enable io bitmaps to avoid IO port 0x80 VMEXITs This patch enables IO bitmaps control on vmx and unmask the 0x80 port to avoid VMEXITs caused by accessing port 0x80. 0x80 is used as delays (see include/asm/io.h), and handling VMEXITs on its access is unnecessary but slows things down. This patch improves kernel build test at around 3%~5%. Because every VM uses the same io bitmap, it is shared between all VMs rather than a per-VM data structure. Signed-off-by: Qing He Signed-off-by: Avi Kivity commit c06d7c14c006c5e2dcd2a7d84603b51e9e60d7a7 Author: Avi Kivity Date: Sun Apr 29 16:25:49 2007 +0300 KVM: Remove unused 'instruction_length' As we no longer emulate in userspace, this is meaningless. We don't compute it on SVM anyway. Signed-off-by: Avi Kivity commit 20426d1309353b3e2771f9c7f534e01ce7a019f2 Author: Avi Kivity Date: Sun Apr 29 15:02:17 2007 +0300 KVM: Don't require explicit indication of completion of mmio or pio It is illegal not to return from a pio or mmio request without completing it, as mmio or pio is an atomic operation. Therefore, we can simplify the userspace interface by avoiding the completion indication. Signed-off-by: Avi Kivity commit 9bf671a47ed6af3164524a31dbef9360f1b66fb5 Author: Avi Kivity Date: Wed Mar 14 15:54:54 2007 +0200 KVM: Remove extraneous guest entry on mmio read When emulating an mmio read, we actually emulate twice: once to determine the physical address of the mmio, and, after we've exited to userspace to get the mmio value, we emulate again to place the value in the result register and update any flags. But we don't really need to enter the guest again for that, only to take an immediate vmexit. So, if we detect that we're doing an mmio read, emulate a single instruction before entering the guest again. Signed-off-by: Avi Kivity commit 8dfdb0d81fb9e858c14e03fd5e007b20167cd065 Author: Avi Kivity Date: Sun Apr 29 13:01:34 2007 +0300 KVM: Remove trailing whitespace Signed-off-by: Avi Kivity commit 1628bcc25417eae4c83ca87e0899c7e02961d975 Author: Signed-off-by: Anthony Liguori Date: Sun Apr 29 11:56:06 2007 +0300 KVM: SVM: Only save/restore MSRs when needed We only have to save/restore MSR_GS_BASE on every VMEXIT. The rest can be saved/restored when we leave the VCPU. Since we don't emulate the DEBUGCTL MSRs and the guest cannot write to them, we don't have to worry about saving/restoring them at all. This shaves a whopping 40% off raw vmexit costs on AMD. Signed-off-by: Anthony Liguori Signed-off-by: Avi Kivity commit 68ba823bbe6d546e3ceb63d006c62a84e92837db Author: Adrian Bunk Date: Sat Apr 28 21:20:48 2007 +0200 KVM: fix an if() condition It might have worked in this case since PT_PRESENT_MASK is 1, but let's express this correctly. Signed-off-by: Adrian Bunk Signed-off-by: Avi Kivity commit fe7dc1f2c0c3d0c21abf9dfa4387f0b748080688 Author: Anthony Liguori Date: Fri Apr 27 09:29:49 2007 +0300 KVM: VMX: Add lazy FPU support for VT Only save/restore the FPU host state when the guest is actually using the FPU. Signed-off-by: Anthony Liguori Signed-off-by: Avi Kivity commit 4a579478e5259df8828a8b9e5b3ddac2a946ce88 Author: Anthony Liguori Date: Fri Apr 27 09:29:21 2007 +0300 KVM: VMX: Properly shadow the CR0 register in the vcpu struct Set all of the host mask bits for CR0 so that we can maintain a proper shadow of CR0. This exposes CR0.TS, paving the way for lazy fpu handling. Signed-off-by: Anthony Liguori Signed-off-by: Avi Kivity commit aad1187a6c0201701026cdb2f7f6eeb49b2af4a2 Author: Avi Kivity Date: Wed Apr 25 16:57:46 2007 +0300 KVM: Move need_resched() check to common code Pointed out by Anthony Liguori. Signed-off-by: Avi Kivity commit b08487bd204708241c9b71ebfc555e334a4e4711 Author: Eddie Dong Date: Wed Apr 25 16:49:19 2007 +0300 KVM: VMX: Avoid unnecessary vcpu_load()/vcpu_put() cycles By checking if a reschedule is needed, we avoid dropping the vcpu. Signed-off-by: Avi Kivity commit 25900fd20d141145348178ffe91948e47c83e2ab Author: Avi Kivity Date: Wed Apr 25 11:51:06 2007 +0300 KVM: Avoid unused function warning due to assertion removal Signed-off-by: Avi Kivity commit 2bd9b992631841b1be5883a5c27b9c58ae9bb96a Author: Avi Kivity Date: Wed Apr 25 11:48:45 2007 +0300 KVM: We want asserts on debug builds, not release Noticed by Michael Riepe. Signed-off-by: Avi Kivity commit c3efc3ab86aa651106f6302592e25c7ab8285c35 Author: Avi Kivity Date: Thu Apr 12 13:03:01 2007 +0300 KVM: Initialize cr0 to indicate an fpu is present Solaris panics if it sees a cpu with no fpu, and it seems to rely on this bit. Closes sourceforge bug 1698920. Signed-off-by: Avi Kivity commit 28b183145d34a8ad1bc462df565165a88bcb5220 Author: Yaozu Dong Date: Wed Apr 25 14:17:25 2007 +0800 KVM: MMU: Avoid heavy ASSERT at non debug mode. Signed-off-by: Avi Kivity commit 418987aef13b475140b76f9f780046d63eb16f86 Author: Avi Kivity Date: Wed Apr 25 11:01:28 2007 +0300 KVM: Document MSR_K6_STAR's special place in the msr index array Signed-off-by: Avi Kivity commit 90ca9e3d54c8b0ac2023c624d1c7260bb8926beb Author: Avi Kivity Date: Wed Apr 25 10:59:52 2007 +0300 KVM: Don't complain about cpu erratum AA15 It slows down Windows x64 horribly. Signed-off-by: Avi Kivity commit 6f19cb49965e1316b285a443c9392031b1634f2e Author: Avi Kivity Date: Tue Apr 24 14:13:01 2007 +0300 KVM: Fix msr-avoidance regression on Core processors Core processors don't have the STAR msr, so the attempt not to save it caused an underflow in the number of msrs. Fix by only avoiding the STAR msr if it is actually present. Signed-off-by: Avi Kivity commit ccf9e2f22e5caf6274b5e9aafd9814a32ef049d5 Author: Anthony Liguori Date: Mon Apr 23 09:17:21 2007 -0500 KVM: Lazy FPU support for SVM Avoid saving and restoring the guest fpu state on every exit. This shaves ~100 cycles off the guest/host switch. Signed-off-by: Anthony Liguori Signed-off-by: Avi Kivity commit d558e0b49319cfc9aa92e9b7215580f265a2ead7 Author: Avi Kivity Date: Sun Apr 22 15:28:19 2007 +0300 KVM: Allow passing 64-bit values to the emulated read/write API This simplifies the API somewhat (by eliminating the special-case cmpxchg8b on i386). Signed-off-by: Avi Kivity commit 551284356a39f20de70cd5556e85ae92080aec8c Author: Avi Kivity Date: Fri Apr 20 13:41:09 2007 +0300 KVM: Silence compile warning on i386 Signed-off-by: Avi Kivity commit 459377fe9ba4a307144ead3ad86993cdee9f8fe8 Author: Avi Kivity Date: Thu Apr 19 17:27:43 2007 +0300 KVM: Per-vcpu statistics Make the exit statistics per-vcpu instead of global. This gives a 3.5% boost when running one virtual machine per core on my two socket dual core (4 cores total) machine. Signed-off-by: Avi Kivity commit 5c828f83928f186320d74627089122ebc9ea98ce Author: Avi Kivity Date: Thu Apr 19 14:28:44 2007 +0300 KVM: VMX: Only save/restore MSR_K6_STAR if necessary Intel hosts only support syscall/sysret in long more (and only if efer.sce is enabled), so only reload the related MSR_K6_STAR if the guest will actually be able to use it. This reduces vmexit cost by about 500 cycles (6400 -> 5870) on my setup. Signed-off-by: Avi Kivity commit 37d6247b3636cbf47014694483d2d25c3806e8f2 Author: Avi Kivity Date: Thu Apr 19 13:26:39 2007 +0300 KVM: Fold drivers/kvm/kvm_vmx.h into drivers/kvm/vmx.c No meat in that file. Signed-off-by: Avi Kivity commit ba9c2fc1015a2b2f1f930274d465662ed8b860e6 Author: Avi Kivity Date: Thu Apr 19 13:22:48 2007 +0300 KVM: VMX: Don't switch 64-bit msrs for 32-bit guests Some msrs are only used by x86_64 instructions, and are therefore not needed when the guest is legacy mode. By not bothering to switch them, we reduce vmexit latency by 2400 cycles (from about 8800) when running a 32-bt guest on a 64-bit host. Signed-off-by: Avi Kivity commit 8d6c8a0d891f8c37889f28f368c2621f85e50035 Author: Avi Kivity Date: Wed Apr 18 11:18:18 2007 +0300 KVM: Fix off-by-one when writing to a nonpae guest pde Nonpae guest pdes are shadowed by two pae ptes, so we double the offset twice: once to account for the pte size difference, and once because we need to shadow pdes for a single guest pde. But when writing to the upper guest pde we also need to truncate the lower bits, otherwise the multiply shifts these bits into the pde index and causes an access to the wrong shadow pde. If we're at the end of the page (accessing the very last guest pde) we can even overflow into the next host page and oops. Signed-off-by: Avi Kivity commit f0b9c908fa1451147a07f2f4e4a9409fb7b14160 Author: Avi Kivity Date: Tue Apr 17 15:30:24 2007 +0300 KVM: VMX: Reduce unnecessary saving of host msrs THe automatically switched msrs are never changed on the host (with the exception of MSR_KERNEL_GS_BASE) and thus there is no need to save them on every vm entry. This reduces vmexit latency by ~400 cycles on i386 and by ~900 cycles (10%) on x86_64. Signed-off-by: Avi Kivity commit 7368e6550cdf72b0ad1b68dbe923f85e37ef4d08 Author: Avi Kivity Date: Tue Apr 17 10:53:22 2007 +0300 KVM: Handle guest page faults when emulating mmio Usually, guest page faults are detected by the kvm page fault handler, which detects if they are shadow faults, mmio faults, pagetable faults, or normal guest page faults. However, in ceratin circumstances, we can detect a page fault much later. One of these events is the following combination: - A two memory operand instruction (e.g. movsb) is executed. - The first operand is in mmio space (which is the fault reported to kvm) - The second operand is in an ummaped address (e.g. a guest page fault) The Windows 2000 installer does such an access, an promptly hangs. Fix by adding the missing page fault injection on that path. Signed-off-by: Avi Kivity commit 894f5a5efc0c48482eb10ad48891054a659e5941 Author: Avi Kivity Date: Mon Apr 16 14:28:40 2007 +0300 KVM: SVM: Report hardware exit reason to userspace instead of dmesg Signed-off-by: Avi Kivity commit 94d806a6efd4401ce43358af6a9e8df5a63151ae Author: Avi Kivity Date: Mon Apr 16 13:36:10 2007 +0300 KVM: Fix pio completion Check cur_count instead of count to avoid false completions. Signed-off-by: Avi Kivity commit d3344ae6f6293913d6e4f230ebee0b370f2e3f98 Author: Avi Kivity Date: Mon Apr 16 11:53:17 2007 +0300 KVM: Retry sleeping allocation if atomic allocation fails This avoids -ENOMEM under memory pressure. Signed-off-by: Avi Kivity commit 327585c3b4c1d6b04bb752f70f350d98ca855080 Author: Avi Kivity Date: Sun Apr 15 16:31:09 2007 +0300 KVM: Use slab caches to allocate mmu data structures Better leak detection, statistics, memory use, speed -- goodness all around. Signed-off-by: Avi Kivity commit 3079541923d2cdf702490eff7081610b7320e37f Author: Avi Kivity Date: Sun Apr 15 15:48:11 2007 +0300 KVM: Fix string pio when count == 0 Surprisingly, VT traps when executing a string pio instruction with zero count. Perhaps more surprisingly, the Windows ne2000 driver issues such instructions. Since we aren't prepared to handle completions of these instructions, avoid the entire mess by continuing execution without escaping to userspace. This fixes the networking problems reported by Leslie Mann with recent versions of kvm. Signed-off-by: Avi Kivity commit 3ef1110c81993e01343e1b473f5d7d1a23e6a8a3 Author: Avi Kivity Date: Thu Apr 12 17:35:58 2007 +0300 KVM: Handle partial pae pdptr Some guests (Solaris) do not set up all four pdptrs, but leave some invalid. kvm incorrectly treated these as valid page directories, pinning the wrong pages and causing general confusion. Fix by checking the valid bit of a pae pdpte. This closes sourceforge bug 1698922. Signed-off-by: Avi Kivity commit 4e9d9d330d9c9e66c449be10950562e407366a73 Author: Avi Kivity Date: Wed Apr 11 19:04:39 2007 +0300 KVM: Fix memory leak on pio completion We get_page() the pages participating in pio before we return to userspace, yet we neglect to free them. The can leak all guest memory in a few seconds by doing a hdparm -d 0 /dev/hda; dd < /dev/hda > /dev/null on the guest. Signed-off-by: Avi Kivity commit b630b9c6819844e29cddcfeaee901f6ada5d571b Author: Eric Sesterhenn / Snakebyte Date: Mon Apr 9 16:15:05 2007 +0200 KVM: Fix overflow bug in overflow detection code The expression sp - 6 < sp where sp is a u16 is undefined in C since 'sp - 6' is promoted to int, and signed overflow is undefined in C. gcc 4.2 actually warns about it. Replace with a simpler test. Signed-off-by: Eric Sesterhenn Signed-off-by: Avi Kivity commit c338c271f150ab2ded369ef4c1882f85b28af709 Author: Avi Kivity Date: Mon Apr 2 13:05:50 2007 +0300 KVM: Use kernel-standard types Noted by Joerg Roedel. Signed-off-by: Avi Kivity commit 0ea6eecef44923d66409a49d71e4fa87fa0f5bed Author: Avi Kivity Date: Sun Apr 1 16:34:31 2007 +0300 KVM: Add fpu get/set operations These are really helpful when migrating an floating point app to another machine. Signed-off-by: Avi Kivity commit 05671a064c73b8cb8966ddd037ece2d6ae2cb75b Author: Avi Kivity Date: Fri Mar 30 16:54:30 2007 +0300 KVM: Add physical memory aliasing feature With this, we can specify that accesses to one physical memory range will be remapped to another. This is useful for the vga window at 0xa0000 which is used as a movable window into the (much larger) framebuffer. Signed-off-by: Avi Kivity commit 8e08039818b6a5b8c81b905f863adaa18d774171 Author: Avi Kivity Date: Fri Mar 30 14:02:32 2007 +0300 KVM: Simply gfn_to_page() Mapping a guest page to a host page is a common operation. Currently, one has first to find the memory slot where the page belongs (gfn_to_memslot), then locate the page itself (gfn_to_page()). This is clumsy, and also won't work well with memory aliases. So simplify gfn_to_page() not to require memory slot translation first, and instead do it internally. Signed-off-by: Avi Kivity commit 66a9932c55ff7240955d57b7d1e62178a9e80868 Author: Dor Laor Date: Fri Mar 30 13:06:33 2007 +0300 Add mmu cache clear function Functions that play around with the physical memory map need a way to clear mappings to possibly nonexistent or invalid memory. Both the mmu cache and the processor tlb are cleared. Signed-off-by: Dor Laor Signed-off-by: Avi Kivity commit 6095d7b8291fc3e05f3b8790a9bc86b54af281a2 Author: Joerg Roedel Date: Fri Mar 30 17:02:14 2007 +0300 KVM: SVM: enable LBRV virtualization if available This patch enables the virtualization of the last branch record MSRs on SVM if this feature is available in hardware. It also introduces a small and simple check feature for specific SVM extensions. Signed-off-by: Joerg Roedel Signed-off-by: Avi Kivity commit 8f1469e8477bea483d5a6348a30a534449048c8d Author: Avi Kivity Date: Wed Mar 28 20:04:16 2007 +0200 KVM: x86 emulator: fix bit string operations operand size On x86, bit operations operate on a string of bits that can reside in multiple words. For example, 'btsl %eax, (blah)' will touch the word at blah+4 if %eax is between 32 and 63. The x86 emulator compensates for that by advancing the operand address by (bit offset / BITS_PER_LONG) and truncating the bit offset to the range (0..BITS_PER_LONG-1). This has a side effect of forcing the operand size to 8 bytes on 64-bit hosts. Now, a 32-bit guest goes and fork()s a process. It write protects a stack page at 0xbffff000 using the 'btr' instruction, at offset 0xffc in the page table, with bit offset 1 (for the write permission bit). The emulator now forces the operand size to 8 bytes as previously described, and an innocent page table update turns into a cross-page-boundary write, which is assumed by the mmu code not to be a page table, so it doesn't actually clear the corresponding shadow page table entry. The guest and host permissions are out of sync and guest memory is corrupted soon afterwards, leading to guest failure. Fix by not using BITS_PER_LONG as the word size; instead use the actual operand size, so we get a 32-bit write in that case. Note we still have to teach the mmu to handle cross-page-boundary writes to guest page table; but for now this allows Damn Small Linux 0.4 (2.4.20) to boot. Signed-off-by: Avi Kivity commit e3a065c4e99bb8282d72a2c3c75234d7d7408be6 Author: Avi Kivity Date: Tue Mar 27 17:50:20 2007 +0200 KVM: Remove debug message No longer interesting. Signed-off-by: Avi Kivity commit 19cd40d605bb99fc9058973a69ef208c8b5b1e42 Author: Avi Kivity Date: Tue Mar 27 16:12:41 2007 +0200 Revert "added KVM_GET_MEM_MAP ioctl to get the memory bitmap for a memory slot" This reverts commit ade11a015f83d270d1201c440199146f852fe5e4. As the balloon path will be through qemu, it will have direct knowledge of released gfns, so this API is not directly needed. If it becomes useful in the future, it will be un-reverted. Signed-off-by: Avi Kivity commit 932bf20c0c2075f958bb86b481d8f359197b4d6a Author: Avi Kivity Date: Mon Mar 26 19:31:52 2007 +0200 KVM: Use list_move() Use list_move() where possible. Noticed by Dor Laor. Signed-off-by: Avi Kivity commit 31e82571e8a77d5feb1093627ef0b31f28649590 Author: Michal Piotrowski Date: Sun Mar 25 17:59:32 2007 +0200 KVM: Remove unused function Remove unused function CC drivers/kvm/svm.o drivers/kvm/svm.c:207: warning: ‘inject_db’ defined but not used Signed-off-by: Michal Piotrowski Signed-off-by: Avi Kivity commit 9207113c121519986a114ee5c498184e618ffd68 Author: Avi Kivity Date: Sun Mar 25 12:07:27 2007 +0200 KVM: SVM: Ensure timestamp counter monotonicity When a vcpu is migrated from one cpu to another, its timestamp counter may lose its monotonic property if the host has unsynced timestamp counters. This can confuse the guest, sometimes to the point of refusing to boot. As the rdtsc instruction is rather fast on AMD processors (7-10 cycles), we can simply record the last host tsc when we drop the cpu, and adjust the vcpu tsc offset when we detect that we've migrated to a different cpu. Signed-off-by: Avi Kivity commit b40faf227eb371a52aa21d08f8e9c33fc06602b4 Author: Avi Kivity Date: Fri Mar 23 09:55:25 2007 +0200 KVM: MMU: Fix hugepage pdes mapping same physical address with different access The kvm mmu keeps a shadow page for hugepage pdes; if several such pdes map the same physical address, they share the same shadow page. This is a fairly common case (kernel mappings on i386 nonpae Linux, for example). However, if the two pdes map the same memory but with different permissions, kvm will happily use the cached shadow page. If the access through the more permissive pde will occur after the access to the strict pde, an endless pagefault loop will be generated and the guest will make no progress. Fix by making the access permissions part of the cache lookup key. The fix allows Xen pae to boot on kvm and run guest domains. Thanks to Jeremy Fitzhardinge for reporting the bug and testing the fix. Signed-off-by: Avi Kivity commit 061bba1190514205594d2046f5dc31a01a135163 Author: Avi Kivity Date: Thu Mar 22 15:10:32 2007 +0200 Revert "KVM: Remove extraneous guest entry on mmio read" This reverts commit b0092d187cfa19dfcada3b85d728af5ae27989dc. While the optimization is sound, it regresses booting the Fedora Core 6 32 bit kernel. Signed-off-by: Avi Kivity commit 4cec1674d1436157c7dcc2b5b6f625b08b2b96e8 Author: Joerg Roedel Date: Wed Mar 21 19:47:00 2007 +0100 KVM: SVM: forbid guest to execute monitor/mwait This patch forbids the guest to execute monitor/mwait instructions on SVM. This is necessary because the guest can execute these instructions if they are available even if the kvm cpuid doesn't report its existence. Signed-off-by: Joerg Roedel Signed-off-by: Avi Kivity commit 7921ad9e303f3f03dd81b552e3b0cd87ef355219 Author: Sergey Kiselev Date: Thu Mar 22 14:06:18 2007 +0200 KVM: Handle writes to MCG_STATUS msr Some older (~2.6.7) kernels write MCG_STATUS register during kernel boot (mce_clear_all() function, called from mce_init()). It's not currently handled by kvm and will cause it to inject a GPF. Following patch adds a "nop" handler for this. Signed-off-by: Sergey Kiselev Signed-off-by: Avi Kivity commit 36809e1326c13887d324025d4592958ead8758d5 Author: Avi Kivity Date: Wed Mar 21 18:14:42 2007 +0200 KVM: Remove unused and write-only variables Trivial cleanup. Signed-off-by: Avi Kivity commit 262e17b818054dad314a062a439681d79a336d48 Author: Avi Kivity Date: Wed Mar 21 18:11:36 2007 +0200 KVM: Don't allow the guest to turn off the cpu cache The cpu cache is a host resource; the guest should not be able to turn it off (even for itself). Signed-off-by: Avi Kivity commit 8c37a70d93ba3e4286ad7524f7915a32ed39cac9 Author: Avi Kivity Date: Wed Mar 21 17:58:32 2007 +0200 KVM: Hack real-mode segments on vmx from KVM_SET_SREGS As usual, we need to mangle segment registers when emulating real mode as vm86 has specific constraints. We special case the reset segment base, and set the "access rights" (or descriptor flags) to vm86 comaptible values. This fixes reboot on vmx. Signed-off-by: Avi Kivity commit 0bf8d346418255335dc9062d96b9f8814b471690 Author: Avi Kivity Date: Wed Mar 21 13:44:58 2007 +0200 KVM: Modify guest segments after potentially switching modes The SET_SREGS ioctl modifies both cr0.pe (real mode/protected mode) and guest segment registers. Since segment handling is modified by the mode on Intel procesors, update the segment registers after the mode switch has taken place. Signed-off-by: Avi Kivity commit f97af70b3aa8a92ddeabb7d42477e7d13dd0a192 Author: Avi Kivity Date: Tue Mar 20 18:44:51 2007 +0200 KVM: Remove set_cr0_no_modeswitch() arch op set_cr0_no_modeswitch() was a hack to avoid corrupting segment registers. As we now cache the protected mode values on entry to real mode, this isn't an issue anymore, and it interferes with reboot (which usually _is_ a modeswitch). Signed-off-by: Avi Kivity commit e314dde30e3851e8effc017c6fffced11d90183a Author: Avi Kivity Date: Tue Mar 20 18:40:40 2007 +0200 KVM: Workaround vmx inability to virtualize the reset state The reset state has cs.selector == 0xf000 and cs.base == 0xffff0000, which aren't compatible with vm86 mode, which is used for real mode virtualization. When we create a vcpu, we set cs.base to 0xf0000, but if we get there by way of a reset, the values are inconsistent and vmx refuses to enter guest mode. Workaround by detecting the state and munging it appropriately. Signed-off-by: Avi Kivity commit 88aea7ddfae755633b0a80ccfa56244b3c79c7b0 Author: Avi Kivity Date: Tue Mar 20 14:34:28 2007 +0200 KVM: MMU: Remove global pte tracking The initial, noncaching, version of the kvm mmu flushed the all nonglobal shadow page table translations (much like a native tlb flush). The new implementation flushes translations only when they change, rendering global pte tracking superfluous. This removes the unused tracking mechanism and storage space. Signed-off-by: Avi Kivity commit 66e5d5c81b5b89e39aa86e3bf9864d228f468b0d Author: Avi Kivity Date: Tue Mar 20 14:29:06 2007 +0200 KVM: MMU: Remove unnecessary check for pdptr access We already special case the pdptr access, so no need to check it again. Signed-off-by: Avi Kivity commit c01571ed56754dfea458cc37d553c360082411a1 Author: Avi Kivity Date: Tue Mar 20 12:46:50 2007 +0200 KVM: Avoid guest virtual addresses in string pio userspace interface The current string pio interface communicates using guest virtual addresses, relying on userspace to translate addresses and to check permissions. This interface cannot fully support guest smp, as the check needs to take into account two pages at one in case an unaligned string transfer straddles a page boundary. Change the interface not to communicate guest addresses at all; instead use a buffer page (mmaped by userspace) and do transfers there. The kernel manages the virtual to physical translation and can perform the checks atomically by taking the appropriate locks. Signed-off-by: Avi Kivity commit 74c24de6e7848a45d6109d987d4fd2ccd83e432e Author: Avi Kivity Date: Wed Mar 7 13:11:17 2007 +0200 KVM: Future-proof argument-less ioctls Some ioctls ignore their arguments. By requiring them to be zero now, we allow a nonzero value to have some special meaning in the future. Signed-off-by: Avi Kivity commit 29e686a1dc9631b7898d087a0ab1c4716672e209 Author: Avi Kivity Date: Wed Mar 7 13:05:38 2007 +0200 KVM: Allow kernel to select size of mmap() buffer This allows us to store offsets in the kernel/user kvm_run area, and be sure that userspace has them mapped. As offsets can be outside the kvm_run struct, userspace has no way of knowing how much to mmap. Signed-off-by: Avi Kivity commit cce3a1062817218c67163732339e2ea25e9f023b Author: Avi Kivity Date: Mon Mar 5 19:46:05 2007 +0200 KVM: Add guest mode signal mask Allow a special signal mask to be used while executing in guest mode. This allows signals to be used to interrupt a vcpu without requiring signal delivery to a userspace handler, which is quite expensive. Userspace still receives -EINTR and can get the signal via sigwait(). Signed-off-by: Avi Kivity commit cd3aaa2392baec9674792d71d304ec41e540b517 Author: Avi Kivity Date: Mon Mar 5 17:45:40 2007 +0200 KVM: Initialize the apic_base msr on svm too Older userspace didn't care, but newer userspace (with the cpuid changes) does. Signed-off-by: Avi Kivity commit c303c0efc5b2ff8c0f77c9079fa66f62801da93d Author: Avi Kivity Date: Sun Mar 4 14:24:03 2007 +0200 KVM: Add a special exit reason when exiting due to an interrupt This is redundant, as we also return -EINTR from the ioctl, but it allows us to examine the exit_reason field on resume without seeing old data. Signed-off-by: Avi Kivity commit 62919332e00e3226dd1f728ff83107d06a6d9a81 Author: Avi Kivity Date: Sun Mar 4 14:17:08 2007 +0200 KVM: Fold kvm_run::exit_type into kvm_run::exit_reason Currently, userspace is told about the nature of the last exit from the guest using two fields, exit_type and exit_reason, where exit_type has just two enumerations (and no need for more). So fold exit_type into exit_reason, reducing the complexity of determining what really happened. Signed-off-by: Avi Kivity commit 9e16898f4f5d6cdc35030bb272631611b71548fe Author: Avi Kivity Date: Sun Mar 4 13:59:30 2007 +0200 KVM: Allow userspace to process hypercalls which have no kernel handler This is useful for paravirtualized graphics devices, for example. Signed-off-by: Avi Kivity commit 440fd9098bceb2ca0856d962ff62db9af4d1094a Author: Avi Kivity Date: Thu Mar 1 17:56:20 2007 +0200 KVM: Add method to check for backwards-compatible API extensions Signed-off-by: Avi Kivity commit 0b37dedb178bcb3b0a28f65e6ae835bf58184301 Author: Avi Kivity Date: Thu Mar 1 17:20:13 2007 +0200 KVM: Renumber ioctls The recent changes have left the ioctl numbers in complete disarray. Signed-off-by: Avi Kivity commit 95cab16b18e1c1a786a9fc5ea6fcd68b29ae3481 Author: Avi Kivity Date: Thu Mar 1 16:47:06 2007 +0200 KVM: Remove minor wart from KVM_CREATE_VCPU ioctl That ioctl does not transfer any data, so it should be an _IO rather than an _IOW. Signed-off-by: Avi Kivity commit ba5cb15b027b76ba7b4d247914eb6d20065c0767 Author: Avi Kivity Date: Thu Mar 1 16:20:40 2007 +0200 KVM: Remove the 'emulated' field from the userspace interface We no longer emulate single instructions in userspace. Instead, we service mmio or pio requests. Signed-off-by: Avi Kivity commit 706e8fe655be36aa686f1fbb398d3a4470d4939b Author: Avi Kivity Date: Wed Feb 28 20:46:53 2007 +0200 KVM: Handle cpuid in the kernel instead of punting to userspace KVM used to handle cpuid by letting userspace decide what values to return to the guest. We now handle cpuid completely in the kernel. We still let userspace decide which values the guest will see by having userspace set up the value table beforehand (this is necessary to allow management software to set the cpu features to the least common denominator, so that live migration can work). The motivation for the change is that kvm kernel code can be impacted by cpuid features, for example the x86 emulator. Signed-off-by: Avi Kivity commit aad2f6e0faf4b03e087bbe6751acdacd72e911b6 Author: Avi Kivity Date: Thu Feb 22 19:48:43 2007 +0200 KVM: Initialize PIO I/O count This allows userspace to ignore the io.rep field. No a big deal, but friendly. Signed-off-by: Avi Kivity commit e668cf946ee8654c7f5afe3feeed686a3566c22a Author: Avi Kivity Date: Thu Feb 22 19:39:30 2007 +0200 KVM: Do not communicate to userspace through cpu registers during PIO Currently when passing the a PIO emulation request to userspace, we rely on userspace updating %rax (on 'in' instructions) and %rsi/%rdi/%rcx (on string instructions). This (a) requires two extra ioctls for getting and setting the registers and (b) is unfriendly to non-x86 archs, when they get kvm ports. So fix by doing the register fixups in the kernel and passing to userspace only an abstract description of the PIO to be done. Signed-off-by: Avi Kivity commit 3de857cd1335bd2e02b60d3a50b7da93ccbabf1d Author: Avi Kivity Date: Thu Feb 22 12:58:31 2007 +0200 KVM: Use a shared page for kernel/user communication when runing a vcpu Instead of passing a 'struct kvm_run' back and forth between the kernel and userspace, allocate a page and allow the user to mmap() it. This reduces needless copying and makes the interface expandable by providing lots of free space. Signed-off-by: Avi Kivity commit 128e159e11e999496ec44a549fcac91de3802389 Author: Avi Kivity Date: Mon Mar 19 13:18:10 2007 +0200 KVM: Prevent system selectors leaking into guest on real->protected mode transition on vmx Intel virtualization extensions do not support virtualizing real mode. So kvm uses virtualized vm86 mode to run real mode code. Unfortunately, this virtualized vm86 mode does not support the so called "big real" mode, where the segment selector and base do not agree with each other according to the real mode rules (base == selector << 4). To work around this, kvm checks whether a selector/base pair violates the virtualized vm86 rules, and if so, forces it into conformance. On a transition back to protected mode, if we see that the guest did not touch a forced segment, we restore it back to the original protected mode value. This pile of hacks breaks down if the gdt has changed in real mode, as it can cause a segment selector to point to a system descriptor instead of a normal data segment. In fact, this happens with the Windows bootloader and the qemu acpi bios, where a protected mode memcpy routine issues an innocent 'pop %es' and traps on an attempt to load a system descriptor. "Fix" by checking if the to-be-restored selector points at a system segment, and if so, coercing it into a normal data segment. The long term solution, of course, is to abandon vm86 mode and use emulation for big real mode. Signed-off-by: Avi Kivity commit ade11a015f83d270d1201c440199146f852fe5e4 Author: Uri Lublin Date: Wed Mar 14 19:21:06 2007 +0200 added KVM_GET_MEM_MAP ioctl to get the memory bitmap for a memory slot To be used when there may be "holes" in the memory. Specifically to not break VM migration when ballooning mechanism exists Signed-off-by: Uri Lublin commit b0092d187cfa19dfcada3b85d728af5ae27989dc Author: Avi Kivity Date: Wed Mar 14 15:54:54 2007 +0200 KVM: Remove extraneous guest entry on mmio read When emulating an mmio read, we actually emulate twice: once to determine the physical address of the mmio, and, after we've exited to userspace to get the mmio value, we emulate again to place the value in the result register and update any flags. But we don't really need to enter the guest again for that, only to take an immediate vmexit. So, if we detect that we're doing an mmio read, emulate a single instruction before entering the guest again. Signed-off-by: Avi Kivity commit 470db88b8b3491199e8d55b771d66e74b2fd53cd Author: Ingo Molnar Date: Sun Mar 11 13:52:33 2007 +0100 KVM: always reload segment selectors failed VM entry on VMX might still change %fs or %gs, thus make sure that KVM always reloads the segment selectors. This is crutial on both x86 and x86_64: x86 has __KERNEL_PDA in %fs on which things like 'current' depends and x86_64 has 0 there and needs MSR_GS_BASE to work. Signed-off-by: Ingo Molnar commit f7edc6a39584a3f95687a5320675fadb23bccbe5 Author: Ingo Molnar Date: Sat Mar 10 11:22:51 2007 +0100 KVM: trivial whitespace fixes trivial whitespace fixes. Signed-off-by: Ingo Molnar commit f3a33bfeaa5cade1a9ac1facb5cb904a483b1e5c Author: Avi Kivity Date: Fri Mar 9 13:04:31 2007 +0200 KVM: MMU: Fix host memory corruption on i386 with >= 4GB ram PAGE_MASK is an unsigned long, so using it to mask physical addresses on i386 (which are 64-bit wide) leads to truncation. This can result in page->private of unrelated memory pages being modified, with disasterous results. Fix by not using PAGE_MASK for physical addresses; instead calculate the correct value directly from PAGE_SIZE. Also fix a similar BUG_ON(). Signed-off-by: Avi Kivity commit 6ee9853b015f8807f497ffad39b142ddc1403aa9 Author: Avi Kivity Date: Thu Mar 8 17:13:32 2007 +0200 KVM: MMU: Fix guest writes to nonpae pde KVM shadow page tables are always in pae mode, regardless of the guest setting. This means that a guest pde (mapping 4MB of memory) is mapped to two shadow pdes (mapping 2MB each). When the guest writes to a pte or pde, we intercept the write and emulate it. We also remove any shadowed mappings corresponding to the write. Since the mmu did not account for the doubling in the number of pdes, it removed the wrong entry, resulting in a mismatch between shadow page tables and guest page tables, followed shortly by guest memory corruption. This patch fixes the problem by detecting the special case of writing to a non-pae pde and adjusting the address and number of shadow pdes zapped accordingly. Signed-off-by: Avi Kivity commit 374c1509c7d04a4e351b1812c2f0b9dac3ea0c0a Author: Avi Kivity Date: Thu Mar 8 11:48:09 2007 +0200 KVM: Fix bogus sign extension in mmu mapping audit When auditing a 32-bit guest on a 64-bit host, sign extension of the page table directory pointer table index caused bogus addresses to be shown on audit errors. Fix by declaring the index unsigned. Signed-off-by: Avi Kivity commit fac539542cbf923a39238b10557c88f99fd45b59 Author: Avi Kivity Date: Wed Mar 7 09:29:48 2007 +0200 KVM: Export This allows users to actually build prgrams that use kvm without the entire source tree. Signed-off-by: Avi Kivity commit c14a46343cc9f04f15ebc67573031fe8bbe1555a Author: Avi Kivity Date: Tue Mar 6 12:05:53 2007 +0200 KVM: Fix guest sysenter on vmx The vmx code currently treats the guest's sysenter support msrs as 32-bit values, which breaks 32-bit compat mode userspace on 64-bit guests. Fix by using the native word width of the machine. Signed-off-by: Avi Kivity commit ea135e7671189ffb7e67843bf98740dac0c6ccfa Author: Avi Kivity Date: Sun Mar 4 13:27:36 2007 +0200 KVM: Use own minor number Use the minor number (232) allocated to kvm by lanana. Signed-off-by: Avi Kivity commit 21af17507f37658414191b1cf1337efbaf7dd530 Author: Dor Laor Date: Mon Feb 19 18:25:43 2007 +0200 KVM: Use the generic skip_emulated_instruction() in hypercall code Instead of twiddling the rip registers directly, use the skip_emulated_instruction() function to do that for us. Signed-off-by: Dor Laor Signed-off-by: Avi Kivity commit 57d78025d84fb607aa335d015a79b257517aa209 Author: Dor Laor Date: Mon Feb 19 16:44:49 2007 +0200 KVM: Fix guest register corruption on paravirt hypercall The hypercall code mixes up the ->cache_regs() and ->decache_regs() callbacks, resulting in guest register corruption. Signed-off-by: Dor Laor Signed-off-by: Avi Kivity commit 28e9803c9134683a884efe05abdb3f814c1ca7e7 Author: Avi Kivity Date: Thu Mar 1 19:21:03 2007 +0200 KVM: Unset kvm_arch_ops if arch module loading failed Otherwise, the core module thinks the arch module is loaded, and won't let you reload it after you've fixed the bug. Signed-off-by: Avi Kivity commit 426bc2fd1462706ec92d0e9efdb0cf3643f4eb67 Author: Avi Kivity Date: Thu Mar 1 11:28:13 2007 +0200 KVM: Move kvmfs magic number to From: Andrew Morton Use the standard magic.h for kvmfs. Cc: Avi Kivity Signed-off-by: Andrew Morton Signed-off-by: Avi Kivity commit c1a8557e1da6e7d8bf8f77cb1b47c077f5c2a67d Author: Avi Kivity Date: Mon Feb 26 16:29:43 2007 +0200 KVM: Fix bogus failure in kvm.ko module initialization A bogus 'return r' can cause an otherwise successful module load to fail. This both denies users the use of kvm, and it also denies them the use of their machine, as it leaves a filesystem registered with its callbacks pointing into now-freed module memory. Fix by returning a zero like a good module. Thanks to Richard Lucassen (?) for reporting the problem and for providing access to a machine which exhibited it. Signed-off-by: Avi Kivity commit 7703ff91ee2ed171f2175d030e7f063c4efab2f5 Author: Uri Lublin Date: Thu Feb 22 17:37:32 2007 +0200 KVM: Remove write access permissions when dirty-page-logging is enabled Enabling dirty page logging is done using KVM_SET_MEMORY_REGION ioctl. If the memory region already exists, we need to remove write accesses, so writes will be caught, and dirty pages will be logged. Signed-off-by: Uri Lublin Signed-off-by: Avi Kivity commit b77fd1f62576463434fc434cbdcd808847e169a1 Author: Uri Lublin Date: Thu Feb 22 17:15:33 2007 +0200 kvm: move do_remove_write_access() up To be called from kvm_vm_ioctl_set_memory_region() Signed-off-by: Uri Lublin Signed-off-by: Avi Kivity commit 62e287e7210d6ff142b3b05233fa1f5df686b794 Author: Uri Lublin Date: Thu Feb 22 16:43:09 2007 +0200 KVM: Fix dirty page log bitmap size/access calculation Since dirty_bitmap is an unsigned long array, the alignment and size need to take that into account. Signed-off-by: Uri Lublin Signed-off-by: Avi Kivity commit 871574eb14e959c19d94fdee7c3e2b88ae06770f Author: Uri Lublin Date: Wed Feb 21 18:25:21 2007 +0200 KVM: Add missing calls to mark_page_dirty() A few places where we modify guest memory fail to call mark_page_dirty(), causing live migration to fail. This adds the missing calls. Signed-off-by: Uri Lublin Signed-off-by: Avi Kivity commit 42017e8bf8eb7b6f65b95bca1368ee274fc5ef50 Author: Uri Lublin Date: Thu Feb 22 17:37:32 2007 +0200 kvm: dirty page logging: remove write access permissions when dirty-page-logging is enabled Enabling dirty page logging is done using KVM_SET_MEMORY_REGION ioctl. If the memory region already exists, there is a need to remove write accesses, so writes will be caught, and dirty pages will be logged. commit a9fd29cfcb643b97cd76c7d836be4d0ed80f69e0 Author: Uri Lublin Date: Thu Feb 22 17:15:33 2007 +0200 kvm: move do_remove_write_access() up To be called from kvm_vm_ioctl_set_memory_region() commit fba4ba9c513ad2cd328f5f16980aa7b90d40cec0 Author: Uri Lublin Date: Thu Feb 22 16:43:09 2007 +0200 kvm: dirty pages log: fix bitmap size/access calculation Since dirty_bitmap is an unsigned long array (pointer) commit ae160d732685ab33d5a3a495663aa2b54c4d4734 Author: Uri Lublin Date: Thu Feb 22 15:47:42 2007 +0200 .gitignore: ignore emacs backup files (*~) commit 8267c1cd9a8a038e91c94e0cabc571a3614dc3e5 Author: Avi Kivity Date: Wed Feb 21 19:47:40 2007 +0200 KVM: Bump API version Signed-off-by: Avi Kivity commit c65237e78c19b8173338a49933c611dece13c1c6 Author: Avi Kivity Date: Wed Feb 21 18:04:26 2007 +0200 KVM: Per-vcpu inodes Allocate a distinct inode for every vcpu in a VM. This has the following benefits: - the filp cachelines are no longer bounced when f_count is incremented on every ioctl() - the API and internal code are distinctly clearer; for example, on the KVM_GET_REGS ioctl, there is no need to copy the vcpu number from userspace and then copy the registers back; the vcpu identity is derived from the fd used to make the call Right now the performance benefits are completely theoretical since (a) we don't support more than one vcpu per VM and (b) virtualization hardware inefficiencies completely everwhelm any cacheline bouncing effects. But both of these will change, and we need to prepare the API today. Signed-off-by: Avi Kivity commit 11c1297fadc533d1f66252088b4f4775018bafbb Author: Avi Kivity Date: Tue Feb 20 18:41:05 2007 +0200 KVM: Move kvm_vm_ioctl_create_vcpu() around In preparation of some hacking. Signed-off-by: Avi Kivity commit f3ad84386727171d8308338a2c5dee1deac2e50d Author: Avi Kivity Date: Tue Feb 20 18:27:58 2007 +0200 KVM: Rename some kvm_dev_ioctl_*() functions to kvm_vm_ioctl_*() This reflects the changed scope, from device-wide to single vm (previously every device open created a virtual machine). Signed-off-by: Avi Kivity commit 733e3f74f1c51bbc2e7a99df8b51767504b58de2 Author: Avi Kivity Date: Wed Feb 21 19:28:04 2007 +0200 KVM: Create an inode per virtual machine This avoids having filp->f_op and the corresponding inode->i_fop different, which is a little unorthodox. The ioctl list is split into two: global kvm ioctls and per-vm ioctls. A new ioctl, KVM_CREATE_VM, is used to create VMs and return the VM fd. Signed-off-by: Avi Kivity commit 52a96114380f8ab615626e4cec57b7015895bd0f Author: Avi Kivity Date: Tue Feb 20 14:07:37 2007 +0200 KVM: Add internal filesystem for generating inodes The kvmfs inodes will represent virtual machines and vcpus, as necessary, reducing cacheline bouncing due to inodes and filps being shared. Signed-off-by: Avi Kivity commit b00bc8b10197715f5b842f1f9a60e67a3484b10f Author: Uri Lublin Date: Wed Feb 21 18:25:21 2007 +0200 kvm, dirty pages log: adding some calls to mark_page_dirty() commit 58a214eba321d92f833221c26777e2119e34a19d Author: Avi Kivity Date: Mon Feb 19 14:37:48 2007 +0200 KVM: More 0 -> NULL conversions Signed-off-by: Avi Kivity commit f73199bb57b4c8feb7d8f60c6f1a25107de18dab Author: Joerg Roedel Date: Mon Feb 19 14:37:47 2007 +0200 KVM: SVM: intercept SMI to handle it at host level This patch changes the SVM code to intercept SMIs and handle it outside the guest. Signed-off-by: Joerg Roedel Signed-off-by: Avi Kivity commit fa2742c78f10fad8682e3af17df3e9fc2eece9e4 Author: Avi Kivity Date: Mon Feb 19 14:37:47 2007 +0200 KVM: svm: init cr0 with the wp bit set Signed-off-by: Avi Kivity commit 8da588a919dc0bef76e384d16fd13ea2189aa82d Author: Avi Kivity Date: Mon Feb 19 14:37:47 2007 +0200 KVM: Wire up hypercall handlers to a central arch-independent location Signed-off-by: Avi Kivity commit 68f16784f188d280c75b39e2367ebc1adbc66d9d Author: Avi Kivity Date: Mon Feb 19 14:37:47 2007 +0200 KVM: Add hypercall host support for svm Signed-off-by: Avi Kivity commit 7c8bd4d6fc0e2bfb35cd4c0e8ff39c4f8972d951 Author: Ingo Molnar Date: Mon Feb 19 14:37:47 2007 +0200 KVM: Add host hypercall support for vmx Signed-off-by: Avi Kivity commit f846fa34a14ec37dc0194c6f47ea4374c140e6f1 Author: Ingo Molnar Date: Mon Feb 19 14:37:47 2007 +0200 KVM: add MSR based hypercall API This adds a special MSR based hypercall API to KVM. This is to be used by paravirtual kernels and virtual drivers. Signed-off-by: Ingo Molnar Signed-off-by: Avi Kivity commit 8aa04bb13cf90d68c26d6bea1e4c720f1f027be0 Author: Markus Rechberger Date: Mon Feb 19 14:37:47 2007 +0200 KVM: Use page_private()/set_page_private() apis Besides using an established api, this allows using kvm in older kernels. Signed-off-by: Markus Rechberger Signed-off-by: Avi Kivity commit 4d5a7e81cc63d28e94373cdeb74dc44045edaa10 Author: Ahmed S. Darwish Date: Mon Feb 19 14:37:46 2007 +0200 KVM: Use ARRAY_SIZE macro instead of manual calculation. Signed-off-by: Ahmed S. Darwish Signed-off-by: Dor Laor Signed-off-by: Avi Kivity commit 0fe9875fb3f9946a6c1cef6f1b9a286edc8ee2b9 Author: Markus Rechberger Date: Mon Feb 19 14:37:46 2007 +0200 KVM: vmx: hack set_cr0_no_modeswitch() to actually do modeswitch From: Joerg Roedel The whole thing is rotten, but this allows vmx to boot with the guest reboot fix. Signed-off-by: Markus Rechberger Signed-off-by: Joerg Roedel Signed-off-by: Avi Kivity commit 7e6e2bbad7f5dbccb389ee6d79be661972b18b15 Author: Avi Kivity Date: Mon Feb 19 14:37:46 2007 +0200 KVM: Cosmetics Signed-off-by: Avi Kivity commit cc66daca849ca8c2900ba8cc7640de664296d36a Author: Jeremy Katz Date: Mon Feb 19 14:37:46 2007 +0200 KVM: Move virtualization deactivation from CPU_DEAD state to CPU_DOWN_PREPARE This gives it more chances of surviving suspend. Signed-off-by: Jeremy Katz Signed-off-by: Avi Kivity commit 2959cd13ecc1fbe1b2339937481844ff963f1e7f Author: Avi Kivity Date: Mon Feb 19 14:37:46 2007 +0200 KVM: mmu: add missing dirty page tracking cases We fail to mark a page dirty in three cases: - setting the accessed bit in a pte - setting the dirty bit in a pte - emulating a write into a pagetable This fix adds the missing cases. Signed-off-by: Avi Kivity Documentation/00-INDEX | 6 - Documentation/ABI/stable/sysfs-driver-usb-usbtmc | 62 + Documentation/ABI/testing/debugfs-kmemtrace | 71 + .../ABI/testing/sysfs-bus-usb-devices-usbsevseg | 43 + Documentation/DocBook/Makefile | 2 +- Documentation/DocBook/gadget.tmpl | 3 + Documentation/DocBook/kernel-api.tmpl | 5 + Documentation/DocBook/networking.tmpl | 3 - Documentation/DocBook/wanbook.tmpl | 99 - Documentation/Makefile | 2 +- Documentation/PCI/pci.txt | 4 + Documentation/RCU/checklist.txt | 2 +- Documentation/RCU/whatisRCU.txt | 2 - Documentation/SELinux.txt | 27 + Documentation/block/deadline-iosched.txt | 14 +- Documentation/credentials.txt | 582 ++ Documentation/devices.txt | 3 + Documentation/early-userspace/00-INDEX | 8 + Documentation/early-userspace/initrd.txt | 366 + Documentation/feature-removal-schedule.txt | 7 + Documentation/filesystems/Makefile | 8 + Documentation/filesystems/dnotify.txt | 36 +- Documentation/filesystems/dnotify_test.c | 34 + Documentation/filesystems/hfs.txt | 2 +- Documentation/filesystems/sharedsubtree.txt | 82 +- Documentation/filesystems/smount.c | 73 + Documentation/hpet.txt | 300 - Documentation/hwmon/lm87 | 9 +- Documentation/hwmon/lm90 | 45 +- Documentation/i2c/busses/i2c-floppy | 37 + Documentation/i2c/busses/i2c-viapro | 8 +- Documentation/initrd.txt | 366 - Documentation/ioctl-number.txt | 2 + Documentation/ja_JP/SubmittingPatches | 4 +- Documentation/kernel-parameters.txt | 181 +- Documentation/kmemcheck.txt | 135 + Documentation/kobject.txt | 4 + Documentation/mtd/nand_ecc.txt | 714 ++ Documentation/mtrr.txt | 305 - Documentation/networking/generic-hdlc.txt | 8 +- Documentation/pcmcia/driver-changes.txt | 6 + Documentation/scheduler/sched-design-CFS.txt | 371 +- Documentation/sound/alsa/ALSA-Configuration.txt | 60 +- .../sound/alsa/DocBook/writing-an-alsa-driver.tmpl | 65 +- Documentation/sparc/sbus_drivers.txt | 309 - Documentation/sysctl/vm.txt | 12 + Documentation/timers/00-INDEX | 10 + Documentation/timers/hpet.txt | 299 + Documentation/tracepoints.txt | 101 + Documentation/usb/anchors.txt | 12 + Documentation/usb/misc_usbsevseg.txt | 46 + Documentation/video4linux/CARDLIST.au0828 | 1 + Documentation/video4linux/CARDLIST.bttv | 1 + Documentation/video4linux/CARDLIST.cx23885 | 2 + Documentation/video4linux/CARDLIST.tuner | 1 + Documentation/video4linux/gspca.txt | 29 +- Documentation/video4linux/soc-camera.txt | 120 + Documentation/vm/kmemtrace.txt | 126 + Documentation/vm/slabinfo.c | 91 +- Documentation/x86/00-INDEX | 4 + Documentation/x86/boot.txt | 900 ++ Documentation/x86/i386/boot.txt | 900 -- Documentation/x86/i386/usb-legacy-support.txt | 44 - Documentation/x86/i386/zero-page.txt | 31 - Documentation/x86/mtrr.txt | 305 + Documentation/x86/pat.txt | 54 +- Documentation/x86/usb-legacy-support.txt | 44 + Documentation/x86/zero-page.txt | 31 + Documentation/zh_CN/SubmittingPatches | 4 +- MAINTAINERS | 44 +- Makefile | 1 + Next/Trees | 117 + Next/merge.log | 5839 ++++++++++++ Next/quilt-import.log | 154 + arch/Kconfig | 17 + arch/alpha/include/asm/statfs.h | 4 + arch/alpha/include/asm/thread_info.h | 2 +- arch/alpha/kernel/asm-offsets.c | 11 +- arch/alpha/kernel/entry.S | 10 +- arch/alpha/kernel/osf_sys.c | 7 +- arch/arm/Kconfig | 47 +- arch/arm/boot/compressed/head.S | 1 + arch/arm/configs/afeb9260_defconfig | 1259 +++ arch/arm/configs/cm_x300_defconfig | 1466 +++ arch/arm/configs/palmz72_defconfig | 951 ++ arch/arm/include/asm/bug.h | 2 +- arch/arm/include/asm/cacheflush.h | 90 - arch/arm/include/asm/cachetype.h | 96 + arch/arm/include/asm/cputype.h | 64 + arch/arm/include/asm/futex.h | 124 +- arch/arm/include/asm/kprobes.h | 1 - arch/arm/include/asm/memory.h | 30 +- arch/arm/include/asm/mmu_context.h | 1 + arch/arm/include/asm/statfs.h | 34 +- arch/arm/include/asm/system.h | 58 - arch/arm/include/asm/uaccess.h | 10 +- arch/arm/kernel/debug.S | 5 + arch/arm/kernel/entry-armv.S | 16 + arch/arm/kernel/entry-common.S | 25 +- arch/arm/kernel/head-common.S | 19 +- arch/arm/kernel/head-nommu.S | 4 +- arch/arm/kernel/head.S | 12 +- arch/arm/kernel/kprobes-decode.c | 4 +- arch/arm/kernel/kprobes.c | 5 +- arch/arm/kernel/setup.c | 46 +- arch/arm/kernel/traps.c | 12 - arch/arm/lib/ashldi3.S | 2 + arch/arm/lib/ashrdi3.S | 2 + arch/arm/lib/backtrace.S | 4 + arch/arm/lib/changebit.S | 2 + arch/arm/lib/clear_user.S | 3 +- arch/arm/lib/clearbit.S | 2 + arch/arm/lib/copy_from_user.S | 2 + arch/arm/lib/copy_page.S | 1 + arch/arm/lib/copy_to_user.S | 2 + arch/arm/lib/csumipv6.S | 1 + arch/arm/lib/csumpartial.S | 1 + arch/arm/lib/csumpartialcopy.S | 7 +- arch/arm/lib/csumpartialcopygeneric.S | 1 + arch/arm/lib/csumpartialcopyuser.S | 7 +- arch/arm/lib/delay.S | 3 + arch/arm/lib/div64.S | 1 + arch/arm/lib/findbit.S | 8 + arch/arm/lib/getuser.S | 14 +- arch/arm/lib/io-readsb.S | 1 + arch/arm/lib/io-readsl.S | 1 + arch/arm/lib/io-readsw-armv4.S | 1 + arch/arm/lib/io-writesb.S | 1 + arch/arm/lib/io-writesl.S | 1 + arch/arm/lib/io-writesw-armv4.S | 1 + arch/arm/lib/lib1funcs.S | 11 + arch/arm/lib/lshrdi3.S | 2 + arch/arm/lib/memchr.S | 1 + arch/arm/lib/memcpy.S | 1 + arch/arm/lib/memmove.S | 1 + arch/arm/lib/memset.S | 1 + arch/arm/lib/memzero.S | 1 + arch/arm/lib/muldi3.S | 2 + arch/arm/lib/putuser.S | 18 +- arch/arm/lib/setbit.S | 2 + arch/arm/lib/sha1.S | 3 + arch/arm/lib/strchr.S | 1 + arch/arm/lib/strncpy_from_user.S | 1 + arch/arm/lib/strnlen_user.S | 1 + arch/arm/lib/strrchr.S | 1 + arch/arm/lib/testchangebit.S | 2 + arch/arm/lib/testclearbit.S | 2 + arch/arm/lib/testsetbit.S | 2 + arch/arm/lib/uaccess.S | 2 + arch/arm/lib/ucmpdi2.S | 4 + arch/arm/mach-at91/Kconfig | 9 + arch/arm/mach-at91/Makefile | 1 + arch/arm/mach-at91/board-afeb-9260v1.c | 210 + arch/arm/mach-footbridge/include/mach/memory.h | 10 - arch/arm/mach-iop13xx/include/mach/memory.h | 3 - arch/arm/mach-iop32x/iq31244.c | 4 +- arch/arm/mach-ixp4xx/common-pci.c | 7 +- arch/arm/mach-ixp4xx/include/mach/cpu.h | 9 +- arch/arm/mach-lh7a40x/clocks.c | 15 +- arch/arm/mach-omap1/board-h3.c | 4 + arch/arm/mach-omap1/mcbsp.c | 16 +- arch/arm/mach-omap1/serial.c | 12 +- arch/arm/mach-omap2/Makefile | 3 +- arch/arm/mach-omap2/board-h4.c | 11 + arch/arm/mach-omap2/clock.c | 46 +- arch/arm/mach-omap2/clock.h | 1 + arch/arm/mach-omap2/clock24xx.h | 238 +- arch/arm/mach-omap2/clock34xx.c | 31 +- arch/arm/mach-omap2/clock34xx.h | 248 +- arch/arm/mach-omap2/clockdomain.c | 623 ++ arch/arm/mach-omap2/clockdomains.h | 305 + arch/arm/mach-omap2/cm-regbits-24xx.h | 24 +- arch/arm/mach-omap2/cm-regbits-34xx.h | 42 +- arch/arm/mach-omap2/cm.h | 2 +- arch/arm/mach-omap2/gpmc.c | 6 +- arch/arm/mach-omap2/id.c | 7 +- arch/arm/mach-omap2/io.c | 9 + arch/arm/mach-omap2/irq.c | 4 +- arch/arm/mach-omap2/powerdomain.c | 1113 +++ arch/arm/mach-omap2/powerdomains.h | 187 + arch/arm/mach-omap2/powerdomains24xx.h | 200 + arch/arm/mach-omap2/powerdomains34xx.h | 327 + arch/arm/mach-omap2/prcm-common.h | 3 +- arch/arm/mach-omap2/prm-regbits-24xx.h | 12 +- arch/arm/mach-omap2/prm-regbits-34xx.h | 11 +- arch/arm/mach-omap2/prm.h | 5 +- arch/arm/mach-omap2/serial.c | 14 +- arch/arm/mach-pxa/Kconfig | 73 +- arch/arm/mach-pxa/Makefile | 16 +- arch/arm/mach-pxa/am200epd.c | 374 + arch/arm/mach-pxa/cm-x300.c | 473 + arch/arm/mach-pxa/devices.h | 1 + arch/arm/mach-pxa/e330.c | 43 + arch/arm/mach-pxa/e350.c | 43 + arch/arm/mach-pxa/e400.c | 94 + arch/arm/mach-pxa/e400_lcd.c | 56 - arch/arm/mach-pxa/e740.c | 169 + arch/arm/mach-pxa/e740_lcd.c | 123 - arch/arm/mach-pxa/e750.c | 126 + arch/arm/mach-pxa/e750_lcd.c | 109 - arch/arm/mach-pxa/e800.c | 186 + arch/arm/mach-pxa/e800_lcd.c | 159 - arch/arm/mach-pxa/eseries.c | 157 +- arch/arm/mach-pxa/eseries.h | 4 + arch/arm/mach-pxa/eseries_udc.c | 57 - arch/arm/mach-pxa/gumstix.c | 100 +- arch/arm/mach-pxa/include/mach/camera.h | 2 - arch/arm/mach-pxa/include/mach/hardware.h | 2 + arch/arm/mach-pxa/include/mach/i2c.h | 6 +- arch/arm/mach-pxa/include/mach/irqs.h | 8 +- arch/arm/mach-pxa/include/mach/mfp-pxa320.h | 8 +- arch/arm/mach-pxa/include/mach/mioa701.h | 67 + arch/arm/mach-pxa/include/mach/palmz72.h | 67 + arch/arm/mach-pxa/include/mach/pm.h | 2 + arch/arm/mach-pxa/include/mach/pxa3xx_nand.h | 44 +- arch/arm/mach-pxa/include/mach/ssp.h | 24 + arch/arm/mach-pxa/include/mach/trizeps4.h | 84 +- arch/arm/mach-pxa/mioa701.c | 905 ++ arch/arm/mach-pxa/mioa701_bootresume.S | 36 + arch/arm/mach-pxa/palmz72.c | 481 + arch/arm/mach-pxa/pm.c | 18 + arch/arm/mach-pxa/pxa25x.c | 20 +- arch/arm/mach-pxa/pxa27x.c | 22 +- arch/arm/mach-pxa/pxa3xx.c | 45 + arch/arm/mach-pxa/trizeps4.c | 549 +- arch/arm/mach-pxa/zylonite_pxa300.c | 8 +- arch/arm/mach-pxa/zylonite_pxa320.c | 6 + arch/arm/mach-sa1100/cpu-sa1100.c | 4 +- arch/arm/mach-sa1100/cpu-sa1110.c | 1 + arch/arm/mach-sa1100/include/mach/SA-1100.h | 16 - arch/arm/mach-sa1100/include/mach/hardware.h | 18 + arch/arm/mm/abort-ev7.S | 1 + arch/arm/mm/abort-nommu.S | 1 + arch/arm/mm/cache-v7.S | 10 + arch/arm/mm/cache-xsc3l2.c | 3 +- arch/arm/mm/copypage-v6.c | 1 + arch/arm/mm/fault-armv.c | 1 + arch/arm/mm/flush.c | 1 + arch/arm/mm/ioremap.c | 1 + arch/arm/mm/mmap.c | 5 +- arch/arm/mm/mmu.c | 1 + arch/arm/mm/proc-v7.S | 8 + arch/arm/mm/tlb-v7.S | 2 + arch/arm/oprofile/Makefile | 1 + arch/arm/oprofile/common.c | 4 + arch/arm/oprofile/op_arm_model.h | 1 + arch/arm/oprofile/op_model_v7.c | 411 + arch/arm/oprofile/op_model_v7.h | 103 + arch/arm/oprofile/op_model_xscale.c | 2 +- arch/arm/plat-mxc/include/mach/mxc_nand.h | 27 + arch/arm/plat-omap/Kconfig | 24 + arch/arm/plat-omap/common.c | 36 +- arch/arm/plat-omap/dma.c | 6 +- arch/arm/plat-omap/dmtimer.c | 2 +- arch/arm/plat-omap/gpio.c | 2 +- arch/arm/plat-omap/include/mach/clock.h | 3 + arch/arm/plat-omap/include/mach/clockdomain.h | 106 + arch/arm/plat-omap/include/mach/control.h | 6 +- arch/arm/plat-omap/include/mach/fpga.h | 12 +- arch/arm/plat-omap/include/mach/hardware.h | 2 +- arch/arm/plat-omap/include/mach/io.h | 53 +- arch/arm/plat-omap/include/mach/irqs.h | 2 + arch/arm/plat-omap/include/mach/mcbsp.h | 4 +- arch/arm/plat-omap/include/mach/onenand.h | 6 +- arch/arm/plat-omap/include/mach/pm.h | 4 +- arch/arm/plat-omap/include/mach/powerdomain.h | 166 + arch/arm/plat-omap/include/mach/sdrc.h | 6 +- arch/arm/plat-omap/include/mach/serial.h | 12 +- arch/arm/plat-omap/mcbsp.c | 25 +- arch/arm/vfp/entry.S | 8 +- arch/arm/vfp/vfphw.S | 25 +- arch/avr32/include/asm/byteorder.h | 22 +- arch/avr32/include/asm/thread_info.h | 2 +- arch/avr32/kernel/asm-offsets.c | 6 + arch/avr32/kernel/entry-avr32b.S | 59 +- arch/avr32/mach-at32ap/include/mach/io.h | 3 +- arch/avr32/mach-at32ap/pm-at32ap700x.S | 2 +- arch/avr32/oprofile/Makefile | 2 +- arch/avr32/oprofile/backtrace.c | 81 + arch/avr32/oprofile/op_model_avr32.c | 4 + arch/cris/arch-v10/boot/compressed/Makefile | 2 +- arch/cris/arch-v10/boot/compressed/decompress.ld | 30 - arch/cris/arch-v10/boot/compressed/decompress.lds | 30 + arch/cris/arch-v10/boot/rescue/Makefile | 2 +- arch/cris/arch-v10/boot/rescue/rescue.ld | 20 - arch/cris/arch-v10/boot/rescue/rescue.lds | 20 + arch/cris/arch-v32/boot/compressed/Makefile | 2 +- arch/cris/arch-v32/boot/compressed/decompress.ld | 30 - arch/cris/arch-v32/boot/compressed/decompress.lds | 30 + arch/cris/arch-v32/boot/rescue/Makefile | 2 +- arch/cris/arch-v32/boot/rescue/rescue.ld | 43 - arch/cris/arch-v32/boot/rescue/rescue.lds | 43 + arch/ia64/ia32/sys_ia32.c | 7 +- arch/ia64/include/asm/statfs.h | 52 +- arch/ia64/kernel/mca_drv.c | 2 +- arch/ia64/kernel/perfmon.c | 43 +- arch/ia64/kernel/signal.c | 4 +- arch/ia64/kvm/Kconfig | 2 + arch/ia64/kvm/irq.h | 32 + arch/ia64/kvm/kvm-ia64.c | 37 +- arch/m68k/Kconfig | 43 +- arch/m68k/amiga/config.c | 9 + arch/m68k/atari/atakeyb.c | 12 - arch/m68k/atari/time.c | 38 +- arch/m68k/bvme6000/config.c | 15 +- arch/m68k/bvme6000/rtc.c | 30 +- arch/m68k/configs/amiga_defconfig | 53 +- arch/m68k/configs/apollo_defconfig | 53 +- arch/m68k/configs/atari_defconfig | 60 +- arch/m68k/configs/bvme6000_defconfig | 52 +- arch/m68k/configs/hp300_defconfig | 52 +- arch/m68k/configs/mac_defconfig | 53 +- arch/m68k/configs/multi_defconfig | 62 +- arch/m68k/configs/mvme147_defconfig | 52 +- arch/m68k/configs/mvme16x_defconfig | 52 +- arch/m68k/configs/q40_defconfig | 53 +- arch/m68k/configs/sun3_defconfig | 54 +- arch/m68k/configs/sun3x_defconfig | 52 +- arch/m68k/kernel/dma.c | 4 +- arch/m68k/kernel/ints.c | 3 + arch/m68k/kernel/traps.c | 9 +- arch/m68k/kernel/vmlinux-std.lds | 9 +- arch/m68k/mvme16x/rtc.c | 26 +- arch/m68k/q40/config.c | 12 +- arch/m68k/sun3x/time.c | 28 +- arch/m68knommu/platform/coldfire/entry.S | 15 +- arch/mips/Kconfig | 2 +- arch/mips/Makefile | 8 +- arch/mips/kernel/kspd.c | 4 +- arch/mips/kernel/mips-mt-fpaff.c | 5 +- arch/mips/kernel/ptrace32.c | 43 +- arch/mips/kernel/rtlx.c | 4 +- arch/mips/kernel/scall64-n32.S | 2 +- arch/mips/kernel/scall64-o32.S | 2 +- arch/mips/kernel/signal32.c | 12 + arch/mips/kernel/vpe.c | 6 +- arch/mips/pci/Makefile | 1 + arch/mips/pci/pci-tx4938.c | 2 +- arch/mips/pci/pci-tx4939.c | 109 + arch/mips/pmc-sierra/msp71xx/Makefile | 1 + arch/mips/pmc-sierra/msp71xx/gpio.c | 218 + arch/mips/pmc-sierra/msp71xx/gpio_extended.c | 148 + arch/mips/rb532/devices.c | 22 +- arch/mips/rb532/gpio.c | 238 +- arch/mips/rb532/irq.c | 2 +- arch/mips/rb532/prom.c | 12 - arch/mips/rb532/serial.c | 6 +- arch/mips/rb532/setup.c | 4 +- arch/mips/sibyte/common/sb_tbprof.c | 3 +- arch/mips/txx9/Kconfig | 24 +- arch/mips/txx9/generic/Makefile | 2 + arch/mips/txx9/generic/irq_tx4927.c | 11 + arch/mips/txx9/generic/irq_tx4938.c | 11 + arch/mips/txx9/generic/irq_tx4939.c | 215 + arch/mips/txx9/generic/setup.c | 431 +- arch/mips/txx9/generic/setup_tx3927.c | 37 +- arch/mips/txx9/generic/setup_tx4927.c | 97 + arch/mips/txx9/generic/setup_tx4938.c | 122 + arch/mips/txx9/generic/setup_tx4939.c | 460 + arch/mips/txx9/generic/spi_eeprom.c | 103 + arch/mips/txx9/jmr3927/prom.c | 1 - arch/mips/txx9/jmr3927/setup.c | 25 +- arch/mips/txx9/rbtx4927/irq.c | 11 +- arch/mips/txx9/rbtx4927/prom.c | 1 - arch/mips/txx9/rbtx4927/setup.c | 25 +- arch/mips/txx9/rbtx4938/Makefile | 2 +- arch/mips/txx9/rbtx4938/irq.c | 8 +- arch/mips/txx9/rbtx4938/prom.c | 3 - arch/mips/txx9/rbtx4938/setup.c | 63 +- arch/mips/txx9/rbtx4938/spi_eeprom.c | 99 - arch/mips/txx9/rbtx4939/Makefile | 3 + arch/mips/txx9/rbtx4939/irq.c | 96 + arch/mips/txx9/rbtx4939/prom.c | 17 + arch/mips/txx9/rbtx4939/setup.c | 306 + arch/parisc/hpux/fs.c | 5 +- arch/parisc/include/asm/Kbuild | 3 + arch/parisc/include/asm/a.out.h | 20 + arch/parisc/include/asm/agp.h | 24 + arch/parisc/include/asm/asmregs.h | 183 + arch/parisc/include/asm/assembly.h | 519 ++ arch/parisc/include/asm/atomic.h | 348 + arch/parisc/include/asm/auxvec.h | 4 + arch/parisc/include/asm/bitops.h | 239 + arch/parisc/include/asm/bug.h | 92 + arch/parisc/include/asm/bugs.h | 19 + arch/parisc/include/asm/byteorder.h | 82 + arch/parisc/include/asm/cache.h | 60 + arch/parisc/include/asm/cacheflush.h | 121 + arch/parisc/include/asm/checksum.h | 210 + arch/parisc/include/asm/compat.h | 165 + arch/parisc/include/asm/compat_rt_sigframe.h | 50 + arch/parisc/include/asm/compat_signal.h | 2 + arch/parisc/include/asm/compat_ucontext.h | 17 + arch/parisc/include/asm/cputime.h | 6 + arch/parisc/include/asm/current.h | 15 + arch/parisc/include/asm/delay.h | 43 + arch/parisc/include/asm/device.h | 7 + arch/parisc/include/asm/div64.h | 1 + arch/parisc/include/asm/dma-mapping.h | 253 + arch/parisc/include/asm/dma.h | 186 + arch/parisc/include/asm/eisa_bus.h | 23 + arch/parisc/include/asm/eisa_eeprom.h | 153 + arch/parisc/include/asm/elf.h | 342 + arch/parisc/include/asm/emergency-restart.h | 6 + arch/parisc/include/asm/errno.h | 124 + arch/parisc/include/asm/fb.h | 19 + arch/parisc/include/asm/fcntl.h | 39 + arch/parisc/include/asm/fixmap.h | 30 + arch/parisc/include/asm/floppy.h | 271 + arch/parisc/include/asm/futex.h | 77 + arch/parisc/include/asm/grfioctl.h | 113 + arch/parisc/include/asm/hardirq.h | 29 + arch/parisc/include/asm/hardware.h | 127 + arch/parisc/include/asm/hw_irq.h | 8 + arch/parisc/include/asm/ide.h | 61 + arch/parisc/include/asm/io.h | 293 + arch/parisc/include/asm/ioctl.h | 44 + arch/parisc/include/asm/ioctls.h | 90 + arch/parisc/include/asm/ipcbuf.h | 27 + arch/parisc/include/asm/irq.h | 57 + arch/parisc/include/asm/irq_regs.h | 1 + arch/parisc/include/asm/kdebug.h | 1 + arch/parisc/include/asm/kmap_types.h | 30 + arch/parisc/include/asm/led.h | 42 + arch/parisc/include/asm/linkage.h | 31 + arch/parisc/include/asm/local.h | 1 + arch/parisc/include/asm/machdep.h | 16 + arch/parisc/include/asm/mc146818rtc.h | 9 + arch/parisc/include/asm/mckinley.h | 9 + arch/parisc/include/asm/mman.h | 61 + arch/parisc/include/asm/mmu.h | 7 + arch/parisc/include/asm/mmu_context.h | 75 + arch/parisc/include/asm/mmzone.h | 73 + arch/parisc/include/asm/module.h | 32 + arch/parisc/include/asm/msgbuf.h | 37 + arch/parisc/include/asm/mutex.h | 9 + arch/parisc/include/asm/page.h | 173 + arch/parisc/include/asm/param.h | 22 + arch/parisc/include/asm/parisc-device.h | 64 + arch/parisc/include/asm/parport.h | 18 + arch/parisc/include/asm/pci.h | 294 + arch/parisc/include/asm/pdc.h | 762 ++ arch/parisc/include/asm/pdc_chassis.h | 381 + arch/parisc/include/asm/pdcpat.h | 308 + arch/parisc/include/asm/percpu.h | 7 + arch/parisc/include/asm/perf.h | 74 + arch/parisc/include/asm/pgalloc.h | 149 + arch/parisc/include/asm/pgtable.h | 508 ++ arch/parisc/include/asm/poll.h | 1 + arch/parisc/include/asm/posix_types.h | 129 + arch/parisc/include/asm/prefetch.h | 39 + arch/parisc/include/asm/processor.h | 357 + arch/parisc/include/asm/psw.h | 62 + arch/parisc/include/asm/ptrace.h | 58 + arch/parisc/include/asm/real.h | 5 + arch/parisc/include/asm/resource.h | 7 + arch/parisc/include/asm/ropes.h | 322 + arch/parisc/include/asm/rt_sigframe.h | 23 + arch/parisc/include/asm/rtc.h | 131 + arch/parisc/include/asm/runway.h | 12 + arch/parisc/include/asm/scatterlist.h | 27 + arch/parisc/include/asm/sections.h | 7 + arch/parisc/include/asm/segment.h | 6 + arch/parisc/include/asm/sembuf.h | 29 + arch/parisc/include/asm/serial.h | 10 + arch/parisc/include/asm/setup.h | 6 + arch/parisc/include/asm/shmbuf.h | 58 + arch/parisc/include/asm/shmparam.h | 8 + arch/parisc/include/asm/sigcontext.h | 20 + arch/parisc/include/asm/siginfo.h | 14 + arch/parisc/include/asm/signal.h | 153 + arch/parisc/include/asm/smp.h | 68 + arch/parisc/include/asm/socket.h | 62 + arch/parisc/include/asm/sockios.h | 13 + arch/parisc/include/asm/spinlock.h | 194 + arch/parisc/include/asm/spinlock_types.h | 21 + arch/parisc/include/asm/stat.h | 100 + arch/parisc/include/asm/statfs.h | 7 + arch/parisc/include/asm/string.h | 10 + arch/parisc/include/asm/superio.h | 85 + arch/parisc/include/asm/system.h | 182 + arch/parisc/include/asm/termbits.h | 200 + arch/parisc/include/asm/termios.h | 90 + arch/parisc/include/asm/thread_info.h | 74 + arch/parisc/include/asm/timex.h | 20 + arch/parisc/include/asm/tlb.h | 27 + arch/parisc/include/asm/tlbflush.h | 80 + arch/parisc/include/asm/topology.h | 6 + arch/parisc/include/asm/traps.h | 16 + arch/parisc/include/asm/types.h | 36 + arch/parisc/include/asm/uaccess.h | 244 + arch/parisc/include/asm/ucontext.h | 12 + arch/parisc/include/asm/unaligned.h | 16 + arch/parisc/include/asm/unistd.h | 991 ++ arch/parisc/include/asm/unwind.h | 77 + arch/parisc/include/asm/user.h | 5 + arch/parisc/include/asm/vga.h | 6 + arch/parisc/include/asm/xor.h | 1 + arch/parisc/kernel/.gitignore | 1 + arch/parisc/kernel/asm-offsets.c | 3 + arch/parisc/kernel/firmware.c | 69 +- arch/parisc/kernel/head.S | 2 +- arch/parisc/kernel/real2.S | 12 + arch/parisc/kernel/setup.c | 27 +- arch/parisc/kernel/signal.c | 2 +- arch/powerpc/Kconfig.debug | 5 + arch/powerpc/boot/dtc-src/Makefile.dtc | 18 +- arch/powerpc/boot/dtc-src/checks.c | 305 +- arch/powerpc/boot/dtc-src/data.c | 62 +- arch/powerpc/boot/dtc-src/dtc-lexer.l | 120 +- arch/powerpc/boot/dtc-src/dtc-lexer.lex.c_shipped | 445 +- arch/powerpc/boot/dtc-src/dtc-parser.tab.c_shipped | 387 +- arch/powerpc/boot/dtc-src/dtc-parser.tab.h_shipped | 12 +- arch/powerpc/boot/dtc-src/dtc-parser.y | 67 +- arch/powerpc/boot/dtc-src/dtc.c | 41 +- arch/powerpc/boot/dtc-src/dtc.h | 43 +- arch/powerpc/boot/dtc-src/flattree.c | 232 +- arch/powerpc/boot/dtc-src/fstree.c | 8 +- arch/powerpc/boot/dtc-src/libfdt_env.h | 23 + arch/powerpc/boot/dtc-src/livetree.c | 9 +- arch/powerpc/boot/dtc-src/srcpos.c | 121 +- arch/powerpc/boot/dtc-src/srcpos.h | 30 +- arch/powerpc/boot/dtc-src/treesource.c | 15 +- arch/powerpc/boot/dtc-src/version_gen.h | 2 +- arch/powerpc/boot/dts/mgcoge.dts | 174 + arch/powerpc/boot/dts/mgsuvd.dts | 163 + arch/powerpc/boot/dts/mpc836x_mds.dts | 23 +- arch/powerpc/boot/libfdt/Makefile.libfdt | 8 +- arch/powerpc/boot/libfdt/fdt.c | 61 +- arch/powerpc/boot/libfdt/fdt_ro.c | 329 +- arch/powerpc/boot/libfdt/fdt_rw.c | 200 +- arch/powerpc/boot/libfdt/fdt_strerror.c | 34 +- arch/powerpc/boot/libfdt/fdt_sw.c | 55 +- arch/powerpc/boot/libfdt/fdt_wip.c | 9 +- arch/powerpc/boot/libfdt/libfdt.h | 383 +- arch/powerpc/boot/libfdt/libfdt_internal.h | 24 +- arch/powerpc/boot/libfdt_env.h | 1 + arch/powerpc/configs/83xx/mpc836x_mds_defconfig | 79 +- arch/powerpc/configs/mgcoge_defconfig | 900 ++ arch/powerpc/configs/mgsuvd_defconfig | 872 ++ arch/powerpc/include/asm/cputable.h | 1 + arch/powerpc/include/asm/kvm_host.h | 14 +- arch/powerpc/include/asm/kvm_ppc.h | 12 + arch/powerpc/include/asm/mpic.h | 4 +- arch/powerpc/include/asm/msi_bitmap.h | 35 + arch/powerpc/include/asm/of_device.h | 3 - arch/powerpc/include/asm/of_platform.h | 3 - arch/powerpc/include/asm/smp.h | 39 +- arch/powerpc/include/asm/statfs.h | 54 - arch/powerpc/kernel/Makefile | 4 +- arch/powerpc/kernel/asm-offsets.c | 4 +- arch/powerpc/kernel/btext.c | 34 +- arch/powerpc/kernel/cputable.c | 24 + arch/powerpc/kernel/entry_64.S | 53 +- arch/powerpc/kernel/lparcfg.c | 8 +- arch/powerpc/kernel/setup_32.c | 11 - arch/powerpc/kernel/sysfs.c | 117 +- arch/powerpc/kvm/44x_tlb.c | 49 +- arch/powerpc/kvm/Kconfig | 11 + arch/powerpc/kvm/Makefile | 6 +- arch/powerpc/kvm/booke_guest.c | 17 + arch/powerpc/kvm/booke_interrupts.S | 79 +- arch/powerpc/kvm/emulate.c | 8 +- arch/powerpc/kvm/powerpc.c | 99 +- arch/powerpc/mm/fault.c | 2 +- arch/powerpc/mm/fsl_booke_mmu.c | 5 +- arch/powerpc/mm/hash_utils_64.c | 2 + arch/powerpc/oprofile/op_model_power4.c | 4 +- arch/powerpc/platforms/82xx/Kconfig | 8 + arch/powerpc/platforms/82xx/Makefile | 1 + arch/powerpc/platforms/82xx/mgcoge.c | 129 + arch/powerpc/platforms/8xx/Kconfig | 6 + arch/powerpc/platforms/8xx/Makefile | 1 + arch/powerpc/platforms/8xx/mgsuvd.c | 92 + arch/powerpc/platforms/cell/spufs/inode.c | 9 +- arch/powerpc/platforms/cell/spufs/syscalls.c | 4 +- arch/powerpc/platforms/chrp/time.c | 24 +- arch/powerpc/platforms/iseries/mf.c | 26 +- arch/powerpc/platforms/maple/time.c | 24 +- arch/powerpc/platforms/powermac/time.c | 3 + arch/powerpc/platforms/pseries/cmm.c | 4 +- arch/powerpc/platforms/pseries/eeh_driver.c | 2 +- arch/powerpc/sysdev/Kconfig | 6 + arch/powerpc/sysdev/Makefile | 1 + arch/powerpc/sysdev/fsl_msi.c | 109 +- arch/powerpc/sysdev/fsl_msi.h | 8 +- arch/powerpc/sysdev/mpic.h | 2 - arch/powerpc/sysdev/mpic_msi.c | 123 +- arch/powerpc/sysdev/mpic_pasemi_msi.c | 24 +- arch/powerpc/sysdev/mpic_u3msi.c | 22 +- arch/powerpc/sysdev/msi_bitmap.c | 247 + arch/s390/Kconfig | 8 +- arch/s390/hypfs/inode.c | 4 +- arch/s390/include/asm/ptrace.h | 1 + arch/s390/include/asm/qdio.h | 8 +- arch/s390/include/asm/statfs.h | 11 +- arch/s390/include/asm/syscall.h | 80 + arch/s390/include/asm/thread_info.h | 2 + arch/s390/kernel/compat_linux.c | 36 +- arch/s390/kernel/compat_linux.h | 1 - arch/s390/kernel/compat_wrapper.S | 2 - arch/s390/kernel/entry.S | 50 +- arch/s390/kernel/entry64.S | 42 +- arch/s390/kernel/irq.c | 3 + arch/s390/kernel/ptrace.c | 61 +- arch/s390/kernel/signal.c | 13 + arch/s390/kernel/syscalls.S | 2 +- arch/s390/kvm/priv.c | 4 +- arch/s390/mm/extmem.c | 251 +- arch/sh/Kconfig | 4 + arch/sh/configs/ap325rxa_defconfig | 22 +- arch/sh/configs/migor_defconfig | 21 +- arch/sh/include/asm/bitops-llsc.h | 144 + arch/sh/include/asm/bitops.h | 2 + arch/sh/include/asm/cmpxchg-llsc.h | 71 + arch/sh/include/asm/smp.h | 26 +- arch/sh/include/asm/system.h | 2 + arch/sh/include/asm/uaccess_64.h | 2 + arch/sh/kernel/cpu/sh4a/smp-shx3.c | 67 +- arch/sh/kernel/machine_kexec.c | 2 +- arch/sh/kernel/process_32.c | 12 +- arch/sh/kernel/ptrace_64.c | 2 + arch/sh/kernel/setup.c | 6 +- arch/sh/kernel/smp.c | 43 +- arch/sh/kernel/sys_sh.c | 2 +- arch/sh/kernel/time_32.c | 10 +- arch/sh/kernel/timers/Makefile | 1 + arch/sh/kernel/timers/timer-broadcast.c | 57 + arch/sh/lib64/c-checksum.c | 4 +- arch/sh/mm/consistent.c | 6 +- arch/sparc/Kconfig | 26 +- arch/sparc/include/asm/Kbuild | 2 - arch/sparc/include/asm/asmmacro.h | 5 - arch/sparc/include/asm/bpp.h | 73 - arch/sparc/include/asm/bugs.h | 7 - arch/sparc/include/asm/cpudata_64.h | 1 - arch/sparc/include/asm/dma-mapping_32.h | 59 +- arch/sparc/include/asm/dma.h | 141 +- arch/sparc/include/asm/dma_32.h | 288 - arch/sparc/include/asm/dma_64.h | 205 - arch/sparc/include/asm/ebus.h | 8 - arch/sparc/include/asm/ebus_32.h | 99 - arch/sparc/include/asm/ebus_64.h | 95 - arch/sparc/include/asm/ebus_dma.h | 35 + arch/sparc/include/asm/elf_32.h | 7 +- arch/sparc/include/asm/fhc.h | 43 +- arch/sparc/include/asm/floppy_32.h | 16 +- arch/sparc/include/asm/floppy_64.h | 130 +- arch/sparc/include/asm/gpio.h | 36 + arch/sparc/include/asm/io-unit.h | 4 - arch/sparc/include/asm/io_32.h | 19 +- arch/sparc/include/asm/io_64.h | 22 +- arch/sparc/include/asm/irq_64.h | 1 - arch/sparc/include/asm/mc146818rtc_64.h | 10 +- arch/sparc/include/asm/memctrl.h | 9 + arch/sparc/include/asm/mostek.h | 8 - arch/sparc/include/asm/mostek_32.h | 171 - arch/sparc/include/asm/mostek_64.h | 143 - arch/sparc/include/asm/of_device.h | 2 + arch/sparc/include/asm/of_platform.h | 3 - arch/sparc/include/asm/oplib_32.h | 1 - arch/sparc/include/asm/page_32.h | 5 +- arch/sparc/include/asm/parport.h | 4 +- arch/sparc/include/asm/pci_32.h | 2 + arch/sparc/include/asm/pgtable_32.h | 4 - arch/sparc/include/asm/prom.h | 12 + arch/sparc/include/asm/reboot.h | 6 - arch/sparc/include/asm/rtc.h | 26 - arch/sparc/include/asm/sbus.h | 8 - arch/sparc/include/asm/sbus_32.h | 153 - arch/sparc/include/asm/sbus_64.h | 190 - arch/sparc/include/asm/sstate.h | 13 - arch/sparc/include/asm/starfire.h | 1 - arch/sparc/include/asm/statfs.h | 8 +- arch/sparc/include/asm/statfs_32.h | 6 - arch/sparc/include/asm/statfs_64.h | 54 - arch/sparc/include/asm/sun4paddr.h | 56 - arch/sparc/include/asm/sun4prom.h | 83 - arch/sparc/include/asm/system_32.h | 8 +- arch/sparc/include/asm/system_64.h | 5 +- arch/sparc/include/asm/thread_info_32.h | 4 - arch/sparc/include/asm/timer_32.h | 8 +- arch/sparc/include/asm/vac-ops.h | 7 - arch/sparc/include/asm/vfc_ioctls.h | 58 - arch/sparc/kernel/Makefile | 4 +- arch/sparc/kernel/apc.c | 72 +- arch/sparc/kernel/auxio.c | 6 +- arch/sparc/kernel/devices.c | 2 +- arch/sparc/kernel/dma.c | 227 + arch/sparc/kernel/dma.h | 14 + arch/sparc/kernel/ebus.c | 393 - arch/sparc/kernel/entry.S | 54 - arch/sparc/kernel/head.S | 28 +- arch/sparc/kernel/idprom.c | 7 - arch/sparc/kernel/ioport.c | 227 +- arch/sparc/kernel/irq.c | 4 + arch/sparc/kernel/of_device.c | 74 +- arch/sparc/kernel/pcic.c | 9 +- arch/sparc/kernel/pmc.c | 57 +- arch/sparc/kernel/process.c | 2 +- arch/sparc/kernel/prom.c | 7 +- arch/sparc/kernel/setup.c | 8 +- arch/sparc/kernel/sparc_ksyms.c | 25 - arch/sparc/kernel/sun4c_irq.c | 74 +- arch/sparc/kernel/sun4d_irq.c | 109 +- arch/sparc/kernel/sun4d_smp.c | 1 - arch/sparc/kernel/sun4m_irq.c | 24 +- arch/sparc/kernel/sun4setup.c | 75 - arch/sparc/kernel/sys_sparc.c | 8 +- arch/sparc/kernel/tick14.c | 1 - arch/sparc/kernel/time.c | 380 +- arch/sparc/mm/Makefile | 9 +- arch/sparc/mm/btfixup.c | 6 +- arch/sparc/mm/fault.c | 2 +- arch/sparc/mm/init.c | 14 +- arch/sparc/mm/io-unit.c | 136 +- arch/sparc/mm/iommu.c | 113 +- arch/sparc/mm/nosrmmu.c | 59 - arch/sparc/mm/srmmu.c | 1 - arch/sparc/mm/sun4c.c | 204 +- arch/sparc/prom/Makefile | 2 - arch/sparc/prom/bootstr.c | 4 - arch/sparc/prom/console.c | 3 - arch/sparc/prom/init.c | 12 - arch/sparc/prom/memory.c | 14 - arch/sparc/prom/ranges.c | 1 - arch/sparc/prom/sun4prom.c | 161 - arch/sparc64/Kconfig | 23 + arch/sparc64/kernel/Makefile | 9 +- arch/sparc64/kernel/auxio.c | 2 +- arch/sparc64/kernel/central.c | 617 +- arch/sparc64/kernel/chmc.c | 817 ++- arch/sparc64/kernel/cpu.c | 208 +- arch/sparc64/kernel/ds.c | 4 +- arch/sparc64/kernel/ebus.c | 299 +- arch/sparc64/kernel/entry.h | 7 +- arch/sparc64/kernel/head.S | 1 + arch/sparc64/kernel/hvapi.c | 3 - arch/sparc64/kernel/hvcalls.S | 354 +- arch/sparc64/kernel/irq.c | 1 - arch/sparc64/kernel/of_device.c | 59 +- arch/sparc64/kernel/pci.c | 152 +- arch/sparc64/kernel/pci_fire.c | 91 +- arch/sparc64/kernel/pci_impl.h | 4 +- arch/sparc64/kernel/pci_psycho.c | 117 +- arch/sparc64/kernel/pci_sabre.c | 138 +- arch/sparc64/kernel/pci_schizo.c | 155 +- arch/sparc64/kernel/pci_sun4v.c | 153 +- arch/sparc64/kernel/pci_sun4v_asm.S | 99 +- arch/sparc64/kernel/power.c | 55 +- arch/sparc64/kernel/process.c | 33 - arch/sparc64/kernel/prom.c | 6 + arch/sparc64/kernel/ptrace.c | 38 +- arch/sparc64/kernel/reboot.c | 52 + arch/sparc64/kernel/sbus.c | 166 +- arch/sparc64/kernel/sparc64_ksyms.c | 23 +- arch/sparc64/kernel/sstate.c | 67 +- arch/sparc64/kernel/starfire.c | 5 - arch/sparc64/kernel/sys_sparc32.c | 8 - arch/sparc64/kernel/syscalls.S | 20 +- arch/sparc64/kernel/systbls.S | 2 +- arch/sparc64/kernel/time.c | 1164 +--- arch/sparc64/kernel/traps.c | 63 +- arch/sparc64/mm/init.c | 48 +- arch/um/Kconfig.char | 4 + arch/um/sys-x86_64/syscall_table.c | 4 +- arch/x86/Kconfig | 169 +- arch/x86/Kconfig.cpu | 70 + arch/x86/Kconfig.debug | 123 + arch/x86/Makefile | 2 +- arch/x86/boot/boot.h | 3 - arch/x86/boot/compressed/head_32.S | 5 +- arch/x86/boot/compressed/misc.c | 12 +- arch/x86/boot/cpucheck.c | 8 +- arch/x86/configs/i386_defconfig | 1 - arch/x86/crypto/Makefile | 2 + arch/x86/crypto/crc32c-intel.c | 197 + arch/x86/es7000/Makefile | 5 + arch/x86/es7000/es7000.h | 114 + arch/x86/es7000/es7000plat.c | 262 + arch/x86/ia32/ia32_aout.c | 13 +- arch/x86/ia32/ia32_signal.c | 72 +- arch/x86/kernel/Makefile | 15 +- arch/x86/kernel/acpi/boot.c | 14 +- arch/x86/kernel/alternative.c | 44 +- arch/x86/kernel/amd_iommu.c | 2 - arch/x86/kernel/apic.c | 2219 +++++ arch/x86/kernel/apic_32.c | 1746 ---- arch/x86/kernel/apic_64.c | 1390 --- arch/x86/kernel/apm_32.c | 1 - arch/x86/kernel/asm-offsets_32.c | 1 + arch/x86/kernel/asm-offsets_64.c | 3 +- arch/x86/kernel/bios_uv.c | 10 +- arch/x86/kernel/cpu/Makefile | 21 +- arch/x86/kernel/cpu/addon_cpuid_features.c | 88 + arch/x86/kernel/cpu/cmpxchg.c | 72 + arch/x86/kernel/cpu/common.c | 47 +- arch/x86/kernel/cpu/common_64.c | 130 +- arch/x86/kernel/cpu/cpufreq/acpi-cpufreq.c | 13 +- arch/x86/kernel/cpu/cpufreq/elanfreq.c | 42 +- arch/x86/kernel/cpu/cpufreq/powernow-k6.c | 41 +- arch/x86/kernel/cpu/cyrix.c | 16 +- arch/x86/kernel/cpu/feature_names.c | 7 +- arch/x86/kernel/cpu/intel.c | 82 +- arch/x86/kernel/cpu/intel_64.c | 5 +- arch/x86/kernel/cpu/intel_cacheinfo.c | 169 +- arch/x86/kernel/cpu/mtrr/main.c | 2 +- arch/x86/kernel/cpu/perfctr-watchdog.c | 11 +- arch/x86/kernel/cpuid.c | 5 +- arch/x86/kernel/crash_dump_64.c | 7 +- arch/x86/kernel/e820.c | 4 + arch/x86/kernel/early_printk.c | 762 ++- arch/x86/kernel/entry_32.S | 46 +- arch/x86/kernel/entry_64.S | 64 +- arch/x86/kernel/ftrace.c | 120 +- arch/x86/kernel/genapic_64.c | 88 +- arch/x86/kernel/genapic_flat_64.c | 62 +- arch/x86/kernel/genx2apic_cluster.c | 159 + arch/x86/kernel/genx2apic_phys.c | 154 + arch/x86/kernel/genx2apic_uv_x.c | 70 +- arch/x86/kernel/hpet.c | 6 +- arch/x86/kernel/i387.c | 154 +- arch/x86/kernel/i8259.c | 24 + arch/x86/kernel/io_apic.c | 3924 ++++++++ arch/x86/kernel/io_apic_32.c | 2901 ------ arch/x86/kernel/io_apic_64.c | 2431 ----- arch/x86/kernel/ioport.c | 1 + arch/x86/kernel/ipi.c | 3 +- arch/x86/kernel/irq_32.c | 71 +- arch/x86/kernel/irq_64.c | 74 +- arch/x86/kernel/irqinit_32.c | 85 +- arch/x86/kernel/irqinit_64.c | 28 +- arch/x86/kernel/kvm.c | 2 +- arch/x86/kernel/kvmclock.c | 30 + arch/x86/kernel/ldt.c | 10 +- arch/x86/kernel/microcode.c | 634 +- arch/x86/kernel/microcode_amd.c | 467 + arch/x86/kernel/microcode_intel.c | 489 + arch/x86/kernel/mpparse.c | 2 + arch/x86/kernel/msr.c | 4 +- arch/x86/kernel/numaq_32.c | 7 + arch/x86/kernel/paravirt-spinlocks.c | 37 + arch/x86/kernel/paravirt.c | 33 +- arch/x86/kernel/paravirt_patch_32.c | 8 +- arch/x86/kernel/paravirt_patch_64.c | 6 +- arch/x86/kernel/pci-calgary_64.c | 14 + arch/x86/kernel/pci-dma.c | 148 +- arch/x86/kernel/pci-gart_64.c | 76 +- arch/x86/kernel/pci-nommu.c | 62 + arch/x86/kernel/process.c | 2 +- arch/x86/kernel/process_32.c | 6 +- arch/x86/kernel/process_64.c | 151 +- arch/x86/kernel/ptrace.c | 73 +- arch/x86/kernel/pvclock.c | 12 + arch/x86/kernel/quirks.c | 3 - arch/x86/kernel/setup.c | 22 + arch/x86/kernel/setup_percpu.c | 28 +- arch/x86/kernel/sigframe.h | 19 +- arch/x86/kernel/signal_32.c | 57 +- arch/x86/kernel/signal_64.c | 201 +- arch/x86/kernel/smpboot.c | 47 +- arch/x86/kernel/stacktrace.c | 7 + arch/x86/kernel/summit_32.c | 2 +- arch/x86/kernel/sys_i386_32.c | 2 + arch/x86/kernel/sys_x86_64.c | 44 +- arch/x86/kernel/syscall_64.c | 4 +- arch/x86/kernel/time_32.c | 1 + arch/x86/kernel/tls.c | 1 + arch/x86/kernel/traps_32.c | 16 +- arch/x86/kernel/traps_64.c | 88 +- arch/x86/kernel/visws_quirks.c | 48 +- arch/x86/kernel/vm86_32.c | 1 + arch/x86/kernel/vmi_32.c | 16 +- arch/x86/kernel/vmiclock_32.c | 3 + arch/x86/kernel/vmlinux_32.lds.S | 2 + arch/x86/kernel/vmlinux_64.lds.S | 3 + arch/x86/kernel/xsave.c | 316 + arch/x86/kvm/i8254.c | 76 +- arch/x86/kvm/i8254.h | 7 +- arch/x86/kvm/i8259.c | 36 +- arch/x86/kvm/irq.c | 36 +- arch/x86/kvm/irq.h | 10 +- arch/x86/kvm/kvm_cache_regs.h | 32 + arch/x86/kvm/lapic.c | 11 +- arch/x86/kvm/mmu.c | 188 +- arch/x86/kvm/paging_tmpl.h | 161 +- arch/x86/kvm/svm.c | 150 +- arch/x86/kvm/vmx.c | 688 +- arch/x86/kvm/vmx.h | 4 +- arch/x86/kvm/x86.c | 670 +- arch/x86/kvm/x86.h | 22 + arch/x86/kvm/x86_emulate.c | 48 +- arch/x86/lguest/boot.c | 41 +- arch/x86/lib/string_32.c | 42 +- arch/x86/lib/strstr_32.c | 6 +- arch/x86/lib/usercopy_32.c | 7 + arch/x86/mach-default/setup.c | 19 +- arch/x86/mach-es7000/Makefile | 5 - arch/x86/mach-es7000/es7000.h | 114 - arch/x86/mach-es7000/es7000plat.c | 262 - arch/x86/mach-generic/Makefile | 2 +- arch/x86/mach-generic/bigsmp.c | 13 +- arch/x86/mach-generic/es7000.c | 27 +- arch/x86/mach-generic/numaq.c | 26 +- arch/x86/mach-generic/summit.c | 25 +- arch/x86/mach-voyager/voyager_smp.c | 4 +- arch/x86/mm/Makefile | 2 + arch/x86/mm/discontig_32.c | 2 +- arch/x86/mm/dump_pagetables.c | 4 +- arch/x86/mm/fault.c | 34 +- arch/x86/mm/init_32.c | 4 + arch/x86/mm/init_64.c | 8 +- arch/x86/mm/ioremap.c | 4 +- arch/x86/mm/kmemcheck/Makefile | 3 + arch/x86/mm/kmemcheck/error.c | 216 + arch/x86/mm/kmemcheck/error.h | 15 + arch/x86/mm/kmemcheck/kmemcheck.c | 485 + arch/x86/mm/kmemcheck/opcode.c | 72 + arch/x86/mm/kmemcheck/opcode.h | 9 + arch/x86/mm/kmemcheck/pte.c | 22 + arch/x86/mm/kmemcheck/pte.h | 10 + arch/x86/mm/kmemcheck/shadow.c | 178 + arch/x86/mm/kmemcheck/shadow.h | 16 + arch/x86/mm/kmemcheck/smp.c | 80 + arch/x86/mm/kmemcheck/smp.h | 23 + arch/x86/mm/kmemcheck/string.c | 95 + arch/x86/mm/numa_64.c | 10 +- arch/x86/mm/pageattr-test.c | 7 +- arch/x86/mm/pageattr.c | 247 +- arch/x86/mm/pat.c | 4 +- arch/x86/mm/pf_in.c | 121 +- arch/x86/mm/pgtable_32.c | 3 +- arch/x86/oprofile/Makefile | 2 +- arch/x86/oprofile/nmi_int.c | 127 +- arch/x86/oprofile/op_counter.h | 3 +- arch/x86/oprofile/op_model_amd.c | 559 ++ arch/x86/oprofile/op_model_athlon.c | 190 - arch/x86/oprofile/op_model_p4.c | 179 +- arch/x86/oprofile/op_model_ppro.c | 2 + arch/x86/oprofile/op_x86_model.h | 7 +- arch/x86/pci/acpi.c | 5 - arch/x86/pci/irq.c | 75 +- arch/x86/power/hibernate_asm_32.S | 14 +- arch/x86/xen/Kconfig | 10 +- arch/x86/xen/Makefile | 12 +- arch/x86/xen/debugfs.c | 123 + arch/x86/xen/debugfs.h | 10 + arch/x86/xen/enlighten.c | 253 +- arch/x86/xen/irq.c | 141 + arch/x86/xen/mmu.c | 268 +- arch/x86/xen/multicalls.c | 115 +- arch/x86/xen/smp.c | 167 - arch/x86/xen/spinlock.c | 423 + arch/x86/xen/time.c | 15 +- arch/x86/xen/xen-asm_32.S | 2 +- arch/x86/xen/xen-asm_64.S | 2 +- arch/x86/xen/xen-ops.h | 6 + arch/xtensa/kernel/irq.c | 2 +- arch/xtensa/kernel/setup.c | 5 - arch/xtensa/platforms/iss/network.c | 2 +- block/Makefile | 4 +- block/as-iosched.c | 6 +- block/blk-barrier.c | 71 +- block/blk-core.c | 378 +- block/blk-exec.c | 6 +- block/blk-integrity.c | 9 +- block/blk-map.c | 68 +- block/blk-merge.c | 129 +- block/blk-settings.c | 37 +- block/blk-softirq.c | 167 + block/blk-sysfs.c | 35 +- block/blk-tag.c | 8 +- block/blk-timeout.c | 182 + block/blk.h | 13 + block/blktrace.c | 29 +- block/bsg.c | 9 +- block/cfq-iosched.c | 49 +- block/cmd-filter.c | 9 +- block/compat_ioctl.c | 1 + block/deadline-iosched.c | 40 +- block/elevator.c | 30 +- block/genhd.c | 957 ++- block/ioctl.c | 124 +- block/scsi_ioctl.c | 8 +- crypto/Kconfig | 127 +- crypto/Makefile | 12 +- crypto/algapi.c | 147 +- crypto/algboss.c | 300 + crypto/ansi_cprng.c | 417 + crypto/api.c | 81 +- crypto/blkcipher.c | 29 - crypto/chainiv.c | 44 +- crypto/cryptomgr.c | 222 - crypto/eseqiv.c | 35 +- crypto/fips.c | 27 + crypto/internal.h | 18 +- crypto/krng.c | 66 + crypto/proc.c | 57 +- crypto/rng.c | 126 + crypto/seqiv.c | 27 +- crypto/tcrypt.c | 1347 +--- crypto/tcrypt.h | 8709 +------------------ crypto/testmgr.c | 1868 ++++ crypto/testmgr.h | 8738 ++++++++++++++++++ drivers/acpi/Kconfig | 11 + drivers/acpi/Makefile | 6 + drivers/acpi/battery.c | 2 +- drivers/acpi/bus.c | 53 +- drivers/acpi/button.c | 2 +- drivers/acpi/dispatcher/dsobject.c | 2 +- drivers/acpi/ec.c | 2 +- drivers/acpi/events/evgpe.c | 2 - drivers/acpi/executer/exconfig.c | 116 +- drivers/acpi/glue.c | 40 + drivers/acpi/hardware/hwsleep.c | 7 + drivers/acpi/namespace/nsxfeval.c | 79 + drivers/acpi/namespace/nsxfname.c | 5 + drivers/acpi/pcc_acpi.c | 779 ++ drivers/acpi/power.c | 68 +- drivers/acpi/processor_perflib.c | 2 +- drivers/acpi/scan.c | 80 +- drivers/acpi/sleep/main.c | 49 +- drivers/acpi/tables.c | 2 + drivers/acpi/tables/tbinstal.c | 61 +- drivers/acpi/thermal.c | 2 +- drivers/acpi/utilities/utglobal.c | 44 +- drivers/acpi/utilities/utobject.c | 8 +- drivers/acpi/utilities/utxface.c | 7 +- drivers/acpi/video.c | 35 +- drivers/acpi/video_detect.c | 268 + drivers/acpi/wmi.c | 10 +- drivers/ata/Kconfig | 1 - drivers/ata/libata-eh.c | 13 +- drivers/ata/libata-scsi.c | 2 +- drivers/ata/libata.h | 2 +- drivers/ata/pata_pcmcia.c | 168 +- drivers/atm/fore200e.c | 410 +- drivers/atm/fore200e.h | 7 +- drivers/base/base.h | 2 +- drivers/base/bus.c | 50 + drivers/base/class.c | 136 +- drivers/base/core.c | 11 +- drivers/base/platform.c | 2 +- drivers/base/sys.c | 2 +- drivers/block/aoe/aoeblk.c | 6 +- drivers/block/aoe/aoechr.c | 6 +- drivers/block/aoe/aoecmd.c | 19 +- drivers/block/aoe/aoedev.c | 2 +- drivers/block/hd.c | 9 +- drivers/block/loop.c | 6 +- drivers/block/nbd.c | 4 +- drivers/block/paride/pg.c | 5 +- drivers/block/paride/pt.c | 10 +- drivers/block/pktcdvd.c | 7 +- drivers/block/ps3disk.c | 11 +- drivers/block/sunvdc.c | 4 +- drivers/block/ub.c | 3 - drivers/block/virtio_blk.c | 4 +- drivers/block/xen-blkfront.c | 2 +- drivers/bluetooth/bluecard_cs.c | 8 +- drivers/bluetooth/bt3c_cs.c | 125 +- drivers/bluetooth/btuart_cs.c | 126 +- drivers/bluetooth/dtl1_cs.c | 67 +- drivers/cdrom/cdrom.c | 2 +- drivers/char/agp/agp.h | 5 + drivers/char/agp/alpha-agp.c | 2 + drivers/char/agp/amd-k7-agp.c | 2 + drivers/char/agp/amd64-agp.c | 2 + drivers/char/agp/ati-agp.c | 2 + drivers/char/agp/efficeon-agp.c | 2 + drivers/char/agp/generic.c | 97 +- drivers/char/agp/hp-agp.c | 2 + drivers/char/agp/i460-agp.c | 2 + drivers/char/agp/intel-agp.c | 28 + drivers/char/agp/nvidia-agp.c | 2 + drivers/char/agp/parisc-agp.c | 6 +- drivers/char/agp/sis-agp.c | 2 + drivers/char/agp/sworks-agp.c | 2 + drivers/char/agp/uninorth-agp.c | 4 + drivers/char/agp/via-agp.c | 4 + drivers/char/amiserial.c | 6 +- drivers/char/bsr.c | 5 +- drivers/char/dsp56k.c | 4 +- drivers/char/hpet.c | 155 +- drivers/char/hvc_xen.c | 6 +- drivers/char/hw_random/n2-drv.c | 2 +- drivers/char/hw_random/omap-rng.c | 2 +- drivers/char/ip2/ip2main.c | 12 +- drivers/char/ipmi/ipmi_devintf.c | 2 +- drivers/char/istallion.c | 5 +- drivers/char/lp.c | 4 +- drivers/char/mem.c | 6 +- drivers/char/misc.c | 4 +- drivers/char/pcmcia/cm4000_cs.c | 75 +- drivers/char/pcmcia/cm4040_cs.c | 83 +- drivers/char/pcmcia/ipwireless/main.c | 46 +- drivers/char/ppdev.c | 5 +- drivers/char/random.c | 78 +- drivers/char/raw.c | 7 +- drivers/char/rtc.c | 30 +- drivers/char/serial167.c | 2 +- drivers/char/snsc.c | 4 +- drivers/char/stallion.c | 4 +- drivers/char/tpm/Kconfig | 1 + drivers/char/tty_audit.c | 6 +- drivers/char/tty_io.c | 29 +- drivers/char/vc_screen.c | 12 +- drivers/char/viotape.c | 8 +- drivers/char/vr41xx_giu.c | 2 +- drivers/char/vt.c | 14 +- drivers/char/xilinx_hwicap/xilinx_hwicap.c | 3 +- drivers/clocksource/acpi_pm.c | 7 +- drivers/connector/cn_proc.c | 16 +- drivers/cpufreq/cpufreq.c | 30 +- drivers/cpufreq/cpufreq_conservative.c | 1 + drivers/cpufreq/cpufreq_ondemand.c | 140 +- drivers/dca/dca-sysfs.c | 8 +- drivers/firewire/fw-card.c | 56 +- drivers/firewire/fw-device.c | 37 +- drivers/firewire/fw-sbp2.c | 116 +- drivers/firewire/fw-transaction.c | 48 +- drivers/firewire/fw-transaction.h | 9 +- drivers/firmware/iscsi_ibft.c | 18 +- drivers/gpio/gpiolib.c | 2 +- drivers/gpu/drm/Kconfig | 1 + drivers/gpu/drm/drm_fops.c | 2 +- drivers/gpu/drm/drm_irq.c | 20 +- drivers/gpu/drm/drm_sysfs.c | 2 +- drivers/gpu/drm/i915/Makefile | 3 +- drivers/gpu/drm/i915/i915_dma.c | 171 +- drivers/gpu/drm/i915/i915_drv.c | 462 +- drivers/gpu/drm/i915/i915_drv.h | 877 +-- drivers/gpu/drm/i915/i915_irq.c | 189 +- drivers/gpu/drm/i915/i915_opregion.c | 371 + drivers/gpu/drm/i915/i915_reg.h | 1406 +++ drivers/gpu/drm/i915/i915_suspend.c | 509 ++ drivers/gpu/drm/radeon/radeon_cp.c | 5 +- drivers/gpu/drm/sis/sis_mm.c | 10 +- drivers/hid/Kconfig | 162 + drivers/hid/Makefile | 31 +- drivers/hid/hid-a4tech.c | 162 + drivers/hid/hid-apple.c | 482 + drivers/hid/hid-belkin.c | 105 + drivers/hid/hid-cherry.c | 87 + drivers/hid/hid-chicony.c | 80 + drivers/hid/hid-core.c | 1158 ++- drivers/hid/hid-cypress.c | 158 + drivers/hid/hid-dell.c | 74 + drivers/hid/hid-dummy.c | 60 + drivers/hid/hid-ezkey.c | 95 + drivers/hid/hid-gyration.c | 96 + drivers/hid/hid-ids.h | 386 + drivers/hid/hid-input-quirks.c | 484 - drivers/hid/hid-input.c | 915 +-- drivers/hid/hid-lg.c | 342 + drivers/hid/hid-lg.h | 18 + drivers/hid/hid-lg2ff.c | 116 + drivers/hid/hid-lgff.c | 179 + drivers/hid/hid-microsoft.c | 219 + drivers/hid/hid-monterey.c | 82 + drivers/hid/hid-petalynx.c | 122 + drivers/hid/hid-samsung.c | 100 + drivers/hid/hid-sony.c | 110 + drivers/hid/hid-sunplus.c | 82 + drivers/hid/hidraw.c | 11 +- drivers/hid/usbhid/Kconfig | 35 - drivers/hid/usbhid/Makefile | 6 - drivers/hid/usbhid/hid-core.c | 432 +- drivers/hid/usbhid/hid-ff.c | 12 - drivers/hid/usbhid/hid-lg2ff.c | 114 - drivers/hid/usbhid/hid-lgff.c | 151 - drivers/hid/usbhid/hid-quirks.c | 933 +-- drivers/hid/usbhid/hid-tmff.c | 19 +- drivers/hid/usbhid/hiddev.c | 20 +- drivers/hid/usbhid/usbhid.h | 2 +- drivers/hid/usbhid/usbkbd.c | 12 +- drivers/hid/usbhid/usbmouse.c | 8 +- drivers/hwmon/Kconfig | 15 +- drivers/hwmon/Makefile | 1 + drivers/hwmon/ad7414.c | 2 +- drivers/hwmon/ams/ams-core.c | 82 +- drivers/hwmon/ams/ams-i2c.c | 60 +- drivers/hwmon/ams/ams-input.c | 63 +- drivers/hwmon/ams/ams-pmu.c | 18 +- drivers/hwmon/ams/ams.h | 6 +- drivers/hwmon/atxp1.c | 18 +- drivers/hwmon/dme1737.c | 320 +- drivers/hwmon/hwmon.c | 4 +- drivers/hwmon/lm87.c | 33 +- drivers/hwmon/lm90.c | 444 +- drivers/hwmon/ultra45_env.c | 320 + drivers/i2c/busses/Kconfig | 33 +- drivers/i2c/busses/Makefile | 2 + drivers/i2c/busses/i2c-amd756.c | 5 - drivers/i2c/busses/i2c-floppy.c | 245 + drivers/i2c/busses/i2c-highlander.c | 498 + drivers/i2c/busses/i2c-omap.c | 2 +- drivers/i2c/busses/i2c-pca-isa.c | 20 +- drivers/i2c/busses/i2c-powermac.c | 29 + drivers/i2c/busses/i2c-pxa.c | 49 +- drivers/i2c/busses/i2c-viapro.c | 9 +- drivers/i2c/chips/isp1301_omap.c | 141 +- drivers/i2c/chips/tps65010.c | 12 +- drivers/i2c/i2c-dev.c | 6 +- drivers/ide/Kconfig | 61 +- drivers/ide/Makefile | 23 +- drivers/ide/arm/icside.c | 5 +- drivers/ide/arm/palm_bk3710.c | 8 +- drivers/ide/h8300/ide-h8300.c | 2 +- drivers/ide/ide-acpi.c | 18 +- drivers/ide/ide-atapi.c | 393 +- drivers/ide/ide-cd.c | 110 +- drivers/ide/ide-disk.c | 572 +- drivers/ide/ide-disk.h | 32 + drivers/ide/ide-disk_ioctl.c | 29 + drivers/ide/ide-disk_proc.c | 129 + drivers/ide/ide-dma.c | 65 +- drivers/ide/ide-floppy.c | 954 +-- drivers/ide/ide-floppy.h | 62 + drivers/ide/ide-floppy_ioctl.c | 293 + drivers/ide/ide-floppy_proc.c | 33 + drivers/ide/ide-generic.c | 102 +- drivers/ide/ide-io.c | 313 +- drivers/ide/ide-ioctls.c | 299 + drivers/ide/ide-iops.c | 289 +- drivers/ide/ide-lib.c | 75 +- drivers/ide/ide-probe.c | 456 +- drivers/ide/ide-proc.c | 310 +- drivers/ide/ide-tape.c | 605 +- drivers/ide/ide-taskfile.c | 241 +- drivers/ide/ide-timings.c | 22 +- drivers/ide/ide.c | 347 +- drivers/ide/legacy/ali14xx.c | 3 +- drivers/ide/legacy/buddha.c | 1 - drivers/ide/legacy/dtc2278.c | 1 - drivers/ide/legacy/falconide.c | 1 - drivers/ide/legacy/gayle.c | 1 - drivers/ide/legacy/ht6560b.c | 10 +- drivers/ide/legacy/ide-4drives.c | 2 +- drivers/ide/legacy/ide-cs.c | 159 +- drivers/ide/legacy/macide.c | 1 - drivers/ide/legacy/q40ide.c | 2 - drivers/ide/legacy/qd65xx.c | 25 +- drivers/ide/legacy/umc8672.c | 1 - drivers/ide/mips/au1xxx-ide.c | 6 +- drivers/ide/pci/aec62xx.c | 15 +- drivers/ide/pci/alim15x3.c | 24 +- drivers/ide/pci/amd74xx.c | 18 +- drivers/ide/pci/atiixp.c | 11 +- drivers/ide/pci/cmd640.c | 51 +- drivers/ide/pci/cmd64x.c | 13 +- drivers/ide/pci/cs5520.c | 9 +- drivers/ide/pci/cs5530.c | 27 +- drivers/ide/pci/cs5535.c | 24 +- drivers/ide/pci/cy82c693.c | 128 +- drivers/ide/pci/delkin_cb.c | 7 +- drivers/ide/pci/generic.c | 11 +- drivers/ide/pci/hpt34x.c | 13 +- drivers/ide/pci/hpt366.c | 88 +- drivers/ide/pci/it8213.c | 11 +- drivers/ide/pci/it821x.c | 104 +- drivers/ide/pci/jmicron.c | 11 +- drivers/ide/pci/ns87415.c | 32 +- drivers/ide/pci/opti621.c | 17 +- drivers/ide/pci/pdc202xx_new.c | 23 +- drivers/ide/pci/pdc202xx_old.c | 23 +- drivers/ide/pci/piix.c | 52 +- drivers/ide/pci/rz1000.c | 7 +- drivers/ide/pci/sc1200.c | 27 +- drivers/ide/pci/scc_pata.c | 20 +- drivers/ide/pci/serverworks.c | 19 +- drivers/ide/pci/sgiioc4.c | 1 - drivers/ide/pci/siimage.c | 34 +- drivers/ide/pci/sis5513.c | 13 +- drivers/ide/pci/sl82c105.c | 15 +- drivers/ide/pci/slc90e66.c | 11 +- drivers/ide/pci/tc86c001.c | 6 +- drivers/ide/pci/triflex.c | 20 +- drivers/ide/pci/trm290.c | 11 +- drivers/ide/pci/via82cxxx.c | 18 +- drivers/ide/ppc/pmac.c | 24 +- drivers/ide/setup-pci.c | 33 + drivers/ieee1394/csr1212.c | 2 +- drivers/ieee1394/dv1394.c | 8 +- drivers/ieee1394/eth1394.c | 2 +- drivers/ieee1394/raw1394.c | 8 +- drivers/ieee1394/sbp2.c | 218 +- drivers/ieee1394/sbp2.h | 33 +- drivers/ieee1394/video1394.c | 5 +- drivers/infiniband/core/cm.c | 8 +- drivers/infiniband/core/mad.c | 5 +- drivers/infiniband/core/ucma.c | 4 +- drivers/infiniband/core/user_mad.c | 12 +- drivers/infiniband/core/uverbs_main.c | 9 +- drivers/infiniband/hw/ipath/ipath_file_ops.c | 2 +- drivers/infiniband/hw/ipath/ipath_rc.c | 3 +- drivers/infiniband/hw/ipath/ipath_ruc.c | 3 +- drivers/input/gameport/gameport.c | 88 +- drivers/input/joystick/a3d.c | 3 +- drivers/input/joystick/adi.c | 3 +- drivers/input/joystick/analog.c | 4 +- drivers/input/joystick/cobra.c | 3 +- drivers/input/joystick/gf2k.c | 3 +- drivers/input/joystick/grip.c | 3 +- drivers/input/joystick/grip_mp.c | 3 +- drivers/input/joystick/guillemot.c | 3 +- drivers/input/joystick/iforce/iforce-ff.c | 36 +- drivers/input/joystick/iforce/iforce-main.c | 14 +- drivers/input/joystick/iforce/iforce-packets.c | 8 +- drivers/input/joystick/iforce/iforce-usb.c | 2 +- drivers/input/joystick/interact.c | 3 +- drivers/input/joystick/joydump.c | 3 +- drivers/input/joystick/sidewinder.c | 3 +- drivers/input/joystick/tmdc.c | 3 +- drivers/input/joystick/xpad.c | 2 +- drivers/input/keyboard/atkbd.c | 30 +- drivers/input/keyboard/bf54x-keys.c | 13 +- drivers/input/keyboard/gpio_keys.c | 42 +- drivers/input/misc/Kconfig | 13 + drivers/input/misc/Makefile | 1 + drivers/input/misc/ati_remote.c | 20 +- drivers/input/misc/ati_remote2.c | 263 +- drivers/input/misc/cm109.c | 884 ++ drivers/input/misc/sparcspkr.c | 4 +- drivers/input/misc/wistron_btns.c | 19 + drivers/input/misc/yealink.c | 3 +- drivers/input/mouse/appletouch.c | 299 +- drivers/input/mouse/logips2pp.c | 4 +- drivers/input/mouse/psmouse-base.c | 12 +- drivers/input/mouse/trackpoint.c | 8 +- drivers/input/serio/i8042-sparcio.h | 2 +- drivers/input/tablet/acecad.c | 3 +- drivers/input/tablet/aiptek.c | 79 +- drivers/input/tablet/gtco.c | 4 +- drivers/input/tablet/kbtab.c | 3 +- drivers/input/tablet/wacom_sys.c | 3 +- drivers/input/touchscreen/Kconfig | 1 + drivers/input/touchscreen/ads7846.c | 6 +- drivers/input/touchscreen/atmel_tsadcc.c | 37 +- drivers/input/touchscreen/ucb1400_ts.c | 382 +- drivers/input/xen-kbdfront.c | 4 +- drivers/isdn/capi/capi.c | 3 +- drivers/isdn/capi/capifs.c | 4 +- drivers/isdn/hardware/avm/avm_cs.c | 85 +- drivers/isdn/hisax/avma1_cs.c | 81 +- drivers/isdn/hisax/elsa_cs.c | 79 +- drivers/isdn/hisax/sedlbauer_cs.c | 197 +- drivers/isdn/hisax/teles_cs.c | 79 +- drivers/isdn/hysdn/hysdn_procconf.c | 6 +- drivers/leds/Kconfig | 8 + drivers/leds/Makefile | 1 + drivers/leds/led-class.c | 4 +- drivers/leds/leds-sunfire.c | 273 + drivers/macintosh/adb.c | 3 +- drivers/md/dm-exception-store.c | 29 +- drivers/md/dm-ioctl.c | 6 +- drivers/md/dm-mpath.c | 50 +- drivers/md/dm-mpath.h | 2 - drivers/md/dm-raid1.c | 4 +- drivers/md/dm-stripe.c | 4 +- drivers/md/dm-table.c | 21 +- drivers/md/dm.c | 40 +- drivers/md/linear.c | 8 +- drivers/md/md.c | 22 +- drivers/md/multipath.c | 8 +- drivers/md/raid0.c | 8 +- drivers/md/raid1.c | 13 +- drivers/md/raid10.c | 12 +- drivers/md/raid5.c | 75 +- drivers/media/common/ir-keymaps.c | 55 +- drivers/media/common/saa7146_core.c | 2 +- drivers/media/common/saa7146_fops.c | 2 +- drivers/media/common/saa7146_video.c | 4 +- drivers/media/common/tuners/mt2131.c | 2 +- drivers/media/common/tuners/mt2131.h | 2 +- drivers/media/common/tuners/mt2131_priv.h | 2 +- drivers/media/common/tuners/mxl5005s.c | 4 +- drivers/media/common/tuners/mxl5005s.h | 2 +- drivers/media/common/tuners/tuner-simple.c | 35 +- drivers/media/common/tuners/tuner-types.c | 22 + drivers/media/common/tuners/xc5000.c | 2 +- drivers/media/common/tuners/xc5000.h | 2 +- drivers/media/common/tuners/xc5000_priv.h | 2 +- drivers/media/dvb/b2c2/flexcop-dma.c | 2 +- drivers/media/dvb/b2c2/flexcop-i2c.c | 12 +- drivers/media/dvb/bt8xx/dvb-bt8xx.c | 2 +- drivers/media/dvb/cinergyT2/cinergyT2.c | 3 +- drivers/media/dvb/dvb-core/dmxdev.c | 1 - drivers/media/dvb/dvb-core/dvb_ca_en50221.c | 4 +- drivers/media/dvb/dvb-core/dvb_frontend.c | 8 +- drivers/media/dvb/dvb-core/dvbdev.c | 2 +- drivers/media/dvb/dvb-usb/Kconfig | 9 + drivers/media/dvb/dvb-usb/Makefile | 3 + drivers/media/dvb/dvb-usb/cxusb.c | 497 +- drivers/media/dvb/dvb-usb/dib0700_devices.c | 9 +- drivers/media/dvb/dvb-usb/dtv5100.c | 240 + drivers/media/dvb/dvb-usb/dtv5100.h | 51 + drivers/media/dvb/dvb-usb/dvb-usb-ids.h | 4 + drivers/media/dvb/frontends/Kconfig | 7 + drivers/media/dvb/frontends/Makefile | 1 + drivers/media/dvb/frontends/au8522.c | 47 +- drivers/media/dvb/frontends/au8522.h | 11 +- drivers/media/dvb/frontends/cx22702.c | 2 +- drivers/media/dvb/frontends/cx22702.h | 2 +- drivers/media/dvb/frontends/cx24123.c | 6 +- drivers/media/dvb/frontends/cx24123.h | 2 +- drivers/media/dvb/frontends/dib0070.h | 8 +- drivers/media/dvb/frontends/dib7000p.c | 3 +- drivers/media/dvb/frontends/dib7000p.h | 41 +- drivers/media/dvb/frontends/drx397xD.c | 288 +- drivers/media/dvb/frontends/drx397xD.h | 6 +- drivers/media/dvb/frontends/lgs8gl5.c | 454 + drivers/media/dvb/frontends/lgs8gl5.h | 45 + drivers/media/dvb/frontends/nxt200x.c | 4 +- drivers/media/dvb/frontends/or51211.c | 2 +- drivers/media/dvb/frontends/s5h1409.c | 3 +- drivers/media/dvb/frontends/s5h1409.h | 2 +- drivers/media/dvb/frontends/s5h1411.c | 3 +- drivers/media/dvb/frontends/s5h1411.h | 2 +- drivers/media/dvb/frontends/s5h1420.c | 3 +- drivers/media/dvb/frontends/tda10048.c | 4 +- drivers/media/dvb/frontends/tda10048.h | 2 +- drivers/media/dvb/siano/sms-cards.c | 2 +- drivers/media/dvb/siano/sms-cards.h | 2 +- drivers/media/dvb/siano/smscoreapi.c | 2 +- drivers/media/dvb/siano/smscoreapi.h | 2 +- drivers/media/dvb/siano/smsdvb.c | 2 +- drivers/media/dvb/siano/smsusb.c | 2 +- drivers/media/dvb/ttpci/Kconfig | 23 +- drivers/media/dvb/ttpci/Makefile | 9 - drivers/media/dvb/ttpci/av7110.c | 20 +- drivers/media/dvb/ttpci/av7110_hw.c | 35 +- drivers/media/dvb/ttpci/av7110_hw.h | 3 +- drivers/media/dvb/ttpci/budget-av.c | 2 +- drivers/media/dvb/ttpci/budget-ci.c | 2 +- drivers/media/dvb/ttpci/budget-patch.c | 2 +- drivers/media/dvb/ttpci/budget.c | 2 +- drivers/media/dvb/ttpci/fdump.c | 44 - drivers/media/dvb/ttusb-budget/dvb-ttusb-budget.c | 2 +- drivers/media/dvb/ttusb-dec/ttusb_dec.c | 2 +- drivers/media/radio/Makefile | 4 - drivers/media/radio/dsbr100.c | 35 +- drivers/media/radio/miropcm20-radio.c | 266 - drivers/media/radio/miropcm20-rds-core.c | 211 - drivers/media/radio/miropcm20-rds-core.h | 19 - drivers/media/radio/miropcm20-rds.c | 136 - drivers/media/radio/radio-aimslab.c | 37 +- drivers/media/radio/radio-aztech.c | 43 +- drivers/media/radio/radio-cadet.c | 3 +- drivers/media/radio/radio-gemtek-pci.c | 44 +- drivers/media/radio/radio-gemtek.c | 40 +- drivers/media/radio/radio-maestro.c | 37 +- drivers/media/radio/radio-maxiradio.c | 68 +- drivers/media/radio/radio-rtrack2.c | 37 +- drivers/media/radio/radio-sf16fmi.c | 36 +- drivers/media/radio/radio-sf16fmr2.c | 34 +- drivers/media/radio/radio-si470x.c | 28 +- drivers/media/radio/radio-terratec.c | 37 +- drivers/media/radio/radio-trust.c | 20 +- drivers/media/radio/radio-typhoon.c | 35 +- drivers/media/radio/radio-zoltrix.c | 37 +- drivers/media/video/Kconfig | 150 +- drivers/media/video/Makefile | 7 +- drivers/media/video/arv.c | 29 +- drivers/media/video/au0828/Kconfig | 1 + drivers/media/video/au0828/au0828-cards.c | 9 +- drivers/media/video/au0828/au0828-cards.h | 3 +- drivers/media/video/au0828/au0828-core.c | 4 +- drivers/media/video/au0828/au0828-dvb.c | 25 +- drivers/media/video/au0828/au0828-i2c.c | 2 +- drivers/media/video/au0828/au0828-reg.h | 2 +- drivers/media/video/au0828/au0828.h | 2 +- drivers/media/video/bt856.c | 8 +- drivers/media/video/bt8xx/bttv-cards.c | 97 +- drivers/media/video/bt8xx/bttv-driver.c | 26 +- drivers/media/video/bt8xx/bttv-input.c | 62 +- drivers/media/video/bt8xx/bttv-risc.c | 3 +- drivers/media/video/bt8xx/bttv.h | 2 +- drivers/media/video/bt8xx/bttvp.h | 5 + drivers/media/video/btcx-risc.c | 6 +- drivers/media/video/btcx-risc.h | 2 +- drivers/media/video/bw-qcam.c | 29 +- drivers/media/video/bw-qcam.h | 1 + drivers/media/video/c-qcam.c | 26 +- drivers/media/video/cafe_ccic.c | 19 +- drivers/media/video/cpia.c | 21 +- drivers/media/video/cpia2/cpia2_v4l.c | 20 +- drivers/media/video/cx18/cx18-av-firmware.c | 16 +- drivers/media/video/cx18/cx18-driver.c | 10 +- drivers/media/video/cx18/cx18-driver.h | 6 +- drivers/media/video/cx18/cx18-dvb.c | 2 +- drivers/media/video/cx18/cx18-dvb.h | 2 +- drivers/media/video/cx18/cx18-fileops.c | 47 +- drivers/media/video/cx18/cx18-ioctl.c | 20 +- drivers/media/video/cx18/cx18-irq.c | 2 +- drivers/media/video/cx18/cx18-mailbox.c | 1 + drivers/media/video/cx18/cx18-queue.c | 135 +- drivers/media/video/cx18/cx18-queue.h | 2 +- drivers/media/video/cx18/cx18-streams.c | 19 +- drivers/media/video/cx18/cx23418.h | 2 +- drivers/media/video/cx2341x.c | 5 +- drivers/media/video/cx23885/Kconfig | 1 + drivers/media/video/cx23885/cx23885-417.c | 12 +- drivers/media/video/cx23885/cx23885-cards.c | 86 +- drivers/media/video/cx23885/cx23885-core.c | 6 +- drivers/media/video/cx23885/cx23885-dvb.c | 104 +- drivers/media/video/cx23885/cx23885-i2c.c | 2 +- drivers/media/video/cx23885/cx23885-reg.h | 2 +- drivers/media/video/cx23885/cx23885-vbi.c | 2 +- drivers/media/video/cx23885/cx23885-video.c | 14 +- drivers/media/video/cx23885/cx23885.h | 4 +- drivers/media/video/cx25840/cx25840-core.c | 2 +- drivers/media/video/cx88/cx88-blackbird.c | 8 +- drivers/media/video/cx88/cx88-video.c | 10 +- drivers/media/video/dabusb.c | 7 +- drivers/media/video/dpc7146.c | 408 - drivers/media/video/em28xx/em28xx-video.c | 7 +- drivers/media/video/et61x251/et61x251_core.c | 14 +- drivers/media/video/gspca/conex.c | 24 +- drivers/media/video/gspca/etoms.c | 30 +- drivers/media/video/gspca/gspca.c | 119 +- drivers/media/video/gspca/gspca.h | 21 +- drivers/media/video/gspca/mars.c | 41 +- drivers/media/video/gspca/ov519.c | 1167 ++-- drivers/media/video/gspca/pac207.c | 87 +- drivers/media/video/gspca/pac7311.c | 1110 ++- drivers/media/video/gspca/pac_common.h | 60 + drivers/media/video/gspca/sonixb.c | 512 +- drivers/media/video/gspca/sonixj.c | 539 +- drivers/media/video/gspca/spca500.c | 20 +- drivers/media/video/gspca/spca501.c | 16 +- drivers/media/video/gspca/spca505.c | 16 +- drivers/media/video/gspca/spca506.c | 20 +- drivers/media/video/gspca/spca508.c | 21 +- drivers/media/video/gspca/spca561.c | 667 +- drivers/media/video/gspca/stk014.c | 20 +- drivers/media/video/gspca/sunplus.c | 167 +- drivers/media/video/gspca/t613.c | 41 +- drivers/media/video/gspca/tv8532.c | 20 +- drivers/media/video/gspca/vc032x.c | 31 +- drivers/media/video/gspca/zc3xx.c | 85 +- drivers/media/video/ivtv/ivtv-driver.c | 6 +- drivers/media/video/ivtv/ivtv-driver.h | 1 + drivers/media/video/ivtv/ivtv-fileops.c | 2 +- drivers/media/video/ivtv/ivtv-fileops.h | 5 - drivers/media/video/ivtv/ivtv-irq.c | 29 +- drivers/media/video/ivtv/ivtv-queue.h | 2 +- drivers/media/video/ivtv/ivtv-streams.c | 2 +- drivers/media/video/ivtv/ivtv-vbi.c | 4 +- drivers/media/video/ivtv/ivtv-version.h | 2 +- drivers/media/video/ks0127.c | 31 +- drivers/media/video/meye.c | 15 +- drivers/media/video/meye.h | 1 + drivers/media/video/mt9m001.c | 55 +- drivers/media/video/mt9m111.c | 973 ++ drivers/media/video/mt9v022.c | 52 +- drivers/media/video/mxb.c | 25 +- drivers/media/video/ov511.c | 138 +- drivers/media/video/ov511.h | 3 +- drivers/media/video/pms.c | 36 +- drivers/media/video/pvrusb2/pvrusb2-hdw.c | 3 +- drivers/media/video/pvrusb2/pvrusb2-main.c | 8 +- drivers/media/video/pvrusb2/pvrusb2-v4l2.c | 6 + drivers/media/video/pwc/pwc-ctrl.c | 18 +- drivers/media/video/pwc/pwc-if.c | 12 +- drivers/media/video/pwc/pwc-v4l.c | 2 +- drivers/media/video/pxa_camera.c | 24 - drivers/media/video/s2255drv.c | 572 +- drivers/media/video/saa5246a.c | 44 +- drivers/media/video/saa5249.c | 56 +- drivers/media/video/saa7115.c | 5 +- drivers/media/video/saa7134/saa6752hs.c | 335 +- drivers/media/video/saa7134/saa7134-alsa.c | 13 +- drivers/media/video/saa7134/saa7134-core.c | 58 +- drivers/media/video/saa7134/saa7134-empress.c | 40 +- drivers/media/video/saa7134/saa7134-input.c | 140 +- drivers/media/video/saa7134/saa7134-ts.c | 56 +- drivers/media/video/saa7134/saa7134-video.c | 8 +- drivers/media/video/saa7134/saa7134.h | 8 + drivers/media/video/se401.c | 46 +- drivers/media/video/sh_mobile_ceu_camera.c | 5 - drivers/media/video/sn9c102/sn9c102_core.c | 14 +- drivers/media/video/sn9c102/sn9c102_devtable.h | 13 +- drivers/media/video/stk-webcam.c | 10 +- drivers/media/video/stradis.c | 7 +- drivers/media/video/stv680.c | 10 +- drivers/media/video/tda9840.c | 166 +- drivers/media/video/tea6415c.c | 131 +- drivers/media/video/tea6420.c | 147 +- drivers/media/video/tuner-3036.c | 214 - drivers/media/video/usbvideo/ibmcam.c | 84 +- drivers/media/video/usbvideo/konicawc.c | 25 +- drivers/media/video/usbvideo/quickcam_messenger.c | 17 +- drivers/media/video/usbvideo/ultracam.c | 29 +- drivers/media/video/usbvideo/usbvideo.c | 166 +- drivers/media/video/usbvideo/vicam.c | 19 +- drivers/media/video/usbvision/usbvision-core.c | 7 +- drivers/media/video/usbvision/usbvision-i2c.c | 3 +- drivers/media/video/usbvision/usbvision-video.c | 131 +- drivers/media/video/uvc/uvc_driver.c | 24 +- drivers/media/video/uvc/uvc_v4l2.c | 13 +- drivers/media/video/uvc/uvc_video.c | 7 +- drivers/media/video/v4l1-compat.c | 4 - drivers/media/video/v4l2-common.c | 187 +- drivers/media/video/v4l2-dev.c | 208 +- drivers/media/video/v4l2-ioctl.c | 4 +- drivers/media/video/vino.c | 30 +- drivers/media/video/vivi.c | 59 +- drivers/media/video/w9966.c | 31 +- drivers/media/video/w9968cf.c | 4 +- drivers/media/video/wm8739.c | 4 +- drivers/media/video/zc0301/zc0301_core.c | 14 +- drivers/media/video/zc0301/zc0301_sensor.h | 19 - drivers/media/video/zoran_device.c | 4 +- drivers/media/video/zoran_driver.c | 3 + drivers/media/video/zr364xx.c | 87 +- drivers/memstick/core/mspro_block.c | 2 +- drivers/message/i2o/i2o_block.c | 2 +- drivers/mfd/Kconfig | 9 + drivers/mfd/Makefile | 1 + drivers/mfd/asic3.c | 4 +- drivers/mfd/htc-egpio.c | 2 +- drivers/mfd/mfd-core.c | 15 +- drivers/mfd/sm501.c | 6 +- drivers/mfd/ucb1400_core.c | 106 + drivers/misc/Makefile | 1 - drivers/misc/acer-wmi.c | 25 +- drivers/misc/asus-laptop.c | 10 +- drivers/misc/compal-laptop.c | 12 +- drivers/misc/eeepc-laptop.c | 12 +- drivers/misc/fujitsu-laptop.c | 26 +- drivers/misc/ibmasm/event.c | 2 +- drivers/misc/lkdtm.c | 345 - drivers/misc/msi-laptop.c | 16 +- drivers/misc/phantom.c | 6 +- drivers/misc/sony-laptop.c | 6 +- drivers/misc/thinkpad_acpi.c | 29 +- drivers/mmc/card/block.c | 48 +- drivers/mmc/card/queue.c | 23 +- drivers/mmc/core/sdio_io.c | 249 + drivers/mmc/core/sdio_irq.c | 16 +- drivers/mmc/core/sdio_ops.c | 10 +- drivers/mmc/host/omap.c | 2 +- drivers/mmc/host/sdhci-pci.c | 5 +- drivers/mmc/host/sdhci.c | 44 +- drivers/mmc/host/sdhci.h | 2 + drivers/mtd/Kconfig | 5 + drivers/mtd/chips/Kconfig | 4 +- drivers/mtd/chips/cfi_cmdset_0001.c | 54 +- drivers/mtd/chips/cfi_probe.c | 58 +- drivers/mtd/chips/cfi_util.c | 66 +- drivers/mtd/chips/gen_probe.c | 2 +- drivers/mtd/devices/Kconfig | 21 + drivers/mtd/devices/m25p80.c | 136 +- drivers/mtd/devices/mtd_dataflash.c | 214 +- drivers/mtd/ftl.c | 24 + drivers/mtd/maps/Kconfig | 31 - drivers/mtd/maps/Makefile | 4 - drivers/mtd/maps/ebony.c | 163 - drivers/mtd/maps/ocotea.c | 154 - drivers/mtd/maps/omap-toto-flash.c | 133 - drivers/mtd/maps/pcmciamtd.c | 29 +- drivers/mtd/maps/sun_uflash.c | 75 +- drivers/mtd/maps/walnut.c | 122 - drivers/mtd/mtd_blkdevs.c | 16 + drivers/mtd/mtdchar.c | 14 +- drivers/mtd/mtdconcat.c | 4 +- drivers/mtd/mtdpart.c | 6 +- drivers/mtd/nand/Kconfig | 20 +- drivers/mtd/nand/Makefile | 2 +- drivers/mtd/nand/alauda.c | 4 +- drivers/mtd/nand/cafe_nand.c | 6 +- drivers/mtd/nand/mxc_nand.c | 1077 +++ drivers/mtd/nand/nand_base.c | 8 +- drivers/mtd/nand/nand_ecc.c | 554 +- drivers/mtd/nand/nandsim.c | 1 - drivers/mtd/nand/pxa3xx_nand.c | 147 +- drivers/mtd/nand/toto.c | 206 - drivers/mtd/onenand/Kconfig | 8 + drivers/mtd/onenand/Makefile | 1 + drivers/mtd/onenand/omap2.c | 782 ++ drivers/mtd/onenand/onenand_base.c | 2 +- drivers/mtd/ssfdc.c | 3 +- drivers/mtd/ubi/cdev.c | 6 +- drivers/net/3c59x.c | 4 +- drivers/net/8139cp.c | 14 +- drivers/net/8139too.c | 4 +- drivers/net/Makefile | 2 +- drivers/net/acenic.c | 117 +- drivers/net/acenic.h | 4 + drivers/net/acenic_firmware.h | 9456 -------------------- drivers/net/bonding/bond_alb.c | 4 +- drivers/net/bonding/bond_main.c | 27 +- drivers/net/bonding/bond_sysfs.c | 15 +- drivers/net/e100.c | 283 +- drivers/net/e1000e/82571.c | 153 +- drivers/net/e1000e/defines.h | 15 + drivers/net/e1000e/e1000.h | 31 +- drivers/net/e1000e/es2lan.c | 2 +- drivers/net/e1000e/ethtool.c | 60 +- drivers/net/e1000e/hw.h | 15 +- drivers/net/e1000e/ich8lan.c | 173 +- drivers/net/e1000e/lib.c | 7 +- drivers/net/e1000e/netdev.c | 435 +- drivers/net/e1000e/param.c | 27 + drivers/net/e1000e/phy.c | 194 +- drivers/net/hamradio/baycom_ser_fdx.c | 4 +- drivers/net/hamradio/scc.c | 6 +- drivers/net/ibm_newemac/mal.h | 4 +- drivers/net/igb/igb_main.c | 12 +- drivers/net/irda/kingsun-sir.c | 3 +- drivers/net/irda/ks959-sir.c | 3 +- drivers/net/irda/ksdazzle-sir.c | 3 +- drivers/net/irda/sir_dongle.c | 2 - drivers/net/irda/stir4200.c | 18 +- drivers/net/ixgbe/ixgbe.h | 43 +- drivers/net/ixgbe/ixgbe_82598.c | 6 +- drivers/net/ixgbe/ixgbe_common.c | 140 +- drivers/net/ixgbe/ixgbe_common.h | 4 +- drivers/net/ixgbe/ixgbe_ethtool.c | 6 +- drivers/net/ixgbe/ixgbe_main.c | 721 +- drivers/net/ixgbe/ixgbe_type.h | 47 +- drivers/net/mlx4/mr.c | 8 +- drivers/net/myri_sbus.c | 196 +- drivers/net/myri_sbus.h | 2 +- drivers/net/niu.c | 2 +- drivers/net/pcmcia/3c574_cs.c | 7 +- drivers/net/pcmcia/3c589_cs.c | 7 +- drivers/net/pcmcia/axnet_cs.c | 80 +- drivers/net/pcmcia/com20020_cs.c | 8 +- drivers/net/pcmcia/fmvj18x_cs.c | 19 +- drivers/net/pcmcia/ibmtr_cs.c | 2 +- drivers/net/pcmcia/pcnet_cs.c | 86 +- drivers/net/pcmcia/smc91c92_cs.c | 147 +- drivers/net/pcmcia/xirc2ps_cs.c | 75 +- drivers/net/phy/phy_device.c | 8 +- drivers/net/ppp_async.c | 8 +- drivers/net/ppp_generic.c | 14 +- drivers/net/pppox.c | 9 +- drivers/net/ps3_gelic_net.c | 1 + drivers/net/ps3_gelic_wireless.c | 1 + drivers/net/r8169.c | 401 +- drivers/net/s2io.c | 4 +- drivers/net/sfc/bitfield.h | 178 +- drivers/net/sfc/boards.c | 12 +- drivers/net/sfc/boards.h | 2 - drivers/net/sfc/efx.c | 471 +- drivers/net/sfc/efx.h | 14 +- drivers/net/sfc/enum.h | 9 +- drivers/net/sfc/ethtool.c | 184 +- drivers/net/sfc/falcon.c | 767 ++- drivers/net/sfc/falcon.h | 16 +- drivers/net/sfc/falcon_hwdefs.h | 79 +- drivers/net/sfc/falcon_xmac.c | 330 +- drivers/net/sfc/mac.h | 4 - drivers/net/sfc/mdio_10g.c | 16 +- drivers/net/sfc/mdio_10g.h | 13 +- drivers/net/sfc/net_driver.h | 136 +- drivers/net/sfc/phy.h | 10 +- drivers/net/sfc/rx.c | 78 +- drivers/net/sfc/rx.h | 4 +- drivers/net/sfc/selftest.c | 391 +- drivers/net/sfc/selftest.h | 13 +- drivers/net/sfc/sfe4001.c | 244 +- drivers/net/sfc/spi.h | 89 +- drivers/net/sfc/tenxpress.c | 90 +- drivers/net/sfc/tx.c | 383 +- drivers/net/sfc/tx.h | 2 +- drivers/net/sfc/workarounds.h | 2 - drivers/net/sfc/xfp_phy.c | 11 +- drivers/net/sky2.c | 170 +- drivers/net/spider_net.c | 2 +- drivers/net/starfire.c | 51 +- drivers/net/starfire_firmware.h | 346 - drivers/net/starfire_firmware.pl | 31 - drivers/net/sunbmac.c | 204 +- drivers/net/sunbmac.h | 4 +- drivers/net/sunhme.c | 322 +- drivers/net/sunhme.h | 7 +- drivers/net/sunlance.c | 180 +- drivers/net/sunqe.c | 162 +- drivers/net/sunqe.h | 4 +- drivers/net/sunvnet.c | 4 +- drivers/net/tg3.c | 789 +-- drivers/net/tg3.h | 4 + drivers/net/tun.c | 8 +- drivers/net/usb/catc.c | 8 +- drivers/net/usb/hso.c | 26 +- drivers/net/usb/kaweth.c | 27 +- drivers/net/usb/rtl8150.c | 31 +- drivers/net/via-rhine.c | 8 +- drivers/net/wan/Makefile | 2 +- drivers/net/wan/c101.c | 6 +- drivers/net/wan/cosa.c | 4 +- drivers/net/wan/hd64570.c | 724 ++ drivers/net/wan/hd64572.c | 641 ++ drivers/net/wan/hd6457x.c | 868 -- drivers/net/wan/hdlc_ppp.c | 648 ++- drivers/net/wan/n2.c | 9 +- drivers/net/wan/pc300too.c | 73 +- drivers/net/wan/pci200syn.c | 77 +- drivers/net/wan/sbni.c | 2 +- drivers/net/wan/syncppp.c | 1479 --- drivers/net/wireless/Kconfig | 17 +- drivers/net/wireless/Makefile | 4 +- drivers/net/wireless/airo.c | 16 +- drivers/net/wireless/airo_cs.c | 222 +- drivers/net/wireless/airport.c | 3 +- drivers/net/wireless/ath5k/ath5k.h | 162 +- drivers/net/wireless/ath5k/base.c | 383 +- drivers/net/wireless/ath5k/base.h | 8 +- drivers/net/wireless/ath5k/hw.c | 77 +- drivers/net/wireless/ath9k/ath9k.h | 55 +- drivers/net/wireless/ath9k/beacon.c | 259 +- drivers/net/wireless/ath9k/core.c | 306 +- drivers/net/wireless/ath9k/core.h | 248 +- drivers/net/wireless/ath9k/hw.c | 150 +- drivers/net/wireless/ath9k/hw.h | 120 +- drivers/net/wireless/ath9k/main.c | 244 +- drivers/net/wireless/ath9k/phy.h | 12 +- drivers/net/wireless/ath9k/rc.c | 183 +- drivers/net/wireless/ath9k/rc.h | 222 +- drivers/net/wireless/ath9k/recv.c | 81 +- drivers/net/wireless/ath9k/reg.h | 6 - drivers/net/wireless/ath9k/xmit.c | 400 +- drivers/net/wireless/atmel_cs.c | 119 +- drivers/net/wireless/b43/Makefile | 4 +- drivers/net/wireless/b43/b43.h | 137 +- drivers/net/wireless/b43/debugfs.c | 79 +- drivers/net/wireless/b43/lo.c | 120 +- drivers/net/wireless/b43/lo.h | 4 +- drivers/net/wireless/b43/main.c | 184 +- drivers/net/wireless/b43/nphy.c | 148 +- drivers/net/wireless/b43/nphy.h | 54 +- drivers/net/wireless/b43/pcmcia.c | 14 +- drivers/net/wireless/b43/phy.c | 3421 +------- drivers/net/wireless/b43/phy.h | 340 - drivers/net/wireless/b43/phy_a.c | 543 ++ drivers/net/wireless/b43/phy_a.h | 124 + drivers/net/wireless/b43/phy_common.c | 367 + drivers/net/wireless/b43/phy_common.h | 381 + drivers/net/wireless/b43/phy_g.c | 3251 +++++++ drivers/net/wireless/b43/phy_g.h | 209 + drivers/net/wireless/b43/rfkill.c | 5 +- drivers/net/wireless/b43/sysfs.c | 23 +- drivers/net/wireless/b43/tables.c | 43 +- drivers/net/wireless/b43/tables_nphy.c | 2 +- drivers/net/wireless/b43/wa.c | 2 +- drivers/net/wireless/b43/xmit.c | 8 +- drivers/net/wireless/b43legacy/xmit.c | 4 +- drivers/net/wireless/hermes.c | 124 +- drivers/net/wireless/hermes.h | 45 + drivers/net/wireless/hermes_dld.c | 730 ++ drivers/net/wireless/hermes_dld.h | 48 + drivers/net/wireless/hermes_rid.h | 17 + drivers/net/wireless/hostap/hostap_cs.c | 235 +- drivers/net/wireless/ipw2100.c | 2 +- drivers/net/wireless/ipw2200.h | 4 +- drivers/net/wireless/iwlwifi/iwl-3945-debug.h | 4 +- drivers/net/wireless/iwlwifi/iwl-3945.c | 104 +- drivers/net/wireless/iwlwifi/iwl-3945.h | 1 - drivers/net/wireless/iwlwifi/iwl-agn.c | 2 - drivers/net/wireless/iwlwifi/iwl-core.c | 1 - drivers/net/wireless/iwlwifi/iwl-debug.h | 12 +- drivers/net/wireless/iwlwifi/iwl-dev.h | 16 - drivers/net/wireless/iwlwifi/iwl-hcmd.c | 14 +- drivers/net/wireless/iwlwifi/iwl-rx.c | 125 +- drivers/net/wireless/iwlwifi/iwl-tx.c | 32 +- drivers/net/wireless/iwlwifi/iwl3945-base.c | 8 +- drivers/net/wireless/libertas/assoc.c | 744 +- drivers/net/wireless/libertas/assoc.h | 18 +- drivers/net/wireless/libertas/cmd.c | 168 +- drivers/net/wireless/libertas/cmd.h | 6 + drivers/net/wireless/libertas/cmdresp.c | 33 - drivers/net/wireless/libertas/decl.h | 1 - drivers/net/wireless/libertas/defs.h | 6 +- drivers/net/wireless/libertas/dev.h | 7 +- drivers/net/wireless/libertas/host.h | 26 +- drivers/net/wireless/libertas/hostcmd.h | 50 +- drivers/net/wireless/libertas/if_cs.c | 2 +- drivers/net/wireless/libertas/if_usb.c | 177 +- drivers/net/wireless/libertas/if_usb.h | 5 + drivers/net/wireless/libertas/main.c | 21 +- drivers/net/wireless/libertas/scan.c | 5 + drivers/net/wireless/libertas/wext.c | 148 +- drivers/net/wireless/libertas_tf/Makefile | 6 + drivers/net/wireless/libertas_tf/cmd.c | 669 ++ drivers/net/wireless/libertas_tf/if_usb.c | 766 ++ drivers/net/wireless/libertas_tf/if_usb.h | 98 + drivers/net/wireless/libertas_tf/libertas_tf.h | 514 ++ drivers/net/wireless/libertas_tf/main.c | 662 ++ drivers/net/wireless/mac80211_hwsim.c | 22 +- drivers/net/wireless/netwave_cs.c | 5 +- drivers/net/wireless/orinoco.c | 1949 ++++- drivers/net/wireless/orinoco.h | 61 +- drivers/net/wireless/orinoco_cs.c | 166 +- drivers/net/wireless/orinoco_nortel.c | 3 +- drivers/net/wireless/orinoco_pci.c | 3 +- drivers/net/wireless/orinoco_plx.c | 3 +- drivers/net/wireless/orinoco_tmd.c | 3 +- drivers/net/wireless/p54/p54.h | 8 +- drivers/net/wireless/p54/p54common.c | 170 +- drivers/net/wireless/p54/p54common.h | 29 +- drivers/net/wireless/p54/p54pci.c | 276 +- drivers/net/wireless/p54/p54pci.h | 20 +- drivers/net/wireless/p54/p54usb.c | 32 +- drivers/net/wireless/p54/p54usb.h | 6 +- drivers/net/wireless/prism54/isl_ioctl.c | 8 +- drivers/net/wireless/ray_cs.c | 4 +- drivers/net/wireless/rt2x00/Kconfig | 6 + drivers/net/wireless/rt2x00/Makefile | 1 + drivers/net/wireless/rt2x00/rt2400pci.c | 42 +- drivers/net/wireless/rt2x00/rt2400pci.h | 22 +- drivers/net/wireless/rt2x00/rt2500pci.c | 43 +- drivers/net/wireless/rt2x00/rt2500pci.h | 17 +- drivers/net/wireless/rt2x00/rt2500usb.c | 46 +- drivers/net/wireless/rt2x00/rt2500usb.h | 17 +- drivers/net/wireless/rt2x00/rt2x00.h | 88 +- drivers/net/wireless/rt2x00/rt2x00config.c | 8 +- drivers/net/wireless/rt2x00/rt2x00crypto.c | 215 + drivers/net/wireless/rt2x00/rt2x00debug.c | 97 + drivers/net/wireless/rt2x00/rt2x00dev.c | 116 +- drivers/net/wireless/rt2x00/rt2x00lib.h | 47 + drivers/net/wireless/rt2x00/rt2x00mac.c | 226 +- drivers/net/wireless/rt2x00/rt2x00queue.c | 112 +- drivers/net/wireless/rt2x00/rt2x00queue.h | 82 +- drivers/net/wireless/rt2x00/rt2x00reg.h | 19 +- drivers/net/wireless/rt2x00/rt2x00rfkill.c | 6 +- drivers/net/wireless/rt2x00/rt2x00usb.c | 21 +- drivers/net/wireless/rt2x00/rt61pci.c | 427 +- drivers/net/wireless/rt2x00/rt61pci.h | 38 +- drivers/net/wireless/rt2x00/rt73usb.c | 437 +- drivers/net/wireless/rt2x00/rt73usb.h | 38 +- drivers/net/wireless/rtl8180.h | 31 - drivers/net/wireless/rtl8180_dev.c | 34 +- drivers/net/wireless/rtl8187.h | 6 - drivers/net/wireless/rtl8187_dev.c | 10 +- drivers/net/wireless/rtl818x.h | 35 + drivers/net/wireless/spectrum_cs.c | 588 +-- drivers/net/wireless/wavelan_cs.c | 16 +- drivers/net/wireless/wl3501_cs.c | 12 +- drivers/net/xen-netfront.c | 6 +- drivers/oprofile/buffer_sync.c | 209 +- drivers/oprofile/cpu_buffer.c | 74 +- drivers/oprofile/cpu_buffer.h | 2 + drivers/oprofile/oprof.c | 58 +- drivers/oprofile/oprof.h | 4 +- drivers/oprofile/oprofile_files.c | 39 +- drivers/parisc/ccio-dma.c | 43 +- drivers/parisc/dino.c | 6 +- drivers/parisc/eisa.c | 4 +- drivers/parisc/gsc.c | 12 +- drivers/parisc/iosapic.c | 4 +- drivers/parisc/superio.c | 4 +- drivers/parport/parport_cs.c | 70 +- drivers/parport/parport_sunbpp.c | 49 +- drivers/pci/Makefile | 2 + drivers/pci/dma_remapping.h | 157 + drivers/pci/dmar.c | 397 +- drivers/pci/hotplug/ibmphp_ebda.c | 92 +- drivers/pci/hotplug/ibmphp_hpc.c | 30 +- drivers/pci/hotplug/pciehp.h | 1 + drivers/pci/hotplug/pciehp_hpc.c | 5 +- drivers/pci/hotplug/rpaphp_slot.c | 4 - drivers/pci/htirq.c | 22 +- drivers/pci/intel-iommu.c | 164 +- drivers/pci/intel-iommu.h | 233 +- drivers/pci/intr_remapping.c | 594 ++ drivers/pci/intr_remapping.h | 8 + drivers/pci/pci-driver.c | 21 +- drivers/pci/pci.c | 50 +- drivers/pci/pcie/portdrv_pci.c | 2 +- drivers/pci/probe.c | 63 +- drivers/pci/quirks.c | 177 +- drivers/pci/search.c | 6 +- drivers/pci/setup-bus.c | 6 +- drivers/pcmcia/Makefile | 7 +- drivers/pcmcia/at91_cf.c | 2 +- drivers/pcmcia/au1000_generic.c | 2 +- drivers/pcmcia/au1000_generic.h | 2 +- drivers/pcmcia/au1000_pb1x00.c | 1 - drivers/pcmcia/au1000_xxs1500.c | 1 - drivers/pcmcia/cardbus.c | 2 +- drivers/pcmcia/cistpl.c | 291 +- drivers/pcmcia/cs.c | 74 +- drivers/pcmcia/cs_internal.h | 214 +- drivers/pcmcia/ds.c | 239 +- drivers/pcmcia/ds_internal.h | 23 - drivers/pcmcia/hd64465_ss.c | 13 +- drivers/pcmcia/i82365.c | 2 +- drivers/pcmcia/m32r_cfc.c | 4 +- drivers/pcmcia/m32r_pcc.c | 4 +- drivers/pcmcia/m8xx_pcmcia.c | 4 +- drivers/pcmcia/o2micro.h | 10 +- drivers/pcmcia/pcmcia_ioctl.c | 116 +- drivers/pcmcia/pcmcia_resource.c | 381 +- drivers/pcmcia/pxa2xx_base.c | 1 - drivers/pcmcia/pxa2xx_palmld.c | 151 + drivers/pcmcia/rsrc_nonstatic.c | 67 +- drivers/pcmcia/soc_common.c | 2 +- drivers/pcmcia/soc_common.h | 3 +- drivers/pcmcia/socket_sysfs.c | 13 +- drivers/pcmcia/tcic.c | 2 +- drivers/pcmcia/ti113x.h | 78 +- drivers/pcmcia/vrc4171_card.c | 2 +- drivers/pcmcia/yenta_socket.c | 86 +- drivers/pnp/Kconfig | 20 +- drivers/pnp/Makefile | 4 - drivers/pnp/base.h | 10 + drivers/pnp/core.c | 29 +- drivers/pnp/driver.c | 4 - drivers/pnp/isapnp/Makefile | 4 - drivers/pnp/isapnp/core.c | 12 +- drivers/pnp/manager.c | 34 +- drivers/pnp/pnpacpi/Makefile | 4 - drivers/pnp/pnpacpi/core.c | 16 +- drivers/pnp/pnpacpi/rsparser.c | 45 +- drivers/pnp/pnpbios/Makefile | 4 - drivers/pnp/pnpbios/core.c | 4 +- drivers/pnp/pnpbios/rsparser.c | 18 +- drivers/pnp/quirks.c | 6 +- drivers/pnp/resource.c | 12 +- drivers/pnp/support.c | 14 +- drivers/power/Kconfig | 6 + drivers/power/Makefile | 1 + drivers/power/bq27x00_battery.c | 382 + drivers/power/pda_power.c | 11 +- drivers/power/power_supply_core.c | 29 +- drivers/rtc/Kconfig | 32 +- drivers/rtc/Makefile | 3 + drivers/rtc/rtc-bq4802.c | 229 + drivers/rtc/rtc-cmos.c | 5 +- drivers/rtc/rtc-m48t59.c | 63 +- drivers/rtc/rtc-starfire.c | 120 + drivers/rtc/rtc-sun4v.c | 153 + drivers/rtc/rtc-vr41xx.c | 4 +- drivers/s390/block/dasd_proc.c | 3 +- drivers/s390/block/dcssblk.c | 520 +- drivers/s390/char/raw3270.c | 14 +- drivers/s390/char/tape_class.c | 6 +- drivers/s390/char/vmlogrdr.c | 8 +- drivers/s390/char/vmur.c | 5 +- drivers/s390/cio/blacklist.c | 11 +- drivers/s390/cio/chp.c | 7 +- drivers/s390/cio/css.c | 32 +- drivers/s390/cio/device.c | 96 +- drivers/s390/cio/device.h | 1 + drivers/s390/cio/device_fsm.c | 7 + drivers/s390/cio/qdio.h | 3 + drivers/s390/cio/qdio_main.c | 24 +- drivers/s390/scsi/zfcp_ccw.c | 6 +- drivers/s390/scsi/zfcp_fc.c | 33 +- drivers/s390/scsi/zfcp_fsf.c | 88 +- drivers/s390/scsi/zfcp_qdio.c | 4 +- drivers/sbus/Makefile | 4 - drivers/sbus/char/Kconfig | 29 +- drivers/sbus/char/Makefile | 6 - drivers/sbus/char/bbc_envctrl.c | 121 +- drivers/sbus/char/bbc_i2c.c | 267 +- drivers/sbus/char/bbc_i2c.h | 75 +- drivers/sbus/char/bpp.c | 1055 --- drivers/sbus/char/cpwatchdog.c | 858 -- drivers/sbus/char/display7seg.c | 251 +- drivers/sbus/char/envctrl.c | 147 +- drivers/sbus/char/flash.c | 130 +- drivers/sbus/char/riowatchdog.c | 295 - drivers/sbus/char/rtc.c | 275 - drivers/sbus/char/uctrl.c | 216 +- drivers/sbus/char/vfc.h | 171 - drivers/sbus/char/vfc_dev.c | 736 -- drivers/sbus/char/vfc_i2c.c | 335 - drivers/sbus/char/vfc_i2c.h | 44 - drivers/sbus/dvma.c | 136 - drivers/sbus/sbus.c | 316 - drivers/scsi/Kconfig | 2 +- drivers/scsi/aacraid/aachba.c | 2 +- drivers/scsi/advansys.c | 1731 +---- drivers/scsi/aha152x.c | 2 +- drivers/scsi/ch.c | 6 +- drivers/scsi/device_handler/scsi_dh_alua.c | 12 +- drivers/scsi/device_handler/scsi_dh_emc.c | 4 +- drivers/scsi/device_handler/scsi_dh_rdac.c | 4 +- drivers/scsi/dpt_i2o.c | 2 +- drivers/scsi/esp_scsi.h | 3 +- drivers/scsi/gdth.c | 60 +- drivers/scsi/gdth.h | 2 +- drivers/scsi/gdth_proc.c | 66 - drivers/scsi/gdth_proc.h | 3 - drivers/scsi/hosts.c | 2 +- drivers/scsi/ibmvscsi/ibmvscsi.c | 2 +- drivers/scsi/ide-scsi.c | 220 +- drivers/scsi/ipr.c | 4 +- drivers/scsi/ips.c | 2 +- drivers/scsi/libiscsi.c | 17 +- drivers/scsi/libsas/sas_ata.c | 2 +- drivers/scsi/libsas/sas_internal.h | 2 +- drivers/scsi/libsas/sas_scsi_host.c | 30 +- drivers/scsi/megaraid/megaraid_sas.c | 6 +- drivers/scsi/ncr53c8xx.c | 4 +- drivers/scsi/osst.c | 3 +- drivers/scsi/pcmcia/aha152x_stub.c | 58 +- drivers/scsi/pcmcia/fdomain_stub.c | 37 +- drivers/scsi/pcmcia/nsp_cs.c | 194 +- drivers/scsi/pcmcia/qlogic_stub.c | 47 +- drivers/scsi/pcmcia/sym53c500_cs.c | 46 +- drivers/scsi/ql1040_fw.h | 2130 ----- drivers/scsi/ql12160_fw.h | 1811 ---- drivers/scsi/ql1280_fw.h | 2048 ----- drivers/scsi/qla1280.c | 118 +- drivers/scsi/qla1280.h | 6 + drivers/scsi/qla2xxx/qla_def.h | 3 +- drivers/scsi/qla4xxx/ql4_os.c | 4 +- drivers/scsi/qlogicpti.c | 209 +- drivers/scsi/qlogicpti.h | 2 +- drivers/scsi/qlogicpti_asm.c | 1160 --- drivers/scsi/scsi.c | 94 +- drivers/scsi/scsi_error.c | 92 +- drivers/scsi/scsi_lib.c | 40 +- drivers/scsi/scsi_priv.h | 8 +- drivers/scsi/scsi_proc.c | 8 +- drivers/scsi/scsi_scan.c | 3 +- drivers/scsi/scsi_sysfs.c | 7 +- drivers/scsi/scsi_tgt_lib.c | 8 +- drivers/scsi/scsi_transport_fc.c | 6 +- drivers/scsi/scsi_transport_iscsi.c | 4 +- drivers/scsi/sd.c | 91 +- drivers/scsi/sg.c | 604 +- drivers/scsi/sr.c | 7 +- drivers/scsi/st.c | 11 +- drivers/scsi/sun_esp.c | 267 +- drivers/scsi/sym53c8xx_2/sym_glue.c | 4 +- drivers/scsi/tmscsim.c | 4 +- drivers/serial/8250.c | 25 +- drivers/serial/Kconfig | 36 - drivers/serial/amba-pl010.c | 2 +- drivers/serial/amba-pl011.c | 2 +- drivers/serial/cpm_uart/cpm_uart_core.c | 2 +- drivers/serial/m32r_sio.c | 4 +- drivers/serial/mpc52xx_uart.c | 4 +- drivers/serial/serial_core.c | 2 +- drivers/serial/serial_cs.c | 300 +- drivers/serial/serial_lh7a40x.c | 2 +- drivers/serial/serial_txx9.c | 113 +- drivers/serial/sh-sci.c | 2 +- drivers/serial/sunhv.c | 2 +- drivers/serial/sunsab.c | 2 +- drivers/serial/sunsu.c | 2 +- drivers/serial/sunzilog.c | 2 +- drivers/serial/ucc_uart.c | 2 +- drivers/spi/omap2_mcspi.c | 8 +- drivers/spi/omap_uwire.c | 2 +- drivers/spi/spidev.c | 7 +- drivers/ssb/pci.c | 84 +- drivers/ssb/pcmcia.c | 22 +- drivers/telephony/ixj_pcmcia.c | 72 +- drivers/uio/uio.c | 20 +- drivers/usb/atm/usbatm.c | 10 +- drivers/usb/atm/usbatm.h | 10 +- drivers/usb/atm/xusbatm.c | 2 +- drivers/usb/class/Kconfig | 10 + drivers/usb/class/Makefile | 1 + drivers/usb/class/cdc-acm.c | 3 +- drivers/usb/class/usblp.c | 18 +- drivers/usb/class/usbtmc.c | 1087 +++ drivers/usb/core/devio.c | 19 +- drivers/usb/core/file.c | 6 +- drivers/usb/core/hcd.c | 8 +- drivers/usb/core/inode.c | 10 +- drivers/usb/core/message.c | 3 +- drivers/usb/core/urb.c | 95 +- drivers/usb/gadget/Kconfig | 273 +- drivers/usb/gadget/Makefile | 23 +- drivers/usb/gadget/cdc2.c | 25 +- drivers/usb/gadget/composite.c | 64 + drivers/usb/gadget/dummy_hcd.c | 33 +- drivers/usb/gadget/ether.c | 28 +- drivers/usb/gadget/f_ecm.c | 108 +- drivers/usb/gadget/f_loopback.c | 34 +- drivers/usb/gadget/f_obex.c | 493 + drivers/usb/gadget/f_subset.c | 44 +- drivers/usb/gadget/file_storage.c | 22 +- drivers/usb/gadget/fsl_usb2_udc.c | 176 +- drivers/usb/gadget/fsl_usb2_udc.h | 21 +- drivers/usb/gadget/gmidi.c | 15 + drivers/usb/gadget/net2280.c | 40 +- drivers/usb/gadget/net2280.h | 1 + drivers/usb/gadget/omap_udc.c | 4 +- drivers/usb/gadget/printer.c | 18 +- drivers/usb/gadget/rndis.c | 115 +- drivers/usb/gadget/serial.c | 32 + drivers/usb/gadget/u_ether.c | 4 +- drivers/usb/gadget/u_serial.h | 1 + drivers/usb/gadget/zero.c | 17 + drivers/usb/host/ehci-hcd.c | 28 +- drivers/usb/host/ehci-sched.c | 32 +- drivers/usb/host/ehci.h | 138 +- drivers/usb/host/isp116x-hcd.c | 13 +- drivers/usb/host/ohci-hcd.c | 2 +- drivers/usb/host/ohci-omap.c | 4 +- drivers/usb/host/r8a66597-hcd.c | 54 +- drivers/usb/host/sl811-hcd.c | 15 +- drivers/usb/host/sl811_cs.c | 133 +- drivers/usb/host/uhci-hcd.c | 2 +- drivers/usb/image/mdc800.c | 15 +- drivers/usb/misc/Kconfig | 19 + drivers/usb/misc/Makefile | 2 + drivers/usb/misc/adutux.c | 5 +- drivers/usb/misc/cytherm.c | 3 +- drivers/usb/misc/emi26.c | 4 +- drivers/usb/misc/emi62.c | 4 +- drivers/usb/misc/gotemp.c | 301 + drivers/usb/misc/idmouse.c | 5 +- drivers/usb/misc/legousbtower.c | 23 +- drivers/usb/misc/phidgetkit.c | 5 +- drivers/usb/misc/phidgetmotorcontrol.c | 5 +- drivers/usb/misc/phidgetservo.c | 5 +- drivers/usb/misc/rio500.c | 11 +- drivers/usb/misc/trancevibrator.c | 3 +- drivers/usb/misc/usblcd.c | 13 +- drivers/usb/misc/usbsevseg.c | 394 + drivers/usb/misc/uss720.c | 19 +- drivers/usb/mon/mon_bin.c | 6 +- drivers/usb/musb/musb_core.c | 4 +- drivers/usb/musb/omap2430.c | 4 +- drivers/usb/musb/omap2430.h | 4 +- drivers/usb/serial/aircable.c | 11 +- drivers/usb/serial/belkin_sa.c | 39 +- drivers/usb/serial/cp2101.c | 3 +- drivers/usb/serial/cyberjack.c | 28 +- drivers/usb/serial/cypress_m8.c | 21 +- drivers/usb/serial/digi_acceleport.c | 68 +- drivers/usb/serial/empeg.c | 11 +- drivers/usb/serial/ezusb.c | 3 +- drivers/usb/serial/ftdi_sio.c | 92 +- drivers/usb/serial/garmin_gps.c | 3 +- drivers/usb/serial/hp4x.c | 3 +- drivers/usb/serial/io_edgeport.c | 19 +- drivers/usb/serial/io_ti.c | 3 +- drivers/usb/serial/ipaq.c | 30 +- drivers/usb/serial/ipw.c | 3 +- drivers/usb/serial/ir-usb.c | 3 +- drivers/usb/serial/iuu_phoenix.c | 3 +- drivers/usb/serial/keyspan.c | 3 +- drivers/usb/serial/keyspan_pda.c | 22 +- drivers/usb/serial/kl5kusb105.c | 69 +- drivers/usb/serial/kobil_sct.c | 4 +- drivers/usb/serial/mct_u232.c | 42 +- drivers/usb/serial/mos7720.c | 22 +- drivers/usb/serial/mos7840.c | 29 +- drivers/usb/serial/omninet.c | 22 +- drivers/usb/serial/option.c | 3 +- drivers/usb/serial/pl2303.c | 2 +- drivers/usb/serial/safe_serial.c | 28 +- drivers/usb/serial/sierra.c | 14 +- drivers/usb/serial/spcp8x5.c | 10 +- drivers/usb/serial/ti_usb_3410_5052.c | 3 +- drivers/usb/serial/usb-serial.c | 26 +- drivers/usb/serial/visor.c | 17 +- drivers/usb/serial/whiteheat.c | 121 +- drivers/usb/storage/Kconfig | 12 - drivers/usb/storage/Makefile | 3 +- drivers/usb/storage/unusual_devs.h | 16 +- drivers/usb/storage/usb.c | 2 - drivers/video/Kconfig | 31 +- drivers/video/Makefile | 1 - drivers/video/am200epd.c | 295 - drivers/video/atmel_lcdfb.c | 4 + drivers/video/bw2.c | 2 +- drivers/video/cg14.c | 2 +- drivers/video/cg3.c | 2 +- drivers/video/cg6.c | 2 +- drivers/video/console/fbcon.c | 4 +- drivers/video/display/display-sysfs.c | 9 +- drivers/video/fbmem.c | 22 +- drivers/video/ffb.c | 2 +- drivers/video/leo.c | 2 +- drivers/video/metronomefb.c | 288 +- drivers/video/omap/dispc.c | 10 +- drivers/video/omap/rfbi.c | 4 +- drivers/video/omap/sossi.c | 2 +- drivers/video/p9100.c | 2 +- drivers/video/tcx.c | 2 +- drivers/video/xen-fbfront.c | 4 +- drivers/watchdog/Makefile | 3 + drivers/watchdog/cpwd.c | 695 ++ drivers/watchdog/ixp4xx_wdt.c | 4 +- drivers/watchdog/riowd.c | 259 + drivers/xen/balloon.c | 176 +- drivers/xen/events.c | 56 +- drivers/xen/grant-table.c | 2 +- drivers/xen/xenbus/xenbus_probe.c | 8 +- firmware/Makefile | 20 + firmware/WHENCE | 121 + firmware/acenic/tg1.bin.ihex | 4573 ++++++++++ firmware/acenic/tg2.bin.ihex | 4844 ++++++++++ firmware/adaptec/starfire_rx.bin.ihex | 53 + firmware/adaptec/starfire_tx.bin.ihex | 53 + firmware/advansys/3550.bin.ihex | 317 + firmware/advansys/38C0800.bin.ihex | 336 + firmware/advansys/38C1600.bin.ihex | 398 + firmware/advansys/mcode.bin.ihex | 147 + firmware/av7110/Boot.S | 109 + firmware/av7110/bootcode.bin.ihex | 15 + firmware/e100/d101m_ucode.bin.ihex | 38 + firmware/e100/d101s_ucode.bin.ihex | 38 + firmware/e100/d102e_ucode.bin.ihex | 38 + firmware/qlogic/1040.bin.ihex | 2111 +++++ firmware/qlogic/12160.bin.ihex | 1771 ++++ firmware/qlogic/1280.bin.ihex | 2008 +++++ firmware/qlogic/isp1000.bin.ihex | 1158 +++ firmware/tigon/tg3.bin.ihex | 175 + firmware/tigon/tg3_tso.bin.ihex | 446 + firmware/tigon/tg3_tso5.bin.ihex | 252 + firmware/yamaha/yss225_registers.bin.ihex | 998 +++ fs/9p/fid.c | 2 +- fs/9p/vfs_inode.c | 4 +- fs/9p/vfs_super.c | 4 +- fs/Kconfig | 220 +- fs/Makefile | 3 +- fs/affs/inode.c | 4 +- fs/affs/super.c | 4 +- fs/anon_inodes.c | 4 +- fs/attr.c | 4 +- fs/autofs/inode.c | 4 +- fs/autofs4/inode.c | 4 +- fs/autofs4/waitq.c | 4 +- fs/bfs/dir.c | 4 +- fs/binfmt_aout.c | 2 +- fs/binfmt_elf.c | 20 +- fs/binfmt_elf_fdpic.c | 19 +- fs/binfmt_flat.c | 2 +- fs/binfmt_som.c | 2 +- fs/bio.c | 156 +- fs/block_dev.c | 106 +- fs/buffer.c | 99 + fs/char_dev.c | 24 +- fs/cifs/cifs_fs_sb.h | 2 +- fs/cifs/cifsproto.h | 2 +- fs/cifs/connect.c | 4 +- fs/cifs/dir.c | 12 +- fs/cifs/inode.c | 8 +- fs/cifs/ioctl.c | 2 +- fs/cifs/misc.c | 4 +- fs/coda/cache.c | 6 +- fs/coda/file.c | 3 +- fs/coda/psdev.c | 5 +- fs/coda/upcall.c | 2 +- fs/compat.c | 64 +- fs/configfs/symlink.c | 16 +- fs/dcache.c | 233 +- fs/devpts/inode.c | 4 +- fs/dlm/config.c | 33 +- fs/dlm/dlm_internal.h | 7 +- fs/dlm/lockspace.c | 158 +- fs/dlm/lockspace.h | 1 + fs/dlm/user.c | 115 +- fs/dlm/user.h | 4 +- fs/dquot.c | 14 +- fs/drop_caches.c | 2 +- fs/ecryptfs/ecryptfs_kernel.h | 3 +- fs/ecryptfs/kthread.c | 9 +- fs/ecryptfs/main.c | 26 +- fs/ecryptfs/messaging.c | 18 +- fs/ecryptfs/miscdev.c | 20 +- fs/efs/namei.c | 29 +- fs/efs/super.c | 2 - fs/exec.c | 192 +- fs/exportfs/expfs.c | 20 +- fs/ext2/balloc.c | 2 +- fs/ext2/dir.c | 14 +- fs/ext2/ext2.h | 4 +- fs/ext2/ialloc.c | 4 +- fs/ext2/namei.c | 30 +- fs/ext2/super.c | 9 + fs/ext3/balloc.c | 2 +- fs/ext3/ialloc.c | 4 +- fs/ext3/namei.c | 84 +- fs/ext3/super.c | 30 +- fs/ext4/balloc.c | 3 +- fs/ext4/ialloc.c | 4 +- fs/ext4/namei.c | 14 +- fs/ext4/super.c | 30 +- fs/fat/fatent.c | 14 + fs/fat/file.c | 2 +- fs/fat/inode.c | 56 +- fs/fcntl.c | 18 +- fs/file_table.c | 10 +- fs/fuse/dev.c | 4 +- fs/fuse/dir.c | 25 +- fs/fuse/inode.c | 23 +- fs/gfs2/glock.c | 13 +- fs/gfs2/incore.h | 7 +- fs/gfs2/inode.c | 58 +- fs/gfs2/inode.h | 1 - fs/gfs2/locking/dlm/mount.c | 3 +- fs/gfs2/mount.c | 7 + fs/gfs2/ops_export.c | 33 +- fs/gfs2/ops_fstype.c | 566 +- fs/gfs2/ops_inode.c | 129 +- fs/gfs2/ops_super.c | 57 +- fs/gfs2/super.c | 340 - fs/gfs2/super.h | 6 - fs/hfs/inode.c | 4 +- fs/hfs/super.c | 4 +- fs/hfsplus/inode.c | 4 +- fs/hfsplus/options.c | 4 +- fs/hpfs/file.c | 2 +- fs/hpfs/hpfs_fn.h | 2 +- fs/hpfs/inode.c | 29 +- fs/hpfs/namei.c | 26 +- fs/hpfs/super.c | 4 +- fs/hppfs/hppfs.c | 6 +- fs/hugetlbfs/inode.c | 21 +- fs/inode.c | 123 + fs/inotify_user.c | 2 +- fs/internal.h | 6 + fs/ioprio.c | 18 +- fs/isofs/export.c | 33 +- fs/jffs2/Kconfig | 188 + fs/jffs2/dir.c | 6 +- fs/jffs2/erase.c | 4 +- fs/jffs2/fs.c | 8 +- fs/jffs2/super.c | 48 + fs/jfs/jfs_inode.c | 4 +- fs/jfs/namei.c | 15 +- fs/libfs.c | 26 +- fs/lockd/host.c | 123 +- fs/lockd/svc.c | 33 +- fs/locks.c | 2 +- fs/minix/bitmap.c | 4 +- fs/namei.c | 85 +- fs/namespace.c | 126 +- fs/ncpfs/ioctl.c | 91 +- fs/nfs/callback.c | 3 +- fs/nfs/dir.c | 6 +- fs/nfs/getroot.c | 6 +- fs/nfsctl.c | 4 +- fs/nfsd/auth.c | 95 +- fs/nfsd/export.c | 125 +- fs/nfsd/nfs3proc.c | 8 +- fs/nfsd/nfs4callback.c | 3 +- fs/nfsd/nfs4recover.c | 119 +- fs/nfsd/nfs4state.c | 8 +- fs/nfsd/nfs4xdr.c | 171 +- fs/nfsd/nfsctl.c | 8 +- fs/nfsd/nfsfh.c | 41 +- fs/nfsd/nfsproc.c | 6 +- fs/nfsd/nfssvc.c | 1 + fs/nfsd/vfs.c | 198 +- fs/nls/nls_base.c | 21 +- fs/ntfs/aops.c | 2 +- fs/ntfs/namei.c | 22 +- fs/ocfs2/Makefile | 5 +- fs/ocfs2/alloc.c | 829 ++- fs/ocfs2/alloc.h | 86 +- fs/ocfs2/aops.c | 30 +- fs/ocfs2/cluster/masklog.c | 1 + fs/ocfs2/cluster/masklog.h | 1 + fs/ocfs2/dir.c | 26 +- fs/ocfs2/dlm/dlmfs.c | 8 +- fs/ocfs2/export.c | 30 +- fs/ocfs2/extent_map.c | 60 + fs/ocfs2/extent_map.h | 3 + fs/ocfs2/file.c | 299 +- fs/ocfs2/file.h | 32 +- fs/ocfs2/inode.c | 23 +- fs/ocfs2/inode.h | 3 + fs/ocfs2/journal.h | 27 +- fs/ocfs2/localalloc.c | 307 +- fs/ocfs2/localalloc.h | 4 + fs/ocfs2/locks.c | 15 + fs/ocfs2/locks.h | 1 + fs/ocfs2/namei.c | 17 +- fs/ocfs2/ocfs2.h | 48 +- fs/ocfs2/ocfs2_fs.h | 220 +- fs/ocfs2/stack_user.c | 33 + fs/ocfs2/stackglue.c | 20 + fs/ocfs2/stackglue.h | 19 + fs/ocfs2/suballoc.c | 129 +- fs/ocfs2/suballoc.h | 15 +- fs/ocfs2/super.c | 27 +- fs/ocfs2/symlink.c | 9 + fs/ocfs2/uptodate.c | 32 +- fs/ocfs2/uptodate.h | 3 + fs/ocfs2/xattr.c | 4867 ++++++++++ fs/ocfs2/xattr.h | 75 + fs/ocfs2/xattr_trusted.c | 82 + fs/ocfs2/xattr_user.c | 94 + fs/omfs/inode.c | 8 +- fs/open.c | 59 +- fs/partitions/check.c | 265 +- fs/partitions/check.h | 4 +- fs/pipe.c | 4 +- fs/posix_acl.c | 4 +- fs/proc/array.c | 32 +- fs/proc/base.c | 32 +- fs/proc/inode.c | 8 + fs/proc/nommu.c | 2 +- fs/proc/proc_misc.c | 76 +- fs/quota.c | 4 +- fs/ramfs/inode.c | 4 +- fs/read_write.c | 58 +- fs/readdir.c | 22 +- fs/reiserfs/inode.c | 13 +- fs/reiserfs/namei.c | 15 +- fs/reiserfs/super.c | 26 +- fs/smbfs/dir.c | 3 +- fs/smbfs/inode.c | 2 +- fs/smbfs/proc.c | 2 +- fs/super.c | 15 +- fs/sysfs/dir.c | 245 +- fs/sysfs/file.c | 88 +- fs/sysfs/inode.c | 23 +- fs/sysfs/mount.c | 94 +- fs/sysfs/sysfs.h | 20 +- fs/sysv/ialloc.c | 4 +- fs/ubifs/budget.c | 115 +- fs/ubifs/dir.c | 5 +- fs/ubifs/file.c | 20 +- fs/ubifs/find.c | 18 +- fs/ubifs/gc.c | 6 + fs/ubifs/misc.h | 49 +- fs/ubifs/super.c | 22 +- fs/ubifs/tnc.c | 116 +- fs/ubifs/ubifs.h | 14 +- fs/udf/ialloc.c | 48 +- fs/udf/namei.c | 19 +- fs/ufs/ialloc.c | 4 +- fs/xfs/linux-2.6/xfs_cred.h | 6 +- fs/xfs/linux-2.6/xfs_export.c | 32 +- fs/xfs/linux-2.6/xfs_file.c | 128 - fs/xfs/linux-2.6/xfs_globals.h | 2 +- fs/xfs/linux-2.6/xfs_ioctl.c | 8 +- fs/xfs/linux-2.6/xfs_super.c | 13 +- fs/xfs/xfs_acl.c | 6 +- fs/xfs/xfs_inode.h | 2 +- fs/xfs/xfs_mount.h | 1 + fs/xfs/xfs_vnodeops.h | 10 +- include/acpi/acconfig.h | 2 +- include/acpi/acdisasm.h | 4 + include/acpi/acmacros.h | 248 +- include/acpi/acpi_bus.h | 2 + include/acpi/acpi_drivers.h | 1 + include/acpi/actbl1.h | 51 +- include/acpi/actypes.h | 3 +- include/acpi/acutils.h | 4 +- include/asm-generic/percpu.h | 11 +- include/asm-generic/sections.h | 10 + include/asm-generic/statfs.h | 65 +- include/asm-generic/vmlinux.lds.h | 60 +- include/asm-m68k/dma-mapping.h | 16 + include/asm-m68k/pci.h | 1 + include/asm-mips/mach-generic/ide.h | 29 - include/asm-mips/mach-rc32434/gpio.h | 74 +- include/asm-mips/mach-rc32434/irq.h | 25 + include/asm-mips/mach-rc32434/prom.h | 4 - include/asm-mips/mach-rc32434/rb.h | 5 +- include/asm-mips/mach-rc32434/rc32434.h | 42 - include/asm-mips/pmc-sierra/msp71xx/gpio.h | 46 + include/asm-mips/ptrace.h | 3 + include/asm-mips/txx9/boards.h | 13 + include/asm-mips/txx9/generic.h | 29 +- include/asm-mips/txx9/rbtx4927.h | 3 + include/asm-mips/txx9/rbtx4939.h | 133 + include/asm-mips/txx9/smsc_fdc37m81x.h | 1 + include/asm-mips/txx9/spi.h | 19 +- include/asm-mips/txx9/tx3927.h | 2 + include/asm-mips/txx9/tx4927.h | 14 + include/asm-mips/txx9/tx4938.h | 2 + include/asm-mips/txx9/tx4939.h | 544 ++ include/asm-parisc/Kbuild | 3 - include/asm-parisc/a.out.h | 20 - include/asm-parisc/agp.h | 24 - include/asm-parisc/asmregs.h | 183 - include/asm-parisc/assembly.h | 519 -- include/asm-parisc/atomic.h | 348 - include/asm-parisc/auxvec.h | 4 - include/asm-parisc/bitops.h | 239 - include/asm-parisc/bug.h | 92 - include/asm-parisc/bugs.h | 19 - include/asm-parisc/byteorder.h | 82 - include/asm-parisc/cache.h | 60 - include/asm-parisc/cacheflush.h | 121 - include/asm-parisc/checksum.h | 210 - include/asm-parisc/compat.h | 165 - include/asm-parisc/compat_rt_sigframe.h | 50 - include/asm-parisc/compat_signal.h | 2 - include/asm-parisc/compat_ucontext.h | 17 - include/asm-parisc/cputime.h | 6 - include/asm-parisc/current.h | 15 - include/asm-parisc/delay.h | 43 - include/asm-parisc/device.h | 7 - include/asm-parisc/div64.h | 1 - include/asm-parisc/dma-mapping.h | 253 - include/asm-parisc/dma.h | 186 - include/asm-parisc/eisa_bus.h | 23 - include/asm-parisc/eisa_eeprom.h | 153 - include/asm-parisc/elf.h | 342 - include/asm-parisc/emergency-restart.h | 6 - include/asm-parisc/errno.h | 124 - include/asm-parisc/fb.h | 19 - include/asm-parisc/fcntl.h | 39 - include/asm-parisc/fixmap.h | 30 - include/asm-parisc/floppy.h | 271 - include/asm-parisc/futex.h | 77 - include/asm-parisc/grfioctl.h | 113 - include/asm-parisc/hardirq.h | 29 - include/asm-parisc/hardware.h | 127 - include/asm-parisc/hw_irq.h | 8 - include/asm-parisc/ide.h | 61 - include/asm-parisc/io.h | 293 - include/asm-parisc/ioctl.h | 44 - include/asm-parisc/ioctls.h | 90 - include/asm-parisc/ipcbuf.h | 27 - include/asm-parisc/irq.h | 57 - include/asm-parisc/irq_regs.h | 1 - include/asm-parisc/kdebug.h | 1 - include/asm-parisc/kmap_types.h | 30 - include/asm-parisc/led.h | 42 - include/asm-parisc/linkage.h | 31 - include/asm-parisc/local.h | 1 - include/asm-parisc/machdep.h | 16 - include/asm-parisc/mc146818rtc.h | 9 - include/asm-parisc/mckinley.h | 9 - include/asm-parisc/mman.h | 61 - include/asm-parisc/mmu.h | 7 - include/asm-parisc/mmu_context.h | 75 - include/asm-parisc/mmzone.h | 73 - include/asm-parisc/module.h | 32 - include/asm-parisc/msgbuf.h | 37 - include/asm-parisc/mutex.h | 9 - include/asm-parisc/page.h | 173 - include/asm-parisc/param.h | 22 - include/asm-parisc/parisc-device.h | 64 - include/asm-parisc/parport.h | 18 - include/asm-parisc/pci.h | 294 - include/asm-parisc/pdc.h | 757 -- include/asm-parisc/pdc_chassis.h | 381 - include/asm-parisc/pdcpat.h | 308 - include/asm-parisc/percpu.h | 7 - include/asm-parisc/perf.h | 74 - include/asm-parisc/pgalloc.h | 149 - include/asm-parisc/pgtable.h | 508 -- include/asm-parisc/poll.h | 1 - include/asm-parisc/posix_types.h | 129 - include/asm-parisc/prefetch.h | 39 - include/asm-parisc/processor.h | 357 - include/asm-parisc/psw.h | 62 - include/asm-parisc/ptrace.h | 58 - include/asm-parisc/real.h | 5 - include/asm-parisc/resource.h | 7 - include/asm-parisc/ropes.h | 322 - include/asm-parisc/rt_sigframe.h | 23 - include/asm-parisc/rtc.h | 131 - include/asm-parisc/runway.h | 12 - include/asm-parisc/scatterlist.h | 27 - include/asm-parisc/sections.h | 7 - include/asm-parisc/segment.h | 6 - include/asm-parisc/sembuf.h | 29 - include/asm-parisc/serial.h | 10 - include/asm-parisc/setup.h | 6 - include/asm-parisc/shmbuf.h | 58 - include/asm-parisc/shmparam.h | 8 - include/asm-parisc/sigcontext.h | 20 - include/asm-parisc/siginfo.h | 14 - include/asm-parisc/signal.h | 153 - include/asm-parisc/smp.h | 68 - include/asm-parisc/socket.h | 62 - include/asm-parisc/sockios.h | 13 - include/asm-parisc/spinlock.h | 194 - include/asm-parisc/spinlock_types.h | 21 - include/asm-parisc/stat.h | 100 - include/asm-parisc/statfs.h | 58 - include/asm-parisc/string.h | 10 - include/asm-parisc/superio.h | 85 - include/asm-parisc/system.h | 182 - include/asm-parisc/termbits.h | 200 - include/asm-parisc/termios.h | 90 - include/asm-parisc/thread_info.h | 74 - include/asm-parisc/timex.h | 20 - include/asm-parisc/tlb.h | 27 - include/asm-parisc/tlbflush.h | 80 - include/asm-parisc/topology.h | 6 - include/asm-parisc/traps.h | 16 - include/asm-parisc/types.h | 36 - include/asm-parisc/uaccess.h | 244 - include/asm-parisc/ucontext.h | 12 - include/asm-parisc/unaligned.h | 16 - include/asm-parisc/unistd.h | 991 -- include/asm-parisc/unwind.h | 77 - include/asm-parisc/user.h | 5 - include/asm-parisc/vga.h | 6 - include/asm-parisc/xor.h | 1 - include/asm-x86/a.out-core.h | 6 +- include/asm-x86/a.out.h | 6 +- include/asm-x86/acpi.h | 6 +- include/asm-x86/agp.h | 6 +- include/asm-x86/alternative.h | 6 +- include/asm-x86/amd_iommu.h | 6 +- include/asm-x86/amd_iommu_types.h | 6 +- include/asm-x86/apic.h | 82 +- include/asm-x86/apicdef.h | 9 +- include/asm-x86/arch_hooks.h | 8 +- include/asm-x86/asm.h | 13 +- include/asm-x86/atomic_32.h | 6 +- include/asm-x86/atomic_64.h | 6 +- include/asm-x86/auxvec.h | 6 +- include/asm-x86/bigsmp/apic.h | 139 + include/asm-x86/bigsmp/apicdef.h | 13 + include/asm-x86/bigsmp/ipi.h | 25 + include/asm-x86/bios_ebda.h | 6 +- include/asm-x86/bitops.h | 6 +- include/asm-x86/boot.h | 6 +- include/asm-x86/bootparam.h | 6 +- include/asm-x86/bug.h | 6 +- include/asm-x86/bugs.h | 11 +- include/asm-x86/byteorder.h | 6 +- include/asm-x86/cache.h | 6 +- include/asm-x86/cacheflush.h | 9 +- include/asm-x86/calgary.h | 6 +- include/asm-x86/checksum_32.h | 6 +- include/asm-x86/checksum_64.h | 6 +- include/asm-x86/cmpxchg_32.h | 6 +- include/asm-x86/cmpxchg_64.h | 6 +- include/asm-x86/compat.h | 6 +- include/asm-x86/cpu.h | 6 +- include/asm-x86/cpufeature.h | 22 +- include/asm-x86/current.h | 6 +- include/asm-x86/debugreg.h | 6 +- include/asm-x86/delay.h | 6 +- include/asm-x86/desc.h | 21 +- include/asm-x86/desc_defs.h | 6 +- include/asm-x86/device.h | 6 +- include/asm-x86/div64.h | 6 +- include/asm-x86/dma-mapping.h | 56 +- include/asm-x86/dma.h | 6 +- include/asm-x86/dmi.h | 6 +- include/asm-x86/ds.h | 6 +- include/asm-x86/dwarf2.h | 6 +- include/asm-x86/e820.h | 8 +- include/asm-x86/edac.h | 6 +- include/asm-x86/efi.h | 6 +- include/asm-x86/elf.h | 11 +- include/asm-x86/emergency-restart.h | 6 +- include/asm-x86/es7000/apic.h | 193 + include/asm-x86/es7000/apicdef.h | 13 + include/asm-x86/es7000/ipi.h | 24 + include/asm-x86/es7000/mpparse.h | 29 + include/asm-x86/es7000/wakecpu.h | 59 + include/asm-x86/fb.h | 6 +- include/asm-x86/fixmap.h | 6 +- include/asm-x86/fixmap_32.h | 6 +- include/asm-x86/fixmap_64.h | 6 +- include/asm-x86/floppy.h | 6 +- include/asm-x86/ftrace.h | 16 +- include/asm-x86/futex.h | 12 +- include/asm-x86/gart.h | 6 +- include/asm-x86/genapic_32.h | 8 +- include/asm-x86/genapic_64.h | 14 +- include/asm-x86/geode.h | 6 +- include/asm-x86/gpio.h | 2 +- include/asm-x86/hardirq_32.h | 6 +- include/asm-x86/hardirq_64.h | 6 +- include/asm-x86/highmem.h | 6 +- include/asm-x86/hpet.h | 6 +- include/asm-x86/hugetlb.h | 6 +- include/asm-x86/hw_irq.h | 30 +- include/asm-x86/hypertransport.h | 6 +- include/asm-x86/i387.h | 91 +- include/asm-x86/i8253.h | 6 +- include/asm-x86/i8259.h | 9 +- include/asm-x86/ia32.h | 6 +- include/asm-x86/ia32_unistd.h | 6 +- include/asm-x86/idle.h | 6 +- include/asm-x86/intel_arch_perfmon.h | 6 +- include/asm-x86/io.h | 8 +- include/asm-x86/io_32.h | 6 +- include/asm-x86/io_64.h | 7 +- include/asm-x86/io_apic.h | 48 +- include/asm-x86/ioctls.h | 6 +- include/asm-x86/iommu.h | 6 +- include/asm-x86/ipcbuf.h | 6 +- include/asm-x86/ipi.h | 22 +- include/asm-x86/irq.h | 6 +- include/asm-x86/irq_regs_32.h | 6 +- include/asm-x86/irq_remapping.h | 8 + include/asm-x86/irq_vectors.h | 30 +- include/asm-x86/irqflags.h | 56 + include/asm-x86/ist.h | 6 +- include/asm-x86/k8.h | 6 +- include/asm-x86/kdebug.h | 9 +- include/asm-x86/kexec.h | 6 +- include/asm-x86/kgdb.h | 6 +- include/asm-x86/kmap_types.h | 6 +- include/asm-x86/kmemcheck.h | 36 + include/asm-x86/kprobes.h | 6 +- include/asm-x86/kvm.h | 28 +- include/asm-x86/kvm_host.h | 97 +- include/asm-x86/kvm_para.h | 6 +- include/asm-x86/kvm_x86_emulate.h | 6 +- include/asm-x86/ldt.h | 6 +- include/asm-x86/lguest.h | 6 +- include/asm-x86/lguest_hcall.h | 6 +- include/asm-x86/linkage.h | 6 +- include/asm-x86/local.h | 6 +- include/asm-x86/mach-bigsmp/mach_apic.h | 144 - include/asm-x86/mach-bigsmp/mach_apicdef.h | 13 - include/asm-x86/mach-bigsmp/mach_ipi.h | 25 - include/asm-x86/mach-default/apm.h | 6 +- include/asm-x86/mach-default/entry_arch.h | 1 + include/asm-x86/mach-default/mach_apic.h | 25 +- include/asm-x86/mach-default/mach_apicdef.h | 12 +- include/asm-x86/mach-default/mach_ipi.h | 6 +- include/asm-x86/mach-default/mach_mpparse.h | 6 +- include/asm-x86/mach-default/mach_mpspec.h | 6 +- include/asm-x86/mach-default/mach_timer.h | 6 +- include/asm-x86/mach-default/mach_traps.h | 6 +- include/asm-x86/mach-default/mach_wakecpu.h | 6 +- include/asm-x86/mach-es7000/mach_apic.h | 194 - include/asm-x86/mach-es7000/mach_apicdef.h | 13 - include/asm-x86/mach-es7000/mach_ipi.h | 24 - include/asm-x86/mach-es7000/mach_mpparse.h | 29 - include/asm-x86/mach-es7000/mach_wakecpu.h | 59 - include/asm-x86/mach-generic/gpio.h | 6 +- include/asm-x86/mach-generic/irq_vectors_limits.h | 14 - include/asm-x86/mach-generic/mach_apic.h | 7 +- include/asm-x86/mach-generic/mach_apicdef.h | 6 +- include/asm-x86/mach-generic/mach_ipi.h | 6 +- include/asm-x86/mach-generic/mach_mpparse.h | 6 +- include/asm-x86/mach-generic/mach_mpspec.h | 6 +- include/asm-x86/mach-numaq/mach_apic.h | 138 - include/asm-x86/mach-numaq/mach_apicdef.h | 14 - include/asm-x86/mach-numaq/mach_ipi.h | 25 - include/asm-x86/mach-numaq/mach_mpparse.h | 7 - include/asm-x86/mach-numaq/mach_wakecpu.h | 43 - include/asm-x86/mach-rdc321x/gpio.h | 6 +- include/asm-x86/mach-summit/irq_vectors_limits.h | 14 - include/asm-x86/mach-summit/mach_apic.h | 185 - include/asm-x86/mach-summit/mach_apicdef.h | 13 - include/asm-x86/mach-summit/mach_ipi.h | 25 - include/asm-x86/mach-summit/mach_mpparse.h | 110 - include/asm-x86/math_emu.h | 6 +- include/asm-x86/mc146818rtc.h | 6 +- include/asm-x86/mca.h | 6 +- include/asm-x86/mca_dma.h | 6 +- include/asm-x86/mce.h | 6 +- include/asm-x86/microcode.h | 99 + include/asm-x86/mman.h | 6 +- include/asm-x86/mmconfig.h | 6 +- include/asm-x86/mmu.h | 6 +- include/asm-x86/mmu_context.h | 6 +- include/asm-x86/mmu_context_32.h | 6 +- include/asm-x86/mmu_context_64.h | 6 +- include/asm-x86/mmx.h | 6 +- include/asm-x86/mmzone_32.h | 6 +- include/asm-x86/mmzone_64.h | 6 +- include/asm-x86/module.h | 6 +- include/asm-x86/mpspec.h | 9 +- include/asm-x86/mpspec_def.h | 6 +- include/asm-x86/msgbuf.h | 6 +- include/asm-x86/msidef.h | 10 +- include/asm-x86/msr-index.h | 6 +- include/asm-x86/msr.h | 29 +- include/asm-x86/mtrr.h | 6 +- include/asm-x86/mutex_32.h | 6 +- include/asm-x86/mutex_64.h | 6 +- include/asm-x86/nmi.h | 6 +- include/asm-x86/nops.h | 6 +- include/asm-x86/numa_32.h | 6 +- include/asm-x86/numa_64.h | 6 +- include/asm-x86/numaq.h | 6 +- include/asm-x86/numaq/apic.h | 136 + include/asm-x86/numaq/apicdef.h | 14 + include/asm-x86/numaq/ipi.h | 25 + include/asm-x86/numaq/mpparse.h | 7 + include/asm-x86/numaq/wakecpu.h | 43 + include/asm-x86/olpc.h | 6 +- include/asm-x86/page.h | 6 +- include/asm-x86/page_32.h | 10 +- include/asm-x86/page_64.h | 7 +- include/asm-x86/param.h | 6 +- include/asm-x86/paravirt.h | 92 +- include/asm-x86/parport.h | 6 +- include/asm-x86/pat.h | 6 +- include/asm-x86/pci-direct.h | 6 +- include/asm-x86/pci.h | 6 +- include/asm-x86/pci_32.h | 6 +- include/asm-x86/pci_64.h | 6 +- include/asm-x86/pda.h | 9 +- include/asm-x86/percpu.h | 89 +- include/asm-x86/pgalloc.h | 6 +- include/asm-x86/pgtable-2level-defs.h | 6 +- include/asm-x86/pgtable-2level.h | 6 +- include/asm-x86/pgtable-3level-defs.h | 6 +- include/asm-x86/pgtable-3level.h | 6 +- include/asm-x86/pgtable.h | 12 +- include/asm-x86/pgtable_32.h | 18 +- include/asm-x86/pgtable_64.h | 12 +- include/asm-x86/posix_types_32.h | 6 +- include/asm-x86/posix_types_64.h | 6 +- include/asm-x86/prctl.h | 6 +- include/asm-x86/processor-cyrix.h | 8 + include/asm-x86/processor-flags.h | 7 +- include/asm-x86/processor.h | 66 +- include/asm-x86/proto.h | 6 +- include/asm-x86/ptrace-abi.h | 6 +- include/asm-x86/ptrace.h | 14 +- include/asm-x86/pvclock-abi.h | 6 +- include/asm-x86/pvclock.h | 7 +- include/asm-x86/reboot.h | 6 +- include/asm-x86/reboot_fixups.h | 6 +- include/asm-x86/required-features.h | 14 +- include/asm-x86/resume-trace.h | 8 +- include/asm-x86/rio.h | 6 +- include/asm-x86/rwlock.h | 6 +- include/asm-x86/rwsem.h | 6 +- include/asm-x86/scatterlist.h | 6 +- include/asm-x86/seccomp_32.h | 6 +- include/asm-x86/seccomp_64.h | 6 +- include/asm-x86/segment.h | 6 +- include/asm-x86/sembuf.h | 6 +- include/asm-x86/serial.h | 6 +- include/asm-x86/setup.h | 8 +- include/asm-x86/shmbuf.h | 6 +- include/asm-x86/shmparam.h | 6 +- include/asm-x86/sigcontext.h | 93 +- include/asm-x86/sigcontext32.h | 12 +- include/asm-x86/siginfo.h | 6 +- include/asm-x86/signal.h | 9 +- include/asm-x86/smp.h | 27 +- include/asm-x86/socket.h | 6 +- include/asm-x86/sockios.h | 6 +- include/asm-x86/sparsemem.h | 6 +- include/asm-x86/spinlock.h | 21 +- include/asm-x86/spinlock_types.h | 6 +- include/asm-x86/srat.h | 6 +- include/asm-x86/stackprotector.h | 38 + include/asm-x86/stacktrace.h | 6 +- include/asm-x86/stat.h | 6 +- include/asm-x86/statfs.h | 67 +- include/asm-x86/string_32.h | 14 +- include/asm-x86/string_64.h | 7 +- include/asm-x86/summit/apic.h | 184 + include/asm-x86/summit/apicdef.h | 13 + include/asm-x86/summit/ipi.h | 25 + include/asm-x86/summit/mpparse.h | 109 + include/asm-x86/suspend_32.h | 6 +- include/asm-x86/suspend_64.h | 6 +- include/asm-x86/swiotlb.h | 6 +- include/asm-x86/sync_bitops.h | 6 +- include/asm-x86/syscall.h | 210 + include/asm-x86/syscalls.h | 93 + include/asm-x86/system.h | 12 +- include/asm-x86/system_64.h | 6 +- include/asm-x86/tce.h | 6 +- include/asm-x86/termbits.h | 6 +- include/asm-x86/termios.h | 6 +- include/asm-x86/therm_throt.h | 6 +- include/asm-x86/thread_info.h | 11 +- include/asm-x86/time.h | 8 +- include/asm-x86/timer.h | 11 +- include/asm-x86/timex.h | 6 +- include/asm-x86/tlb.h | 6 +- include/asm-x86/tlbflush.h | 6 +- include/asm-x86/topology.h | 6 +- include/asm-x86/trampoline.h | 6 +- include/asm-x86/traps.h | 10 +- include/asm-x86/tsc.h | 6 +- include/asm-x86/types.h | 6 +- include/asm-x86/uaccess.h | 6 +- include/asm-x86/uaccess_32.h | 6 +- include/asm-x86/uaccess_64.h | 6 +- include/asm-x86/ucontext.h | 12 +- include/asm-x86/unaligned.h | 6 +- include/asm-x86/unistd_32.h | 6 +- include/asm-x86/unistd_64.h | 6 +- include/asm-x86/unwind.h | 6 +- include/asm-x86/user32.h | 6 +- include/asm-x86/user_32.h | 6 +- include/asm-x86/user_64.h | 6 +- include/asm-x86/uv/bios.h | 6 +- include/asm-x86/uv/uv_bau.h | 6 +- include/asm-x86/uv/uv_hub.h | 6 +- include/asm-x86/uv/uv_mmrs.h | 6 +- include/asm-x86/vdso.h | 6 +- include/asm-x86/vga.h | 6 +- include/asm-x86/vgtod.h | 6 +- include/asm-x86/visws/cobalt.h | 6 +- include/asm-x86/visws/lithium.h | 6 +- include/asm-x86/visws/piix4.h | 6 +- include/asm-x86/vm86.h | 6 +- include/asm-x86/vmi_time.h | 6 +- include/asm-x86/vsyscall.h | 6 +- include/asm-x86/xcr.h | 49 + include/asm-x86/xen/events.h | 6 +- include/asm-x86/xen/grant_table.h | 6 +- include/asm-x86/xen/hypercall.h | 6 +- include/asm-x86/xen/hypervisor.h | 20 +- include/asm-x86/xen/interface.h | 6 +- include/asm-x86/xen/interface_32.h | 6 +- include/asm-x86/xen/interface_64.h | 6 +- include/asm-x86/xen/page.h | 6 +- include/asm-x86/xsave.h | 118 + include/asm-xtensa/rwsem.h | 4 + include/crypto/internal/rng.h | 26 + include/crypto/internal/skcipher.h | 6 - include/crypto/rng.h | 75 + include/drm/drm.h | 17 - include/keys/keyring-type.h | 31 + include/linux/acpi.h | 52 +- include/linux/ata.h | 112 +- include/linux/binfmts.h | 16 +- include/linux/bio.h | 80 +- include/linux/blkdev.h | 93 +- include/linux/blktrace_api.h | 6 + include/linux/capability.h | 2 - include/linux/clocksource.h | 14 +- include/linux/compiler.h | 30 +- include/linux/cpufreq.h | 7 +- include/linux/cred.h | 340 +- include/linux/crypto.h | 35 + include/linux/dcache.h | 2 +- include/linux/device.h | 24 +- include/linux/dlm.h | 5 +- include/linux/dlm_device.h | 2 +- include/linux/dmar.h | 127 +- include/linux/dynamic_printk.h | 93 + include/linux/elevator.h | 9 +- include/linux/elf.h | 1 + include/linux/fs.h | 78 +- include/linux/ftrace.h | 50 +- include/linux/gameport.h | 7 +- include/linux/genhd.h | 363 +- include/linux/gfp.h | 3 +- include/linux/hardirq.h | 27 +- include/linux/hid.h | 357 +- include/linux/hiddev.h | 6 +- include/linux/hpet.h | 14 +- include/linux/i2c-id.h | 1 - include/linux/ide.h | 854 +- include/linux/ieee80211.h | 1 + include/linux/if_ether.h | 1 + include/linux/init.h | 55 +- include/linux/init_task.h | 13 +- include/linux/input.h | 15 +- include/linux/interrupt.h | 21 + include/linux/ip_vs.h | 160 + include/linux/irq.h | 90 +- include/linux/kernel.h | 36 +- include/linux/kernel_stat.h | 26 +- include/linux/key-ui.h | 66 - include/linux/key.h | 32 +- include/linux/keyctl.h | 4 +- include/linux/klist.h | 3 +- include/linux/kmemcheck.h | 70 + include/linux/kmemtrace.h | 86 + include/linux/kprobes.h | 5 +- include/linux/kvm.h | 67 +- include/linux/kvm_host.h | 19 + include/linux/linkage.h | 2 - include/linux/lockd/lockd.h | 4 + include/linux/magic.h | 1 + include/linux/major.h | 2 + include/linux/mm.h | 3 +- include/linux/mm_types.h | 4 + include/linux/mmc/sdio_func.h | 41 +- include/linux/mmzone.h | 1 + include/linux/mod_devicetable.h | 12 +- include/linux/module.h | 21 + include/linux/mtd/blktrans.h | 2 + include/linux/mtd/cfi.h | 9 +- include/linux/mtd/flashchip.h | 4 + include/linux/mtd/mtd.h | 4 +- include/linux/mtd/nand.h | 1 + include/linux/mtd/onenand_regs.h | 2 + include/linux/namei.h | 7 +- include/linux/netdevice.h | 1 - include/linux/nfsd/nfsd.h | 3 +- include/linux/nl80211.h | 31 + include/linux/oprofile.h | 5 + include/linux/page-flags.h | 2 + include/linux/pci.h | 12 +- include/linux/pci_ids.h | 9 +- include/linux/percpu.h | 24 +- include/linux/pnp.h | 10 - include/linux/poison.h | 16 +- include/linux/power_supply.h | 6 + include/linux/proportions.h | 2 +- include/linux/rcuclassic.h | 31 +- include/linux/rculist.h | 14 - include/linux/rcupdate.h | 20 + include/linux/rcupreempt.h | 11 +- include/linux/rfkill.h | 7 +- include/linux/rtc/m48t59.h | 47 +- include/linux/sched.h | 84 +- include/linux/securebits.h | 2 +- include/linux/security.h | 380 +- include/linux/slab.h | 68 +- include/linux/slab_def.h | 149 +- include/linux/slob_def.h | 9 +- include/linux/slub_def.h | 69 +- include/linux/ssb/ssb_regs.h | 19 +- include/linux/stackprotector.h | 16 + include/linux/stacktrace.h | 3 + include/linux/stringify.h | 5 + include/linux/sunrpc/clnt.h | 4 +- include/linux/sunrpc/svc.h | 19 +- include/linux/swap.h | 3 + include/linux/sysfs.h | 31 +- include/linux/tick.h | 2 +- include/linux/time.h | 2 + include/linux/timex.h | 9 +- include/linux/tracepoint.h | 127 + include/linux/ucb1400.h | 161 + include/linux/usb.h | 8 +- include/linux/usb/Kbuild | 2 +- include/linux/usb/cdc.h | 9 + include/linux/usb/composite.h | 11 +- include/linux/usb/ehci_def.h | 160 + include/linux/usb/tmc.h | 43 + include/linux/videodev2.h | 32 +- include/math-emu/op-2.h | 2 +- include/math-emu/op-common.h | 12 +- include/math-emu/soft-fp.h | 19 + include/media/ir-common.h | 6 + include/media/saa7146.h | 2 +- include/media/sh_mobile_ceu.h | 2 - include/media/soc_camera.h | 3 + include/media/tuner.h | 1 + include/media/v4l2-chip-ident.h | 5 + include/media/v4l2-common.h | 3 + include/media/v4l2-dev.h | 65 +- include/net/9p/9p.h | 1 + include/net/9p/transport.h | 9 +- include/net/bluetooth/hci_core.h | 7 +- include/net/cfg80211.h | 23 + include/net/cipso_ipv4.h | 55 +- include/net/inet_connection_sock.h | 2 + include/net/ip_vs.h | 2 + include/net/mac80211.h | 31 +- include/net/netlabel.h | 50 +- include/net/netlink.h | 82 - include/net/scm.h | 4 +- include/net/sock.h | 2 + include/net/syncppp.h | 102 - include/pcmcia/ciscode.h | 2 +- include/pcmcia/cistpl.h | 18 +- include/pcmcia/cs.h | 92 +- include/pcmcia/cs_types.h | 8 - include/pcmcia/device_id.h | 18 +- include/pcmcia/ds.h | 318 +- include/pcmcia/ss.h | 202 +- include/scsi/scsi.h | 14 + include/scsi/scsi_cmnd.h | 3 - include/scsi/scsi_host.h | 9 +- include/scsi/scsi_transport.h | 3 +- include/sound/ad1848.h | 218 - include/sound/asound.h | 3 +- include/sound/asoundef.h | 89 +- include/sound/core.h | 33 +- include/sound/cs4231.h | 175 - include/sound/jack.h | 75 + include/sound/memalloc.h | 18 +- include/sound/minors.h | 2 + include/sound/pcm.h | 39 +- include/sound/sb.h | 5 + include/sound/snd_wavefront.h | 1 - include/sound/soc-of-simple.h | 25 + include/sound/soc.h | 74 +- include/sound/tea575x-tuner.h | 1 + include/sound/version.h | 2 +- include/sound/vx_core.h | 9 - include/sound/wss.h | 235 + include/trace/sched.h | 56 + include/video/atmel_lcdc.h | 1 + include/video/metronomefb.h | 31 +- include/xen/events.h | 2 + init/Kconfig | 32 +- init/Makefile | 2 +- init/do_mounts.c | 6 + init/do_mounts_md.c | 9 + init/dyn_array.c | 124 + init/initramfs.c | 71 +- init/main.c | 115 +- ipc/mqueue.c | 19 +- ipc/shm.c | 9 +- ipc/util.c | 18 +- kernel/Makefile | 7 +- kernel/acct.c | 7 +- kernel/audit_tree.c | 48 +- kernel/auditsc.c | 57 +- kernel/backtracetest.c | 91 - kernel/capability.c | 268 +- kernel/cgroup.c | 17 +- kernel/cpuset.c | 312 +- kernel/cred-internals.h | 26 + kernel/cred.c | 591 ++ kernel/dma-coherent.c | 2 + kernel/exit.c | 38 +- kernel/extable.c | 16 + kernel/fork.c | 69 +- kernel/futex.c | 20 +- kernel/futex_compat.c | 7 +- kernel/hrtimer.c | 11 +- kernel/irq/autoprobe.c | 30 +- kernel/irq/chip.c | 100 +- kernel/irq/handle.c | 274 +- kernel/irq/internals.h | 4 +- kernel/irq/manage.c | 91 +- kernel/irq/migration.c | 14 +- kernel/irq/proc.c | 44 +- kernel/irq/resend.c | 6 +- kernel/irq/spurious.c | 147 +- kernel/kmod.c | 32 +- kernel/kthread.c | 5 + kernel/lockdep.c | 4 +- kernel/module.c | 125 +- kernel/notifier.c | 8 +- kernel/panic.c | 12 +- kernel/posix-timers.c | 15 + kernel/printk.c | 22 +- kernel/ptrace.c | 29 +- kernel/rcuclassic.c | 331 +- kernel/rcupreempt.c | 8 - kernel/rcupreempt_trace.c | 7 +- kernel/rcutorture.c | 1157 --- kernel/rtmutex-tester.c | 443 - kernel/sched.c | 277 +- kernel/sched_clock.c | 8 + kernel/sched_rt.c | 5 +- kernel/signal.c | 63 +- kernel/softirq.c | 11 + kernel/softlockup.c | 2 +- kernel/sys.c | 579 +- kernel/sys_ni.c | 1 + kernel/sysctl.c | 54 +- kernel/test_kprobes.c | 228 - kernel/time/clocksource.c | 3 + kernel/time/jiffies.c | 1 + kernel/time/ntp.c | 76 +- kernel/time/tick-sched.c | 13 +- kernel/time/timekeeping.c | 113 +- kernel/timer.c | 20 +- kernel/trace/Kconfig | 9 + kernel/trace/ftrace.c | 246 +- kernel/trace/trace.c | 739 ++- kernel/trace/trace.h | 28 +- kernel/trace/trace_mmiotrace.c | 12 +- kernel/trace/trace_sched_switch.c | 120 +- kernel/trace/trace_sched_wakeup.c | 135 +- kernel/trace/trace_selftest.c | 11 +- kernel/tracepoint.c | 476 + kernel/tsacct.c | 6 +- kernel/uid16.c | 31 +- kernel/user.c | 41 +- kernel/user_namespace.c | 14 +- kernel/workqueue.c | 8 +- lib/Kconfig.debug | 185 +- lib/Makefile | 5 +- lib/cmdline.c | 2 +- lib/dynamic_printk.c | 418 + lib/is_single_threaded.c | 45 + lib/klist.c | 96 +- lib/kobject.c | 85 +- lib/locking-selftest-hardirq.h | 9 - lib/locking-selftest-mutex.h | 11 - lib/locking-selftest-rlock-hardirq.h | 2 - lib/locking-selftest-rlock-softirq.h | 2 - lib/locking-selftest-rlock.h | 14 - lib/locking-selftest-rsem.h | 14 - lib/locking-selftest-softirq.h | 9 - lib/locking-selftest-spin-hardirq.h | 2 - lib/locking-selftest-spin-softirq.h | 2 - lib/locking-selftest-spin.h | 11 - lib/locking-selftest-wlock-hardirq.h | 2 - lib/locking-selftest-wlock-softirq.h | 2 - lib/locking-selftest-wlock.h | 14 - lib/locking-selftest-wsem.h | 14 - lib/locking-selftest.c | 1218 --- lib/vsprintf.c | 2 +- localversion-next | 1 + mm/Makefile | 3 +- mm/bounce.c | 2 +- mm/filemap.c | 15 +- mm/highmem.c | 5 +- mm/kmemcheck.c | 97 + mm/kmemtrace.c | 335 + mm/mempolicy.c | 9 +- mm/migrate.c | 11 +- mm/oom_kill.c | 6 +- mm/shmem.c | 8 +- mm/slab.c | 180 +- mm/slob.c | 37 +- mm/slub.c | 537 +- mm/vmscan.c | 64 +- mm/vmstat.c | 4 +- net/9p/client.c | 12 +- net/9p/mod.c | 92 +- net/9p/trans_fd.c | 340 +- net/9p/trans_virtio.c | 23 +- net/Kconfig | 8 +- net/ax25/af_ax25.c | 2 +- net/ax25/ax25_route.c | 2 +- net/bluetooth/af_bluetooth.c | 8 +- net/bluetooth/hci_core.c | 2 +- net/bluetooth/hidp/core.c | 214 +- net/bluetooth/hidp/hidp.h | 2 + net/bridge/netfilter/ebtables.c | 15 +- net/can/af_can.c | 4 +- net/core/dev.c | 10 +- net/core/rtnetlink.c | 4 +- net/core/scm.c | 10 +- net/dccp/ccid.c | 2 +- net/dccp/ccids/ccid2.c | 2 +- net/dccp/ccids/ccid3.c | 2 +- net/dccp/ccids/lib/loss_interval.c | 6 +- net/dccp/ccids/lib/tfrc.c | 2 +- net/dccp/input.c | 4 +- net/dccp/options.c | 13 +- net/dccp/proto.c | 4 +- net/decnet/dn_dev.c | 2 - net/ieee80211/ieee80211_module.c | 8 +- net/ipv4/cipso_ipv4.c | 609 +- net/ipv4/devinet.c | 2 - net/ipv4/inet_diag.c | 8 +- net/ipv4/ip_options.c | 2 +- net/ipv4/ipvs/Kconfig | 6 + net/ipv4/ipvs/Makefile | 3 +- net/ipv4/ipvs/ip_vs_core.c | 8 +- net/ipv4/ipvs/ip_vs_ctl.c | 896 ++- net/ipv4/ipvs/ip_vs_est.c | 18 +- net/ipv4/ipvs/ip_vs_lblc.c | 213 +- net/ipv4/ipvs/ip_vs_lblcr.c | 238 +- net/ipv4/ipvs/ip_vs_lc.c | 21 - net/ipv4/ipvs/ip_vs_nq.c | 24 - net/ipv4/ipvs/ip_vs_proto_ah.c | 178 - net/ipv4/ipvs/ip_vs_proto_ah_esp.c | 203 + net/ipv4/ipvs/ip_vs_proto_esp.c | 176 - net/ipv4/ipvs/ip_vs_rr.c | 7 - net/ipv4/ipvs/ip_vs_sed.c | 24 - net/ipv4/ipvs/ip_vs_wlc.c | 24 - net/ipv4/netfilter/ipt_LOG.c | 4 +- net/ipv4/route.c | 14 +- net/ipv4/tcp_cong.c | 4 +- net/ipv4/tcp_input.c | 208 +- net/ipv4/tcp_ipv4.c | 26 +- net/ipv6/ip6_flowlabel.c | 2 +- net/ipv6/netfilter/ip6t_LOG.c | 4 +- net/mac80211/cfg.c | 63 +- net/mac80211/debugfs_sta.c | 2 +- net/mac80211/event.c | 5 +- net/mac80211/ieee80211_i.h | 121 +- net/mac80211/iface.c | 8 +- net/mac80211/main.c | 86 +- net/mac80211/mesh.c | 29 +- net/mac80211/mesh.h | 61 +- net/mac80211/mesh_hwmp.c | 120 +- net/mac80211/mesh_pathtbl.c | 76 +- net/mac80211/mesh_plink.c | 56 +- net/mac80211/mlme.c | 1082 ++-- net/mac80211/rx.c | 140 +- net/mac80211/tx.c | 46 +- net/mac80211/util.c | 46 +- net/mac80211/wep.c | 14 +- net/mac80211/wext.c | 53 +- net/mac80211/wme.c | 2 - net/mac80211/wme.h | 2 - net/mac80211/wpa.c | 2 +- net/netfilter/nf_conntrack_pptp.c | 2 +- net/netfilter/nfnetlink.c | 2 +- net/netfilter/nfnetlink_log.c | 5 +- net/netfilter/xt_owner.c | 16 +- net/netlabel/Makefile | 3 +- net/netlabel/netlabel_addrlist.c | 388 + net/netlabel/netlabel_addrlist.h | 189 + net/netlabel/netlabel_cipso_v4.c | 132 +- net/netlabel/netlabel_cipso_v4.h | 10 +- net/netlabel/netlabel_domainhash.c | 377 +- net/netlabel/netlabel_domainhash.h | 40 +- net/netlabel/netlabel_kapi.c | 270 +- net/netlabel/netlabel_mgmt.c | 399 +- net/netlabel/netlabel_mgmt.h | 59 +- net/netlabel/netlabel_unlabeled.c | 425 +- net/netlink/af_netlink.c | 2 +- net/netrom/af_netrom.c | 4 +- net/rfkill/rfkill-input.h | 1 + net/rfkill/rfkill.c | 238 +- net/rose/af_rose.c | 4 +- net/rxrpc/ar-key.c | 6 +- net/sched/act_api.c | 2 +- net/sched/cls_api.c | 2 +- net/sched/cls_flow.c | 4 +- net/sched/ematch.c | 2 +- net/sched/sch_api.c | 2 +- net/sched/sch_netem.c | 18 +- net/sched/sch_prio.c | 6 +- net/socket.c | 6 +- net/sunrpc/auth.c | 16 +- net/sunrpc/rpcb_clnt.c | 65 +- net/sunrpc/svc.c | 174 +- net/sunrpc/svc_xprt.c | 39 +- net/sunrpc/svcsock.c | 13 + net/unix/af_unix.c | 29 +- net/wireless/nl80211.c | 62 + net/wireless/wext.c | 2 +- samples/Kconfig | 6 + samples/Makefile | 2 +- samples/tracepoints/Makefile | 6 + samples/tracepoints/tp-samples-trace.h | 13 + samples/tracepoints/tracepoint-probe-sample.c | 55 + samples/tracepoints/tracepoint-probe-sample2.c | 42 + samples/tracepoints/tracepoint-sample.c | 53 + scripts/Makefile | 3 +- scripts/Makefile.build | 6 + scripts/Makefile.lib | 11 +- scripts/basic/Makefile | 2 +- scripts/basic/hash.c | 64 + scripts/kernel-doc | 6 +- scripts/mod/file2alias.c | 18 + scripts/recordmcount.pl | 395 + scripts/selinux/Makefile | 2 + scripts/selinux/README | 2 + scripts/selinux/install_policy.sh | 69 + scripts/selinux/mdp/Makefile | 5 + scripts/selinux/mdp/dbus_contexts | 6 + scripts/selinux/mdp/mdp.c | 242 + security/Kconfig | 8 + security/Makefile | 3 +- security/capability.c | 56 +- security/commoncap.c | 699 +- security/inode.c | 33 +- security/keys/internal.h | 47 +- security/keys/key.c | 25 +- security/keys/keyctl.c | 210 +- security/keys/keyring.c | 15 +- security/keys/permission.c | 29 +- security/keys/proc.c | 8 +- security/keys/process_keys.c | 468 +- security/keys/request_key.c | 133 +- security/keys/request_key_auth.c | 46 +- security/root_plug.c | 13 +- security/security.c | 104 +- security/selinux/avc.c | 2 +- security/selinux/exports.c | 8 +- security/selinux/hooks.c | 1312 ++-- security/selinux/include/av_perm_to_string.h | 2 + security/selinux/include/av_permissions.h | 2 + security/selinux/include/avc.h | 4 + security/selinux/include/class_to_string.h | 5 + security/selinux/include/flask.h | 1 + security/selinux/include/netlabel.h | 34 + security/selinux/include/objsec.h | 20 +- security/selinux/include/security.h | 15 +- security/selinux/netlabel.c | 181 +- security/selinux/selinuxfs.c | 13 +- security/selinux/ss/avtab.c | 8 +- security/selinux/ss/conditional.c | 18 +- security/selinux/ss/conditional.h | 2 +- security/selinux/ss/ebitmap.c | 4 +- security/selinux/ss/hashtab.c | 6 +- security/selinux/ss/mls.c | 14 +- security/selinux/ss/policydb.c | 225 +- security/selinux/ss/policydb.h | 5 + security/selinux/ss/services.c | 193 +- security/selinux/ss/sidtab.c | 12 +- security/selinux/xfrm.c | 6 +- security/smack/smack.h | 1 + security/smack/smack_access.c | 12 +- security/smack/smack_lsm.c | 178 +- security/smack/smackfs.c | 100 +- sound/Kconfig | 5 + sound/aoa/codecs/snd-aoa-codec-tas.c | 6 +- sound/aoa/soundbus/soundbus.h | 2 +- sound/arm/aaci.c | 6 +- sound/arm/sa11xx-uda1341.c | 5 +- sound/core/Kconfig | 7 + sound/core/Makefile | 1 + sound/core/control.c | 50 +- sound/core/control_compat.c | 3 +- sound/core/device.c | 26 +- sound/core/hwdep.c | 16 +- sound/core/info.c | 23 +- sound/core/info_oss.c | 6 +- sound/core/init.c | 9 +- sound/core/jack.c | 163 + sound/core/memalloc.c | 100 +- sound/core/oss/copy.c | 30 +- sound/core/oss/io.c | 24 +- sound/core/oss/linear.c | 29 +- sound/core/oss/mixer_oss.c | 18 +- sound/core/oss/mulaw.c | 27 +- sound/core/oss/pcm_oss.c | 52 +- sound/core/oss/pcm_plugin.c | 38 +- sound/core/oss/rate.c | 42 +- sound/core/oss/route.c | 12 +- sound/core/pcm.c | 84 +- sound/core/pcm_compat.c | 3 +- sound/core/pcm_lib.c | 102 +- sound/core/pcm_memory.c | 40 +- sound/core/pcm_native.c | 140 +- sound/core/pcm_timer.c | 6 +- sound/core/rawmidi.c | 25 +- sound/core/rtctimer.c | 6 +- sound/core/seq/oss/seq_oss.c | 12 +- sound/core/seq/oss/seq_oss_synth.c | 6 +- sound/core/seq/seq_clientmgr.c | 30 +- sound/core/seq/seq_compat.c | 3 +- sound/core/seq/seq_device.c | 6 +- sound/core/seq/seq_fifo.c | 15 +- sound/core/seq/seq_memory.c | 12 +- sound/core/seq/seq_midi.c | 15 +- sound/core/seq/seq_ports.c | 13 +- sound/core/seq/seq_prioq.c | 4 +- sound/core/seq/seq_queue.c | 6 +- sound/core/seq/seq_timer.c | 24 +- sound/core/sgbuf.c | 62 +- sound/core/sound.c | 19 +- sound/core/sound_oss.c | 12 +- sound/core/timer.c | 33 +- sound/core/timer_compat.c | 9 +- sound/drivers/dummy.c | 41 +- sound/drivers/opl3/opl3_lib.c | 6 +- sound/drivers/opl3/opl3_midi.c | 6 +- sound/drivers/opl3/opl3_oss.c | 15 +- sound/drivers/opl3/opl3_synth.c | 3 +- sound/drivers/opl4/opl4_synth.c | 2 +- sound/drivers/vx/vx_cmd.c | 3 +- sound/drivers/vx/vx_core.c | 21 +- sound/drivers/vx/vx_hwdep.c | 6 +- sound/drivers/vx/vx_mixer.c | 3 +- sound/drivers/vx/vx_pcm.c | 9 +- sound/drivers/vx/vx_uer.c | 6 +- sound/i2c/cs8427.c | 15 +- sound/i2c/i2c.c | 6 +- sound/i2c/l3/uda1341.c | 3 +- sound/i2c/other/ak4114.c | 3 +- sound/i2c/other/ak4117.c | 3 +- sound/i2c/other/ak4xxx-adda.c | 4 +- sound/i2c/other/tea575x-tuner.c | 25 +- sound/isa/Kconfig | 54 +- sound/isa/Makefile | 2 +- sound/isa/ad1816a/ad1816a.c | 4 +- sound/isa/ad1816a/ad1816a_lib.c | 6 +- sound/isa/ad1848/Makefile | 2 - sound/isa/ad1848/ad1848.c | 17 +- sound/isa/ad1848/ad1848_lib.c | 1267 --- sound/isa/azt2320.c | 29 +- sound/isa/cmi8330.c | 106 +- sound/isa/cs423x/Makefile | 2 - sound/isa/cs423x/cs4231.c | 18 +- sound/isa/cs423x/cs4231_lib.c | 1945 ---- sound/isa/cs423x/cs4236.c | 51 +- sound/isa/cs423x/cs4236_lib.c | 349 +- sound/isa/es1688/es1688_lib.c | 3 +- sound/isa/gus/gus_main.c | 6 +- sound/isa/gus/gus_mixer.c | 6 +- sound/isa/gus/gus_pcm.c | 12 +- sound/isa/gus/gusmax.c | 50 +- sound/isa/gus/interwave.c | 67 +- sound/isa/opl3sa2.c | 99 +- sound/isa/opti9xx/miro.c | 28 +- sound/isa/opti9xx/opti92x-ad1848.c | 70 +- sound/isa/sb/emu8000.c | 3 +- sound/isa/sb/emu8000_patch.c | 3 +- sound/isa/sb/sb16_csp.c | 9 +- sound/isa/sb/sb16_main.c | 3 +- sound/isa/sb/sb8_main.c | 8 +- sound/isa/sb/sb_common.c | 3 +- sound/isa/sb/sb_mixer.c | 9 +- sound/isa/sc6000.c | 18 +- sound/isa/sgalaxy.c | 43 +- sound/isa/sscape.c | 63 +- sound/isa/wavefront/wavefront.c | 62 +- sound/isa/wavefront/wavefront_fx.c | 24 +- sound/isa/wavefront/wavefront_midi.c | 24 +- sound/isa/wavefront/wavefront_synth.c | 7 +- sound/isa/wavefront/yss225.c | 2739 ------ sound/isa/wss/Makefile | 10 + sound/isa/wss/wss_lib.c | 2322 +++++ sound/mips/au1x00.c | 6 +- sound/oss/Kconfig | 7 - sound/oss/Makefile | 1 - sound/oss/dmasound/Kconfig | 1 + sound/oss/hal2.c | 1558 ---- sound/oss/hal2.h | 248 - sound/oss/mpu401.c | 2 +- sound/oss/soundcard.c | 15 +- sound/parisc/harmony.c | 3 +- sound/pci/Kconfig | 22 +- sound/pci/ac97/ac97_codec.c | 41 +- sound/pci/ac97/ac97_patch.c | 208 +- sound/pci/ad1889.c | 6 +- sound/pci/ak4531_codec.c | 10 +- sound/pci/als4000.c | 391 +- sound/pci/atiixp.c | 13 +- sound/pci/atiixp_modem.c | 10 +- sound/pci/au88x0/au88x0.h | 7 +- sound/pci/au88x0/au88x0_core.c | 40 +- sound/pci/au88x0/au88x0_pcm.c | 14 +- sound/pci/azt3328.c | 6 +- sound/pci/bt87x.c | 5 +- sound/pci/ca0106/ca_midi.c | 20 +- sound/pci/cmipci.c | 9 +- sound/pci/cs4281.c | 13 +- sound/pci/cs46xx/cs46xx_lib.c | 72 +- sound/pci/cs46xx/dsp_spos.c | 51 +- sound/pci/cs46xx/dsp_spos_scb_lib.c | 115 +- sound/pci/echoaudio/darla20_dsp.c | 3 +- sound/pci/echoaudio/darla24_dsp.c | 8 +- sound/pci/echoaudio/echo3g_dsp.c | 9 +- sound/pci/echoaudio/echoaudio.c | 22 +- sound/pci/echoaudio/echoaudio_3g.c | 11 +- sound/pci/echoaudio/echoaudio_dsp.c | 21 +- sound/pci/echoaudio/echoaudio_gml.c | 6 +- sound/pci/echoaudio/gina20_dsp.c | 6 +- sound/pci/echoaudio/gina24_dsp.c | 11 +- sound/pci/echoaudio/indigo_dsp.c | 8 +- sound/pci/echoaudio/indigodj_dsp.c | 8 +- sound/pci/echoaudio/indigoio_dsp.c | 8 +- sound/pci/echoaudio/layla20_dsp.c | 9 +- sound/pci/echoaudio/layla24_dsp.c | 11 +- sound/pci/echoaudio/mia_dsp.c | 13 +- sound/pci/echoaudio/midi.c | 6 +- sound/pci/echoaudio/mona_dsp.c | 6 +- sound/pci/emu10k1/emu10k1_callback.c | 6 +- sound/pci/emu10k1/emu10k1_patch.c | 23 +- sound/pci/emu10k1/emu10k1x.c | 18 +- sound/pci/emu10k1/emufx.c | 6 +- sound/pci/emu10k1/emumpu401.c | 18 +- sound/pci/emu10k1/memory.c | 31 +- sound/pci/emu10k1/voice.c | 9 +- sound/pci/es1938.c | 3 +- sound/pci/es1968.c | 6 +- sound/pci/hda/Makefile | 1 + sound/pci/hda/hda_beep.c | 134 + sound/pci/hda/hda_beep.h | 44 + sound/pci/hda/hda_codec.c | 29 +- sound/pci/hda/hda_codec.h | 92 +- sound/pci/hda/hda_generic.c | 3 +- sound/pci/hda/hda_intel.c | 105 +- sound/pci/hda/hda_proc.c | 23 +- sound/pci/hda/patch_analog.c | 80 +- sound/pci/hda/patch_atihdmi.c | 45 +- sound/pci/hda/patch_realtek.c | 1788 ++++- sound/pci/hda/patch_sigmatel.c | 485 +- sound/pci/ice1712/ak4xxx.c | 3 +- sound/pci/ice1712/aureon.c | 22 +- sound/pci/ice1712/delta.h | 1 + sound/pci/ice1712/ews.c | 9 +- sound/pci/ice1712/ice1712.c | 3 +- sound/pci/ice1712/ice1724.c | 8 +- sound/pci/ice1712/juli.c | 3 +- sound/pci/ice1712/phase.c | 35 +- sound/pci/ice1712/phase.h | 4 +- sound/pci/ice1712/revo.c | 17 +- sound/pci/intel8x0.c | 44 +- sound/pci/intel8x0m.c | 3 +- sound/pci/korg1212/korg1212.c | 9 +- sound/pci/maestro3.c | 10 +- sound/pci/mixart/mixart.c | 4 +- sound/pci/mixart/mixart_core.c | 18 +- sound/pci/mixart/mixart_hwdep.c | 19 +- sound/pci/mixart/mixart_mixer.c | 8 +- sound/pci/nm256/nm256.c | 15 +- sound/pci/pcxhr/pcxhr.c | 6 +- sound/pci/pcxhr/pcxhr_core.c | 27 +- sound/pci/pcxhr/pcxhr_hwdep.c | 15 +- sound/pci/riptide/riptide.c | 31 +- sound/pci/rme9652/hdsp.c | 25 +- sound/pci/rme9652/hdspm.c | 52 +- sound/pci/rme9652/rme9652.c | 23 +- sound/pci/sonicvibes.c | 10 +- sound/pci/trident/trident_main.c | 22 +- sound/pci/trident/trident_memory.c | 37 +- sound/pci/via82xx.c | 60 +- sound/pci/via82xx_modem.c | 8 +- sound/pci/vx222/vx222_ops.c | 12 +- sound/pci/ymfpci/ymfpci_main.c | 21 +- sound/pcmcia/vx/vxp_ops.c | 3 +- sound/ppc/awacs.c | 73 +- sound/ppc/beep.c | 6 +- sound/ppc/tumbler.c | 17 +- sound/sh/aica.c | 3 +- sound/soc/at91/at91-ssc.c | 2 +- sound/soc/at91/eti_b1_wm8731.c | 1 + sound/soc/codecs/Kconfig | 43 + sound/soc/codecs/Makefile | 10 + sound/soc/codecs/ad1980.c | 309 + sound/soc/codecs/ad1980.h | 23 + sound/soc/codecs/ak4535.c | 116 +- sound/soc/codecs/ak4535.h | 1 + sound/soc/codecs/cs4270.c | 71 +- sound/soc/codecs/tlv320aic26.c | 520 ++ sound/soc/codecs/tlv320aic26.h | 96 + sound/soc/codecs/uda1380.c | 115 +- sound/soc/codecs/uda1380.h | 1 + sound/soc/codecs/wm8580.c | 1055 +++ sound/soc/codecs/wm8580.h | 42 + sound/soc/codecs/wm8731.c | 177 +- sound/soc/codecs/wm8731.h | 2 + sound/soc/codecs/wm8750.c | 111 +- sound/soc/codecs/wm8750.h | 1 + sound/soc/codecs/wm8900.c | 1542 ++++ sound/soc/codecs/wm8900.h | 64 + sound/soc/codecs/wm8903.c | 1813 ++++ sound/soc/codecs/wm8903.h | 1463 +++ sound/soc/codecs/wm8990.c | 109 +- sound/soc/codecs/wm8990.h | 1 + sound/soc/davinci/davinci-i2s.c | 2 +- sound/soc/fsl/Kconfig | 10 + sound/soc/fsl/Makefile | 5 + sound/soc/fsl/mpc5200_psc_i2s.c | 884 ++ sound/soc/fsl/mpc8610_hpcd.c | 26 +- sound/soc/fsl/soc-of-simple.c | 171 + sound/soc/pxa/corgi.c | 1 + sound/soc/pxa/poodle.c | 1 + sound/soc/pxa/pxa2xx-pcm.c | 4 +- sound/soc/pxa/spitz.c | 1 + sound/soc/s3c24xx/s3c2443-ac97.c | 11 +- sound/soc/soc-core.c | 132 +- sound/soc/soc-dapm.c | 119 +- sound/sound_core.c | 84 +- sound/sparc/amd7930.c | 104 +- sound/sparc/cs4231.c | 202 +- sound/sparc/dbri.c | 106 +- sound/synth/emux/emux.c | 8 +- sound/synth/emux/emux_nrpn.c | 8 +- sound/synth/emux/emux_oss.c | 42 +- sound/synth/emux/emux_seq.c | 15 +- sound/synth/emux/emux_synth.c | 47 +- sound/synth/util_mem.c | 10 +- sound/usb/Kconfig | 11 + sound/usb/Makefile | 1 + sound/usb/usbaudio.c | 19 +- sound/usb/usbaudio.h | 4 +- sound/usb/usbmidi.c | 39 + sound/usb/usbmixer.c | 19 +- sound/usb/usbquirks.h | 31 +- sound/usb/usx2y/Makefile | 2 + sound/usb/usx2y/us122l.c | 692 ++ sound/usb/usx2y/us122l.h | 27 + sound/usb/usx2y/usb_stream.c | 761 ++ sound/usb/usx2y/usb_stream.h | 112 + tests/Kconfig | 101 + tests/Makefile | 10 + tests/backtracetest.c | 91 + tests/lkdtm.c | 345 + tests/locking-selftest-hardirq.h | 9 + tests/locking-selftest-mutex.h | 11 + tests/locking-selftest-rlock-hardirq.h | 2 + tests/locking-selftest-rlock-softirq.h | 2 + tests/locking-selftest-rlock.h | 14 + tests/locking-selftest-rsem.h | 14 + tests/locking-selftest-softirq.h | 9 + tests/locking-selftest-spin-hardirq.h | 2 + tests/locking-selftest-spin-softirq.h | 2 + tests/locking-selftest-spin.h | 11 + tests/locking-selftest-wlock-hardirq.h | 2 + tests/locking-selftest-wlock-softirq.h | 2 + tests/locking-selftest-wlock.h | 14 + tests/locking-selftest-wsem.h | 14 + tests/locking-selftest.c | 1218 +++ tests/rcutorture.c | 1157 +++ tests/rtmutex-tester.c | 443 + tests/test_kprobes.c | 228 + virt/kvm/ioapic.c | 22 +- virt/kvm/ioapic.h | 3 +- virt/kvm/kvm_main.c | 70 +- virt/kvm/kvm_trace.c | 30 +- 3769 files changed, 221672 insertions(+), 141987 deletions(-) diff --git a/Documentation/00-INDEX b/Documentation/00-INDEX index 5b5aba4..7b2e518 100644 --- a/Documentation/00-INDEX +++ b/Documentation/00-INDEX @@ -159,8 +159,6 @@ hayes-esp.txt - info on using the Hayes ESP serial driver. highuid.txt - notes on the change from 16 bit to 32 bit user/group IDs. -hpet.txt - - High Precision Event Timer Driver for Linux. timers/ - info on the timer related topics hw_random.txt @@ -177,8 +175,6 @@ ia64/ - directory with info about Linux on Intel 64 bit architecture. infiniband/ - directory with documents concerning Linux InfiniBand support. -initrd.txt - - how to use the RAM disk as an initial/temporary root filesystem. input/ - info on Linux input device support. io_ordering.txt @@ -251,8 +247,6 @@ mono.txt - how to execute Mono-based .NET binaries with the help of BINFMT_MISC. moxa-smartio - file with info on installing/using Moxa multiport serial driver. -mtrr.txt - - how to use PPro Memory Type Range Registers to increase performance. mutex-design.txt - info on the generic mutex subsystem. namespaces/ diff --git a/Documentation/ABI/stable/sysfs-driver-usb-usbtmc b/Documentation/ABI/stable/sysfs-driver-usb-usbtmc new file mode 100644 index 0000000..9a75fb2 --- /dev/null +++ b/Documentation/ABI/stable/sysfs-driver-usb-usbtmc @@ -0,0 +1,62 @@ +What: /sys/bus/usb/drivers/usbtmc/devices/*/interface_capabilities +What: /sys/bus/usb/drivers/usbtmc/devices/*/device_capabilities +Date: August 2008 +Contact: Greg Kroah-Hartman +Description: + These files show the various USB TMC capabilities as described + by the device itself. The full description of the bitfields + can be found in the USB TMC documents from the USB-IF entitled + "Universal Serial Bus Test and Measurement Class Specification + (USBTMC) Revision 1.0" section 4.2.1.8. + + The files are read only. + + +What: /sys/bus/usb/drivers/usbtmc/devices/*/usb488_interface_capabilities +What: /sys/bus/usb/drivers/usbtmc/devices/*/usb488_device_capabilities +Date: August 2008 +Contact: Greg Kroah-Hartman +Description: + These files show the various USB TMC capabilities as described + by the device itself. The full description of the bitfields + can be found in the USB TMC documents from the USB-IF entitled + "Universal Serial Bus Test and Measurement Class, Subclass + USB488 Specification (USBTMC-USB488) Revision 1.0" section + 4.2.2. + + The files are read only. + + +What: /sys/bus/usb/drivers/usbtmc/devices/*/TermChar +Date: August 2008 +Contact: Greg Kroah-Hartman +Description: + This file is the TermChar value to be sent to the USB TMC + device as described by the document, "Universal Serial Bus Test + and Measurement Class Specification + (USBTMC) Revision 1.0" as published by the USB-IF. + + Note that the TermCharEnabled file determines if this value is + sent to the device or not. + + +What: /sys/bus/usb/drivers/usbtmc/devices/*/TermCharEnabled +Date: August 2008 +Contact: Greg Kroah-Hartman +Description: + This file determines if the TermChar is to be sent to the + device on every transaction or not. For more details about + this, please see the document, "Universal Serial Bus Test and + Measurement Class Specification (USBTMC) Revision 1.0" as + published by the USB-IF. + + +What: /sys/bus/usb/drivers/usbtmc/devices/*/auto_abort +Date: August 2008 +Contact: Greg Kroah-Hartman +Description: + This file determines if the the transaction of the USB TMC + device is to be automatically aborted if there is any error. + For more details about this, please see the document, + "Universal Serial Bus Test and Measurement Class Specification + (USBTMC) Revision 1.0" as published by the USB-IF. diff --git a/Documentation/ABI/testing/debugfs-kmemtrace b/Documentation/ABI/testing/debugfs-kmemtrace new file mode 100644 index 0000000..5e6a92a --- /dev/null +++ b/Documentation/ABI/testing/debugfs-kmemtrace @@ -0,0 +1,71 @@ +What: /sys/kernel/debug/kmemtrace/ +Date: July 2008 +Contact: Eduard - Gabriel Munteanu +Description: + +In kmemtrace-enabled kernels, the following files are created: + +/sys/kernel/debug/kmemtrace/ + cpu (0400) Per-CPU tracing data, see below. (binary) + total_overruns (0400) Total number of bytes which were dropped from + cpu files because of full buffer condition, + non-binary. (text) + abi_version (0400) Kernel's kmemtrace ABI version. (text) + +Each per-CPU file should be read according to the relay interface. That is, +the reader should set affinity to that specific CPU and, as currently done by +the userspace application (though there are other methods), use poll() with +an infinite timeout before every read(). Otherwise, erroneous data may be +read. The binary data has the following _core_ format: + + Event ID (1 byte) Unsigned integer, one of: + 0 - represents an allocation (KMEMTRACE_EVENT_ALLOC) + 1 - represents a freeing of previously allocated memory + (KMEMTRACE_EVENT_FREE) + Type ID (1 byte) Unsigned integer, one of: + 0 - this is a kmalloc() / kfree() + 1 - this is a kmem_cache_alloc() / kmem_cache_free() + 2 - this is a __get_free_pages() et al. + Event size (2 bytes) Unsigned integer representing the + size of this event. Used to extend + kmemtrace. Discard the bytes you + don't know about. + Sequence number (4 bytes) Signed integer used to reorder data + logged on SMP machines. Wraparound + must be taken into account, although + it is unlikely. + Caller address (8 bytes) Return address to the caller. + Pointer to mem (8 bytes) Pointer to target memory area. Can be + NULL, but not all such calls might be + recorded. + +In case of KMEMTRACE_EVENT_ALLOC events, the next fields follow: + + Requested bytes (8 bytes) Total number of requested bytes, + unsigned, must not be zero. + Allocated bytes (8 bytes) Total number of actually allocated + bytes, unsigned, must not be lower + than requested bytes. + Requested flags (4 bytes) GFP flags supplied by the caller. + Target CPU (4 bytes) Signed integer, valid for event id 1. + If equal to -1, target CPU is the same + as origin CPU, but the reverse might + not be true. + +The data is made available in the same endianness the machine has. + +Other event ids and type ids may be defined and added. Other fields may be +added by increasing event size, but see below for details. +Every modification to the ABI, including new id definitions, are followed +by bumping the ABI version by one. + +Adding new data to the packet (features) is done at the end of the mandatory +data: + Feature size (2 byte) + Feature ID (1 byte) + Feature data (Feature size - 3 bytes) + + +Users: + kmemtrace-user - git://repo.or.cz/kmemtrace-user.git + diff --git a/Documentation/ABI/testing/sysfs-bus-usb-devices-usbsevseg b/Documentation/ABI/testing/sysfs-bus-usb-devices-usbsevseg new file mode 100644 index 0000000..cb830df --- /dev/null +++ b/Documentation/ABI/testing/sysfs-bus-usb-devices-usbsevseg @@ -0,0 +1,43 @@ +Where: /sys/bus/usb/.../powered +Date: August 2008 +Kernel Version: 2.6.26 +Contact: Harrison Metzger +Description: Controls whether the device's display will powered. + A value of 0 is off and a non-zero value is on. + +Where: /sys/bus/usb/.../mode_msb +Where: /sys/bus/usb/.../mode_lsb +Date: August 2008 +Kernel Version: 2.6.26 +Contact: Harrison Metzger +Description: Controls the devices display mode. + For a 6 character display the values are + MSB 0x06; LSB 0x3F, and + for an 8 character display the values are + MSB 0x08; LSB 0xFF. + +Where: /sys/bus/usb/.../textmode +Date: August 2008 +Kernel Version: 2.6.26 +Contact: Harrison Metzger +Description: Controls the way the device interprets its text buffer. + raw: each character controls its segment manually + hex: each character is between 0-15 + ascii: each character is between '0'-'9' and 'A'-'F'. + +Where: /sys/bus/usb/.../text +Date: August 2008 +Kernel Version: 2.6.26 +Contact: Harrison Metzger +Description: The text (or data) for the device to display + +Where: /sys/bus/usb/.../decimals +Date: August 2008 +Kernel Version: 2.6.26 +Contact: Harrison Metzger +Description: Controls the decimal places on the device. + To set the nth decimal place, give this field + the value of 10 ** n. Assume this field has + the value k and has 1 or more decimal places set, + to set the mth place (where m is not already set), + change this fields value to k + 10 ** m. \ No newline at end of file diff --git a/Documentation/DocBook/Makefile b/Documentation/DocBook/Makefile index 1615350..69f4a93 100644 --- a/Documentation/DocBook/Makefile +++ b/Documentation/DocBook/Makefile @@ -6,7 +6,7 @@ # To add a new book the only step required is to add the book to the # list of DOCBOOKS. -DOCBOOKS := wanbook.xml z8530book.xml mcabook.xml videobook.xml \ +DOCBOOKS := z8530book.xml mcabook.xml videobook.xml \ kernel-hacking.xml kernel-locking.xml deviceiobook.xml \ procfs-guide.xml writing_usb_driver.xml networking.xml \ kernel-api.xml filesystems.xml lsm.xml usb.xml kgdb.xml \ diff --git a/Documentation/DocBook/gadget.tmpl b/Documentation/DocBook/gadget.tmpl index ea3bc95..6ef2f00 100644 --- a/Documentation/DocBook/gadget.tmpl +++ b/Documentation/DocBook/gadget.tmpl @@ -557,6 +557,9 @@ Near-term plans include converting all of them, except for "gadgetfs". !Edrivers/usb/gadget/f_acm.c +!Edrivers/usb/gadget/f_ecm.c +!Edrivers/usb/gadget/f_subset.c +!Edrivers/usb/gadget/f_obex.c !Edrivers/usb/gadget/f_serial.c diff --git a/Documentation/DocBook/kernel-api.tmpl b/Documentation/DocBook/kernel-api.tmpl index b7b1482..9d0058e 100644 --- a/Documentation/DocBook/kernel-api.tmpl +++ b/Documentation/DocBook/kernel-api.tmpl @@ -283,6 +283,7 @@ X!Earch/x86/kernel/mca_32.c Security Framework !Isecurity/security.c +!Esecurity/inode.c @@ -364,6 +365,10 @@ X!Edrivers/pnp/system.c !Eblock/blk-barrier.c !Eblock/blk-tag.c !Iblock/blk-tag.c +!Eblock/blk-integrity.c +!Iblock/blktrace.c +!Iblock/genhd.c +!Eblock/genhd.c diff --git a/Documentation/DocBook/networking.tmpl b/Documentation/DocBook/networking.tmpl index f24f9e8..627707a 100644 --- a/Documentation/DocBook/networking.tmpl +++ b/Documentation/DocBook/networking.tmpl @@ -98,9 +98,6 @@ X!Enet/core/wireless.c --> - Synchronous PPP -!Edrivers/net/wan/syncppp.c - diff --git a/Documentation/DocBook/wanbook.tmpl b/Documentation/DocBook/wanbook.tmpl deleted file mode 100644 index 9eebcc3..0000000 --- a/Documentation/DocBook/wanbook.tmpl +++ /dev/null @@ -1,99 +0,0 @@ - - - - - - Synchronous PPP and Cisco HDLC Programming Guide - - - - Alan - Cox - -
- alan@redhat.com -
-
-
-
- - - 2000 - Alan Cox - - - - - This documentation is free software; you can redistribute - it and/or modify it under the terms of the GNU General Public - License as published by the Free Software Foundation; either - version 2 of the License, or (at your option) any later - version. - - - - This program is distributed in the hope that it will be - useful, but WITHOUT ANY WARRANTY; without even the implied - warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. - See the GNU General Public License for more details. - - - - You should have received a copy of the GNU General Public - License along with this program; if not, write to the Free - Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, - MA 02111-1307 USA - - - - For more details see the file COPYING in the source - distribution of Linux. - - -
- - - - - Introduction - - The syncppp drivers in Linux provide a fairly complete - implementation of Cisco HDLC and a minimal implementation of - PPP. The longer term goal is to switch the PPP layer to the - generic PPP interface that is new in Linux 2.3.x. The API should - remain unchanged when this is done, but support will then be - available for IPX, compression and other PPP features - - - - Known Bugs And Assumptions - - - PPP is minimal - - - The current PPP implementation is very basic, although sufficient - for most wan usages. - - - - Cisco HDLC Quirks - - - Currently we do not end all packets with the correct Cisco multicast - or unicast flags. Nothing appears to mind too much but this should - be corrected. - - - - - - - - - Public Functions Provided -!Edrivers/net/wan/syncppp.c - - -
diff --git a/Documentation/Makefile b/Documentation/Makefile index 94b9457..c1d9dd1 100644 --- a/Documentation/Makefile +++ b/Documentation/Makefile @@ -1,3 +1,3 @@ obj-m := DocBook/ accounting/ auxdisplay/ connector/ \ - filesystems/configfs/ ia64/ networking/ \ + filesystems/ filesystems/configfs/ ia64/ networking/ \ pcmcia/ spi/ video4linux/ vm/ watchdog/src/ diff --git a/Documentation/PCI/pci.txt b/Documentation/PCI/pci.txt index 8d4dc62..fd4907a 100644 --- a/Documentation/PCI/pci.txt +++ b/Documentation/PCI/pci.txt @@ -163,6 +163,10 @@ need pass only as many optional fields as necessary: o class and classmask fields default to 0 o driver_data defaults to 0UL. +Note that driver_data must match the value used by any of the pci_device_id +entries defined in the driver. This makes the driver_data field mandatory +if all the pci_device_id entries have a non-zero driver_data value. + Once added, the driver probe routine will be invoked for any unclaimed PCI devices listed in its (newly updated) pci_ids list. diff --git a/Documentation/RCU/checklist.txt b/Documentation/RCU/checklist.txt index cf5562c..6e25340 100644 --- a/Documentation/RCU/checklist.txt +++ b/Documentation/RCU/checklist.txt @@ -210,7 +210,7 @@ over a rather long period of time, but improvements are always welcome! number of updates per grace period. 9. All RCU list-traversal primitives, which include - rcu_dereference(), list_for_each_rcu(), list_for_each_entry_rcu(), + rcu_dereference(), list_for_each_entry_rcu(), list_for_each_continue_rcu(), and list_for_each_safe_rcu(), must be either within an RCU read-side critical section or must be protected by appropriate update-side locks. RCU diff --git a/Documentation/RCU/whatisRCU.txt b/Documentation/RCU/whatisRCU.txt index e04d643..9617082 100644 --- a/Documentation/RCU/whatisRCU.txt +++ b/Documentation/RCU/whatisRCU.txt @@ -786,8 +786,6 @@ RCU pointer/list traversal: list_for_each_entry_rcu hlist_for_each_entry_rcu - list_for_each_rcu (to be deprecated in favor of - list_for_each_entry_rcu) list_for_each_continue_rcu (to be deprecated in favor of new list_for_each_entry_continue_rcu) diff --git a/Documentation/SELinux.txt b/Documentation/SELinux.txt new file mode 100644 index 0000000..07eae00 --- /dev/null +++ b/Documentation/SELinux.txt @@ -0,0 +1,27 @@ +If you want to use SELinux, chances are you will want +to use the distro-provided policies, or install the +latest reference policy release from + http://oss.tresys.com/projects/refpolicy + +However, if you want to install a dummy policy for +testing, you can do using 'mdp' provided under +scripts/selinux. Note that this requires the selinux +userspace to be installed - in particular you will +need checkpolicy to compile a kernel, and setfiles and +fixfiles to label the filesystem. + + 1. Compile the kernel with selinux enabled. + 2. Type 'make' to compile mdp. + 3. Make sure that you are not running with + SELinux enabled and a real policy. If + you are, reboot with selinux disabled + before continuing. + 4. Run install_policy.sh: + cd scripts/selinux + sh install_policy.sh + +Step 4 will create a new dummy policy valid for your +kernel, with a single selinux user, role, and type. +It will compile the policy, will set your SELINUXTYPE to +dummy in /etc/selinux/config, install the compiled policy +as 'dummy', and relabel your filesystem. diff --git a/Documentation/block/deadline-iosched.txt b/Documentation/block/deadline-iosched.txt index c23cab1..7257676 100644 --- a/Documentation/block/deadline-iosched.txt +++ b/Documentation/block/deadline-iosched.txt @@ -30,12 +30,18 @@ write_expire (in ms) Similar to read_expire mentioned above, but for writes. -fifo_batch +fifo_batch (number of requests) ---------- -When a read request expires its deadline, we must move some requests from -the sorted io scheduler list to the block device dispatch queue. fifo_batch -controls how many requests we move. +Requests are grouped into ``batches'' of a particular data direction (read or +write) which are serviced in increasing sector order. To limit extra seeking, +deadline expiries are only checked between batches. fifo_batch controls the +maximum number of requests per batch. + +This parameter tunes the balance between per-request latency and aggregate +throughput. When low latency is the primary concern, smaller is better (where +a value of 1 yields first-come first-served behaviour). Increasing fifo_batch +generally improves throughput, at the cost of latency variation. writes_starved (number of dispatches) diff --git a/Documentation/credentials.txt b/Documentation/credentials.txt new file mode 100644 index 0000000..1394106 --- /dev/null +++ b/Documentation/credentials.txt @@ -0,0 +1,582 @@ + ==================== + CREDENTIALS IN LINUX + ==================== + +By: David Howells + +Contents: + + (*) Overview. + + (*) Types of credentials. + + (*) File markings. + + (*) Task credentials. + + - Immutable credentials. + - Accessing task credentials. + - Accessing another task's credentials. + - Altering credentials. + - Managing credentials. + + (*) Open file credentials. + + (*) Overriding the VFS's use of credentials. + + +======== +OVERVIEW +======== + +There are several parts to the security check performed by Linux when one +object acts upon another: + + (1) Objects. + + Objects are things in the system that may be acted upon directly by + userspace programs. Linux has a variety of actionable objects, including: + + - Tasks + - Files/inodes + - Sockets + - Message queues + - Shared memory segments + - Semaphores + - Keys + + As a part of the description of all these objects there is a set of + credentials. What's in the set depends on the type of object. + + (2) Object ownership. + + Amongst the credentials of most objects, there will be a subset that + indicates the ownership of that object. This is used for resource + accounting and limitation (disk quotas and task rlimits for example). + + In a standard UNIX filesystem, for instance, this will be defined by the + UID marked on the inode. + + (3) The objective context. + + Also amongst the credentials of those objects, there will be a subset that + indicates the 'objective context' of that object. This may or may not be + the same set as in (2) - in standard UNIX files, for instance, this is the + defined by the UID and the GID marked on the inode. + + The objective context is used as part of the security calculation that is + carried out when an object is acted upon. + + (4) Subjects. + + A subject is an object that is acting upon another object. + + Most of the objects in the system are inactive: they don't act on other + objects within the system. Processes/tasks are the obvious exception: + they do stuff; they access and manipulate things. + + Objects other than tasks may under some circumstances also be subjects. + For instance an open file may send SIGIO to a task using the UID and EUID + given to it by a task that called fcntl(F_SETOWN) upon it. In this case, + the file struct will have a subjective context too. + + (5) The subjective context. + + A subject has an additional interpretation of its credentials. A subset + of its credentials forms the 'subjective context'. The subjective context + is used as part of the security calculation that is carried out when a + subject acts. + + A Linux task, for example, has the FSUID, FSGID and the supplementary + group list for when it is acting upon a file - which are quite separate + from the real UID and GID that normally form the objective context of the + task. + + (6) Actions. + + Linux has a number of actions available that a subject may perform upon an + object. The set of actions available depends on the nature of the subject + and the object. + + Actions include reading, writing, creating and deleting files; forking or + signalling and tracing tasks. + + (7) Rules, access control lists and security calculations. + + When a subject acts upon an object, a security calculation is made. This + involves taking the subjective context, the objective context and the + action, and searching one or more sets of rules to see whether the subject + is granted or denied permission to act in the desired manner on the + object, given those contexts. + + There are two main sources of rules: + + (a) Discretionary access control (DAC): + + Sometimes the object will include sets of rules as part of its + description. This is an 'Access Control List' or 'ACL'. A Linux file + may supply more than one ACL. + + A traditional UNIX file, for example, includes a permissions mask that + is an abbreviated ACL with three fixed classes of subject ('user', + 'group' and 'other'), each of which may be granted certain privileges + ('read', 'write' and 'execute' - whatever those map to for the object + in question). UNIX file permissions do not allow the arbitrary + specification of subjects, however, and so are of limited use. + + A Linux file might also sport a POSIX ACL. This is a list of rules + that grants various permissions to arbitrary subjects. + + (b) Mandatory access control (MAC): + + The system as a whole may have one or more sets of rules that get + applied to all subjects and objects, regardless of their source. + SELinux and Smack are examples of this. + + In the case of SELinux and Smack, each object is given a label as part + of its credentials. When an action is requested, they take the + subject label, the object label and the action and look for a rule + that says that this action is either granted or denied. + + +==================== +TYPES OF CREDENTIALS +==================== + +The Linux kernel supports the following types of credentials: + + (1) Traditional UNIX credentials. + + Real User ID + Real Group ID + + The UID and GID are carried by most, if not all, Linux objects, even if in + some cases it has to be invented (FAT or CIFS files for example, which are + derived from Windows). These (mostly) define the objective context of + that object, with tasks being slightly different in some cases. + + Effective, Saved and FS User ID + Effective, Saved and FS Group ID + Supplementary groups + + These are additional credentials used by tasks only. Usually, an + EUID/EGID/GROUPS will be used as the subjective context, and real UID/GID + will be used as the objective. For tasks, it should be noted that this is + not always true. + + (2) Capabilities. + + Set of permitted capabilities + Set of inheritable capabilities + Set of effective capabilities + Capability bounding set + + These are only carried by tasks. They indicate superior capabilities + granted piecemeal to a task that an ordinary task wouldn't otherwise have. + These are manipulated implicitly by changes to the traditional UNIX + credentials, but can also be manipulated directly by the capset() system + call. + + The permitted capabilities are those caps that the process might grant + itself to its effective or permitted sets through capset(). This + inheritable set might also be so constrained. + + The effective capabilities are the ones that a task is actually allowed to + make use of itself. + + The inheritable capabilities are the ones that may get passed across + execve(). + + The bounding set limits the capabilities that may be inherited across + execve(), especially when a binary is executed that will execute as UID 0. + + (3) Secure management flags (securebits). + + These are only carried by tasks. These govern the way the above + credentials are manipulated and inherited over certain operations such as + execve(). They aren't used directly as objective or subjective + credentials. + + (4) Keys and keyrings. + + These are only carried by tasks. They carry and cache security tokens + that don't fit into the other standard UNIX credentials. They are for + making such things as network filesystem keys available to the file + accesses performed by processes, without the necessity of ordinary + programs having to know about security details involved. + + Keyrings are a special type of key. They carry sets of other keys and can + be searched for the desired key. Each process may subscribe to a number + of keyrings: + + Per-thread keying + Per-process keyring + Per-session keyring + + When a process accesses a key, if not already present, it will normally be + cached on one of these keyrings for future accesses to find. + + For more information on using keys, see Documentation/keys.txt. + + (5) LSM + + The Linux Security Module allows extra controls to be placed over the + operations that a task may do. Currently Linux supports two main + alternate LSM options: SELinux and Smack. + + Both work by labelling the objects in a system and then applying sets of + rules (policies) that say what operations a task with one label may do to + an object with another label. + + (6) AF_KEY + + This is a socket-based approach to credential management for networking + stacks [RFC 2367]. It isn't discussed by this document as it doesn't + interact directly with task and file credentials; rather it keeps system + level credentials. + + +When a file is opened, part of the opening task's subjective context is +recorded in the file struct created. This allows operations using that file +struct to use those credentials instead of the subjective context of the task +that issued the operation. An example of this would be a file opened on a +network filesystem where the credentials of the opened file should be presented +to the server, regardless of who is actually doing a read or a write upon it. + + +============= +FILE MARKINGS +============= + +Files on disk or obtained over the network may have annotations that form the +objective security context of that file. Depending on the type of filesystem, +this may include one or more of the following: + + (*) UNIX UID, GID, mode; + + (*) Windows user ID; + + (*) Access control list; + + (*) LSM security label; + + (*) UNIX exec privilege escalation bits (SUID/SGID); + + (*) File capabilities exec privilege escalation bits. + +These are compared to the task's subjective security context, and certain +operations allowed or disallowed as a result. In the case of execve(), the +privilege escalation bits come into play, and may allow the resulting process +extra privileges, based on the annotations on the executable file. + + +================ +TASK CREDENTIALS +================ + +In Linux, all of a task's credentials are held in (uid, gid) or through +(groups, keys, LSM security) a refcounted structure of type 'struct cred'. +Each task points to its credentials by a pointer called 'cred' in its +task_struct. + +Once a set of credentials has been prepared and committed, it may not be +changed, barring the following exceptions: + + (1) its reference count may be changed; + + (2) the reference count on the group_info struct it points to may be changed; + + (3) the reference count on the security data it points to may be changed; + + (4) the reference count on any keyrings it points to may be changed; + + (5) any keyrings it points to may be revoked, expired or have their security + attributes changed; and + + (6) the contents of any keyrings to which it points may be changed (the whole + point of keyrings being a shared set of credentials, modifiable by anyone + with appropriate access). + +To alter anything in the cred struct, the copy-and-replace principle must be +adhered to. First take a copy, then alter the copy and then use RCU to change +the task pointer to make it point to the new copy. There are wrappers to aid +with this (see below). + +A task may only alter its _own_ credentials; it is no longer permitted for a +task to alter another's credentials. This means the capset() system call is no +longer permitted to take any PID other than the one of the current process. +Also keyctl_instantiate() and keyctl_negate() functions no longer permit +attachment to process-specific keyrings in the requesting process as the +instantiating process may need to create them. + + +IMMUTABLE CREDENTIALS +--------------------- + +Once a set of credentials has been made public (by calling commit_creds() for +example), it must be considered immutable, barring two exceptions: + + (1) The reference count may be altered. + + (2) Whilst the keyring subscriptions of a set of credentials may not be + changed, the keyrings subscribed to may have their contents altered. + +To catch accidental credential alteration at compile time, struct task_struct +has _const_ pointers to its credential sets, as does struct file. Furthermore, +certain functions such as get_cred() and put_cred() operate on const pointers, +thus rendering casts unnecessary, but require to temporarily ditch the const +qualification to be able to alter the reference count. + + +ACCESSING TASK CREDENTIALS +-------------------------- + +A task being able to alter only its own credentials permits the current process +to read or replace its own credentials without the need for any form of locking +- which simplifies things greatly. It can just call: + + const struct cred *current_cred() + +to get a pointer to its credentials structure, and it doesn't have to release +it afterwards. + +There are convenience wrappers for retrieving specific aspects of a task's +credentials (the value is simply returned in each case): + + uid_t current_uid(void) Current's real UID + gid_t current_gid(void) Current's real GID + uid_t current_euid(void) Current's effective UID + gid_t current_egid(void) Current's effective GID + uid_t current_fsuid(void) Current's file access UID + gid_t current_fsgid(void) Current's file access GID + kernel_cap_t current_cap(void) Current's effective capabilities + void *current_security(void) Current's LSM security pointer + struct user_struct *current_user(void) Current's user account + +There are also convenience wrappers for retrieving specific associated pairs of +a task's credentials: + + void current_uid_gid(uid_t *, gid_t *); + void current_euid_egid(uid_t *, gid_t *); + void current_fsuid_fsgid(uid_t *, gid_t *); + +which return these pairs of values through their arguments after retrieving +them from the current task's credentials. + + +In addition, there is a function for obtaining a reference on the current +process's current set of credentials: + + const struct cred *get_current_cred(void); + +and functions for getting references to one of the credentials that don't +actually live in struct cred: + + struct user_struct *get_current_user(void); + struct group_info *get_current_groups(void); + +which get references to the current process's user accounting structure and +supplementary groups list respectively. + +Once a reference has been obtained, it must be released with put_cred(), +free_uid() or put_group_info() as appropriate. + + +ACCESSING ANOTHER TASK'S CREDENTIALS +------------------------------------ + +Whilst a task may access its own credentials without the need for locking, the +same is not true of a task wanting to access another task's credentials. It +must use the RCU read lock and rcu_dereference(). + +The rcu_dereference() is wrapped by: + + const struct cred *__task_cred(struct task_struct *task); + +This should be used inside the RCU read lock, as in the following example: + + void foo(struct task_struct *t, struct foo_data *f) + { + const struct cred *tcred; + ... + rcu_read_lock(); + tcred = __task_cred(t); + f->uid = tcred->uid; + f->gid = tcred->gid; + f->groups = get_group_info(tcred->groups); + rcu_read_unlock(); + ... + } + +A function need not get RCU read lock to use __task_cred() if it is holding a +spinlock at the time as this implicitly holds the RCU read lock. + +Should it be necessary to hold another task's credentials for a long period of +time, and possibly to sleep whilst doing so, then the caller should get a +reference on them using: + + const struct cred *get_task_cred(struct task_struct *task); + +This does all the RCU magic inside of it. The caller must call put_cred() on +the credentials so obtained when they're finished with. + +There are a couple of convenience functions to access bits of another task's +credentials, hiding the RCU magic from the caller: + + uid_t task_uid(task) Task's real UID + uid_t task_euid(task) Task's effective UID + +If the caller is holding a spinlock or the RCU read lock at the time anyway, +then: + + __task_cred(task)->uid + __task_cred(task)->euid + +should be used instead. Similarly, if multiple aspects of a task's credentials +need to be accessed, RCU read lock or a spinlock should be used, __task_cred() +called, the result stored in a temporary pointer and then the credential +aspects called from that before dropping the lock. This prevents the +potentially expensive RCU magic from being invoked multiple times. + +Should some other single aspect of another task's credentials need to be +accessed, then this can be used: + + task_cred_xxx(task, member) + +where 'member' is a non-pointer member of the cred struct. For instance: + + uid_t task_cred_xxx(task, suid); + +will retrieve 'struct cred::suid' from the task, doing the appropriate RCU +magic. This may not be used for pointer members as what they point to may +disappear the moment the RCU read lock is dropped. + + +ALTERING CREDENTIALS +-------------------- + +As previously mentioned, a task may only alter its own credentials, and may not +alter those of another task. This means that it doesn't need to use any +locking to alter its own credentials. + +To alter the current process's credentials, a function should first prepare a +new set of credentials by calling: + + struct cred *prepare_creds(void); + +this locks current->cred_replace_mutex and then allocates and constructs a +duplicate of the current process's credentials, returning with the mutex still +held if successful. It returns NULL if not successful (out of memory). + +The mutex prevents ptrace() from altering the ptrace state of a process whilst +security checks on credentials construction and changing is taking place as +the ptrace state may alter the outcome, particularly in the case of execve(). + +The new credentials set should be altered appropriately, and any security +checks and hooks done. Both the current and the proposed sets of credentials +are available for this purpose as current_cred() will return the current set +still at this point. + + +When the credential set is ready, it should be committed to the current process +by calling: + + int commit_creds(struct cred *new); + +This will alter various aspects of the credentials and the process, giving the +LSM a chance to do likewise, then it will use rcu_assign_pointer() to actually +commit the new credentials to current->cred, it will release +current->cred_replace_mutex to allow ptrace() to take place, and it will notify +the scheduler and others of the changes. + +This function is guaranteed to return 0, so that it can be tail-called at the +end of such functions as sys_setresuid(). + +Note that this function consumes the caller's reference to the new credentials. +The caller should _not_ call put_cred() on the new credentials afterwards. + +Furthermore, once this function has been called on a new set of credentials, +those credentials may _not_ be changed further. + + +Should the security checks fail or some other error occur after prepare_creds() +has been called, then the following function should be invoked: + + void abort_creds(struct cred *new); + +This releases the lock on current->cred_replace_mutex that prepare_creds() got +and then releases the new credentials. + + +A typical credentials alteration function would look something like this: + + int alter_suid(uid_t suid) + { + struct cred *new; + int ret; + + new = prepare_creds(); + if (!new) + return -ENOMEM; + + new->suid = suid; + ret = security_alter_suid(new); + if (ret < 0) { + abort_creds(new); + return ret; + } + + return commit_creds(new); + } + + +MANAGING CREDENTIALS +-------------------- + +There are some functions to help manage credentials: + + (*) void put_cred(const struct cred *cred); + + This releases a reference to the given set of credentials. If the + reference count reaches zero, the credentials will be scheduled for + destruction by the RCU system. + + (*) const struct cred *get_cred(const struct cred *cred); + + This gets a reference on a live set of credentials, returning a pointer to + that set of credentials. + + (*) struct cred *get_new_cred(struct cred *cred); + + This gets a reference on a set of credentials that is under construction + and is thus still mutable, returning a pointer to that set of credentials. + + +===================== +OPEN FILE CREDENTIALS +===================== + +When a new file is opened, a reference is obtained on the opening task's +credentials and this is attached to the file struct as 'f_cred' in place of +'f_uid' and 'f_gid'. Code that used to access file->f_uid and file->f_gid +should now access file->f_cred->fsuid and file->f_cred->fsgid. + +It is safe to access f_cred without the use of RCU or locking because the +pointer will not change over the lifetime of the file struct, and nor will the +contents of the cred struct pointed to, barring the exceptions listed above +(see the Task Credentials section). + + +======================================= +OVERRIDING THE VFS'S USE OF CREDENTIALS +======================================= + +Under some circumstances it is desirable to override the credentials used by +the VFS, and that can be done by calling into such as vfs_mkdir() with a +different set of credentials. This is done in the following places: + + (*) sys_faccessat(). + + (*) do_coredump(). + + (*) nfs4recover.c. diff --git a/Documentation/devices.txt b/Documentation/devices.txt index 05c8064..2be0824 100644 --- a/Documentation/devices.txt +++ b/Documentation/devices.txt @@ -2571,6 +2571,9 @@ Your cooperation is appreciated. 160 = /dev/usb/legousbtower0 1st USB Legotower device ... 175 = /dev/usb/legousbtower15 16th USB Legotower device + 176 = /dev/usb/usbtmc1 First USB TMC device + ... + 192 = /dev/usb/usbtmc16 16th USB TMC device 240 = /dev/usb/dabusb0 First daubusb device ... 243 = /dev/usb/dabusb3 Fourth dabusb device diff --git a/Documentation/early-userspace/00-INDEX b/Documentation/early-userspace/00-INDEX new file mode 100644 index 0000000..9deb666 --- /dev/null +++ b/Documentation/early-userspace/00-INDEX @@ -0,0 +1,8 @@ +00-INDEX + - this file +README + - explains what early userspace is +buffer_format.txt + - documents the initramfs buffer format +initrd.txt + - how to use the RAM disk as an initial/temporary root filesystem. diff --git a/Documentation/early-userspace/initrd.txt b/Documentation/early-userspace/initrd.txt new file mode 100644 index 0000000..772d6a3 --- /dev/null +++ b/Documentation/early-userspace/initrd.txt @@ -0,0 +1,366 @@ +Using the initial RAM disk (initrd) +=================================== + +Written 1996,2000 by Werner Almesberger and + Hans Lermen + + +initrd provides the capability to load a RAM disk by the boot loader. +This RAM disk can then be mounted as the root file system and programs +can be run from it. Afterwards, a new root file system can be mounted +from a different device. The previous root (from initrd) is then moved +to a directory and can be subsequently unmounted. + +initrd is mainly designed to allow system startup to occur in two phases, +where the kernel comes up with a minimum set of compiled-in drivers, and +where additional modules are loaded from initrd. + +This document gives a brief overview of the use of initrd. A more detailed +discussion of the boot process can be found in [1]. + + +Operation +--------- + +When using initrd, the system typically boots as follows: + + 1) the boot loader loads the kernel and the initial RAM disk + 2) the kernel converts initrd into a "normal" RAM disk and + frees the memory used by initrd + 3) if the root device is not /dev/ram0, the old (deprecated) + change_root procedure is followed. see the "Obsolete root change + mechanism" section below. + 4) root device is mounted. if it is /dev/ram0, the initrd image is + then mounted as root + 5) /sbin/init is executed (this can be any valid executable, including + shell scripts; it is run with uid 0 and can do basically everything + init can do). + 6) init mounts the "real" root file system + 7) init places the root file system at the root directory using the + pivot_root system call + 8) init execs the /sbin/init on the new root filesystem, performing + the usual boot sequence + 9) the initrd file system is removed + +Note that changing the root directory does not involve unmounting it. +It is therefore possible to leave processes running on initrd during that +procedure. Also note that file systems mounted under initrd continue to +be accessible. + + +Boot command-line options +------------------------- + +initrd adds the following new options: + + initrd= (e.g. LOADLIN) + + Loads the specified file as the initial RAM disk. When using LILO, you + have to specify the RAM disk image file in /etc/lilo.conf, using the + INITRD configuration variable. + + noinitrd + + initrd data is preserved but it is not converted to a RAM disk and + the "normal" root file system is mounted. initrd data can be read + from /dev/initrd. Note that the data in initrd can have any structure + in this case and doesn't necessarily have to be a file system image. + This option is used mainly for debugging. + + Note: /dev/initrd is read-only and it can only be used once. As soon + as the last process has closed it, all data is freed and /dev/initrd + can't be opened anymore. + + root=/dev/ram0 + + initrd is mounted as root, and the normal boot procedure is followed, + with the RAM disk mounted as root. + +Compressed cpio images +---------------------- + +Recent kernels have support for populating a ramdisk from a compressed cpio +archive. On such systems, the creation of a ramdisk image doesn't need to +involve special block devices or loopbacks; you merely create a directory on +disk with the desired initrd content, cd to that directory, and run (as an +example): + +find . | cpio --quiet -H newc -o | gzip -9 -n > /boot/imagefile.img + +Examining the contents of an existing image file is just as simple: + +mkdir /tmp/imagefile +cd /tmp/imagefile +gzip -cd /boot/imagefile.img | cpio -imd --quiet + +Installation +------------ + +First, a directory for the initrd file system has to be created on the +"normal" root file system, e.g. + +# mkdir /initrd + +The name is not relevant. More details can be found on the pivot_root(2) +man page. + +If the root file system is created during the boot procedure (i.e. if +you're building an install floppy), the root file system creation +procedure should create the /initrd directory. + +If initrd will not be mounted in some cases, its content is still +accessible if the following device has been created: + +# mknod /dev/initrd b 1 250 +# chmod 400 /dev/initrd + +Second, the kernel has to be compiled with RAM disk support and with +support for the initial RAM disk enabled. Also, at least all components +needed to execute programs from initrd (e.g. executable format and file +system) must be compiled into the kernel. + +Third, you have to create the RAM disk image. This is done by creating a +file system on a block device, copying files to it as needed, and then +copying the content of the block device to the initrd file. With recent +kernels, at least three types of devices are suitable for that: + + - a floppy disk (works everywhere but it's painfully slow) + - a RAM disk (fast, but allocates physical memory) + - a loopback device (the most elegant solution) + +We'll describe the loopback device method: + + 1) make sure loopback block devices are configured into the kernel + 2) create an empty file system of the appropriate size, e.g. + # dd if=/dev/zero of=initrd bs=300k count=1 + # mke2fs -F -m0 initrd + (if space is critical, you may want to use the Minix FS instead of Ext2) + 3) mount the file system, e.g. + # mount -t ext2 -o loop initrd /mnt + 4) create the console device: + # mkdir /mnt/dev + # mknod /mnt/dev/console c 5 1 + 5) copy all the files that are needed to properly use the initrd + environment. Don't forget the most important file, /sbin/init + Note that /sbin/init's permissions must include "x" (execute). + 6) correct operation the initrd environment can frequently be tested + even without rebooting with the command + # chroot /mnt /sbin/init + This is of course limited to initrds that do not interfere with the + general system state (e.g. by reconfiguring network interfaces, + overwriting mounted devices, trying to start already running demons, + etc. Note however that it is usually possible to use pivot_root in + such a chroot'ed initrd environment.) + 7) unmount the file system + # umount /mnt + 8) the initrd is now in the file "initrd". Optionally, it can now be + compressed + # gzip -9 initrd + +For experimenting with initrd, you may want to take a rescue floppy and +only add a symbolic link from /sbin/init to /bin/sh. Alternatively, you +can try the experimental newlib environment [2] to create a small +initrd. + +Finally, you have to boot the kernel and load initrd. Almost all Linux +boot loaders support initrd. Since the boot process is still compatible +with an older mechanism, the following boot command line parameters +have to be given: + + root=/dev/ram0 rw + +(rw is only necessary if writing to the initrd file system.) + +With LOADLIN, you simply execute + + LOADLIN initrd= +e.g. LOADLIN C:\LINUX\BZIMAGE initrd=C:\LINUX\INITRD.GZ root=/dev/ram0 rw + +With LILO, you add the option INITRD= to either the global section +or to the section of the respective kernel in /etc/lilo.conf, and pass +the options using APPEND, e.g. + + image = /bzImage + initrd = /boot/initrd.gz + append = "root=/dev/ram0 rw" + +and run /sbin/lilo + +For other boot loaders, please refer to the respective documentation. + +Now you can boot and enjoy using initrd. + + +Changing the root device +------------------------ + +When finished with its duties, init typically changes the root device +and proceeds with starting the Linux system on the "real" root device. + +The procedure involves the following steps: + - mounting the new root file system + - turning it into the root file system + - removing all accesses to the old (initrd) root file system + - unmounting the initrd file system and de-allocating the RAM disk + +Mounting the new root file system is easy: it just needs to be mounted on +a directory under the current root. Example: + +# mkdir /new-root +# mount -o ro /dev/hda1 /new-root + +The root change is accomplished with the pivot_root system call, which +is also available via the pivot_root utility (see pivot_root(8) man +page; pivot_root is distributed with util-linux version 2.10h or higher +[3]). pivot_root moves the current root to a directory under the new +root, and puts the new root at its place. The directory for the old root +must exist before calling pivot_root. Example: + +# cd /new-root +# mkdir initrd +# pivot_root . initrd + +Now, the init process may still access the old root via its +executable, shared libraries, standard input/output/error, and its +current root directory. All these references are dropped by the +following command: + +# exec chroot . what-follows dev/console 2>&1 + +Where what-follows is a program under the new root, e.g. /sbin/init +If the new root file system will be used with udev and has no valid +/dev directory, udev must be initialized before invoking chroot in order +to provide /dev/console. + +Note: implementation details of pivot_root may change with time. In order +to ensure compatibility, the following points should be observed: + + - before calling pivot_root, the current directory of the invoking + process should point to the new root directory + - use . as the first argument, and the _relative_ path of the directory + for the old root as the second argument + - a chroot program must be available under the old and the new root + - chroot to the new root afterwards + - use relative paths for dev/console in the exec command + +Now, the initrd can be unmounted and the memory allocated by the RAM +disk can be freed: + +# umount /initrd +# blockdev --flushbufs /dev/ram0 + +It is also possible to use initrd with an NFS-mounted root, see the +pivot_root(8) man page for details. + + +Usage scenarios +--------------- + +The main motivation for implementing initrd was to allow for modular +kernel configuration at system installation. The procedure would work +as follows: + + 1) system boots from floppy or other media with a minimal kernel + (e.g. support for RAM disks, initrd, a.out, and the Ext2 FS) and + loads initrd + 2) /sbin/init determines what is needed to (1) mount the "real" root FS + (i.e. device type, device drivers, file system) and (2) the + distribution media (e.g. CD-ROM, network, tape, ...). This can be + done by asking the user, by auto-probing, or by using a hybrid + approach. + 3) /sbin/init loads the necessary kernel modules + 4) /sbin/init creates and populates the root file system (this doesn't + have to be a very usable system yet) + 5) /sbin/init invokes pivot_root to change the root file system and + execs - via chroot - a program that continues the installation + 6) the boot loader is installed + 7) the boot loader is configured to load an initrd with the set of + modules that was used to bring up the system (e.g. /initrd can be + modified, then unmounted, and finally, the image is written from + /dev/ram0 or /dev/rd/0 to a file) + 8) now the system is bootable and additional installation tasks can be + performed + +The key role of initrd here is to re-use the configuration data during +normal system operation without requiring the use of a bloated "generic" +kernel or re-compiling or re-linking the kernel. + +A second scenario is for installations where Linux runs on systems with +different hardware configurations in a single administrative domain. In +such cases, it is desirable to generate only a small set of kernels +(ideally only one) and to keep the system-specific part of configuration +information as small as possible. In this case, a common initrd could be +generated with all the necessary modules. Then, only /sbin/init or a file +read by it would have to be different. + +A third scenario is more convenient recovery disks, because information +like the location of the root FS partition doesn't have to be provided at +boot time, but the system loaded from initrd can invoke a user-friendly +dialog and it can also perform some sanity checks (or even some form of +auto-detection). + +Last not least, CD-ROM distributors may use it for better installation +from CD, e.g. by using a boot floppy and bootstrapping a bigger RAM disk +via initrd from CD; or by booting via a loader like LOADLIN or directly +from the CD-ROM, and loading the RAM disk from CD without need of +floppies. + + +Obsolete root change mechanism +------------------------------ + +The following mechanism was used before the introduction of pivot_root. +Current kernels still support it, but you should _not_ rely on its +continued availability. + +It works by mounting the "real" root device (i.e. the one set with rdev +in the kernel image or with root=... at the boot command line) as the +root file system when linuxrc exits. The initrd file system is then +unmounted, or, if it is still busy, moved to a directory /initrd, if +such a directory exists on the new root file system. + +In order to use this mechanism, you do not have to specify the boot +command options root, init, or rw. (If specified, they will affect +the real root file system, not the initrd environment.) + +If /proc is mounted, the "real" root device can be changed from within +linuxrc by writing the number of the new root FS device to the special +file /proc/sys/kernel/real-root-dev, e.g. + + # echo 0x301 >/proc/sys/kernel/real-root-dev + +Note that the mechanism is incompatible with NFS and similar file +systems. + +This old, deprecated mechanism is commonly called "change_root", while +the new, supported mechanism is called "pivot_root". + + +Mixed change_root and pivot_root mechanism +------------------------------------------ + +In case you did not want to use root=/dev/ram0 to trigger the pivot_root +mechanism, you may create both /linuxrc and /sbin/init in your initrd image. + +/linuxrc would contain only the following: + +#! /bin/sh +mount -n -t proc proc /proc +echo 0x0100 >/proc/sys/kernel/real-root-dev +umount -n /proc + +Once linuxrc exited, the kernel would mount again your initrd as root, +this time executing /sbin/init. Again, it would be the duty of this init +to build the right environment (maybe using the root= device passed on +the cmdline) before the final execution of the real /sbin/init. + + +Resources +--------- + +[1] Almesberger, Werner; "Booting Linux: The History and the Future" + http://www.almesberger.net/cv/papers/ols2k-9.ps.gz +[2] newlib package (experimental), with initrd example + http://sources.redhat.com/newlib/ +[3] Brouwer, Andries; "util-linux: Miscellaneous utilities for Linux" + ftp://ftp.win.tue.nl/pub/linux-local/utils/util-linux/ diff --git a/Documentation/feature-removal-schedule.txt b/Documentation/feature-removal-schedule.txt index eb1a47b..81fc817 100644 --- a/Documentation/feature-removal-schedule.txt +++ b/Documentation/feature-removal-schedule.txt @@ -274,6 +274,13 @@ Who: Sebastian Siewior --------------------------- +What: remove HID compat support +When: 2.6.29 +Why: needed only as a temporary solution until distros fix themselves up +Who: Jiri Slaby + +--------------------------- + What: /sys/o2cb symlink When: January 2010 Why: /sys/fs/o2cb is the proper location for this information - /sys/o2cb diff --git a/Documentation/filesystems/Makefile b/Documentation/filesystems/Makefile new file mode 100644 index 0000000..3f19a70 --- /dev/null +++ b/Documentation/filesystems/Makefile @@ -0,0 +1,8 @@ +# kbuild trick to avoid linker error. Can be omitted if a module is built. +obj- := dummy.o + +# List of programs to build +hostprogs-y := smount dnotify_test + +# Tell kbuild to always build the programs +always := $(hostprogs-y) diff --git a/Documentation/filesystems/dnotify.txt b/Documentation/filesystems/dnotify.txt index 9f5d338..7bb77d7 100644 --- a/Documentation/filesystems/dnotify.txt +++ b/Documentation/filesystems/dnotify.txt @@ -62,38 +62,4 @@ disabled, fcntl(fd, F_NOTIFY, ...) will return -EINVAL. Example ------- - - #define _GNU_SOURCE /* needed to get the defines */ - #include /* in glibc 2.2 this has the needed - values defined */ - #include - #include - #include - - static volatile int event_fd; - - static void handler(int sig, siginfo_t *si, void *data) - { - event_fd = si->si_fd; - } - - int main(void) - { - struct sigaction act; - int fd; - - act.sa_sigaction = handler; - sigemptyset(&act.sa_mask); - act.sa_flags = SA_SIGINFO; - sigaction(SIGRTMIN + 1, &act, NULL); - - fd = open(".", O_RDONLY); - fcntl(fd, F_SETSIG, SIGRTMIN + 1); - fcntl(fd, F_NOTIFY, DN_MODIFY|DN_CREATE|DN_MULTISHOT); - /* we will now be notified if any of the files - in "." is modified or new files are created */ - while (1) { - pause(); - printf("Got event on fd=%d\n", event_fd); - } - } +See Documentation/filesystems/dnotify_test.c for an example. diff --git a/Documentation/filesystems/dnotify_test.c b/Documentation/filesystems/dnotify_test.c new file mode 100644 index 0000000..8b37b4a --- /dev/null +++ b/Documentation/filesystems/dnotify_test.c @@ -0,0 +1,34 @@ +#define _GNU_SOURCE /* needed to get the defines */ +#include /* in glibc 2.2 this has the needed + values defined */ +#include +#include +#include + +static volatile int event_fd; + +static void handler(int sig, siginfo_t *si, void *data) +{ + event_fd = si->si_fd; +} + +int main(void) +{ + struct sigaction act; + int fd; + + act.sa_sigaction = handler; + sigemptyset(&act.sa_mask); + act.sa_flags = SA_SIGINFO; + sigaction(SIGRTMIN + 1, &act, NULL); + + fd = open(".", O_RDONLY); + fcntl(fd, F_SETSIG, SIGRTMIN + 1); + fcntl(fd, F_NOTIFY, DN_MODIFY|DN_CREATE|DN_MULTISHOT); + /* we will now be notified if any of the files + in "." is modified or new files are created */ + while (1) { + pause(); + printf("Got event on fd=%d\n", event_fd); + } +} diff --git a/Documentation/filesystems/hfs.txt b/Documentation/filesystems/hfs.txt index bd0fa77..28f0225 100644 --- a/Documentation/filesystems/hfs.txt +++ b/Documentation/filesystems/hfs.txt @@ -61,7 +61,7 @@ the a little strange: Finder's metadata. o They are however created (with default values), deleted and renamed along with the corresponding data fork or directory. - o Copying files to a different filesystem will loose those attributes + o Copying files to a different filesystem will lose those attributes that are essential for MacOS to work. diff --git a/Documentation/filesystems/sharedsubtree.txt b/Documentation/filesystems/sharedsubtree.txt index 7365400..6e74a4a 100644 --- a/Documentation/filesystems/sharedsubtree.txt +++ b/Documentation/filesystems/sharedsubtree.txt @@ -47,6 +47,7 @@ replicas continue to be exactly same. note: mount command does not yet support the --make-shared flag. I have included a small C program which does the same by executing 'smount /mnt shared' + [see Documentation/filesystems/smount.c] #mount --bind /mnt /tmp The above command replicates the mount at /mnt to the mountpoint /tmp @@ -141,87 +142,12 @@ replicas continue to be exactly same. Currently the mount command is not aware of shared subtree features. Work is in progress to add the support in mount ( util-linux package ). - Till then use the following program. + Until then use the 'smount' program that is located in + "Documentation/filesystems/smount.c" and build it like: - ------------------------------------------------------------------------ - // - //this code was developed my Miklos Szeredi - //and modified by Ram Pai - // sample usage: - // smount /tmp shared - // - #include - #include - #include - #include - #include - #include - - #ifndef MS_REC - #define MS_REC 0x4000 /* 16384: Recursive loopback */ - #endif - - #ifndef MS_SHARED - #define MS_SHARED 1<<20 /* Shared */ - #endif - - #ifndef MS_PRIVATE - #define MS_PRIVATE 1<<18 /* Private */ - #endif - - #ifndef MS_SLAVE - #define MS_SLAVE 1<<19 /* Slave */ - #endif - - #ifndef MS_UNBINDABLE - #define MS_UNBINDABLE 1<<17 /* Unbindable */ - #endif - - int main(int argc, char *argv[]) - { - int type; - if(argc != 3) { - fprintf(stderr, "usage: %s dir " - "\n" , argv[0]); - return 1; - } - - fprintf(stdout, "%s %s %s\n", argv[0], argv[1], argv[2]); - - if (strcmp(argv[2],"rshared")==0) - type=(MS_SHARED|MS_REC); - else if (strcmp(argv[2],"rslave")==0) - type=(MS_SLAVE|MS_REC); - else if (strcmp(argv[2],"rprivate")==0) - type=(MS_PRIVATE|MS_REC); - else if (strcmp(argv[2],"runbindable")==0) - type=(MS_UNBINDABLE|MS_REC); - else if (strcmp(argv[2],"shared")==0) - type=MS_SHARED; - else if (strcmp(argv[2],"slave")==0) - type=MS_SLAVE; - else if (strcmp(argv[2],"private")==0) - type=MS_PRIVATE; - else if (strcmp(argv[2],"unbindable")==0) - type=MS_UNBINDABLE; - else { - fprintf(stderr, "invalid operation: %s\n", argv[2]); - return 1; - } - setfsuid(getuid()); - - if(mount("", argv[1], "dontcare", type, "") == -1) { - perror("mount"); - return 1; - } - return 0; - } - ----------------------------------------------------------------------- - - Copy the above code snippet into smount.c gcc -o smount smount.c + ----------------------------------------------------------------------- (i) To mark all the mounts under /mnt as shared execute the following command: diff --git a/Documentation/filesystems/smount.c b/Documentation/filesystems/smount.c new file mode 100644 index 0000000..233d78c --- /dev/null +++ b/Documentation/filesystems/smount.c @@ -0,0 +1,73 @@ +// +//this code was developed my Miklos Szeredi +//and modified by Ram Pai +// sample usage: +// smount /tmp shared +// +#include +#include +#include +#include +#include +#include + +#ifndef MS_REC +#define MS_REC 0x4000 /* 16384: Recursive loopback */ +#endif + +#ifndef MS_SHARED +#define MS_SHARED 1<<20 /* Shared */ +#endif + +#ifndef MS_PRIVATE +#define MS_PRIVATE 1<<18 /* Private */ +#endif + +#ifndef MS_SLAVE +#define MS_SLAVE 1<<19 /* Slave */ +#endif + +#ifndef MS_UNBINDABLE +#define MS_UNBINDABLE 1<<17 /* Unbindable */ +#endif + +int main(int argc, char *argv[]) +{ + int type; + if(argc != 3) { + fprintf(stderr, "usage: %s dir " + "\n" , argv[0]); + return 1; + } + + fprintf(stdout, "%s %s %s\n", argv[0], argv[1], argv[2]); + + if (strcmp(argv[2],"rshared")==0) + type=(MS_SHARED|MS_REC); + else if (strcmp(argv[2],"rslave")==0) + type=(MS_SLAVE|MS_REC); + else if (strcmp(argv[2],"rprivate")==0) + type=(MS_PRIVATE|MS_REC); + else if (strcmp(argv[2],"runbindable")==0) + type=(MS_UNBINDABLE|MS_REC); + else if (strcmp(argv[2],"shared")==0) + type=MS_SHARED; + else if (strcmp(argv[2],"slave")==0) + type=MS_SLAVE; + else if (strcmp(argv[2],"private")==0) + type=MS_PRIVATE; + else if (strcmp(argv[2],"unbindable")==0) + type=MS_UNBINDABLE; + else { + fprintf(stderr, "invalid operation: %s\n", argv[2]); + return 1; + } + setfsuid(getuid()); + + if(mount("", argv[1], "dontcare", type, "") == -1) { + perror("mount"); + return 1; + } + return 0; +} diff --git a/Documentation/hpet.txt b/Documentation/hpet.txt deleted file mode 100644 index 6ad52d9..0000000 --- a/Documentation/hpet.txt +++ /dev/null @@ -1,300 +0,0 @@ - High Precision Event Timer Driver for Linux - -The High Precision Event Timer (HPET) hardware is the future replacement -for the 8254 and Real Time Clock (RTC) periodic timer functionality. -Each HPET can have up to 32 timers. It is possible to configure the -first two timers as legacy replacements for 8254 and RTC periodic timers. -A specification done by Intel and Microsoft can be found at -. - -The driver supports detection of HPET driver allocation and initialization -of the HPET before the driver module_init routine is called. This enables -platform code which uses timer 0 or 1 as the main timer to intercept HPET -initialization. An example of this initialization can be found in -arch/i386/kernel/time_hpet.c. - -The driver provides two APIs which are very similar to the API found in -the rtc.c driver. There is a user space API and a kernel space API. -An example user space program is provided below. - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - - -extern void hpet_open_close(int, const char **); -extern void hpet_info(int, const char **); -extern void hpet_poll(int, const char **); -extern void hpet_fasync(int, const char **); -extern void hpet_read(int, const char **); - -#include -#include -#include - -struct hpet_command { - char *command; - void (*func)(int argc, const char ** argv); -} hpet_command[] = { - { - "open-close", - hpet_open_close - }, - { - "info", - hpet_info - }, - { - "poll", - hpet_poll - }, - { - "fasync", - hpet_fasync - }, -}; - -int -main(int argc, const char ** argv) -{ - int i; - - argc--; - argv++; - - if (!argc) { - fprintf(stderr, "-hpet: requires command\n"); - return -1; - } - - - for (i = 0; i < (sizeof (hpet_command) / sizeof (hpet_command[0])); i++) - if (!strcmp(argv[0], hpet_command[i].command)) { - argc--; - argv++; - fprintf(stderr, "-hpet: executing %s\n", - hpet_command[i].command); - hpet_command[i].func(argc, argv); - return 0; - } - - fprintf(stderr, "do_hpet: command %s not implemented\n", argv[0]); - - return -1; -} - -void -hpet_open_close(int argc, const char **argv) -{ - int fd; - - if (argc != 1) { - fprintf(stderr, "hpet_open_close: device-name\n"); - return; - } - - fd = open(argv[0], O_RDONLY); - if (fd < 0) - fprintf(stderr, "hpet_open_close: open failed\n"); - else - close(fd); - - return; -} - -void -hpet_info(int argc, const char **argv) -{ -} - -void -hpet_poll(int argc, const char **argv) -{ - unsigned long freq; - int iterations, i, fd; - struct pollfd pfd; - struct hpet_info info; - struct timeval stv, etv; - struct timezone tz; - long usec; - - if (argc != 3) { - fprintf(stderr, "hpet_poll: device-name freq iterations\n"); - return; - } - - freq = atoi(argv[1]); - iterations = atoi(argv[2]); - - fd = open(argv[0], O_RDONLY); - - if (fd < 0) { - fprintf(stderr, "hpet_poll: open of %s failed\n", argv[0]); - return; - } - - if (ioctl(fd, HPET_IRQFREQ, freq) < 0) { - fprintf(stderr, "hpet_poll: HPET_IRQFREQ failed\n"); - goto out; - } - - if (ioctl(fd, HPET_INFO, &info) < 0) { - fprintf(stderr, "hpet_poll: failed to get info\n"); - goto out; - } - - fprintf(stderr, "hpet_poll: info.hi_flags 0x%lx\n", info.hi_flags); - - if (info.hi_flags && (ioctl(fd, HPET_EPI, 0) < 0)) { - fprintf(stderr, "hpet_poll: HPET_EPI failed\n"); - goto out; - } - - if (ioctl(fd, HPET_IE_ON, 0) < 0) { - fprintf(stderr, "hpet_poll, HPET_IE_ON failed\n"); - goto out; - } - - pfd.fd = fd; - pfd.events = POLLIN; - - for (i = 0; i < iterations; i++) { - pfd.revents = 0; - gettimeofday(&stv, &tz); - if (poll(&pfd, 1, -1) < 0) - fprintf(stderr, "hpet_poll: poll failed\n"); - else { - long data; - - gettimeofday(&etv, &tz); - usec = stv.tv_sec * 1000000 + stv.tv_usec; - usec = (etv.tv_sec * 1000000 + etv.tv_usec) - usec; - - fprintf(stderr, - "hpet_poll: expired time = 0x%lx\n", usec); - - fprintf(stderr, "hpet_poll: revents = 0x%x\n", - pfd.revents); - - if (read(fd, &data, sizeof(data)) != sizeof(data)) { - fprintf(stderr, "hpet_poll: read failed\n"); - } - else - fprintf(stderr, "hpet_poll: data 0x%lx\n", - data); - } - } - -out: - close(fd); - return; -} - -static int hpet_sigio_count; - -static void -hpet_sigio(int val) -{ - fprintf(stderr, "hpet_sigio: called\n"); - hpet_sigio_count++; -} - -void -hpet_fasync(int argc, const char **argv) -{ - unsigned long freq; - int iterations, i, fd, value; - sig_t oldsig; - struct hpet_info info; - - hpet_sigio_count = 0; - fd = -1; - - if ((oldsig = signal(SIGIO, hpet_sigio)) == SIG_ERR) { - fprintf(stderr, "hpet_fasync: failed to set signal handler\n"); - return; - } - - if (argc != 3) { - fprintf(stderr, "hpet_fasync: device-name freq iterations\n"); - goto out; - } - - fd = open(argv[0], O_RDONLY); - - if (fd < 0) { - fprintf(stderr, "hpet_fasync: failed to open %s\n", argv[0]); - return; - } - - - if ((fcntl(fd, F_SETOWN, getpid()) == 1) || - ((value = fcntl(fd, F_GETFL)) == 1) || - (fcntl(fd, F_SETFL, value | O_ASYNC) == 1)) { - fprintf(stderr, "hpet_fasync: fcntl failed\n"); - goto out; - } - - freq = atoi(argv[1]); - iterations = atoi(argv[2]); - - if (ioctl(fd, HPET_IRQFREQ, freq) < 0) { - fprintf(stderr, "hpet_fasync: HPET_IRQFREQ failed\n"); - goto out; - } - - if (ioctl(fd, HPET_INFO, &info) < 0) { - fprintf(stderr, "hpet_fasync: failed to get info\n"); - goto out; - } - - fprintf(stderr, "hpet_fasync: info.hi_flags 0x%lx\n", info.hi_flags); - - if (info.hi_flags && (ioctl(fd, HPET_EPI, 0) < 0)) { - fprintf(stderr, "hpet_fasync: HPET_EPI failed\n"); - goto out; - } - - if (ioctl(fd, HPET_IE_ON, 0) < 0) { - fprintf(stderr, "hpet_fasync, HPET_IE_ON failed\n"); - goto out; - } - - for (i = 0; i < iterations; i++) { - (void) pause(); - fprintf(stderr, "hpet_fasync: count = %d\n", hpet_sigio_count); - } - -out: - signal(SIGIO, oldsig); - - if (fd >= 0) - close(fd); - - return; -} - -The kernel API has three interfaces exported from the driver: - - hpet_register(struct hpet_task *tp, int periodic) - hpet_unregister(struct hpet_task *tp) - hpet_control(struct hpet_task *tp, unsigned int cmd, unsigned long arg) - -The kernel module using this interface fills in the ht_func and ht_data -members of the hpet_task structure before calling hpet_register. -hpet_control simply vectors to the hpet_ioctl routine and has the same -commands and respective arguments as the user API. hpet_unregister -is used to terminate usage of the HPET timer reserved by hpet_register. diff --git a/Documentation/hwmon/lm87 b/Documentation/hwmon/lm87 index ec27aa1..6b47b67 100644 --- a/Documentation/hwmon/lm87 +++ b/Documentation/hwmon/lm87 @@ -65,11 +65,10 @@ The LM87 has four pins which can serve one of two possible functions, depending on the hardware configuration. Some functions share pins, so not all functions are available at the same -time. Which are depends on the hardware setup. This driver assumes that -the BIOS configured the chip correctly. In that respect, it differs from -the original driver (from lm_sensors for Linux 2.4), which would force the -LM87 to an arbitrary, compile-time chosen mode, regardless of the actual -chipset wiring. +time. Which are depends on the hardware setup. This driver normally +assumes that firmware configured the chip correctly. Where this is not +the case, platform code must set the I2C client's platform_data to point +to a u8 value to be written to the channel register. For reference, here is the list of exclusive functions: - in0+in5 (default) or temp3 diff --git a/Documentation/hwmon/lm90 b/Documentation/hwmon/lm90 index aa4a0ec..e0d5206 100644 --- a/Documentation/hwmon/lm90 +++ b/Documentation/hwmon/lm90 @@ -11,7 +11,7 @@ Supported chips: Prefix: 'lm99' Addresses scanned: I2C 0x4c and 0x4d Datasheet: Publicly available at the National Semiconductor website - http://www.national.com/pf/LM/LM89.html + http://www.national.com/mpf/LM/LM89.html * National Semiconductor LM99 Prefix: 'lm99' Addresses scanned: I2C 0x4c and 0x4d @@ -21,18 +21,32 @@ Supported chips: Prefix: 'lm86' Addresses scanned: I2C 0x4c Datasheet: Publicly available at the National Semiconductor website - http://www.national.com/pf/LM/LM86.html + http://www.national.com/mpf/LM/LM86.html * Analog Devices ADM1032 Prefix: 'adm1032' Addresses scanned: I2C 0x4c and 0x4d - Datasheet: Publicly available at the Analog Devices website - http://www.analog.com/en/prod/0,2877,ADM1032,00.html + Datasheet: Publicly available at the ON Semiconductor website + http://www.onsemi.com/PowerSolutions/product.do?id=ADM1032 * Analog Devices ADT7461 Prefix: 'adt7461' Addresses scanned: I2C 0x4c and 0x4d - Datasheet: Publicly available at the Analog Devices website - http://www.analog.com/en/prod/0,2877,ADT7461,00.html - Note: Only if in ADM1032 compatibility mode + Datasheet: Publicly available at the ON Semiconductor website + http://www.onsemi.com/PowerSolutions/product.do?id=ADT7461 + * Maxim MAX6646 + Prefix: 'max6646' + Addresses scanned: I2C 0x4d + Datasheet: Publicly available at the Maxim website + http://www.maxim-ic.com/quick_view2.cfm/qv_pk/3497 + * Maxim MAX6647 + Prefix: 'max6646' + Addresses scanned: I2C 0x4e + Datasheet: Publicly available at the Maxim website + http://www.maxim-ic.com/quick_view2.cfm/qv_pk/3497 + * Maxim MAX6649 + Prefix: 'max6646' + Addresses scanned: I2C 0x4c + Datasheet: Publicly available at the Maxim website + http://www.maxim-ic.com/quick_view2.cfm/qv_pk/3497 * Maxim MAX6657 Prefix: 'max6657' Addresses scanned: I2C 0x4c @@ -70,25 +84,21 @@ Description The LM90 is a digital temperature sensor. It senses its own temperature as well as the temperature of up to one external diode. It is compatible -with many other devices such as the LM86, the LM89, the LM99, the ADM1032, -the MAX6657, MAX6658, MAX6659, MAX6680 and the MAX6681 all of which are -supported by this driver. +with many other devices, many of which are supported by this driver. Note that there is no easy way to differentiate between the MAX6657, MAX6658 and MAX6659 variants. The extra address and features of the MAX6659 are not supported by this driver. The MAX6680 and MAX6681 only differ in their pinout, therefore they obviously can't (and don't need to) -be distinguished. Additionally, the ADT7461 is supported if found in -ADM1032 compatibility mode. +be distinguished. The specificity of this family of chipsets over the ADM1021/LM84 family is that it features critical limits with hysteresis, and an increased resolution of the remote temperature measurement. The different chipsets of the family are not strictly identical, although -very similar. This driver doesn't handle any specific feature for now, -with the exception of SMBus PEC. For reference, here comes a non-exhaustive -list of specific features: +very similar. For reference, here comes a non-exhaustive list of specific +features: LM90: * Filter and alert configuration register at 0xBF. @@ -114,9 +124,11 @@ ADT7461: * Lower resolution for remote temperature MAX6657 and MAX6658: + * Better local resolution * Remote sensor type selection MAX6659: + * Better local resolution * Selectable address * Second critical temperature limit * Remote sensor type selection @@ -127,7 +139,8 @@ MAX6680 and MAX6681: All temperature values are given in degrees Celsius. Resolution is 1.0 degree for the local temperature, 0.125 degree for the remote -temperature. +temperature, except for the MAX6657, MAX6658 and MAX6659 which have a +resolution of 0.125 degree for both temperatures. Each sensor has its own high and low limits, plus a critical limit. Additionally, there is a relative hysteresis value common to both critical diff --git a/Documentation/i2c/busses/i2c-floppy b/Documentation/i2c/busses/i2c-floppy new file mode 100644 index 0000000..5536cf2 --- /dev/null +++ b/Documentation/i2c/busses/i2c-floppy @@ -0,0 +1,37 @@ +Kernel driver i2c-floppy + +Author: Herbert Poetzl + +This driver is for a simple do-it-yourself floppy controller to +I2C adapter which uses direct I/O access to control both Motor +Enable lines (A/B) and read back data via the Disk Changed line. + +The following circuit is not suited to be used together with +a Floppy drive (which would need some logic to work properly) +but as replacement. + + +---+ + | F | Motor Enable A [/MOTEA,10] -------------- SCL + | L | + | O | Motor Enable B [/MOTEB,16] ------+------- SDA + | P | | + | P | | + | Y | Disk Change [/DSKCHG,34] ------+ +-- GND + +-+-+ | + | | + GND GND + +The Motor Enable output of floppy disk controllers is an open +drain output (48mA), usually pulled up to +5V via 1k or higher, +and the Disk Change is a Schmitt Trigger (0.8V/2.2V) input with +max 150uA input current (data taken from the WD/FDC 37C6xx +Floppy Disk Subsystem Controller datasheets, which basically +combine all the necessary parts of the PC floppy circuit). + +So it should be fine to connect it to all 5V I2C devices, and +most 3.3V devices (which are usually capable of handling 5V +I2C bus voltages). + +Power for those devices can be drawn from either the Floppy +power connector (+5V/+12V) or from the SATA 3.3V lines +(or if you prefer from some external source). diff --git a/Documentation/i2c/busses/i2c-viapro b/Documentation/i2c/busses/i2c-viapro index 1405fb6..22efedf 100644 --- a/Documentation/i2c/busses/i2c-viapro +++ b/Documentation/i2c/busses/i2c-viapro @@ -16,6 +16,9 @@ Supported adapters: * VIA Technologies, Inc. CX700 Datasheet: available on request and under NDA from VIA + * VIA Technologies, Inc. VX800/VX820 + Datasheet: available on http://linux.via.com.tw + Authors: Kyösti Mälkki , Mark D. Studebaker , @@ -49,6 +52,7 @@ Your lspci -n listing must show one of these : device 1106:3372 (VT8237S) device 1106:3287 (VT8251) device 1106:8324 (CX700) + device 1106:8353 (VX800/VX820) If none of these show up, you should look in the BIOS for settings like enable ACPI / SMBus or even USB. @@ -57,5 +61,5 @@ Except for the oldest chips (VT82C596A/B, VT82C686A and most probably VT8231), this driver supports I2C block transactions. Such transactions are mainly useful to read from and write to EEPROMs. -The CX700 additionally appears to support SMBus PEC, although this driver -doesn't implement it yet. +The CX700/VX800/VX820 additionally appears to support SMBus PEC, although +this driver doesn't implement it yet. diff --git a/Documentation/initrd.txt b/Documentation/initrd.txt deleted file mode 100644 index 1ba84f3..0000000 --- a/Documentation/initrd.txt +++ /dev/null @@ -1,366 +0,0 @@ -Using the initial RAM disk (initrd) -=================================== - -Written 1996,2000 by Werner Almesberger and - Hans Lermen - - -initrd provides the capability to load a RAM disk by the boot loader. -This RAM disk can then be mounted as the root file system and programs -can be run from it. Afterwards, a new root file system can be mounted -from a different device. The previous root (from initrd) is then moved -to a directory and can be subsequently unmounted. - -initrd is mainly designed to allow system startup to occur in two phases, -where the kernel comes up with a minimum set of compiled-in drivers, and -where additional modules are loaded from initrd. - -This document gives a brief overview of the use of initrd. A more detailed -discussion of the boot process can be found in [1]. - - -Operation ---------- - -When using initrd, the system typically boots as follows: - - 1) the boot loader loads the kernel and the initial RAM disk - 2) the kernel converts initrd into a "normal" RAM disk and - frees the memory used by initrd - 3) if the root device is not /dev/ram0, the old (deprecated) - change_root procedure is followed. see the "Obsolete root change - mechanism" section below. - 4) root device is mounted. if it is /dev/ram0, the initrd image is - then mounted as root - 5) /sbin/init is executed (this can be any valid executable, including - shell scripts; it is run with uid 0 and can do basically everything - init can do). - 6) init mounts the "real" root file system - 7) init places the root file system at the root directory using the - pivot_root system call - 8) init execs the /sbin/init on the new root filesystem, performing - the usual boot sequence - 9) the initrd file system is removed - -Note that changing the root directory does not involve unmounting it. -It is therefore possible to leave processes running on initrd during that -procedure. Also note that file systems mounted under initrd continue to -be accessible. - - -Boot command-line options -------------------------- - -initrd adds the following new options: - - initrd= (e.g. LOADLIN) - - Loads the specified file as the initial RAM disk. When using LILO, you - have to specify the RAM disk image file in /etc/lilo.conf, using the - INITRD configuration variable. - - noinitrd - - initrd data is preserved but it is not converted to a RAM disk and - the "normal" root file system is mounted. initrd data can be read - from /dev/initrd. Note that the data in initrd can have any structure - in this case and doesn't necessarily have to be a file system image. - This option is used mainly for debugging. - - Note: /dev/initrd is read-only and it can only be used once. As soon - as the last process has closed it, all data is freed and /dev/initrd - can't be opened anymore. - - root=/dev/ram0 - - initrd is mounted as root, and the normal boot procedure is followed, - with the RAM disk mounted as root. - -Compressed cpio images ----------------------- - -Recent kernels have support for populating a ramdisk from a compressed cpio -archive. On such systems, the creation of a ramdisk image doesn't need to -involve special block devices or loopbacks; you merely create a directory on -disk with the desired initrd content, cd to that directory, and run (as an -example): - -find . | cpio --quiet -H newc -o | gzip -9 -n > /boot/imagefile.img - -Examining the contents of an existing image file is just as simple: - -mkdir /tmp/imagefile -cd /tmp/imagefile -gzip -cd /boot/imagefile.img | cpio -imd --quiet - -Installation ------------- - -First, a directory for the initrd file system has to be created on the -"normal" root file system, e.g. - -# mkdir /initrd - -The name is not relevant. More details can be found on the pivot_root(2) -man page. - -If the root file system is created during the boot procedure (i.e. if -you're building an install floppy), the root file system creation -procedure should create the /initrd directory. - -If initrd will not be mounted in some cases, its content is still -accessible if the following device has been created: - -# mknod /dev/initrd b 1 250 -# chmod 400 /dev/initrd - -Second, the kernel has to be compiled with RAM disk support and with -support for the initial RAM disk enabled. Also, at least all components -needed to execute programs from initrd (e.g. executable format and file -system) must be compiled into the kernel. - -Third, you have to create the RAM disk image. This is done by creating a -file system on a block device, copying files to it as needed, and then -copying the content of the block device to the initrd file. With recent -kernels, at least three types of devices are suitable for that: - - - a floppy disk (works everywhere but it's painfully slow) - - a RAM disk (fast, but allocates physical memory) - - a loopback device (the most elegant solution) - -We'll describe the loopback device method: - - 1) make sure loopback block devices are configured into the kernel - 2) create an empty file system of the appropriate size, e.g. - # dd if=/dev/zero of=initrd bs=300k count=1 - # mke2fs -F -m0 initrd - (if space is critical, you may want to use the Minix FS instead of Ext2) - 3) mount the file system, e.g. - # mount -t ext2 -o loop initrd /mnt - 4) create the console device: - # mkdir /mnt/dev - # mknod /mnt/dev/console c 5 1 - 5) copy all the files that are needed to properly use the initrd - environment. Don't forget the most important file, /sbin/init - Note that /sbin/init's permissions must include "x" (execute). - 6) correct operation the initrd environment can frequently be tested - even without rebooting with the command - # chroot /mnt /sbin/init - This is of course limited to initrds that do not interfere with the - general system state (e.g. by reconfiguring network interfaces, - overwriting mounted devices, trying to start already running demons, - etc. Note however that it is usually possible to use pivot_root in - such a chroot'ed initrd environment.) - 7) unmount the file system - # umount /mnt - 8) the initrd is now in the file "initrd". Optionally, it can now be - compressed - # gzip -9 initrd - -For experimenting with initrd, you may want to take a rescue floppy and -only add a symbolic link from /sbin/init to /bin/sh. Alternatively, you -can try the experimental newlib environment [2] to create a small -initrd. - -Finally, you have to boot the kernel and load initrd. Almost all Linux -boot loaders support initrd. Since the boot process is still compatible -with an older mechanism, the following boot command line parameters -have to be given: - - root=/dev/ram0 rw - -(rw is only necessary if writing to the initrd file system.) - -With LOADLIN, you simply execute - - LOADLIN initrd= -e.g. LOADLIN C:\LINUX\BZIMAGE initrd=C:\LINUX\INITRD.GZ root=/dev/ram0 rw - -With LILO, you add the option INITRD= to either the global section -or to the section of the respective kernel in /etc/lilo.conf, and pass -the options using APPEND, e.g. - - image = /bzImage - initrd = /boot/initrd.gz - append = "root=/dev/ram0 rw" - -and run /sbin/lilo - -For other boot loaders, please refer to the respective documentation. - -Now you can boot and enjoy using initrd. - - -Changing the root device ------------------------- - -When finished with its duties, init typically changes the root device -and proceeds with starting the Linux system on the "real" root device. - -The procedure involves the following steps: - - mounting the new root file system - - turning it into the root file system - - removing all accesses to the old (initrd) root file system - - unmounting the initrd file system and de-allocating the RAM disk - -Mounting the new root file system is easy: it just needs to be mounted on -a directory under the current root. Example: - -# mkdir /new-root -# mount -o ro /dev/hda1 /new-root - -The root change is accomplished with the pivot_root system call, which -is also available via the pivot_root utility (see pivot_root(8) man -page; pivot_root is distributed with util-linux version 2.10h or higher -[3]). pivot_root moves the current root to a directory under the new -root, and puts the new root at its place. The directory for the old root -must exist before calling pivot_root. Example: - -# cd /new-root -# mkdir initrd -# pivot_root . initrd - -Now, the init process may still access the old root via its -executable, shared libraries, standard input/output/error, and its -current root directory. All these references are dropped by the -following command: - -# exec chroot . what-follows dev/console 2>&1 - -Where what-follows is a program under the new root, e.g. /sbin/init -If the new root file system will be used with udev and has no valid -/dev directory, udev must be initialized before invoking chroot in order -to provide /dev/console. - -Note: implementation details of pivot_root may change with time. In order -to ensure compatibility, the following points should be observed: - - - before calling pivot_root, the current directory of the invoking - process should point to the new root directory - - use . as the first argument, and the _relative_ path of the directory - for the old root as the second argument - - a chroot program must be available under the old and the new root - - chroot to the new root afterwards - - use relative paths for dev/console in the exec command - -Now, the initrd can be unmounted and the memory allocated by the RAM -disk can be freed: - -# umount /initrd -# blockdev --flushbufs /dev/ram0 - -It is also possible to use initrd with an NFS-mounted root, see the -pivot_root(8) man page for details. - - -Usage scenarios ---------------- - -The main motivation for implementing initrd was to allow for modular -kernel configuration at system installation. The procedure would work -as follows: - - 1) system boots from floppy or other media with a minimal kernel - (e.g. support for RAM disks, initrd, a.out, and the Ext2 FS) and - loads initrd - 2) /sbin/init determines what is needed to (1) mount the "real" root FS - (i.e. device type, device drivers, file system) and (2) the - distribution media (e.g. CD-ROM, network, tape, ...). This can be - done by asking the user, by auto-probing, or by using a hybrid - approach. - 3) /sbin/init loads the necessary kernel modules - 4) /sbin/init creates and populates the root file system (this doesn't - have to be a very usable system yet) - 5) /sbin/init invokes pivot_root to change the root file system and - execs - via chroot - a program that continues the installation - 6) the boot loader is installed - 7) the boot loader is configured to load an initrd with the set of - modules that was used to bring up the system (e.g. /initrd can be - modified, then unmounted, and finally, the image is written from - /dev/ram0 or /dev/rd/0 to a file) - 8) now the system is bootable and additional installation tasks can be - performed - -The key role of initrd here is to re-use the configuration data during -normal system operation without requiring the use of a bloated "generic" -kernel or re-compiling or re-linking the kernel. - -A second scenario is for installations where Linux runs on systems with -different hardware configurations in a single administrative domain. In -such cases, it is desirable to generate only a small set of kernels -(ideally only one) and to keep the system-specific part of configuration -information as small as possible. In this case, a common initrd could be -generated with all the necessary modules. Then, only /sbin/init or a file -read by it would have to be different. - -A third scenario is more convenient recovery disks, because information -like the location of the root FS partition doesn't have to be provided at -boot time, but the system loaded from initrd can invoke a user-friendly -dialog and it can also perform some sanity checks (or even some form of -auto-detection). - -Last not least, CD-ROM distributors may use it for better installation -from CD, e.g. by using a boot floppy and bootstrapping a bigger RAM disk -via initrd from CD; or by booting via a loader like LOADLIN or directly -from the CD-ROM, and loading the RAM disk from CD without need of -floppies. - - -Obsolete root change mechanism ------------------------------- - -The following mechanism was used before the introduction of pivot_root. -Current kernels still support it, but you should _not_ rely on its -continued availability. - -It works by mounting the "real" root device (i.e. the one set with rdev -in the kernel image or with root=... at the boot command line) as the -root file system when linuxrc exits. The initrd file system is then -unmounted, or, if it is still busy, moved to a directory /initrd, if -such a directory exists on the new root file system. - -In order to use this mechanism, you do not have to specify the boot -command options root, init, or rw. (If specified, they will affect -the real root file system, not the initrd environment.) - -If /proc is mounted, the "real" root device can be changed from within -linuxrc by writing the number of the new root FS device to the special -file /proc/sys/kernel/real-root-dev, e.g. - - # echo 0x301 >/proc/sys/kernel/real-root-dev - -Note that the mechanism is incompatible with NFS and similar file -systems. - -This old, deprecated mechanism is commonly called "change_root", while -the new, supported mechanism is called "pivot_root". - - -Mixed change_root and pivot_root mechanism ------------------------------------------- - -In case you did not want to use root=/dev/ram0 to trigger the pivot_root -mechanism, you may create both /linuxrc and /sbin/init in your initrd image. - -/linuxrc would contain only the following: - -#! /bin/sh -mount -n -t proc proc /proc -echo 0x0100 >/proc/sys/kernel/real-root-dev -umount -n /proc - -Once linuxrc exited, the kernel would mount again your initrd as root, -this time executing /sbin/init. Again, it would be the duty of this init -to build the right environment (maybe using the root= device passed on -the cmdline) before the final execution of the real /sbin/init. - - -Resources ---------- - -[1] Almesberger, Werner; "Booting Linux: The History and the Future" - http://www.almesberger.net/cv/papers/ols2k-9.ps.gz -[2] newlib package (experimental), with initrd example - http://sources.redhat.com/newlib/ -[3] Brouwer, Andries; "util-linux: Miscellaneous utilities for Linux" - ftp://ftp.win.tue.nl/pub/linux-local/utils/util-linux/ diff --git a/Documentation/ioctl-number.txt b/Documentation/ioctl-number.txt index 1c6b545..f8deb85 100644 --- a/Documentation/ioctl-number.txt +++ b/Documentation/ioctl-number.txt @@ -110,6 +110,8 @@ Code Seq# Include File Comments 'W' 00-1F linux/wanrouter.h conflict! 'X' all linux/xfs_fs.h 'Y' all linux/cyclades.h +'[' 00-07 linux/usb/usbtmc.h USB Test and Measurement Devices + 'a' all ATM on linux 'b' 00-FF bit3 vme host bridge diff --git a/Documentation/ja_JP/SubmittingPatches b/Documentation/ja_JP/SubmittingPatches index a9dc124..4230c39 100644 --- a/Documentation/ja_JP/SubmittingPatches +++ b/Documentation/ja_JP/SubmittingPatches @@ -195,7 +195,7 @@ VGER.KERNEL.ORG ã§ãƒ›ã‚¹ãƒ†ã‚£ãƒ³ã‚°ã•ã‚Œã¦ã„るメーリングリスト㮠ãŸã¨ãˆã€ãƒ¡ãƒ³ãƒ†ãƒŠãŒ #4 ã§åå¿œãŒãªã‹ã£ãŸã¨ã—ã¦ã‚‚ã€ãƒ¡ãƒ³ãƒ†ãƒŠã®ã‚³ãƒ¼ãƒ‰ã«å¤‰æ›´ã‚’ 加ãˆãŸã¨ãã«ã¯ã€ã„ã¤ã‚‚メンテナ㫠CC ã™ã‚‹ã®ã‚’忘れãªã„よã†ã«ã—ã¦ãã ã•ã„。 -å°ã•ãªãƒ‘ッãƒã§ã‚ã‚Œã°ã€Adrian Bunk ãŒç®¡ç†ã—ã¦ã„ã‚‹ Trivial Patch Monkey +å°ã•ãªãƒ‘ッãƒã§ã‚ã‚Œã°ã€Jesper Juhl ãŒç®¡ç†ã—ã¦ã„ã‚‹ Trivial Patch Monkey (ã¡ã‚‡ã£ã¨ã—ãŸãƒ‘ッãƒã‚’集ã‚ã¦ã„ã‚‹)ã« CC ã—ã¦ã‚‚ã„ã„ ã§ã™ã€‚ã¡ã‚‡ã£ã¨ã—ãŸãƒ‘ッãƒã¨ã¯ä»¥ä¸‹ã®ãƒ«ãƒ¼ãƒ«ã®ã©ã‚Œã‹1ã¤ã‚’満ãŸã—ã¦ã„ãªã‘ ã‚Œã°ãªã‚Šã¾ã›ã‚“。 @@ -210,7 +210,7 @@ VGER.KERNEL.ORG ã§ãƒ›ã‚¹ãƒ†ã‚£ãƒ³ã‚°ã•ã‚Œã¦ã„るメーリングリスト㮠・移æ¤æ€§ã®ãªã„コードã‹ã‚‰ç§»æ¤æ€§ã®ã‚るコードã¸ã®ç½®ãæ›ãˆ(å°ã•ã„範囲㧠ã‚ã‚Œã°ã‚¢ãƒ¼ã‚­ãƒ†ã‚¯ãƒãƒ£ç‰¹æœ‰ã®ã“ã¨ã§ã‚‚ä»–ã®äººãŒã‚³ãƒ”ーã§ãã¾ã™) ・作者やメンテナã«ã‚ˆã‚‹ä¿®æ­£(ã™ãªã‚ã¡ patch monkey ã®å†è»¢é€ãƒ¢ãƒ¼ãƒ‰) -URL: +URL: 7) MIME やリンクや圧縮ファイルや添付ファイルã§ã¯ãªãプレインテキストã®ã¿ diff --git a/Documentation/kernel-parameters.txt b/Documentation/kernel-parameters.txt index 1150444..e674698 100644 --- a/Documentation/kernel-parameters.txt +++ b/Documentation/kernel-parameters.txt @@ -49,6 +49,7 @@ parameter is applicable: ISAPNP ISA PnP code is enabled. ISDN Appropriate ISDN support is enabled. JOY Appropriate joystick support is enabled. + KMEMTRACE kmemtrace is enabled. LIBATA Libata driver is enabled LP Printer support is enabled. LOOP Loopback device support is enabled. @@ -101,6 +102,7 @@ parameter is applicable: X86-64 X86-64 architecture is enabled. More X86-64 boot options can be found in Documentation/x86_64/boot-options.txt . + X86 Either 32bit or 64bit x86 (same as X86-32+X86-64) In addition, the following text indicates that the option: @@ -197,40 +199,104 @@ and is between 256 and 4096 characters. It is defined in the file that require a timer override, but don't have HPET + acpi_backlight= [HW,ACPI] + acpi_backlight=vendor + acpi_backlight=video + If set to vendor, it enforces the use of a + vendor specific ACPI driver for backlight switching + (e.g. thinkpad_acpi, sony_acpi, etc.) instead + of the video.ko driver. + + acpi_display_output= [HW,ACPI] + acpi_display_output=vendor + acpi_display_output=video + See above. + acpi.debug_layer= [HW,ACPI] Format: Each bit of the indicates an ACPI debug layer, - 1: enable, 0: disable. It is useful for boot time - debugging. After system has booted up, it can be set - via /sys/module/acpi/parameters/debug_layer. - CONFIG_ACPI_DEBUG must be enabled for this to produce any output. - Available bits (add the numbers together) to enable debug output - for specific parts of the ACPI subsystem: - 0x01 utilities 0x02 hardware 0x04 events 0x08 tables - 0x10 namespace 0x20 parser 0x40 dispatcher - 0x80 executer 0x100 resources 0x200 acpica debugger - 0x400 os services 0x800 acpica disassembler. - The number can be in decimal or prefixed with 0x in hex. - Warning: Many of these options can produce a lot of - output and make your system unusable. Be very careful. + which corresponds to the _COMPONENT definition in + ACPI source files. After system has booted, this mask + can be set via /sys/module/acpi/parameters/debug_layer. + + CONFIG_ACPI_DEBUG must be enabled for this to produce + any output. The number can be in decimal or prefixed + with 0x in hex. Some of these options produce so much + output that the system is unusable. + + The following are some of the global components + defined by the ACPI CA and the Linux OSPM: + 0x01 utilities + 0x02 hardware + 0x04 events + 0x08 tables + 0x10 namespace + 0x20 parser + 0x40 dispatcher + 0x80 executer + 0x100 resources + 0x200 ACPI CA debugger + 0x400 OS services + 0x800 ACPI CA disassembler + 0x40000 battery + 0x80000 button + 0x200000 fan + 0x400000 PCI + 0x10000000 bay + + Many others, e.g., ACPI_BUS_COMPONENT and + ACPI_AC_COMPONENT, are defined by the Linux OSPM and + individual drivers. + + For debugging PCI/_PRT issues (PCI, info msgs): + acpi.debug_layer=0x400000 acpi.debug_level=0x10 + For ACPI hardware issues (hardware, all msgs): + acpi.debug_layer=0x2 acpi.debug_level=0xffffffff acpi.debug_level= [HW,ACPI] Format: Each bit of the indicates an ACPI debug level, - 1: enable, 0: disable. It is useful for boot time - debugging. After system has booted up, it can be set - via /sys/module/acpi/parameters/debug_level. - CONFIG_ACPI_DEBUG must be enabled for this to produce any output. - Available bits (add the numbers together) to enable different - debug output levels of the ACPI subsystem: - 0x01 error 0x02 warn 0x04 init 0x08 debug object - 0x10 info 0x20 init names 0x40 parse 0x80 load - 0x100 dispatch 0x200 execute 0x400 names 0x800 operation region - 0x1000 bfield 0x2000 tables 0x4000 values 0x8000 objects - 0x10000 resources 0x20000 user requests 0x40000 package. - The number can be in decimal or prefixed with 0x in hex. - Warning: Many of these options can produce a lot of - output and make your system unusable. Be very careful. + which corresponds to the level in an ACPI_DEBUG_PRINT + statement. After system has booted up, this mask + can be set via /sys/module/acpi/parameters/debug_level. + + CONFIG_ACPI_DEBUG must be enabled for this to produce + any output. The number can be in decimal or prefixed + with 0x in hex. Some of these options produce so much + output that the system is unusable. + + The following global components are defined by the + ACPI CA: + 0x01 error + 0x02 warn + 0x04 init + 0x08 debug object + 0x10 info + 0x20 init names + 0x40 parse + 0x80 load + 0x100 dispatch + 0x200 execute + 0x400 names + 0x800 operation region + 0x1000 bfield + 0x2000 tables + 0x4000 values + 0x8000 objects + 0x10000 resources + 0x20000 user requests + 0x40000 package + The number can be in decimal or prefixed with 0x in hex. + Warning: Many of these options can produce a lot of + output and make your system unusable. Be very careful. + + acpi.power_nocheck= [HW,ACPI] + Format: 1/0 enable/disable the check of power state. + On some bogus BIOS the _PSC object/_STA object of + power resource can't return the correct device power + state. In such case it is unneccessary to check its + power state again in power transition. + 1 : disable the power state check acpi_pm_good [X86-32,X86-64] Override the pmtimer bug detection: force the kernel @@ -659,11 +725,12 @@ and is between 256 and 4096 characters. It is defined in the file earlyprintk= [X86-32,X86-64,SH,BLACKFIN] earlyprintk=vga earlyprintk=serial[,ttySn[,baudrate]] + earlyprintk=dbgp Append ",keep" to not disable it when the real console takes over. - Only vga or serial at a time, not both. + Only vga or serial or usb debug port at a time. Currently only ttyS0 and ttyS1 are supported. @@ -1000,6 +1067,15 @@ and is between 256 and 4096 characters. It is defined in the file use the HighMem zone if it exists, and the Normal zone if it does not. + kmemtrace.enable= [KNL,KMEMTRACE] Format: { yes | no } + Controls whether kmemtrace is enabled + at boot-time. + + kmemtrace.subbufs=n [KNL,KMEMTRACE] Overrides the number of + subbufs kmemtrace's relay channel has. Set this + higher than default (KMEMTRACE_N_SUBBUFS in code) if + you experience buffer overruns. + movablecore=nn[KMG] [KNL,X86-32,IA-64,PPC,X86-64] This parameter is similar to kernelcore except it specifies the amount of memory used for migratable allocations. @@ -1020,6 +1096,10 @@ and is between 256 and 4096 characters. It is defined in the file (only serial suported for now) Format: [,baud] + kmac= [MIPS] korina ethernet MAC address. + Configure the RouterBoard 532 series on-chip + Ethernet adapter MAC address. + l2cr= [PPC] l3cr= [PPC] @@ -1425,6 +1505,12 @@ and is between 256 and 4096 characters. It is defined in the file nolapic_timer [X86-32,APIC] Do not use the local APIC timer. + nox2apic [X86-64,APIC] Do not enable x2APIC mode. + + x2apic_phys [X86-64,APIC] Use x2apic physical mode instead of + default x2apic cluster mode on platforms + supporting x2apic. + noltlbs [PPC] Do not use large page/tlb entries for kernel lowmem mapping on PPC40x. @@ -1544,7 +1630,7 @@ and is between 256 and 4096 characters. It is defined in the file See also Documentation/paride.txt. pci=option[,option...] [PCI] various PCI subsystem options: - off [X86-32] don't probe for the PCI bus + off [X86] don't probe for the PCI bus bios [X86-32] force use of PCI BIOS, don't access the hardware directly. Use this if your machine has a non-standard PCI host bridge. @@ -1552,9 +1638,9 @@ and is between 256 and 4096 characters. It is defined in the file hardware access methods are allowed. Use this if you experience crashes upon bootup and you suspect they are caused by the BIOS. - conf1 [X86-32] Force use of PCI Configuration + conf1 [X86] Force use of PCI Configuration Mechanism 1. - conf2 [X86-32] Force use of PCI Configuration + conf2 [X86] Force use of PCI Configuration Mechanism 2. noaer [PCIE] If the PCIEAER kernel config parameter is enabled, this kernel boot option can be used to @@ -1574,37 +1660,37 @@ and is between 256 and 4096 characters. It is defined in the file this option if the kernel is unable to allocate IRQs or discover secondary PCI buses on your motherboard. - rom [X86-32] Assign address space to expansion ROMs. + rom [X86] Assign address space to expansion ROMs. Use with caution as certain devices share address decoders between ROMs and other resources. - norom [X86-32,X86_64] Do not assign address space to + norom [X86] Do not assign address space to expansion ROMs that do not already have BIOS assigned address ranges. - irqmask=0xMMMM [X86-32] Set a bit mask of IRQs allowed to be + irqmask=0xMMMM [X86] Set a bit mask of IRQs allowed to be assigned automatically to PCI devices. You can make the kernel exclude IRQs of your ISA cards this way. - pirqaddr=0xAAAAA [X86-32] Specify the physical address + pirqaddr=0xAAAAA [X86] Specify the physical address of the PIRQ table (normally generated by the BIOS) if it is outside the F0000h-100000h range. - lastbus=N [X86-32] Scan all buses thru bus #N. Can be + lastbus=N [X86] Scan all buses thru bus #N. Can be useful if the kernel is unable to find your secondary buses and you want to tell it explicitly which ones they are. - assign-busses [X86-32] Always assign all PCI bus + assign-busses [X86] Always assign all PCI bus numbers ourselves, overriding whatever the firmware may have done. - usepirqmask [X86-32] Honor the possible IRQ mask stored + usepirqmask [X86] Honor the possible IRQ mask stored in the BIOS $PIR table. This is needed on some systems with broken BIOSes, notably some HP Pavilion N5400 and Omnibook XE3 notebooks. This will have no effect if ACPI IRQ routing is enabled. - noacpi [X86-32] Do not use ACPI for IRQ routing + noacpi [X86] Do not use ACPI for IRQ routing or for PCI scanning. - use_crs [X86-32] Use _CRS for PCI resource + use_crs [X86] Use _CRS for PCI resource allocation. routeirq Do IRQ routing for all PCI devices. This is normally done in pci_enable_device(), @@ -1660,6 +1746,10 @@ and is between 256 and 4096 characters. It is defined in the file Override pmtimer IOPort with a hex value. e.g. pmtmr=0x508 + pnp.debug [PNP] + Enable PNP debug messages. This depends on the + CONFIG_PNP_DEBUG_MESSAGES option. + pnpacpi= [ACPI] { off } @@ -1680,6 +1770,11 @@ and is between 256 and 4096 characters. It is defined in the file autoconfiguration. Ranges are in pairs (memory base and size). + dynamic_printk + Enables pr_debug()/dev_dbg() calls if + CONFIG_DYNAMIC_PRINTK_DEBUG has been enabled. These can also + be switched on/off via /dynamic_printk/modules + print-fatal-signals= [KNL] debug: print fatal signals print-fatal-signals=1: print segfault info to @@ -1882,6 +1977,12 @@ and is between 256 and 4096 characters. It is defined in the file shapers= [NET] Maximal number of shapers. + show_msr= [x86] show boot-time MSR settings + Format: { } + Show boot-time (BIOS-initialized) MSR settings. + The parameter means the number of CPUs to show, + for example 1 means boot CPU only. + sim710= [SCSI,HW] See header of drivers/scsi/sim710.c. diff --git a/Documentation/kmemcheck.txt b/Documentation/kmemcheck.txt new file mode 100644 index 0000000..843a63c --- /dev/null +++ b/Documentation/kmemcheck.txt @@ -0,0 +1,135 @@ +Contents +======== + + 1. How to use + 2. Technical description + 3. Changes to the slab allocators + 4. Problems + 5. Parameters + 6. Future enhancements + + +How to use (IMPORTANT) +====================== + +Always remember this: kmemcheck _will_ give false positives. So don't enable +it and spam the mailing list with its reports; you are not going to be heard, +and it will make people's skins thicker for when the real errors are found. + +Instead, I encourage maintainers and developers to find errors in _their_ +_own_ code. And if you find false positives, you can try to work around them, +try to figure out if it's a real bug or not, or simply ignore them. Most +developers know their own code and will quickly and efficiently determine the +root cause of a kmemcheck report. This is therefore also the most efficient +way to work with kmemcheck. + +If you still want to run kmemcheck to inspect others' code, the rule of thumb +should be: If it's not obvious (to you), don't tell us about it either. Most +likely the code is correct and you'll only waste our time. If you can work +out the error, please do send the maintainer a heads up and/or a patch, but +don't expect him/her to fix something that wasn't wrong in the first place. + + +Technical description +===================== + +kmemcheck works by marking memory pages non-present. This means that whenever +somebody attempts to access the page, a page fault is generated. The page +fault handler notices that the page was in fact only hidden, and so it calls +on the kmemcheck code to make further investigations. + +When the investigations are completed, kmemcheck "shows" the page by marking +it present (as it would be under normal circumstances). This way, the +interrupted code can continue as usual. + +But after the instruction has been executed, we should hide the page again, so +that we can catch the next access too! Now kmemcheck makes use of a debugging +feature of the processor, namely single-stepping. When the processor has +finished the one instruction that generated the memory access, a debug +exception is raised. From here, we simply hide the page again and continue +execution, this time with the single-stepping feature turned off. + + +Changes to the slab allocators +============================== + +kmemcheck requires some assistance from the memory allocator in order to work. +The memory allocator needs to + +1. Tell kmemcheck about newly allocated pages and pages that are about to + be freed. This allows kmemcheck to set up and tear down the shadow memory + for the pages in question. The shadow memory stores the status of each byte + in the allocation proper, e.g. whether it is initialized or uninitialized. +2. Tell kmemcheck which parts of memory should be marked uninitialized. There + are actually a few more states, such as "not yet allocated" and "recently + freed". + +If a slab cache is set up using the SLAB_NOTRACK flag, it will never return +memory that can take page faults because of kmemcheck. + +If a slab cache is NOT set up using the SLAB_NOTRACK flag, callers can still +request memory with the __GFP_NOTRACK flag. This does not prevent the page +faults from occurring, however, but marks the object in question as being +initialized so that no warnings will ever be produced for this object. + +Currently, the SLAB and SLUB allocators are supported by kmemcheck. + + +Problems +======== + +The most prominent problem seems to be that of bit-fields. kmemcheck can only +track memory with byte granularity. Therefore, when gcc generates code to +access only one bit in a bit-field, there is really no way for kmemcheck to +know which of the other bits will be used or thrown away. Consequently, there +may be bogus warnings for bit-field accesses. There is some experimental +support to detect this automatically, though it is probably better to work +around this by explicitly initializing whole bit-fields at once. + +Some allocations are used for DMA. As DMA doesn't go through the paging +mechanism, we have absolutely no way to detect DMA writes. This means that +spurious warnings may be seen on access to DMA memory. DMA allocations should +be annotated with the __GFP_NOTRACK flag or allocated from caches marked +SLAB_NOTRACK to work around this problem. + + +Parameters +========== + +In addition to enabling CONFIG_KMEMCHECK before the kernel is compiled, the +parameter kmemcheck=1 must be passed to the kernel when it is started in order +to actually do the tracking. So by default, there is only a very small +(probably negligible) overhead for enabling the config option. + +Similarly, kmemcheck may be turned on or off at run-time using, respectively: + +echo 1 > /proc/sys/kernel/kmemcheck + and +echo 0 > /proc/sys/kernel/kmemcheck + +Note that this is a lazy setting; once turned off, the old allocations will +still have to take a single page fault exception before tracking is turned off +for that particular page. Enabling kmemcheck on will only enable tracking for +allocations made from that point onwards. + +The default mode is the one-shot mode, where only the first error is reported +before kmemcheck is disabled. This mode can be enabled by passing kmemcheck=2 +to the kernel at boot, or running + +echo 2 > /proc/sys/kernel/kmemcheck + +when the kernel is already running. + + +Future enhancements +=================== + +There is already some preliminary support for catching use-after-free errors. +What still needs to be done is delaying kfree() so that memory is not +reallocated immediately after freeing it. [Suggested by Pekka Enberg.] + +It should be possible to allow SMP systems by duplicating the page tables for +each processor in the system. This is probably extremely difficult, however. +[Suggested by Ingo Molnar.] + +Support for instruction set extensions like XMM, SSE2, etc. diff --git a/Documentation/kobject.txt b/Documentation/kobject.txt index 51a8021..f5d2aad 100644 --- a/Documentation/kobject.txt +++ b/Documentation/kobject.txt @@ -118,6 +118,10 @@ the name of the kobject, call kobject_rename(): int kobject_rename(struct kobject *kobj, const char *new_name); +Note kobject_rename does perform any locking or have a solid notion of +what names are valid so the provide must provide their own sanity checking +and serialization. + There is a function called kobject_set_name() but that is legacy cruft and is being removed. If your code needs to call this function, it is incorrect and needs to be fixed. diff --git a/Documentation/mtd/nand_ecc.txt b/Documentation/mtd/nand_ecc.txt new file mode 100644 index 0000000..bdf93b7 --- /dev/null +++ b/Documentation/mtd/nand_ecc.txt @@ -0,0 +1,714 @@ +Introduction +============ + +Having looked at the linux mtd/nand driver and more specific at nand_ecc.c +I felt there was room for optimisation. I bashed the code for a few hours +performing tricks like table lookup removing superfluous code etc. +After that the speed was increased by 35-40%. +Still I was not too happy as I felt there was additional room for improvement. + +Bad! I was hooked. +I decided to annotate my steps in this file. Perhaps it is useful to someone +or someone learns something from it. + + +The problem +=========== + +NAND flash (at least SLC one) typically has sectors of 256 bytes. +However NAND flash is not extremely reliable so some error detection +(and sometimes correction) is needed. + +This is done by means of a Hamming code. I'll try to explain it in +laymans terms (and apologies to all the pro's in the field in case I do +not use the right terminology, my coding theory class was almost 30 +years ago, and I must admit it was not one of my favourites). + +As I said before the ecc calculation is performed on sectors of 256 +bytes. This is done by calculating several parity bits over the rows and +columns. The parity used is even parity which means that the parity bit = 1 +if the data over which the parity is calculated is 1 and the parity bit = 0 +if the data over which the parity is calculated is 0. So the total +number of bits over the data over which the parity is calculated + the +parity bit is even. (see wikipedia if you can't follow this). +Parity is often calculated by means of an exclusive or operation, +sometimes also referred to as xor. In C the operator for xor is ^ + +Back to ecc. +Let's give a small figure: + +byte 0: bit7 bit6 bit5 bit4 bit3 bit2 bit1 bit0 rp0 rp2 rp4 ... rp14 +byte 1: bit7 bit6 bit5 bit4 bit3 bit2 bit1 bit0 rp1 rp2 rp4 ... rp14 +byte 2: bit7 bit6 bit5 bit4 bit3 bit2 bit1 bit0 rp0 rp3 rp4 ... rp14 +byte 3: bit7 bit6 bit5 bit4 bit3 bit2 bit1 bit0 rp1 rp3 rp4 ... rp14 +byte 4: bit7 bit6 bit5 bit4 bit3 bit2 bit1 bit0 rp0 rp2 rp5 ... rp14 +.... +byte 254: bit7 bit6 bit5 bit4 bit3 bit2 bit1 bit0 rp0 rp3 rp5 ... rp15 +byte 255: bit7 bit6 bit5 bit4 bit3 bit2 bit1 bit0 rp1 rp3 rp5 ... rp15 + cp1 cp0 cp1 cp0 cp1 cp0 cp1 cp0 + cp3 cp3 cp2 cp2 cp3 cp3 cp2 cp2 + cp5 cp5 cp5 cp5 cp4 cp4 cp4 cp4 + +This figure represents a sector of 256 bytes. +cp is my abbreviaton for column parity, rp for row parity. + +Let's start to explain column parity. +cp0 is the parity that belongs to all bit0, bit2, bit4, bit6. +so the sum of all bit0, bit2, bit4 and bit6 values + cp0 itself is even. +Similarly cp1 is the sum of all bit1, bit3, bit5 and bit7. +cp2 is the parity over bit0, bit1, bit4 and bit5 +cp3 is the parity over bit2, bit3, bit6 and bit7. +cp4 is the parity over bit0, bit1, bit2 and bit3. +cp5 is the parity over bit4, bit5, bit6 and bit7. +Note that each of cp0 .. cp5 is exactly one bit. + +Row parity actually works almost the same. +rp0 is the parity of all even bytes (0, 2, 4, 6, ... 252, 254) +rp1 is the parity of all odd bytes (1, 3, 5, 7, ..., 253, 255) +rp2 is the parity of all bytes 0, 1, 4, 5, 8, 9, ... +(so handle two bytes, then skip 2 bytes). +rp3 is covers the half rp2 does not cover (bytes 2, 3, 6, 7, 10, 11, ...) +for rp4 the rule is cover 4 bytes, skip 4 bytes, cover 4 bytes, skip 4 etc. +so rp4 calculates parity over bytes 0, 1, 2, 3, 8, 9, 10, 11, 16, ...) +and rp5 covers the other half, so bytes 4, 5, 6, 7, 12, 13, 14, 15, 20, .. +The story now becomes quite boring. I guess you get the idea. +rp6 covers 8 bytes then skips 8 etc +rp7 skips 8 bytes then covers 8 etc +rp8 covers 16 bytes then skips 16 etc +rp9 skips 16 bytes then covers 16 etc +rp10 covers 32 bytes then skips 32 etc +rp11 skips 32 bytes then covers 32 etc +rp12 covers 64 bytes then skips 64 etc +rp13 skips 64 bytes then covers 64 etc +rp14 covers 128 bytes then skips 128 +rp15 skips 128 bytes then covers 128 + +In the end the parity bits are grouped together in three bytes as +follows: +ECC Bit 7 Bit 6 Bit 5 Bit 4 Bit 3 Bit 2 Bit 1 Bit 0 +ECC 0 rp07 rp06 rp05 rp04 rp03 rp02 rp01 rp00 +ECC 1 rp15 rp14 rp13 rp12 rp11 rp10 rp09 rp08 +ECC 2 cp5 cp4 cp3 cp2 cp1 cp0 1 1 + +I detected after writing this that ST application note AN1823 +(http://www.st.com/stonline/books/pdf/docs/10123.pdf) gives a much +nicer picture.(but they use line parity as term where I use row parity) +Oh well, I'm graphically challenged, so suffer with me for a moment :-) +And I could not reuse the ST picture anyway for copyright reasons. + + +Attempt 0 +========= + +Implementing the parity calculation is pretty simple. +In C pseudocode: +for (i = 0; i < 256; i++) +{ + if (i & 0x01) + rp1 = bit7 ^ bit6 ^ bit5 ^ bit4 ^ bit3 ^ bit2 ^ bit1 ^ bit0 ^ rp1; + else + rp0 = bit7 ^ bit6 ^ bit5 ^ bit4 ^ bit3 ^ bit2 ^ bit1 ^ bit0 ^ rp1; + if (i & 0x02) + rp3 = bit7 ^ bit6 ^ bit5 ^ bit4 ^ bit3 ^ bit2 ^ bit1 ^ bit0 ^ rp3; + else + rp2 = bit7 ^ bit6 ^ bit5 ^ bit4 ^ bit3 ^ bit2 ^ bit1 ^ bit0 ^ rp2; + if (i & 0x04) + rp5 = bit7 ^ bit6 ^ bit5 ^ bit4 ^ bit3 ^ bit2 ^ bit1 ^ bit0 ^ rp5; + else + rp4 = bit7 ^ bit6 ^ bit5 ^ bit4 ^ bit3 ^ bit2 ^ bit1 ^ bit0 ^ rp4; + if (i & 0x08) + rp7 = bit7 ^ bit6 ^ bit5 ^ bit4 ^ bit3 ^ bit2 ^ bit1 ^ bit0 ^ rp7; + else + rp6 = bit7 ^ bit6 ^ bit5 ^ bit4 ^ bit3 ^ bit2 ^ bit1 ^ bit0 ^ rp6; + if (i & 0x10) + rp9 = bit7 ^ bit6 ^ bit5 ^ bit4 ^ bit3 ^ bit2 ^ bit1 ^ bit0 ^ rp9; + else + rp8 = bit7 ^ bit6 ^ bit5 ^ bit4 ^ bit3 ^ bit2 ^ bit1 ^ bit0 ^ rp8; + if (i & 0x20) + rp11 = bit7 ^ bit6 ^ bit5 ^ bit4 ^ bit3 ^ bit2 ^ bit1 ^ bit0 ^ rp11; + else + rp10 = bit7 ^ bit6 ^ bit5 ^ bit4 ^ bit3 ^ bit2 ^ bit1 ^ bit0 ^ rp10; + if (i & 0x40) + rp13 = bit7 ^ bit6 ^ bit5 ^ bit4 ^ bit3 ^ bit2 ^ bit1 ^ bit0 ^ rp13; + else + rp12 = bit7 ^ bit6 ^ bit5 ^ bit4 ^ bit3 ^ bit2 ^ bit1 ^ bit0 ^ rp12; + if (i & 0x80) + rp15 = bit7 ^ bit6 ^ bit5 ^ bit4 ^ bit3 ^ bit2 ^ bit1 ^ bit0 ^ rp15; + else + rp14 = bit7 ^ bit6 ^ bit5 ^ bit4 ^ bit3 ^ bit2 ^ bit1 ^ bit0 ^ rp14; + cp0 = bit6 ^ bit4 ^ bit2 ^ bit0 ^ cp0; + cp1 = bit7 ^ bit5 ^ bit3 ^ bit1 ^ cp1; + cp2 = bit5 ^ bit4 ^ bit1 ^ bit0 ^ cp2; + cp3 = bit7 ^ bit6 ^ bit3 ^ bit2 ^ cp3 + cp4 = bit3 ^ bit2 ^ bit1 ^ bit0 ^ cp4 + cp5 = bit7 ^ bit6 ^ bit5 ^ bit4 ^ cp5 +} + + +Analysis 0 +========== + +C does have bitwise operators but not really operators to do the above +efficiently (and most hardware has no such instructions either). +Therefore without implementing this it was clear that the code above was +not going to bring me a Nobel prize :-) + +Fortunately the exclusive or operation is commutative, so we can combine +the values in any order. So instead of calculating all the bits +individually, let us try to rearrange things. +For the column parity this is easy. We can just xor the bytes and in the +end filter out the relevant bits. This is pretty nice as it will bring +all cp calculation out of the if loop. + +Similarly we can first xor the bytes for the various rows. +This leads to: + + +Attempt 1 +========= + +const char parity[256] = { + 0, 1, 1, 0, 1, 0, 0, 1, 1, 0, 0, 1, 0, 1, 1, 0, + 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 1, 0, 0, 1, + 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 1, 0, 0, 1, + 0, 1, 1, 0, 1, 0, 0, 1, 1, 0, 0, 1, 0, 1, 1, 0, + 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 1, 0, 0, 1, + 0, 1, 1, 0, 1, 0, 0, 1, 1, 0, 0, 1, 0, 1, 1, 0, + 0, 1, 1, 0, 1, 0, 0, 1, 1, 0, 0, 1, 0, 1, 1, 0, + 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 1, 0, 0, 1, + 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 1, 0, 0, 1, + 0, 1, 1, 0, 1, 0, 0, 1, 1, 0, 0, 1, 0, 1, 1, 0, + 0, 1, 1, 0, 1, 0, 0, 1, 1, 0, 0, 1, 0, 1, 1, 0, + 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 1, 0, 0, 1, + 0, 1, 1, 0, 1, 0, 0, 1, 1, 0, 0, 1, 0, 1, 1, 0, + 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 1, 0, 0, 1, + 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 1, 0, 0, 1, + 0, 1, 1, 0, 1, 0, 0, 1, 1, 0, 0, 1, 0, 1, 1, 0 +}; + +void ecc1(const unsigned char *buf, unsigned char *code) +{ + int i; + const unsigned char *bp = buf; + unsigned char cur; + unsigned char rp0, rp1, rp2, rp3, rp4, rp5, rp6, rp7; + unsigned char rp8, rp9, rp10, rp11, rp12, rp13, rp14, rp15; + unsigned char par; + + par = 0; + rp0 = 0; rp1 = 0; rp2 = 0; rp3 = 0; + rp4 = 0; rp5 = 0; rp6 = 0; rp7 = 0; + rp8 = 0; rp9 = 0; rp10 = 0; rp11 = 0; + rp12 = 0; rp13 = 0; rp14 = 0; rp15 = 0; + + for (i = 0; i < 256; i++) + { + cur = *bp++; + par ^= cur; + if (i & 0x01) rp1 ^= cur; else rp0 ^= cur; + if (i & 0x02) rp3 ^= cur; else rp2 ^= cur; + if (i & 0x04) rp5 ^= cur; else rp4 ^= cur; + if (i & 0x08) rp7 ^= cur; else rp6 ^= cur; + if (i & 0x10) rp9 ^= cur; else rp8 ^= cur; + if (i & 0x20) rp11 ^= cur; else rp10 ^= cur; + if (i & 0x40) rp13 ^= cur; else rp12 ^= cur; + if (i & 0x80) rp15 ^= cur; else rp14 ^= cur; + } + code[0] = + (parity[rp7] << 7) | + (parity[rp6] << 6) | + (parity[rp5] << 5) | + (parity[rp4] << 4) | + (parity[rp3] << 3) | + (parity[rp2] << 2) | + (parity[rp1] << 1) | + (parity[rp0]); + code[1] = + (parity[rp15] << 7) | + (parity[rp14] << 6) | + (parity[rp13] << 5) | + (parity[rp12] << 4) | + (parity[rp11] << 3) | + (parity[rp10] << 2) | + (parity[rp9] << 1) | + (parity[rp8]); + code[2] = + (parity[par & 0xf0] << 7) | + (parity[par & 0x0f] << 6) | + (parity[par & 0xcc] << 5) | + (parity[par & 0x33] << 4) | + (parity[par & 0xaa] << 3) | + (parity[par & 0x55] << 2); + code[0] = ~code[0]; + code[1] = ~code[1]; + code[2] = ~code[2]; +} + +Still pretty straightforward. The last three invert statements are there to +give a checksum of 0xff 0xff 0xff for an empty flash. In an empty flash +all data is 0xff, so the checksum then matches. + +I also introduced the parity lookup. I expected this to be the fastest +way to calculate the parity, but I will investigate alternatives later +on. + + +Analysis 1 +========== + +The code works, but is not terribly efficient. On my system it took +almost 4 times as much time as the linux driver code. But hey, if it was +*that* easy this would have been done long before. +No pain. no gain. + +Fortunately there is plenty of room for improvement. + +In step 1 we moved from bit-wise calculation to byte-wise calculation. +However in C we can also use the unsigned long data type and virtually +every modern microprocessor supports 32 bit operations, so why not try +to write our code in such a way that we process data in 32 bit chunks. + +Of course this means some modification as the row parity is byte by +byte. A quick analysis: +for the column parity we use the par variable. When extending to 32 bits +we can in the end easily calculate p0 and p1 from it. +(because par now consists of 4 bytes, contributing to rp1, rp0, rp1, rp0 +respectively) +also rp2 and rp3 can be easily retrieved from par as rp3 covers the +first two bytes and rp2 the last two bytes. + +Note that of course now the loop is executed only 64 times (256/4). +And note that care must taken wrt byte ordering. The way bytes are +ordered in a long is machine dependent, and might affect us. +Anyway, if there is an issue: this code is developed on x86 (to be +precise: a DELL PC with a D920 Intel CPU) + +And of course the performance might depend on alignment, but I expect +that the I/O buffers in the nand driver are aligned properly (and +otherwise that should be fixed to get maximum performance). + +Let's give it a try... + + +Attempt 2 +========= + +extern const char parity[256]; + +void ecc2(const unsigned char *buf, unsigned char *code) +{ + int i; + const unsigned long *bp = (unsigned long *)buf; + unsigned long cur; + unsigned long rp0, rp1, rp2, rp3, rp4, rp5, rp6, rp7; + unsigned long rp8, rp9, rp10, rp11, rp12, rp13, rp14, rp15; + unsigned long par; + + par = 0; + rp0 = 0; rp1 = 0; rp2 = 0; rp3 = 0; + rp4 = 0; rp5 = 0; rp6 = 0; rp7 = 0; + rp8 = 0; rp9 = 0; rp10 = 0; rp11 = 0; + rp12 = 0; rp13 = 0; rp14 = 0; rp15 = 0; + + for (i = 0; i < 64; i++) + { + cur = *bp++; + par ^= cur; + if (i & 0x01) rp5 ^= cur; else rp4 ^= cur; + if (i & 0x02) rp7 ^= cur; else rp6 ^= cur; + if (i & 0x04) rp9 ^= cur; else rp8 ^= cur; + if (i & 0x08) rp11 ^= cur; else rp10 ^= cur; + if (i & 0x10) rp13 ^= cur; else rp12 ^= cur; + if (i & 0x20) rp15 ^= cur; else rp14 ^= cur; + } + /* + we need to adapt the code generation for the fact that rp vars are now + long; also the column parity calculation needs to be changed. + we'll bring rp4 to 15 back to single byte entities by shifting and + xoring + */ + rp4 ^= (rp4 >> 16); rp4 ^= (rp4 >> 8); rp4 &= 0xff; + rp5 ^= (rp5 >> 16); rp5 ^= (rp5 >> 8); rp5 &= 0xff; + rp6 ^= (rp6 >> 16); rp6 ^= (rp6 >> 8); rp6 &= 0xff; + rp7 ^= (rp7 >> 16); rp7 ^= (rp7 >> 8); rp7 &= 0xff; + rp8 ^= (rp8 >> 16); rp8 ^= (rp8 >> 8); rp8 &= 0xff; + rp9 ^= (rp9 >> 16); rp9 ^= (rp9 >> 8); rp9 &= 0xff; + rp10 ^= (rp10 >> 16); rp10 ^= (rp10 >> 8); rp10 &= 0xff; + rp11 ^= (rp11 >> 16); rp11 ^= (rp11 >> 8); rp11 &= 0xff; + rp12 ^= (rp12 >> 16); rp12 ^= (rp12 >> 8); rp12 &= 0xff; + rp13 ^= (rp13 >> 16); rp13 ^= (rp13 >> 8); rp13 &= 0xff; + rp14 ^= (rp14 >> 16); rp14 ^= (rp14 >> 8); rp14 &= 0xff; + rp15 ^= (rp15 >> 16); rp15 ^= (rp15 >> 8); rp15 &= 0xff; + rp3 = (par >> 16); rp3 ^= (rp3 >> 8); rp3 &= 0xff; + rp2 = par & 0xffff; rp2 ^= (rp2 >> 8); rp2 &= 0xff; + par ^= (par >> 16); + rp1 = (par >> 8); rp1 &= 0xff; + rp0 = (par & 0xff); + par ^= (par >> 8); par &= 0xff; + + code[0] = + (parity[rp7] << 7) | + (parity[rp6] << 6) | + (parity[rp5] << 5) | + (parity[rp4] << 4) | + (parity[rp3] << 3) | + (parity[rp2] << 2) | + (parity[rp1] << 1) | + (parity[rp0]); + code[1] = + (parity[rp15] << 7) | + (parity[rp14] << 6) | + (parity[rp13] << 5) | + (parity[rp12] << 4) | + (parity[rp11] << 3) | + (parity[rp10] << 2) | + (parity[rp9] << 1) | + (parity[rp8]); + code[2] = + (parity[par & 0xf0] << 7) | + (parity[par & 0x0f] << 6) | + (parity[par & 0xcc] << 5) | + (parity[par & 0x33] << 4) | + (parity[par & 0xaa] << 3) | + (parity[par & 0x55] << 2); + code[0] = ~code[0]; + code[1] = ~code[1]; + code[2] = ~code[2]; +} + +The parity array is not shown any more. Note also that for these +examples I kinda deviated from my regular programming style by allowing +multiple statements on a line, not using { } in then and else blocks +with only a single statement and by using operators like ^= + + +Analysis 2 +========== + +The code (of course) works, and hurray: we are a little bit faster than +the linux driver code (about 15%). But wait, don't cheer too quickly. +THere is more to be gained. +If we look at e.g. rp14 and rp15 we see that we either xor our data with +rp14 or with rp15. However we also have par which goes over all data. +This means there is no need to calculate rp14 as it can be calculated from +rp15 through rp14 = par ^ rp15; +(or if desired we can avoid calculating rp15 and calculate it from +rp14). That is why some places refer to inverse parity. +Of course the same thing holds for rp4/5, rp6/7, rp8/9, rp10/11 and rp12/13. +Effectively this means we can eliminate the else clause from the if +statements. Also we can optimise the calculation in the end a little bit +by going from long to byte first. Actually we can even avoid the table +lookups + +Attempt 3 +========= + +Odd replaced: + if (i & 0x01) rp5 ^= cur; else rp4 ^= cur; + if (i & 0x02) rp7 ^= cur; else rp6 ^= cur; + if (i & 0x04) rp9 ^= cur; else rp8 ^= cur; + if (i & 0x08) rp11 ^= cur; else rp10 ^= cur; + if (i & 0x10) rp13 ^= cur; else rp12 ^= cur; + if (i & 0x20) rp15 ^= cur; else rp14 ^= cur; +with + if (i & 0x01) rp5 ^= cur; + if (i & 0x02) rp7 ^= cur; + if (i & 0x04) rp9 ^= cur; + if (i & 0x08) rp11 ^= cur; + if (i & 0x10) rp13 ^= cur; + if (i & 0x20) rp15 ^= cur; + + and outside the loop added: + rp4 = par ^ rp5; + rp6 = par ^ rp7; + rp8 = par ^ rp9; + rp10 = par ^ rp11; + rp12 = par ^ rp13; + rp14 = par ^ rp15; + +And after that the code takes about 30% more time, although the number of +statements is reduced. This is also reflected in the assembly code. + + +Analysis 3 +========== + +Very weird. Guess it has to do with caching or instruction parallellism +or so. I also tried on an eeePC (Celeron, clocked at 900 Mhz). Interesting +observation was that this one is only 30% slower (according to time) +executing the code as my 3Ghz D920 processor. + +Well, it was expected not to be easy so maybe instead move to a +different track: let's move back to the code from attempt2 and do some +loop unrolling. This will eliminate a few if statements. I'll try +different amounts of unrolling to see what works best. + + +Attempt 4 +========= + +Unrolled the loop 1, 2, 3 and 4 times. +For 4 the code starts with: + + for (i = 0; i < 4; i++) + { + cur = *bp++; + par ^= cur; + rp4 ^= cur; + rp6 ^= cur; + rp8 ^= cur; + rp10 ^= cur; + if (i & 0x1) rp13 ^= cur; else rp12 ^= cur; + if (i & 0x2) rp15 ^= cur; else rp14 ^= cur; + cur = *bp++; + par ^= cur; + rp5 ^= cur; + rp6 ^= cur; + ... + + +Analysis 4 +========== + +Unrolling once gains about 15% +Unrolling twice keeps the gain at about 15% +Unrolling three times gives a gain of 30% compared to attempt 2. +Unrolling four times gives a marginal improvement compared to unrolling +three times. + +I decided to proceed with a four time unrolled loop anyway. It was my gut +feeling that in the next steps I would obtain additional gain from it. + +The next step was triggered by the fact that par contains the xor of all +bytes and rp4 and rp5 each contain the xor of half of the bytes. +So in effect par = rp4 ^ rp5. But as xor is commutative we can also say +that rp5 = par ^ rp4. So no need to keep both rp4 and rp5 around. We can +eliminate rp5 (or rp4, but I already foresaw another optimisation). +The same holds for rp6/7, rp8/9, rp10/11 rp12/13 and rp14/15. + + +Attempt 5 +========= + +Effectively so all odd digit rp assignments in the loop were removed. +This included the else clause of the if statements. +Of course after the loop we need to correct things by adding code like: + rp5 = par ^ rp4; +Also the initial assignments (rp5 = 0; etc) could be removed. +Along the line I also removed the initialisation of rp0/1/2/3. + + +Analysis 5 +========== + +Measurements showed this was a good move. The run-time roughly halved +compared with attempt 4 with 4 times unrolled, and we only require 1/3rd +of the processor time compared to the current code in the linux kernel. + +However, still I thought there was more. I didn't like all the if +statements. Why not keep a running parity and only keep the last if +statement. Time for yet another version! + + +Attempt 6 +========= + +THe code within the for loop was changed to: + + for (i = 0; i < 4; i++) + { + cur = *bp++; tmppar = cur; rp4 ^= cur; + cur = *bp++; tmppar ^= cur; rp6 ^= tmppar; + cur = *bp++; tmppar ^= cur; rp4 ^= cur; + cur = *bp++; tmppar ^= cur; rp8 ^= tmppar; + + cur = *bp++; tmppar ^= cur; rp4 ^= cur; rp6 ^= cur; + cur = *bp++; tmppar ^= cur; rp6 ^= cur; + cur = *bp++; tmppar ^= cur; rp4 ^= cur; + cur = *bp++; tmppar ^= cur; rp10 ^= tmppar; + + cur = *bp++; tmppar ^= cur; rp4 ^= cur; rp6 ^= cur; rp8 ^= cur; + cur = *bp++; tmppar ^= cur; rp6 ^= cur; rp8 ^= cur; + cur = *bp++; tmppar ^= cur; rp4 ^= cur; rp8 ^= cur; + cur = *bp++; tmppar ^= cur; rp8 ^= cur; + + cur = *bp++; tmppar ^= cur; rp4 ^= cur; rp6 ^= cur; + cur = *bp++; tmppar ^= cur; rp6 ^= cur; + cur = *bp++; tmppar ^= cur; rp4 ^= cur; + cur = *bp++; tmppar ^= cur; + + par ^= tmppar; + if ((i & 0x1) == 0) rp12 ^= tmppar; + if ((i & 0x2) == 0) rp14 ^= tmppar; + } + +As you can see tmppar is used to accumulate the parity within a for +iteration. In the last 3 statements is is added to par and, if needed, +to rp12 and rp14. + +While making the changes I also found that I could exploit that tmppar +contains the running parity for this iteration. So instead of having: +rp4 ^= cur; rp6 = cur; +I removed the rp6 = cur; statement and did rp6 ^= tmppar; on next +statement. A similar change was done for rp8 and rp10 + + +Analysis 6 +========== + +Measuring this code again showed big gain. When executing the original +linux code 1 million times, this took about 1 second on my system. +(using time to measure the performance). After this iteration I was back +to 0.075 sec. Actually I had to decide to start measuring over 10 +million interations in order not to loose too much accuracy. This one +definitely seemed to be the jackpot! + +There is a little bit more room for improvement though. There are three +places with statements: +rp4 ^= cur; rp6 ^= cur; +It seems more efficient to also maintain a variable rp4_6 in the while +loop; This eliminates 3 statements per loop. Of course after the loop we +need to correct by adding: + rp4 ^= rp4_6; + rp6 ^= rp4_6 +Furthermore there are 4 sequential assingments to rp8. This can be +encoded slightly more efficient by saving tmppar before those 4 lines +and later do rp8 = rp8 ^ tmppar ^ notrp8; +(where notrp8 is the value of rp8 before those 4 lines). +Again a use of the commutative property of xor. +Time for a new test! + + +Attempt 7 +========= + +The new code now looks like: + + for (i = 0; i < 4; i++) + { + cur = *bp++; tmppar = cur; rp4 ^= cur; + cur = *bp++; tmppar ^= cur; rp6 ^= tmppar; + cur = *bp++; tmppar ^= cur; rp4 ^= cur; + cur = *bp++; tmppar ^= cur; rp8 ^= tmppar; + + cur = *bp++; tmppar ^= cur; rp4_6 ^= cur; + cur = *bp++; tmppar ^= cur; rp6 ^= cur; + cur = *bp++; tmppar ^= cur; rp4 ^= cur; + cur = *bp++; tmppar ^= cur; rp10 ^= tmppar; + + notrp8 = tmppar; + cur = *bp++; tmppar ^= cur; rp4_6 ^= cur; + cur = *bp++; tmppar ^= cur; rp6 ^= cur; + cur = *bp++; tmppar ^= cur; rp4 ^= cur; + cur = *bp++; tmppar ^= cur; + rp8 = rp8 ^ tmppar ^ notrp8; + + cur = *bp++; tmppar ^= cur; rp4_6 ^= cur; + cur = *bp++; tmppar ^= cur; rp6 ^= cur; + cur = *bp++; tmppar ^= cur; rp4 ^= cur; + cur = *bp++; tmppar ^= cur; + + par ^= tmppar; + if ((i & 0x1) == 0) rp12 ^= tmppar; + if ((i & 0x2) == 0) rp14 ^= tmppar; + } + rp4 ^= rp4_6; + rp6 ^= rp4_6; + + +Not a big change, but every penny counts :-) + + +Analysis 7 +========== + +Acutally this made things worse. Not very much, but I don't want to move +into the wrong direction. Maybe something to investigate later. Could +have to do with caching again. + +Guess that is what there is to win within the loop. Maybe unrolling one +more time will help. I'll keep the optimisations from 7 for now. + + +Attempt 8 +========= + +Unrolled the loop one more time. + + +Analysis 8 +========== + +This makes things worse. Let's stick with attempt 6 and continue from there. +Although it seems that the code within the loop cannot be optimised +further there is still room to optimize the generation of the ecc codes. +We can simply calcualate the total parity. If this is 0 then rp4 = rp5 +etc. If the parity is 1, then rp4 = !rp5; +But if rp4 = rp5 we do not need rp5 etc. We can just write the even bits +in the result byte and then do something like + code[0] |= (code[0] << 1); +Lets test this. + + +Attempt 9 +========= + +Changed the code but again this slightly degrades performance. Tried all +kind of other things, like having dedicated parity arrays to avoid the +shift after parity[rp7] << 7; No gain. +Change the lookup using the parity array by using shift operators (e.g. +replace parity[rp7] << 7 with: +rp7 ^= (rp7 << 4); +rp7 ^= (rp7 << 2); +rp7 ^= (rp7 << 1); +rp7 &= 0x80; +No gain. + +The only marginal change was inverting the parity bits, so we can remove +the last three invert statements. + +Ah well, pity this does not deliver more. Then again 10 million +iterations using the linux driver code takes between 13 and 13.5 +seconds, whereas my code now takes about 0.73 seconds for those 10 +million iterations. So basically I've improved the performance by a +factor 18 on my system. Not that bad. Of course on different hardware +you will get different results. No warranties! + +But of course there is no such thing as a free lunch. The codesize almost +tripled (from 562 bytes to 1434 bytes). Then again, it is not that much. + + +Correcting errors +================= + +For correcting errors I again used the ST application note as a starter, +but I also peeked at the existing code. +The algorithm itself is pretty straightforward. Just xor the given and +the calculated ecc. If all bytes are 0 there is no problem. If 11 bits +are 1 we have one correctable bit error. If there is 1 bit 1, we have an +error in the given ecc code. +It proved to be fastest to do some table lookups. Performance gain +introduced by this is about a factor 2 on my system when a repair had to +be done, and 1% or so if no repair had to be done. +Code size increased from 330 bytes to 686 bytes for this function. +(gcc 4.2, -O3) + + +Conclusion +========== + +The gain when calculating the ecc is tremendous. Om my development hardware +a speedup of a factor of 18 for ecc calculation was achieved. On a test on an +embedded system with a MIPS core a factor 7 was obtained. +On a test with a Linksys NSLU2 (ARMv5TE processor) the speedup was a factor +5 (big endian mode, gcc 4.1.2, -O3) +For correction not much gain could be obtained (as bitflips are rare). Then +again there are also much less cycles spent there. + +It seems there is not much more gain possible in this, at least when +programmed in C. Of course it might be possible to squeeze something more +out of it with an assembler program, but due to pipeline behaviour etc +this is very tricky (at least for intel hw). + +Author: Frans Meulenbroeks +Copyright (C) 2008 Koninklijke Philips Electronics NV. diff --git a/Documentation/mtrr.txt b/Documentation/mtrr.txt deleted file mode 100644 index c39ac39..0000000 --- a/Documentation/mtrr.txt +++ /dev/null @@ -1,305 +0,0 @@ -MTRR (Memory Type Range Register) control -3 Jun 1999 -Richard Gooch - - - On Intel P6 family processors (Pentium Pro, Pentium II and later) - the Memory Type Range Registers (MTRRs) may be used to control - processor access to memory ranges. This is most useful when you have - a video (VGA) card on a PCI or AGP bus. Enabling write-combining - allows bus write transfers to be combined into a larger transfer - before bursting over the PCI/AGP bus. This can increase performance - of image write operations 2.5 times or more. - - The Cyrix 6x86, 6x86MX and M II processors have Address Range - Registers (ARRs) which provide a similar functionality to MTRRs. For - these, the ARRs are used to emulate the MTRRs. - - The AMD K6-2 (stepping 8 and above) and K6-3 processors have two - MTRRs. These are supported. The AMD Athlon family provide 8 Intel - style MTRRs. - - The Centaur C6 (WinChip) has 8 MCRs, allowing write-combining. These - are supported. - - The VIA Cyrix III and VIA C3 CPUs offer 8 Intel style MTRRs. - - The CONFIG_MTRR option creates a /proc/mtrr file which may be used - to manipulate your MTRRs. Typically the X server should use - this. This should have a reasonably generic interface so that - similar control registers on other processors can be easily - supported. - - -There are two interfaces to /proc/mtrr: one is an ASCII interface -which allows you to read and write. The other is an ioctl() -interface. The ASCII interface is meant for administration. The -ioctl() interface is meant for C programs (i.e. the X server). The -interfaces are described below, with sample commands and C code. - -=============================================================================== -Reading MTRRs from the shell: - -% cat /proc/mtrr -reg00: base=0x00000000 ( 0MB), size= 128MB: write-back, count=1 -reg01: base=0x08000000 ( 128MB), size= 64MB: write-back, count=1 -=============================================================================== -Creating MTRRs from the C-shell: -# echo "base=0xf8000000 size=0x400000 type=write-combining" >! /proc/mtrr -or if you use bash: -# echo "base=0xf8000000 size=0x400000 type=write-combining" >| /proc/mtrr - -And the result thereof: -% cat /proc/mtrr -reg00: base=0x00000000 ( 0MB), size= 128MB: write-back, count=1 -reg01: base=0x08000000 ( 128MB), size= 64MB: write-back, count=1 -reg02: base=0xf8000000 (3968MB), size= 4MB: write-combining, count=1 - -This is for video RAM at base address 0xf8000000 and size 4 megabytes. To -find out your base address, you need to look at the output of your X -server, which tells you where the linear framebuffer address is. A -typical line that you may get is: - -(--) S3: PCI: 968 rev 0, Linear FB @ 0xf8000000 - -Note that you should only use the value from the X server, as it may -move the framebuffer base address, so the only value you can trust is -that reported by the X server. - -To find out the size of your framebuffer (what, you don't actually -know?), the following line will tell you: - -(--) S3: videoram: 4096k - -That's 4 megabytes, which is 0x400000 bytes (in hexadecimal). -A patch is being written for XFree86 which will make this automatic: -in other words the X server will manipulate /proc/mtrr using the -ioctl() interface, so users won't have to do anything. If you use a -commercial X server, lobby your vendor to add support for MTRRs. -=============================================================================== -Creating overlapping MTRRs: - -%echo "base=0xfb000000 size=0x1000000 type=write-combining" >/proc/mtrr -%echo "base=0xfb000000 size=0x1000 type=uncachable" >/proc/mtrr - -And the results: cat /proc/mtrr -reg00: base=0x00000000 ( 0MB), size= 64MB: write-back, count=1 -reg01: base=0xfb000000 (4016MB), size= 16MB: write-combining, count=1 -reg02: base=0xfb000000 (4016MB), size= 4kB: uncachable, count=1 - -Some cards (especially Voodoo Graphics boards) need this 4 kB area -excluded from the beginning of the region because it is used for -registers. - -NOTE: You can only create type=uncachable region, if the first -region that you created is type=write-combining. -=============================================================================== -Removing MTRRs from the C-shell: -% echo "disable=2" >! /proc/mtrr -or using bash: -% echo "disable=2" >| /proc/mtrr -=============================================================================== -Reading MTRRs from a C program using ioctl()'s: - -/* mtrr-show.c - - Source file for mtrr-show (example program to show MTRRs using ioctl()'s) - - Copyright (C) 1997-1998 Richard Gooch - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program; if not, write to the Free Software - Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. - - Richard Gooch may be reached by email at rgooch@atnf.csiro.au - The postal address is: - Richard Gooch, c/o ATNF, P. O. Box 76, Epping, N.S.W., 2121, Australia. -*/ - -/* - This program will use an ioctl() on /proc/mtrr to show the current MTRR - settings. This is an alternative to reading /proc/mtrr. - - - Written by Richard Gooch 17-DEC-1997 - - Last updated by Richard Gooch 2-MAY-1998 - - -*/ -#include -#include -#include -#include -#include -#include -#include -#include -#include - -#define TRUE 1 -#define FALSE 0 -#define ERRSTRING strerror (errno) - -static char *mtrr_strings[MTRR_NUM_TYPES] = -{ - "uncachable", /* 0 */ - "write-combining", /* 1 */ - "?", /* 2 */ - "?", /* 3 */ - "write-through", /* 4 */ - "write-protect", /* 5 */ - "write-back", /* 6 */ -}; - -int main () -{ - int fd; - struct mtrr_gentry gentry; - - if ( ( fd = open ("/proc/mtrr", O_RDONLY, 0) ) == -1 ) - { - if (errno == ENOENT) - { - fputs ("/proc/mtrr not found: not supported or you don't have a PPro?\n", - stderr); - exit (1); - } - fprintf (stderr, "Error opening /proc/mtrr\t%s\n", ERRSTRING); - exit (2); - } - for (gentry.regnum = 0; ioctl (fd, MTRRIOC_GET_ENTRY, &gentry) == 0; - ++gentry.regnum) - { - if (gentry.size < 1) - { - fprintf (stderr, "Register: %u disabled\n", gentry.regnum); - continue; - } - fprintf (stderr, "Register: %u base: 0x%lx size: 0x%lx type: %s\n", - gentry.regnum, gentry.base, gentry.size, - mtrr_strings[gentry.type]); - } - if (errno == EINVAL) exit (0); - fprintf (stderr, "Error doing ioctl(2) on /dev/mtrr\t%s\n", ERRSTRING); - exit (3); -} /* End Function main */ -=============================================================================== -Creating MTRRs from a C programme using ioctl()'s: - -/* mtrr-add.c - - Source file for mtrr-add (example programme to add an MTRRs using ioctl()) - - Copyright (C) 1997-1998 Richard Gooch - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program; if not, write to the Free Software - Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. - - Richard Gooch may be reached by email at rgooch@atnf.csiro.au - The postal address is: - Richard Gooch, c/o ATNF, P. O. Box 76, Epping, N.S.W., 2121, Australia. -*/ - -/* - This programme will use an ioctl() on /proc/mtrr to add an entry. The first - available mtrr is used. This is an alternative to writing /proc/mtrr. - - - Written by Richard Gooch 17-DEC-1997 - - Last updated by Richard Gooch 2-MAY-1998 - - -*/ -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -#define TRUE 1 -#define FALSE 0 -#define ERRSTRING strerror (errno) - -static char *mtrr_strings[MTRR_NUM_TYPES] = -{ - "uncachable", /* 0 */ - "write-combining", /* 1 */ - "?", /* 2 */ - "?", /* 3 */ - "write-through", /* 4 */ - "write-protect", /* 5 */ - "write-back", /* 6 */ -}; - -int main (int argc, char **argv) -{ - int fd; - struct mtrr_sentry sentry; - - if (argc != 4) - { - fprintf (stderr, "Usage:\tmtrr-add base size type\n"); - exit (1); - } - sentry.base = strtoul (argv[1], NULL, 0); - sentry.size = strtoul (argv[2], NULL, 0); - for (sentry.type = 0; sentry.type < MTRR_NUM_TYPES; ++sentry.type) - { - if (strcmp (argv[3], mtrr_strings[sentry.type]) == 0) break; - } - if (sentry.type >= MTRR_NUM_TYPES) - { - fprintf (stderr, "Illegal type: \"%s\"\n", argv[3]); - exit (2); - } - if ( ( fd = open ("/proc/mtrr", O_WRONLY, 0) ) == -1 ) - { - if (errno == ENOENT) - { - fputs ("/proc/mtrr not found: not supported or you don't have a PPro?\n", - stderr); - exit (3); - } - fprintf (stderr, "Error opening /proc/mtrr\t%s\n", ERRSTRING); - exit (4); - } - if (ioctl (fd, MTRRIOC_ADD_ENTRY, &sentry) == -1) - { - fprintf (stderr, "Error doing ioctl(2) on /dev/mtrr\t%s\n", ERRSTRING); - exit (5); - } - fprintf (stderr, "Sleeping for 5 seconds so you can see the new entry\n"); - sleep (5); - close (fd); - fputs ("I've just closed /proc/mtrr so now the new entry should be gone\n", - stderr); -} /* End Function main */ -=============================================================================== diff --git a/Documentation/networking/generic-hdlc.txt b/Documentation/networking/generic-hdlc.txt index 31bc8b7..4eb3cc4 100644 --- a/Documentation/networking/generic-hdlc.txt +++ b/Documentation/networking/generic-hdlc.txt @@ -3,15 +3,15 @@ Krzysztof Halasa Generic HDLC layer currently supports: -1. Frame Relay (ANSI, CCITT, Cisco and no LMI). +1. Frame Relay (ANSI, CCITT, Cisco and no LMI) - Normal (routed) and Ethernet-bridged (Ethernet device emulation) interfaces can share a single PVC. - ARP support (no InARP support in the kernel - there is an experimental InARP user-space daemon available on: http://www.kernel.org/pub/linux/utils/net/hdlc/). -2. raw HDLC - either IP (IPv4) interface or Ethernet device emulation. -3. Cisco HDLC. -4. PPP (uses syncppp.c). +2. raw HDLC - either IP (IPv4) interface or Ethernet device emulation +3. Cisco HDLC +4. PPP 5. X.25 (uses X.25 routines). Generic HDLC is a protocol driver only - it needs a low-level driver diff --git a/Documentation/pcmcia/driver-changes.txt b/Documentation/pcmcia/driver-changes.txt index 96f155e..0599343 100644 --- a/Documentation/pcmcia/driver-changes.txt +++ b/Documentation/pcmcia/driver-changes.txt @@ -1,5 +1,11 @@ This file details changes in 2.6 which affect PCMCIA card driver authors: +* New configuration loop helper (as of 2.6.28) + By calling pcmcia_loop_config(), a driver can iterate over all available + configuration options. During a driver's probe() phase, one doesn't need + to use pcmcia_get_{first,next}_tuple, pcmcia_get_tuple_data and + pcmcia_parse_tuple directly in most if not all cases. + * New release helper (as of 2.6.17) Instead of calling pcmcia_release_{configuration,io,irq,win}, all that's necessary now is calling pcmcia_disable_device. As there is no valid diff --git a/Documentation/scheduler/sched-design-CFS.txt b/Documentation/scheduler/sched-design-CFS.txt index 88bcb87..b2aa856 100644 --- a/Documentation/scheduler/sched-design-CFS.txt +++ b/Documentation/scheduler/sched-design-CFS.txt @@ -1,151 +1,218 @@ + ============= + CFS Scheduler + ============= -This is the CFS scheduler. - -80% of CFS's design can be summed up in a single sentence: CFS basically -models an "ideal, precise multi-tasking CPU" on real hardware. - -"Ideal multi-tasking CPU" is a (non-existent :-)) CPU that has 100% -physical power and which can run each task at precise equal speed, in -parallel, each at 1/nr_running speed. For example: if there are 2 tasks -running then it runs each at 50% physical power - totally in parallel. - -On real hardware, we can run only a single task at once, so while that -one task runs, the other tasks that are waiting for the CPU are at a -disadvantage - the current task gets an unfair amount of CPU time. In -CFS this fairness imbalance is expressed and tracked via the per-task -p->wait_runtime (nanosec-unit) value. "wait_runtime" is the amount of -time the task should now run on the CPU for it to become completely fair -and balanced. - -( small detail: on 'ideal' hardware, the p->wait_runtime value would - always be zero - no task would ever get 'out of balance' from the - 'ideal' share of CPU time. ) - -CFS's task picking logic is based on this p->wait_runtime value and it -is thus very simple: it always tries to run the task with the largest -p->wait_runtime value. In other words, CFS tries to run the task with -the 'gravest need' for more CPU time. So CFS always tries to split up -CPU time between runnable tasks as close to 'ideal multitasking -hardware' as possible. - -Most of the rest of CFS's design just falls out of this really simple -concept, with a few add-on embellishments like nice levels, -multiprocessing and various algorithm variants to recognize sleepers. - -In practice it works like this: the system runs a task a bit, and when -the task schedules (or a scheduler tick happens) the task's CPU usage is -'accounted for': the (small) time it just spent using the physical CPU -is deducted from p->wait_runtime. [minus the 'fair share' it would have -gotten anyway]. Once p->wait_runtime gets low enough so that another -task becomes the 'leftmost task' of the time-ordered rbtree it maintains -(plus a small amount of 'granularity' distance relative to the leftmost -task so that we do not over-schedule tasks and trash the cache) then the -new leftmost task is picked and the current task is preempted. - -The rq->fair_clock value tracks the 'CPU time a runnable task would have -fairly gotten, had it been runnable during that time'. So by using -rq->fair_clock values we can accurately timestamp and measure the -'expected CPU time' a task should have gotten. All runnable tasks are -sorted in the rbtree by the "rq->fair_clock - p->wait_runtime" key, and -CFS picks the 'leftmost' task and sticks to it. As the system progresses -forwards, newly woken tasks are put into the tree more and more to the -right - slowly but surely giving a chance for every task to become the -'leftmost task' and thus get on the CPU within a deterministic amount of -time. - -Some implementation details: - - - the introduction of Scheduling Classes: an extensible hierarchy of - scheduler modules. These modules encapsulate scheduling policy - details and are handled by the scheduler core without the core - code assuming about them too much. - - - sched_fair.c implements the 'CFS desktop scheduler': it is a - replacement for the vanilla scheduler's SCHED_OTHER interactivity - code. - - I'd like to give credit to Con Kolivas for the general approach here: - he has proven via RSDL/SD that 'fair scheduling' is possible and that - it results in better desktop scheduling. Kudos Con! - - The CFS patch uses a completely different approach and implementation - from RSDL/SD. My goal was to make CFS's interactivity quality exceed - that of RSDL/SD, which is a high standard to meet :-) Testing - feedback is welcome to decide this one way or another. [ and, in any - case, all of SD's logic could be added via a kernel/sched_sd.c module - as well, if Con is interested in such an approach. ] - - CFS's design is quite radical: it does not use runqueues, it uses a - time-ordered rbtree to build a 'timeline' of future task execution, - and thus has no 'array switch' artifacts (by which both the vanilla - scheduler and RSDL/SD are affected). - - CFS uses nanosecond granularity accounting and does not rely on any - jiffies or other HZ detail. Thus the CFS scheduler has no notion of - 'timeslices' and has no heuristics whatsoever. There is only one - central tunable (you have to switch on CONFIG_SCHED_DEBUG): - - /proc/sys/kernel/sched_granularity_ns - - which can be used to tune the scheduler from 'desktop' (low - latencies) to 'server' (good batching) workloads. It defaults to a - setting suitable for desktop workloads. SCHED_BATCH is handled by the - CFS scheduler module too. - - Due to its design, the CFS scheduler is not prone to any of the - 'attacks' that exist today against the heuristics of the stock - scheduler: fiftyp.c, thud.c, chew.c, ring-test.c, massive_intr.c all - work fine and do not impact interactivity and produce the expected - behavior. - - the CFS scheduler has a much stronger handling of nice levels and - SCHED_BATCH: both types of workloads should be isolated much more - agressively than under the vanilla scheduler. - - ( another detail: due to nanosec accounting and timeline sorting, - sched_yield() support is very simple under CFS, and in fact under - CFS sched_yield() behaves much better than under any other - scheduler i have tested so far. ) - - - sched_rt.c implements SCHED_FIFO and SCHED_RR semantics, in a simpler - way than the vanilla scheduler does. It uses 100 runqueues (for all - 100 RT priority levels, instead of 140 in the vanilla scheduler) - and it needs no expired array. - - - reworked/sanitized SMP load-balancing: the runqueue-walking - assumptions are gone from the load-balancing code now, and - iterators of the scheduling modules are used. The balancing code got - quite a bit simpler as a result. - - -Group scheduler extension to CFS -================================ - -Normally the scheduler operates on individual tasks and strives to provide -fair CPU time to each task. Sometimes, it may be desirable to group tasks -and provide fair CPU time to each such task group. For example, it may -be desirable to first provide fair CPU time to each user on the system -and then to each task belonging to a user. - -CONFIG_FAIR_GROUP_SCHED strives to achieve exactly that. It lets -SCHED_NORMAL/BATCH tasks be be grouped and divides CPU time fairly among such -groups. At present, there are two (mutually exclusive) mechanisms to group -tasks for CPU bandwidth control purpose: - - - Based on user id (CONFIG_FAIR_USER_SCHED) - In this option, tasks are grouped according to their user id. - - Based on "cgroup" pseudo filesystem (CONFIG_FAIR_CGROUP_SCHED) - This options lets the administrator create arbitrary groups - of tasks, using the "cgroup" pseudo filesystem. See - Documentation/cgroups.txt for more information about this - filesystem. -Only one of these options to group tasks can be chosen and not both. +1. OVERVIEW + +CFS stands for "Completely Fair Scheduler," and is the new "desktop" process +scheduler implemented by Ingo Molnar and merged in Linux 2.6.23. It is the +replacement for the previous vanilla scheduler's SCHED_OTHER interactivity +code. + +80% of CFS's design can be summed up in a single sentence: CFS basically models +an "ideal, precise multi-tasking CPU" on real hardware. + +"Ideal multi-tasking CPU" is a (non-existent :-)) CPU that has 100% physical +power and which can run each task at precise equal speed, in parallel, each at +1/nr_running speed. For example: if there are 2 tasks running, then it runs +each at 50% physical power --- i.e., actually in parallel. + +On real hardware, we can run only a single task at once, so we have to +introduce the concept of "virtual runtime." The virtual runtime of a task +specifies when its next timeslice would start execution on the ideal +multi-tasking CPU described above. In practice, the virtual runtime of a task +is its actual runtime normalized to the total number of running tasks. + + + +2. FEW IMPLEMENTATION DETAILS + +In CFS the virtual runtime is expressed and tracked via the per-task +p->se.vruntime (nanosec-unit) value. This way, it's possible to accurately +timestamp and measure the "expected CPU time" a task should have gotten. + +[ small detail: on "ideal" hardware, at any time all tasks would have the same + p->se.vruntime value --- i.e., tasks would execute simultaneously and no task + would ever get "out of balance" from the "ideal" share of CPU time. ] + +CFS's task picking logic is based on this p->se.vruntime value and it is thus +very simple: it always tries to run the task with the smallest p->se.vruntime +value (i.e., the task which executed least so far). CFS always tries to split +up CPU time between runnable tasks as close to "ideal multitasking hardware" as +possible. + +Most of the rest of CFS's design just falls out of this really simple concept, +with a few add-on embellishments like nice levels, multiprocessing and various +algorithm variants to recognize sleepers. + + + +3. THE RBTREE + +CFS's design is quite radical: it does not use the old data structures for the +runqueues, but it uses a time-ordered rbtree to build a "timeline" of future +task execution, and thus has no "array switch" artifacts (by which both the +previous vanilla scheduler and RSDL/SD are affected). + +CFS also maintains the rq->cfs.min_vruntime value, which is a monotonic +increasing value tracking the smallest vruntime among all tasks in the +runqueue. The total amount of work done by the system is tracked using +min_vruntime; that value is used to place newly activated entities on the left +side of the tree as much as possible. + +The total number of running tasks in the runqueue is accounted through the +rq->cfs.load value, which is the sum of the weights of the tasks queued on the +runqueue. + +CFS maintains a time-ordered rbtree, where all runnable tasks are sorted by the +p->se.vruntime key (there is a subtraction using rq->cfs.min_vruntime to +account for possible wraparounds). CFS picks the "leftmost" task from this +tree and sticks to it. +As the system progresses forwards, the executed tasks are put into the tree +more and more to the right --- slowly but surely giving a chance for every task +to become the "leftmost task" and thus get on the CPU within a deterministic +amount of time. + +Summing up, CFS works like this: it runs a task a bit, and when the task +schedules (or a scheduler tick happens) the task's CPU usage is "accounted +for": the (small) time it just spent using the physical CPU is added to +p->se.vruntime. Once p->se.vruntime gets high enough so that another task +becomes the "leftmost task" of the time-ordered rbtree it maintains (plus a +small amount of "granularity" distance relative to the leftmost task so that we +do not over-schedule tasks and trash the cache), then the new leftmost task is +picked and the current task is preempted. + + + +4. SOME FEATURES OF CFS + +CFS uses nanosecond granularity accounting and does not rely on any jiffies or +other HZ detail. Thus the CFS scheduler has no notion of "timeslices" in the +way the previous scheduler had, and has no heuristics whatsoever. There is +only one central tunable (you have to switch on CONFIG_SCHED_DEBUG): + + /proc/sys/kernel/sched_granularity_ns + +which can be used to tune the scheduler from "desktop" (i.e., low latencies) to +"server" (i.e., good batching) workloads. It defaults to a setting suitable +for desktop workloads. SCHED_BATCH is handled by the CFS scheduler module too. + +Due to its design, the CFS scheduler is not prone to any of the "attacks" that +exist today against the heuristics of the stock scheduler: fiftyp.c, thud.c, +chew.c, ring-test.c, massive_intr.c all work fine and do not impact +interactivity and produce the expected behavior. + +The CFS scheduler has a much stronger handling of nice levels and SCHED_BATCH +than the previous vanilla scheduler: both types of workloads are isolated much +more aggressively. + +SMP load-balancing has been reworked/sanitized: the runqueue-walking +assumptions are gone from the load-balancing code now, and iterators of the +scheduling modules are used. The balancing code got quite a bit simpler as a +result. + + + +5. SCHEDULING CLASSES + +The new CFS scheduler has been designed in such a way to introduce "Scheduling +Classes," an extensible hierarchy of scheduler modules. These modules +encapsulate scheduling policy details and are handled by the scheduler core +without the core code assuming too much about them. + +sched_fair.c implements the CFS scheduler described above. -Group scheduler tunables: +sched_rt.c implements SCHED_FIFO and SCHED_RR semantics, in a simpler way than +the previous vanilla scheduler did. It uses 100 runqueues (for all 100 RT +priority levels, instead of 140 in the previous scheduler) and it needs no +expired array. -When CONFIG_FAIR_USER_SCHED is defined, a directory is created in sysfs for -each new user and a "cpu_share" file is added in that directory. +Scheduling classes are implemented through the sched_class structure, which +contains hooks to functions that must be called whenever an interesting event +occurs. + +This is the (partial) list of the hooks: + + - enqueue_task(...) + + Called when a task enters a runnable state. + It puts the scheduling entity (task) into the red-black tree and + increments the nr_running variable. + + - dequeue_tree(...) + + When a task is no longer runnable, this function is called to keep the + corresponding scheduling entity out of the red-black tree. It decrements + the nr_running variable. + + - yield_task(...) + + This function is basically just a dequeue followed by an enqueue, unless the + compat_yield sysctl is turned on; in that case, it places the scheduling + entity at the right-most end of the red-black tree. + + - check_preempt_curr(...) + + This function checks if a task that entered the runnable state should + preempt the currently running task. + + - pick_next_task(...) + + This function chooses the most appropriate task eligible to run next. + + - set_curr_task(...) + + This function is called when a task changes its scheduling class or changes + its task group. + + - task_tick(...) + + This function is mostly called from time tick functions; it might lead to + process switch. This drives the running preemption. + + - task_new(...) + + The core scheduler gives the scheduling module an opportunity to manage new + task startup. The CFS scheduling module uses it for group scheduling, while + the scheduling module for a real-time task does not use it. + + + +6. GROUP SCHEDULER EXTENSIONS TO CFS + +Normally, the scheduler operates on individual tasks and strives to provide +fair CPU time to each task. Sometimes, it may be desirable to group tasks and +provide fair CPU time to each such task group. For example, it may be +desirable to first provide fair CPU time to each user on the system and then to +each task belonging to a user. + +CONFIG_GROUP_SCHED strives to achieve exactly that. It lets tasks to be +grouped and divides CPU time fairly among such groups. + +CONFIG_RT_GROUP_SCHED permits to group real-time (i.e., SCHED_FIFO and +SCHED_RR) tasks. + +CONFIG_FAIR_GROUP_SCHED permits to group CFS (i.e., SCHED_NORMAL and +SCHED_BATCH) tasks. + +At present, there are two (mutually exclusive) mechanisms to group tasks for +CPU bandwidth control purposes: + + - Based on user id (CONFIG_USER_SCHED) + + With this option, tasks are grouped according to their user id. + + - Based on "cgroup" pseudo filesystem (CONFIG_CGROUP_SCHED) + + This options needs CONFIG_CGROUPS to be defined, and lets the administrator + create arbitrary groups of tasks, using the "cgroup" pseudo filesystem. See + Documentation/cgroups.txt for more information about this filesystem. + +Only one of these options to group tasks can be chosen and not both. + +When CONFIG_USER_SCHED is defined, a directory is created in sysfs for each new +user and a "cpu_share" file is added in that directory. # cd /sys/kernel/uids # cat 512/cpu_share # Display user 512's CPU share @@ -155,16 +222,14 @@ each new user and a "cpu_share" file is added in that directory. 2048 # -CPU bandwidth between two users are divided in the ratio of their CPU shares. -For ex: if you would like user "root" to get twice the bandwidth of user -"guest", then set the cpu_share for both the users such that "root"'s -cpu_share is twice "guest"'s cpu_share - +CPU bandwidth between two users is divided in the ratio of their CPU shares. +For example: if you would like user "root" to get twice the bandwidth of user +"guest," then set the cpu_share for both the users such that "root"'s cpu_share +is twice "guest"'s cpu_share. -When CONFIG_FAIR_CGROUP_SCHED is defined, a "cpu.shares" file is created -for each group created using the pseudo filesystem. See example steps -below to create task groups and modify their CPU share using the "cgroups" -pseudo filesystem +When CONFIG_CGROUP_SCHED is defined, a "cpu.shares" file is created for each +group created using the pseudo filesystem. See example steps below to create +task groups and modify their CPU share using the "cgroups" pseudo filesystem. # mkdir /dev/cpuctl # mount -t cgroup -ocpu none /dev/cpuctl diff --git a/Documentation/sound/alsa/ALSA-Configuration.txt b/Documentation/sound/alsa/ALSA-Configuration.txt index b117e42..e07a5d4 100644 --- a/Documentation/sound/alsa/ALSA-Configuration.txt +++ b/Documentation/sound/alsa/ALSA-Configuration.txt @@ -746,8 +746,10 @@ Prior to version 0.9.0rc4 options had a 'snd_' prefix. This was removed. Module snd-hda-intel -------------------- - Module for Intel HD Audio (ICH6, ICH6M, ESB2, ICH7, ICH8), - ATI SB450, SB600, RS600, + Module for Intel HD Audio (ICH6, ICH6M, ESB2, ICH7, ICH8, ICH9, ICH10, + PCH, SCH), + ATI SB450, SB600, R600, RS600, RS690, RS780, RV610, RV620, + RV630, RV635, RV670, RV770, VIA VT8251/VT8237A, SIS966, ULI M5461 @@ -807,6 +809,7 @@ Prior to version 0.9.0rc4 options had a 'snd_' prefix. This was removed. ALC260 hp HP machines hp-3013 HP machines (3013-variant) + hp-dc7600 HP DC7600 fujitsu Fujitsu S7020 acer Acer TravelMate will Will laptops (PB V7900) @@ -828,8 +831,11 @@ Prior to version 0.9.0rc4 options had a 'snd_' prefix. This was removed. hippo Hippo (ATI) with jack detection, Sony UX-90s hippo_1 Hippo (Benq) with jack detection sony-assamd Sony ASSAMD + toshiba-s06 Toshiba S06 + toshiba-rx1 Toshiba RX1 ultra Samsung Q1 Ultra Vista model lenovo-3000 Lenovo 3000 y410 + nec NEC Versa S9100 basic fixed pin assignment w/o SPDIF auto auto-config reading BIOS (default) @@ -838,6 +844,7 @@ Prior to version 0.9.0rc4 options had a 'snd_' prefix. This was removed. 3stack 3-stack model toshiba Toshiba A205 acer Acer laptops + acer-aspire Acer Aspire One dell Dell OEM laptops (Vostro 1200) zepto Zepto laptops test for testing/debugging purpose, almost all controls can @@ -847,6 +854,9 @@ Prior to version 0.9.0rc4 options had a 'snd_' prefix. This was removed. ALC269 basic Basic preset + quanta Quanta FL1 + eeepc-p703 ASUS Eeepc P703 P900A + eeepc-p901 ASUS Eeepc P901 S101 ALC662/663 3stack-dig 3-stack (2-channel) with SPDIF @@ -856,10 +866,17 @@ Prior to version 0.9.0rc4 options had a 'snd_' prefix. This was removed. lenovo-101e Lenovo laptop eeepc-p701 ASUS Eeepc P701 eeepc-ep20 ASUS Eeepc EP20 + ecs ECS/Foxconn mobo m51va ASUS M51VA g71v ASUS G71V h13 ASUS H13 g50v ASUS G50V + asus-mode1 ASUS + asus-mode2 ASUS + asus-mode3 ASUS + asus-mode4 ASUS + asus-mode5 ASUS + asus-mode6 ASUS auto auto-config reading BIOS (default) ALC882/885 @@ -891,12 +908,14 @@ Prior to version 0.9.0rc4 options had a 'snd_' prefix. This was removed. lenovo-101e Lenovo 101E lenovo-nb0763 Lenovo NB0763 lenovo-ms7195-dig Lenovo MS7195 + lenovo-sky Lenovo Sky haier-w66 Haier W66 3stack-hp HP machines with 3stack (Lucknow, Samba boards) 6stack-dell Dell machines with 6stack (Inspiron 530) mitac Mitac 8252D clevo-m720 Clevo M720 laptop series fujitsu-pi2515 Fujitsu AMILO Pi2515 + 3stack-6ch-intel Intel DG33* boards auto auto-config reading BIOS (default) ALC861/660 @@ -929,7 +948,7 @@ Prior to version 0.9.0rc4 options had a 'snd_' prefix. This was removed. allout 5-jack in back, 2-jack in front, SPDIF out auto auto-config reading BIOS (default) - AD1882 + AD1882 / AD1882A 3stack 3-stack mode (default) 6stack 6-stack mode @@ -1079,7 +1098,7 @@ Prior to version 0.9.0rc4 options had a 'snd_' prefix. This was removed. register value without FIFO size correction as the current DMA pointer. position_fix=2 will make the driver to use the position buffer instead of reading SD_LPIB register. - (Usually SD_LPLIB register is more accurate than the + (Usually SD_LPIB register is more accurate than the position buffer.) NB: If you get many "azx_get_response timeout" messages at @@ -1166,6 +1185,7 @@ Prior to version 0.9.0rc4 options had a 'snd_' prefix. This was removed. * Event Electronics, EZ8 * Digigram VX442 * Lionstracs, Mediastaton + * Terrasoniq TS 88 model - Use the given board model, one of the following: delta1010, dio2496, delta66, delta44, audiophile, delta410, @@ -1200,7 +1220,10 @@ Prior to version 0.9.0rc4 options had a 'snd_' prefix. This was removed. * TerraTec Phase 22 * TerraTec Phase 28 * AudioTrak Prodigy 7.1 - * AudioTrak Prodigy 7.1LT + * AudioTrak Prodigy 7.1 LT + * AudioTrak Prodigy 7.1 XT + * AudioTrak Prodigy 7.1 HIFI + * AudioTrak Prodigy 7.1 HD2 * AudioTrak Prodigy 192 * Pontis MS300 * Albatron K8X800 Pro II @@ -1211,12 +1234,16 @@ Prior to version 0.9.0rc4 options had a 'snd_' prefix. This was removed. * Shuttle SN25P * Onkyo SE-90PCI * Onkyo SE-200PCI + * ESI Juli@ + * Hercules Fortissimo IV + * EGO-SYS WaveTerminal 192M model - Use the given board model, one of the following: revo51, revo71, amp2000, prodigy71, prodigy71lt, - prodigy192, aureon51, aureon71, universe, ap192, - k8x800, phase22, phase28, ms300, av710, se200pci, - se90pci + prodigy71xt, prodigy71hifi, prodigyhd2, prodigy192, + juli, aureon51, aureon71, universe, ap192, k8x800, + phase22, phase28, ms300, av710, se200pci, se90pci, + fortissimo4, sn25p, WT192M This module supports multiple cards and autoprobe. @@ -1255,7 +1282,7 @@ Prior to version 0.9.0rc4 options had a 'snd_' prefix. This was removed. Module for AC'97 motherboards from Intel and compatibles. * Intel i810/810E, i815, i820, i830, i84x, MX440 - ICH5, ICH6, ICH7, ESB2 + ICH5, ICH6, ICH7, 6300ESB, ESB2 * SiS 7012 (SiS 735) * NVidia NForce, NForce2, NForce3, MCP04, CK804 CK8, CK8S, MCP501 @@ -1951,6 +1978,8 @@ Prior to version 0.9.0rc4 options had a 'snd_' prefix. This was removed. * CHIC True Sound 4Dwave * Shark Predator4D-PCI * Jaton SonicWave 4D + * SiS SI7018 PCI Audio + * Hoontech SoundTrack Digital 4DWave NX pcm_channels - max channels (voices) reserved for PCM wavetable_size - max wavetable size in kB (4-?kb) @@ -1966,12 +1995,25 @@ Prior to version 0.9.0rc4 options had a 'snd_' prefix. This was removed. vid - Vendor ID for the device (optional) pid - Product ID for the device (optional) + nrpacks - Max. number of packets per URB (default: 8) + async_unlink - Use async unlink mode (default: yes) device_setup - Device specific magic number (optional) - Influence depends on the device - Default: 0x0000 + ignore_ctl_error - Ignore any USB-controller regarding mixer + interface (default: no) This module supports multiple devices, autoprobe and hotplugging. + NB: nrpacks parameter can be modified dynamically via sysfs. + Don't put the value over 20. Changing via sysfs has no sanity + check. + NB: async_unlink=0 would cause Oops. It remains just for + debugging purpose (if any). + NB: ignore_ctl_error=1 may help when you get an error at accessing + the mixer element such as URB error -22. This happens on some + buggy USB device or the controller. + Module snd-usb-caiaq -------------------- diff --git a/Documentation/sound/alsa/DocBook/writing-an-alsa-driver.tmpl b/Documentation/sound/alsa/DocBook/writing-an-alsa-driver.tmpl index e13c4e6..87a7c07 100644 --- a/Documentation/sound/alsa/DocBook/writing-an-alsa-driver.tmpl +++ b/Documentation/sound/alsa/DocBook/writing-an-alsa-driver.tmpl @@ -5073,8 +5073,7 @@ struct _snd_pcm_runtime { with SNDRV_DMA_TYPE_CONTINUOUS type and the snd_dma_continuous_data(GFP_KERNEL) device pointer, where GFP_KERNEL is the kernel allocation flag to - use. For the SBUS, SNDRV_DMA_TYPE_SBUS and - snd_dma_sbus_data(sbus_dev) are used instead. + use. For the PCI scatter-gather buffers, use SNDRV_DMA_TYPE_DEV_SG with snd_dma_pci_data(pci) @@ -6135,44 +6134,58 @@ struct _snd_pcm_runtime { -
- <function>snd_assert()</function> +
+ <function>snd_BUG()</function> - snd_assert() macro is similar with the - normal assert() macro. For example, + It shows the BUG? message and + stack trace as well as snd_BUG_ON at the point. + It's useful to show that a fatal error happens there. + + + When no debug flag is set, this macro is ignored. + +
+ +
+ <function>snd_BUG_ON()</function> + + snd_BUG_ON() macro is similar with + WARN_ON() macro. For example, - - - The first argument is the expression to evaluate, and the - second argument is the action if it fails. When - CONFIG_SND_DEBUG, is set, it will show an - error message such as BUG? (xxx) - together with stack trace. - - - When no debug flag is set, this macro is ignored. - -
+ or it can be used as the condition, + + + + + -
- <function>snd_BUG()</function> - - It shows the BUG? message and - stack trace as well as snd_assert at the point. - It's useful to show that a fatal error happens there. + - When no debug flag is set, this macro is ignored. + The macro takes an conditional expression to evaluate. + When CONFIG_SND_DEBUG, is set, the + expression is actually evaluated. If it's non-zero, it shows + the warning message such as + BUG? (xxx) + normally followed by stack trace. It returns the evaluated + value. + When no CONFIG_SND_DEBUG is set, this + macro always returns zero. +
+ diff --git a/Documentation/sparc/sbus_drivers.txt b/Documentation/sparc/sbus_drivers.txt deleted file mode 100644 index eb1e28a..0000000 --- a/Documentation/sparc/sbus_drivers.txt +++ /dev/null @@ -1,309 +0,0 @@ - - Writing SBUS Drivers - - David S. Miller (davem@redhat.com) - - The SBUS driver interfaces of the Linux kernel have been -revamped completely for 2.4.x for several reasons. Foremost were -performance and complexity concerns. This document details these -new interfaces and how they are used to write an SBUS device driver. - - SBUS drivers need to include to get access -to functions and structures described here. - - Probing and Detection - - Each SBUS device inside the machine is described by a -structure called "struct sbus_dev". Likewise, each SBUS bus -found in the system is described by a "struct sbus_bus". For -each SBUS bus, the devices underneath are hung in a tree-like -fashion off of the bus structure. - - The SBUS device structure contains enough information -for you to implement your device probing algorithm and obtain -the bits necessary to run your device. The most commonly -used members of this structure, and their typical usage, -will be detailed below. - - Here is a piece of skeleton code for performing a device -probe in an SBUS driver under Linux: - - static int __devinit mydevice_probe_one(struct sbus_dev *sdev) - { - struct mysdevice *mp = kzalloc(sizeof(*mp), GFP_KERNEL); - - if (!mp) - return -ENODEV; - - ... - dev_set_drvdata(&sdev->ofdev.dev, mp); - return 0; - ... - } - - static int __devinit mydevice_probe(struct of_device *dev, - const struct of_device_id *match) - { - struct sbus_dev *sdev = to_sbus_device(&dev->dev); - - return mydevice_probe_one(sdev); - } - - static int __devexit mydevice_remove(struct of_device *dev) - { - struct sbus_dev *sdev = to_sbus_device(&dev->dev); - struct mydevice *mp = dev_get_drvdata(&dev->dev); - - return mydevice_remove_one(sdev, mp); - } - - static struct of_device_id mydevice_match[] = { - { - .name = "mydevice", - }, - {}, - }; - - MODULE_DEVICE_TABLE(of, mydevice_match); - - static struct of_platform_driver mydevice_driver = { - .match_table = mydevice_match, - .probe = mydevice_probe, - .remove = __devexit_p(mydevice_remove), - .driver = { - .name = "mydevice", - }, - }; - - static int __init mydevice_init(void) - { - return of_register_driver(&mydevice_driver, &sbus_bus_type); - } - - static void __exit mydevice_exit(void) - { - of_unregister_driver(&mydevice_driver); - } - - module_init(mydevice_init); - module_exit(mydevice_exit); - - The mydevice_match table is a series of entries which -describes what SBUS devices your driver is meant for. In the -simplest case you specify a string for the 'name' field. Every -SBUS device with a 'name' property matching your string will -be passed one-by-one to your .probe method. - - You should store away your device private state structure -pointer in the drvdata area so that you can retrieve it later on -in your .remove method. - - Any memory allocated, registers mapped, IRQs registered, -etc. must be undone by your .remove method so that all resources -of your device are released by the time it returns. - - You should _NOT_ use the for_each_sbus(), for_each_sbusdev(), -and for_all_sbusdev() interfaces. They are deprecated, will be -removed, and no new driver should reference them ever. - - Mapping and Accessing I/O Registers - - Each SBUS device structure contains an array of descriptors -which describe each register set. We abuse struct resource for that. -They each correspond to the "reg" properties provided by the OBP firmware. - - Before you can access your device's registers you must map -them. And later if you wish to shutdown your driver (for module -unload or similar) you must unmap them. You must treat them as -a resource, which you allocate (map) before using and free up -(unmap) when you are done with it. - - The mapping information is stored in an opaque value -typed as an "unsigned long". This is the type of the return value -of the mapping interface, and the arguments to the unmapping -interface. Let's say you want to map the first set of registers. -Perhaps part of your driver software state structure looks like: - - struct mydevice { - unsigned long control_regs; - ... - struct sbus_dev *sdev; - ... - }; - - At initialization time you then use the sbus_ioremap -interface to map in your registers, like so: - - static void init_one_mydevice(struct sbus_dev *sdev) - { - struct mydevice *mp; - ... - - mp->control_regs = sbus_ioremap(&sdev->resource[0], 0, - CONTROL_REGS_SIZE, "mydevice regs"); - if (!mp->control_regs) { - /* Failure, cleanup and return. */ - } - } - - Second argument to sbus_ioremap is an offset for -cranky devices with broken OBP PROM. The sbus_ioremap uses only -a start address and flags from the resource structure. -Therefore it is possible to use the same resource to map -several sets of registers or even to fabricate a resource -structure if driver gets physical address from some private place. -This practice is discouraged though. Use whatever OBP PROM -provided to you. - - And here is how you might unmap these registers later at -driver shutdown or module unload time, using the sbus_iounmap -interface: - - static void mydevice_unmap_regs(struct mydevice *mp) - { - sbus_iounmap(mp->control_regs, CONTROL_REGS_SIZE); - } - - Finally, to actually access your registers there are 6 -interface routines at your disposal. Accesses are byte (8 bit), -word (16 bit), or longword (32 bit) sized. Here they are: - - u8 sbus_readb(unsigned long reg) /* read byte */ - u16 sbus_readw(unsigned long reg) /* read word */ - u32 sbus_readl(unsigned long reg) /* read longword */ - void sbus_writeb(u8 value, unsigned long reg) /* write byte */ - void sbus_writew(u16 value, unsigned long reg) /* write word */ - void sbus_writel(u32 value, unsigned long reg) /* write longword */ - - So, let's say your device has a control register of some sort -at offset zero. The following might implement resetting your device: - - #define CONTROL 0x00UL - - #define CONTROL_RESET 0x00000001 /* Reset hardware */ - - static void mydevice_reset(struct mydevice *mp) - { - sbus_writel(CONTROL_RESET, mp->regs + CONTROL); - } - - Or perhaps there is a data port register at an offset of -16 bytes which allows you to read bytes from a fifo in the device: - - #define DATA 0x10UL - - static u8 mydevice_get_byte(struct mydevice *mp) - { - return sbus_readb(mp->regs + DATA); - } - - It's pretty straightforward, and clueful readers may have -noticed that these interfaces mimick the PCI interfaces of the -Linux kernel. This was not by accident. - - WARNING: - - DO NOT try to treat these opaque register mapping - values as a memory mapped pointer to some structure - which you can dereference. - - It may be memory mapped, it may not be. In fact it - could be a physical address, or it could be the time - of day xor'd with 0xdeadbeef. :-) - - Whatever it is, it's an implementation detail. The - interface was done this way to shield the driver - author from such complexities. - - Doing DVMA - - SBUS devices can perform DMA transactions in a way similar -to PCI but dissimilar to ISA, e.g. DMA masters supply address. -In contrast to PCI, however, that address (a bus address) is -translated by IOMMU before a memory access is performed and therefore -it is virtual. Sun calls this procedure DVMA. - - Linux supports two styles of using SBUS DVMA: "consistent memory" -and "streaming DVMA". CPU view of consistent memory chunk is, well, -consistent with a view of a device. Think of it as an uncached memory. -Typically this way of doing DVMA is not very fast and drivers use it -mostly for control blocks or queues. On some CPUs we cannot flush or -invalidate individual pages or cache lines and doing explicit flushing -over ever little byte in every control block would be wasteful. - -Streaming DVMA is a preferred way to transfer large amounts of data. -This process works in the following way: -1. a CPU stops accessing a certain part of memory, - flushes its caches covering that memory; -2. a device does DVMA accesses, then posts an interrupt; -3. CPU invalidates its caches and starts to access the memory. - -A single streaming DVMA operation can touch several discontiguous -regions of a virtual bus address space. This is called a scatter-gather -DVMA. - -[TBD: Why do not we neither Solaris attempt to map disjoint pages -into a single virtual chunk with the help of IOMMU, so that non SG -DVMA masters would do SG? It'd be very helpful for RAID.] - - In order to perform a consistent DVMA a driver does something -like the following: - - char *mem; /* Address in the CPU space */ - u32 busa; /* Address in the SBus space */ - - mem = (char *) sbus_alloc_consistent(sdev, MYMEMSIZE, &busa); - - Then mem is used when CPU accesses this memory and u32 -is fed to the device so that it can do DVMA. This is typically -done with an sbus_writel() into some device register. - - Do not forget to free the DVMA resources once you are done: - - sbus_free_consistent(sdev, MYMEMSIZE, mem, busa); - - Streaming DVMA is more interesting. First you allocate some -memory suitable for it or pin down some user pages. Then it all works -like this: - - char *mem = argumen1; - unsigned int size = argument2; - u32 busa; /* Address in the SBus space */ - - *mem = 1; /* CPU can access */ - busa = sbus_map_single(sdev, mem, size); - if (busa == 0) ....... - - /* Tell the device to use busa here */ - /* CPU cannot access the memory without sbus_dma_sync_single() */ - - sbus_unmap_single(sdev, busa, size); - if (*mem == 0) .... /* CPU can access again */ - - It is possible to retain mappings and ask the device to -access data again and again without calling sbus_unmap_single. -However, CPU caches must be invalidated with sbus_dma_sync_single -before such access. - -[TBD but what about writeback caches here... do we have any?] - - There is an equivalent set of functions doing the same thing -only with several memory segments at once for devices capable of -scatter-gather transfers. Use the Source, Luke. - - Examples - - drivers/net/sunhme.c - This is a complicated driver which illustrates many concepts -discussed above and plus it handles both PCI and SBUS boards. - - drivers/scsi/esp.c - Check it out for scatter-gather DVMA. - - drivers/sbus/char/bpp.c - A non-DVMA device. - - drivers/net/sunlance.c - Lance driver abuses consistent mappings for data transfer. -It is a nifty trick which we do not particularly recommend... -Just check it out and know that it's legal. diff --git a/Documentation/sysctl/vm.txt b/Documentation/sysctl/vm.txt index d79eeda..5e7329a 100644 --- a/Documentation/sysctl/vm.txt +++ b/Documentation/sysctl/vm.txt @@ -38,6 +38,7 @@ Currently, these files are in /proc/sys/vm: - numa_zonelist_order - nr_hugepages - nr_overcommit_hugepages +- slab_defrag_limit ============================================================== @@ -347,3 +348,14 @@ Change the maximum size of the hugepage pool. The maximum is nr_hugepages + nr_overcommit_hugepages. See Documentation/vm/hugetlbpage.txt + +============================================================== + +slab_defrag_limit + +Determines the frequency of calls from reclaim into slab defragmentation. +Slab defrag reclaims objects from sparsely populates slab pages. +The default is 1000. Increase if slab defragmentation occurs +too frequently. Decrease if more slab defragmentation passes +are needed. The slabinfo tool can report on the frequency of the callbacks. + diff --git a/Documentation/timers/00-INDEX b/Documentation/timers/00-INDEX new file mode 100644 index 0000000..397dc35 --- /dev/null +++ b/Documentation/timers/00-INDEX @@ -0,0 +1,10 @@ +00-INDEX + - this file +highres.txt + - High resolution timers and dynamic ticks design notes +hpet.txt + - High Precision Event Timer Driver for Linux +hrtimers.txt + - subsystem for high-resolution kernel timers +timer_stats.txt + - timer usage statistics diff --git a/Documentation/timers/hpet.txt b/Documentation/timers/hpet.txt new file mode 100644 index 0000000..e7c09ab --- /dev/null +++ b/Documentation/timers/hpet.txt @@ -0,0 +1,299 @@ + High Precision Event Timer Driver for Linux + +The High Precision Event Timer (HPET) hardware follows a specification +by Intel and Microsoft which can be found at + + http://www.intel.com/technology/architecture/hpetspec.htm + +Each HPET has one fixed-rate counter (at 10+ MHz, hence "High Precision") +and up to 32 comparators. Normally three or more comparators are provided, +each of which can generate oneshot interupts and at least one of which has +additional hardware to support periodic interrupts. The comparators are +also called "timers", which can be misleading since usually timers are +independent of each other ... these share a counter, complicating resets. + +HPET devices can support two interrupt routing modes. In one mode, the +comparators are additional interrupt sources with no particular system +role. Many x86 BIOS writers don't route HPET interrupts at all, which +prevents use of that mode. They support the other "legacy replacement" +mode where the first two comparators block interrupts from 8254 timers +and from the RTC. + +The driver supports detection of HPET driver allocation and initialization +of the HPET before the driver module_init routine is called. This enables +platform code which uses timer 0 or 1 as the main timer to intercept HPET +initialization. An example of this initialization can be found in +arch/x86/kernel/hpet.c. + +The driver provides a userspace API which resembles the API found in the +RTC driver framework. An example user space program is provided below. + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + + +extern void hpet_open_close(int, const char **); +extern void hpet_info(int, const char **); +extern void hpet_poll(int, const char **); +extern void hpet_fasync(int, const char **); +extern void hpet_read(int, const char **); + +#include +#include +#include + +struct hpet_command { + char *command; + void (*func)(int argc, const char ** argv); +} hpet_command[] = { + { + "open-close", + hpet_open_close + }, + { + "info", + hpet_info + }, + { + "poll", + hpet_poll + }, + { + "fasync", + hpet_fasync + }, +}; + +int +main(int argc, const char ** argv) +{ + int i; + + argc--; + argv++; + + if (!argc) { + fprintf(stderr, "-hpet: requires command\n"); + return -1; + } + + + for (i = 0; i < (sizeof (hpet_command) / sizeof (hpet_command[0])); i++) + if (!strcmp(argv[0], hpet_command[i].command)) { + argc--; + argv++; + fprintf(stderr, "-hpet: executing %s\n", + hpet_command[i].command); + hpet_command[i].func(argc, argv); + return 0; + } + + fprintf(stderr, "do_hpet: command %s not implemented\n", argv[0]); + + return -1; +} + +void +hpet_open_close(int argc, const char **argv) +{ + int fd; + + if (argc != 1) { + fprintf(stderr, "hpet_open_close: device-name\n"); + return; + } + + fd = open(argv[0], O_RDONLY); + if (fd < 0) + fprintf(stderr, "hpet_open_close: open failed\n"); + else + close(fd); + + return; +} + +void +hpet_info(int argc, const char **argv) +{ +} + +void +hpet_poll(int argc, const char **argv) +{ + unsigned long freq; + int iterations, i, fd; + struct pollfd pfd; + struct hpet_info info; + struct timeval stv, etv; + struct timezone tz; + long usec; + + if (argc != 3) { + fprintf(stderr, "hpet_poll: device-name freq iterations\n"); + return; + } + + freq = atoi(argv[1]); + iterations = atoi(argv[2]); + + fd = open(argv[0], O_RDONLY); + + if (fd < 0) { + fprintf(stderr, "hpet_poll: open of %s failed\n", argv[0]); + return; + } + + if (ioctl(fd, HPET_IRQFREQ, freq) < 0) { + fprintf(stderr, "hpet_poll: HPET_IRQFREQ failed\n"); + goto out; + } + + if (ioctl(fd, HPET_INFO, &info) < 0) { + fprintf(stderr, "hpet_poll: failed to get info\n"); + goto out; + } + + fprintf(stderr, "hpet_poll: info.hi_flags 0x%lx\n", info.hi_flags); + + if (info.hi_flags && (ioctl(fd, HPET_EPI, 0) < 0)) { + fprintf(stderr, "hpet_poll: HPET_EPI failed\n"); + goto out; + } + + if (ioctl(fd, HPET_IE_ON, 0) < 0) { + fprintf(stderr, "hpet_poll, HPET_IE_ON failed\n"); + goto out; + } + + pfd.fd = fd; + pfd.events = POLLIN; + + for (i = 0; i < iterations; i++) { + pfd.revents = 0; + gettimeofday(&stv, &tz); + if (poll(&pfd, 1, -1) < 0) + fprintf(stderr, "hpet_poll: poll failed\n"); + else { + long data; + + gettimeofday(&etv, &tz); + usec = stv.tv_sec * 1000000 + stv.tv_usec; + usec = (etv.tv_sec * 1000000 + etv.tv_usec) - usec; + + fprintf(stderr, + "hpet_poll: expired time = 0x%lx\n", usec); + + fprintf(stderr, "hpet_poll: revents = 0x%x\n", + pfd.revents); + + if (read(fd, &data, sizeof(data)) != sizeof(data)) { + fprintf(stderr, "hpet_poll: read failed\n"); + } + else + fprintf(stderr, "hpet_poll: data 0x%lx\n", + data); + } + } + +out: + close(fd); + return; +} + +static int hpet_sigio_count; + +static void +hpet_sigio(int val) +{ + fprintf(stderr, "hpet_sigio: called\n"); + hpet_sigio_count++; +} + +void +hpet_fasync(int argc, const char **argv) +{ + unsigned long freq; + int iterations, i, fd, value; + sig_t oldsig; + struct hpet_info info; + + hpet_sigio_count = 0; + fd = -1; + + if ((oldsig = signal(SIGIO, hpet_sigio)) == SIG_ERR) { + fprintf(stderr, "hpet_fasync: failed to set signal handler\n"); + return; + } + + if (argc != 3) { + fprintf(stderr, "hpet_fasync: device-name freq iterations\n"); + goto out; + } + + fd = open(argv[0], O_RDONLY); + + if (fd < 0) { + fprintf(stderr, "hpet_fasync: failed to open %s\n", argv[0]); + return; + } + + + if ((fcntl(fd, F_SETOWN, getpid()) == 1) || + ((value = fcntl(fd, F_GETFL)) == 1) || + (fcntl(fd, F_SETFL, value | O_ASYNC) == 1)) { + fprintf(stderr, "hpet_fasync: fcntl failed\n"); + goto out; + } + + freq = atoi(argv[1]); + iterations = atoi(argv[2]); + + if (ioctl(fd, HPET_IRQFREQ, freq) < 0) { + fprintf(stderr, "hpet_fasync: HPET_IRQFREQ failed\n"); + goto out; + } + + if (ioctl(fd, HPET_INFO, &info) < 0) { + fprintf(stderr, "hpet_fasync: failed to get info\n"); + goto out; + } + + fprintf(stderr, "hpet_fasync: info.hi_flags 0x%lx\n", info.hi_flags); + + if (info.hi_flags && (ioctl(fd, HPET_EPI, 0) < 0)) { + fprintf(stderr, "hpet_fasync: HPET_EPI failed\n"); + goto out; + } + + if (ioctl(fd, HPET_IE_ON, 0) < 0) { + fprintf(stderr, "hpet_fasync, HPET_IE_ON failed\n"); + goto out; + } + + for (i = 0; i < iterations; i++) { + (void) pause(); + fprintf(stderr, "hpet_fasync: count = %d\n", hpet_sigio_count); + } + +out: + signal(SIGIO, oldsig); + + if (fd >= 0) + close(fd); + + return; +} diff --git a/Documentation/tracepoints.txt b/Documentation/tracepoints.txt new file mode 100644 index 0000000..5d354e1 --- /dev/null +++ b/Documentation/tracepoints.txt @@ -0,0 +1,101 @@ + Using the Linux Kernel Tracepoints + + Mathieu Desnoyers + + +This document introduces Linux Kernel Tracepoints and their use. It provides +examples of how to insert tracepoints in the kernel and connect probe functions +to them and provides some examples of probe functions. + + +* Purpose of tracepoints + +A tracepoint placed in code provides a hook to call a function (probe) that you +can provide at runtime. A tracepoint can be "on" (a probe is connected to it) or +"off" (no probe is attached). When a tracepoint is "off" it has no effect, +except for adding a tiny time penalty (checking a condition for a branch) and +space penalty (adding a few bytes for the function call at the end of the +instrumented function and adds a data structure in a separate section). When a +tracepoint is "on", the function you provide is called each time the tracepoint +is executed, in the execution context of the caller. When the function provided +ends its execution, it returns to the caller (continuing from the tracepoint +site). + +You can put tracepoints at important locations in the code. They are +lightweight hooks that can pass an arbitrary number of parameters, +which prototypes are described in a tracepoint declaration placed in a header +file. + +They can be used for tracing and performance accounting. + + +* Usage + +Two elements are required for tracepoints : + +- A tracepoint definition, placed in a header file. +- The tracepoint statement, in C code. + +In order to use tracepoints, you should include linux/tracepoint.h. + +In include/trace/subsys.h : + +#include + +DEFINE_TRACE(subsys_eventname, + TPPTOTO(int firstarg, struct task_struct *p), + TPARGS(firstarg, p)); + +In subsys/file.c (where the tracing statement must be added) : + +#include + +void somefct(void) +{ + ... + trace_subsys_eventname(arg, task); + ... +} + +Where : +- subsys_eventname is an identifier unique to your event + - subsys is the name of your subsystem. + - eventname is the name of the event to trace. +- TPPTOTO(int firstarg, struct task_struct *p) is the prototype of the function + called by this tracepoint. +- TPARGS(firstarg, p) are the parameters names, same as found in the prototype. + +Connecting a function (probe) to a tracepoint is done by providing a probe +(function to call) for the specific tracepoint through +register_trace_subsys_eventname(). Removing a probe is done through +unregister_trace_subsys_eventname(); it will remove the probe sure there is no +caller left using the probe when it returns. Probe removal is preempt-safe +because preemption is disabled around the probe call. See the "Probe example" +section below for a sample probe module. + +The tracepoint mechanism supports inserting multiple instances of the same +tracepoint, but a single definition must be made of a given tracepoint name over +all the kernel to make sure no type conflict will occur. Name mangling of the +tracepoints is done using the prototypes to make sure typing is correct. +Verification of probe type correctness is done at the registration site by the +compiler. Tracepoints can be put in inline functions, inlined static functions, +and unrolled loops as well as regular functions. + +The naming scheme "subsys_event" is suggested here as a convention intended +to limit collisions. Tracepoint names are global to the kernel: they are +considered as being the same whether they are in the core kernel image or in +modules. + + +* Probe / tracepoint example + +See the example provided in samples/tracepoints/src + +Compile them with your kernel. + +Run, as root : +modprobe tracepoint-example (insmod order is not important) +modprobe tracepoint-probe-example +cat /proc/tracepoint-example (returns an expected error) +rmmod tracepoint-example tracepoint-probe-example +dmesg diff --git a/Documentation/usb/anchors.txt b/Documentation/usb/anchors.txt index 7304bcf..5e6b64c 100644 --- a/Documentation/usb/anchors.txt +++ b/Documentation/usb/anchors.txt @@ -42,9 +42,21 @@ This function kills all URBs associated with an anchor. The URBs are called in the reverse temporal order they were submitted. This way no data can be reordered. +usb_unlink_anchored_urbs() +-------------------------- + +This function unlinks all URBs associated with an anchor. The URBs +are processed in the reverse temporal order they were submitted. +This is similar to usb_kill_anchored_urbs(), but it will not sleep. +Therefore no guarantee is made that the URBs have been unlinked when +the call returns. They may be unlinked later but will be unlinked in +finite time. + usb_wait_anchor_empty_timeout() ------------------------------- This function waits for all URBs associated with an anchor to finish or a timeout, whichever comes first. Its return value will tell you whether the timeout was reached. + + diff --git a/Documentation/usb/misc_usbsevseg.txt b/Documentation/usb/misc_usbsevseg.txt new file mode 100644 index 0000000..0f6be4f --- /dev/null +++ b/Documentation/usb/misc_usbsevseg.txt @@ -0,0 +1,46 @@ +USB 7-Segment Numeric Display +Manufactured by Delcom Engineering + +Device Information +------------------ +USB VENDOR_ID 0x0fc5 +USB PRODUCT_ID 0x1227 +Both the 6 character and 8 character displays have PRODUCT_ID, +and according to Delcom Engineering no queryable information +can be obtained from the device to tell them apart. + +Device Modes +------------ +By default, the driver assumes the display is only 6 characters +The mode for 6 characters is: + MSB 0x06; LSB 0x3f +For the 8 character display: + MSB 0x08; LSB 0xff +The device can accept "text" either in raw, hex, or ascii textmode. +raw controls each segment manually, +hex expects a value between 0-15 per character, +ascii expects a value between '0'-'9' and 'A'-'F'. +The default is ascii. + +Device Operation +---------------- +1. Turn on the device: + echo 1 > /sys/bus/usb/.../powered +2. Set the device's mode: + echo $mode_msb > /sys/bus/usb/.../mode_msb + echo $mode_lsb > /sys/bus/usb/.../mode_lsb +3. Set the textmode: + echo $textmode > /sys/bus/usb/.../textmode +4. set the text (for example): + echo "123ABC" > /sys/bus/usb/.../text (ascii) + echo "A1B2" > /sys/bus/usb/.../text (ascii) + echo -ne "\x01\x02\x03" > /sys/bus/usb/.../text (hex) +5. Set the decimal places. + The device has either 6 or 8 decimal points. + to set the nth decimal place calculate 10 ** n + and echo it in to /sys/bus/usb/.../decimals + To set multiple decimals points sum up each power. + For example, to set the 0th and 3rd decimal place + echo 1001 > /sys/bus/usb/.../decimals + + diff --git a/Documentation/video4linux/CARDLIST.au0828 b/Documentation/video4linux/CARDLIST.au0828 index eedc399..aa05e5b 100644 --- a/Documentation/video4linux/CARDLIST.au0828 +++ b/Documentation/video4linux/CARDLIST.au0828 @@ -3,3 +3,4 @@ 2 -> Hauppauge HVR850 (au0828) [2040:7240] 3 -> DViCO FusionHDTV USB (au0828) [0fe9:d620] 4 -> Hauppauge HVR950Q rev xxF8 (au0828) [2040:7201,2040:7211,2040:7281] + 5 -> Hauppauge Woodbury (au0828) [2040:8200] diff --git a/Documentation/video4linux/CARDLIST.bttv b/Documentation/video4linux/CARDLIST.bttv index f32efb6..60ba668 100644 --- a/Documentation/video4linux/CARDLIST.bttv +++ b/Documentation/video4linux/CARDLIST.bttv @@ -150,3 +150,4 @@ 149 -> Typhoon TV-Tuner PCI (50684) 150 -> Geovision GV-600 [008a:763c] 151 -> Kozumi KTV-01C +152 -> Encore ENL TV-FM-2 [1000:1801] diff --git a/Documentation/video4linux/CARDLIST.cx23885 b/Documentation/video4linux/CARDLIST.cx23885 index f0e613b..64823cc 100644 --- a/Documentation/video4linux/CARDLIST.cx23885 +++ b/Documentation/video4linux/CARDLIST.cx23885 @@ -9,3 +9,5 @@ 8 -> Hauppauge WinTV-HVR1700 [0070:8101] 9 -> Hauppauge WinTV-HVR1400 [0070:8010] 10 -> DViCO FusionHDTV7 Dual Express [18ac:d618] + 11 -> DViCO FusionHDTV DVB-T Dual Express [18ac:db78] + 12 -> Leadtek Winfast PxDVR3200 H [107d:6681] diff --git a/Documentation/video4linux/CARDLIST.tuner b/Documentation/video4linux/CARDLIST.tuner index 0e23946..30bbdda 100644 --- a/Documentation/video4linux/CARDLIST.tuner +++ b/Documentation/video4linux/CARDLIST.tuner @@ -74,3 +74,4 @@ tuner=72 - Thomson FE6600 tuner=73 - Samsung TCPG 6121P30A tuner=75 - Philips TEA5761 FM Radio tuner=76 - Xceive 5000 tuner +tuner=77 - TCL tuner MF02GIP-5N-E diff --git a/Documentation/video4linux/gspca.txt b/Documentation/video4linux/gspca.txt index 78a863a..0f03900 100644 --- a/Documentation/video4linux/gspca.txt +++ b/Documentation/video4linux/gspca.txt @@ -88,14 +88,14 @@ zc3xx 0471:0325 Philips SPC 200 NC zc3xx 0471:0326 Philips SPC 300 NC sonixj 0471:0327 Philips SPC 600 NC sonixj 0471:0328 Philips SPC 700 NC -zc3xx 0471:032d Philips spc210nc -zc3xx 0471:032e Philips spc315nc -sonixj 0471:0330 Philips SPC 710NC +zc3xx 0471:032d Philips SPC 210 NC +zc3xx 0471:032e Philips SPC 315 NC +sonixj 0471:0330 Philips SPC 710 NC spca501 0497:c001 Smile International sunplus 04a5:3003 Benq DC 1300 sunplus 04a5:3008 Benq DC 1500 -sunplus 04a5:300a Benq DC3410 -spca500 04a5:300c Benq DC1016 +sunplus 04a5:300a Benq DC 3410 +spca500 04a5:300c Benq DC 1016 sunplus 04f1:1001 JVC GC A50 spca561 04fc:0561 Flexcam 100 sunplus 04fc:500c Sunplus CA500C @@ -175,19 +175,21 @@ sunplus 08ca:2060 Aiptek PocketDV5300 tv8532 0923:010f ICM532 cams mars 093a:050f Mars-Semi Pc-Camera pac207 093a:2460 PAC207 Qtec Webcam 100 -pac207 093a:2463 Philips spc200nc pac207 +pac207 093a:2463 Philips SPC 220 NC pac207 093a:2464 Labtec Webcam 1200 pac207 093a:2468 PAC207 pac207 093a:2470 Genius GF112 -pac207 093a:2471 PAC207 Genius VideoCam ge111 -pac207 093a:2472 PAC207 Genius VideoCam ge110 +pac207 093a:2471 Genius VideoCam ge111 +pac207 093a:2472 Genius VideoCam ge110 pac7311 093a:2600 PAC7311 Typhoon -pac7311 093a:2601 PAC7311 Phillips SPC610NC +pac7311 093a:2601 Philips SPC 610 NC pac7311 093a:2603 PAC7312 -pac7311 093a:2608 PAC7311 Trust WB-3300p -pac7311 093a:260e PAC7311 Gigaware VGA PC Camera, Trust WB-3350p, SIGMA cam 2350 -pac7311 093a:260f PAC7311 SnakeCam +pac7311 093a:2608 Trust WB-3300p +pac7311 093a:260e Gigaware VGA PC Camera, Trust WB-3350p, SIGMA cam 2350 +pac7311 093a:260f SnakeCam pac7311 093a:2621 PAC731x +pac7311 093a:2624 PAC7302 +pac7311 093a:2626 Labtec 2200 zc3xx 0ac8:0302 Z-star Vimicro zc0302 vc032x 0ac8:0321 Vimicro generic vc0321 vc032x 0ac8:0323 Vimicro Vc0323 @@ -220,6 +222,7 @@ sonixj 0c45:60c0 Sangha Sn535 sonixj 0c45:60ec SN9C105+MO4000 sonixj 0c45:60fb Surfer NoName sonixj 0c45:60fc LG-LIC300 +sonixj 0c45:6128 Microdia/Sonix SNP325 sonixj 0c45:612a Avant Camera sonixj 0c45:612c Typhoon Rasy Cam 1.3MPix sonixj 0c45:6130 Sonix Pccam @@ -234,7 +237,7 @@ zc3xx 10fd:0128 Typhoon Webshot II USB 300k 0x0128 spca561 10fd:7e50 FlyCam Usb 100 zc3xx 10fd:8050 Typhoon Webshot II USB 300k spca501 1776:501c Arowana 300K CMOS Camera -t613 17a1:0128 T613/TAS5130A +t613 17a1:0128 TASCORP JPEG Webcam, NGS Cyclops vc032x 17ef:4802 Lenovo Vc0323+MI1310_SOC pac207 2001:f115 D-Link DSB-C120 spca500 2899:012c Toptro Industrial diff --git a/Documentation/video4linux/soc-camera.txt b/Documentation/video4linux/soc-camera.txt new file mode 100644 index 0000000..178ef3c --- /dev/null +++ b/Documentation/video4linux/soc-camera.txt @@ -0,0 +1,120 @@ + Soc-Camera Subsystem + ==================== + +Terminology +----------- + +The following terms are used in this document: + - camera / camera device / camera sensor - a video-camera sensor chip, capable + of connecting to a variety of systems and interfaces, typically uses i2c for + control and configuration, and a parallel or a serial bus for data. + - camera host - an interface, to which a camera is connected. Typically a + specialised interface, present on many SoCs, e.g., PXA27x and PXA3xx, SuperH, + AVR32, i.MX27, i.MX31. + - camera host bus - a connection between a camera host and a camera. Can be + parallel or serial, consists of data and control lines, e.g., clock, vertical + and horizontal synchronization signals. + +Purpose of the soc-camera subsystem +----------------------------------- + +The soc-camera subsystem provides a unified API between camera host drivers and +camera sensor drivers. It implements a V4L2 interface to the user, currently +only the mmap method is supported. + +This subsystem has been written to connect drivers for System-on-Chip (SoC) +video capture interfaces with drivers for CMOS camera sensor chips to enable +the reuse of sensor drivers with various hosts. The subsystem has been designed +to support multiple camera host interfaces and multiple cameras per interface, +although most applications have only one camera sensor. + +Existing drivers +---------------- + +As of 2.6.27-rc4 there are two host drivers in the mainline: pxa_camera.c for +PXA27x SoCs and sh_mobile_ceu_camera.c for SuperH SoCs, and four sensor drivers: +mt9m001.c, mt9m111.c, mt9v022.c and a generic soc_camera_platform.c driver. This +list is not supposed to be updated, look for more examples in your tree. + +Camera host API +--------------- + +A host camera driver is registered using the + +soc_camera_host_register(struct soc_camera_host *); + +function. The host object can be initialized as follows: + +static struct soc_camera_host pxa_soc_camera_host = { + .drv_name = PXA_CAM_DRV_NAME, + .ops = &pxa_soc_camera_host_ops, +}; + +All camera host methods are passed in a struct soc_camera_host_ops: + +static struct soc_camera_host_ops pxa_soc_camera_host_ops = { + .owner = THIS_MODULE, + .add = pxa_camera_add_device, + .remove = pxa_camera_remove_device, + .suspend = pxa_camera_suspend, + .resume = pxa_camera_resume, + .set_fmt_cap = pxa_camera_set_fmt_cap, + .try_fmt_cap = pxa_camera_try_fmt_cap, + .init_videobuf = pxa_camera_init_videobuf, + .reqbufs = pxa_camera_reqbufs, + .poll = pxa_camera_poll, + .querycap = pxa_camera_querycap, + .try_bus_param = pxa_camera_try_bus_param, + .set_bus_param = pxa_camera_set_bus_param, +}; + +.add and .remove methods are called when a sensor is attached to or detached +from the host, apart from performing host-internal tasks they shall also call +sensor driver's .init and .release methods respectively. .suspend and .resume +methods implement host's power-management functionality and its their +responsibility to call respective sensor's methods. .try_bus_param and +.set_bus_param are used to negotiate physical connection parameters between the +host and the sensor. .init_videobuf is called by soc-camera core when a +video-device is opened, further video-buffer management is implemented completely +by the specific camera host driver. The rest of the methods are called from +respective V4L2 operations. + +Camera API +---------- + +Sensor drivers can use struct soc_camera_link, typically provided by the +platform, and used to specify to which camera host bus the sensor is connected, +and arbitrarily provide platform .power and .reset methods for the camera. +soc_camera_device_register() and soc_camera_device_unregister() functions are +used to add a sensor driver to or remove one from the system. The registration +function takes a pointer to struct soc_camera_device as the only parameter. +This struct can be initialized as follows: + + /* link to driver operations */ + icd->ops = &mt9m001_ops; + /* link to the underlying physical (e.g., i2c) device */ + icd->control = &client->dev; + /* window geometry */ + icd->x_min = 20; + icd->y_min = 12; + icd->x_current = 20; + icd->y_current = 12; + icd->width_min = 48; + icd->width_max = 1280; + icd->height_min = 32; + icd->height_max = 1024; + icd->y_skip_top = 1; + /* camera bus ID, typically obtained from platform data */ + icd->iface = icl->bus_id; + +struct soc_camera_ops provides .probe and .remove methods, which are called by +the soc-camera core, when a camera is matched against or removed from a camera +host bus, .init, .release, .suspend, and .resume are called from the camera host +driver as discussed above. Other members of this struct provide respective V4L2 +functionality. + +struct soc_camera_device also links to an array of struct soc_camera_data_format, +listing pixel formats, supported by the camera. + +-- +Author: Guennadi Liakhovetski diff --git a/Documentation/vm/kmemtrace.txt b/Documentation/vm/kmemtrace.txt new file mode 100644 index 0000000..f656cac --- /dev/null +++ b/Documentation/vm/kmemtrace.txt @@ -0,0 +1,126 @@ + kmemtrace - Kernel Memory Tracer + + by Eduard - Gabriel Munteanu + + +I. Introduction +=============== + +kmemtrace helps kernel developers figure out two things: +1) how different allocators (SLAB, SLUB etc.) perform +2) how kernel code allocates memory and how much + +To do this, we trace every allocation and export information to the userspace +through the relay interface. We export things such as the number of requested +bytes, the number of bytes actually allocated (i.e. including internal +fragmentation), whether this is a slab allocation or a plain kmalloc() and so +on. + +The actual analysis is performed by a userspace tool (see section III for +details on where to get it from). It logs the data exported by the kernel, +processes it and (as of writing this) can provide the following information: +- the total amount of memory allocated and fragmentation per call-site +- the amount of memory allocated and fragmentation per allocation +- total memory allocated and fragmentation in the collected dataset +- number of cross-CPU allocation and frees (makes sense in NUMA environments) + +Moreover, it can potentially find inconsistent and erroneous behavior in +kernel code, such as using slab free functions on kmalloc'ed memory or +allocating less memory than requested (but not truly failed allocations). + +kmemtrace also makes provisions for tracing on some arch and analysing the +data on another. + +II. Design and goals +==================== + +kmemtrace was designed to handle rather large amounts of data. Thus, it uses +the relay interface to export whatever is logged to userspace, which then +stores it. Analysis and reporting is done asynchronously, that is, after the +data is collected and stored. By design, it allows one to log and analyse +on different machines and different arches. + +As of writing this, the ABI is not considered stable, though it might not +change much. However, no guarantees are made about compatibility yet. When +deemed stable, the ABI should still allow easy extension while maintaining +backward compatibility. This is described further in Documentation/ABI. + +Summary of design goals: + - allow logging and analysis to be done across different machines + - be fast and anticipate usage in high-load environments (*) + - be reasonably extensible + - make it possible for GNU/Linux distributions to have kmemtrace + included in their repositories + +(*) - one of the reasons Pekka Enberg's original userspace data analysis + tool's code was rewritten from Perl to C (although this is more than a + simple conversion) + + +III. Quick usage guide +====================== + +1) Get a kernel that supports kmemtrace and build it accordingly (i.e. enable +CONFIG_KMEMTRACE and CONFIG_KMEMTRACE_DEFAULT_ENABLED). + +2) Get the userspace tool and build it: +$ git-clone git://repo.or.cz/kmemtrace-user.git # current repository +$ cd kmemtrace-user/ +$ ./autogen.sh +$ ./configure +$ make + +3) Boot the kmemtrace-enabled kernel if you haven't, preferably in the +'single' runlevel (so that relay buffers don't fill up easily), and run +kmemtrace: +# '$' does not mean user, but root here. +$ mount -t debugfs none /sys/kernel/debug +$ mount -t proc none /proc +$ cd path/to/kmemtrace-user/ +$ ./kmemtraced +Wait a bit, then stop it with CTRL+C. +$ cat /sys/kernel/debug/kmemtrace/total_overruns # Check if we didn't + # overrun, should + # be zero. +$ (Optionally) [Run kmemtrace_check separately on each cpu[0-9]*.out file to + check its correctness] +$ ./kmemtrace-report + +Now you should have a nice and short summary of how the allocator performs. + +IV. FAQ and known issues +======================== + +Q: 'cat /sys/kernel/debug/kmemtrace/total_overruns' is non-zero, how do I fix +this? Should I worry? +A: If it's non-zero, this affects kmemtrace's accuracy, depending on how +large the number is. You can fix it by supplying a higher +'kmemtrace.subbufs=N' kernel parameter. +--- + +Q: kmemtrace_check reports errors, how do I fix this? Should I worry? +A: This is a bug and should be reported. It can occur for a variety of +reasons: + - possible bugs in relay code + - possible misuse of relay by kmemtrace + - timestamps being collected unorderly +Or you may fix it yourself and send us a patch. +--- + +Q: kmemtrace_report shows many errors, how do I fix this? Should I worry? +A: This is a known issue and I'm working on it. These might be true errors +in kernel code, which may have inconsistent behavior (e.g. allocating memory +with kmem_cache_alloc() and freeing it with kfree()). Pekka Enberg pointed +out this behavior may work with SLAB, but may fail with other allocators. + +It may also be due to lack of tracing in some unusual allocator functions. + +We don't want bug reports regarding this issue yet. +--- + +V. See also +=========== + +Documentation/kernel-parameters.txt +Documentation/ABI/testing/debugfs-kmemtrace + diff --git a/Documentation/vm/slabinfo.c b/Documentation/vm/slabinfo.c index df32276..72f4301 100644 --- a/Documentation/vm/slabinfo.c +++ b/Documentation/vm/slabinfo.c @@ -31,6 +31,8 @@ struct slabinfo { int hwcache_align, object_size, objs_per_slab; int sanity_checks, slab_size, store_user, trace; int order, poison, reclaim_account, red_zone; + int defrag, ctor; + int defrag_ratio, remote_node_defrag_ratio; unsigned long partial, objects, slabs, objects_partial, objects_total; unsigned long alloc_fastpath, alloc_slowpath; unsigned long free_fastpath, free_slowpath; @@ -39,6 +41,9 @@ struct slabinfo { unsigned long cpuslab_flush, deactivate_full, deactivate_empty; unsigned long deactivate_to_head, deactivate_to_tail; unsigned long deactivate_remote_frees, order_fallback; + unsigned long shrink_calls, shrink_attempt_defrag, shrink_empty_slab; + unsigned long shrink_slab_skipped, shrink_slab_reclaimed; + unsigned long shrink_object_reclaim_failed; int numa[MAX_NODES]; int numa_partial[MAX_NODES]; } slabinfo[MAX_SLABS]; @@ -64,6 +69,8 @@ int show_slab = 0; int skip_zero = 1; int show_numa = 0; int show_track = 0; +int show_defrag = 0; +int show_ctor = 0; int show_first_alias = 0; int validate = 0; int shrink = 0; @@ -75,6 +82,7 @@ int sort_active = 0; int set_debug = 0; int show_ops = 0; int show_activity = 0; +int show_defragcount = 0; /* Debug options */ int sanity = 0; @@ -100,13 +108,16 @@ void fatal(const char *x, ...) void usage(void) { printf("slabinfo 5/7/2007. (c) 2007 sgi.\n\n" - "slabinfo [-ahnpvtsz] [-d debugopts] [slab-regexp]\n" + "slabinfo [-aCdDefFhnpvtsz] [-d debugopts] [slab-regexp]\n" "-a|--aliases Show aliases\n" "-A|--activity Most active slabs first\n" "-d|--debug= Set/Clear Debug options\n" + "-C|--ctor Show slabs with ctors\n" "-D|--display-active Switch line format to activity\n" "-e|--empty Show empty slabs\n" "-f|--first-alias Show first alias\n" + "-F|--defrag Show defragmentable caches\n" + "-G:--display-defrag Display defrag counters\n" "-h|--help Show usage information\n" "-i|--inverted Inverted list\n" "-l|--slabs Show slabs\n" @@ -294,9 +305,11 @@ void first_line(void) { if (show_activity) printf("Name Objects Alloc Free %%Fast Fallb O\n"); + else if (show_defragcount) + printf("Name Objects DefragRQ Slabs Success Empty Skipped Failed\n"); else printf("Name Objects Objsize Space " - "Slabs/Part/Cpu O/S O %%Fr %%Ef Flg\n"); + "Slabs/Part/Cpu O/S O %%Ra %%Ef Flg\n"); } /* @@ -345,7 +358,7 @@ void slab_numa(struct slabinfo *s, int mode) return; if (!line) { - printf("\n%-21s:", mode ? "NUMA nodes" : "Slab"); + printf("\n%-21s: Rto ", mode ? "NUMA nodes" : "Slab"); for(node = 0; node <= highest_node; node++) printf(" %4d", node); printf("\n----------------------"); @@ -354,6 +367,7 @@ void slab_numa(struct slabinfo *s, int mode) printf("\n"); } printf("%-21s ", mode ? "All slabs" : s->name); + printf("%3d ", s->remote_node_defrag_ratio); for(node = 0; node <= highest_node; node++) { char b[20]; @@ -459,22 +473,28 @@ void slab_stats(struct slabinfo *s) printf("Total %8lu %8lu\n\n", total_alloc, total_free); - if (s->cpuslab_flush) - printf("Flushes %8lu\n", s->cpuslab_flush); - - if (s->alloc_refill) - printf("Refill %8lu\n", s->alloc_refill); + if (s->cpuslab_flush || s->alloc_refill) + printf("CPU Slab : Flushes=%lu Refills=%lu\n", + s->cpuslab_flush, s->alloc_refill); total = s->deactivate_full + s->deactivate_empty + s->deactivate_to_head + s->deactivate_to_tail; if (total) - printf("Deactivate Full=%lu(%lu%%) Empty=%lu(%lu%%) " + printf("Deactivate: Full=%lu(%lu%%) Empty=%lu(%lu%%) " "ToHead=%lu(%lu%%) ToTail=%lu(%lu%%)\n", s->deactivate_full, (s->deactivate_full * 100) / total, s->deactivate_empty, (s->deactivate_empty * 100) / total, s->deactivate_to_head, (s->deactivate_to_head * 100) / total, s->deactivate_to_tail, (s->deactivate_to_tail * 100) / total); + + if (s->shrink_calls) + printf("Shrink : Calls=%lu Attempts=%lu Empty=%lu Successful=%lu\n", + s->shrink_calls, s->shrink_attempt_defrag, + s->shrink_empty_slab, s->shrink_slab_reclaimed); + if (s->shrink_slab_skipped || s->shrink_object_reclaim_failed) + printf("Defrag : Slabs skipped=%lu Object reclaim failed=%lu\n", + s->shrink_slab_skipped, s->shrink_object_reclaim_failed); } void report(struct slabinfo *s) @@ -492,6 +512,8 @@ void report(struct slabinfo *s) printf("** Slabs are destroyed via RCU\n"); if (s->reclaim_account) printf("** Reclaim accounting active\n"); + if (s->defrag) + printf("** Defragmentation at %d%%\n", s->defrag_ratio); printf("\nSizes (bytes) Slabs Debug Memory\n"); printf("------------------------------------------------------------------------\n"); @@ -539,6 +561,12 @@ void slabcache(struct slabinfo *s) if (show_empty && s->slabs) return; + if (show_defrag && !s->defrag) + return; + + if (show_ctor && !s->ctor) + return; + store_size(size_str, slab_size(s)); snprintf(dist_str, 40, "%lu/%lu/%d", s->slabs - s->cpu_slabs, s->partial, s->cpu_slabs); @@ -550,6 +578,10 @@ void slabcache(struct slabinfo *s) *p++ = '*'; if (s->cache_dma) *p++ = 'd'; + if (s->defrag) + *p++ = 'F'; + if (s->ctor) + *p++ = 'C'; if (s->hwcache_align) *p++ = 'A'; if (s->poison) @@ -579,12 +611,18 @@ void slabcache(struct slabinfo *s) total_alloc ? (s->alloc_fastpath * 100 / total_alloc) : 0, total_free ? (s->free_fastpath * 100 / total_free) : 0, s->order_fallback, s->order); - } + } else + if (show_defragcount) + printf("%-21s %8ld %7lu %7lu %7lu %7lu %7lu %7lu\n", + s->name, s->objects, s->shrink_calls, s->shrink_attempt_defrag, + s->shrink_slab_reclaimed, s->shrink_empty_slab, + s->shrink_slab_skipped, s->shrink_object_reclaim_failed); else printf("%-21s %8ld %7d %8s %14s %4d %1d %3ld %3ld %s\n", s->name, s->objects, s->object_size, size_str, dist_str, s->objs_per_slab, s->order, - s->slabs ? (s->partial * 100) / s->slabs : 100, + s->slabs ? (s->partial * 100) / + (s->slabs * s->objs_per_slab) : 100, s->slabs ? (s->objects * s->object_size * 100) / (s->slabs * (page_size << s->order)) : 100, flags); @@ -1190,7 +1228,24 @@ void read_slab_dir(void) slab->deactivate_to_tail = get_obj("deactivate_to_tail"); slab->deactivate_remote_frees = get_obj("deactivate_remote_frees"); slab->order_fallback = get_obj("order_fallback"); + slab->shrink_calls = get_obj("shrink_calls"); + slab->shrink_attempt_defrag = get_obj("shrink_attempt_defrag"); + slab->shrink_empty_slab = get_obj("shrink_empty_slab"); + slab->shrink_slab_skipped = get_obj("shrink_slab_skipped"); + slab->shrink_slab_reclaimed = get_obj("shrink_slab_reclaimed"); + slab->shrink_object_reclaim_failed = + get_obj("shrink_object_reclaim_failed"); + slab->defrag_ratio = get_obj("defrag_ratio"); + slab->remote_node_defrag_ratio = + get_obj("remote_node_defrag_ratio"); chdir(".."); + if (read_slab_obj(slab, "ops")) { + if (strstr(buffer, "ctor :")) + slab->ctor = 1; + if (strstr(buffer, "kick :")) + slab->defrag = 1; + } + if (slab->name[0] == ':') alias_targets++; slab++; @@ -1241,10 +1296,13 @@ void output_slabs(void) struct option opts[] = { { "aliases", 0, NULL, 'a' }, { "activity", 0, NULL, 'A' }, + { "ctor", 0, NULL, 'C' }, { "debug", 2, NULL, 'd' }, { "display-activity", 0, NULL, 'D' }, + { "display-defrag", 0, NULL, 'G' }, { "empty", 0, NULL, 'e' }, { "first-alias", 0, NULL, 'f' }, + { "defrag", 0, NULL, 'F' }, { "help", 0, NULL, 'h' }, { "inverted", 0, NULL, 'i'}, { "numa", 0, NULL, 'n' }, @@ -1267,7 +1325,7 @@ int main(int argc, char *argv[]) page_size = getpagesize(); - while ((c = getopt_long(argc, argv, "aAd::Defhil1noprstvzTS", + while ((c = getopt_long(argc, argv, "aACd::DefFGhil1noprstvzTS", opts, NULL)) != -1) switch (c) { case '1': @@ -1293,6 +1351,9 @@ int main(int argc, char *argv[]) case 'f': show_first_alias = 1; break; + case 'G': + show_defragcount = 1; + break; case 'h': usage(); return 0; @@ -1323,6 +1384,12 @@ int main(int argc, char *argv[]) case 'z': skip_zero = 0; break; + case 'C': + show_ctor = 1; + break; + case 'F': + show_defrag = 1; + break; case 'T': show_totals = 1; break; diff --git a/Documentation/x86/00-INDEX b/Documentation/x86/00-INDEX new file mode 100644 index 0000000..dbe3377 --- /dev/null +++ b/Documentation/x86/00-INDEX @@ -0,0 +1,4 @@ +00-INDEX + - this file +mtrr.txt + - how to use x86 Memory Type Range Registers to increase performance diff --git a/Documentation/x86/boot.txt b/Documentation/x86/boot.txt new file mode 100644 index 0000000..83c0033 --- /dev/null +++ b/Documentation/x86/boot.txt @@ -0,0 +1,900 @@ + THE LINUX/x86 BOOT PROTOCOL + --------------------------- + +On the x86 platform, the Linux kernel uses a rather complicated boot +convention. This has evolved partially due to historical aspects, as +well as the desire in the early days to have the kernel itself be a +bootable image, the complicated PC memory model and due to changed +expectations in the PC industry caused by the effective demise of +real-mode DOS as a mainstream operating system. + +Currently, the following versions of the Linux/x86 boot protocol exist. + +Old kernels: zImage/Image support only. Some very early kernels + may not even support a command line. + +Protocol 2.00: (Kernel 1.3.73) Added bzImage and initrd support, as + well as a formalized way to communicate between the + boot loader and the kernel. setup.S made relocatable, + although the traditional setup area still assumed + writable. + +Protocol 2.01: (Kernel 1.3.76) Added a heap overrun warning. + +Protocol 2.02: (Kernel 2.4.0-test3-pre3) New command line protocol. + Lower the conventional memory ceiling. No overwrite + of the traditional setup area, thus making booting + safe for systems which use the EBDA from SMM or 32-bit + BIOS entry points. zImage deprecated but still + supported. + +Protocol 2.03: (Kernel 2.4.18-pre1) Explicitly makes the highest possible + initrd address available to the bootloader. + +Protocol 2.04: (Kernel 2.6.14) Extend the syssize field to four bytes. + +Protocol 2.05: (Kernel 2.6.20) Make protected mode kernel relocatable. + Introduce relocatable_kernel and kernel_alignment fields. + +Protocol 2.06: (Kernel 2.6.22) Added a field that contains the size of + the boot command line. + +Protocol 2.07: (Kernel 2.6.24) Added paravirtualised boot protocol. + Introduced hardware_subarch and hardware_subarch_data + and KEEP_SEGMENTS flag in load_flags. + +Protocol 2.08: (Kernel 2.6.26) Added crc32 checksum and ELF format + payload. Introduced payload_offset and payload length + fields to aid in locating the payload. + +Protocol 2.09: (Kernel 2.6.26) Added a field of 64-bit physical + pointer to single linked list of struct setup_data. + +**** MEMORY LAYOUT + +The traditional memory map for the kernel loader, used for Image or +zImage kernels, typically looks like: + + | | +0A0000 +------------------------+ + | Reserved for BIOS | Do not use. Reserved for BIOS EBDA. +09A000 +------------------------+ + | Command line | + | Stack/heap | For use by the kernel real-mode code. +098000 +------------------------+ + | Kernel setup | The kernel real-mode code. +090200 +------------------------+ + | Kernel boot sector | The kernel legacy boot sector. +090000 +------------------------+ + | Protected-mode kernel | The bulk of the kernel image. +010000 +------------------------+ + | Boot loader | <- Boot sector entry point 0000:7C00 +001000 +------------------------+ + | Reserved for MBR/BIOS | +000800 +------------------------+ + | Typically used by MBR | +000600 +------------------------+ + | BIOS use only | +000000 +------------------------+ + + +When using bzImage, the protected-mode kernel was relocated to +0x100000 ("high memory"), and the kernel real-mode block (boot sector, +setup, and stack/heap) was made relocatable to any address between +0x10000 and end of low memory. Unfortunately, in protocols 2.00 and +2.01 the 0x90000+ memory range is still used internally by the kernel; +the 2.02 protocol resolves that problem. + +It is desirable to keep the "memory ceiling" -- the highest point in +low memory touched by the boot loader -- as low as possible, since +some newer BIOSes have begun to allocate some rather large amounts of +memory, called the Extended BIOS Data Area, near the top of low +memory. The boot loader should use the "INT 12h" BIOS call to verify +how much low memory is available. + +Unfortunately, if INT 12h reports that the amount of memory is too +low, there is usually nothing the boot loader can do but to report an +error to the user. The boot loader should therefore be designed to +take up as little space in low memory as it reasonably can. For +zImage or old bzImage kernels, which need data written into the +0x90000 segment, the boot loader should make sure not to use memory +above the 0x9A000 point; too many BIOSes will break above that point. + +For a modern bzImage kernel with boot protocol version >= 2.02, a +memory layout like the following is suggested: + + ~ ~ + | Protected-mode kernel | +100000 +------------------------+ + | I/O memory hole | +0A0000 +------------------------+ + | Reserved for BIOS | Leave as much as possible unused + ~ ~ + | Command line | (Can also be below the X+10000 mark) +X+10000 +------------------------+ + | Stack/heap | For use by the kernel real-mode code. +X+08000 +------------------------+ + | Kernel setup | The kernel real-mode code. + | Kernel boot sector | The kernel legacy boot sector. +X +------------------------+ + | Boot loader | <- Boot sector entry point 0000:7C00 +001000 +------------------------+ + | Reserved for MBR/BIOS | +000800 +------------------------+ + | Typically used by MBR | +000600 +------------------------+ + | BIOS use only | +000000 +------------------------+ + +... where the address X is as low as the design of the boot loader +permits. + + +**** THE REAL-MODE KERNEL HEADER + +In the following text, and anywhere in the kernel boot sequence, "a +sector" refers to 512 bytes. It is independent of the actual sector +size of the underlying medium. + +The first step in loading a Linux kernel should be to load the +real-mode code (boot sector and setup code) and then examine the +following header at offset 0x01f1. The real-mode code can total up to +32K, although the boot loader may choose to load only the first two +sectors (1K) and then examine the bootup sector size. + +The header looks like: + +Offset Proto Name Meaning +/Size + +01F1/1 ALL(1 setup_sects The size of the setup in sectors +01F2/2 ALL root_flags If set, the root is mounted readonly +01F4/4 2.04+(2 syssize The size of the 32-bit code in 16-byte paras +01F8/2 ALL ram_size DO NOT USE - for bootsect.S use only +01FA/2 ALL vid_mode Video mode control +01FC/2 ALL root_dev Default root device number +01FE/2 ALL boot_flag 0xAA55 magic number +0200/2 2.00+ jump Jump instruction +0202/4 2.00+ header Magic signature "HdrS" +0206/2 2.00+ version Boot protocol version supported +0208/4 2.00+ realmode_swtch Boot loader hook (see below) +020C/2 2.00+ start_sys The load-low segment (0x1000) (obsolete) +020E/2 2.00+ kernel_version Pointer to kernel version string +0210/1 2.00+ type_of_loader Boot loader identifier +0211/1 2.00+ loadflags Boot protocol option flags +0212/2 2.00+ setup_move_size Move to high memory size (used with hooks) +0214/4 2.00+ code32_start Boot loader hook (see below) +0218/4 2.00+ ramdisk_image initrd load address (set by boot loader) +021C/4 2.00+ ramdisk_size initrd size (set by boot loader) +0220/4 2.00+ bootsect_kludge DO NOT USE - for bootsect.S use only +0224/2 2.01+ heap_end_ptr Free memory after setup end +0226/2 N/A pad1 Unused +0228/4 2.02+ cmd_line_ptr 32-bit pointer to the kernel command line +022C/4 2.03+ initrd_addr_max Highest legal initrd address +0230/4 2.05+ kernel_alignment Physical addr alignment required for kernel +0234/1 2.05+ relocatable_kernel Whether kernel is relocatable or not +0235/3 N/A pad2 Unused +0238/4 2.06+ cmdline_size Maximum size of the kernel command line +023C/4 2.07+ hardware_subarch Hardware subarchitecture +0240/8 2.07+ hardware_subarch_data Subarchitecture-specific data +0248/4 2.08+ payload_offset Offset of kernel payload +024C/4 2.08+ payload_length Length of kernel payload +0250/8 2.09+ setup_data 64-bit physical pointer to linked list + of struct setup_data + +(1) For backwards compatibility, if the setup_sects field contains 0, the + real value is 4. + +(2) For boot protocol prior to 2.04, the upper two bytes of the syssize + field are unusable, which means the size of a bzImage kernel + cannot be determined. + +If the "HdrS" (0x53726448) magic number is not found at offset 0x202, +the boot protocol version is "old". Loading an old kernel, the +following parameters should be assumed: + + Image type = zImage + initrd not supported + Real-mode kernel must be located at 0x90000. + +Otherwise, the "version" field contains the protocol version, +e.g. protocol version 2.01 will contain 0x0201 in this field. When +setting fields in the header, you must make sure only to set fields +supported by the protocol version in use. + + +**** DETAILS OF HEADER FIELDS + +For each field, some are information from the kernel to the bootloader +("read"), some are expected to be filled out by the bootloader +("write"), and some are expected to be read and modified by the +bootloader ("modify"). + +All general purpose boot loaders should write the fields marked +(obligatory). Boot loaders who want to load the kernel at a +nonstandard address should fill in the fields marked (reloc); other +boot loaders can ignore those fields. + +The byte order of all fields is littleendian (this is x86, after all.) + +Field name: setup_sects +Type: read +Offset/size: 0x1f1/1 +Protocol: ALL + + The size of the setup code in 512-byte sectors. If this field is + 0, the real value is 4. The real-mode code consists of the boot + sector (always one 512-byte sector) plus the setup code. + +Field name: root_flags +Type: modify (optional) +Offset/size: 0x1f2/2 +Protocol: ALL + + If this field is nonzero, the root defaults to readonly. The use of + this field is deprecated; use the "ro" or "rw" options on the + command line instead. + +Field name: syssize +Type: read +Offset/size: 0x1f4/4 (protocol 2.04+) 0x1f4/2 (protocol ALL) +Protocol: 2.04+ + + The size of the protected-mode code in units of 16-byte paragraphs. + For protocol versions older than 2.04 this field is only two bytes + wide, and therefore cannot be trusted for the size of a kernel if + the LOAD_HIGH flag is set. + +Field name: ram_size +Type: kernel internal +Offset/size: 0x1f8/2 +Protocol: ALL + + This field is obsolete. + +Field name: vid_mode +Type: modify (obligatory) +Offset/size: 0x1fa/2 + + Please see the section on SPECIAL COMMAND LINE OPTIONS. + +Field name: root_dev +Type: modify (optional) +Offset/size: 0x1fc/2 +Protocol: ALL + + The default root device device number. The use of this field is + deprecated, use the "root=" option on the command line instead. + +Field name: boot_flag +Type: read +Offset/size: 0x1fe/2 +Protocol: ALL + + Contains 0xAA55. This is the closest thing old Linux kernels have + to a magic number. + +Field name: jump +Type: read +Offset/size: 0x200/2 +Protocol: 2.00+ + + Contains an x86 jump instruction, 0xEB followed by a signed offset + relative to byte 0x202. This can be used to determine the size of + the header. + +Field name: header +Type: read +Offset/size: 0x202/4 +Protocol: 2.00+ + + Contains the magic number "HdrS" (0x53726448). + +Field name: version +Type: read +Offset/size: 0x206/2 +Protocol: 2.00+ + + Contains the boot protocol version, in (major << 8)+minor format, + e.g. 0x0204 for version 2.04, and 0x0a11 for a hypothetical version + 10.17. + +Field name: readmode_swtch +Type: modify (optional) +Offset/size: 0x208/4 +Protocol: 2.00+ + + Boot loader hook (see ADVANCED BOOT LOADER HOOKS below.) + +Field name: start_sys +Type: read +Offset/size: 0x20c/2 +Protocol: 2.00+ + + The load low segment (0x1000). Obsolete. + +Field name: kernel_version +Type: read +Offset/size: 0x20e/2 +Protocol: 2.00+ + + If set to a nonzero value, contains a pointer to a NUL-terminated + human-readable kernel version number string, less 0x200. This can + be used to display the kernel version to the user. This value + should be less than (0x200*setup_sects). + + For example, if this value is set to 0x1c00, the kernel version + number string can be found at offset 0x1e00 in the kernel file. + This is a valid value if and only if the "setup_sects" field + contains the value 15 or higher, as: + + 0x1c00 < 15*0x200 (= 0x1e00) but + 0x1c00 >= 14*0x200 (= 0x1c00) + + 0x1c00 >> 9 = 14, so the minimum value for setup_secs is 15. + +Field name: type_of_loader +Type: write (obligatory) +Offset/size: 0x210/1 +Protocol: 2.00+ + + If your boot loader has an assigned id (see table below), enter + 0xTV here, where T is an identifier for the boot loader and V is + a version number. Otherwise, enter 0xFF here. + + Assigned boot loader ids: + 0 LILO (0x00 reserved for pre-2.00 bootloader) + 1 Loadlin + 2 bootsect-loader (0x20, all other values reserved) + 3 SYSLINUX + 4 EtherBoot + 5 ELILO + 7 GRuB + 8 U-BOOT + 9 Xen + A Gujin + B Qemu + + Please contact if you need a bootloader ID + value assigned. + +Field name: loadflags +Type: modify (obligatory) +Offset/size: 0x211/1 +Protocol: 2.00+ + + This field is a bitmask. + + Bit 0 (read): LOADED_HIGH + - If 0, the protected-mode code is loaded at 0x10000. + - If 1, the protected-mode code is loaded at 0x100000. + + Bit 5 (write): QUIET_FLAG + - If 0, print early messages. + - If 1, suppress early messages. + This requests to the kernel (decompressor and early + kernel) to not write early messages that require + accessing the display hardware directly. + + Bit 6 (write): KEEP_SEGMENTS + Protocol: 2.07+ + - If 0, reload the segment registers in the 32bit entry point. + - If 1, do not reload the segment registers in the 32bit entry point. + Assume that %cs %ds %ss %es are all set to flat segments with + a base of 0 (or the equivalent for their environment). + + Bit 7 (write): CAN_USE_HEAP + Set this bit to 1 to indicate that the value entered in the + heap_end_ptr is valid. If this field is clear, some setup code + functionality will be disabled. + +Field name: setup_move_size +Type: modify (obligatory) +Offset/size: 0x212/2 +Protocol: 2.00-2.01 + + When using protocol 2.00 or 2.01, if the real mode kernel is not + loaded at 0x90000, it gets moved there later in the loading + sequence. Fill in this field if you want additional data (such as + the kernel command line) moved in addition to the real-mode kernel + itself. + + The unit is bytes starting with the beginning of the boot sector. + + This field is can be ignored when the protocol is 2.02 or higher, or + if the real-mode code is loaded at 0x90000. + +Field name: code32_start +Type: modify (optional, reloc) +Offset/size: 0x214/4 +Protocol: 2.00+ + + The address to jump to in protected mode. This defaults to the load + address of the kernel, and can be used by the boot loader to + determine the proper load address. + + This field can be modified for two purposes: + + 1. as a boot loader hook (see ADVANCED BOOT LOADER HOOKS below.) + + 2. if a bootloader which does not install a hook loads a + relocatable kernel at a nonstandard address it will have to modify + this field to point to the load address. + +Field name: ramdisk_image +Type: write (obligatory) +Offset/size: 0x218/4 +Protocol: 2.00+ + + The 32-bit linear address of the initial ramdisk or ramfs. Leave at + zero if there is no initial ramdisk/ramfs. + +Field name: ramdisk_size +Type: write (obligatory) +Offset/size: 0x21c/4 +Protocol: 2.00+ + + Size of the initial ramdisk or ramfs. Leave at zero if there is no + initial ramdisk/ramfs. + +Field name: bootsect_kludge +Type: kernel internal +Offset/size: 0x220/4 +Protocol: 2.00+ + + This field is obsolete. + +Field name: heap_end_ptr +Type: write (obligatory) +Offset/size: 0x224/2 +Protocol: 2.01+ + + Set this field to the offset (from the beginning of the real-mode + code) of the end of the setup stack/heap, minus 0x0200. + +Field name: cmd_line_ptr +Type: write (obligatory) +Offset/size: 0x228/4 +Protocol: 2.02+ + + Set this field to the linear address of the kernel command line. + The kernel command line can be located anywhere between the end of + the setup heap and 0xA0000; it does not have to be located in the + same 64K segment as the real-mode code itself. + + Fill in this field even if your boot loader does not support a + command line, in which case you can point this to an empty string + (or better yet, to the string "auto".) If this field is left at + zero, the kernel will assume that your boot loader does not support + the 2.02+ protocol. + +Field name: initrd_addr_max +Type: read +Offset/size: 0x22c/4 +Protocol: 2.03+ + + The maximum address that may be occupied by the initial + ramdisk/ramfs contents. For boot protocols 2.02 or earlier, this + field is not present, and the maximum address is 0x37FFFFFF. (This + address is defined as the address of the highest safe byte, so if + your ramdisk is exactly 131072 bytes long and this field is + 0x37FFFFFF, you can start your ramdisk at 0x37FE0000.) + +Field name: kernel_alignment +Type: read (reloc) +Offset/size: 0x230/4 +Protocol: 2.05+ + + Alignment unit required by the kernel (if relocatable_kernel is true.) + +Field name: relocatable_kernel +Type: read (reloc) +Offset/size: 0x234/1 +Protocol: 2.05+ + + If this field is nonzero, the protected-mode part of the kernel can + be loaded at any address that satisfies the kernel_alignment field. + After loading, the boot loader must set the code32_start field to + point to the loaded code, or to a boot loader hook. + +Field name: cmdline_size +Type: read +Offset/size: 0x238/4 +Protocol: 2.06+ + + The maximum size of the command line without the terminating + zero. This means that the command line can contain at most + cmdline_size characters. With protocol version 2.05 and earlier, the + maximum size was 255. + +Field name: hardware_subarch +Type: write (optional, defaults to x86/PC) +Offset/size: 0x23c/4 +Protocol: 2.07+ + + In a paravirtualized environment the hardware low level architectural + pieces such as interrupt handling, page table handling, and + accessing process control registers needs to be done differently. + + This field allows the bootloader to inform the kernel we are in one + one of those environments. + + 0x00000000 The default x86/PC environment + 0x00000001 lguest + 0x00000002 Xen + +Field name: hardware_subarch_data +Type: write (subarch-dependent) +Offset/size: 0x240/8 +Protocol: 2.07+ + + A pointer to data that is specific to hardware subarch + This field is currently unused for the default x86/PC environment, + do not modify. + +Field name: payload_offset +Type: read +Offset/size: 0x248/4 +Protocol: 2.08+ + + If non-zero then this field contains the offset from the end of the + real-mode code to the payload. + + The payload may be compressed. The format of both the compressed and + uncompressed data should be determined using the standard magic + numbers. Currently only gzip compressed ELF is used. + +Field name: payload_length +Type: read +Offset/size: 0x24c/4 +Protocol: 2.08+ + + The length of the payload. + +Field name: setup_data +Type: write (special) +Offset/size: 0x250/8 +Protocol: 2.09+ + + The 64-bit physical pointer to NULL terminated single linked list of + struct setup_data. This is used to define a more extensible boot + parameters passing mechanism. The definition of struct setup_data is + as follow: + + struct setup_data { + u64 next; + u32 type; + u32 len; + u8 data[0]; + }; + + Where, the next is a 64-bit physical pointer to the next node of + linked list, the next field of the last node is 0; the type is used + to identify the contents of data; the len is the length of data + field; the data holds the real payload. + + This list may be modified at a number of points during the bootup + process. Therefore, when modifying this list one should always make + sure to consider the case where the linked list already contains + entries. + + +**** THE IMAGE CHECKSUM + +From boot protocol version 2.08 onwards the CRC-32 is calculated over +the entire file using the characteristic polynomial 0x04C11DB7 and an +initial remainder of 0xffffffff. The checksum is appended to the +file; therefore the CRC of the file up to the limit specified in the +syssize field of the header is always 0. + + +**** THE KERNEL COMMAND LINE + +The kernel command line has become an important way for the boot +loader to communicate with the kernel. Some of its options are also +relevant to the boot loader itself, see "special command line options" +below. + +The kernel command line is a null-terminated string. The maximum +length can be retrieved from the field cmdline_size. Before protocol +version 2.06, the maximum was 255 characters. A string that is too +long will be automatically truncated by the kernel. + +If the boot protocol version is 2.02 or later, the address of the +kernel command line is given by the header field cmd_line_ptr (see +above.) This address can be anywhere between the end of the setup +heap and 0xA0000. + +If the protocol version is *not* 2.02 or higher, the kernel +command line is entered using the following protocol: + + At offset 0x0020 (word), "cmd_line_magic", enter the magic + number 0xA33F. + + At offset 0x0022 (word), "cmd_line_offset", enter the offset + of the kernel command line (relative to the start of the + real-mode kernel). + + The kernel command line *must* be within the memory region + covered by setup_move_size, so you may need to adjust this + field. + + +**** MEMORY LAYOUT OF THE REAL-MODE CODE + +The real-mode code requires a stack/heap to be set up, as well as +memory allocated for the kernel command line. This needs to be done +in the real-mode accessible memory in bottom megabyte. + +It should be noted that modern machines often have a sizable Extended +BIOS Data Area (EBDA). As a result, it is advisable to use as little +of the low megabyte as possible. + +Unfortunately, under the following circumstances the 0x90000 memory +segment has to be used: + + - When loading a zImage kernel ((loadflags & 0x01) == 0). + - When loading a 2.01 or earlier boot protocol kernel. + + -> For the 2.00 and 2.01 boot protocols, the real-mode code + can be loaded at another address, but it is internally + relocated to 0x90000. For the "old" protocol, the + real-mode code must be loaded at 0x90000. + +When loading at 0x90000, avoid using memory above 0x9a000. + +For boot protocol 2.02 or higher, the command line does not have to be +located in the same 64K segment as the real-mode setup code; it is +thus permitted to give the stack/heap the full 64K segment and locate +the command line above it. + +The kernel command line should not be located below the real-mode +code, nor should it be located in high memory. + + +**** SAMPLE BOOT CONFIGURATION + +As a sample configuration, assume the following layout of the real +mode segment: + + When loading below 0x90000, use the entire segment: + + 0x0000-0x7fff Real mode kernel + 0x8000-0xdfff Stack and heap + 0xe000-0xffff Kernel command line + + When loading at 0x90000 OR the protocol version is 2.01 or earlier: + + 0x0000-0x7fff Real mode kernel + 0x8000-0x97ff Stack and heap + 0x9800-0x9fff Kernel command line + +Such a boot loader should enter the following fields in the header: + + unsigned long base_ptr; /* base address for real-mode segment */ + + if ( setup_sects == 0 ) { + setup_sects = 4; + } + + if ( protocol >= 0x0200 ) { + type_of_loader = ; + if ( loading_initrd ) { + ramdisk_image = ; + ramdisk_size = ; + } + + if ( protocol >= 0x0202 && loadflags & 0x01 ) + heap_end = 0xe000; + else + heap_end = 0x9800; + + if ( protocol >= 0x0201 ) { + heap_end_ptr = heap_end - 0x200; + loadflags |= 0x80; /* CAN_USE_HEAP */ + } + + if ( protocol >= 0x0202 ) { + cmd_line_ptr = base_ptr + heap_end; + strcpy(cmd_line_ptr, cmdline); + } else { + cmd_line_magic = 0xA33F; + cmd_line_offset = heap_end; + setup_move_size = heap_end + strlen(cmdline)+1; + strcpy(base_ptr+cmd_line_offset, cmdline); + } + } else { + /* Very old kernel */ + + heap_end = 0x9800; + + cmd_line_magic = 0xA33F; + cmd_line_offset = heap_end; + + /* A very old kernel MUST have its real-mode code + loaded at 0x90000 */ + + if ( base_ptr != 0x90000 ) { + /* Copy the real-mode kernel */ + memcpy(0x90000, base_ptr, (setup_sects+1)*512); + base_ptr = 0x90000; /* Relocated */ + } + + strcpy(0x90000+cmd_line_offset, cmdline); + + /* It is recommended to clear memory up to the 32K mark */ + memset(0x90000 + (setup_sects+1)*512, 0, + (64-(setup_sects+1))*512); + } + + +**** LOADING THE REST OF THE KERNEL + +The 32-bit (non-real-mode) kernel starts at offset (setup_sects+1)*512 +in the kernel file (again, if setup_sects == 0 the real value is 4.) +It should be loaded at address 0x10000 for Image/zImage kernels and +0x100000 for bzImage kernels. + +The kernel is a bzImage kernel if the protocol >= 2.00 and the 0x01 +bit (LOAD_HIGH) in the loadflags field is set: + + is_bzImage = (protocol >= 0x0200) && (loadflags & 0x01); + load_address = is_bzImage ? 0x100000 : 0x10000; + +Note that Image/zImage kernels can be up to 512K in size, and thus use +the entire 0x10000-0x90000 range of memory. This means it is pretty +much a requirement for these kernels to load the real-mode part at +0x90000. bzImage kernels allow much more flexibility. + + +**** SPECIAL COMMAND LINE OPTIONS + +If the command line provided by the boot loader is entered by the +user, the user may expect the following command line options to work. +They should normally not be deleted from the kernel command line even +though not all of them are actually meaningful to the kernel. Boot +loader authors who need additional command line options for the boot +loader itself should get them registered in +Documentation/kernel-parameters.txt to make sure they will not +conflict with actual kernel options now or in the future. + + vga= + here is either an integer (in C notation, either + decimal, octal, or hexadecimal) or one of the strings + "normal" (meaning 0xFFFF), "ext" (meaning 0xFFFE) or "ask" + (meaning 0xFFFD). This value should be entered into the + vid_mode field, as it is used by the kernel before the command + line is parsed. + + mem= + is an integer in C notation optionally followed by + (case insensitive) K, M, G, T, P or E (meaning << 10, << 20, + << 30, << 40, << 50 or << 60). This specifies the end of + memory to the kernel. This affects the possible placement of + an initrd, since an initrd should be placed near end of + memory. Note that this is an option to *both* the kernel and + the bootloader! + + initrd= + An initrd should be loaded. The meaning of is + obviously bootloader-dependent, and some boot loaders + (e.g. LILO) do not have such a command. + +In addition, some boot loaders add the following options to the +user-specified command line: + + BOOT_IMAGE= + The boot image which was loaded. Again, the meaning of + is obviously bootloader-dependent. + + auto + The kernel was booted without explicit user intervention. + +If these options are added by the boot loader, it is highly +recommended that they are located *first*, before the user-specified +or configuration-specified command line. Otherwise, "init=/bin/sh" +gets confused by the "auto" option. + + +**** RUNNING THE KERNEL + +The kernel is started by jumping to the kernel entry point, which is +located at *segment* offset 0x20 from the start of the real mode +kernel. This means that if you loaded your real-mode kernel code at +0x90000, the kernel entry point is 9020:0000. + +At entry, ds = es = ss should point to the start of the real-mode +kernel code (0x9000 if the code is loaded at 0x90000), sp should be +set up properly, normally pointing to the top of the heap, and +interrupts should be disabled. Furthermore, to guard against bugs in +the kernel, it is recommended that the boot loader sets fs = gs = ds = +es = ss. + +In our example from above, we would do: + + /* Note: in the case of the "old" kernel protocol, base_ptr must + be == 0x90000 at this point; see the previous sample code */ + + seg = base_ptr >> 4; + + cli(); /* Enter with interrupts disabled! */ + + /* Set up the real-mode kernel stack */ + _SS = seg; + _SP = heap_end; + + _DS = _ES = _FS = _GS = seg; + jmp_far(seg+0x20, 0); /* Run the kernel */ + +If your boot sector accesses a floppy drive, it is recommended to +switch off the floppy motor before running the kernel, since the +kernel boot leaves interrupts off and thus the motor will not be +switched off, especially if the loaded kernel has the floppy driver as +a demand-loaded module! + + +**** ADVANCED BOOT LOADER HOOKS + +If the boot loader runs in a particularly hostile environment (such as +LOADLIN, which runs under DOS) it may be impossible to follow the +standard memory location requirements. Such a boot loader may use the +following hooks that, if set, are invoked by the kernel at the +appropriate time. The use of these hooks should probably be +considered an absolutely last resort! + +IMPORTANT: All the hooks are required to preserve %esp, %ebp, %esi and +%edi across invocation. + + realmode_swtch: + A 16-bit real mode far subroutine invoked immediately before + entering protected mode. The default routine disables NMI, so + your routine should probably do so, too. + + code32_start: + A 32-bit flat-mode routine *jumped* to immediately after the + transition to protected mode, but before the kernel is + uncompressed. No segments, except CS, are guaranteed to be + set up (current kernels do, but older ones do not); you should + set them up to BOOT_DS (0x18) yourself. + + After completing your hook, you should jump to the address + that was in this field before your boot loader overwrote it + (relocated, if appropriate.) + + +**** 32-bit BOOT PROTOCOL + +For machine with some new BIOS other than legacy BIOS, such as EFI, +LinuxBIOS, etc, and kexec, the 16-bit real mode setup code in kernel +based on legacy BIOS can not be used, so a 32-bit boot protocol needs +to be defined. + +In 32-bit boot protocol, the first step in loading a Linux kernel +should be to setup the boot parameters (struct boot_params, +traditionally known as "zero page"). The memory for struct boot_params +should be allocated and initialized to all zero. Then the setup header +from offset 0x01f1 of kernel image on should be loaded into struct +boot_params and examined. The end of setup header can be calculated as +follow: + + 0x0202 + byte value at offset 0x0201 + +In addition to read/modify/write the setup header of the struct +boot_params as that of 16-bit boot protocol, the boot loader should +also fill the additional fields of the struct boot_params as that +described in zero-page.txt. + +After setupping the struct boot_params, the boot loader can load the +32/64-bit kernel in the same way as that of 16-bit boot protocol. + +In 32-bit boot protocol, the kernel is started by jumping to the +32-bit kernel entry point, which is the start address of loaded +32/64-bit kernel. + +At entry, the CPU must be in 32-bit protected mode with paging +disabled; a GDT must be loaded with the descriptors for selectors +__BOOT_CS(0x10) and __BOOT_DS(0x18); both descriptors must be 4G flat +segment; __BOOS_CS must have execute/read permission, and __BOOT_DS +must have read/write permission; CS must be __BOOT_CS and DS, ES, SS +must be __BOOT_DS; interrupt must be disabled; %esi must hold the base +address of the struct boot_params; %ebp, %edi and %ebx must be zero. diff --git a/Documentation/x86/i386/boot.txt b/Documentation/x86/i386/boot.txt deleted file mode 100644 index 147bfe5..0000000 --- a/Documentation/x86/i386/boot.txt +++ /dev/null @@ -1,900 +0,0 @@ - THE LINUX/x86 BOOT PROTOCOL - --------------------------- - -On the x86 platform, the Linux kernel uses a rather complicated boot -convention. This has evolved partially due to historical aspects, as -well as the desire in the early days to have the kernel itself be a -bootable image, the complicated PC memory model and due to changed -expectations in the PC industry caused by the effective demise of -real-mode DOS as a mainstream operating system. - -Currently, the following versions of the Linux/x86 boot protocol exist. - -Old kernels: zImage/Image support only. Some very early kernels - may not even support a command line. - -Protocol 2.00: (Kernel 1.3.73) Added bzImage and initrd support, as - well as a formalized way to communicate between the - boot loader and the kernel. setup.S made relocatable, - although the traditional setup area still assumed - writable. - -Protocol 2.01: (Kernel 1.3.76) Added a heap overrun warning. - -Protocol 2.02: (Kernel 2.4.0-test3-pre3) New command line protocol. - Lower the conventional memory ceiling. No overwrite - of the traditional setup area, thus making booting - safe for systems which use the EBDA from SMM or 32-bit - BIOS entry points. zImage deprecated but still - supported. - -Protocol 2.03: (Kernel 2.4.18-pre1) Explicitly makes the highest possible - initrd address available to the bootloader. - -Protocol 2.04: (Kernel 2.6.14) Extend the syssize field to four bytes. - -Protocol 2.05: (Kernel 2.6.20) Make protected mode kernel relocatable. - Introduce relocatable_kernel and kernel_alignment fields. - -Protocol 2.06: (Kernel 2.6.22) Added a field that contains the size of - the boot command line. - -Protocol 2.07: (Kernel 2.6.24) Added paravirtualised boot protocol. - Introduced hardware_subarch and hardware_subarch_data - and KEEP_SEGMENTS flag in load_flags. - -Protocol 2.08: (Kernel 2.6.26) Added crc32 checksum and ELF format - payload. Introduced payload_offset and payload length - fields to aid in locating the payload. - -Protocol 2.09: (Kernel 2.6.26) Added a field of 64-bit physical - pointer to single linked list of struct setup_data. - -**** MEMORY LAYOUT - -The traditional memory map for the kernel loader, used for Image or -zImage kernels, typically looks like: - - | | -0A0000 +------------------------+ - | Reserved for BIOS | Do not use. Reserved for BIOS EBDA. -09A000 +------------------------+ - | Command line | - | Stack/heap | For use by the kernel real-mode code. -098000 +------------------------+ - | Kernel setup | The kernel real-mode code. -090200 +------------------------+ - | Kernel boot sector | The kernel legacy boot sector. -090000 +------------------------+ - | Protected-mode kernel | The bulk of the kernel image. -010000 +------------------------+ - | Boot loader | <- Boot sector entry point 0000:7C00 -001000 +------------------------+ - | Reserved for MBR/BIOS | -000800 +------------------------+ - | Typically used by MBR | -000600 +------------------------+ - | BIOS use only | -000000 +------------------------+ - - -When using bzImage, the protected-mode kernel was relocated to -0x100000 ("high memory"), and the kernel real-mode block (boot sector, -setup, and stack/heap) was made relocatable to any address between -0x10000 and end of low memory. Unfortunately, in protocols 2.00 and -2.01 the 0x90000+ memory range is still used internally by the kernel; -the 2.02 protocol resolves that problem. - -It is desirable to keep the "memory ceiling" -- the highest point in -low memory touched by the boot loader -- as low as possible, since -some newer BIOSes have begun to allocate some rather large amounts of -memory, called the Extended BIOS Data Area, near the top of low -memory. The boot loader should use the "INT 12h" BIOS call to verify -how much low memory is available. - -Unfortunately, if INT 12h reports that the amount of memory is too -low, there is usually nothing the boot loader can do but to report an -error to the user. The boot loader should therefore be designed to -take up as little space in low memory as it reasonably can. For -zImage or old bzImage kernels, which need data written into the -0x90000 segment, the boot loader should make sure not to use memory -above the 0x9A000 point; too many BIOSes will break above that point. - -For a modern bzImage kernel with boot protocol version >= 2.02, a -memory layout like the following is suggested: - - ~ ~ - | Protected-mode kernel | -100000 +------------------------+ - | I/O memory hole | -0A0000 +------------------------+ - | Reserved for BIOS | Leave as much as possible unused - ~ ~ - | Command line | (Can also be below the X+10000 mark) -X+10000 +------------------------+ - | Stack/heap | For use by the kernel real-mode code. -X+08000 +------------------------+ - | Kernel setup | The kernel real-mode code. - | Kernel boot sector | The kernel legacy boot sector. -X +------------------------+ - | Boot loader | <- Boot sector entry point 0000:7C00 -001000 +------------------------+ - | Reserved for MBR/BIOS | -000800 +------------------------+ - | Typically used by MBR | -000600 +------------------------+ - | BIOS use only | -000000 +------------------------+ - -... where the address X is as low as the design of the boot loader -permits. - - -**** THE REAL-MODE KERNEL HEADER - -In the following text, and anywhere in the kernel boot sequence, "a -sector" refers to 512 bytes. It is independent of the actual sector -size of the underlying medium. - -The first step in loading a Linux kernel should be to load the -real-mode code (boot sector and setup code) and then examine the -following header at offset 0x01f1. The real-mode code can total up to -32K, although the boot loader may choose to load only the first two -sectors (1K) and then examine the bootup sector size. - -The header looks like: - -Offset Proto Name Meaning -/Size - -01F1/1 ALL(1 setup_sects The size of the setup in sectors -01F2/2 ALL root_flags If set, the root is mounted readonly -01F4/4 2.04+(2 syssize The size of the 32-bit code in 16-byte paras -01F8/2 ALL ram_size DO NOT USE - for bootsect.S use only -01FA/2 ALL vid_mode Video mode control -01FC/2 ALL root_dev Default root device number -01FE/2 ALL boot_flag 0xAA55 magic number -0200/2 2.00+ jump Jump instruction -0202/4 2.00+ header Magic signature "HdrS" -0206/2 2.00+ version Boot protocol version supported -0208/4 2.00+ realmode_swtch Boot loader hook (see below) -020C/2 2.00+ start_sys The load-low segment (0x1000) (obsolete) -020E/2 2.00+ kernel_version Pointer to kernel version string -0210/1 2.00+ type_of_loader Boot loader identifier -0211/1 2.00+ loadflags Boot protocol option flags -0212/2 2.00+ setup_move_size Move to high memory size (used with hooks) -0214/4 2.00+ code32_start Boot loader hook (see below) -0218/4 2.00+ ramdisk_image initrd load address (set by boot loader) -021C/4 2.00+ ramdisk_size initrd size (set by boot loader) -0220/4 2.00+ bootsect_kludge DO NOT USE - for bootsect.S use only -0224/2 2.01+ heap_end_ptr Free memory after setup end -0226/2 N/A pad1 Unused -0228/4 2.02+ cmd_line_ptr 32-bit pointer to the kernel command line -022C/4 2.03+ initrd_addr_max Highest legal initrd address -0230/4 2.05+ kernel_alignment Physical addr alignment required for kernel -0234/1 2.05+ relocatable_kernel Whether kernel is relocatable or not -0235/3 N/A pad2 Unused -0238/4 2.06+ cmdline_size Maximum size of the kernel command line -023C/4 2.07+ hardware_subarch Hardware subarchitecture -0240/8 2.07+ hardware_subarch_data Subarchitecture-specific data -0248/4 2.08+ payload_offset Offset of kernel payload -024C/4 2.08+ payload_length Length of kernel payload -0250/8 2.09+ setup_data 64-bit physical pointer to linked list - of struct setup_data - -(1) For backwards compatibility, if the setup_sects field contains 0, the - real value is 4. - -(2) For boot protocol prior to 2.04, the upper two bytes of the syssize - field are unusable, which means the size of a bzImage kernel - cannot be determined. - -If the "HdrS" (0x53726448) magic number is not found at offset 0x202, -the boot protocol version is "old". Loading an old kernel, the -following parameters should be assumed: - - Image type = zImage - initrd not supported - Real-mode kernel must be located at 0x90000. - -Otherwise, the "version" field contains the protocol version, -e.g. protocol version 2.01 will contain 0x0201 in this field. When -setting fields in the header, you must make sure only to set fields -supported by the protocol version in use. - - -**** DETAILS OF HEADER FIELDS - -For each field, some are information from the kernel to the bootloader -("read"), some are expected to be filled out by the bootloader -("write"), and some are expected to be read and modified by the -bootloader ("modify"). - -All general purpose boot loaders should write the fields marked -(obligatory). Boot loaders who want to load the kernel at a -nonstandard address should fill in the fields marked (reloc); other -boot loaders can ignore those fields. - -The byte order of all fields is littleendian (this is x86, after all.) - -Field name: setup_sects -Type: read -Offset/size: 0x1f1/1 -Protocol: ALL - - The size of the setup code in 512-byte sectors. If this field is - 0, the real value is 4. The real-mode code consists of the boot - sector (always one 512-byte sector) plus the setup code. - -Field name: root_flags -Type: modify (optional) -Offset/size: 0x1f2/2 -Protocol: ALL - - If this field is nonzero, the root defaults to readonly. The use of - this field is deprecated; use the "ro" or "rw" options on the - command line instead. - -Field name: syssize -Type: read -Offset/size: 0x1f4/4 (protocol 2.04+) 0x1f4/2 (protocol ALL) -Protocol: 2.04+ - - The size of the protected-mode code in units of 16-byte paragraphs. - For protocol versions older than 2.04 this field is only two bytes - wide, and therefore cannot be trusted for the size of a kernel if - the LOAD_HIGH flag is set. - -Field name: ram_size -Type: kernel internal -Offset/size: 0x1f8/2 -Protocol: ALL - - This field is obsolete. - -Field name: vid_mode -Type: modify (obligatory) -Offset/size: 0x1fa/2 - - Please see the section on SPECIAL COMMAND LINE OPTIONS. - -Field name: root_dev -Type: modify (optional) -Offset/size: 0x1fc/2 -Protocol: ALL - - The default root device device number. The use of this field is - deprecated, use the "root=" option on the command line instead. - -Field name: boot_flag -Type: read -Offset/size: 0x1fe/2 -Protocol: ALL - - Contains 0xAA55. This is the closest thing old Linux kernels have - to a magic number. - -Field name: jump -Type: read -Offset/size: 0x200/2 -Protocol: 2.00+ - - Contains an x86 jump instruction, 0xEB followed by a signed offset - relative to byte 0x202. This can be used to determine the size of - the header. - -Field name: header -Type: read -Offset/size: 0x202/4 -Protocol: 2.00+ - - Contains the magic number "HdrS" (0x53726448). - -Field name: version -Type: read -Offset/size: 0x206/2 -Protocol: 2.00+ - - Contains the boot protocol version, in (major << 8)+minor format, - e.g. 0x0204 for version 2.04, and 0x0a11 for a hypothetical version - 10.17. - -Field name: readmode_swtch -Type: modify (optional) -Offset/size: 0x208/4 -Protocol: 2.00+ - - Boot loader hook (see ADVANCED BOOT LOADER HOOKS below.) - -Field name: start_sys -Type: read -Offset/size: 0x20c/4 -Protocol: 2.00+ - - The load low segment (0x1000). Obsolete. - -Field name: kernel_version -Type: read -Offset/size: 0x20e/2 -Protocol: 2.00+ - - If set to a nonzero value, contains a pointer to a NUL-terminated - human-readable kernel version number string, less 0x200. This can - be used to display the kernel version to the user. This value - should be less than (0x200*setup_sects). - - For example, if this value is set to 0x1c00, the kernel version - number string can be found at offset 0x1e00 in the kernel file. - This is a valid value if and only if the "setup_sects" field - contains the value 15 or higher, as: - - 0x1c00 < 15*0x200 (= 0x1e00) but - 0x1c00 >= 14*0x200 (= 0x1c00) - - 0x1c00 >> 9 = 14, so the minimum value for setup_secs is 15. - -Field name: type_of_loader -Type: write (obligatory) -Offset/size: 0x210/1 -Protocol: 2.00+ - - If your boot loader has an assigned id (see table below), enter - 0xTV here, where T is an identifier for the boot loader and V is - a version number. Otherwise, enter 0xFF here. - - Assigned boot loader ids: - 0 LILO (0x00 reserved for pre-2.00 bootloader) - 1 Loadlin - 2 bootsect-loader (0x20, all other values reserved) - 3 SYSLINUX - 4 EtherBoot - 5 ELILO - 7 GRuB - 8 U-BOOT - 9 Xen - A Gujin - B Qemu - - Please contact if you need a bootloader ID - value assigned. - -Field name: loadflags -Type: modify (obligatory) -Offset/size: 0x211/1 -Protocol: 2.00+ - - This field is a bitmask. - - Bit 0 (read): LOADED_HIGH - - If 0, the protected-mode code is loaded at 0x10000. - - If 1, the protected-mode code is loaded at 0x100000. - - Bit 5 (write): QUIET_FLAG - - If 0, print early messages. - - If 1, suppress early messages. - This requests to the kernel (decompressor and early - kernel) to not write early messages that require - accessing the display hardware directly. - - Bit 6 (write): KEEP_SEGMENTS - Protocol: 2.07+ - - If 0, reload the segment registers in the 32bit entry point. - - If 1, do not reload the segment registers in the 32bit entry point. - Assume that %cs %ds %ss %es are all set to flat segments with - a base of 0 (or the equivalent for their environment). - - Bit 7 (write): CAN_USE_HEAP - Set this bit to 1 to indicate that the value entered in the - heap_end_ptr is valid. If this field is clear, some setup code - functionality will be disabled. - -Field name: setup_move_size -Type: modify (obligatory) -Offset/size: 0x212/2 -Protocol: 2.00-2.01 - - When using protocol 2.00 or 2.01, if the real mode kernel is not - loaded at 0x90000, it gets moved there later in the loading - sequence. Fill in this field if you want additional data (such as - the kernel command line) moved in addition to the real-mode kernel - itself. - - The unit is bytes starting with the beginning of the boot sector. - - This field is can be ignored when the protocol is 2.02 or higher, or - if the real-mode code is loaded at 0x90000. - -Field name: code32_start -Type: modify (optional, reloc) -Offset/size: 0x214/4 -Protocol: 2.00+ - - The address to jump to in protected mode. This defaults to the load - address of the kernel, and can be used by the boot loader to - determine the proper load address. - - This field can be modified for two purposes: - - 1. as a boot loader hook (see ADVANCED BOOT LOADER HOOKS below.) - - 2. if a bootloader which does not install a hook loads a - relocatable kernel at a nonstandard address it will have to modify - this field to point to the load address. - -Field name: ramdisk_image -Type: write (obligatory) -Offset/size: 0x218/4 -Protocol: 2.00+ - - The 32-bit linear address of the initial ramdisk or ramfs. Leave at - zero if there is no initial ramdisk/ramfs. - -Field name: ramdisk_size -Type: write (obligatory) -Offset/size: 0x21c/4 -Protocol: 2.00+ - - Size of the initial ramdisk or ramfs. Leave at zero if there is no - initial ramdisk/ramfs. - -Field name: bootsect_kludge -Type: kernel internal -Offset/size: 0x220/4 -Protocol: 2.00+ - - This field is obsolete. - -Field name: heap_end_ptr -Type: write (obligatory) -Offset/size: 0x224/2 -Protocol: 2.01+ - - Set this field to the offset (from the beginning of the real-mode - code) of the end of the setup stack/heap, minus 0x0200. - -Field name: cmd_line_ptr -Type: write (obligatory) -Offset/size: 0x228/4 -Protocol: 2.02+ - - Set this field to the linear address of the kernel command line. - The kernel command line can be located anywhere between the end of - the setup heap and 0xA0000; it does not have to be located in the - same 64K segment as the real-mode code itself. - - Fill in this field even if your boot loader does not support a - command line, in which case you can point this to an empty string - (or better yet, to the string "auto".) If this field is left at - zero, the kernel will assume that your boot loader does not support - the 2.02+ protocol. - -Field name: initrd_addr_max -Type: read -Offset/size: 0x22c/4 -Protocol: 2.03+ - - The maximum address that may be occupied by the initial - ramdisk/ramfs contents. For boot protocols 2.02 or earlier, this - field is not present, and the maximum address is 0x37FFFFFF. (This - address is defined as the address of the highest safe byte, so if - your ramdisk is exactly 131072 bytes long and this field is - 0x37FFFFFF, you can start your ramdisk at 0x37FE0000.) - -Field name: kernel_alignment -Type: read (reloc) -Offset/size: 0x230/4 -Protocol: 2.05+ - - Alignment unit required by the kernel (if relocatable_kernel is true.) - -Field name: relocatable_kernel -Type: read (reloc) -Offset/size: 0x234/1 -Protocol: 2.05+ - - If this field is nonzero, the protected-mode part of the kernel can - be loaded at any address that satisfies the kernel_alignment field. - After loading, the boot loader must set the code32_start field to - point to the loaded code, or to a boot loader hook. - -Field name: cmdline_size -Type: read -Offset/size: 0x238/4 -Protocol: 2.06+ - - The maximum size of the command line without the terminating - zero. This means that the command line can contain at most - cmdline_size characters. With protocol version 2.05 and earlier, the - maximum size was 255. - -Field name: hardware_subarch -Type: write (optional, defaults to x86/PC) -Offset/size: 0x23c/4 -Protocol: 2.07+ - - In a paravirtualized environment the hardware low level architectural - pieces such as interrupt handling, page table handling, and - accessing process control registers needs to be done differently. - - This field allows the bootloader to inform the kernel we are in one - one of those environments. - - 0x00000000 The default x86/PC environment - 0x00000001 lguest - 0x00000002 Xen - -Field name: hardware_subarch_data -Type: write (subarch-dependent) -Offset/size: 0x240/8 -Protocol: 2.07+ - - A pointer to data that is specific to hardware subarch - This field is currently unused for the default x86/PC environment, - do not modify. - -Field name: payload_offset -Type: read -Offset/size: 0x248/4 -Protocol: 2.08+ - - If non-zero then this field contains the offset from the end of the - real-mode code to the payload. - - The payload may be compressed. The format of both the compressed and - uncompressed data should be determined using the standard magic - numbers. Currently only gzip compressed ELF is used. - -Field name: payload_length -Type: read -Offset/size: 0x24c/4 -Protocol: 2.08+ - - The length of the payload. - -Field name: setup_data -Type: write (special) -Offset/size: 0x250/8 -Protocol: 2.09+ - - The 64-bit physical pointer to NULL terminated single linked list of - struct setup_data. This is used to define a more extensible boot - parameters passing mechanism. The definition of struct setup_data is - as follow: - - struct setup_data { - u64 next; - u32 type; - u32 len; - u8 data[0]; - }; - - Where, the next is a 64-bit physical pointer to the next node of - linked list, the next field of the last node is 0; the type is used - to identify the contents of data; the len is the length of data - field; the data holds the real payload. - - This list may be modified at a number of points during the bootup - process. Therefore, when modifying this list one should always make - sure to consider the case where the linked list already contains - entries. - - -**** THE IMAGE CHECKSUM - -From boot protocol version 2.08 onwards the CRC-32 is calculated over -the entire file using the characteristic polynomial 0x04C11DB7 and an -initial remainder of 0xffffffff. The checksum is appended to the -file; therefore the CRC of the file up to the limit specified in the -syssize field of the header is always 0. - - -**** THE KERNEL COMMAND LINE - -The kernel command line has become an important way for the boot -loader to communicate with the kernel. Some of its options are also -relevant to the boot loader itself, see "special command line options" -below. - -The kernel command line is a null-terminated string. The maximum -length can be retrieved from the field cmdline_size. Before protocol -version 2.06, the maximum was 255 characters. A string that is too -long will be automatically truncated by the kernel. - -If the boot protocol version is 2.02 or later, the address of the -kernel command line is given by the header field cmd_line_ptr (see -above.) This address can be anywhere between the end of the setup -heap and 0xA0000. - -If the protocol version is *not* 2.02 or higher, the kernel -command line is entered using the following protocol: - - At offset 0x0020 (word), "cmd_line_magic", enter the magic - number 0xA33F. - - At offset 0x0022 (word), "cmd_line_offset", enter the offset - of the kernel command line (relative to the start of the - real-mode kernel). - - The kernel command line *must* be within the memory region - covered by setup_move_size, so you may need to adjust this - field. - - -**** MEMORY LAYOUT OF THE REAL-MODE CODE - -The real-mode code requires a stack/heap to be set up, as well as -memory allocated for the kernel command line. This needs to be done -in the real-mode accessible memory in bottom megabyte. - -It should be noted that modern machines often have a sizable Extended -BIOS Data Area (EBDA). As a result, it is advisable to use as little -of the low megabyte as possible. - -Unfortunately, under the following circumstances the 0x90000 memory -segment has to be used: - - - When loading a zImage kernel ((loadflags & 0x01) == 0). - - When loading a 2.01 or earlier boot protocol kernel. - - -> For the 2.00 and 2.01 boot protocols, the real-mode code - can be loaded at another address, but it is internally - relocated to 0x90000. For the "old" protocol, the - real-mode code must be loaded at 0x90000. - -When loading at 0x90000, avoid using memory above 0x9a000. - -For boot protocol 2.02 or higher, the command line does not have to be -located in the same 64K segment as the real-mode setup code; it is -thus permitted to give the stack/heap the full 64K segment and locate -the command line above it. - -The kernel command line should not be located below the real-mode -code, nor should it be located in high memory. - - -**** SAMPLE BOOT CONFIGURATION - -As a sample configuration, assume the following layout of the real -mode segment: - - When loading below 0x90000, use the entire segment: - - 0x0000-0x7fff Real mode kernel - 0x8000-0xdfff Stack and heap - 0xe000-0xffff Kernel command line - - When loading at 0x90000 OR the protocol version is 2.01 or earlier: - - 0x0000-0x7fff Real mode kernel - 0x8000-0x97ff Stack and heap - 0x9800-0x9fff Kernel command line - -Such a boot loader should enter the following fields in the header: - - unsigned long base_ptr; /* base address for real-mode segment */ - - if ( setup_sects == 0 ) { - setup_sects = 4; - } - - if ( protocol >= 0x0200 ) { - type_of_loader = ; - if ( loading_initrd ) { - ramdisk_image = ; - ramdisk_size = ; - } - - if ( protocol >= 0x0202 && loadflags & 0x01 ) - heap_end = 0xe000; - else - heap_end = 0x9800; - - if ( protocol >= 0x0201 ) { - heap_end_ptr = heap_end - 0x200; - loadflags |= 0x80; /* CAN_USE_HEAP */ - } - - if ( protocol >= 0x0202 ) { - cmd_line_ptr = base_ptr + heap_end; - strcpy(cmd_line_ptr, cmdline); - } else { - cmd_line_magic = 0xA33F; - cmd_line_offset = heap_end; - setup_move_size = heap_end + strlen(cmdline)+1; - strcpy(base_ptr+cmd_line_offset, cmdline); - } - } else { - /* Very old kernel */ - - heap_end = 0x9800; - - cmd_line_magic = 0xA33F; - cmd_line_offset = heap_end; - - /* A very old kernel MUST have its real-mode code - loaded at 0x90000 */ - - if ( base_ptr != 0x90000 ) { - /* Copy the real-mode kernel */ - memcpy(0x90000, base_ptr, (setup_sects+1)*512); - base_ptr = 0x90000; /* Relocated */ - } - - strcpy(0x90000+cmd_line_offset, cmdline); - - /* It is recommended to clear memory up to the 32K mark */ - memset(0x90000 + (setup_sects+1)*512, 0, - (64-(setup_sects+1))*512); - } - - -**** LOADING THE REST OF THE KERNEL - -The 32-bit (non-real-mode) kernel starts at offset (setup_sects+1)*512 -in the kernel file (again, if setup_sects == 0 the real value is 4.) -It should be loaded at address 0x10000 for Image/zImage kernels and -0x100000 for bzImage kernels. - -The kernel is a bzImage kernel if the protocol >= 2.00 and the 0x01 -bit (LOAD_HIGH) in the loadflags field is set: - - is_bzImage = (protocol >= 0x0200) && (loadflags & 0x01); - load_address = is_bzImage ? 0x100000 : 0x10000; - -Note that Image/zImage kernels can be up to 512K in size, and thus use -the entire 0x10000-0x90000 range of memory. This means it is pretty -much a requirement for these kernels to load the real-mode part at -0x90000. bzImage kernels allow much more flexibility. - - -**** SPECIAL COMMAND LINE OPTIONS - -If the command line provided by the boot loader is entered by the -user, the user may expect the following command line options to work. -They should normally not be deleted from the kernel command line even -though not all of them are actually meaningful to the kernel. Boot -loader authors who need additional command line options for the boot -loader itself should get them registered in -Documentation/kernel-parameters.txt to make sure they will not -conflict with actual kernel options now or in the future. - - vga= - here is either an integer (in C notation, either - decimal, octal, or hexadecimal) or one of the strings - "normal" (meaning 0xFFFF), "ext" (meaning 0xFFFE) or "ask" - (meaning 0xFFFD). This value should be entered into the - vid_mode field, as it is used by the kernel before the command - line is parsed. - - mem= - is an integer in C notation optionally followed by - (case insensitive) K, M, G, T, P or E (meaning << 10, << 20, - << 30, << 40, << 50 or << 60). This specifies the end of - memory to the kernel. This affects the possible placement of - an initrd, since an initrd should be placed near end of - memory. Note that this is an option to *both* the kernel and - the bootloader! - - initrd= - An initrd should be loaded. The meaning of is - obviously bootloader-dependent, and some boot loaders - (e.g. LILO) do not have such a command. - -In addition, some boot loaders add the following options to the -user-specified command line: - - BOOT_IMAGE= - The boot image which was loaded. Again, the meaning of - is obviously bootloader-dependent. - - auto - The kernel was booted without explicit user intervention. - -If these options are added by the boot loader, it is highly -recommended that they are located *first*, before the user-specified -or configuration-specified command line. Otherwise, "init=/bin/sh" -gets confused by the "auto" option. - - -**** RUNNING THE KERNEL - -The kernel is started by jumping to the kernel entry point, which is -located at *segment* offset 0x20 from the start of the real mode -kernel. This means that if you loaded your real-mode kernel code at -0x90000, the kernel entry point is 9020:0000. - -At entry, ds = es = ss should point to the start of the real-mode -kernel code (0x9000 if the code is loaded at 0x90000), sp should be -set up properly, normally pointing to the top of the heap, and -interrupts should be disabled. Furthermore, to guard against bugs in -the kernel, it is recommended that the boot loader sets fs = gs = ds = -es = ss. - -In our example from above, we would do: - - /* Note: in the case of the "old" kernel protocol, base_ptr must - be == 0x90000 at this point; see the previous sample code */ - - seg = base_ptr >> 4; - - cli(); /* Enter with interrupts disabled! */ - - /* Set up the real-mode kernel stack */ - _SS = seg; - _SP = heap_end; - - _DS = _ES = _FS = _GS = seg; - jmp_far(seg+0x20, 0); /* Run the kernel */ - -If your boot sector accesses a floppy drive, it is recommended to -switch off the floppy motor before running the kernel, since the -kernel boot leaves interrupts off and thus the motor will not be -switched off, especially if the loaded kernel has the floppy driver as -a demand-loaded module! - - -**** ADVANCED BOOT LOADER HOOKS - -If the boot loader runs in a particularly hostile environment (such as -LOADLIN, which runs under DOS) it may be impossible to follow the -standard memory location requirements. Such a boot loader may use the -following hooks that, if set, are invoked by the kernel at the -appropriate time. The use of these hooks should probably be -considered an absolutely last resort! - -IMPORTANT: All the hooks are required to preserve %esp, %ebp, %esi and -%edi across invocation. - - realmode_swtch: - A 16-bit real mode far subroutine invoked immediately before - entering protected mode. The default routine disables NMI, so - your routine should probably do so, too. - - code32_start: - A 32-bit flat-mode routine *jumped* to immediately after the - transition to protected mode, but before the kernel is - uncompressed. No segments, except CS, are guaranteed to be - set up (current kernels do, but older ones do not); you should - set them up to BOOT_DS (0x18) yourself. - - After completing your hook, you should jump to the address - that was in this field before your boot loader overwrote it - (relocated, if appropriate.) - - -**** 32-bit BOOT PROTOCOL - -For machine with some new BIOS other than legacy BIOS, such as EFI, -LinuxBIOS, etc, and kexec, the 16-bit real mode setup code in kernel -based on legacy BIOS can not be used, so a 32-bit boot protocol needs -to be defined. - -In 32-bit boot protocol, the first step in loading a Linux kernel -should be to setup the boot parameters (struct boot_params, -traditionally known as "zero page"). The memory for struct boot_params -should be allocated and initialized to all zero. Then the setup header -from offset 0x01f1 of kernel image on should be loaded into struct -boot_params and examined. The end of setup header can be calculated as -follow: - - 0x0202 + byte value at offset 0x0201 - -In addition to read/modify/write the setup header of the struct -boot_params as that of 16-bit boot protocol, the boot loader should -also fill the additional fields of the struct boot_params as that -described in zero-page.txt. - -After setupping the struct boot_params, the boot loader can load the -32/64-bit kernel in the same way as that of 16-bit boot protocol. - -In 32-bit boot protocol, the kernel is started by jumping to the -32-bit kernel entry point, which is the start address of loaded -32/64-bit kernel. - -At entry, the CPU must be in 32-bit protected mode with paging -disabled; a GDT must be loaded with the descriptors for selectors -__BOOT_CS(0x10) and __BOOT_DS(0x18); both descriptors must be 4G flat -segment; __BOOS_CS must have execute/read permission, and __BOOT_DS -must have read/write permission; CS must be __BOOT_CS and DS, ES, SS -must be __BOOT_DS; interrupt must be disabled; %esi must hold the base -address of the struct boot_params; %ebp, %edi and %ebx must be zero. diff --git a/Documentation/x86/i386/usb-legacy-support.txt b/Documentation/x86/i386/usb-legacy-support.txt deleted file mode 100644 index 1894cdf..0000000 --- a/Documentation/x86/i386/usb-legacy-support.txt +++ /dev/null @@ -1,44 +0,0 @@ -USB Legacy support -~~~~~~~~~~~~~~~~~~ - -Vojtech Pavlik , January 2004 - - -Also known as "USB Keyboard" or "USB Mouse support" in the BIOS Setup is a -feature that allows one to use the USB mouse and keyboard as if they were -their classic PS/2 counterparts. This means one can use an USB keyboard to -type in LILO for example. - -It has several drawbacks, though: - -1) On some machines, the emulated PS/2 mouse takes over even when no USB - mouse is present and a real PS/2 mouse is present. In that case the extra - features (wheel, extra buttons, touchpad mode) of the real PS/2 mouse may - not be available. - -2) If CONFIG_HIGHMEM64G is enabled, the PS/2 mouse emulation can cause - system crashes, because the SMM BIOS is not expecting to be in PAE mode. - The Intel E7505 is a typical machine where this happens. - -3) If AMD64 64-bit mode is enabled, again system crashes often happen, - because the SMM BIOS isn't expecting the CPU to be in 64-bit mode. The - BIOS manufacturers only test with Windows, and Windows doesn't do 64-bit - yet. - -Solutions: - -Problem 1) can be solved by loading the USB drivers prior to loading the -PS/2 mouse driver. Since the PS/2 mouse driver is in 2.6 compiled into -the kernel unconditionally, this means the USB drivers need to be -compiled-in, too. - -Problem 2) can currently only be solved by either disabling HIGHMEM64G -in the kernel config or USB Legacy support in the BIOS. A BIOS update -could help, but so far no such update exists. - -Problem 3) is usually fixed by a BIOS update. Check the board -manufacturers web site. If an update is not available, disable USB -Legacy support in the BIOS. If this alone doesn't help, try also adding -idle=poll on the kernel command line. The BIOS may be entering the SMM -on the HLT instruction as well. - diff --git a/Documentation/x86/i386/zero-page.txt b/Documentation/x86/i386/zero-page.txt deleted file mode 100644 index 169ad42..0000000 --- a/Documentation/x86/i386/zero-page.txt +++ /dev/null @@ -1,31 +0,0 @@ -The additional fields in struct boot_params as a part of 32-bit boot -protocol of kernel. These should be filled by bootloader or 16-bit -real-mode setup code of the kernel. References/settings to it mainly -are in: - - include/asm-x86/bootparam.h - - -Offset Proto Name Meaning -/Size - -000/040 ALL screen_info Text mode or frame buffer information - (struct screen_info) -040/014 ALL apm_bios_info APM BIOS information (struct apm_bios_info) -060/010 ALL ist_info Intel SpeedStep (IST) BIOS support information - (struct ist_info) -080/010 ALL hd0_info hd0 disk parameter, OBSOLETE!! -090/010 ALL hd1_info hd1 disk parameter, OBSOLETE!! -0A0/010 ALL sys_desc_table System description table (struct sys_desc_table) -140/080 ALL edid_info Video mode setup (struct edid_info) -1C0/020 ALL efi_info EFI 32 information (struct efi_info) -1E0/004 ALL alk_mem_k Alternative mem check, in KB -1E4/004 ALL scratch Scratch field for the kernel setup code -1E8/001 ALL e820_entries Number of entries in e820_map (below) -1E9/001 ALL eddbuf_entries Number of entries in eddbuf (below) -1EA/001 ALL edd_mbr_sig_buf_entries Number of entries in edd_mbr_sig_buffer - (below) -290/040 ALL edd_mbr_sig_buffer EDD MBR signatures -2D0/A00 ALL e820_map E820 memory map table - (array of struct e820entry) -D00/1EC ALL eddbuf EDD data (array of struct edd_info) diff --git a/Documentation/x86/mtrr.txt b/Documentation/x86/mtrr.txt new file mode 100644 index 0000000..cc071dc --- /dev/null +++ b/Documentation/x86/mtrr.txt @@ -0,0 +1,305 @@ +MTRR (Memory Type Range Register) control +3 Jun 1999 +Richard Gooch + + + On Intel P6 family processors (Pentium Pro, Pentium II and later) + the Memory Type Range Registers (MTRRs) may be used to control + processor access to memory ranges. This is most useful when you have + a video (VGA) card on a PCI or AGP bus. Enabling write-combining + allows bus write transfers to be combined into a larger transfer + before bursting over the PCI/AGP bus. This can increase performance + of image write operations 2.5 times or more. + + The Cyrix 6x86, 6x86MX and M II processors have Address Range + Registers (ARRs) which provide a similar functionality to MTRRs. For + these, the ARRs are used to emulate the MTRRs. + + The AMD K6-2 (stepping 8 and above) and K6-3 processors have two + MTRRs. These are supported. The AMD Athlon family provide 8 Intel + style MTRRs. + + The Centaur C6 (WinChip) has 8 MCRs, allowing write-combining. These + are supported. + + The VIA Cyrix III and VIA C3 CPUs offer 8 Intel style MTRRs. + + The CONFIG_MTRR option creates a /proc/mtrr file which may be used + to manipulate your MTRRs. Typically the X server should use + this. This should have a reasonably generic interface so that + similar control registers on other processors can be easily + supported. + + +There are two interfaces to /proc/mtrr: one is an ASCII interface +which allows you to read and write. The other is an ioctl() +interface. The ASCII interface is meant for administration. The +ioctl() interface is meant for C programs (i.e. the X server). The +interfaces are described below, with sample commands and C code. + +=============================================================================== +Reading MTRRs from the shell: + +% cat /proc/mtrr +reg00: base=0x00000000 ( 0MB), size= 128MB: write-back, count=1 +reg01: base=0x08000000 ( 128MB), size= 64MB: write-back, count=1 +=============================================================================== +Creating MTRRs from the C-shell: +# echo "base=0xf8000000 size=0x400000 type=write-combining" >! /proc/mtrr +or if you use bash: +# echo "base=0xf8000000 size=0x400000 type=write-combining" >| /proc/mtrr + +And the result thereof: +% cat /proc/mtrr +reg00: base=0x00000000 ( 0MB), size= 128MB: write-back, count=1 +reg01: base=0x08000000 ( 128MB), size= 64MB: write-back, count=1 +reg02: base=0xf8000000 (3968MB), size= 4MB: write-combining, count=1 + +This is for video RAM at base address 0xf8000000 and size 4 megabytes. To +find out your base address, you need to look at the output of your X +server, which tells you where the linear framebuffer address is. A +typical line that you may get is: + +(--) S3: PCI: 968 rev 0, Linear FB @ 0xf8000000 + +Note that you should only use the value from the X server, as it may +move the framebuffer base address, so the only value you can trust is +that reported by the X server. + +To find out the size of your framebuffer (what, you don't actually +know?), the following line will tell you: + +(--) S3: videoram: 4096k + +That's 4 megabytes, which is 0x400000 bytes (in hexadecimal). +A patch is being written for XFree86 which will make this automatic: +in other words the X server will manipulate /proc/mtrr using the +ioctl() interface, so users won't have to do anything. If you use a +commercial X server, lobby your vendor to add support for MTRRs. +=============================================================================== +Creating overlapping MTRRs: + +%echo "base=0xfb000000 size=0x1000000 type=write-combining" >/proc/mtrr +%echo "base=0xfb000000 size=0x1000 type=uncachable" >/proc/mtrr + +And the results: cat /proc/mtrr +reg00: base=0x00000000 ( 0MB), size= 64MB: write-back, count=1 +reg01: base=0xfb000000 (4016MB), size= 16MB: write-combining, count=1 +reg02: base=0xfb000000 (4016MB), size= 4kB: uncachable, count=1 + +Some cards (especially Voodoo Graphics boards) need this 4 kB area +excluded from the beginning of the region because it is used for +registers. + +NOTE: You can only create type=uncachable region, if the first +region that you created is type=write-combining. +=============================================================================== +Removing MTRRs from the C-shell: +% echo "disable=2" >! /proc/mtrr +or using bash: +% echo "disable=2" >| /proc/mtrr +=============================================================================== +Reading MTRRs from a C program using ioctl()'s: + +/* mtrr-show.c + + Source file for mtrr-show (example program to show MTRRs using ioctl()'s) + + Copyright (C) 1997-1998 Richard Gooch + + This program is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program; if not, write to the Free Software + Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + + Richard Gooch may be reached by email at rgooch@atnf.csiro.au + The postal address is: + Richard Gooch, c/o ATNF, P. O. Box 76, Epping, N.S.W., 2121, Australia. +*/ + +/* + This program will use an ioctl() on /proc/mtrr to show the current MTRR + settings. This is an alternative to reading /proc/mtrr. + + + Written by Richard Gooch 17-DEC-1997 + + Last updated by Richard Gooch 2-MAY-1998 + + +*/ +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#define TRUE 1 +#define FALSE 0 +#define ERRSTRING strerror (errno) + +static char *mtrr_strings[MTRR_NUM_TYPES] = +{ + "uncachable", /* 0 */ + "write-combining", /* 1 */ + "?", /* 2 */ + "?", /* 3 */ + "write-through", /* 4 */ + "write-protect", /* 5 */ + "write-back", /* 6 */ +}; + +int main () +{ + int fd; + struct mtrr_gentry gentry; + + if ( ( fd = open ("/proc/mtrr", O_RDONLY, 0) ) == -1 ) + { + if (errno == ENOENT) + { + fputs ("/proc/mtrr not found: not supported or you don't have a PPro?\n", + stderr); + exit (1); + } + fprintf (stderr, "Error opening /proc/mtrr\t%s\n", ERRSTRING); + exit (2); + } + for (gentry.regnum = 0; ioctl (fd, MTRRIOC_GET_ENTRY, &gentry) == 0; + ++gentry.regnum) + { + if (gentry.size < 1) + { + fprintf (stderr, "Register: %u disabled\n", gentry.regnum); + continue; + } + fprintf (stderr, "Register: %u base: 0x%lx size: 0x%lx type: %s\n", + gentry.regnum, gentry.base, gentry.size, + mtrr_strings[gentry.type]); + } + if (errno == EINVAL) exit (0); + fprintf (stderr, "Error doing ioctl(2) on /dev/mtrr\t%s\n", ERRSTRING); + exit (3); +} /* End Function main */ +=============================================================================== +Creating MTRRs from a C programme using ioctl()'s: + +/* mtrr-add.c + + Source file for mtrr-add (example programme to add an MTRRs using ioctl()) + + Copyright (C) 1997-1998 Richard Gooch + + This program is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program; if not, write to the Free Software + Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + + Richard Gooch may be reached by email at rgooch@atnf.csiro.au + The postal address is: + Richard Gooch, c/o ATNF, P. O. Box 76, Epping, N.S.W., 2121, Australia. +*/ + +/* + This programme will use an ioctl() on /proc/mtrr to add an entry. The first + available mtrr is used. This is an alternative to writing /proc/mtrr. + + + Written by Richard Gooch 17-DEC-1997 + + Last updated by Richard Gooch 2-MAY-1998 + + +*/ +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#define TRUE 1 +#define FALSE 0 +#define ERRSTRING strerror (errno) + +static char *mtrr_strings[MTRR_NUM_TYPES] = +{ + "uncachable", /* 0 */ + "write-combining", /* 1 */ + "?", /* 2 */ + "?", /* 3 */ + "write-through", /* 4 */ + "write-protect", /* 5 */ + "write-back", /* 6 */ +}; + +int main (int argc, char **argv) +{ + int fd; + struct mtrr_sentry sentry; + + if (argc != 4) + { + fprintf (stderr, "Usage:\tmtrr-add base size type\n"); + exit (1); + } + sentry.base = strtoul (argv[1], NULL, 0); + sentry.size = strtoul (argv[2], NULL, 0); + for (sentry.type = 0; sentry.type < MTRR_NUM_TYPES; ++sentry.type) + { + if (strcmp (argv[3], mtrr_strings[sentry.type]) == 0) break; + } + if (sentry.type >= MTRR_NUM_TYPES) + { + fprintf (stderr, "Illegal type: \"%s\"\n", argv[3]); + exit (2); + } + if ( ( fd = open ("/proc/mtrr", O_WRONLY, 0) ) == -1 ) + { + if (errno == ENOENT) + { + fputs ("/proc/mtrr not found: not supported or you don't have a PPro?\n", + stderr); + exit (3); + } + fprintf (stderr, "Error opening /proc/mtrr\t%s\n", ERRSTRING); + exit (4); + } + if (ioctl (fd, MTRRIOC_ADD_ENTRY, &sentry) == -1) + { + fprintf (stderr, "Error doing ioctl(2) on /dev/mtrr\t%s\n", ERRSTRING); + exit (5); + } + fprintf (stderr, "Sleeping for 5 seconds so you can see the new entry\n"); + sleep (5); + close (fd); + fputs ("I've just closed /proc/mtrr so now the new entry should be gone\n", + stderr); +} /* End Function main */ +=============================================================================== diff --git a/Documentation/x86/pat.txt b/Documentation/x86/pat.txt index 17965f9..c93ff5f 100644 --- a/Documentation/x86/pat.txt +++ b/Documentation/x86/pat.txt @@ -14,6 +14,10 @@ PAT allows for different types of memory attributes. The most commonly used ones that will be supported at this time are Write-back, Uncached, Write-combined and Uncached Minus. + +PAT APIs +-------- + There are many different APIs in the kernel that allows setting of memory attributes at the page level. In order to avoid aliasing, these interfaces should be used thoughtfully. Below is a table of interfaces available, @@ -26,38 +30,38 @@ address range to avoid any aliasing. API | RAM | ACPI,... | Reserved/Holes | -----------------------|----------|------------|------------------| | | | | -ioremap | -- | UC | UC | +ioremap | -- | UC- | UC- | | | | | ioremap_cache | -- | WB | WB | | | | | -ioremap_nocache | -- | UC | UC | +ioremap_nocache | -- | UC- | UC- | | | | | ioremap_wc | -- | -- | WC | | | | | -set_memory_uc | UC | -- | -- | +set_memory_uc | UC- | -- | -- | set_memory_wb | | | | | | | | set_memory_wc | WC | -- | -- | set_memory_wb | | | | | | | | -pci sysfs resource | -- | -- | UC | +pci sysfs resource | -- | -- | UC- | | | | | pci sysfs resource_wc | -- | -- | WC | is IORESOURCE_PREFETCH| | | | | | | | -pci proc | -- | -- | UC | +pci proc | -- | -- | UC- | !PCIIOC_WRITE_COMBINE | | | | | | | | pci proc | -- | -- | WC | PCIIOC_WRITE_COMBINE | | | | | | | | -/dev/mem | -- | UC | UC | +/dev/mem | -- | WB/WC/UC- | WB/WC/UC- | read-write | | | | | | | | -/dev/mem | -- | UC | UC | +/dev/mem | -- | UC- | UC- | mmap SYNC flag | | | | | | | | -/dev/mem | -- | WB/WC/UC | WB/WC/UC | +/dev/mem | -- | WB/WC/UC- | WB/WC/UC- | mmap !SYNC flag | |(from exist-| (from exist- | and | | ing alias)| ing alias) | any alias to this area| | | | @@ -68,7 +72,7 @@ pci proc | -- | -- | WC | and | | | | MTRR says WB | | | | | | | | -/dev/mem | -- | -- | UC_MINUS | +/dev/mem | -- | -- | UC- | mmap !SYNC flag | | | | no alias to this area | | | | and | | | | @@ -98,3 +102,35 @@ types. Drivers should use set_memory_[uc|wc] to set access type for RAM ranges. + +PAT debugging +------------- + +With CONFIG_DEBUG_FS enabled, PAT memtype list can be examined by + +# mount -t debugfs debugfs /sys/kernel/debug +# cat /sys/kernel/debug/x86/pat_memtype_list +PAT memtype list: +uncached-minus @ 0x7fadf000-0x7fae0000 +uncached-minus @ 0x7fb19000-0x7fb1a000 +uncached-minus @ 0x7fb1a000-0x7fb1b000 +uncached-minus @ 0x7fb1b000-0x7fb1c000 +uncached-minus @ 0x7fb1c000-0x7fb1d000 +uncached-minus @ 0x7fb1d000-0x7fb1e000 +uncached-minus @ 0x7fb1e000-0x7fb25000 +uncached-minus @ 0x7fb25000-0x7fb26000 +uncached-minus @ 0x7fb26000-0x7fb27000 +uncached-minus @ 0x7fb27000-0x7fb28000 +uncached-minus @ 0x7fb28000-0x7fb2e000 +uncached-minus @ 0x7fb2e000-0x7fb2f000 +uncached-minus @ 0x7fb2f000-0x7fb30000 +uncached-minus @ 0x7fb31000-0x7fb32000 +uncached-minus @ 0x80000000-0x90000000 + +This list shows physical address ranges and various PAT settings used to +access those physical address ranges. + +Another, more verbose way of getting PAT related debug messages is with +"debugpat" boot parameter. With this parameter, various debug messages are +printed to dmesg log. + diff --git a/Documentation/x86/usb-legacy-support.txt b/Documentation/x86/usb-legacy-support.txt new file mode 100644 index 0000000..1894cdf --- /dev/null +++ b/Documentation/x86/usb-legacy-support.txt @@ -0,0 +1,44 @@ +USB Legacy support +~~~~~~~~~~~~~~~~~~ + +Vojtech Pavlik , January 2004 + + +Also known as "USB Keyboard" or "USB Mouse support" in the BIOS Setup is a +feature that allows one to use the USB mouse and keyboard as if they were +their classic PS/2 counterparts. This means one can use an USB keyboard to +type in LILO for example. + +It has several drawbacks, though: + +1) On some machines, the emulated PS/2 mouse takes over even when no USB + mouse is present and a real PS/2 mouse is present. In that case the extra + features (wheel, extra buttons, touchpad mode) of the real PS/2 mouse may + not be available. + +2) If CONFIG_HIGHMEM64G is enabled, the PS/2 mouse emulation can cause + system crashes, because the SMM BIOS is not expecting to be in PAE mode. + The Intel E7505 is a typical machine where this happens. + +3) If AMD64 64-bit mode is enabled, again system crashes often happen, + because the SMM BIOS isn't expecting the CPU to be in 64-bit mode. The + BIOS manufacturers only test with Windows, and Windows doesn't do 64-bit + yet. + +Solutions: + +Problem 1) can be solved by loading the USB drivers prior to loading the +PS/2 mouse driver. Since the PS/2 mouse driver is in 2.6 compiled into +the kernel unconditionally, this means the USB drivers need to be +compiled-in, too. + +Problem 2) can currently only be solved by either disabling HIGHMEM64G +in the kernel config or USB Legacy support in the BIOS. A BIOS update +could help, but so far no such update exists. + +Problem 3) is usually fixed by a BIOS update. Check the board +manufacturers web site. If an update is not available, disable USB +Legacy support in the BIOS. If this alone doesn't help, try also adding +idle=poll on the kernel command line. The BIOS may be entering the SMM +on the HLT instruction as well. + diff --git a/Documentation/x86/zero-page.txt b/Documentation/x86/zero-page.txt new file mode 100644 index 0000000..169ad42 --- /dev/null +++ b/Documentation/x86/zero-page.txt @@ -0,0 +1,31 @@ +The additional fields in struct boot_params as a part of 32-bit boot +protocol of kernel. These should be filled by bootloader or 16-bit +real-mode setup code of the kernel. References/settings to it mainly +are in: + + include/asm-x86/bootparam.h + + +Offset Proto Name Meaning +/Size + +000/040 ALL screen_info Text mode or frame buffer information + (struct screen_info) +040/014 ALL apm_bios_info APM BIOS information (struct apm_bios_info) +060/010 ALL ist_info Intel SpeedStep (IST) BIOS support information + (struct ist_info) +080/010 ALL hd0_info hd0 disk parameter, OBSOLETE!! +090/010 ALL hd1_info hd1 disk parameter, OBSOLETE!! +0A0/010 ALL sys_desc_table System description table (struct sys_desc_table) +140/080 ALL edid_info Video mode setup (struct edid_info) +1C0/020 ALL efi_info EFI 32 information (struct efi_info) +1E0/004 ALL alk_mem_k Alternative mem check, in KB +1E4/004 ALL scratch Scratch field for the kernel setup code +1E8/001 ALL e820_entries Number of entries in e820_map (below) +1E9/001 ALL eddbuf_entries Number of entries in eddbuf (below) +1EA/001 ALL edd_mbr_sig_buf_entries Number of entries in edd_mbr_sig_buffer + (below) +290/040 ALL edd_mbr_sig_buffer EDD MBR signatures +2D0/A00 ALL e820_map E820 memory map table + (array of struct e820entry) +D00/1EC ALL eddbuf EDD data (array of struct edd_info) diff --git a/Documentation/zh_CN/SubmittingPatches b/Documentation/zh_CN/SubmittingPatches index 985c92e..a3a4697 100644 --- a/Documentation/zh_CN/SubmittingPatches +++ b/Documentation/zh_CN/SubmittingPatches @@ -152,7 +152,7 @@ MAITAINERS 文件里的)å‘é€ä¸€ä¸ªæ‰‹å†Œé¡µï¼ˆman-pages)补ä¸ï¼Œæˆ–者至 å³ä½¿åœ¨ç¬¬å››æ­¥çš„时候,维护者没有作出回应,也è¦ç¡®è®¤åœ¨ä¿®æ”¹ä»–们的代ç çš„时候 ,一直将维护者拷è´åˆ°CC列表中。 -对于å°çš„è¡¥ä¸ï¼Œä½ ä¹Ÿè®¸ä¼šCC到 Adrian Bunk 管ç†çš„æœé›†ç碎补ä¸çš„邮件列表 +对于å°çš„è¡¥ä¸ï¼Œä½ ä¹Ÿè®¸ä¼šCC到 Jesper Juhl 管ç†çš„æœé›†ç碎补ä¸çš„邮件列表 (Trivial Patch Monkey)trivial@kernel.org,那里专门收集ç碎的补ä¸ã€‚下é¢è¿™æ · çš„è¡¥ä¸ä¼šè¢«çœ‹ä½œâ€œç碎的â€è¡¥ä¸ï¼š 文档的拼写修正。 @@ -166,7 +166,7 @@ MAITAINERS 文件里的)å‘é€ä¸€ä¸ªæ‰‹å†Œé¡µï¼ˆman-pages)补ä¸ï¼Œæˆ–者至 人拷è´ï¼Œåªè¦å®ƒæ˜¯ç碎的) 任何文件的作者/维护者对该文件的改动(例如 patch monkey 在é‡ä¼ æ¨¡å¼ä¸‹ï¼‰ -URL: +URL: (译注,关于“ç碎补ä¸â€çš„一些说明:因为原文的这一部分写得比较简å•ï¼Œæ‰€ä»¥ä¸å¾—ä¸ è¿ä¾‹å†™ä¸€ä¸‹è¯‘注。"trivial"这个英文å•è¯çš„本æ„是“ç碎的,ä¸é‡è¦çš„。â€ä½†æ˜¯åœ¨è¿™é‡Œ diff --git a/MAINTAINERS b/MAINTAINERS index ced3c20..a2ffb38 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -390,6 +390,11 @@ M: joerg.roedel@amd.com L: iommu@lists.linux-foundation.org S: Supported +AMD MICROCODE UPDATE SUPPORT +P: Peter Oruba +M: peter.oruba@amd.com +S: Supported + AMS (Apple Motion Sensor) DRIVER P: Stelian Pop M: stelian@popies.net @@ -467,6 +472,12 @@ M: kernel@wantstofly.org L: linux-arm-kernel@lists.arm.linux.org.uk (subscribers-only) S: Maintained +ARM/AFEB9260 MACHINE SUPPORT +P: Sergey Lapin +M: slapin@ossfans.org +L: linux-arm-kernel@lists.arm.linux.org.uk (subscribers-only) +S: Maintained + ARM/AJECO 1ARM MACHINE SUPPORT P: Lennert Buytenhek M: kernel@wantstofly.org @@ -492,7 +503,7 @@ M: kernel@wantstofly.org L: linux-arm-kernel@lists.arm.linux.org.uk (subscribers-only) S: Maintained -ARM/COMPULAB CM-X270/EM-X270 MACHINE SUPPORT +ARM/COMPULAB CM-X270/EM-X270 and CM-X300 MACHINE SUPPORT P: Mike Rapoport M: mike@compulab.co.il L: linux-arm-kernel@lists.arm.linux.org.uk (subscribers-only) @@ -624,6 +635,12 @@ M: marek.vasut@gmail.com W: http://hackndev.com S: Maintained +ARM/PALMZ72 SUPPORT +P: Sergey Lapin +M: slapin@ossfans.org +W: http://hackndev.com +S: Maintained + ARM/PLEB SUPPORT P: Peter Chubb M: pleb@gelato.unsw.edu.au @@ -2455,6 +2472,20 @@ M: jason.wessel@windriver.com L: kgdb-bugreport@lists.sourceforge.net S: Maintained +KMEMCHECK +P: Vegard Nossum +M: vegardno@ifi.uio.no +P Pekka Enberg +M: penberg@cs.helsinki.fi +L: linux-kernel@vger.kernel.org +S: Maintained + +KMEMTRACE +P: Eduard - Gabriel Munteanu +M: eduard.munteanu@linux360.ro +L: linux-kernel@vger.kernel.org +S: Maintained + KPROBES P: Ananth N Mavinakayanahalli M: ananth@in.ibm.com @@ -3147,6 +3178,11 @@ M: olof@lixom.net L: i2c@lm-sensors.org S: Maintained +PANASONIC LAPTOP ACPI EXTRAS DRIVER +P: Harald Welte +M: laforge@gnumonks.org +S: Maintained + PARALLEL PORT SUPPORT L: linux-parport@lists.infradead.org (subscribers-only) S: Orphan @@ -3274,7 +3310,9 @@ S: Maintained PNP SUPPORT P: Adam Belay -M: ambx1@neo.rr.com +M: abelay@mit.edu +P: Bjorn Helgaas +M: bjorn.helgaas@hp.com S: Maintained PNXxxxx I2C DRIVER @@ -3827,6 +3865,8 @@ S: Maintained SOUND P: Jaroslav Kysela M: perex@perex.cz +P: Takashi Iwai +M: tiwai@suse.de L: alsa-devel@alsa-project.org (subscribers-only) S: Maintained diff --git a/Makefile b/Makefile index f448e00..b59250e 100644 --- a/Makefile +++ b/Makefile @@ -620,6 +620,7 @@ export mod_strip_cmd ifeq ($(KBUILD_EXTMOD),) core-y += kernel/ mm/ fs/ ipc/ security/ crypto/ block/ +core-$(CONFIG_KERNEL_TESTS) += tests/ vmlinux-dirs := $(patsubst %/,%,$(filter %/, $(init-y) $(init-m) \ $(core-y) $(core-m) $(drivers-y) $(drivers-m) \ diff --git a/Next/Trees b/Next/Trees new file mode 100644 index 0000000..b5fcc3e --- /dev/null +++ b/Next/Trees @@ -0,0 +1,117 @@ +Trees included into this release: + +Name Type URL +---- ---- --- +origin git git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux-2.6.git#master +powerpc-merge git git://git.kernel.org/pub/scm/linux/kernel/git/paulus/powerpc.git#merge +scsi-rc-fixes git git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi-rc-fixes-2.6.git#master +net-current git git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-2.6.git#master +sparc-current git git://git.kernel.org/pub/scm/linux/kernel/git/davem/sparc-2.6.git#master +sound-current git git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound-2.6.git#for-linus +arm-current git ssh://master.kernel.org/home/rmk/linux-2.6-arm.git#master +pci-current git git://git.kernel.org/pub/scm/linux/kernel/git/jbarnes/pci-2.6#for-linus +wireless-current git git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless-2.6.git#master +kbuild-current git git://git.kernel.org/pub/scm/linux/kernel/git/sam/kbuild-fixes.git#master +driver-core.current quilt http://kernel.org/pub/linux/kernel/people/gregkh/gregkh-2.6/gregkh-01-driver-core.current/ +usb.current quilt http://kernel.org/pub/linux/kernel/people/gregkh/gregkh-2.6/gregkh-02-usb.current/ +cpufreq-current git git://git.kernel.org/pub/scm/linux/kernel/git/davej/cpufreq.git#fixes +input-current git git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input.git#for-linus +md-current git git://neil.brown.name/md#for-2.6.26 +dwmw2 git git://git.infradead.org/users/dwmw2/random-2.6.git#master +arm git ssh://master.kernel.org/home/rmk/linux-2.6-arm.git#devel +avr32 git git://git.kernel.org/pub/scm/linux/kernel/git/hskinnemoen/avr32-2.6.git#avr32-arch +blackfin git git://git.kernel.org/pub/scm/linux/kernel/git/cooloney/blackfin-2.6.git#for-linus +cris git git://www.jni.nu/cris.git#for-next +ia64 git git://git.kernel.org/pub/scm/linux/kernel/git/aegl/linux-2.6.git#test +m68k quilt http://www.kernel.org/pub/linux/kernel/people/geert/linux-m68k-patches-2.6/ +m68knommu git git://git.kernel.org/pub/scm/linux/kernel/git/gerg/m68knommu.git#for-next +mips git git://git.linux-mips.org/pub/scm/upstream-sfr.git#mips-for-linux-next +parisc git git://git.kernel.org/pub/scm/linux/kernel/git/kyle/parisc-2.6.git#master +powerpc git git://git.kernel.org/pub/scm/linux/kernel/git/paulus/powerpc.git#powerpc-next +4xx git git://git.kernel.org/pub/scm/linux/kernel/git/jwboyer/powerpc-4xx.git#next +galak git git://git.kernel.org/pub/scm/linux/kernel/git/galak/powerpc.git#powerpc-next +s390 git git://git390.osdl.marist.edu/pub/scm/linux-2.6.git#features +sh git git://git.kernel.org/pub/scm/linux/kernel/git/lethal/sh-2.6.git#master +sparc git git://git.kernel.org/pub/scm/linux/kernel/git/davem/sparc-next-2.6.git#master +x86 git git://git.kernel.org/pub/scm/linux/kernel/git/x86/linux-2.6-tip.git#auto-x86-next +xtensa git git://git.kernel.org/pub/scm/linux/kernel/git/czankel/xtensa-next.git#master +driver-core quilt http://kernel.org/pub/linux/kernel/people/gregkh/gregkh-2.6/gregkh-03-driver-core/ +usb quilt http://kernel.org/pub/linux/kernel/people/gregkh/gregkh-2.6/gregkh-04-usb/ +tip-core git git://git.kernel.org/pub/scm/linux/kernel/git/x86/linux-2.6-tip.git#auto-core-next +cpus4096 git git://git.kernel.org/pub/scm/linux/kernel/git/x86/linux-2.6-tip.git#auto-cpus4096-next +ftrace git git://git.kernel.org/pub/scm/linux/kernel/git/x86/linux-2.6-tip.git#auto-ftrace-next +genirq git git://git.kernel.org/pub/scm/linux/kernel/git/x86/linux-2.6-tip.git#auto-genirq-next +safe-poison-pointers git git://git.kernel.org/pub/scm/linux/kernel/git/x86/linux-2.6-tip.git#auto-safe-poison-pointers-next +sched git git://git.kernel.org/pub/scm/linux/kernel/git/x86/linux-2.6-tip.git#auto-sched-next +stackprotector git git://git.kernel.org/pub/scm/linux/kernel/git/x86/linux-2.6-tip.git#auto-stackprotector-next +timers git git://git.kernel.org/pub/scm/linux/kernel/git/x86/linux-2.6-tip.git#auto-timers-next +pci git git://git.kernel.org/pub/scm/linux/kernel/git/jbarnes/pci-2.6#linux-next +device-mapper quilt http://www.kernel.org/pub/linux/kernel/people/agk/patches/2.6/editing/ +hid git git://git.kernel.org/pub/scm/linux/kernel/git/jikos/hid.git#mm +i2c quilt http://khali.linux-fr.org/devel/linux-2.6/jdelvare-i2c/ +jdelvare-hwmon quilt http://khali.linux-fr.org/devel/linux-2.6/jdelvare-hwmon/ +kernel-doc quilt http://oss.oracle.com/~rdunlap/kernel-doc-patches/current/ +v4l-dvb git git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-next.git#stable +jfs git git://git.kernel.org/pub/scm/linux/kernel/git/shaggy/jfs-2.6.git#next +kbuild git git://git.kernel.org/pub/scm/linux/kernel/git/sam/kbuild-next.git#master +ide quilt http://kernel.org/pub/linux/kernel/people/bart/pata-2.6/patches/ +libata git git://git.kernel.org/pub/scm/linux/kernel/git/jgarzik/libata-dev.git#NEXT +nfs git git://git.linux-nfs.org/projects/trondmy/nfs-2.6.git#linux-next +xfs git git://oss.sgi.com:8090/xfs/xfs-2.6.git#master +infiniband git git://git.kernel.org/pub/scm/linux/kernel/git/roland/infiniband.git#for-next +acpi git git://git.kernel.org/pub/scm/linux/kernel/git/ak/linux-acpi-2.6.git#test +nfsd git git://git.linux-nfs.org/~bfields/linux.git#nfsd-next +ieee1394 git git://git.kernel.org/pub/scm/linux/kernel/git/ieee1394/linux1394-2.6.git#for-next +ubi git git://git.infradead.org/~dedekind/ubi-2.6.git#linux-next +kvm git git://git.kernel.org/pub/scm/linux/kernel/git/avi/kvm.git#master +dlm git git://git.kernel.org/pub/scm/linux/kernel/git/teigland/dlm.git#next +scsi git git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi-misc-2.6.git#master +tests git git://git.kernel.org/pub/scm/linux/kernel/git/sam/test.git#master +ocfs2 git git://git.kernel.org/pub/scm/linux/kernel/git/mfasheh/ocfs2.git#linux-next +ext4 git git://git.kernel.org/pub/scm/linux/kernel/git/tytso/ext4.git#next +async_tx git git://git.kernel.org/pub/scm/linux/kernel/git/djbw/async_tx.git#next +udf git git://git.kernel.org/pub/scm/linux/kernel/git/jack/linux-udf-2.6.git#for_next +net git git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next-2.6.git#master +mtd git git://git.infradead.org/mtd-2.6.git#master +wireless git git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless-next-2.6.git#master +crypto git git://git.kernel.org/pub/scm/linux/kernel/git/herbert/cryptodev-2.6#master +vfs git git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs-2.6.git#for-next +sound git git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound-2.6.git#for-next +cpufreq git git://git.kernel.org/pub/scm/linux/kernel/git/davej/cpufreq.git#next +v9fs git git://git.kernel.org/pub/scm/linux/kernel/git/ericvh/v9fs.git#for-next +rr quilt http://ozlabs.org/~rusty/kernel/rr-latest/ +cifs git git://git.kernel.org/pub/scm/linux/kernel/git/sfrench/cifs-2.6.git#master +mmc git git://git.kernel.org/pub/scm/linux/kernel/git/drzeus/mmc.git#next +gfs2 git git://git.kernel.org/pub/scm/linux/kernel/git/steve/gfs2-2.6-nmw.git#master +input git git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input.git#next +semaphore git git://git.kernel.org/pub/scm/linux/kernel/git/willy/misc.git#semaphore +semaphore-removal git git://git.kernel.org/pub/scm/linux/kernel/git/willy/misc.git#semaphore-removal +bkl-removal git git://git.lwn.net/linux-2.6.git#bkl-removal +trivial git git://git.kernel.org/pub/scm/linux/kernel/git/juhl/trivial-2.6.git#next +ubifs git git://git.infradead.org/~dedekind/ubifs-2.6.git#linux-next +lsm git git://git.kernel.org/pub/scm/linux/kernel/git/chrisw/lsm-2.6.git#for-next +block git git://git.kernel.dk/linux-2.6-block.git#for-next +embedded git git://git.infradead.org/embedded-2.6.git#master +firmware git git://git.infradead.org/users/dwmw2/firmware-2.6.git#master +pcmcia git git://git.kernel.org/pub/scm/linux/kernel/git/brodo/pcmcia-2.6.git#master +battery git git://git.infradead.org/battery-2.6.git#master +leds git git://git.o-hand.com/linux-rpurdie-leds#for-mm +backlight git git://git.o-hand.com/linux-rpurdie-backlight#for-mm +kgdb git git://git.kernel.org/pub/scm/linux/kernel/git/jwessel/linux-2.6-kgdb#kgdb-next +slab git git://git.kernel.org/pub/scm/linux/kernel/git/penberg/slab-2.6.git#for-next +uclinux git git://git.kernel.org/pub/scm/linux/kernel/git/gerg/uclinux.git#for-next +md git git://neil.brown.name/md#for-next +kmemcheck git git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip.git#auto-kmemcheck-next +generic-ipi git git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip.git#auto-generic-ipi-next +mfd git git://git.o-hand.com/linux-mfd#for-next +hdlc git git://git.kernel.org/pub/scm/linux/kernel/git/chris/linux-2.6.git#hdlc-next +drm git git://git.kernel.org/pub/scm/linux/kernel/git/airlied/drm-2.6.git#drm-next +voltage git git://git.kernel.org/pub/scm/linux/kernel/git/lrg/voltage-2.6.git#reg-for-linus +security-testing git git://git.kernel.org/pub/scm/linux/kernel/git/jmorris/security-testing-2.6.git#next +lblnet git git://git.infradead.org/users/pcmoore/lblnet-2.6_next#master +ttydev quilt http://www.linux.org.uk/~alan/ttydev/ +agp git git://git.kernel.org/pub/scm/linux/kernel/git/airlied/agp-2.6.git#agp-next +creds git git://git.kernel.org/pub/scm/linux/kernel/git/jmorris/security-testing-2.6#next-creds +oprofile git git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip.git#auto-oprofile-next +fastboot git git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip.git#auto-fastboot-next +sparseirq git git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip.git#auto-sparseirq-next diff --git a/Next/merge.log b/Next/merge.log new file mode 100644 index 0000000..e2b29ff --- /dev/null +++ b/Next/merge.log @@ -0,0 +1,5839 @@ +$ git checkout master +Already on "master" +$ git reset --hard stable +HEAD is now at afa153f Merge git://git.kernel.org/pub/scm/linux/kernel/git/bart/ide-2.6 +Merging origin/master +$ git merge origin/master +Updating afa153f..ec0c15a +Fast forward + Documentation/ABI/testing/sysfs-firmware-sgi_uv | 27 +++ + Documentation/filesystems/ntfs.txt | 4 +- + Documentation/filesystems/proc.txt | 19 ++ + MAINTAINERS | 8 +- + arch/x86/kernel/tsc.c | 235 ++++++++++++++++++----- + drivers/char/random.c | 19 +- + drivers/firmware/iscsi_ibft.c | 3 +- + drivers/misc/acer-wmi.c | 3 +- + drivers/misc/hp-wmi.c | 91 +++++---- + drivers/mmc/host/at91_mci.c | 20 ++- + drivers/net/wireless/ath9k/hw.c | 8 +- + drivers/net/wireless/ath9k/main.c | 6 +- + drivers/net/wireless/ath9k/recv.c | 5 +- + drivers/net/wireless/iwlwifi/iwl-4965.c | 4 +- + drivers/net/wireless/iwlwifi/iwl-5000.c | 14 +- + drivers/net/wireless/iwlwifi/iwl-agn.c | 8 + + drivers/net/wireless/iwlwifi/iwl-fh.h | 1 + + drivers/net/wireless/iwlwifi/iwl-tx.c | 2 +- + drivers/net/wireless/libertas/if_cs.c | 13 +- + drivers/net/wireless/orinoco.c | 10 +- + drivers/net/wireless/rt2x00/rt2x00reg.h | 5 +- + drivers/rtc/rtc-cmos.c | 38 +++- + drivers/rtc/rtc-lib.c | 5 +- + drivers/serial/8250.c | 16 ++- + drivers/serial/8250.h | 1 + + drivers/video/cirrusfb.c | 59 ++---- + drivers/video/tdfxfb.c | 9 +- + fs/ntfs/usnjrnl.h | 4 +- + fs/proc/proc_misc.c | 7 +- + include/linux/Kbuild | 1 - + include/linux/mroute.h | 2 +- + include/linux/mroute6.h | 1 + + include/linux/pim.h | 18 -- + include/linux/quicklist.h | 7 + + kernel/exit.c | 78 ++++----- + kernel/pid_namespace.c | 3 - + kernel/pm_qos_params.c | 25 +-- + mm/filemap.c | 11 +- + mm/page_alloc.c | 9 +- + mm/quicklist.c | 9 +- + mm/truncate.c | 4 +- + net/ipv4/devinet.c | 15 ++- + net/ipv6/raw.c | 6 +- + net/mac80211/debugfs_key.c | 6 +- + net/mac80211/ieee80211_i.h | 4 +- + net/sched/cls_api.c | 2 +- + net/sched/cls_route.c | 2 +- + net/sched/sch_api.c | 8 +- + net/sched/sch_cbq.c | 2 +- + net/sched/sch_htb.c | 4 +- + net/sched/sch_netem.c | 2 +- + net/sched/sch_teql.c | 2 +- + net/wireless/Kconfig | 3 +- + net/xfrm/xfrm_policy.c | 6 +- + net/xfrm/xfrm_state.c | 32 +++- + security/device_cgroup.c | 18 +- + 56 files changed, 589 insertions(+), 335 deletions(-) + create mode 100644 Documentation/ABI/testing/sysfs-firmware-sgi_uv +Merging powerpc-merge/merge +$ git merge powerpc-merge/merge +Already up-to-date. +Merging scsi-rc-fixes/master +$ git merge scsi-rc-fixes/master +Merge made by recursive. + drivers/s390/scsi/zfcp_ccw.c | 6 +-- + drivers/s390/scsi/zfcp_fc.c | 33 ++++------- + drivers/s390/scsi/zfcp_fsf.c | 88 ++++++++++++++-------------- + drivers/s390/scsi/zfcp_qdio.c | 4 +- + drivers/scsi/Kconfig | 2 +- + drivers/scsi/device_handler/scsi_dh_alua.c | 12 ++-- + drivers/scsi/device_handler/scsi_dh_emc.c | 4 +- + drivers/scsi/device_handler/scsi_dh_rdac.c | 4 +- + drivers/scsi/scsi_error.c | 2 +- + drivers/scsi/scsi_scan.c | 3 +- + include/scsi/scsi.h | 14 +++++ + 11 files changed, 87 insertions(+), 85 deletions(-) +Merging net-current/master +$ git merge net-current/master +Merge made by recursive. + drivers/net/bnx2x.h | 5 +- + drivers/net/bnx2x_main.c | 34 ++++++------ + drivers/net/ixgbe/ixgbe_main.c | 6 ++ + drivers/net/netxen/netxen_nic_main.c | 10 ---- + drivers/net/pcmcia/axnet_cs.c | 1 + + drivers/net/pcmcia/pcnet_cs.c | 2 +- + drivers/net/usb/pegasus.c | 11 ++-- + drivers/net/wireless/ath9k/main.c | 12 ++++- + drivers/net/wireless/ath9k/xmit.c | 4 +- + drivers/net/wireless/iwlwifi/iwl-agn-rs.c | 3 +- + drivers/net/wireless/iwlwifi/iwl-agn.c | 27 ++++++----- + drivers/net/wireless/iwlwifi/iwl-core.c | 77 +++++++++++++++++------------ + drivers/net/wireless/iwlwifi/iwl-dev.h | 1 - + drivers/net/wireless/iwlwifi/iwl-rx.c | 5 ++- + drivers/net/wireless/iwlwifi/iwl-scan.c | 2 +- + drivers/net/wireless/iwlwifi/iwl-tx.c | 27 ++++++---- + net/tipc/bcast.c | 22 ++++---- + net/tipc/bcast.h | 22 ++++---- + net/tipc/bearer.c | 2 +- + net/tipc/bearer.h | 2 +- + net/tipc/cluster.c | 16 +++--- + net/tipc/cluster.h | 10 ++-- + net/tipc/discover.c | 2 +- + net/tipc/link.c | 26 +++++----- + net/tipc/link.h | 2 +- + net/tipc/name_table.h | 2 +- + net/tipc/net.c | 2 +- + net/tipc/net.h | 2 +- + net/tipc/node.c | 60 +++++++++++----------- + net/tipc/node.h | 42 ++++++++-------- + net/tipc/node_subscr.c | 4 +- + net/tipc/node_subscr.h | 10 ++-- + net/tipc/port.h | 2 +- + net/tipc/zone.c | 4 +- + net/tipc/zone.h | 2 +- + 35 files changed, 248 insertions(+), 213 deletions(-) +Merging sparc-current/master +$ git merge sparc-current/master +Already up-to-date. +Merging sound-current/for-linus +$ git merge sound-current/for-linus +Already up-to-date. +Merging arm-current/master +$ git merge arm-current/master +Merge made by recursive. + arch/arm/mach-omap1/mcbsp.c | 8 ++++---- + arch/arm/plat-omap/gpio.c | 2 +- + arch/arm/plat-omap/mcbsp.c | 4 ++-- + drivers/usb/host/ohci-omap.c | 2 +- + 4 files changed, 8 insertions(+), 8 deletions(-) +Merging pci-current/for-linus +$ git merge pci-current/for-linus +Already up-to-date. +Merging wireless-current/master +$ git merge wireless-current/master +Already up-to-date. +Merging kbuild-current/master +$ git merge kbuild-current/master +Already up-to-date. +Merging quilt/driver-core.current +$ git merge quilt/driver-core.current +Already up-to-date. +Merging quilt/usb.current +$ git merge quilt/usb.current +Merge made by recursive. + Documentation/ABI/stable/sysfs-driver-usb-usbtmc | 62 ++ + .../ABI/testing/sysfs-bus-usb-devices-usbsevseg | 43 + + Documentation/devices.txt | 3 + + Documentation/ioctl-number.txt | 2 + + Documentation/usb/anchors.txt | 12 + + Documentation/usb/misc_usbsevseg.txt | 46 + + drivers/usb/class/Kconfig | 10 + + drivers/usb/class/Makefile | 1 + + drivers/usb/class/usbtmc.c | 1087 ++++++++++++++++++++ + drivers/usb/core/hcd.c | 3 +- + drivers/usb/gadget/omap_udc.c | 4 +- + drivers/usb/host/ehci-hcd.c | 26 +- + drivers/usb/host/ehci-sched.c | 32 +- + drivers/usb/misc/Kconfig | 9 + + drivers/usb/misc/Makefile | 1 + + drivers/usb/misc/usbsevseg.c | 394 +++++++ + drivers/usb/musb/musb_core.c | 4 +- + drivers/usb/musb/omap2430.c | 4 +- + drivers/usb/musb/omap2430.h | 4 +- + drivers/usb/serial/sierra.c | 11 +- + drivers/usb/storage/Kconfig | 12 - + drivers/usb/storage/Makefile | 3 +- + drivers/usb/storage/unusual_devs.h | 16 +- + drivers/usb/storage/usb.c | 2 - + include/linux/usb/Kbuild | 2 +- + include/linux/usb/tmc.h | 43 + + 26 files changed, 1775 insertions(+), 61 deletions(-) + create mode 100644 Documentation/ABI/stable/sysfs-driver-usb-usbtmc + create mode 100644 Documentation/ABI/testing/sysfs-bus-usb-devices-usbsevseg + create mode 100644 Documentation/usb/misc_usbsevseg.txt + create mode 100644 drivers/usb/class/usbtmc.c + create mode 100644 drivers/usb/misc/usbsevseg.c + create mode 100644 include/linux/usb/tmc.h +Merging cpufreq-current/fixes +$ git merge cpufreq-current/fixes +Already up-to-date. +Merging input-current/for-linus +$ git merge input-current/for-linus +Auto-merged MAINTAINERS +Merge made by recursive. +Merging md-current/for-2.6.26 +$ git merge md-current/for-2.6.26 +Already up-to-date. +Merging dwmw2/master +$ git merge dwmw2/master +Removed arch/sparc/include/asm/statfs_32.h +Removed arch/sparc/include/asm/statfs_64.h +Merge made by recursive. + arch/alpha/include/asm/statfs.h | 4 ++ + arch/arm/include/asm/statfs.h | 34 +----------------- + arch/ia64/include/asm/statfs.h | 52 +++-------------------------- + arch/powerpc/include/asm/statfs.h | 54 ----------------------------- + arch/s390/include/asm/statfs.h | 11 ++---- + arch/sparc/include/asm/statfs.h | 8 ++--- + arch/sparc/include/asm/statfs_32.h | 6 --- + arch/sparc/include/asm/statfs_64.h | 54 ----------------------------- + arch/x86/kernel/early-quirks.c | 18 ++++++++++ + drivers/media/video/cafe_ccic.c | 13 ++----- + drivers/mmc/host/sdhci-pci.c | 2 +- + drivers/mtd/nand/cafe_nand.c | 6 +++- + fs/efs/super.c | 2 - + include/asm-generic/statfs.h | 65 ++++++++++++++++++++++++++--------- + include/asm-parisc/statfs.h | 55 +----------------------------- + include/asm-x86/statfs.h | 61 +++------------------------------- + include/linux/pci_ids.h | 4 ++- + 17 files changed, 103 insertions(+), 346 deletions(-) + delete mode 100644 arch/sparc/include/asm/statfs_32.h + delete mode 100644 arch/sparc/include/asm/statfs_64.h +$ git revert 1bc3029e516e62baa14318888985075f3f3a9f7e +Finished one revert. +Created commit 636b031: Revert "Blacklist DMAR on Intel G31/G33 chipsets" + 1 files changed, 0 insertions(+), 18 deletions(-) +Merging arm/devel +$ git merge arm/devel +Auto-merged MAINTAINERS +Auto-merged arch/arm/mach-omap1/mcbsp.c +Removed arch/arm/mach-pxa/e400_lcd.c +Removed arch/arm/mach-pxa/e740_lcd.c +Removed arch/arm/mach-pxa/eseries_udc.c +Auto-merged arch/arm/plat-omap/mcbsp.c +Auto-merged drivers/serial/8250.c +Auto-merged drivers/usb/host/ohci-omap.c +Removed drivers/video/am200epd.c +Merge made by recursive. + MAINTAINERS | 14 +- + arch/arm/Kconfig | 47 +- + arch/arm/boot/compressed/head.S | 1 + + arch/arm/configs/afeb9260_defconfig | 1259 ++++++++++++++++++++ + arch/arm/configs/cm_x300_defconfig | 1466 ++++++++++++++++++++++++ + arch/arm/configs/palmz72_defconfig | 951 +++++++++++++++ + arch/arm/include/asm/bug.h | 2 +- + arch/arm/include/asm/cacheflush.h | 90 -- + arch/arm/include/asm/cachetype.h | 96 ++ + arch/arm/include/asm/cputype.h | 64 + + arch/arm/include/asm/futex.h | 124 ++- + arch/arm/include/asm/kprobes.h | 1 - + arch/arm/include/asm/memory.h | 30 +- + arch/arm/include/asm/mmu_context.h | 1 + + arch/arm/include/asm/system.h | 58 - + arch/arm/include/asm/uaccess.h | 10 +- + arch/arm/kernel/debug.S | 5 + + arch/arm/kernel/entry-armv.S | 16 + + arch/arm/kernel/entry-common.S | 25 +- + arch/arm/kernel/head-common.S | 19 +- + arch/arm/kernel/head-nommu.S | 4 +- + arch/arm/kernel/head.S | 12 +- + arch/arm/kernel/kprobes-decode.c | 4 +- + arch/arm/kernel/kprobes.c | 5 +- + arch/arm/kernel/setup.c | 46 +- + arch/arm/kernel/traps.c | 12 - + arch/arm/lib/ashldi3.S | 2 + + arch/arm/lib/ashrdi3.S | 2 + + arch/arm/lib/backtrace.S | 4 + + arch/arm/lib/changebit.S | 2 + + arch/arm/lib/clear_user.S | 3 +- + arch/arm/lib/clearbit.S | 2 + + arch/arm/lib/copy_from_user.S | 2 + + arch/arm/lib/copy_page.S | 1 + + arch/arm/lib/copy_to_user.S | 2 + + arch/arm/lib/csumipv6.S | 1 + + arch/arm/lib/csumpartial.S | 1 + + arch/arm/lib/csumpartialcopy.S | 7 +- + arch/arm/lib/csumpartialcopygeneric.S | 1 + + arch/arm/lib/csumpartialcopyuser.S | 7 +- + arch/arm/lib/delay.S | 3 + + arch/arm/lib/div64.S | 1 + + arch/arm/lib/findbit.S | 8 + + arch/arm/lib/getuser.S | 14 +- + arch/arm/lib/io-readsb.S | 1 + + arch/arm/lib/io-readsl.S | 1 + + arch/arm/lib/io-readsw-armv4.S | 1 + + arch/arm/lib/io-writesb.S | 1 + + arch/arm/lib/io-writesl.S | 1 + + arch/arm/lib/io-writesw-armv4.S | 1 + + arch/arm/lib/lib1funcs.S | 11 + + arch/arm/lib/lshrdi3.S | 2 + + arch/arm/lib/memchr.S | 1 + + arch/arm/lib/memcpy.S | 1 + + arch/arm/lib/memmove.S | 1 + + arch/arm/lib/memset.S | 1 + + arch/arm/lib/memzero.S | 1 + + arch/arm/lib/muldi3.S | 2 + + arch/arm/lib/putuser.S | 18 +- + arch/arm/lib/setbit.S | 2 + + arch/arm/lib/sha1.S | 3 + + arch/arm/lib/strchr.S | 1 + + arch/arm/lib/strncpy_from_user.S | 1 + + arch/arm/lib/strnlen_user.S | 1 + + arch/arm/lib/strrchr.S | 1 + + arch/arm/lib/testchangebit.S | 2 + + arch/arm/lib/testclearbit.S | 2 + + arch/arm/lib/testsetbit.S | 2 + + arch/arm/lib/uaccess.S | 2 + + arch/arm/lib/ucmpdi2.S | 4 + + arch/arm/mach-at91/Kconfig | 9 + + arch/arm/mach-at91/Makefile | 1 + + arch/arm/mach-at91/board-afeb-9260v1.c | 210 ++++ + arch/arm/mach-footbridge/include/mach/memory.h | 10 - + arch/arm/mach-iop13xx/include/mach/memory.h | 3 - + arch/arm/mach-iop32x/iq31244.c | 4 +- + arch/arm/mach-ixp4xx/common-pci.c | 7 +- + arch/arm/mach-ixp4xx/include/mach/cpu.h | 9 +- + arch/arm/mach-omap1/mcbsp.c | 8 +- + arch/arm/mach-omap1/serial.c | 12 +- + arch/arm/mach-omap2/Makefile | 3 +- + arch/arm/mach-omap2/clock.c | 46 +- + arch/arm/mach-omap2/clock.h | 1 + + arch/arm/mach-omap2/clock24xx.h | 238 +++- + arch/arm/mach-omap2/clock34xx.c | 31 +- + arch/arm/mach-omap2/clock34xx.h | 248 ++++- + arch/arm/mach-omap2/clockdomain.c | 623 ++++++++++ + arch/arm/mach-omap2/clockdomains.h | 305 +++++ + arch/arm/mach-omap2/cm-regbits-24xx.h | 24 +- + arch/arm/mach-omap2/cm-regbits-34xx.h | 42 +- + arch/arm/mach-omap2/cm.h | 2 +- + arch/arm/mach-omap2/gpmc.c | 6 +- + arch/arm/mach-omap2/id.c | 7 +- + arch/arm/mach-omap2/io.c | 9 + + arch/arm/mach-omap2/irq.c | 4 +- + arch/arm/mach-omap2/powerdomain.c | 1113 ++++++++++++++++++ + arch/arm/mach-omap2/powerdomains.h | 187 +++ + arch/arm/mach-omap2/powerdomains24xx.h | 200 ++++ + arch/arm/mach-omap2/powerdomains34xx.h | 327 ++++++ + arch/arm/mach-omap2/prcm-common.h | 3 +- + arch/arm/mach-omap2/prm-regbits-24xx.h | 12 +- + arch/arm/mach-omap2/prm-regbits-34xx.h | 11 +- + arch/arm/mach-omap2/prm.h | 5 +- + arch/arm/mach-omap2/serial.c | 14 +- + arch/arm/mach-pxa/Kconfig | 73 ++- + arch/arm/mach-pxa/Makefile | 16 +- + arch/arm/mach-pxa/am200epd.c | 374 ++++++ + arch/arm/mach-pxa/cm-x300.c | 473 ++++++++ + arch/arm/mach-pxa/devices.h | 1 + + arch/arm/mach-pxa/e330.c | 43 + + arch/arm/mach-pxa/e350.c | 43 + + arch/arm/mach-pxa/e400.c | 94 ++ + arch/arm/mach-pxa/e400_lcd.c | 56 - + arch/arm/mach-pxa/e740.c | 169 +++ + arch/arm/mach-pxa/e740_lcd.c | 123 -- + arch/arm/mach-pxa/{e750_lcd.c => e750.c} | 67 +- + arch/arm/mach-pxa/{e800_lcd.c => e800.c} | 79 +- + arch/arm/mach-pxa/eseries.c | 157 +--- + arch/arm/mach-pxa/eseries.h | 4 + + arch/arm/mach-pxa/eseries_udc.c | 57 - + arch/arm/mach-pxa/gumstix.c | 100 ++- + arch/arm/mach-pxa/include/mach/hardware.h | 2 + + arch/arm/mach-pxa/include/mach/i2c.h | 6 +- + arch/arm/mach-pxa/include/mach/irqs.h | 8 +- + arch/arm/mach-pxa/include/mach/mfp-pxa320.h | 8 +- + arch/arm/mach-pxa/include/mach/mioa701.h | 67 ++ + arch/arm/mach-pxa/include/mach/palmz72.h | 67 ++ + arch/arm/mach-pxa/include/mach/pm.h | 2 + + arch/arm/mach-pxa/include/mach/ssp.h | 24 + + arch/arm/mach-pxa/include/mach/trizeps4.h | 84 ++- + arch/arm/mach-pxa/mioa701.c | 905 +++++++++++++++ + arch/arm/mach-pxa/mioa701_bootresume.S | 36 + + arch/arm/mach-pxa/palmz72.c | 481 ++++++++ + arch/arm/mach-pxa/pm.c | 18 + + arch/arm/mach-pxa/pxa25x.c | 20 +- + arch/arm/mach-pxa/pxa27x.c | 22 +- + arch/arm/mach-pxa/pxa3xx.c | 45 + + arch/arm/mach-pxa/trizeps4.c | 549 ++++++---- + arch/arm/mach-pxa/zylonite_pxa300.c | 8 +- + arch/arm/mach-pxa/zylonite_pxa320.c | 6 + + arch/arm/mach-sa1100/cpu-sa1100.c | 4 +- + arch/arm/mach-sa1100/cpu-sa1110.c | 1 + + arch/arm/mach-sa1100/include/mach/SA-1100.h | 16 - + arch/arm/mach-sa1100/include/mach/hardware.h | 18 + + arch/arm/mm/abort-ev7.S | 1 + + arch/arm/mm/abort-nommu.S | 1 + + arch/arm/mm/cache-v7.S | 10 + + arch/arm/mm/cache-xsc3l2.c | 3 +- + arch/arm/mm/copypage-v6.c | 1 + + arch/arm/mm/fault-armv.c | 1 + + arch/arm/mm/flush.c | 1 + + arch/arm/mm/ioremap.c | 1 + + arch/arm/mm/mmap.c | 5 +- + arch/arm/mm/mmu.c | 1 + + arch/arm/mm/proc-v7.S | 8 + + arch/arm/mm/tlb-v7.S | 2 + + arch/arm/oprofile/Makefile | 1 + + arch/arm/oprofile/common.c | 4 + + arch/arm/oprofile/op_arm_model.h | 1 + + arch/arm/oprofile/op_model_v7.c | 411 +++++++ + arch/arm/oprofile/op_model_v7.h | 103 ++ + arch/arm/oprofile/op_model_xscale.c | 2 +- + arch/arm/plat-omap/Kconfig | 24 + + arch/arm/plat-omap/common.c | 36 +- + arch/arm/plat-omap/dma.c | 6 +- + arch/arm/plat-omap/dmtimer.c | 2 +- + arch/arm/plat-omap/include/mach/clock.h | 3 + + arch/arm/plat-omap/include/mach/clockdomain.h | 106 ++ + arch/arm/plat-omap/include/mach/control.h | 6 +- + arch/arm/plat-omap/include/mach/fpga.h | 12 +- + arch/arm/plat-omap/include/mach/hardware.h | 2 +- + arch/arm/plat-omap/include/mach/io.h | 53 +- + arch/arm/plat-omap/include/mach/irqs.h | 2 + + arch/arm/plat-omap/include/mach/mcbsp.h | 4 +- + arch/arm/plat-omap/include/mach/pm.h | 4 +- + arch/arm/plat-omap/include/mach/powerdomain.h | 166 +++ + arch/arm/plat-omap/include/mach/sdrc.h | 6 +- + arch/arm/plat-omap/include/mach/serial.h | 12 +- + arch/arm/plat-omap/mcbsp.c | 21 +- + arch/arm/vfp/entry.S | 8 +- + arch/arm/vfp/vfphw.S | 25 +- + drivers/char/hw_random/omap-rng.c | 2 +- + drivers/i2c/busses/i2c-omap.c | 2 +- + drivers/i2c/busses/i2c-pxa.c | 49 +- + drivers/input/touchscreen/Kconfig | 1 + + drivers/input/touchscreen/ucb1400_ts.c | 382 +++---- + drivers/mfd/Kconfig | 9 + + drivers/mfd/Makefile | 1 + + drivers/mfd/ucb1400_core.c | 106 ++ + drivers/mmc/host/omap.c | 2 +- + drivers/pcmcia/Makefile | 3 +- + drivers/pcmcia/pxa2xx_palmld.c | 151 +++ + drivers/serial/8250.c | 23 +- + drivers/spi/omap2_mcspi.c | 8 +- + drivers/spi/omap_uwire.c | 2 +- + drivers/usb/host/ohci-omap.c | 2 +- + drivers/video/Kconfig | 31 +- + drivers/video/Makefile | 1 - + drivers/video/am200epd.c | 295 ----- + drivers/video/atmel_lcdfb.c | 4 + + drivers/video/metronomefb.c | 288 +++--- + drivers/video/omap/dispc.c | 10 +- + drivers/video/omap/rfbi.c | 4 +- + drivers/video/omap/sossi.c | 2 +- + drivers/watchdog/ixp4xx_wdt.c | 4 +- + include/linux/ucb1400.h | 161 +++ + include/video/atmel_lcdc.h | 1 + + include/video/metronomefb.h | 31 +- + 208 files changed, 13123 insertions(+), 2057 deletions(-) + create mode 100644 arch/arm/configs/afeb9260_defconfig + create mode 100644 arch/arm/configs/cm_x300_defconfig + create mode 100644 arch/arm/configs/palmz72_defconfig + create mode 100644 arch/arm/include/asm/cachetype.h + create mode 100644 arch/arm/include/asm/cputype.h + create mode 100644 arch/arm/mach-at91/board-afeb-9260v1.c + create mode 100644 arch/arm/mach-omap2/clockdomain.c + create mode 100644 arch/arm/mach-omap2/clockdomains.h + create mode 100644 arch/arm/mach-omap2/powerdomain.c + create mode 100644 arch/arm/mach-omap2/powerdomains.h + create mode 100644 arch/arm/mach-omap2/powerdomains24xx.h + create mode 100644 arch/arm/mach-omap2/powerdomains34xx.h + create mode 100644 arch/arm/mach-pxa/am200epd.c + create mode 100644 arch/arm/mach-pxa/cm-x300.c + create mode 100644 arch/arm/mach-pxa/e330.c + create mode 100644 arch/arm/mach-pxa/e350.c + create mode 100644 arch/arm/mach-pxa/e400.c + delete mode 100644 arch/arm/mach-pxa/e400_lcd.c + create mode 100644 arch/arm/mach-pxa/e740.c + delete mode 100644 arch/arm/mach-pxa/e740_lcd.c + rename arch/arm/mach-pxa/{e750_lcd.c => e750.c} (61%) + rename arch/arm/mach-pxa/{e800_lcd.c => e800.c} (65%) + create mode 100644 arch/arm/mach-pxa/eseries.h + delete mode 100644 arch/arm/mach-pxa/eseries_udc.c + create mode 100644 arch/arm/mach-pxa/include/mach/mioa701.h + create mode 100644 arch/arm/mach-pxa/include/mach/palmz72.h + create mode 100644 arch/arm/mach-pxa/mioa701.c + create mode 100644 arch/arm/mach-pxa/mioa701_bootresume.S + create mode 100644 arch/arm/mach-pxa/palmz72.c + create mode 100644 arch/arm/oprofile/op_model_v7.c + create mode 100644 arch/arm/oprofile/op_model_v7.h + create mode 100644 arch/arm/plat-omap/include/mach/clockdomain.h + create mode 100644 arch/arm/plat-omap/include/mach/powerdomain.h + create mode 100644 drivers/mfd/ucb1400_core.c + create mode 100644 drivers/pcmcia/pxa2xx_palmld.c + delete mode 100644 drivers/video/am200epd.c + create mode 100644 include/linux/ucb1400.h +Merging avr32/avr32-arch +$ git merge avr32/avr32-arch +Merge made by recursive. + arch/avr32/include/asm/byteorder.h | 22 +++++--- + arch/avr32/kernel/asm-offsets.c | 6 ++ + arch/avr32/kernel/entry-avr32b.S | 59 +++++++++++++++++++++- + arch/avr32/mach-at32ap/include/mach/io.h | 3 +- + arch/avr32/mach-at32ap/pm-at32ap700x.S | 2 +- + arch/avr32/oprofile/Makefile | 2 +- + arch/avr32/oprofile/backtrace.c | 81 ++++++++++++++++++++++++++++++ + arch/avr32/oprofile/op_model_avr32.c | 4 ++ + 8 files changed, 165 insertions(+), 14 deletions(-) + create mode 100644 arch/avr32/oprofile/backtrace.c +Merging blackfin/for-linus +$ git merge blackfin/for-linus +Already up-to-date. +Merging cris/for-next +$ git merge cris/for-next +Merge made by recursive. + arch/cris/arch-v10/boot/compressed/Makefile | 2 +- + .../compressed/{decompress.ld => decompress.lds} | 0 + arch/cris/arch-v10/boot/rescue/Makefile | 2 +- + .../arch-v10/boot/rescue/{rescue.ld => rescue.lds} | 0 + arch/cris/arch-v32/boot/compressed/Makefile | 2 +- + .../compressed/{decompress.ld => decompress.lds} | 0 + arch/cris/arch-v32/boot/rescue/Makefile | 2 +- + .../arch-v32/boot/rescue/{rescue.ld => rescue.lds} | 0 + 8 files changed, 4 insertions(+), 4 deletions(-) + rename arch/cris/arch-v10/boot/compressed/{decompress.ld => decompress.lds} (100%) + rename arch/cris/arch-v10/boot/rescue/{rescue.ld => rescue.lds} (100%) + rename arch/cris/arch-v32/boot/compressed/{decompress.ld => decompress.lds} (100%) + rename arch/cris/arch-v32/boot/rescue/{rescue.ld => rescue.lds} (100%) +Merging ia64/test +$ git merge ia64/test +Already up-to-date. +Merging quilt/m68k +$ git merge quilt/m68k +Merge made by recursive. + arch/m68k/Kconfig | 43 ++++++++++++----------- + arch/m68k/amiga/config.c | 9 +++++ + arch/m68k/atari/atakeyb.c | 12 ------ + arch/m68k/atari/time.c | 38 +++++++++++--------- + arch/m68k/bvme6000/config.c | 15 +-------- + arch/m68k/bvme6000/rtc.c | 30 ++++++++-------- + arch/m68k/configs/amiga_defconfig | 53 +++++++++++++++++----------- + arch/m68k/configs/apollo_defconfig | 53 +++++++++++++++++----------- + arch/m68k/configs/atari_defconfig | 60 +++++++++++++++++++------------- + arch/m68k/configs/bvme6000_defconfig | 52 +++++++++++++++++----------- + arch/m68k/configs/hp300_defconfig | 52 +++++++++++++++++----------- + arch/m68k/configs/mac_defconfig | 53 +++++++++++++++++----------- + arch/m68k/configs/multi_defconfig | 62 +++++++++++++++++++-------------- + arch/m68k/configs/mvme147_defconfig | 52 +++++++++++++++++----------- + arch/m68k/configs/mvme16x_defconfig | 52 +++++++++++++++++----------- + arch/m68k/configs/q40_defconfig | 53 +++++++++++++++++----------- + arch/m68k/configs/sun3_defconfig | 54 +++++++++++++++++------------ + arch/m68k/configs/sun3x_defconfig | 52 +++++++++++++++++----------- + arch/m68k/kernel/dma.c | 4 +- + arch/m68k/kernel/traps.c | 9 ++--- + arch/m68k/kernel/vmlinux-std.lds | 9 +++-- + arch/m68k/mvme16x/rtc.c | 26 +++++++------- + arch/m68k/q40/config.c | 12 +------ + arch/m68k/sun3x/time.c | 28 ++++++++-------- + drivers/char/amiserial.c | 6 ++- + include/asm-m68k/dma-mapping.h | 16 +++++++++ + include/asm-m68k/pci.h | 1 + + 27 files changed, 517 insertions(+), 389 deletions(-) +Merging m68knommu/for-next +$ git merge m68knommu/for-next +Merge made by recursive. + arch/m68knommu/platform/coldfire/entry.S | 15 ++------------- + 1 files changed, 2 insertions(+), 13 deletions(-) +Merging mips/mips-for-linux-next +$ git merge mips/mips-for-linux-next +Merge made by recursive. + Documentation/kernel-parameters.txt | 4 + + arch/mips/Kconfig | 2 +- + arch/mips/Makefile | 8 +- + arch/mips/kernel/ptrace32.c | 43 +-- + arch/mips/kernel/scall64-n32.S | 2 +- + arch/mips/kernel/scall64-o32.S | 2 +- + arch/mips/kernel/signal32.c | 12 + + arch/mips/pci/Makefile | 1 + + arch/mips/pci/pci-tx4938.c | 2 +- + arch/mips/pci/pci-tx4939.c | 109 ++++ + arch/mips/pmc-sierra/msp71xx/Makefile | 1 + + arch/mips/pmc-sierra/msp71xx/gpio.c | 218 ++++++++ + arch/mips/pmc-sierra/msp71xx/gpio_extended.c | 148 ++++++ + arch/mips/rb532/devices.c | 22 +- + arch/mips/rb532/gpio.c | 238 +++++++--- + arch/mips/rb532/irq.c | 2 +- + arch/mips/rb532/prom.c | 12 - + arch/mips/rb532/serial.c | 6 +- + arch/mips/rb532/setup.c | 4 +- + arch/mips/txx9/Kconfig | 24 +- + arch/mips/txx9/generic/Makefile | 2 + + arch/mips/txx9/generic/irq_tx4927.c | 11 + + arch/mips/txx9/generic/irq_tx4938.c | 11 + + arch/mips/txx9/generic/irq_tx4939.c | 215 ++++++++ + arch/mips/txx9/generic/setup.c | 431 ++++++++++++++++- + arch/mips/txx9/generic/setup_tx3927.c | 37 +- + arch/mips/txx9/generic/setup_tx4927.c | 97 ++++ + arch/mips/txx9/generic/setup_tx4938.c | 122 +++++ + arch/mips/txx9/generic/setup_tx4939.c | 460 +++++++++++++++++ + arch/mips/txx9/{rbtx4938 => generic}/spi_eeprom.c | 28 +- + arch/mips/txx9/jmr3927/prom.c | 1 - + arch/mips/txx9/jmr3927/setup.c | 25 +- + arch/mips/txx9/rbtx4927/irq.c | 11 +- + arch/mips/txx9/rbtx4927/prom.c | 1 - + arch/mips/txx9/rbtx4927/setup.c | 25 +- + arch/mips/txx9/rbtx4938/Makefile | 2 +- + arch/mips/txx9/rbtx4938/irq.c | 8 +- + arch/mips/txx9/rbtx4938/prom.c | 3 - + arch/mips/txx9/rbtx4938/setup.c | 63 ++- + arch/mips/txx9/rbtx4939/Makefile | 3 + + arch/mips/txx9/rbtx4939/irq.c | 96 ++++ + arch/mips/txx9/rbtx4939/prom.c | 17 + + arch/mips/txx9/rbtx4939/setup.c | 306 ++++++++++++ + include/asm-mips/mach-rc32434/gpio.h | 74 +--- + include/asm-mips/mach-rc32434/irq.h | 25 + + include/asm-mips/mach-rc32434/prom.h | 4 - + include/asm-mips/mach-rc32434/rb.h | 5 +- + include/asm-mips/mach-rc32434/rc32434.h | 42 -- + include/asm-mips/pmc-sierra/msp71xx/gpio.h | 46 ++ + include/asm-mips/ptrace.h | 3 + + include/asm-mips/txx9/boards.h | 13 + + include/asm-mips/txx9/generic.h | 29 +- + include/asm-mips/txx9/rbtx4927.h | 3 + + include/asm-mips/txx9/rbtx4939.h | 133 +++++ + include/asm-mips/txx9/smsc_fdc37m81x.h | 1 + + include/asm-mips/txx9/spi.h | 19 +- + include/asm-mips/txx9/tx3927.h | 2 + + include/asm-mips/txx9/tx4927.h | 14 + + include/asm-mips/txx9/tx4938.h | 2 + + include/asm-mips/txx9/tx4939.h | 544 +++++++++++++++++++++ + 60 files changed, 3449 insertions(+), 345 deletions(-) + create mode 100644 arch/mips/pci/pci-tx4939.c + create mode 100644 arch/mips/pmc-sierra/msp71xx/gpio.c + create mode 100644 arch/mips/pmc-sierra/msp71xx/gpio_extended.c + create mode 100644 arch/mips/txx9/generic/irq_tx4939.c + create mode 100644 arch/mips/txx9/generic/setup_tx4939.c + rename arch/mips/txx9/{rbtx4938 => generic}/spi_eeprom.c (79%) + create mode 100644 arch/mips/txx9/rbtx4939/Makefile + create mode 100644 arch/mips/txx9/rbtx4939/irq.c + create mode 100644 arch/mips/txx9/rbtx4939/prom.c + create mode 100644 arch/mips/txx9/rbtx4939/setup.c + create mode 100644 include/asm-mips/pmc-sierra/msp71xx/gpio.h + create mode 100644 include/asm-mips/txx9/boards.h + create mode 100644 include/asm-mips/txx9/rbtx4939.h + create mode 100644 include/asm-mips/txx9/tx4939.h +Merging parisc/master +$ git merge parisc/master +Merge made by recursive. + .../asm-parisc => arch/parisc/include/asm}/Kbuild | 0 + .../asm-parisc => arch/parisc/include/asm}/a.out.h | 0 + .../asm-parisc => arch/parisc/include/asm}/agp.h | 0 + .../parisc/include/asm}/asmregs.h | 0 + .../parisc/include/asm}/assembly.h | 0 + .../parisc/include/asm}/atomic.h | 0 + .../parisc/include/asm}/auxvec.h | 0 + .../parisc/include/asm}/bitops.h | 0 + .../asm-parisc => arch/parisc/include/asm}/bug.h | 0 + .../asm-parisc => arch/parisc/include/asm}/bugs.h | 0 + .../parisc/include/asm}/byteorder.h | 0 + .../asm-parisc => arch/parisc/include/asm}/cache.h | 0 + .../parisc/include/asm}/cacheflush.h | 0 + .../parisc/include/asm}/checksum.h | 0 + .../parisc/include/asm}/compat.h | 0 + .../parisc/include/asm}/compat_rt_sigframe.h | 0 + .../parisc/include/asm}/compat_signal.h | 0 + .../parisc/include/asm}/compat_ucontext.h | 0 + .../parisc/include/asm}/cputime.h | 0 + .../parisc/include/asm}/current.h | 0 + .../asm-parisc => arch/parisc/include/asm}/delay.h | 0 + .../parisc/include/asm}/device.h | 0 + .../asm-parisc => arch/parisc/include/asm}/div64.h | 0 + .../parisc/include/asm}/dma-mapping.h | 0 + .../asm-parisc => arch/parisc/include/asm}/dma.h | 0 + .../parisc/include/asm}/eisa_bus.h | 0 + .../parisc/include/asm}/eisa_eeprom.h | 0 + .../asm-parisc => arch/parisc/include/asm}/elf.h | 0 + .../parisc/include/asm}/emergency-restart.h | 0 + .../asm-parisc => arch/parisc/include/asm}/errno.h | 0 + .../asm-parisc => arch/parisc/include/asm}/fb.h | 0 + .../asm-parisc => arch/parisc/include/asm}/fcntl.h | 0 + .../parisc/include/asm}/fixmap.h | 0 + .../parisc/include/asm}/floppy.h | 0 + .../asm-parisc => arch/parisc/include/asm}/futex.h | 0 + .../parisc/include/asm}/grfioctl.h | 0 + .../parisc/include/asm}/hardirq.h | 0 + .../parisc/include/asm}/hardware.h | 0 + .../parisc/include/asm}/hw_irq.h | 0 + .../asm-parisc => arch/parisc/include/asm}/ide.h | 0 + .../asm-parisc => arch/parisc/include/asm}/io.h | 0 + .../asm-parisc => arch/parisc/include/asm}/ioctl.h | 0 + .../parisc/include/asm}/ioctls.h | 0 + .../parisc/include/asm}/ipcbuf.h | 0 + .../asm-parisc => arch/parisc/include/asm}/irq.h | 0 + .../parisc/include/asm}/irq_regs.h | 0 + .../parisc/include/asm}/kdebug.h | 0 + .../parisc/include/asm}/kmap_types.h | 0 + .../asm-parisc => arch/parisc/include/asm}/led.h | 0 + .../parisc/include/asm}/linkage.h | 0 + .../asm-parisc => arch/parisc/include/asm}/local.h | 0 + .../parisc/include/asm}/machdep.h | 0 + .../parisc/include/asm}/mc146818rtc.h | 0 + .../parisc/include/asm}/mckinley.h | 0 + .../asm-parisc => arch/parisc/include/asm}/mman.h | 0 + .../asm-parisc => arch/parisc/include/asm}/mmu.h | 0 + .../parisc/include/asm}/mmu_context.h | 0 + .../parisc/include/asm}/mmzone.h | 0 + .../parisc/include/asm}/module.h | 0 + .../parisc/include/asm}/msgbuf.h | 0 + .../asm-parisc => arch/parisc/include/asm}/mutex.h | 0 + .../asm-parisc => arch/parisc/include/asm}/page.h | 0 + .../asm-parisc => arch/parisc/include/asm}/param.h | 0 + .../parisc/include/asm}/parisc-device.h | 0 + .../parisc/include/asm}/parport.h | 0 + .../asm-parisc => arch/parisc/include/asm}/pci.h | 0 + .../asm-parisc => arch/parisc/include/asm}/pdc.h | 5 ++ + .../parisc/include/asm}/pdc_chassis.h | 0 + .../parisc/include/asm}/pdcpat.h | 0 + .../parisc/include/asm}/percpu.h | 0 + .../asm-parisc => arch/parisc/include/asm}/perf.h | 0 + .../parisc/include/asm}/pgalloc.h | 0 + .../parisc/include/asm}/pgtable.h | 0 + .../asm-parisc => arch/parisc/include/asm}/poll.h | 0 + .../parisc/include/asm}/posix_types.h | 0 + .../parisc/include/asm}/prefetch.h | 0 + .../parisc/include/asm}/processor.h | 0 + .../asm-parisc => arch/parisc/include/asm}/psw.h | 0 + .../parisc/include/asm}/ptrace.h | 0 + .../asm-parisc => arch/parisc/include/asm}/real.h | 0 + .../parisc/include/asm}/resource.h | 0 + .../asm-parisc => arch/parisc/include/asm}/ropes.h | 2 +- + .../parisc/include/asm}/rt_sigframe.h | 0 + .../asm-parisc => arch/parisc/include/asm}/rtc.h | 0 + .../parisc/include/asm}/runway.h | 0 + .../parisc/include/asm}/scatterlist.h | 0 + .../parisc/include/asm}/sections.h | 0 + .../parisc/include/asm}/segment.h | 0 + .../parisc/include/asm}/sembuf.h | 0 + .../parisc/include/asm}/serial.h | 0 + .../asm-parisc => arch/parisc/include/asm}/setup.h | 0 + .../parisc/include/asm}/shmbuf.h | 0 + .../parisc/include/asm}/shmparam.h | 0 + .../parisc/include/asm}/sigcontext.h | 0 + .../parisc/include/asm}/siginfo.h | 0 + .../parisc/include/asm}/signal.h | 0 + .../asm-parisc => arch/parisc/include/asm}/smp.h | 0 + .../parisc/include/asm}/socket.h | 0 + .../parisc/include/asm}/sockios.h | 0 + .../parisc/include/asm}/spinlock.h | 0 + .../parisc/include/asm}/spinlock_types.h | 0 + .../asm-parisc => arch/parisc/include/asm}/stat.h | 0 + .../parisc/include/asm}/statfs.h | 0 + .../parisc/include/asm}/string.h | 0 + .../parisc/include/asm}/superio.h | 0 + .../parisc/include/asm}/system.h | 0 + .../parisc/include/asm}/termbits.h | 0 + .../parisc/include/asm}/termios.h | 0 + .../parisc/include/asm}/thread_info.h | 0 + .../asm-parisc => arch/parisc/include/asm}/timex.h | 0 + .../asm-parisc => arch/parisc/include/asm}/tlb.h | 0 + .../parisc/include/asm}/tlbflush.h | 0 + .../parisc/include/asm}/topology.h | 0 + .../asm-parisc => arch/parisc/include/asm}/traps.h | 0 + .../asm-parisc => arch/parisc/include/asm}/types.h | 0 + .../parisc/include/asm}/uaccess.h | 0 + .../parisc/include/asm}/ucontext.h | 0 + .../parisc/include/asm}/unaligned.h | 0 + .../parisc/include/asm}/unistd.h | 0 + .../parisc/include/asm}/unwind.h | 0 + .../asm-parisc => arch/parisc/include/asm}/user.h | 0 + .../asm-parisc => arch/parisc/include/asm}/vga.h | 0 + .../asm-parisc => arch/parisc/include/asm}/xor.h | 0 + arch/parisc/kernel/.gitignore | 1 + + arch/parisc/kernel/asm-offsets.c | 3 + + arch/parisc/kernel/firmware.c | 69 +++++++++++++------- + arch/parisc/kernel/head.S | 2 +- + arch/parisc/kernel/real2.S | 12 ++++ + arch/parisc/kernel/setup.c | 27 +++++++- + drivers/char/agp/parisc-agp.c | 4 +- + drivers/parisc/ccio-dma.c | 43 +++++------- + 131 files changed, 114 insertions(+), 54 deletions(-) + rename {include/asm-parisc => arch/parisc/include/asm}/Kbuild (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/a.out.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/agp.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/asmregs.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/assembly.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/atomic.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/auxvec.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/bitops.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/bug.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/bugs.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/byteorder.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/cache.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/cacheflush.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/checksum.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/compat.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/compat_rt_sigframe.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/compat_signal.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/compat_ucontext.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/cputime.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/current.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/delay.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/device.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/div64.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/dma-mapping.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/dma.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/eisa_bus.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/eisa_eeprom.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/elf.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/emergency-restart.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/errno.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/fb.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/fcntl.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/fixmap.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/floppy.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/futex.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/grfioctl.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/hardirq.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/hardware.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/hw_irq.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/ide.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/io.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/ioctl.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/ioctls.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/ipcbuf.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/irq.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/irq_regs.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/kdebug.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/kmap_types.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/led.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/linkage.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/local.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/machdep.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/mc146818rtc.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/mckinley.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/mman.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/mmu.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/mmu_context.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/mmzone.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/module.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/msgbuf.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/mutex.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/page.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/param.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/parisc-device.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/parport.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/pci.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/pdc.h (99%) + rename {include/asm-parisc => arch/parisc/include/asm}/pdc_chassis.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/pdcpat.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/percpu.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/perf.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/pgalloc.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/pgtable.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/poll.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/posix_types.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/prefetch.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/processor.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/psw.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/ptrace.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/real.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/resource.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/ropes.h (99%) + rename {include/asm-parisc => arch/parisc/include/asm}/rt_sigframe.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/rtc.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/runway.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/scatterlist.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/sections.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/segment.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/sembuf.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/serial.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/setup.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/shmbuf.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/shmparam.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/sigcontext.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/siginfo.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/signal.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/smp.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/socket.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/sockios.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/spinlock.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/spinlock_types.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/stat.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/statfs.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/string.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/superio.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/system.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/termbits.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/termios.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/thread_info.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/timex.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/tlb.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/tlbflush.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/topology.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/traps.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/types.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/uaccess.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/ucontext.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/unaligned.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/unistd.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/unwind.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/user.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/vga.h (100%) + rename {include/asm-parisc => arch/parisc/include/asm}/xor.h (100%) + create mode 100644 arch/parisc/kernel/.gitignore +Merging powerpc/powerpc-next +$ git merge powerpc/powerpc-next +Merge made by recursive. + arch/powerpc/Kconfig.debug | 5 + + arch/powerpc/boot/dtc-src/Makefile.dtc | 18 +- + arch/powerpc/boot/dtc-src/checks.c | 305 +++---------- + arch/powerpc/boot/dtc-src/data.c | 62 ++-- + arch/powerpc/boot/dtc-src/dtc-lexer.l | 120 +++--- + arch/powerpc/boot/dtc-src/dtc-lexer.lex.c_shipped | 445 ++++++++++---------- + arch/powerpc/boot/dtc-src/dtc-parser.tab.c_shipped | 387 ++++++++++-------- + arch/powerpc/boot/dtc-src/dtc-parser.tab.h_shipped | 12 +- + arch/powerpc/boot/dtc-src/dtc-parser.y | 67 +++- + arch/powerpc/boot/dtc-src/dtc.c | 41 +- + arch/powerpc/boot/dtc-src/dtc.h | 43 +-- + arch/powerpc/boot/dtc-src/flattree.c | 232 ++++------- + arch/powerpc/boot/dtc-src/fstree.c | 8 +- + arch/powerpc/boot/dtc-src/libfdt_env.h | 23 + + arch/powerpc/boot/dtc-src/livetree.c | 9 +- + arch/powerpc/boot/dtc-src/srcpos.c | 121 +++--- + arch/powerpc/boot/dtc-src/srcpos.h | 30 +- + arch/powerpc/boot/dtc-src/treesource.c | 15 +- + arch/powerpc/boot/dtc-src/version_gen.h | 2 +- + arch/powerpc/boot/libfdt/Makefile.libfdt | 8 +- + arch/powerpc/boot/libfdt/fdt.c | 61 +++- + arch/powerpc/boot/libfdt/fdt_ro.c | 329 +++++---------- + arch/powerpc/boot/libfdt/fdt_rw.c | 200 +++++---- + arch/powerpc/boot/libfdt/fdt_strerror.c | 34 +- + arch/powerpc/boot/libfdt/fdt_sw.c | 55 ++-- + arch/powerpc/boot/libfdt/fdt_wip.c | 9 +- + arch/powerpc/boot/libfdt/libfdt.h | 383 ++++++++++++++++- + arch/powerpc/boot/libfdt/libfdt_internal.h | 24 +- + arch/powerpc/boot/libfdt_env.h | 1 + + arch/powerpc/include/asm/cputable.h | 1 + + arch/powerpc/include/asm/mpic.h | 4 +- + arch/powerpc/include/asm/msi_bitmap.h | 35 ++ + arch/powerpc/include/asm/of_device.h | 3 - + arch/powerpc/include/asm/of_platform.h | 3 - + arch/powerpc/include/asm/smp.h | 39 ++- + arch/powerpc/kernel/Makefile | 4 +- + arch/powerpc/kernel/btext.c | 34 +- + arch/powerpc/kernel/cputable.c | 24 + + arch/powerpc/kernel/entry_64.S | 53 ++- + arch/powerpc/kernel/lparcfg.c | 8 +- + arch/powerpc/kernel/setup_32.c | 11 - + arch/powerpc/kernel/sysfs.c | 117 ++++-- + arch/powerpc/mm/hash_utils_64.c | 2 + + arch/powerpc/oprofile/op_model_power4.c | 4 +- + arch/powerpc/platforms/chrp/time.c | 24 +- + arch/powerpc/platforms/iseries/mf.c | 26 +- + arch/powerpc/platforms/maple/time.c | 24 +- + arch/powerpc/platforms/powermac/time.c | 3 + + arch/powerpc/platforms/pseries/cmm.c | 4 +- + arch/powerpc/platforms/pseries/eeh_driver.c | 2 +- + arch/powerpc/sysdev/Kconfig | 6 + + arch/powerpc/sysdev/Makefile | 1 + + arch/powerpc/sysdev/fsl_msi.c | 109 +---- + arch/powerpc/sysdev/fsl_msi.h | 8 +- + arch/powerpc/sysdev/mpic.h | 2 - + arch/powerpc/sysdev/mpic_msi.c | 123 +----- + arch/powerpc/sysdev/mpic_pasemi_msi.c | 24 +- + arch/powerpc/sysdev/mpic_u3msi.c | 22 +- + arch/powerpc/sysdev/msi_bitmap.c | 247 +++++++++++ + drivers/hwmon/ams/ams.h | 2 +- + drivers/pci/hotplug/rpaphp_slot.c | 4 - + sound/aoa/soundbus/soundbus.h | 2 +- + 62 files changed, 2216 insertions(+), 1808 deletions(-) + create mode 100644 arch/powerpc/boot/dtc-src/libfdt_env.h + create mode 100644 arch/powerpc/include/asm/msi_bitmap.h + create mode 100644 arch/powerpc/sysdev/msi_bitmap.c +Merging 4xx/next +$ git merge 4xx/next +Already up-to-date. +Merging galak/powerpc-next +$ git merge galak/powerpc-next +Auto-merged arch/powerpc/configs/83xx/mpc836x_mds_defconfig +Merge made by recursive. + arch/powerpc/boot/dts/mgcoge.dts | 174 +++++ + arch/powerpc/boot/dts/mgsuvd.dts | 163 ++++ + arch/powerpc/boot/dts/mpc836x_mds.dts | 23 +- + arch/powerpc/configs/83xx/mpc836x_mds_defconfig | 79 ++- + arch/powerpc/configs/mgcoge_defconfig | 900 +++++++++++++++++++++++ + arch/powerpc/configs/mgsuvd_defconfig | 872 ++++++++++++++++++++++ + arch/powerpc/mm/fsl_booke_mmu.c | 5 +- + arch/powerpc/platforms/82xx/Kconfig | 8 + + arch/powerpc/platforms/82xx/Makefile | 1 + + arch/powerpc/platforms/82xx/mgcoge.c | 129 ++++ + arch/powerpc/platforms/8xx/Kconfig | 6 + + arch/powerpc/platforms/8xx/Makefile | 1 + + arch/powerpc/platforms/8xx/mgsuvd.c | 92 +++ + drivers/serial/Kconfig | 36 - + include/math-emu/op-2.h | 2 +- + include/math-emu/op-common.h | 12 +- + include/math-emu/soft-fp.h | 19 + + 17 files changed, 2475 insertions(+), 47 deletions(-) + create mode 100644 arch/powerpc/boot/dts/mgcoge.dts + create mode 100644 arch/powerpc/boot/dts/mgsuvd.dts + create mode 100644 arch/powerpc/configs/mgcoge_defconfig + create mode 100644 arch/powerpc/configs/mgsuvd_defconfig + create mode 100644 arch/powerpc/platforms/82xx/mgcoge.c + create mode 100644 arch/powerpc/platforms/8xx/mgsuvd.c +Merging s390/features +$ git merge s390/features +Merge made by recursive. + arch/s390/Kconfig | 1 + + arch/s390/include/asm/ptrace.h | 1 + + arch/s390/include/asm/qdio.h | 8 +- + arch/s390/include/asm/syscall.h | 80 ++++++ + arch/s390/include/asm/thread_info.h | 2 + + arch/s390/kernel/compat_linux.c | 8 - + arch/s390/kernel/compat_linux.h | 1 - + arch/s390/kernel/compat_wrapper.S | 2 - + arch/s390/kernel/entry.S | 50 +++- + arch/s390/kernel/entry64.S | 42 +++- + arch/s390/kernel/ptrace.c | 61 +++-- + arch/s390/kernel/signal.c | 13 + + arch/s390/kernel/syscalls.S | 2 +- + arch/s390/mm/extmem.c | 251 ++++++++++++++--- + drivers/s390/block/dcssblk.c | 516 ++++++++++++++++++++++++++--------- + drivers/s390/cio/blacklist.c | 11 +- + drivers/s390/cio/chp.c | 7 +- + drivers/s390/cio/css.c | 32 ++- + drivers/s390/cio/device.c | 96 +++++-- + drivers/s390/cio/device.h | 1 + + drivers/s390/cio/device_fsm.c | 7 + + drivers/s390/cio/qdio.h | 3 + + drivers/s390/cio/qdio_main.c | 24 ++- + 23 files changed, 931 insertions(+), 288 deletions(-) + create mode 100644 arch/s390/include/asm/syscall.h +Merging sh/master +$ git merge sh/master +Merge made by recursive. + arch/sh/Kconfig | 4 + + arch/sh/configs/ap325rxa_defconfig | 22 +++-- + arch/sh/configs/migor_defconfig | 21 +++-- + arch/sh/include/asm/bitops-llsc.h | 144 +++++++++++++++++++++++++++++++ + arch/sh/include/asm/bitops.h | 2 + + arch/sh/include/asm/cmpxchg-llsc.h | 71 +++++++++++++++ + arch/sh/include/asm/smp.h | 26 +++--- + arch/sh/include/asm/system.h | 2 + + arch/sh/include/asm/uaccess_64.h | 2 + + arch/sh/kernel/cpu/sh4a/smp-shx3.c | 67 ++++++--------- + arch/sh/kernel/machine_kexec.c | 2 +- + arch/sh/kernel/process_32.c | 12 ++- + arch/sh/kernel/ptrace_64.c | 2 + + arch/sh/kernel/setup.c | 6 +- + arch/sh/kernel/smp.c | 43 +++++++++- + arch/sh/kernel/sys_sh.c | 2 +- + arch/sh/kernel/time_32.c | 10 ++- + arch/sh/kernel/timers/Makefile | 1 + + arch/sh/kernel/timers/timer-broadcast.c | 57 ++++++++++++ + arch/sh/mm/consistent.c | 6 +- + 20 files changed, 414 insertions(+), 88 deletions(-) + create mode 100644 arch/sh/include/asm/bitops-llsc.h + create mode 100644 arch/sh/include/asm/cmpxchg-llsc.h + create mode 100644 arch/sh/kernel/timers/timer-broadcast.c +Merging sparc/master +$ git merge sparc/master +Removed Documentation/sparc/sbus_drivers.txt +Removed arch/sparc/include/asm/bpp.h +Removed arch/sparc/include/asm/dma_32.h +Removed arch/sparc/include/asm/dma_64.h +Removed arch/sparc/include/asm/ebus.h +Removed arch/sparc/include/asm/ebus_32.h +Removed arch/sparc/include/asm/ebus_64.h +Removed arch/sparc/include/asm/mostek.h +Removed arch/sparc/include/asm/mostek_32.h +Removed arch/sparc/include/asm/mostek_64.h +Removed arch/sparc/include/asm/reboot.h +Removed arch/sparc/include/asm/rtc.h +Removed arch/sparc/include/asm/sbus.h +Removed arch/sparc/include/asm/sbus_32.h +Removed arch/sparc/include/asm/sbus_64.h +Removed arch/sparc/include/asm/sstate.h +Removed arch/sparc/include/asm/sun4paddr.h +Removed arch/sparc/include/asm/sun4prom.h +Removed arch/sparc/include/asm/vfc_ioctls.h +Removed arch/sparc/kernel/ebus.c +Auto-merged arch/sparc/kernel/of_device.c +CONFLICT (content): Merge conflict in arch/sparc/kernel/of_device.c +Auto-merged arch/sparc/kernel/sun4d_smp.c +Removed arch/sparc/kernel/sun4setup.c +Removed arch/sparc/mm/nosrmmu.c +Removed arch/sparc/prom/sun4prom.c +Auto-merged arch/sparc64/Kconfig +Auto-merged arch/sparc64/kernel/of_device.c +Auto-merged arch/sparc64/mm/init.c +Auto-merged drivers/rtc/rtc-cmos.c +Removed drivers/sbus/char/bpp.c +Removed drivers/sbus/char/cpwatchdog.c +Removed drivers/sbus/char/rtc.c +Removed drivers/sbus/char/vfc.h +Removed drivers/sbus/char/vfc_dev.c +Removed drivers/sbus/char/vfc_i2c.c +Removed drivers/sbus/char/vfc_i2c.h +Removed drivers/sbus/dvma.c +Removed drivers/sbus/sbus.c +Auto-merged drivers/watchdog/Makefile +Recorded preimage for 'arch/sparc/kernel/of_device.c' +Automatic merge failed; fix conflicts and then commit the result. +$ git commit -v -a +Recorded resolution for 'arch/sparc/kernel/of_device.c'. +Created commit a18f1a6: Merge commit 'sparc/master' +$ git diff -M --stat --summary HEAD^.. + .../sound/alsa/DocBook/writing-an-alsa-driver.tmpl | 3 +- + Documentation/sparc/sbus_drivers.txt | 309 ------ + arch/sparc/Kconfig | 26 +- + arch/sparc/include/asm/Kbuild | 2 - + arch/sparc/include/asm/asmmacro.h | 5 - + arch/sparc/include/asm/bpp.h | 73 -- + arch/sparc/include/asm/bugs.h | 7 - + arch/sparc/include/asm/cpudata_64.h | 1 - + arch/sparc/include/asm/dma-mapping_32.h | 59 +- + arch/sparc/include/asm/dma.h | 141 +++- + arch/sparc/include/asm/dma_32.h | 288 ----- + arch/sparc/include/asm/dma_64.h | 205 ---- + arch/sparc/include/asm/ebus.h | 8 - + arch/sparc/include/asm/ebus_32.h | 99 -- + arch/sparc/include/asm/ebus_64.h | 95 -- + arch/sparc/include/asm/ebus_dma.h | 35 + + arch/sparc/include/asm/elf_32.h | 7 +- + arch/sparc/include/asm/fhc.h | 43 +- + arch/sparc/include/asm/floppy_32.h | 16 +- + arch/sparc/include/asm/floppy_64.h | 130 ++-- + arch/sparc/include/asm/gpio.h | 36 + + arch/sparc/include/asm/io-unit.h | 4 - + arch/sparc/include/asm/io_32.h | 19 +- + arch/sparc/include/asm/io_64.h | 22 +- + arch/sparc/include/asm/irq_64.h | 1 - + arch/sparc/include/asm/mc146818rtc_64.h | 10 +- + arch/sparc/include/asm/memctrl.h | 9 + + arch/sparc/include/asm/mostek.h | 8 - + arch/sparc/include/asm/mostek_32.h | 171 --- + arch/sparc/include/asm/mostek_64.h | 143 --- + arch/sparc/include/asm/of_device.h | 2 + + arch/sparc/include/asm/of_platform.h | 3 - + arch/sparc/include/asm/oplib_32.h | 1 - + arch/sparc/include/asm/page_32.h | 5 +- + arch/sparc/include/asm/parport.h | 4 +- + arch/sparc/include/asm/pci_32.h | 2 + + arch/sparc/include/asm/pgtable_32.h | 4 - + arch/sparc/include/asm/prom.h | 12 + + arch/sparc/include/asm/reboot.h | 6 - + arch/sparc/include/asm/rtc.h | 26 - + arch/sparc/include/asm/sbus.h | 8 - + arch/sparc/include/asm/sbus_32.h | 153 --- + arch/sparc/include/asm/sbus_64.h | 190 ---- + arch/sparc/include/asm/sstate.h | 13 - + arch/sparc/include/asm/starfire.h | 1 - + arch/sparc/include/asm/sun4paddr.h | 56 - + arch/sparc/include/asm/sun4prom.h | 83 -- + arch/sparc/include/asm/system_32.h | 8 +- + arch/sparc/include/asm/system_64.h | 5 +- + arch/sparc/include/asm/thread_info_32.h | 4 - + arch/sparc/include/asm/timer_32.h | 8 +- + arch/sparc/include/asm/vac-ops.h | 7 - + arch/sparc/include/asm/vfc_ioctls.h | 58 - + arch/sparc/kernel/Makefile | 4 +- + arch/sparc/kernel/apc.c | 72 +- + arch/sparc/kernel/auxio.c | 6 +- + arch/sparc/kernel/devices.c | 2 +- + arch/sparc/kernel/dma.c | 227 ++++ + arch/sparc/kernel/dma.h | 14 + + arch/sparc/kernel/ebus.c | 393 ------- + arch/sparc/kernel/entry.S | 54 - + arch/sparc/kernel/head.S | 28 +- + arch/sparc/kernel/idprom.c | 7 - + arch/sparc/kernel/ioport.c | 227 +---- + arch/sparc/kernel/of_device.c | 74 +- + arch/sparc/kernel/pcic.c | 9 +- + arch/sparc/kernel/pmc.c | 57 +- + arch/sparc/kernel/process.c | 2 +- + arch/sparc/kernel/prom.c | 7 +- + arch/sparc/kernel/setup.c | 8 +- + arch/sparc/kernel/sparc_ksyms.c | 25 - + arch/sparc/kernel/sun4c_irq.c | 74 +- + arch/sparc/kernel/sun4d_irq.c | 109 +- + arch/sparc/kernel/sun4d_smp.c | 1 - + arch/sparc/kernel/sun4m_irq.c | 24 +- + arch/sparc/kernel/sun4setup.c | 75 -- + arch/sparc/kernel/sys_sparc.c | 8 +- + arch/sparc/kernel/tick14.c | 1 - + arch/sparc/kernel/time.c | 380 +------ + arch/sparc/mm/Makefile | 9 +- + arch/sparc/mm/btfixup.c | 6 +- + arch/sparc/mm/fault.c | 2 +- + arch/sparc/mm/init.c | 14 +- + arch/sparc/mm/io-unit.c | 136 +-- + arch/sparc/mm/iommu.c | 113 +- + arch/sparc/mm/nosrmmu.c | 59 - + arch/sparc/mm/srmmu.c | 1 - + arch/sparc/mm/sun4c.c | 204 +--- + arch/sparc/prom/Makefile | 2 - + arch/sparc/prom/bootstr.c | 4 - + arch/sparc/prom/console.c | 3 - + arch/sparc/prom/init.c | 12 - + arch/sparc/prom/memory.c | 14 - + arch/sparc/prom/ranges.c | 1 - + arch/sparc/prom/sun4prom.c | 161 --- + arch/sparc64/Kconfig | 23 + + arch/sparc64/kernel/Makefile | 9 +- + arch/sparc64/kernel/auxio.c | 2 +- + arch/sparc64/kernel/central.c | 617 ++++------- + arch/sparc64/kernel/chmc.c | 817 +++++++++++---- + arch/sparc64/kernel/cpu.c | 208 ++-- + arch/sparc64/kernel/ds.c | 4 +- + arch/sparc64/kernel/ebus.c | 299 +----- + arch/sparc64/kernel/entry.h | 7 +- + arch/sparc64/kernel/head.S | 1 + + arch/sparc64/kernel/hvapi.c | 3 - + arch/sparc64/kernel/hvcalls.S | 354 ++---- + arch/sparc64/kernel/irq.c | 1 - + arch/sparc64/kernel/of_device.c | 59 +- + arch/sparc64/kernel/pci.c | 152 +--- + arch/sparc64/kernel/pci_fire.c | 91 +- + arch/sparc64/kernel/pci_impl.h | 4 +- + arch/sparc64/kernel/pci_psycho.c | 117 ++- + arch/sparc64/kernel/pci_sabre.c | 138 ++- + arch/sparc64/kernel/pci_schizo.c | 155 ++- + arch/sparc64/kernel/pci_sun4v.c | 153 ++- + arch/sparc64/kernel/pci_sun4v_asm.S | 99 +- + arch/sparc64/kernel/power.c | 55 +- + arch/sparc64/kernel/process.c | 33 - + arch/sparc64/kernel/prom.c | 6 + + arch/sparc64/kernel/ptrace.c | 38 +- + arch/sparc64/kernel/reboot.c | 52 + + arch/sparc64/kernel/sbus.c | 166 ++-- + arch/sparc64/kernel/sparc64_ksyms.c | 23 +- + arch/sparc64/kernel/sstate.c | 67 +- + arch/sparc64/kernel/starfire.c | 5 - + arch/sparc64/kernel/sys_sparc32.c | 8 - + arch/sparc64/kernel/syscalls.S | 20 +- + arch/sparc64/kernel/systbls.S | 2 +- + arch/sparc64/kernel/time.c | 1164 +++----------------- + arch/sparc64/kernel/traps.c | 63 +- + arch/sparc64/mm/init.c | 48 +- + drivers/ata/Kconfig | 1 - + drivers/atm/fore200e.c | 410 ++++---- + drivers/atm/fore200e.h | 7 +- + drivers/block/sunvdc.c | 4 +- + drivers/char/hw_random/n2-drv.c | 2 +- + drivers/char/rtc.c | 30 +- + drivers/hwmon/Kconfig | 7 + + drivers/hwmon/Makefile | 1 + + drivers/hwmon/ultra45_env.c | 320 ++++++ + drivers/input/misc/sparcspkr.c | 4 +- + drivers/input/serio/i8042-sparcio.h | 2 +- + drivers/leds/Kconfig | 8 + + drivers/leds/Makefile | 1 + + drivers/leds/leds-sunfire.c | 273 +++++ + drivers/mtd/maps/sun_uflash.c | 75 +- + drivers/net/myri_sbus.c | 196 ++-- + drivers/net/myri_sbus.h | 2 +- + drivers/net/niu.c | 2 +- + drivers/net/sunbmac.c | 204 ++-- + drivers/net/sunbmac.h | 4 +- + drivers/net/sunhme.c | 322 +++---- + drivers/net/sunhme.h | 7 +- + drivers/net/sunlance.c | 180 ++-- + drivers/net/sunqe.c | 162 ++-- + drivers/net/sunqe.h | 4 +- + drivers/net/sunvnet.c | 4 +- + drivers/parport/parport_sunbpp.c | 49 +- + drivers/rtc/Kconfig | 32 +- + drivers/rtc/Makefile | 3 + + drivers/rtc/rtc-bq4802.c | 229 ++++ + drivers/rtc/rtc-cmos.c | 5 +- + drivers/rtc/rtc-m48t59.c | 63 +- + drivers/rtc/rtc-starfire.c | 120 ++ + drivers/rtc/rtc-sun4v.c | 153 +++ + drivers/sbus/Makefile | 4 - + drivers/sbus/char/Kconfig | 29 +- + drivers/sbus/char/Makefile | 6 - + drivers/sbus/char/bbc_envctrl.c | 121 +-- + drivers/sbus/char/bbc_i2c.c | 267 ++--- + drivers/sbus/char/bbc_i2c.h | 75 ++- + drivers/sbus/char/bpp.c | 1055 ------------------ + drivers/sbus/char/cpwatchdog.c | 858 --------------- + drivers/sbus/char/display7seg.c | 251 +++-- + drivers/sbus/char/envctrl.c | 147 ++-- + drivers/sbus/char/flash.c | 130 +-- + drivers/sbus/char/rtc.c | 275 ----- + drivers/sbus/char/uctrl.c | 216 ++-- + drivers/sbus/char/vfc.h | 171 --- + drivers/sbus/char/vfc_dev.c | 736 ------------- + drivers/sbus/char/vfc_i2c.c | 335 ------ + drivers/sbus/char/vfc_i2c.h | 44 - + drivers/sbus/dvma.c | 136 --- + drivers/sbus/sbus.c | 316 ------ + drivers/scsi/esp_scsi.h | 3 +- + drivers/scsi/qlogicpti.c | 146 ++-- + drivers/scsi/qlogicpti.h | 2 +- + drivers/scsi/sun_esp.c | 267 +++-- + drivers/serial/sunhv.c | 2 +- + drivers/serial/sunsab.c | 2 +- + drivers/serial/sunsu.c | 2 +- + drivers/serial/sunzilog.c | 2 +- + drivers/video/bw2.c | 2 +- + drivers/video/cg14.c | 2 +- + drivers/video/cg3.c | 2 +- + drivers/video/cg6.c | 2 +- + drivers/video/ffb.c | 2 +- + drivers/video/leo.c | 2 +- + drivers/video/p9100.c | 2 +- + drivers/video/tcx.c | 2 +- + drivers/watchdog/Makefile | 3 + + drivers/watchdog/cpwd.c | 695 ++++++++++++ + .../{sbus/char/riowatchdog.c => watchdog/riowd.c} | 236 ++--- + include/linux/rtc/m48t59.h | 47 +- + include/sound/core.h | 3 - + include/sound/memalloc.h | 2 - + sound/core/memalloc.c | 48 +- + sound/sparc/amd7930.c | 85 +-- + sound/sparc/cs4231.c | 199 ++-- + sound/sparc/dbri.c | 89 +- + 211 files changed, 6954 insertions(+), 13279 deletions(-) + delete mode 100644 Documentation/sparc/sbus_drivers.txt + delete mode 100644 arch/sparc/include/asm/bpp.h + delete mode 100644 arch/sparc/include/asm/dma_32.h + delete mode 100644 arch/sparc/include/asm/dma_64.h + delete mode 100644 arch/sparc/include/asm/ebus.h + delete mode 100644 arch/sparc/include/asm/ebus_32.h + delete mode 100644 arch/sparc/include/asm/ebus_64.h + create mode 100644 arch/sparc/include/asm/ebus_dma.h + create mode 100644 arch/sparc/include/asm/gpio.h + create mode 100644 arch/sparc/include/asm/memctrl.h + delete mode 100644 arch/sparc/include/asm/mostek.h + delete mode 100644 arch/sparc/include/asm/mostek_32.h + delete mode 100644 arch/sparc/include/asm/mostek_64.h + delete mode 100644 arch/sparc/include/asm/reboot.h + delete mode 100644 arch/sparc/include/asm/rtc.h + delete mode 100644 arch/sparc/include/asm/sbus.h + delete mode 100644 arch/sparc/include/asm/sbus_32.h + delete mode 100644 arch/sparc/include/asm/sbus_64.h + delete mode 100644 arch/sparc/include/asm/sstate.h + delete mode 100644 arch/sparc/include/asm/sun4paddr.h + delete mode 100644 arch/sparc/include/asm/sun4prom.h + delete mode 100644 arch/sparc/include/asm/vfc_ioctls.h + create mode 100644 arch/sparc/kernel/dma.c + create mode 100644 arch/sparc/kernel/dma.h + delete mode 100644 arch/sparc/kernel/ebus.c + delete mode 100644 arch/sparc/kernel/sun4setup.c + delete mode 100644 arch/sparc/mm/nosrmmu.c + delete mode 100644 arch/sparc/prom/sun4prom.c + create mode 100644 arch/sparc64/kernel/reboot.c + create mode 100644 drivers/hwmon/ultra45_env.c + create mode 100644 drivers/leds/leds-sunfire.c + create mode 100644 drivers/rtc/rtc-bq4802.c + create mode 100644 drivers/rtc/rtc-starfire.c + create mode 100644 drivers/rtc/rtc-sun4v.c + delete mode 100644 drivers/sbus/char/bpp.c + delete mode 100644 drivers/sbus/char/cpwatchdog.c + delete mode 100644 drivers/sbus/char/rtc.c + delete mode 100644 drivers/sbus/char/vfc.h + delete mode 100644 drivers/sbus/char/vfc_dev.c + delete mode 100644 drivers/sbus/char/vfc_i2c.c + delete mode 100644 drivers/sbus/char/vfc_i2c.h + delete mode 100644 drivers/sbus/dvma.c + delete mode 100644 drivers/sbus/sbus.c + create mode 100644 drivers/watchdog/cpwd.c + rename drivers/{sbus/char/riowatchdog.c => watchdog/riowd.c} (51%) +Merging x86/auto-x86-next +$ git merge x86/auto-x86-next +Auto-merged Documentation/kernel-parameters.txt +Auto-merged MAINTAINERS +Auto-merged arch/x86/Kconfig +Auto-merged arch/x86/kernel/cpuid.c +Auto-merged drivers/char/agp/parisc-agp.c +Auto-merged include/asm-x86/cpufeature.h +CONFLICT (content): Merge conflict in include/asm-x86/cpufeature.h +Auto-merged include/asm-x86/kvm_host.h +Removed include/asm-x86/mach-es7000/mach_apicdef.h +Removed include/asm-x86/mach-summit/mach_apicdef.h +Auto-merged include/asm-x86/mce.h +Auto-merged include/asm-x86/msr.h +Auto-merged include/asm-x86/statfs.h +CONFLICT (content): Merge conflict in include/asm-x86/statfs.h +Auto-merged include/asm-x86/xen/hypervisor.h +Resolved 'include/asm-x86/cpufeature.h' using previous resolution. +Resolved 'include/asm-x86/statfs.h' using previous resolution. +Automatic merge failed; fix conflicts and then commit the result. +$ git commit -v -a +Created commit 988014b: Merge commit 'x86/auto-x86-next' +$ git diff -M --stat --summary HEAD^.. + Documentation/00-INDEX | 2 - + Documentation/kernel-parameters.txt | 15 +- + Documentation/x86/00-INDEX | 4 + + Documentation/x86/{i386 => }/boot.txt | 2 +- + Documentation/{ => x86}/mtrr.txt | 4 +- + Documentation/x86/pat.txt | 54 ++- + .../x86/{i386 => }/usb-legacy-support.txt | 0 + Documentation/x86/{i386 => }/zero-page.txt | 0 + MAINTAINERS | 5 + + arch/um/sys-x86_64/syscall_table.c | 4 +- + arch/x86/Kconfig | 120 +++- + arch/x86/Kconfig.cpu | 70 ++ + arch/x86/Kconfig.debug | 13 + + arch/x86/boot/compressed/head_32.S | 5 +- + arch/x86/boot/compressed/misc.c | 12 +- + arch/x86/boot/cpucheck.c | 8 +- + arch/x86/{mach-es7000 => es7000}/Makefile | 0 + arch/x86/{mach-es7000 => es7000}/es7000.h | 18 +- + arch/x86/{mach-es7000 => es7000}/es7000plat.c | 2 +- + arch/x86/ia32/ia32_aout.c | 11 +- + arch/x86/ia32/ia32_signal.c | 72 +- + arch/x86/kernel/Makefile | 10 +- + arch/x86/kernel/acpi/boot.c | 9 +- + arch/x86/kernel/alternative.c | 44 +- + arch/x86/kernel/amd_iommu.c | 2 - + arch/x86/kernel/apic_32.c | 437 +++++++----- + arch/x86/kernel/apic_64.c | 626 ++++++++++++++--- + arch/x86/kernel/apm_32.c | 1 - + arch/x86/kernel/asm-offsets_64.c | 2 +- + arch/x86/kernel/bios_uv.c | 10 +- + arch/x86/kernel/cpu/Makefile | 21 +- + arch/x86/kernel/cpu/addon_cpuid_features.c | 88 +++ + arch/x86/kernel/cpu/cmpxchg.c | 72 ++ + arch/x86/kernel/cpu/common.c | 45 ++- + arch/x86/kernel/cpu/common_64.c | 130 +++- + arch/x86/kernel/cpu/cyrix.c | 16 +- + arch/x86/kernel/cpu/feature_names.c | 7 +- + arch/x86/kernel/cpu/intel.c | 82 +-- + arch/x86/kernel/cpu/intel_64.c | 5 +- + arch/x86/kernel/cpu/intel_cacheinfo.c | 169 ++++- + arch/x86/kernel/cpu/mtrr/main.c | 2 +- + arch/x86/kernel/cpuid.c | 1 - + arch/x86/kernel/crash_dump_64.c | 7 +- + arch/x86/kernel/e820.c | 4 + + arch/x86/kernel/early_printk.c | 762 +++++++++++++++++++- + arch/x86/kernel/entry_64.S | 4 +- + arch/x86/kernel/genapic_64.c | 88 +-- + arch/x86/kernel/genapic_flat_64.c | 62 ++- + arch/x86/kernel/genx2apic_cluster.c | 159 ++++ + arch/x86/kernel/genx2apic_phys.c | 154 ++++ + arch/x86/kernel/genx2apic_uv_x.c | 70 ++- + arch/x86/kernel/i387.c | 154 ++++- + arch/x86/kernel/i8259.c | 24 + + arch/x86/kernel/io_apic_32.c | 47 +- + arch/x86/kernel/io_apic_64.c | 639 +++++++++++++++-- + arch/x86/kernel/ioport.c | 1 + + arch/x86/kernel/ipi.c | 3 +- + arch/x86/kernel/irqinit_32.c | 49 ++ + arch/x86/kernel/kvm.c | 2 +- + arch/x86/kernel/ldt.c | 10 +- + arch/x86/kernel/microcode.c | 634 ++++------------- + arch/x86/kernel/microcode_amd.c | 467 ++++++++++++ + arch/x86/kernel/microcode_intel.c | 489 +++++++++++++ + arch/x86/kernel/mpparse.c | 2 + + arch/x86/kernel/numaq_32.c | 7 + + arch/x86/kernel/paravirt-spinlocks.c | 37 + + arch/x86/kernel/paravirt.c | 30 +- + arch/x86/kernel/paravirt_patch_32.c | 2 +- + arch/x86/kernel/pci-calgary_64.c | 14 + + arch/x86/kernel/pci-dma.c | 148 +---- + arch/x86/kernel/pci-gart_64.c | 76 ++- + arch/x86/kernel/pci-nommu.c | 62 ++ + arch/x86/kernel/process_32.c | 2 + + arch/x86/kernel/process_64.c | 132 ++-- + arch/x86/kernel/ptrace.c | 73 ++- + arch/x86/kernel/setup.c | 18 + + arch/x86/kernel/setup_percpu.c | 9 +- + arch/x86/kernel/sigframe.h | 19 +- + arch/x86/kernel/signal_32.c | 57 +- + arch/x86/kernel/signal_64.c | 201 ++---- + arch/x86/kernel/smpboot.c | 47 +- + arch/x86/kernel/summit_32.c | 2 +- + arch/x86/kernel/sys_i386_32.c | 2 + + arch/x86/kernel/sys_x86_64.c | 44 +- + arch/x86/kernel/syscall_64.c | 4 +- + arch/x86/kernel/time_32.c | 1 + + arch/x86/kernel/tls.c | 1 + + arch/x86/kernel/traps_32.c | 1 - + arch/x86/kernel/traps_64.c | 72 +- + arch/x86/kernel/visws_quirks.c | 16 +- + arch/x86/kernel/vm86_32.c | 1 + + arch/x86/kernel/vmi_32.c | 14 +- + arch/x86/kernel/xsave.c | 316 ++++++++ + arch/x86/lguest/boot.c | 38 +- + arch/x86/lib/string_32.c | 42 +- + arch/x86/lib/strstr_32.c | 6 +- + arch/x86/lib/usercopy_32.c | 7 + + arch/x86/mach-default/setup.c | 19 +- + arch/x86/mach-generic/Makefile | 2 +- + arch/x86/mach-generic/bigsmp.c | 9 +- + arch/x86/mach-generic/es7000.c | 13 +- + arch/x86/mach-generic/numaq.c | 12 +- + arch/x86/mach-generic/summit.c | 11 +- + arch/x86/mm/discontig_32.c | 2 +- + arch/x86/mm/dump_pagetables.c | 4 +- + arch/x86/mm/fault.c | 3 +- + arch/x86/mm/init_32.c | 1 + + arch/x86/mm/init_64.c | 8 +- + arch/x86/mm/ioremap.c | 4 +- + arch/x86/mm/numa_64.c | 10 +- + arch/x86/mm/pageattr-test.c | 7 +- + arch/x86/mm/pageattr.c | 247 +++++-- + arch/x86/mm/pat.c | 4 +- + arch/x86/mm/pgtable_32.c | 3 +- + arch/x86/oprofile/op_model_p4.c | 175 +++--- + arch/x86/pci/acpi.c | 5 - + arch/x86/pci/irq.c | 67 +- + arch/x86/power/hibernate_asm_32.S | 14 +- + arch/x86/xen/Kconfig | 10 +- + arch/x86/xen/Makefile | 12 +- + arch/x86/xen/debugfs.c | 123 ++++ + arch/x86/xen/debugfs.h | 10 + + arch/x86/xen/enlighten.c | 252 ++++---- + arch/x86/xen/irq.c | 143 ++++ + arch/x86/xen/mmu.c | 268 ++++++- + arch/x86/xen/multicalls.c | 115 +++- + arch/x86/xen/smp.c | 167 ----- + arch/x86/xen/spinlock.c | 423 +++++++++++ + arch/x86/xen/time.c | 4 +- + arch/x86/xen/xen-asm_32.S | 2 +- + arch/x86/xen/xen-asm_64.S | 2 +- + arch/x86/xen/xen-ops.h | 6 + + drivers/block/xen-blkfront.c | 2 +- + drivers/char/agp/agp.h | 5 + + drivers/char/agp/alpha-agp.c | 2 + + drivers/char/agp/amd-k7-agp.c | 2 + + drivers/char/agp/amd64-agp.c | 2 + + drivers/char/agp/ati-agp.c | 2 + + drivers/char/agp/efficeon-agp.c | 2 + + drivers/char/agp/generic.c | 97 +++- + drivers/char/agp/hp-agp.c | 2 + + drivers/char/agp/i460-agp.c | 2 + + drivers/char/agp/intel-agp.c | 28 + + drivers/char/agp/nvidia-agp.c | 2 + + drivers/char/agp/parisc-agp.c | 2 + + drivers/char/agp/sis-agp.c | 2 + + drivers/char/agp/sworks-agp.c | 2 + + drivers/char/agp/uninorth-agp.c | 4 + + drivers/char/agp/via-agp.c | 4 + + drivers/char/hvc_xen.c | 6 +- + drivers/input/xen-kbdfront.c | 4 +- + drivers/net/xen-netfront.c | 6 +- + drivers/pci/Makefile | 2 + + drivers/pci/dma_remapping.h | 157 ++++ + drivers/pci/dmar.c | 397 ++++++++++- + drivers/pci/intel-iommu.c | 164 +---- + drivers/pci/intel-iommu.h | 233 +++---- + drivers/pci/intr_remapping.c | 471 ++++++++++++ + drivers/pci/intr_remapping.h | 8 + + drivers/usb/host/ehci.h | 138 +---- + drivers/video/xen-fbfront.c | 4 +- + drivers/xen/balloon.c | 176 +---- + drivers/xen/events.c | 36 +- + drivers/xen/grant-table.c | 2 +- + drivers/xen/xenbus/xenbus_probe.c | 8 +- + include/asm-x86/a.out-core.h | 6 +- + include/asm-x86/a.out.h | 6 +- + include/asm-x86/acpi.h | 6 +- + include/asm-x86/agp.h | 6 +- + include/asm-x86/alternative.h | 6 +- + include/asm-x86/amd_iommu.h | 6 +- + include/asm-x86/amd_iommu_types.h | 6 +- + include/asm-x86/apic.h | 80 ++- + include/asm-x86/apicdef.h | 9 +- + include/asm-x86/arch_hooks.h | 8 +- + include/asm-x86/asm.h | 13 +- + include/asm-x86/atomic_32.h | 6 +- + include/asm-x86/atomic_64.h | 6 +- + include/asm-x86/auxvec.h | 6 +- + .../{mach-bigsmp/mach_apic.h => bigsmp/apic.h} | 4 +- + .../mach_apicdef.h => bigsmp/apicdef.h} | 6 +- + .../{mach-bigsmp/mach_ipi.h => bigsmp/ipi.h} | 0 + include/asm-x86/bios_ebda.h | 6 +- + include/asm-x86/bitops.h | 6 +- + include/asm-x86/boot.h | 6 +- + include/asm-x86/bootparam.h | 6 +- + include/asm-x86/bug.h | 6 +- + include/asm-x86/bugs.h | 11 +- + include/asm-x86/byteorder.h | 6 +- + include/asm-x86/cache.h | 6 +- + include/asm-x86/cacheflush.h | 9 +- + include/asm-x86/calgary.h | 6 +- + include/asm-x86/checksum_32.h | 6 +- + include/asm-x86/checksum_64.h | 6 +- + include/asm-x86/cmpxchg_32.h | 6 +- + include/asm-x86/cmpxchg_64.h | 6 +- + include/asm-x86/compat.h | 6 +- + include/asm-x86/cpu.h | 6 +- + include/asm-x86/cpufeature.h | 22 +- + include/asm-x86/current.h | 6 +- + include/asm-x86/debugreg.h | 6 +- + include/asm-x86/delay.h | 6 +- + include/asm-x86/desc.h | 21 +- + include/asm-x86/desc_defs.h | 6 +- + include/asm-x86/device.h | 6 +- + include/asm-x86/div64.h | 6 +- + include/asm-x86/dma-mapping.h | 56 +- + include/asm-x86/dma.h | 6 +- + include/asm-x86/dmi.h | 6 +- + include/asm-x86/ds.h | 6 +- + include/asm-x86/dwarf2.h | 6 +- + include/asm-x86/e820.h | 8 +- + include/asm-x86/edac.h | 6 +- + include/asm-x86/efi.h | 6 +- + include/asm-x86/elf.h | 11 +- + include/asm-x86/emergency-restart.h | 6 +- + .../{mach-es7000/mach_apic.h => es7000/apic.h} | 32 +- + include/asm-x86/es7000/apicdef.h | 13 + + .../{mach-es7000/mach_ipi.h => es7000/ipi.h} | 6 +- + .../mach_mpparse.h => es7000/mpparse.h} | 4 +- + .../mach_wakecpu.h => es7000/wakecpu.h} | 6 +- + include/asm-x86/fb.h | 6 +- + include/asm-x86/fixmap.h | 6 +- + include/asm-x86/fixmap_32.h | 6 +- + include/asm-x86/fixmap_64.h | 6 +- + include/asm-x86/floppy.h | 6 +- + include/asm-x86/ftrace.h | 6 +- + include/asm-x86/futex.h | 12 +- + include/asm-x86/gart.h | 6 +- + include/asm-x86/genapic_32.h | 6 +- + include/asm-x86/genapic_64.h | 14 +- + include/asm-x86/geode.h | 6 +- + include/asm-x86/gpio.h | 2 +- + include/asm-x86/hardirq_32.h | 6 +- + include/asm-x86/hardirq_64.h | 6 +- + include/asm-x86/highmem.h | 6 +- + include/asm-x86/hpet.h | 6 +- + include/asm-x86/hugetlb.h | 6 +- + include/asm-x86/hw_irq.h | 29 +- + include/asm-x86/hypertransport.h | 6 +- + include/asm-x86/i387.h | 91 ++- + include/asm-x86/i8253.h | 6 +- + include/asm-x86/i8259.h | 9 +- + include/asm-x86/ia32.h | 6 +- + include/asm-x86/ia32_unistd.h | 6 +- + include/asm-x86/idle.h | 6 +- + include/asm-x86/intel_arch_perfmon.h | 6 +- + include/asm-x86/io.h | 8 +- + include/asm-x86/io_32.h | 6 +- + include/asm-x86/io_64.h | 7 +- + include/asm-x86/io_apic.h | 26 +- + include/asm-x86/ioctls.h | 6 +- + include/asm-x86/iommu.h | 6 +- + include/asm-x86/ipcbuf.h | 6 +- + include/asm-x86/ipi.h | 22 +- + include/asm-x86/irq.h | 6 +- + include/asm-x86/irq_regs_32.h | 6 +- + include/asm-x86/irq_remapping.h | 8 + + include/asm-x86/irq_vectors.h | 6 +- + include/asm-x86/ist.h | 6 +- + include/asm-x86/k8.h | 6 +- + include/asm-x86/kdebug.h | 6 +- + include/asm-x86/kexec.h | 6 +- + include/asm-x86/kgdb.h | 6 +- + include/asm-x86/kmap_types.h | 6 +- + include/asm-x86/kprobes.h | 6 +- + include/asm-x86/kvm.h | 6 +- + include/asm-x86/kvm_host.h | 8 +- + include/asm-x86/kvm_para.h | 6 +- + include/asm-x86/kvm_x86_emulate.h | 6 +- + include/asm-x86/ldt.h | 6 +- + include/asm-x86/lguest.h | 6 +- + include/asm-x86/lguest_hcall.h | 6 +- + include/asm-x86/linkage.h | 6 +- + include/asm-x86/local.h | 6 +- + include/asm-x86/mach-default/apm.h | 6 +- + include/asm-x86/mach-default/mach_apic.h | 10 +- + include/asm-x86/mach-default/mach_apicdef.h | 12 +- + include/asm-x86/mach-default/mach_ipi.h | 6 +- + include/asm-x86/mach-default/mach_mpparse.h | 6 +- + include/asm-x86/mach-default/mach_mpspec.h | 6 +- + include/asm-x86/mach-default/mach_timer.h | 6 +- + include/asm-x86/mach-default/mach_traps.h | 6 +- + include/asm-x86/mach-default/mach_wakecpu.h | 6 +- + include/asm-x86/mach-es7000/mach_apicdef.h | 13 - + include/asm-x86/mach-generic/gpio.h | 6 +- + include/asm-x86/mach-generic/irq_vectors_limits.h | 6 +- + include/asm-x86/mach-generic/mach_apic.h | 6 +- + include/asm-x86/mach-generic/mach_apicdef.h | 6 +- + include/asm-x86/mach-generic/mach_ipi.h | 6 +- + include/asm-x86/mach-generic/mach_mpparse.h | 6 +- + include/asm-x86/mach-generic/mach_mpspec.h | 6 +- + include/asm-x86/mach-rdc321x/gpio.h | 6 +- + include/asm-x86/mach-summit/mach_apicdef.h | 13 - + include/asm-x86/math_emu.h | 6 +- + include/asm-x86/mc146818rtc.h | 6 +- + include/asm-x86/mca.h | 6 +- + include/asm-x86/mca_dma.h | 6 +- + include/asm-x86/mce.h | 6 +- + include/asm-x86/microcode.h | 99 +++ + include/asm-x86/mman.h | 6 +- + include/asm-x86/mmconfig.h | 6 +- + include/asm-x86/mmu.h | 6 +- + include/asm-x86/mmu_context.h | 6 +- + include/asm-x86/mmu_context_32.h | 6 +- + include/asm-x86/mmu_context_64.h | 6 +- + include/asm-x86/mmx.h | 6 +- + include/asm-x86/mmzone_32.h | 6 +- + include/asm-x86/mmzone_64.h | 6 +- + include/asm-x86/module.h | 6 +- + include/asm-x86/mpspec.h | 9 +- + include/asm-x86/mpspec_def.h | 6 +- + include/asm-x86/msgbuf.h | 6 +- + include/asm-x86/msidef.h | 10 +- + include/asm-x86/msr-index.h | 6 +- + include/asm-x86/msr.h | 29 +- + include/asm-x86/mtrr.h | 6 +- + include/asm-x86/mutex_32.h | 6 +- + include/asm-x86/mutex_64.h | 6 +- + include/asm-x86/nmi.h | 6 +- + include/asm-x86/nops.h | 6 +- + include/asm-x86/numa_32.h | 6 +- + include/asm-x86/numa_64.h | 6 +- + include/asm-x86/numaq.h | 6 +- + .../{mach-numaq/mach_apic.h => numaq/apic.h} | 6 +- + .../{mach-numaq/mach_apicdef.h => numaq/apicdef.h} | 4 +- + .../asm-x86/{mach-numaq/mach_ipi.h => numaq/ipi.h} | 6 +- + .../{mach-numaq/mach_mpparse.h => numaq/mpparse.h} | 6 +- + .../{mach-numaq/mach_wakecpu.h => numaq/wakecpu.h} | 6 +- + include/asm-x86/olpc.h | 6 +- + include/asm-x86/page.h | 6 +- + include/asm-x86/page_32.h | 10 +- + include/asm-x86/page_64.h | 7 +- + include/asm-x86/param.h | 6 +- + include/asm-x86/paravirt.h | 87 ++- + include/asm-x86/parport.h | 6 +- + include/asm-x86/pat.h | 6 +- + include/asm-x86/pci-direct.h | 6 +- + include/asm-x86/pci.h | 6 +- + include/asm-x86/pci_32.h | 6 +- + include/asm-x86/pci_64.h | 6 +- + include/asm-x86/pda.h | 6 +- + include/asm-x86/percpu.h | 6 +- + include/asm-x86/pgalloc.h | 6 +- + include/asm-x86/pgtable-2level-defs.h | 6 +- + include/asm-x86/pgtable-2level.h | 6 +- + include/asm-x86/pgtable-3level-defs.h | 6 +- + include/asm-x86/pgtable-3level.h | 6 +- + include/asm-x86/pgtable.h | 8 +- + include/asm-x86/pgtable_32.h | 12 +- + include/asm-x86/pgtable_64.h | 6 +- + include/asm-x86/posix_types_32.h | 6 +- + include/asm-x86/posix_types_64.h | 6 +- + include/asm-x86/prctl.h | 6 +- + include/asm-x86/processor-cyrix.h | 8 + + include/asm-x86/processor-flags.h | 7 +- + include/asm-x86/processor.h | 66 +- + include/asm-x86/proto.h | 6 +- + include/asm-x86/ptrace-abi.h | 6 +- + include/asm-x86/ptrace.h | 14 +- + include/asm-x86/pvclock-abi.h | 6 +- + include/asm-x86/pvclock.h | 6 +- + include/asm-x86/reboot.h | 6 +- + include/asm-x86/reboot_fixups.h | 6 +- + include/asm-x86/required-features.h | 14 +- + include/asm-x86/resume-trace.h | 8 +- + include/asm-x86/rio.h | 6 +- + include/asm-x86/rwlock.h | 6 +- + include/asm-x86/rwsem.h | 6 +- + include/asm-x86/scatterlist.h | 6 +- + include/asm-x86/seccomp_32.h | 6 +- + include/asm-x86/seccomp_64.h | 6 +- + include/asm-x86/segment.h | 6 +- + include/asm-x86/sembuf.h | 6 +- + include/asm-x86/serial.h | 6 +- + include/asm-x86/setup.h | 8 +- + include/asm-x86/shmbuf.h | 6 +- + include/asm-x86/shmparam.h | 6 +- + include/asm-x86/sigcontext.h | 93 +++- + include/asm-x86/sigcontext32.h | 12 +- + include/asm-x86/siginfo.h | 6 +- + include/asm-x86/signal.h | 9 +- + include/asm-x86/smp.h | 27 +- + include/asm-x86/socket.h | 6 +- + include/asm-x86/sockios.h | 6 +- + include/asm-x86/sparsemem.h | 6 +- + include/asm-x86/spinlock.h | 21 +- + include/asm-x86/spinlock_types.h | 6 +- + include/asm-x86/srat.h | 6 +- + include/asm-x86/stacktrace.h | 6 +- + include/asm-x86/stat.h | 6 +- + include/asm-x86/statfs.h | 6 +- + include/asm-x86/string_32.h | 6 +- + include/asm-x86/string_64.h | 6 +- + .../{mach-summit/mach_apic.h => summit/apic.h} | 24 +- + include/asm-x86/summit/apicdef.h | 13 + + .../{mach-summit/mach_ipi.h => summit/ipi.h} | 6 +- + .../{mach-summit => summit}/irq_vectors_limits.h | 0 + .../mach_mpparse.h => summit/mpparse.h} | 13 +- + include/asm-x86/suspend_32.h | 6 +- + include/asm-x86/suspend_64.h | 6 +- + include/asm-x86/swiotlb.h | 6 +- + include/asm-x86/sync_bitops.h | 6 +- + include/asm-x86/syscall.h | 210 ++++++ + include/asm-x86/syscalls.h | 93 +++ + include/asm-x86/system.h | 6 +- + include/asm-x86/system_64.h | 6 +- + include/asm-x86/tce.h | 6 +- + include/asm-x86/termbits.h | 6 +- + include/asm-x86/termios.h | 6 +- + include/asm-x86/therm_throt.h | 6 +- + include/asm-x86/thread_info.h | 11 +- + include/asm-x86/time.h | 8 +- + include/asm-x86/timer.h | 11 +- + include/asm-x86/timex.h | 6 +- + include/asm-x86/tlb.h | 6 +- + include/asm-x86/tlbflush.h | 6 +- + include/asm-x86/topology.h | 6 +- + include/asm-x86/trampoline.h | 6 +- + include/asm-x86/traps.h | 10 +- + include/asm-x86/tsc.h | 6 +- + include/asm-x86/types.h | 6 +- + include/asm-x86/uaccess.h | 6 +- + include/asm-x86/uaccess_32.h | 6 +- + include/asm-x86/uaccess_64.h | 6 +- + include/asm-x86/ucontext.h | 12 +- + include/asm-x86/unaligned.h | 6 +- + include/asm-x86/unistd_32.h | 6 +- + include/asm-x86/unistd_64.h | 6 +- + include/asm-x86/unwind.h | 6 +- + include/asm-x86/user32.h | 6 +- + include/asm-x86/user_32.h | 6 +- + include/asm-x86/user_64.h | 6 +- + include/asm-x86/uv/bios.h | 6 +- + include/asm-x86/uv/uv_bau.h | 6 +- + include/asm-x86/uv/uv_hub.h | 6 +- + include/asm-x86/uv/uv_mmrs.h | 6 +- + include/asm-x86/vdso.h | 6 +- + include/asm-x86/vga.h | 6 +- + include/asm-x86/vgtod.h | 6 +- + include/asm-x86/visws/cobalt.h | 6 +- + include/asm-x86/visws/lithium.h | 6 +- + include/asm-x86/visws/piix4.h | 6 +- + include/asm-x86/vm86.h | 6 +- + include/asm-x86/vmi_time.h | 6 +- + include/asm-x86/vsyscall.h | 6 +- + include/asm-x86/xcr.h | 49 ++ + include/asm-x86/xen/events.h | 6 +- + include/asm-x86/xen/grant_table.h | 6 +- + include/asm-x86/xen/hypercall.h | 6 +- + include/asm-x86/xen/hypervisor.h | 20 +- + include/asm-x86/xen/interface.h | 6 +- + include/asm-x86/xen/interface_32.h | 6 +- + include/asm-x86/xen/interface_64.h | 6 +- + include/asm-x86/xen/page.h | 6 +- + include/asm-x86/xsave.h | 118 +++ + include/linux/dmar.h | 127 +++- + include/linux/elf.h | 1 + + include/linux/irq.h | 1 + + include/linux/kernel.h | 2 +- + include/linux/usb/ehci_def.h | 160 ++++ + include/xen/events.h | 2 + + kernel/dma-coherent.c | 2 + + kernel/irq/manage.c | 9 +- + lib/cmdline.c | 2 +- + mm/highmem.c | 5 +- + 466 files changed, 10976 insertions(+), 4075 deletions(-) + create mode 100644 Documentation/x86/00-INDEX + rename Documentation/x86/{i386 => }/boot.txt (99%) + rename Documentation/{ => x86}/mtrr.txt (99%) + rename Documentation/x86/{i386 => }/usb-legacy-support.txt (100%) + rename Documentation/x86/{i386 => }/zero-page.txt (100%) + rename arch/x86/{mach-es7000 => es7000}/Makefile (100%) + rename arch/x86/{mach-es7000 => es7000}/es7000.h (89%) + rename arch/x86/{mach-es7000 => es7000}/es7000plat.c (99%) + create mode 100644 arch/x86/kernel/cpu/cmpxchg.c + create mode 100644 arch/x86/kernel/genx2apic_cluster.c + create mode 100644 arch/x86/kernel/genx2apic_phys.c + create mode 100644 arch/x86/kernel/microcode_amd.c + create mode 100644 arch/x86/kernel/microcode_intel.c + create mode 100644 arch/x86/kernel/paravirt-spinlocks.c + create mode 100644 arch/x86/kernel/xsave.c + create mode 100644 arch/x86/xen/debugfs.c + create mode 100644 arch/x86/xen/debugfs.h + create mode 100644 arch/x86/xen/irq.c + create mode 100644 arch/x86/xen/spinlock.c + create mode 100644 drivers/pci/dma_remapping.h + create mode 100644 drivers/pci/intr_remapping.c + create mode 100644 drivers/pci/intr_remapping.h + rename include/asm-x86/{mach-bigsmp/mach_apic.h => bigsmp/apic.h} (98%) + rename include/asm-x86/{mach-bigsmp/mach_apicdef.h => bigsmp/apicdef.h} (74%) + rename include/asm-x86/{mach-bigsmp/mach_ipi.h => bigsmp/ipi.h} (100%) + rename include/asm-x86/{mach-es7000/mach_apic.h => es7000/apic.h} (92%) + create mode 100644 include/asm-x86/es7000/apicdef.h + rename include/asm-x86/{mach-es7000/mach_ipi.h => es7000/ipi.h} (83%) + rename include/asm-x86/{mach-es7000/mach_mpparse.h => es7000/mpparse.h} (91%) + rename include/asm-x86/{mach-es7000/mach_wakecpu.h => es7000/wakecpu.h} (95%) + create mode 100644 include/asm-x86/irq_remapping.h + delete mode 100644 include/asm-x86/mach-es7000/mach_apicdef.h + delete mode 100644 include/asm-x86/mach-summit/mach_apicdef.h + create mode 100644 include/asm-x86/microcode.h + rename include/asm-x86/{mach-numaq/mach_apic.h => numaq/apic.h} (97%) + rename include/asm-x86/{mach-numaq/mach_apicdef.h => numaq/apicdef.h} (75%) + rename include/asm-x86/{mach-numaq/mach_ipi.h => numaq/ipi.h} (83%) + rename include/asm-x86/{mach-numaq/mach_mpparse.h => numaq/mpparse.h} (50%) + rename include/asm-x86/{mach-numaq/mach_wakecpu.h => numaq/wakecpu.h} (91%) + rename include/asm-x86/{mach-summit/mach_apic.h => summit/apic.h} (94%) + create mode 100644 include/asm-x86/summit/apicdef.h + rename include/asm-x86/{mach-summit/mach_ipi.h => summit/ipi.h} (83%) + rename include/asm-x86/{mach-summit => summit}/irq_vectors_limits.h (100%) + rename include/asm-x86/{mach-summit/mach_mpparse.h => summit/mpparse.h} (96%) + create mode 100644 include/asm-x86/syscall.h + create mode 100644 include/asm-x86/syscalls.h + create mode 100644 include/asm-x86/xcr.h + create mode 100644 include/asm-x86/xsave.h + create mode 100644 include/linux/usb/ehci_def.h +Merging xtensa/master +$ git merge xtensa/master +Merge made by recursive. + arch/xtensa/kernel/irq.c | 2 +- + arch/xtensa/kernel/setup.c | 5 ----- + arch/xtensa/platforms/iss/network.c | 2 +- + include/asm-xtensa/rwsem.h | 4 ++++ + 4 files changed, 6 insertions(+), 7 deletions(-) +Merging quilt/driver-core +$ git merge quilt/driver-core +Auto-merged Documentation/kernel-parameters.txt +Auto-merged arch/x86/kernel/cpuid.c +Auto-merged arch/x86/kernel/traps_32.c +Auto-merged arch/x86/kernel/traps_64.c +Auto-merged drivers/firmware/iscsi_ibft.c +Auto-merged drivers/mtd/mtdchar.c +Auto-merged include/linux/kernel.h +Merge made by recursive. + Documentation/kernel-parameters.txt | 5 + + Documentation/kobject.txt | 4 + + arch/mips/kernel/rtlx.c | 4 +- + arch/mips/sibyte/common/sb_tbprof.c | 3 +- + arch/x86/kernel/cpuid.c | 4 +- + arch/x86/kernel/msr.c | 4 +- + arch/x86/kernel/traps_32.c | 1 + + arch/x86/kernel/traps_64.c | 1 + + block/bsg.c | 3 +- + drivers/base/base.h | 2 +- + drivers/base/bus.c | 50 +++ + drivers/base/class.c | 136 +++++++-- + drivers/base/core.c | 11 +- + drivers/base/platform.c | 2 +- + drivers/block/aoe/aoechr.c | 6 +- + drivers/block/paride/pg.c | 5 +- + drivers/block/paride/pt.c | 10 +- + drivers/block/pktcdvd.c | 5 +- + drivers/char/bsr.c | 5 +- + drivers/char/dsp56k.c | 4 +- + drivers/char/ip2/ip2main.c | 12 +- + drivers/char/ipmi/ipmi_devintf.c | 2 +- + drivers/char/istallion.c | 5 +- + drivers/char/lp.c | 4 +- + drivers/char/mem.c | 6 +- + drivers/char/misc.c | 4 +- + drivers/char/pcmcia/cm4000_cs.c | 2 +- + drivers/char/pcmcia/cm4040_cs.c | 3 +- + drivers/char/ppdev.c | 5 +- + drivers/char/raw.c | 7 +- + drivers/char/snsc.c | 4 +- + drivers/char/stallion.c | 4 +- + drivers/char/tty_io.c | 12 +- + drivers/char/vc_screen.c | 12 +- + drivers/char/viotape.c | 8 +- + drivers/char/vt.c | 14 +- + drivers/char/xilinx_hwicap/xilinx_hwicap.c | 3 +- + drivers/dca/dca-sysfs.c | 8 +- + drivers/firmware/iscsi_ibft.c | 18 +- + drivers/hid/hidraw.c | 5 +- + drivers/hwmon/hwmon.c | 4 +- + drivers/i2c/i2c-dev.c | 6 +- + drivers/ide/ide-probe.c | 4 +- + drivers/ide/ide-tape.c | 11 +- + drivers/ieee1394/dv1394.c | 8 +- + drivers/ieee1394/raw1394.c | 8 +- + drivers/ieee1394/video1394.c | 5 +- + drivers/infiniband/core/cm.c | 6 +- + drivers/infiniband/core/user_mad.c | 12 +- + drivers/infiniband/core/uverbs_main.c | 9 +- + drivers/infiniband/hw/ipath/ipath_file_ops.c | 2 +- + drivers/isdn/capi/capi.c | 3 +- + drivers/leds/led-class.c | 4 +- + drivers/macintosh/adb.c | 3 +- + drivers/media/dvb/dvb-core/dvbdev.c | 2 +- + drivers/misc/phantom.c | 6 +- + drivers/mtd/mtdchar.c | 10 +- + drivers/net/phy/phy_device.c | 8 +- + drivers/net/ppp_generic.c | 4 +- + drivers/net/wan/cosa.c | 4 +- + drivers/net/wireless/mac80211_hwsim.c | 6 +- + drivers/pci/probe.c | 50 +--- + drivers/power/power_supply_core.c | 4 +- + drivers/s390/char/raw3270.c | 14 +- + drivers/s390/char/tape_class.c | 6 +- + drivers/s390/char/vmlogrdr.c | 8 +- + drivers/s390/char/vmur.c | 5 +- + drivers/scsi/ch.c | 6 +- + drivers/scsi/dpt_i2o.c | 2 +- + drivers/scsi/osst.c | 3 +- + drivers/scsi/sg.c | 10 +- + drivers/scsi/st.c | 11 +- + drivers/spi/spidev.c | 7 +- + drivers/uio/uio.c | 6 +- + drivers/usb/core/devio.c | 6 +- + drivers/usb/core/file.c | 6 +- + drivers/usb/core/hcd.c | 5 +- + drivers/usb/gadget/Makefile | 23 +- + drivers/usb/gadget/cdc2.c | 25 ++- + drivers/usb/gadget/ether.c | 28 ++- + drivers/usb/gadget/f_ecm.c | 108 ++++---- + drivers/usb/gadget/f_loopback.c | 34 ++- + drivers/usb/gadget/f_subset.c | 44 ++-- + drivers/usb/gadget/file_storage.c | 12 + + drivers/usb/gadget/gmidi.c | 15 + + drivers/usb/gadget/printer.c | 18 +- + drivers/usb/gadget/rndis.c | 115 ++++---- + drivers/usb/gadget/serial.c | 18 ++ + drivers/usb/gadget/u_ether.c | 4 +- + drivers/usb/gadget/zero.c | 17 + + drivers/usb/misc/phidgetkit.c | 5 +- + drivers/usb/misc/phidgetmotorcontrol.c | 5 +- + drivers/usb/misc/phidgetservo.c | 5 +- + drivers/usb/mon/mon_bin.c | 6 +- + drivers/video/console/fbcon.c | 4 +- + drivers/video/display/display-sysfs.c | 9 +- + drivers/video/fbmem.c | 5 +- + fs/coda/psdev.c | 5 +- + fs/sysfs/dir.c | 245 +++++++++++---- + fs/sysfs/file.c | 88 ++++-- + fs/sysfs/inode.c | 23 +- + fs/sysfs/mount.c | 94 ++++++- + fs/sysfs/sysfs.h | 20 +- + include/asm-generic/vmlinux.lds.h | 10 +- + include/linux/device.h | 24 ++- + include/linux/dynamic_printk.h | 93 ++++++ + include/linux/init.h | 1 + + include/linux/kernel.h | 7 +- + include/linux/klist.h | 3 +- + include/linux/module.h | 4 + + include/linux/sysfs.h | 31 ++- + init/main.c | 9 + + kernel/module.c | 37 +++ + lib/Kconfig.debug | 55 ++++ + lib/Makefile | 2 + + lib/dynamic_printk.c | 418 ++++++++++++++++++++++++++ + lib/klist.c | 96 +++++-- + lib/kobject.c | 85 +++++- + net/netfilter/nf_conntrack_pptp.c | 2 +- + scripts/Makefile.lib | 11 +- + scripts/basic/Makefile | 2 +- + scripts/basic/hash.c | 64 ++++ + sound/core/init.c | 6 +- + sound/core/sound.c | 5 +- + sound/oss/soundcard.c | 15 +- + sound/sound_core.c | 5 +- + 126 files changed, 1940 insertions(+), 697 deletions(-) + create mode 100644 include/linux/dynamic_printk.h + create mode 100644 lib/dynamic_printk.c + create mode 100644 scripts/basic/hash.c +Merging quilt/usb +$ git merge quilt/usb +Auto-merged drivers/media/video/dabusb.c +Merge made by recursive. + Documentation/DocBook/gadget.tmpl | 3 + + drivers/block/ub.c | 3 - + drivers/hid/usbhid/hid-core.c | 20 +- + drivers/hid/usbhid/hid-tmff.c | 19 +- + drivers/hid/usbhid/usbkbd.c | 12 +- + drivers/hid/usbhid/usbmouse.c | 3 +- + drivers/input/joystick/iforce/iforce-ff.c | 36 +- + drivers/input/joystick/iforce/iforce-main.c | 14 +- + drivers/input/joystick/iforce/iforce-packets.c | 8 +- + drivers/input/joystick/iforce/iforce-usb.c | 2 +- + drivers/input/joystick/xpad.c | 2 +- + drivers/input/misc/ati_remote.c | 20 +- + drivers/input/misc/yealink.c | 3 +- + drivers/input/tablet/acecad.c | 3 +- + drivers/input/tablet/aiptek.c | 26 +- + drivers/input/tablet/gtco.c | 4 +- + drivers/input/tablet/kbtab.c | 3 +- + drivers/input/tablet/wacom_sys.c | 3 +- + drivers/media/dvb/cinergyT2/cinergyT2.c | 3 +- + drivers/media/radio/dsbr100.c | 16 +- + drivers/media/video/dabusb.c | 7 +- + drivers/media/video/ov511.c | 124 +++--- + drivers/media/video/ov511.h | 3 +- + drivers/media/video/pvrusb2/pvrusb2-main.c | 8 +- + drivers/media/video/se401.c | 37 +- + drivers/media/video/stv680.c | 6 +- + drivers/media/video/usbvideo/ibmcam.c | 78 ++-- + drivers/media/video/usbvideo/konicawc.c | 25 +- + drivers/media/video/usbvideo/quickcam_messenger.c | 17 +- + drivers/media/video/usbvideo/ultracam.c | 29 +- + drivers/media/video/usbvideo/usbvideo.c | 163 +++++--- + drivers/media/video/usbvision/usbvision-core.c | 3 +- + drivers/media/video/usbvision/usbvision-i2c.c | 3 +- + drivers/media/video/usbvision/usbvision-video.c | 3 +- + drivers/media/video/zr364xx.c | 50 ++- + drivers/mtd/nand/alauda.c | 4 +- + drivers/net/irda/kingsun-sir.c | 3 +- + drivers/net/irda/ks959-sir.c | 3 +- + drivers/net/irda/ksdazzle-sir.c | 3 +- + drivers/net/irda/stir4200.c | 18 +- + drivers/net/usb/catc.c | 8 +- + drivers/net/usb/hso.c | 26 +- + drivers/net/usb/kaweth.c | 27 +- + drivers/net/usb/rtl8150.c | 31 +- + drivers/usb/atm/usbatm.c | 10 +- + drivers/usb/atm/usbatm.h | 10 +- + drivers/usb/atm/xusbatm.c | 2 +- + drivers/usb/class/cdc-acm.c | 3 +- + drivers/usb/class/usblp.c | 18 +- + drivers/usb/core/devio.c | 3 +- + drivers/usb/core/inode.c | 6 +- + drivers/usb/core/message.c | 3 +- + drivers/usb/core/urb.c | 95 ++++- + drivers/usb/gadget/Kconfig | 273 +++++++----- + drivers/usb/gadget/composite.c | 64 +++ + drivers/usb/gadget/dummy_hcd.c | 33 ++- + drivers/usb/gadget/f_obex.c | 493 +++++++++++++++++++++ + drivers/usb/gadget/file_storage.c | 10 +- + drivers/usb/gadget/fsl_usb2_udc.c | 176 ++++---- + drivers/usb/gadget/fsl_usb2_udc.h | 21 +- + drivers/usb/gadget/net2280.c | 40 ++- + drivers/usb/gadget/net2280.h | 1 + + drivers/usb/gadget/serial.c | 14 + + drivers/usb/gadget/u_serial.h | 1 + + drivers/usb/host/isp116x-hcd.c | 13 +- + drivers/usb/host/r8a66597-hcd.c | 54 ++- + drivers/usb/host/sl811-hcd.c | 15 +- + drivers/usb/image/mdc800.c | 15 +- + drivers/usb/misc/Kconfig | 10 + + drivers/usb/misc/Makefile | 1 + + drivers/usb/misc/adutux.c | 5 +- + drivers/usb/misc/cytherm.c | 3 +- + drivers/usb/misc/emi26.c | 4 +- + drivers/usb/misc/emi62.c | 4 +- + drivers/usb/misc/gotemp.c | 301 +++++++++++++ + drivers/usb/misc/idmouse.c | 5 +- + drivers/usb/misc/legousbtower.c | 23 +- + drivers/usb/misc/rio500.c | 11 +- + drivers/usb/misc/trancevibrator.c | 3 +- + drivers/usb/misc/usblcd.c | 13 +- + drivers/usb/misc/uss720.c | 19 +- + drivers/usb/serial/aircable.c | 11 +- + drivers/usb/serial/belkin_sa.c | 39 +- + drivers/usb/serial/cp2101.c | 3 +- + drivers/usb/serial/cyberjack.c | 28 +- + drivers/usb/serial/cypress_m8.c | 21 +- + drivers/usb/serial/digi_acceleport.c | 68 ++-- + drivers/usb/serial/empeg.c | 11 +- + drivers/usb/serial/ezusb.c | 3 +- + drivers/usb/serial/ftdi_sio.c | 90 +++-- + drivers/usb/serial/garmin_gps.c | 3 +- + drivers/usb/serial/hp4x.c | 3 +- + drivers/usb/serial/io_edgeport.c | 19 +- + drivers/usb/serial/io_ti.c | 3 +- + drivers/usb/serial/ipaq.c | 30 +- + drivers/usb/serial/ipw.c | 3 +- + drivers/usb/serial/ir-usb.c | 3 +- + drivers/usb/serial/iuu_phoenix.c | 3 +- + drivers/usb/serial/keyspan.c | 3 +- + drivers/usb/serial/keyspan_pda.c | 22 +- + drivers/usb/serial/kl5kusb105.c | 69 ++-- + drivers/usb/serial/kobil_sct.c | 4 +- + drivers/usb/serial/mct_u232.c | 42 ++- + drivers/usb/serial/mos7720.c | 22 +- + drivers/usb/serial/mos7840.c | 29 +- + drivers/usb/serial/omninet.c | 22 +- + drivers/usb/serial/option.c | 3 +- + drivers/usb/serial/pl2303.c | 2 +- + drivers/usb/serial/safe_serial.c | 28 +- + drivers/usb/serial/sierra.c | 3 +- + drivers/usb/serial/spcp8x5.c | 10 +- + drivers/usb/serial/ti_usb_3410_5052.c | 3 +- + drivers/usb/serial/usb-serial.c | 26 +- + drivers/usb/serial/visor.c | 17 +- + drivers/usb/serial/whiteheat.c | 121 +++-- + include/linux/usb.h | 8 +- + include/linux/usb/cdc.h | 9 + + include/linux/usb/composite.h | 11 +- + 118 files changed, 2432 insertions(+), 1020 deletions(-) + create mode 100644 drivers/usb/gadget/f_obex.c + create mode 100644 drivers/usb/misc/gotemp.c +Merging tip-core/auto-core-next +$ git merge tip-core/auto-core-next +Auto-merged arch/x86/kernel/cpu/common.c +Auto-merged include/asm-generic/vmlinux.lds.h +Auto-merged include/asm-x86/percpu.h +Auto-merged include/linux/kernel.h +Auto-merged kernel/lockdep.c +Auto-merged kernel/module.c +Auto-merged kernel/softlockup.c +Auto-merged kernel/time/tick-sched.c +Auto-merged lib/Kconfig.debug +Auto-merged mm/filemap.c +Merge made by recursive. + arch/x86/boot/boot.h | 3 - + arch/x86/kernel/cpu/common.c | 2 +- + arch/x86/kernel/vmlinux_32.lds.S | 1 + + include/asm-generic/percpu.h | 11 ++++- + include/asm-generic/sections.h | 10 ++++ + include/asm-generic/vmlinux.lds.h | 17 ++++++++ + include/asm-x86/percpu.h | 83 ++++++++++++++++++++++++++++++++++-- + include/linux/compiler.h | 30 +++++++++++++ + include/linux/kernel.h | 15 +----- + include/linux/percpu.h | 24 ++++++++++- + kernel/lockdep.c | 4 +- + kernel/module.c | 7 ++- + kernel/notifier.c | 16 +++++++ + kernel/printk.c | 22 ++++++++-- + kernel/softlockup.c | 2 +- + kernel/time/tick-sched.c | 2 +- + kernel/timer.c | 1 + + lib/Kconfig.debug | 10 ++++ + mm/filemap.c | 15 ++++--- + 19 files changed, 233 insertions(+), 42 deletions(-) +Merging cpus4096/auto-cpus4096-next +$ git merge cpus4096/auto-cpus4096-next +Already up-to-date. +Merging ftrace/auto-ftrace-next +$ git merge ftrace/auto-ftrace-next +Auto-merged arch/x86/Kconfig +Auto-merged arch/x86/kernel/asm-offsets_64.c +Auto-merged arch/x86/kernel/entry_64.S +Auto-merged arch/x86/kernel/paravirt.c +Auto-merged arch/x86/kernel/paravirt_patch_32.c +Auto-merged arch/x86/kernel/traps_32.c +Auto-merged arch/x86/kernel/traps_64.c +Auto-merged arch/x86/kernel/vmi_32.c +Auto-merged arch/x86/lguest/boot.c +Auto-merged arch/x86/mm/fault.c +Auto-merged arch/x86/xen/enlighten.c +Auto-merged include/asm-generic/vmlinux.lds.h +Auto-merged include/asm-x86/ftrace.h +Auto-merged include/asm-x86/paravirt.h +Auto-merged include/linux/compiler.h +Auto-merged include/linux/init.h +Auto-merged include/linux/kernel.h +Auto-merged include/linux/module.h +Auto-merged init/main.c +Auto-merged kernel/exit.c +Auto-merged kernel/module.c +CONFLICT (content): Merge conflict in kernel/module.c +Auto-merged kernel/notifier.c +Auto-merged kernel/sched_clock.c +Resolved 'kernel/module.c' using previous resolution. +Automatic merge failed; fix conflicts and then commit the result. +$ git commit -v -a +Created commit f095316: Merge commit 'ftrace/auto-ftrace-next' +$ git diff -M --stat --summary HEAD^.. + Documentation/tracepoints.txt | 101 ++++ + arch/alpha/include/asm/thread_info.h | 2 +- + arch/avr32/include/asm/thread_info.h | 2 +- + arch/x86/Kconfig | 1 + + arch/x86/kernel/asm-offsets_32.c | 1 + + arch/x86/kernel/asm-offsets_64.c | 1 + + arch/x86/kernel/cpu/perfctr-watchdog.c | 11 +- + arch/x86/kernel/entry_32.S | 44 +- + arch/x86/kernel/entry_64.S | 60 +- + arch/x86/kernel/ftrace.c | 120 +++-- + arch/x86/kernel/paravirt.c | 3 + + arch/x86/kernel/paravirt_patch_32.c | 6 +- + arch/x86/kernel/paravirt_patch_64.c | 6 +- + arch/x86/kernel/traps_32.c | 3 + + arch/x86/kernel/traps_64.c | 4 + + arch/x86/kernel/vmi_32.c | 2 + + arch/x86/lguest/boot.c | 1 + + arch/x86/mm/fault.c | 4 +- + arch/x86/mm/pf_in.c | 121 +++-- + arch/x86/xen/enlighten.c | 1 + + include/asm-generic/vmlinux.lds.h | 14 +- + include/asm-x86/ftrace.h | 10 + + include/asm-x86/irqflags.h | 56 ++ + include/asm-x86/paravirt.h | 5 + + include/linux/compiler.h | 2 + + include/linux/ftrace.h | 50 ++- + include/linux/hardirq.h | 27 +- + include/linux/init.h | 2 +- + include/linux/kernel.h | 5 + + include/linux/kprobes.h | 5 +- + include/linux/linkage.h | 2 - + include/linux/module.h | 17 + + include/linux/rcupdate.h | 20 + + include/linux/stringify.h | 5 + + include/linux/tracepoint.h | 127 ++++ + include/trace/sched.h | 56 ++ + init/Kconfig | 7 + + init/main.c | 3 + + kernel/Makefile | 1 + + kernel/exit.c | 10 +- + kernel/fork.c | 3 + + kernel/kthread.c | 5 + + kernel/module.c | 81 +++- + kernel/notifier.c | 2 +- + kernel/sched.c | 17 +- + kernel/sched_clock.c | 8 + + kernel/signal.c | 3 + + kernel/trace/Kconfig | 9 + + kernel/trace/ftrace.c | 244 ++++++-- + kernel/trace/trace.c | 737 ++++++++++++++++++------ + kernel/trace/trace.h | 28 +- + kernel/trace/trace_mmiotrace.c | 12 +- + kernel/trace/trace_sched_switch.c | 120 +--- + kernel/trace/trace_sched_wakeup.c | 135 ++---- + kernel/trace/trace_selftest.c | 11 +- + kernel/tracepoint.c | 476 +++++++++++++++ + samples/Kconfig | 6 + + samples/Makefile | 2 +- + samples/tracepoints/Makefile | 6 + + samples/tracepoints/tp-samples-trace.h | 13 + + samples/tracepoints/tracepoint-probe-sample.c | 55 ++ + samples/tracepoints/tracepoint-probe-sample2.c | 42 ++ + samples/tracepoints/tracepoint-sample.c | 53 ++ + scripts/Makefile.build | 6 + + scripts/recordmcount.pl | 401 +++++++++++++ + 65 files changed, 2785 insertions(+), 608 deletions(-) + create mode 100644 Documentation/tracepoints.txt + create mode 100644 include/linux/tracepoint.h + create mode 100644 include/trace/sched.h + create mode 100644 kernel/tracepoint.c + create mode 100644 samples/tracepoints/Makefile + create mode 100644 samples/tracepoints/tp-samples-trace.h + create mode 100644 samples/tracepoints/tracepoint-probe-sample.c + create mode 100644 samples/tracepoints/tracepoint-probe-sample2.c + create mode 100644 samples/tracepoints/tracepoint-sample.c + create mode 100755 scripts/recordmcount.pl +$ git am -3 ../patches/ftrace__remove_warning_of_old_objcopy_and_local_functions +Applying ftrace: remove warning of old objcopy and local functions +Merging genirq/auto-genirq-next +$ git merge genirq/auto-genirq-next +Auto-merged include/linux/irq.h +Auto-merged kernel/irq/manage.c +Merge made by recursive. + include/linux/irq.h | 4 - + kernel/irq/handle.c | 2 - + kernel/irq/manage.c | 17 +++-- + kernel/irq/spurious.c | 146 ++++++++++++++++++++++++++++++------------------ + 4 files changed, 101 insertions(+), 68 deletions(-) +Merging safe-poison-pointers/auto-safe-poison-pointers-next +$ git merge safe-poison-pointers/auto-safe-poison-pointers-next +Auto-merged arch/x86/Kconfig +Merge made by recursive. + arch/x86/Kconfig | 5 +++++ + include/linux/poison.h | 16 ++++++++++++++-- + 2 files changed, 19 insertions(+), 2 deletions(-) +Merging sched/auto-sched-next +$ git merge sched/auto-sched-next +Auto-merged include/linux/compiler.h +Auto-merged kernel/sched.c +Auto-merged kernel/sched_rt.c +Auto-merged lib/Kconfig.debug +Merge made by recursive. + Documentation/RCU/checklist.txt | 2 +- + Documentation/RCU/whatisRCU.txt | 2 - + Documentation/scheduler/sched-design-CFS.txt | 371 +++++++++++++++----------- + include/linux/compiler.h | 4 +- + include/linux/proportions.h | 2 +- + include/linux/rcuclassic.h | 31 ++- + include/linux/rculist.h | 14 - + include/linux/rcupreempt.h | 11 +- + include/linux/sched.h | 4 +- + kernel/cpuset.c | 312 +++++++++++++--------- + kernel/rcuclassic.c | 331 +++++++++++++++++------ + kernel/rcupreempt.c | 8 - + kernel/rcupreempt_trace.c | 7 +- + kernel/sched.c | 227 +++++++++-------- + kernel/sched_rt.c | 5 +- + kernel/user.c | 4 +- + lib/Kconfig.debug | 13 + + 17 files changed, 827 insertions(+), 521 deletions(-) +Merging stackprotector/auto-stackprotector-next +$ git merge stackprotector/auto-stackprotector-next +Auto-merged arch/x86/Kconfig +Auto-merged arch/x86/Kconfig.debug +Auto-merged arch/x86/kernel/Makefile +Auto-merged arch/x86/kernel/process_64.c +Auto-merged arch/x86/mm/fault.c +Auto-merged include/asm-x86/pda.h +CONFLICT (content): Merge conflict in include/asm-x86/pda.h +Auto-merged include/asm-x86/system.h +Auto-merged include/linux/sched.h +Auto-merged init/main.c +Auto-merged kernel/exit.c +Auto-merged kernel/fork.c +CONFLICT (content): Merge conflict in kernel/fork.c +Auto-merged kernel/sched.c +Resolved 'include/asm-x86/pda.h' using previous resolution. +Resolved 'kernel/fork.c' using previous resolution. +Automatic merge failed; fix conflicts and then commit the result. +$ git commit -v -a +Created commit adc956c: Merge commit 'stackprotector/auto-stackprotector-next' +$ git diff -M --stat --summary HEAD^.. + arch/x86/Kconfig | 23 ++++++++++------------- + arch/x86/Kconfig.debug | 1 + + arch/x86/Makefile | 2 +- + arch/x86/kernel/Makefile | 1 + + arch/x86/kernel/process_64.c | 13 ++++++++++++- + arch/x86/mm/fault.c | 7 +++++++ + include/asm-x86/pda.h | 3 +-- + include/asm-x86/stackprotector.h | 38 ++++++++++++++++++++++++++++++++++++++ + include/asm-x86/system.h | 6 +++++- + include/linux/magic.h | 1 + + include/linux/sched.h | 16 ++++++++++++++-- + include/linux/stackprotector.h | 16 ++++++++++++++++ + init/main.c | 7 +++++++ + kernel/exit.c | 5 +---- + kernel/fork.c | 5 +++++ + kernel/panic.c | 12 +++++++++++- + kernel/sched.c | 7 +------ + 17 files changed, 132 insertions(+), 31 deletions(-) + create mode 100644 include/asm-x86/stackprotector.h + create mode 100644 include/linux/stackprotector.h +Merging timers/auto-timers-next +$ git merge timers/auto-timers-next +Auto-merged Documentation/00-INDEX +Auto-merged kernel/timer.c +Merge made by recursive. + Documentation/00-INDEX | 2 - + Documentation/timers/00-INDEX | 10 ++ + Documentation/{ => timers}/hpet.txt | 43 +++++----- + arch/x86/kernel/hpet.c | 6 +- + drivers/char/hpet.c | 155 ++++++++++++++++++++--------------- + drivers/clocksource/acpi_pm.c | 7 +- + include/linux/clocksource.h | 14 ++- + include/linux/hpet.h | 14 +--- + include/linux/time.h | 2 + + include/linux/timex.h | 9 ++- + kernel/hrtimer.c | 11 ++- + kernel/posix-timers.c | 15 ++++ + kernel/time/clocksource.c | 3 + + kernel/time/jiffies.c | 1 + + kernel/time/ntp.c | 76 +++++++++-------- + kernel/time/timekeeping.c | 113 +++++++++++++++++-------- + kernel/timer.c | 11 ++- + 17 files changed, 300 insertions(+), 192 deletions(-) + create mode 100644 Documentation/timers/00-INDEX + rename Documentation/{ => timers}/hpet.txt (81%) +Merging pci/linux-next +$ git merge pci/linux-next +Auto-merged Documentation/kernel-parameters.txt +Auto-merged arch/x86/pci/irq.c +Auto-merged drivers/pci/probe.c +Auto-merged init/Kconfig +Merge made by recursive. + Documentation/PCI/pci.txt | 4 + + Documentation/kernel-parameters.txt | 25 +++--- + arch/x86/pci/irq.c | 8 +- + drivers/i2c/busses/i2c-amd756.c | 5 - + drivers/i2c/busses/i2c-viapro.c | 5 - + drivers/pci/hotplug/ibmphp_ebda.c | 92 +++++-------------- + drivers/pci/hotplug/pciehp.h | 1 + + drivers/pci/hotplug/pciehp_hpc.c | 5 +- + drivers/pci/pci-driver.c | 21 ++++- + drivers/pci/pci.c | 48 +++++++--- + drivers/pci/pcie/portdrv_pci.c | 2 +- + drivers/pci/probe.c | 13 ++- + drivers/pci/quirks.c | 177 ++++++++++++++++++----------------- + drivers/pci/search.c | 6 +- + drivers/pci/setup-bus.c | 6 +- + drivers/scsi/ipr.c | 1 - + drivers/scsi/qla2xxx/qla_def.h | 2 +- + include/linux/pci.h | 12 +- + init/Kconfig | 8 ++ + 19 files changed, 223 insertions(+), 218 deletions(-) +Merging quilt/device-mapper +$ git merge quilt/device-mapper +Merge made by recursive. + drivers/md/dm-exception-store.c | 29 +++++++++++++++++++---------- + drivers/md/dm-mpath.c | 35 +++++++++++++++++++---------------- + drivers/md/dm-mpath.h | 2 -- + drivers/md/dm-raid1.c | 4 +++- + 4 files changed, 41 insertions(+), 29 deletions(-) +Merging hid/mm +$ git merge hid/mm +Removed drivers/hid/hid-input-quirks.c +Auto-merged drivers/hid/hidraw.c +Auto-merged drivers/hid/usbhid/hid-core.c +CONFLICT (content): Merge conflict in drivers/hid/usbhid/hid-core.c +Auto-merged drivers/hid/usbhid/usbmouse.c +Resolved 'drivers/hid/usbhid/hid-core.c' using previous resolution. +Automatic merge failed; fix conflicts and then commit the result. +$ git commit -v -a +Created commit 2908d6f: Merge commit 'hid/mm' +$ git diff -M --stat --summary HEAD^.. + Documentation/feature-removal-schedule.txt | 7 + + drivers/hid/Kconfig | 162 ++++ + drivers/hid/Makefile | 31 +- + drivers/hid/hid-a4tech.c | 162 ++++ + drivers/hid/hid-apple.c | 482 ++++++++++++ + drivers/hid/hid-belkin.c | 105 +++ + drivers/hid/hid-cherry.c | 87 +++ + drivers/hid/hid-chicony.c | 80 ++ + drivers/hid/hid-core.c | 1158 ++++++++++++++++++++++------ + drivers/hid/hid-cypress.c | 158 ++++ + drivers/hid/hid-dell.c | 74 ++ + drivers/hid/hid-dummy.c | 60 ++ + drivers/hid/hid-ezkey.c | 95 +++ + drivers/hid/hid-gyration.c | 96 +++ + drivers/hid/hid-ids.h | 386 +++++++++ + drivers/hid/hid-input-quirks.c | 484 ------------ + drivers/hid/hid-input.c | 915 ++++++++-------------- + drivers/hid/hid-lg.c | 342 ++++++++ + drivers/hid/hid-lg.h | 18 + + drivers/hid/{usbhid => }/hid-lg2ff.c | 6 +- + drivers/hid/{usbhid => }/hid-lgff.c | 34 +- + drivers/hid/hid-microsoft.c | 219 ++++++ + drivers/hid/hid-monterey.c | 82 ++ + drivers/hid/hid-petalynx.c | 122 +++ + drivers/hid/hid-samsung.c | 100 +++ + drivers/hid/hid-sony.c | 110 +++ + drivers/hid/hid-sunplus.c | 82 ++ + drivers/hid/hidraw.c | 6 +- + drivers/hid/usbhid/Kconfig | 35 - + drivers/hid/usbhid/Makefile | 6 - + drivers/hid/usbhid/hid-core.c | 424 +++++------ + drivers/hid/usbhid/hid-ff.c | 12 - + drivers/hid/usbhid/hid-quirks.c | 933 +---------------------- + drivers/hid/usbhid/hiddev.c | 20 +- + drivers/hid/usbhid/usbhid.h | 2 +- + drivers/hid/usbhid/usbmouse.c | 5 + + include/linux/hid.h | 357 +++++++-- + include/linux/hiddev.h | 6 +- + include/linux/mod_devicetable.h | 10 + + net/bluetooth/hidp/core.c | 214 ++++-- + net/bluetooth/hidp/hidp.h | 2 + + scripts/mod/file2alias.c | 18 + + 42 files changed, 5005 insertions(+), 2702 deletions(-) + create mode 100644 drivers/hid/hid-a4tech.c + create mode 100644 drivers/hid/hid-apple.c + create mode 100644 drivers/hid/hid-belkin.c + create mode 100644 drivers/hid/hid-cherry.c + create mode 100644 drivers/hid/hid-chicony.c + create mode 100644 drivers/hid/hid-cypress.c + create mode 100644 drivers/hid/hid-dell.c + create mode 100644 drivers/hid/hid-dummy.c + create mode 100644 drivers/hid/hid-ezkey.c + create mode 100644 drivers/hid/hid-gyration.c + create mode 100644 drivers/hid/hid-ids.h + delete mode 100644 drivers/hid/hid-input-quirks.c + create mode 100644 drivers/hid/hid-lg.c + create mode 100644 drivers/hid/hid-lg.h + rename drivers/hid/{usbhid => }/hid-lg2ff.c (97%) + rename drivers/hid/{usbhid => }/hid-lgff.c (81%) + create mode 100644 drivers/hid/hid-microsoft.c + create mode 100644 drivers/hid/hid-monterey.c + create mode 100644 drivers/hid/hid-petalynx.c + create mode 100644 drivers/hid/hid-samsung.c + create mode 100644 drivers/hid/hid-sony.c + create mode 100644 drivers/hid/hid-sunplus.c +$ git am -3 ../patches/0001-HID-fix-for-warn-removal.patch +Applying HID: fix for warn() removal +Merging quilt/i2c +$ git merge quilt/i2c +Auto-merged drivers/i2c/busses/i2c-viapro.c +Merge made by recursive. + Documentation/i2c/busses/i2c-floppy | 37 +++ + Documentation/i2c/busses/i2c-viapro | 8 +- + arch/arm/mach-omap1/board-h3.c | 4 + + arch/arm/mach-omap2/board-h4.c | 11 + + drivers/hwmon/dme1737.c | 320 +++++++++++------------ + drivers/i2c/busses/Kconfig | 33 +++- + drivers/i2c/busses/Makefile | 2 + + drivers/i2c/busses/i2c-floppy.c | 245 +++++++++++++++++ + drivers/i2c/busses/i2c-highlander.c | 498 +++++++++++++++++++++++++++++++++++ + drivers/i2c/busses/i2c-pca-isa.c | 20 ++- + drivers/i2c/busses/i2c-viapro.c | 4 + + drivers/i2c/chips/isp1301_omap.c | 141 ++++------ + drivers/i2c/chips/tps65010.c | 12 +- + 13 files changed, 1073 insertions(+), 262 deletions(-) + create mode 100644 Documentation/i2c/busses/i2c-floppy + create mode 100644 drivers/i2c/busses/i2c-floppy.c + create mode 100644 drivers/i2c/busses/i2c-highlander.c +Merging quilt/jdelvare-hwmon +$ git merge quilt/jdelvare-hwmon +Auto-merged drivers/hwmon/Kconfig +Auto-merged drivers/hwmon/ams/ams.h +Merge made by recursive. + Documentation/hwmon/lm87 | 9 +- + Documentation/hwmon/lm90 | 45 +++-- + drivers/hwmon/Kconfig | 8 +- + drivers/hwmon/ad7414.c | 2 +- + drivers/hwmon/ams/ams-core.c | 82 +++---- + drivers/hwmon/ams/ams-i2c.c | 60 ++---- + drivers/hwmon/ams/ams-input.c | 63 +++--- + drivers/hwmon/ams/ams-pmu.c | 18 +- + drivers/hwmon/ams/ams.h | 4 +- + drivers/hwmon/atxp1.c | 18 +- + drivers/hwmon/lm87.c | 33 ++- + drivers/hwmon/lm90.c | 444 ++++++++++++++++++++++++++----------- + drivers/i2c/busses/i2c-powermac.c | 29 +++ + 13 files changed, 501 insertions(+), 314 deletions(-) +Merging quilt/kernel-doc +$ git merge quilt/kernel-doc +Renamed Documentation/mtrr.txt->Documentation/x86/mtrr.txt +Auto-merged Documentation/x86/mtrr.txt +Auto-merged Documentation/00-INDEX +Auto-merged arch/x86/Kconfig +Auto-merged block/blk-core.c +Auto-merged block/blk-tag.c +Auto-merged block/genhd.c +Auto-merged include/linux/kernel.h +Merge made by recursive. + Documentation/00-INDEX | 2 - + Documentation/DocBook/kernel-api.tmpl | 5 ++ + Documentation/Makefile | 2 +- + Documentation/early-userspace/00-INDEX | 8 ++ + Documentation/{ => early-userspace}/initrd.txt | 6 +- + Documentation/filesystems/Makefile | 8 ++ + Documentation/filesystems/dnotify.txt | 36 +---------- + Documentation/filesystems/dnotify_test.c | 34 ++++++++++ + Documentation/filesystems/sharedsubtree.txt | 82 +---------------------- + Documentation/filesystems/smount.c | 73 +++++++++++++++++++++ + block/blk-core.c | 72 ++++++++++---------- + block/blk-exec.c | 6 +- + block/blk-integrity.c | 4 +- + block/blk-map.c | 16 ++-- + block/blk-settings.c | 8 +- + block/blk-tag.c | 8 +- + block/genhd.c | 5 +- + include/linux/kernel.h | 4 +- + scripts/kernel-doc | 6 +- + security/inode.c | 33 +++++----- + security/security.c | 8 +- + 21 files changed, 222 insertions(+), 204 deletions(-) + create mode 100644 Documentation/early-userspace/00-INDEX + rename Documentation/{ => early-userspace}/initrd.txt (99%) + create mode 100644 Documentation/filesystems/Makefile + create mode 100644 Documentation/filesystems/dnotify_test.c + create mode 100644 Documentation/filesystems/smount.c +Merging v4l-dvb/stable +$ git merge v4l-dvb/stable +Auto-merged drivers/media/radio/dsbr100.c +CONFLICT (content): Merge conflict in drivers/media/radio/dsbr100.c +Removed drivers/media/radio/miropcm20-radio.c +Removed drivers/media/radio/miropcm20-rds-core.c +Removed drivers/media/radio/miropcm20-rds-core.h +Removed drivers/media/radio/miropcm20-rds.c +Auto-merged drivers/media/video/cafe_ccic.c +Auto-merged drivers/media/video/dabusb.c +Removed drivers/media/video/dpc7146.c +Auto-merged drivers/media/video/ov511.c +Auto-merged drivers/media/video/se401.c +Auto-merged drivers/media/video/stv680.c +Removed drivers/media/video/tuner-3036.c +Auto-merged drivers/media/video/usbvideo/ibmcam.c +Auto-merged drivers/media/video/usbvideo/usbvideo.c +Auto-merged drivers/media/video/usbvision/usbvision-video.c +Auto-merged drivers/media/video/zr364xx.c +CONFLICT (content): Merge conflict in drivers/media/video/zr364xx.c +Resolved 'drivers/media/radio/dsbr100.c' using previous resolution. +Resolved 'drivers/media/video/zr364xx.c' using previous resolution. +Automatic merge failed; fix conflicts and then commit the result. +$ git commit -v -a +Created commit 16a05f6: Merge commit 'v4l-dvb/stable' +$ git diff -M --stat --summary HEAD^.. + Documentation/video4linux/CARDLIST.au0828 | 1 + + Documentation/video4linux/CARDLIST.bttv | 1 + + Documentation/video4linux/CARDLIST.cx23885 | 2 + + Documentation/video4linux/CARDLIST.tuner | 1 + + Documentation/video4linux/gspca.txt | 29 +- + Documentation/video4linux/soc-camera.txt | 120 +++ + arch/arm/mach-pxa/include/mach/camera.h | 2 - + drivers/media/common/ir-keymaps.c | 55 +- + drivers/media/common/saa7146_core.c | 2 +- + drivers/media/common/saa7146_fops.c | 2 +- + drivers/media/common/saa7146_video.c | 4 +- + drivers/media/common/tuners/mt2131.c | 2 +- + drivers/media/common/tuners/mt2131.h | 2 +- + drivers/media/common/tuners/mt2131_priv.h | 2 +- + drivers/media/common/tuners/mxl5005s.c | 4 +- + drivers/media/common/tuners/mxl5005s.h | 2 +- + drivers/media/common/tuners/tuner-simple.c | 35 +- + drivers/media/common/tuners/tuner-types.c | 22 + + drivers/media/common/tuners/xc5000.c | 2 +- + drivers/media/common/tuners/xc5000.h | 2 +- + drivers/media/common/tuners/xc5000_priv.h | 2 +- + drivers/media/dvb/b2c2/flexcop-dma.c | 2 +- + drivers/media/dvb/b2c2/flexcop-i2c.c | 12 +- + drivers/media/dvb/bt8xx/dvb-bt8xx.c | 2 +- + drivers/media/dvb/dvb-core/dmxdev.c | 1 - + drivers/media/dvb/dvb-core/dvb_ca_en50221.c | 4 +- + drivers/media/dvb/dvb-core/dvb_frontend.c | 8 +- + drivers/media/dvb/dvb-usb/Kconfig | 9 + + drivers/media/dvb/dvb-usb/Makefile | 3 + + drivers/media/dvb/dvb-usb/cxusb.c | 497 +++++++++- + drivers/media/dvb/dvb-usb/dib0700_devices.c | 9 +- + drivers/media/dvb/dvb-usb/dtv5100.c | 240 +++++ + drivers/media/dvb/dvb-usb/dtv5100.h | 51 + + drivers/media/dvb/dvb-usb/dvb-usb-ids.h | 4 + + drivers/media/dvb/frontends/Kconfig | 7 + + drivers/media/dvb/frontends/Makefile | 1 + + drivers/media/dvb/frontends/au8522.c | 47 +- + drivers/media/dvb/frontends/au8522.h | 11 +- + drivers/media/dvb/frontends/cx22702.c | 2 +- + drivers/media/dvb/frontends/cx22702.h | 2 +- + drivers/media/dvb/frontends/cx24123.c | 6 +- + drivers/media/dvb/frontends/cx24123.h | 2 +- + drivers/media/dvb/frontends/dib0070.h | 8 +- + drivers/media/dvb/frontends/dib7000p.c | 3 +- + drivers/media/dvb/frontends/dib7000p.h | 41 +- + drivers/media/dvb/frontends/drx397xD.c | 288 +++--- + drivers/media/dvb/frontends/drx397xD.h | 6 +- + drivers/media/dvb/frontends/lgs8gl5.c | 454 ++++++++ + drivers/media/dvb/frontends/lgs8gl5.h | 45 + + drivers/media/dvb/frontends/nxt200x.c | 4 +- + drivers/media/dvb/frontends/or51211.c | 2 +- + drivers/media/dvb/frontends/s5h1409.c | 3 +- + drivers/media/dvb/frontends/s5h1409.h | 2 +- + drivers/media/dvb/frontends/s5h1411.c | 3 +- + drivers/media/dvb/frontends/s5h1411.h | 2 +- + drivers/media/dvb/frontends/s5h1420.c | 3 +- + drivers/media/dvb/frontends/tda10048.c | 4 +- + drivers/media/dvb/frontends/tda10048.h | 2 +- + drivers/media/dvb/siano/sms-cards.c | 2 +- + drivers/media/dvb/siano/sms-cards.h | 2 +- + drivers/media/dvb/siano/smscoreapi.c | 2 +- + drivers/media/dvb/siano/smscoreapi.h | 2 +- + drivers/media/dvb/siano/smsdvb.c | 2 +- + drivers/media/dvb/siano/smsusb.c | 2 +- + drivers/media/dvb/ttpci/av7110.c | 2 +- + drivers/media/dvb/ttpci/budget-av.c | 2 +- + drivers/media/dvb/ttpci/budget-ci.c | 2 +- + drivers/media/dvb/ttpci/budget-patch.c | 2 +- + drivers/media/dvb/ttpci/budget.c | 2 +- + drivers/media/dvb/ttusb-budget/dvb-ttusb-budget.c | 2 +- + drivers/media/dvb/ttusb-dec/ttusb_dec.c | 2 +- + drivers/media/radio/Makefile | 4 - + drivers/media/radio/dsbr100.c | 19 +- + drivers/media/radio/miropcm20-radio.c | 266 ----- + drivers/media/radio/miropcm20-rds-core.c | 211 ---- + drivers/media/radio/miropcm20-rds-core.h | 19 - + drivers/media/radio/miropcm20-rds.c | 136 --- + drivers/media/radio/radio-aimslab.c | 37 +- + drivers/media/radio/radio-aztech.c | 43 +- + drivers/media/radio/radio-cadet.c | 3 +- + drivers/media/radio/radio-gemtek-pci.c | 44 +- + drivers/media/radio/radio-gemtek.c | 40 +- + drivers/media/radio/radio-maestro.c | 37 +- + drivers/media/radio/radio-maxiradio.c | 68 +- + drivers/media/radio/radio-rtrack2.c | 37 +- + drivers/media/radio/radio-sf16fmi.c | 36 +- + drivers/media/radio/radio-sf16fmr2.c | 34 +- + drivers/media/radio/radio-si470x.c | 28 +- + drivers/media/radio/radio-terratec.c | 37 +- + drivers/media/radio/radio-trust.c | 20 +- + drivers/media/radio/radio-typhoon.c | 35 +- + drivers/media/radio/radio-zoltrix.c | 37 +- + drivers/media/video/Kconfig | 150 ++-- + drivers/media/video/Makefile | 7 +- + drivers/media/video/arv.c | 29 +- + drivers/media/video/au0828/Kconfig | 1 + + drivers/media/video/au0828/au0828-cards.c | 9 +- + drivers/media/video/au0828/au0828-cards.h | 3 +- + drivers/media/video/au0828/au0828-core.c | 4 +- + drivers/media/video/au0828/au0828-dvb.c | 25 +- + drivers/media/video/au0828/au0828-i2c.c | 2 +- + drivers/media/video/au0828/au0828-reg.h | 2 +- + drivers/media/video/au0828/au0828.h | 2 +- + drivers/media/video/bt856.c | 8 +- + drivers/media/video/bt8xx/bttv-cards.c | 97 ++- + drivers/media/video/bt8xx/bttv-driver.c | 26 +- + drivers/media/video/bt8xx/bttv-input.c | 62 +- + drivers/media/video/bt8xx/bttv-risc.c | 3 +- + drivers/media/video/bt8xx/bttv.h | 2 +- + drivers/media/video/bt8xx/bttvp.h | 5 + + drivers/media/video/btcx-risc.c | 6 +- + drivers/media/video/btcx-risc.h | 2 +- + drivers/media/video/bw-qcam.c | 29 +- + drivers/media/video/bw-qcam.h | 1 + + drivers/media/video/c-qcam.c | 26 +- + drivers/media/video/cafe_ccic.c | 6 +- + drivers/media/video/cpia.c | 17 +- + drivers/media/video/cpia2/cpia2_v4l.c | 20 +- + drivers/media/video/cx18/cx18-av-firmware.c | 16 +- + drivers/media/video/cx18/cx18-driver.c | 10 +- + drivers/media/video/cx18/cx18-driver.h | 6 +- + drivers/media/video/cx18/cx18-dvb.c | 2 +- + drivers/media/video/cx18/cx18-dvb.h | 2 +- + drivers/media/video/cx18/cx18-fileops.c | 47 +- + drivers/media/video/cx18/cx18-ioctl.c | 20 +- + drivers/media/video/cx18/cx18-irq.c | 2 +- + drivers/media/video/cx18/cx18-mailbox.c | 1 + + drivers/media/video/cx18/cx18-queue.c | 135 +-- + drivers/media/video/cx18/cx18-queue.h | 2 +- + drivers/media/video/cx18/cx18-streams.c | 19 +- + drivers/media/video/cx18/cx23418.h | 2 +- + drivers/media/video/cx2341x.c | 5 +- + drivers/media/video/cx23885/Kconfig | 1 + + drivers/media/video/cx23885/cx23885-417.c | 12 +- + drivers/media/video/cx23885/cx23885-cards.c | 86 ++- + drivers/media/video/cx23885/cx23885-core.c | 6 +- + drivers/media/video/cx23885/cx23885-dvb.c | 104 ++- + drivers/media/video/cx23885/cx23885-i2c.c | 2 +- + drivers/media/video/cx23885/cx23885-reg.h | 2 +- + drivers/media/video/cx23885/cx23885-vbi.c | 2 +- + drivers/media/video/cx23885/cx23885-video.c | 14 +- + drivers/media/video/cx23885/cx23885.h | 4 +- + drivers/media/video/cx25840/cx25840-core.c | 2 +- + drivers/media/video/cx88/cx88-blackbird.c | 8 +- + drivers/media/video/cx88/cx88-video.c | 10 +- + drivers/media/video/dpc7146.c | 408 ------- + drivers/media/video/em28xx/em28xx-video.c | 7 +- + drivers/media/video/et61x251/et61x251_core.c | 14 +- + drivers/media/video/gspca/conex.c | 24 +- + drivers/media/video/gspca/etoms.c | 30 +- + drivers/media/video/gspca/gspca.c | 119 ++- + drivers/media/video/gspca/gspca.h | 21 +- + drivers/media/video/gspca/mars.c | 41 +- + drivers/media/video/gspca/ov519.c | 1167 +++++++++++---------- + drivers/media/video/gspca/pac207.c | 87 +-- + drivers/media/video/gspca/pac7311.c | 1110 +++++++++++++------- + drivers/media/video/gspca/pac_common.h | 60 ++ + drivers/media/video/gspca/sonixb.c | 512 +++++----- + drivers/media/video/gspca/sonixj.c | 539 +++++++---- + drivers/media/video/gspca/spca500.c | 20 +- + drivers/media/video/gspca/spca501.c | 16 +- + drivers/media/video/gspca/spca505.c | 16 +- + drivers/media/video/gspca/spca506.c | 20 +- + drivers/media/video/gspca/spca508.c | 21 +- + drivers/media/video/gspca/spca561.c | 667 ++++++++----- + drivers/media/video/gspca/stk014.c | 20 +- + drivers/media/video/gspca/sunplus.c | 167 ++-- + drivers/media/video/gspca/t613.c | 41 +- + drivers/media/video/gspca/tv8532.c | 20 +- + drivers/media/video/gspca/vc032x.c | 31 +- + drivers/media/video/gspca/zc3xx.c | 85 +- + drivers/media/video/ivtv/ivtv-driver.c | 6 +- + drivers/media/video/ivtv/ivtv-driver.h | 1 + + drivers/media/video/ivtv/ivtv-fileops.c | 2 +- + drivers/media/video/ivtv/ivtv-fileops.h | 5 - + drivers/media/video/ivtv/ivtv-irq.c | 29 +- + drivers/media/video/ivtv/ivtv-queue.h | 2 +- + drivers/media/video/ivtv/ivtv-streams.c | 2 +- + drivers/media/video/ivtv/ivtv-vbi.c | 4 +- + drivers/media/video/ivtv/ivtv-version.h | 2 +- + drivers/media/video/ks0127.c | 31 +- + drivers/media/video/meye.c | 15 +- + drivers/media/video/meye.h | 1 + + drivers/media/video/mt9m001.c | 55 +- + drivers/media/video/mt9m111.c | 973 +++++++++++++++++ + drivers/media/video/mt9v022.c | 52 +- + drivers/media/video/mxb.c | 25 +- + drivers/media/video/ov511.c | 14 +- + drivers/media/video/pms.c | 36 +- + drivers/media/video/pvrusb2/pvrusb2-hdw.c | 3 +- + drivers/media/video/pvrusb2/pvrusb2-v4l2.c | 6 + + drivers/media/video/pwc/pwc-ctrl.c | 18 +- + drivers/media/video/pwc/pwc-if.c | 12 +- + drivers/media/video/pwc/pwc-v4l.c | 2 +- + drivers/media/video/pxa_camera.c | 24 - + drivers/media/video/s2255drv.c | 572 ++++++----- + drivers/media/video/saa5246a.c | 44 +- + drivers/media/video/saa5249.c | 56 +- + drivers/media/video/saa7115.c | 5 +- + drivers/media/video/saa7134/saa6752hs.c | 335 ++++-- + drivers/media/video/saa7134/saa7134-core.c | 58 +- + drivers/media/video/saa7134/saa7134-empress.c | 40 +- + drivers/media/video/saa7134/saa7134-input.c | 140 +++- + drivers/media/video/saa7134/saa7134-ts.c | 56 +- + drivers/media/video/saa7134/saa7134-video.c | 8 +- + drivers/media/video/saa7134/saa7134.h | 8 + + drivers/media/video/se401.c | 9 +- + drivers/media/video/sh_mobile_ceu_camera.c | 5 - + drivers/media/video/sn9c102/sn9c102_core.c | 14 +- + drivers/media/video/sn9c102/sn9c102_devtable.h | 13 +- + drivers/media/video/stk-webcam.c | 10 +- + drivers/media/video/stradis.c | 7 +- + drivers/media/video/stv680.c | 4 +- + drivers/media/video/tda9840.c | 166 +-- + drivers/media/video/tea6415c.c | 131 +-- + drivers/media/video/tea6420.c | 147 +-- + drivers/media/video/tuner-3036.c | 214 ---- + drivers/media/video/usbvideo/ibmcam.c | 6 +- + drivers/media/video/usbvideo/usbvideo.c | 3 +- + drivers/media/video/usbvideo/vicam.c | 19 +- + drivers/media/video/usbvision/usbvision-video.c | 124 +-- + drivers/media/video/uvc/uvc_driver.c | 24 +- + drivers/media/video/uvc/uvc_v4l2.c | 13 +- + drivers/media/video/uvc/uvc_video.c | 7 +- + drivers/media/video/v4l2-common.c | 183 +++- + drivers/media/video/v4l2-dev.c | 208 ++--- + drivers/media/video/v4l2-ioctl.c | 4 +- + drivers/media/video/vino.c | 25 +- + drivers/media/video/vivi.c | 59 +- + drivers/media/video/w9966.c | 31 +- + drivers/media/video/wm8739.c | 4 +- + drivers/media/video/zc0301/zc0301_core.c | 14 +- + drivers/media/video/zc0301/zc0301_sensor.h | 19 - + drivers/media/video/zoran_device.c | 4 +- + drivers/media/video/zoran_driver.c | 3 + + drivers/media/video/zr364xx.c | 37 +- + include/linux/i2c-id.h | 1 - + include/linux/videodev2.h | 32 +- + include/media/ir-common.h | 6 + + include/media/saa7146.h | 2 +- + include/media/sh_mobile_ceu.h | 2 - + include/media/soc_camera.h | 3 + + include/media/tuner.h | 1 + + include/media/v4l2-chip-ident.h | 5 + + include/media/v4l2-common.h | 3 + + include/media/v4l2-dev.h | 65 +- + include/sound/tea575x-tuner.h | 1 + + sound/i2c/other/tea575x-tuner.c | 25 +- + 248 files changed, 8348 insertions(+), 5577 deletions(-) + create mode 100644 Documentation/video4linux/soc-camera.txt + create mode 100644 drivers/media/dvb/dvb-usb/dtv5100-fe.c + create mode 100644 drivers/media/dvb/dvb-usb/dtv5100.c + create mode 100644 drivers/media/dvb/dvb-usb/dtv5100.h + create mode 100644 drivers/media/dvb/frontends/lgs8gl5.c + create mode 100644 drivers/media/dvb/frontends/lgs8gl5.h + delete mode 100644 drivers/media/radio/miropcm20-radio.c + delete mode 100644 drivers/media/radio/miropcm20-rds-core.c + delete mode 100644 drivers/media/radio/miropcm20-rds-core.h + delete mode 100644 drivers/media/radio/miropcm20-rds.c + delete mode 100644 drivers/media/video/dpc7146.c + create mode 100644 drivers/media/video/gspca/pac_common.h + create mode 100644 drivers/media/video/mt9m111.c + delete mode 100644 drivers/media/video/tuner-3036.c +Merging jfs/next +$ git merge jfs/next +Already up-to-date. +Merging kbuild/master +$ git merge kbuild/master +Already up-to-date. +Merging quilt/ide +$ git merge quilt/ide +Auto-merged drivers/ide/ide-probe.c +Auto-merged drivers/ide/ide-tape.c +Merge made by recursive. + drivers/ata/libata-scsi.c | 2 +- + drivers/block/hd.c | 9 +- + drivers/ide/Kconfig | 61 +--- + drivers/ide/Makefile | 23 +- + drivers/ide/arm/icside.c | 5 +- + drivers/ide/arm/palm_bk3710.c | 8 +- + drivers/ide/h8300/ide-h8300.c | 2 +- + drivers/ide/ide-acpi.c | 18 +- + drivers/ide/ide-atapi.c | 393 ++++++++++++--- + drivers/ide/ide-cd.c | 108 ++--- + drivers/ide/ide-disk.c | 560 +++++++-------------- + drivers/ide/ide-disk.h | 32 ++ + drivers/ide/ide-disk_ioctl.c | 29 + + drivers/ide/ide-disk_proc.c | 129 +++++ + drivers/ide/ide-dma.c | 65 ++-- + drivers/ide/ide-floppy.c | 954 +++++++---------------------------- + drivers/ide/ide-floppy.h | 62 +++ + drivers/ide/ide-floppy_ioctl.c | 293 +++++++++++ + drivers/ide/ide-floppy_proc.c | 33 ++ + drivers/ide/ide-generic.c | 102 +++-- + drivers/ide/ide-io.c | 313 +++++------- + drivers/ide/ide-ioctls.c | 299 +++++++++++ + drivers/ide/ide-iops.c | 289 ++++------- + drivers/ide/ide-lib.c | 75 ++-- + drivers/ide/ide-probe.c | 450 ++++++++--------- + drivers/ide/ide-proc.c | 310 ++++-------- + drivers/ide/ide-tape.c | 594 ++++++---------------- + drivers/ide/ide-taskfile.c | 241 ++-------- + drivers/ide/ide-timings.c | 22 +- + drivers/ide/ide.c | 347 ++++--------- + drivers/ide/legacy/ali14xx.c | 3 +- + drivers/ide/legacy/buddha.c | 1 - + drivers/ide/legacy/dtc2278.c | 1 - + drivers/ide/legacy/falconide.c | 1 - + drivers/ide/legacy/gayle.c | 1 - + drivers/ide/legacy/ht6560b.c | 10 +- + drivers/ide/legacy/ide-4drives.c | 2 +- + drivers/ide/legacy/ide-cs.c | 1 - + drivers/ide/legacy/macide.c | 1 - + drivers/ide/legacy/q40ide.c | 2 - + drivers/ide/legacy/qd65xx.c | 25 +- + drivers/ide/legacy/umc8672.c | 1 - + drivers/ide/mips/au1xxx-ide.c | 6 +- + drivers/ide/pci/aec62xx.c | 15 +- + drivers/ide/pci/alim15x3.c | 24 +- + drivers/ide/pci/amd74xx.c | 18 +- + drivers/ide/pci/atiixp.c | 11 +- + drivers/ide/pci/cmd640.c | 51 +- + drivers/ide/pci/cmd64x.c | 13 +- + drivers/ide/pci/cs5520.c | 9 +- + drivers/ide/pci/cs5530.c | 27 +- + drivers/ide/pci/cs5535.c | 24 +- + drivers/ide/pci/cy82c693.c | 128 +----- + drivers/ide/pci/delkin_cb.c | 7 +- + drivers/ide/pci/generic.c | 11 +- + drivers/ide/pci/hpt34x.c | 13 +- + drivers/ide/pci/hpt366.c | 88 ++-- + drivers/ide/pci/it8213.c | 11 +- + drivers/ide/pci/it821x.c | 104 ++-- + drivers/ide/pci/jmicron.c | 11 +- + drivers/ide/pci/ns87415.c | 32 +- + drivers/ide/pci/opti621.c | 17 +- + drivers/ide/pci/pdc202xx_new.c | 23 +- + drivers/ide/pci/pdc202xx_old.c | 23 +- + drivers/ide/pci/piix.c | 52 ++- + drivers/ide/pci/rz1000.c | 7 +- + drivers/ide/pci/sc1200.c | 27 +- + drivers/ide/pci/scc_pata.c | 20 +- + drivers/ide/pci/serverworks.c | 19 +- + drivers/ide/pci/sgiioc4.c | 1 - + drivers/ide/pci/siimage.c | 34 +- + drivers/ide/pci/sis5513.c | 13 +- + drivers/ide/pci/sl82c105.c | 15 +- + drivers/ide/pci/slc90e66.c | 11 +- + drivers/ide/pci/tc86c001.c | 6 +- + drivers/ide/pci/triflex.c | 20 +- + drivers/ide/pci/trm290.c | 11 +- + drivers/ide/pci/via82cxxx.c | 18 +- + drivers/ide/ppc/pmac.c | 24 +- + drivers/ide/setup-pci.c | 33 ++ + drivers/scsi/ide-scsi.c | 218 +++----- + include/asm-mips/mach-generic/ide.h | 29 - + include/linux/ata.h | 112 ++++- + include/linux/ide.h | 854 ++++++++++++++++++------------- + 84 files changed, 3830 insertions(+), 4237 deletions(-) + create mode 100644 drivers/ide/ide-disk.h + create mode 100644 drivers/ide/ide-disk_ioctl.c + create mode 100644 drivers/ide/ide-disk_proc.c + create mode 100644 drivers/ide/ide-floppy.h + create mode 100644 drivers/ide/ide-floppy_ioctl.c + create mode 100644 drivers/ide/ide-floppy_proc.c + create mode 100644 drivers/ide/ide-ioctls.c +Merging libata/NEXT +$ git merge libata/NEXT +Already up-to-date. +Merging nfs/linux-next +$ git merge nfs/linux-next +Already up-to-date. +Merging xfs/master +$ git merge xfs/master +Merge made by recursive. + fs/xfs/linux-2.6/xfs_super.c | 11 ++++++++++- + fs/xfs/xfs_mount.h | 1 + + 2 files changed, 11 insertions(+), 1 deletions(-) +Merging infiniband/for-next +$ git merge infiniband/for-next +Auto-merged drivers/infiniband/core/cm.c +Merge made by recursive. + drivers/infiniband/core/cm.c | 2 ++ + drivers/infiniband/core/mad.c | 5 ++--- + drivers/infiniband/core/ucma.c | 4 ++-- + drivers/infiniband/hw/ipath/ipath_rc.c | 3 ++- + drivers/infiniband/hw/ipath/ipath_ruc.c | 3 ++- + drivers/net/mlx4/mr.c | 8 ++++++-- + 6 files changed, 16 insertions(+), 9 deletions(-) +Merging acpi/test +$ git merge acpi/test +Auto-merged Documentation/kernel-parameters.txt +Auto-merged MAINTAINERS +Auto-merged drivers/misc/acer-wmi.c +CONFLICT (content): Merge conflict in drivers/misc/acer-wmi.c +Auto-merged drivers/misc/eeepc-laptop.c +Resolved 'drivers/misc/acer-wmi.c' using previous resolution. +Automatic merge failed; fix conflicts and then commit the result. +$ git commit -v -a +Created commit a0119f5: Merge commit 'acpi/test' +$ git diff -M --stat --summary HEAD^.. + Documentation/kernel-parameters.txt | 122 +++++-- + MAINTAINERS | 9 +- + drivers/acpi/Kconfig | 11 + + drivers/acpi/Makefile | 6 + + drivers/acpi/bus.c | 53 ++- + drivers/acpi/dispatcher/dsobject.c | 2 +- + drivers/acpi/ec.c | 2 +- + drivers/acpi/events/evgpe.c | 2 - + drivers/acpi/executer/exconfig.c | 116 ++++-- + drivers/acpi/glue.c | 40 ++ + drivers/acpi/hardware/hwsleep.c | 7 + + drivers/acpi/namespace/nsxfeval.c | 79 ++++ + drivers/acpi/namespace/nsxfname.c | 5 + + drivers/acpi/pcc_acpi.c | 779 +++++++++++++++++++++++++++++++++++ + drivers/acpi/power.c | 68 ++- + drivers/acpi/processor_perflib.c | 2 +- + drivers/acpi/scan.c | 80 ++-- + drivers/acpi/sleep/main.c | 49 +++- + drivers/acpi/tables.c | 2 + + drivers/acpi/tables/tbinstal.c | 61 +++- + drivers/acpi/utilities/utglobal.c | 44 ++- + drivers/acpi/utilities/utobject.c | 8 +- + drivers/acpi/utilities/utxface.c | 7 +- + drivers/acpi/video.c | 35 +- + drivers/acpi/video_detect.c | 268 ++++++++++++ + drivers/acpi/wmi.c | 10 +- + drivers/misc/acer-wmi.c | 25 +- + drivers/misc/asus-laptop.c | 10 +- + drivers/misc/compal-laptop.c | 12 +- + drivers/misc/eeepc-laptop.c | 12 +- + drivers/misc/fujitsu-laptop.c | 26 +- + drivers/misc/msi-laptop.c | 16 +- + drivers/misc/sony-laptop.c | 6 +- + drivers/misc/thinkpad_acpi.c | 29 +- + drivers/pnp/Kconfig | 20 +- + drivers/pnp/Makefile | 4 - + drivers/pnp/base.h | 10 + + drivers/pnp/core.c | 29 +- + drivers/pnp/driver.c | 4 - + drivers/pnp/isapnp/Makefile | 4 - + drivers/pnp/isapnp/core.c | 12 +- + drivers/pnp/manager.c | 34 +- + drivers/pnp/pnpacpi/Makefile | 4 - + drivers/pnp/pnpacpi/core.c | 16 +- + drivers/pnp/pnpacpi/rsparser.c | 45 +- + drivers/pnp/pnpbios/Makefile | 4 - + drivers/pnp/pnpbios/core.c | 4 +- + drivers/pnp/pnpbios/rsparser.c | 18 +- + drivers/pnp/quirks.c | 6 +- + drivers/pnp/resource.c | 12 +- + drivers/pnp/support.c | 14 +- + include/acpi/acconfig.h | 2 +- + include/acpi/acdisasm.h | 4 + + include/acpi/acmacros.h | 248 +++++------ + include/acpi/acpi_bus.h | 2 + + include/acpi/acpi_drivers.h | 1 + + include/acpi/actbl1.h | 51 ++- + include/acpi/actypes.h | 3 +- + include/acpi/acutils.h | 4 +- + include/linux/acpi.h | 52 ++- + include/linux/pnp.h | 10 - + 61 files changed, 2118 insertions(+), 502 deletions(-) + create mode 100644 drivers/acpi/pcc_acpi.c + create mode 100644 drivers/acpi/video_detect.c +Merging nfsd/nfsd-next +$ git merge nfsd/nfsd-next +Auto-merged fs/proc/proc_misc.c +Merge made by recursive. + fs/Kconfig | 30 ++++++++ + fs/Makefile | 3 +- + fs/lockd/host.c | 123 +++++++++++++++++++++++-------- + fs/lockd/svc.c | 33 ++++----- + fs/nfs/callback.c | 3 +- + fs/nfsd/nfs3proc.c | 8 +- + fs/nfsd/nfs4callback.c | 3 +- + fs/nfsd/nfs4xdr.c | 171 ++++++++++++++++++++++-------------------- + fs/nfsd/nfsfh.c | 30 +++++--- + fs/nfsd/nfsproc.c | 6 +- + fs/nfsd/nfssvc.c | 1 + + fs/nfsd/vfs.c | 63 +++++++++------- + fs/proc/proc_misc.c | 4 + + include/linux/fs.h | 57 ++++++++++++-- + include/linux/lockd/lockd.h | 4 + + include/linux/nfsd/nfsd.h | 3 +- + include/linux/sunrpc/clnt.h | 4 +- + include/linux/sunrpc/svc.h | 19 +++-- + kernel/sys_ni.c | 1 + + kernel/sysctl.c | 6 +- + net/sunrpc/rpcb_clnt.c | 65 +++++++--------- + net/sunrpc/svc.c | 174 +++++++++++++++++++++++++++++++++++------- + net/sunrpc/svc_xprt.c | 39 ++++++++-- + net/sunrpc/svcsock.c | 13 +++ + 24 files changed, 596 insertions(+), 267 deletions(-) +Merging ieee1394/for-next +$ git merge ieee1394/for-next +Merge made by recursive. + drivers/firewire/fw-card.c | 56 +++------- + drivers/firewire/fw-device.c | 37 +----- + drivers/firewire/fw-sbp2.c | 116 ++++++++------------ + drivers/firewire/fw-transaction.c | 48 ++++++++- + drivers/firewire/fw-transaction.h | 9 +- + drivers/ieee1394/csr1212.c | 2 +- + drivers/ieee1394/eth1394.c | 2 +- + drivers/ieee1394/sbp2.c | 218 +++++++++++++++--------------------- + drivers/ieee1394/sbp2.h | 33 ++---- + 9 files changed, 218 insertions(+), 303 deletions(-) +Merging ubi/linux-next +$ git merge ubi/linux-next +Merge made by recursive. + drivers/mtd/ubi/cdev.c | 6 +----- + 1 files changed, 1 insertions(+), 5 deletions(-) +Merging kvm/master +$ git merge kvm/master +Auto-merged arch/s390/Kconfig +Auto-merged arch/x86/xen/time.c +Auto-merged include/asm-x86/kvm.h +CONFLICT (content): Merge conflict in include/asm-x86/kvm.h +Auto-merged include/asm-x86/kvm_host.h +Auto-merged include/asm-x86/pvclock.h +Resolved 'include/asm-x86/kvm.h' using previous resolution. +Automatic merge failed; fix conflicts and then commit the result. +$ git commit -v -a +Created commit 9db417b: Merge commit 'kvm/master' +$ git diff -M --stat --summary HEAD^.. + arch/ia64/kvm/Kconfig | 2 + + arch/ia64/kvm/irq.h | 32 ++ + arch/ia64/kvm/kvm-ia64.c | 37 ++- + arch/powerpc/include/asm/kvm_host.h | 14 +- + arch/powerpc/include/asm/kvm_ppc.h | 12 + + arch/powerpc/kernel/asm-offsets.c | 4 +- + arch/powerpc/kvm/44x_tlb.c | 49 ++- + arch/powerpc/kvm/Kconfig | 11 + + arch/powerpc/kvm/Makefile | 6 +- + arch/powerpc/kvm/booke_guest.c | 17 + + arch/powerpc/kvm/booke_interrupts.S | 79 +++-- + arch/powerpc/kvm/emulate.c | 8 +- + arch/powerpc/kvm/powerpc.c | 99 +++++- + arch/s390/Kconfig | 7 +- + arch/s390/kvm/priv.c | 4 +- + arch/x86/kernel/kvmclock.c | 30 ++ + arch/x86/kernel/pvclock.c | 12 + + arch/x86/kvm/i8254.c | 76 ++-- + arch/x86/kvm/i8254.h | 7 +- + arch/x86/kvm/i8259.c | 36 ++- + arch/x86/kvm/irq.c | 36 ++- + arch/x86/kvm/irq.h | 10 +- + arch/x86/kvm/kvm_cache_regs.h | 32 ++ + arch/x86/kvm/lapic.c | 11 +- + arch/x86/kvm/mmu.c | 188 ++++++---- + arch/x86/kvm/paging_tmpl.h | 161 +++++---- + arch/x86/kvm/svm.c | 150 +++----- + arch/x86/kvm/vmx.c | 688 ++++++++++++++++++++++++----------- + arch/x86/kvm/vmx.h | 4 +- + arch/x86/kvm/x86.c | 670 +++++++++++++++++++++++++--------- + arch/x86/kvm/x86.h | 22 ++ + arch/x86/kvm/x86_emulate.c | 48 ++- + arch/x86/xen/time.c | 11 +- + include/asm-x86/kvm.h | 22 -- + include/asm-x86/kvm_host.h | 89 +++-- + include/asm-x86/pvclock.h | 1 + + include/linux/kvm.h | 67 +++- + include/linux/kvm_host.h | 19 + + virt/kvm/ioapic.c | 22 +- + virt/kvm/ioapic.h | 3 +- + virt/kvm/kvm_main.c | 70 +++-- + virt/kvm/kvm_trace.c | 30 +- + 42 files changed, 2014 insertions(+), 882 deletions(-) + create mode 100644 arch/ia64/kvm/irq.h + create mode 100644 arch/x86/kvm/kvm_cache_regs.h + create mode 100644 arch/x86/kvm/x86.h +Merging dlm/next +$ git merge dlm/next +Merge made by recursive. + fs/dlm/config.c | 33 +++++++++- + fs/dlm/dlm_internal.h | 7 ++- + fs/dlm/lockspace.c | 158 ++++++++++++++++++++++++++++++++----------- + fs/dlm/lockspace.h | 1 + + fs/dlm/user.c | 115 +++++++++++++++++++++++++------ + fs/dlm/user.h | 4 +- + fs/gfs2/locking/dlm/mount.c | 3 +- + include/linux/dlm.h | 5 +- + include/linux/dlm_device.h | 2 +- + 9 files changed, 258 insertions(+), 70 deletions(-) +Merging scsi/master +$ git merge scsi/master +Auto-merged drivers/scsi/qla2xxx/qla_def.h +Merge made by recursive. + drivers/scsi/hosts.c | 2 +- + drivers/scsi/qla2xxx/qla_def.h | 1 - + drivers/scsi/scsi_proc.c | 8 ++++---- + drivers/scsi/scsi_tgt_lib.c | 6 +++--- + drivers/scsi/scsi_transport_iscsi.c | 4 ++-- + drivers/scsi/tmscsim.c | 4 ++-- + 6 files changed, 12 insertions(+), 13 deletions(-) +Merging tests/master +$ git merge tests/master +Auto-merged Makefile +Auto-merged drivers/misc/Makefile +Auto-merged kernel/Makefile +Auto-merged lib/Kconfig.debug +CONFLICT (content): Merge conflict in lib/Kconfig.debug +Auto-merged lib/Makefile +Resolved 'lib/Kconfig.debug' using previous resolution. +Automatic merge failed; fix conflicts and then commit the result. +$ git commit -v -a +Created commit 4603305: Merge commit 'tests/master' +$ git diff -M --stat --summary HEAD^.. + Makefile | 1 + + drivers/misc/Makefile | 1 - + kernel/Makefile | 4 - + lib/Kconfig.debug | 93 +-------------------- + lib/Makefile | 1 - + tests/Kconfig | 101 +++++++++++++++++++++++ + tests/Makefile | 10 ++ + {kernel => tests}/backtracetest.c | 0 + {drivers/misc => tests}/lkdtm.c | 0 + {lib => tests}/locking-selftest-hardirq.h | 0 + {lib => tests}/locking-selftest-mutex.h | 0 + {lib => tests}/locking-selftest-rlock-hardirq.h | 0 + {lib => tests}/locking-selftest-rlock-softirq.h | 0 + {lib => tests}/locking-selftest-rlock.h | 0 + {lib => tests}/locking-selftest-rsem.h | 0 + {lib => tests}/locking-selftest-softirq.h | 0 + {lib => tests}/locking-selftest-spin-hardirq.h | 0 + {lib => tests}/locking-selftest-spin-softirq.h | 0 + {lib => tests}/locking-selftest-spin.h | 0 + {lib => tests}/locking-selftest-wlock-hardirq.h | 0 + {lib => tests}/locking-selftest-wlock-softirq.h | 0 + {lib => tests}/locking-selftest-wlock.h | 0 + {lib => tests}/locking-selftest-wsem.h | 0 + {lib => tests}/locking-selftest.c | 0 + {kernel => tests}/rcutorture.c | 0 + {kernel => tests}/rtmutex-tester.c | 2 +- + {kernel => tests}/test_kprobes.c | 0 + 27 files changed, 115 insertions(+), 98 deletions(-) + create mode 100644 tests/Kconfig + create mode 100644 tests/Makefile + rename {kernel => tests}/backtracetest.c (100%) + rename {drivers/misc => tests}/lkdtm.c (100%) + rename {lib => tests}/locking-selftest-hardirq.h (100%) + rename {lib => tests}/locking-selftest-mutex.h (100%) + rename {lib => tests}/locking-selftest-rlock-hardirq.h (100%) + rename {lib => tests}/locking-selftest-rlock-softirq.h (100%) + rename {lib => tests}/locking-selftest-rlock.h (100%) + rename {lib => tests}/locking-selftest-rsem.h (100%) + rename {lib => tests}/locking-selftest-softirq.h (100%) + rename {lib => tests}/locking-selftest-spin-hardirq.h (100%) + rename {lib => tests}/locking-selftest-spin-softirq.h (100%) + rename {lib => tests}/locking-selftest-spin.h (100%) + rename {lib => tests}/locking-selftest-wlock-hardirq.h (100%) + rename {lib => tests}/locking-selftest-wlock-softirq.h (100%) + rename {lib => tests}/locking-selftest-wlock.h (100%) + rename {lib => tests}/locking-selftest-wsem.h (100%) + rename {lib => tests}/locking-selftest.c (100%) + rename {kernel => tests}/rcutorture.c (100%) + rename {kernel => tests}/rtmutex-tester.c (99%) + rename {kernel => tests}/test_kprobes.c (100%) +Merging ocfs2/linux-next +$ git merge ocfs2/linux-next +Merge made by recursive. + fs/ocfs2/Makefile | 5 +- + fs/ocfs2/alloc.c | 829 ++++++-- + fs/ocfs2/alloc.h | 86 +- + fs/ocfs2/aops.c | 30 +- + fs/ocfs2/cluster/masklog.c | 1 + + fs/ocfs2/cluster/masklog.h | 1 + + fs/ocfs2/dir.c | 26 +- + fs/ocfs2/extent_map.c | 60 + + fs/ocfs2/extent_map.h | 3 + + fs/ocfs2/file.c | 299 +-- + fs/ocfs2/file.h | 32 +- + fs/ocfs2/inode.c | 23 +- + fs/ocfs2/inode.h | 3 + + fs/ocfs2/journal.h | 27 +- + fs/ocfs2/localalloc.c | 307 +++- + fs/ocfs2/localalloc.h | 4 + + fs/ocfs2/locks.c | 15 + + fs/ocfs2/locks.h | 1 + + fs/ocfs2/namei.c | 13 +- + fs/ocfs2/ocfs2.h | 48 +- + fs/ocfs2/ocfs2_fs.h | 220 ++- + fs/ocfs2/stack_user.c | 33 + + fs/ocfs2/stackglue.c | 20 + + fs/ocfs2/stackglue.h | 19 + + fs/ocfs2/suballoc.c | 129 +- + fs/ocfs2/suballoc.h | 15 +- + fs/ocfs2/super.c | 27 +- + fs/ocfs2/symlink.c | 9 + + fs/ocfs2/uptodate.c | 32 +- + fs/ocfs2/uptodate.h | 3 + + fs/ocfs2/xattr.c | 4867 ++++++++++++++++++++++++++++++++++++++++++++ + fs/ocfs2/xattr.h | 75 + + fs/ocfs2/xattr_trusted.c | 82 + + fs/ocfs2/xattr_user.c | 94 + + 34 files changed, 6914 insertions(+), 524 deletions(-) + create mode 100644 fs/ocfs2/xattr.c + create mode 100644 fs/ocfs2/xattr.h + create mode 100644 fs/ocfs2/xattr_trusted.c + create mode 100644 fs/ocfs2/xattr_user.c +Merging ext4/next +$ git merge ext4/next +Already up-to-date. +Merging async_tx/next +$ git merge async_tx/next +Already up-to-date. +Merging udf/for_next +$ git merge udf/for_next +Merge made by recursive. + fs/udf/ialloc.c | 44 +++++++++++++++++++------------------------- + 1 files changed, 19 insertions(+), 25 deletions(-) +Merging net/master +$ git merge net/master +Auto-merged drivers/net/ixgbe/ixgbe_main.c +Auto-merged drivers/net/wireless/ath9k/hw.c +Auto-merged drivers/net/wireless/ath9k/main.c +Auto-merged drivers/net/wireless/ath9k/recv.c +Auto-merged drivers/net/wireless/ath9k/xmit.c +Removed drivers/net/wireless/b43/phy.h +Auto-merged drivers/net/wireless/iwlwifi/iwl-agn.c +Auto-merged drivers/net/wireless/iwlwifi/iwl-core.c +Auto-merged drivers/net/wireless/iwlwifi/iwl-dev.h +Auto-merged drivers/net/wireless/iwlwifi/iwl-rx.c +Auto-merged drivers/net/wireless/iwlwifi/iwl-tx.c +Auto-merged drivers/net/wireless/libertas/if_cs.c +Auto-merged drivers/net/wireless/mac80211_hwsim.c +Auto-merged drivers/net/wireless/orinoco.c +Auto-merged drivers/net/wireless/rt2x00/rt2x00reg.h +Removed net/ipv4/ipvs/ip_vs_proto_esp.c +Auto-merged net/mac80211/ieee80211_i.h +Merge made by recursive. + drivers/net/8139cp.c | 14 +- + drivers/net/8139too.c | 4 +- + drivers/net/Makefile | 2 +- + drivers/net/bonding/bond_alb.c | 4 +- + drivers/net/bonding/bond_main.c | 6 +- + drivers/net/e1000e/82571.c | 153 +- + drivers/net/e1000e/defines.h | 15 + + drivers/net/e1000e/e1000.h | 31 +- + drivers/net/e1000e/es2lan.c | 2 +- + drivers/net/e1000e/ethtool.c | 60 +- + drivers/net/e1000e/hw.h | 15 +- + drivers/net/e1000e/ich8lan.c | 173 +- + drivers/net/e1000e/lib.c | 7 +- + drivers/net/e1000e/netdev.c | 435 +++- + drivers/net/e1000e/param.c | 27 + + drivers/net/e1000e/phy.c | 194 ++- + drivers/net/ibm_newemac/mal.h | 4 +- + drivers/net/igb/igb_main.c | 12 +- + drivers/net/ixgbe/ixgbe.h | 43 +- + drivers/net/ixgbe/ixgbe_82598.c | 6 +- + drivers/net/ixgbe/ixgbe_common.c | 140 +- + drivers/net/ixgbe/ixgbe_common.h | 4 +- + drivers/net/ixgbe/ixgbe_ethtool.c | 6 +- + drivers/net/ixgbe/ixgbe_main.c | 721 +++-- + drivers/net/ixgbe/ixgbe_type.h | 47 +- + drivers/net/r8169.c | 401 ++- + drivers/net/s2io.c | 4 +- + drivers/net/sfc/bitfield.h | 178 +- + drivers/net/sfc/boards.c | 12 +- + drivers/net/sfc/boards.h | 2 - + drivers/net/sfc/efx.c | 471 ++-- + drivers/net/sfc/efx.h | 14 +- + drivers/net/sfc/enum.h | 9 +- + drivers/net/sfc/ethtool.c | 184 +- + drivers/net/sfc/falcon.c | 767 ++++-- + drivers/net/sfc/falcon.h | 16 +- + drivers/net/sfc/falcon_hwdefs.h | 79 +- + drivers/net/sfc/falcon_xmac.c | 330 +-- + drivers/net/sfc/mac.h | 4 - + drivers/net/sfc/mdio_10g.c | 16 +- + drivers/net/sfc/mdio_10g.h | 13 +- + drivers/net/sfc/net_driver.h | 136 +- + drivers/net/sfc/phy.h | 10 +- + drivers/net/sfc/rx.c | 78 +- + drivers/net/sfc/rx.h | 4 +- + drivers/net/sfc/selftest.c | 391 ++- + drivers/net/sfc/selftest.h | 13 +- + drivers/net/sfc/sfe4001.c | 244 +- + drivers/net/sfc/spi.h | 89 +- + drivers/net/sfc/tenxpress.c | 90 +- + drivers/net/sfc/tx.c | 383 ++- + drivers/net/sfc/tx.h | 2 +- + drivers/net/sfc/workarounds.h | 2 - + drivers/net/sfc/xfp_phy.c | 11 +- + drivers/net/sky2.c | 170 +- + drivers/net/via-rhine.c | 8 +- + drivers/net/wireless/Kconfig | 17 +- + drivers/net/wireless/Makefile | 4 +- + drivers/net/wireless/airo.c | 16 +- + drivers/net/wireless/airport.c | 3 +- + drivers/net/wireless/ath5k/ath5k.h | 162 +- + drivers/net/wireless/ath5k/base.c | 383 +-- + drivers/net/wireless/ath5k/base.h | 8 +- + drivers/net/wireless/ath5k/hw.c | 77 +- + drivers/net/wireless/ath9k/ath9k.h | 55 +- + drivers/net/wireless/ath9k/beacon.c | 259 +- + drivers/net/wireless/ath9k/core.c | 306 +-- + drivers/net/wireless/ath9k/core.h | 248 +- + drivers/net/wireless/ath9k/hw.c | 150 +- + drivers/net/wireless/ath9k/hw.h | 120 +- + drivers/net/wireless/ath9k/main.c | 244 ++- + drivers/net/wireless/ath9k/phy.h | 12 +- + drivers/net/wireless/ath9k/rc.c | 183 +- + drivers/net/wireless/ath9k/rc.h | 222 +- + drivers/net/wireless/ath9k/recv.c | 81 +- + drivers/net/wireless/ath9k/reg.h | 6 - + drivers/net/wireless/ath9k/xmit.c | 400 +-- + drivers/net/wireless/b43/Makefile | 4 +- + drivers/net/wireless/b43/b43.h | 137 +- + drivers/net/wireless/b43/debugfs.c | 79 +- + drivers/net/wireless/b43/lo.c | 120 +- + drivers/net/wireless/b43/lo.h | 4 +- + drivers/net/wireless/b43/main.c | 184 +- + drivers/net/wireless/b43/nphy.c | 148 +- + drivers/net/wireless/b43/nphy.h | 54 +- + drivers/net/wireless/b43/phy.c | 3421 +------------------- + drivers/net/wireless/b43/phy.h | 340 -- + drivers/net/wireless/b43/phy_a.c | 543 ++++ + drivers/net/wireless/b43/phy_a.h | 124 + + drivers/net/wireless/b43/phy_common.c | 367 +++ + drivers/net/wireless/b43/phy_common.h | 381 +++ + drivers/net/wireless/b43/phy_g.c | 3251 +++++++++++++++++++ + drivers/net/wireless/b43/phy_g.h | 209 ++ + drivers/net/wireless/b43/rfkill.c | 5 +- + drivers/net/wireless/b43/sysfs.c | 23 +- + drivers/net/wireless/b43/tables.c | 43 +- + drivers/net/wireless/b43/tables_nphy.c | 2 +- + drivers/net/wireless/b43/wa.c | 2 +- + drivers/net/wireless/b43/xmit.c | 8 +- + drivers/net/wireless/b43legacy/xmit.c | 4 +- + drivers/net/wireless/hermes.c | 124 +- + drivers/net/wireless/hermes.h | 45 + + drivers/net/wireless/hermes_dld.c | 730 +++++ + drivers/net/wireless/hermes_dld.h | 48 + + drivers/net/wireless/hermes_rid.h | 17 + + drivers/net/wireless/ipw2100.c | 2 +- + drivers/net/wireless/ipw2200.h | 4 +- + drivers/net/wireless/iwlwifi/iwl-3945-debug.h | 4 +- + drivers/net/wireless/iwlwifi/iwl-3945.c | 104 +- + drivers/net/wireless/iwlwifi/iwl-3945.h | 1 - + drivers/net/wireless/iwlwifi/iwl-agn.c | 2 - + drivers/net/wireless/iwlwifi/iwl-core.c | 1 - + drivers/net/wireless/iwlwifi/iwl-debug.h | 12 +- + drivers/net/wireless/iwlwifi/iwl-dev.h | 16 - + drivers/net/wireless/iwlwifi/iwl-hcmd.c | 14 +- + drivers/net/wireless/iwlwifi/iwl-rx.c | 125 +- + drivers/net/wireless/iwlwifi/iwl-tx.c | 32 +- + drivers/net/wireless/iwlwifi/iwl3945-base.c | 8 +- + drivers/net/wireless/libertas/assoc.c | 744 ++--- + drivers/net/wireless/libertas/assoc.h | 18 +- + drivers/net/wireless/libertas/cmd.c | 168 +- + drivers/net/wireless/libertas/cmd.h | 6 + + drivers/net/wireless/libertas/cmdresp.c | 33 - + drivers/net/wireless/libertas/decl.h | 1 - + drivers/net/wireless/libertas/defs.h | 6 +- + drivers/net/wireless/libertas/dev.h | 7 +- + drivers/net/wireless/libertas/host.h | 26 +- + drivers/net/wireless/libertas/hostcmd.h | 50 +- + drivers/net/wireless/libertas/if_cs.c | 2 +- + drivers/net/wireless/libertas/if_usb.c | 177 +- + drivers/net/wireless/libertas/if_usb.h | 5 + + drivers/net/wireless/libertas/main.c | 21 +- + drivers/net/wireless/libertas/scan.c | 5 + + drivers/net/wireless/libertas/wext.c | 148 +- + drivers/net/wireless/libertas_tf/Makefile | 6 + + drivers/net/wireless/libertas_tf/cmd.c | 669 ++++ + drivers/net/wireless/libertas_tf/if_usb.c | 766 +++++ + drivers/net/wireless/libertas_tf/if_usb.h | 98 + + drivers/net/wireless/libertas_tf/libertas_tf.h | 514 +++ + drivers/net/wireless/libertas_tf/main.c | 662 ++++ + drivers/net/wireless/mac80211_hwsim.c | 16 +- + drivers/net/wireless/orinoco.c | 1949 ++++++++++- + drivers/net/wireless/orinoco.h | 61 +- + drivers/net/wireless/orinoco_cs.c | 3 +- + drivers/net/wireless/orinoco_nortel.c | 3 +- + drivers/net/wireless/orinoco_pci.c | 3 +- + drivers/net/wireless/orinoco_plx.c | 3 +- + drivers/net/wireless/orinoco_tmd.c | 3 +- + drivers/net/wireless/p54/p54.h | 8 +- + drivers/net/wireless/p54/p54common.c | 170 +- + drivers/net/wireless/p54/p54common.h | 29 +- + drivers/net/wireless/p54/p54pci.c | 276 +- + drivers/net/wireless/p54/p54pci.h | 20 +- + drivers/net/wireless/p54/p54usb.c | 32 +- + drivers/net/wireless/p54/p54usb.h | 6 +- + drivers/net/wireless/prism54/isl_ioctl.c | 8 +- + drivers/net/wireless/rt2x00/Kconfig | 6 + + drivers/net/wireless/rt2x00/Makefile | 1 + + drivers/net/wireless/rt2x00/rt2400pci.c | 42 +- + drivers/net/wireless/rt2x00/rt2400pci.h | 22 +- + drivers/net/wireless/rt2x00/rt2500pci.c | 43 +- + drivers/net/wireless/rt2x00/rt2500pci.h | 17 +- + drivers/net/wireless/rt2x00/rt2500usb.c | 46 +- + drivers/net/wireless/rt2x00/rt2500usb.h | 17 +- + drivers/net/wireless/rt2x00/rt2x00.h | 88 +- + drivers/net/wireless/rt2x00/rt2x00config.c | 8 +- + drivers/net/wireless/rt2x00/rt2x00crypto.c | 215 ++ + drivers/net/wireless/rt2x00/rt2x00debug.c | 97 + + drivers/net/wireless/rt2x00/rt2x00dev.c | 116 +- + drivers/net/wireless/rt2x00/rt2x00lib.h | 47 + + drivers/net/wireless/rt2x00/rt2x00mac.c | 226 +- + drivers/net/wireless/rt2x00/rt2x00queue.c | 112 +- + drivers/net/wireless/rt2x00/rt2x00queue.h | 82 +- + drivers/net/wireless/rt2x00/rt2x00reg.h | 19 +- + drivers/net/wireless/rt2x00/rt2x00rfkill.c | 6 +- + drivers/net/wireless/rt2x00/rt2x00usb.c | 21 +- + drivers/net/wireless/rt2x00/rt61pci.c | 427 +++- + drivers/net/wireless/rt2x00/rt61pci.h | 38 +- + drivers/net/wireless/rt2x00/rt73usb.c | 437 +++- + drivers/net/wireless/rt2x00/rt73usb.h | 38 +- + drivers/net/wireless/rtl8180.h | 31 - + drivers/net/wireless/rtl8180_dev.c | 34 +- + drivers/net/wireless/rtl8187.h | 6 - + drivers/net/wireless/rtl8187_dev.c | 10 +- + drivers/net/wireless/rtl818x.h | 35 + + drivers/net/wireless/spectrum_cs.c | 426 +--- + drivers/net/wireless/wl3501_cs.c | 8 +- + drivers/ssb/pci.c | 84 +- + include/linux/ieee80211.h | 1 + + include/linux/if_ether.h | 1 + + include/linux/ip_vs.h | 160 + + include/linux/nl80211.h | 31 + + include/linux/rfkill.h | 7 +- + include/linux/ssb/ssb_regs.h | 19 +- + include/net/cfg80211.h | 23 + + include/net/inet_connection_sock.h | 2 + + include/net/ip_vs.h | 2 + + include/net/mac80211.h | 31 +- + include/net/netlink.h | 82 - + include/net/sock.h | 2 + + net/Kconfig | 8 +- + net/dccp/ccids/ccid2.c | 2 +- + net/dccp/ccids/ccid3.c | 2 +- + net/dccp/ccids/lib/loss_interval.c | 6 +- + net/dccp/ccids/lib/tfrc.c | 2 +- + net/dccp/input.c | 4 +- + net/dccp/options.c | 13 +- + net/dccp/proto.c | 4 +- + net/ieee80211/ieee80211_module.c | 8 +- + net/ipv4/inet_diag.c | 6 +- + net/ipv4/ipvs/Kconfig | 6 + + net/ipv4/ipvs/Makefile | 3 +- + net/ipv4/ipvs/ip_vs_core.c | 8 +- + net/ipv4/ipvs/ip_vs_ctl.c | 896 +++++- + net/ipv4/ipvs/ip_vs_est.c | 18 +- + net/ipv4/ipvs/ip_vs_lblc.c | 213 +- + net/ipv4/ipvs/ip_vs_lblcr.c | 238 +- + net/ipv4/ipvs/ip_vs_lc.c | 21 - + net/ipv4/ipvs/ip_vs_nq.c | 24 - + .../{ip_vs_proto_ah.c => ip_vs_proto_ah_esp.c} | 69 +- + net/ipv4/ipvs/ip_vs_proto_esp.c | 176 - + net/ipv4/ipvs/ip_vs_rr.c | 7 - + net/ipv4/ipvs/ip_vs_sed.c | 24 - + net/ipv4/ipvs/ip_vs_wlc.c | 24 - + net/ipv4/route.c | 14 +- + net/ipv4/tcp_input.c | 208 +- + net/ipv4/tcp_ipv4.c | 26 +- + net/mac80211/cfg.c | 63 +- + net/mac80211/debugfs_sta.c | 2 +- + net/mac80211/event.c | 5 +- + net/mac80211/ieee80211_i.h | 121 +- + net/mac80211/iface.c | 8 +- + net/mac80211/main.c | 86 +- + net/mac80211/mesh.c | 29 +- + net/mac80211/mesh.h | 61 +- + net/mac80211/mesh_hwmp.c | 120 +- + net/mac80211/mesh_pathtbl.c | 76 +- + net/mac80211/mesh_plink.c | 56 +- + net/mac80211/mlme.c | 1082 +++---- + net/mac80211/rx.c | 140 +- + net/mac80211/tx.c | 46 +- + net/mac80211/util.c | 46 +- + net/mac80211/wep.c | 14 +- + net/mac80211/wext.c | 53 +- + net/mac80211/wme.c | 2 - + net/mac80211/wme.h | 2 - + net/mac80211/wpa.c | 2 +- + net/rfkill/rfkill-input.h | 1 + + net/rfkill/rfkill.c | 238 ++- + net/sched/sch_netem.c | 18 +- + net/sched/sch_prio.c | 6 +- + net/wireless/nl80211.c | 62 + + 252 files changed, 21932 insertions(+), 12279 deletions(-) + delete mode 100644 drivers/net/wireless/b43/phy.h + create mode 100644 drivers/net/wireless/b43/phy_a.c + create mode 100644 drivers/net/wireless/b43/phy_a.h + create mode 100644 drivers/net/wireless/b43/phy_common.c + create mode 100644 drivers/net/wireless/b43/phy_common.h + create mode 100644 drivers/net/wireless/b43/phy_g.c + create mode 100644 drivers/net/wireless/b43/phy_g.h + create mode 100644 drivers/net/wireless/hermes_dld.c + create mode 100644 drivers/net/wireless/hermes_dld.h + create mode 100644 drivers/net/wireless/libertas_tf/Makefile + create mode 100644 drivers/net/wireless/libertas_tf/cmd.c + create mode 100644 drivers/net/wireless/libertas_tf/if_usb.c + create mode 100644 drivers/net/wireless/libertas_tf/if_usb.h + create mode 100644 drivers/net/wireless/libertas_tf/libertas_tf.h + create mode 100644 drivers/net/wireless/libertas_tf/main.c + create mode 100644 drivers/net/wireless/rt2x00/rt2x00crypto.c + rename net/ipv4/ipvs/{ip_vs_proto_ah.c => ip_vs_proto_ah_esp.c} (63%) + delete mode 100644 net/ipv4/ipvs/ip_vs_proto_esp.c +Merging mtd/master +$ git merge mtd/master +Removed drivers/mtd/maps/ebony.c +Removed drivers/mtd/maps/ocotea.c +Removed drivers/mtd/maps/omap-toto-flash.c +Removed drivers/mtd/maps/walnut.c +Auto-merged drivers/mtd/mtdchar.c +Removed drivers/mtd/nand/toto.c +Auto-merged fs/Kconfig +Merge made by recursive. + Documentation/mtd/nand_ecc.txt | 714 +++++++++++++++++ + arch/arm/mach-pxa/include/mach/pxa3xx_nand.h | 44 +- + arch/arm/plat-mxc/include/mach/mxc_nand.h | 27 + + arch/arm/plat-omap/include/mach/onenand.h | 6 +- + drivers/mtd/Kconfig | 5 + + drivers/mtd/chips/Kconfig | 4 +- + drivers/mtd/chips/cfi_cmdset_0001.c | 54 +- + drivers/mtd/chips/cfi_probe.c | 58 +-- + drivers/mtd/chips/cfi_util.c | 66 ++- + drivers/mtd/chips/gen_probe.c | 2 +- + drivers/mtd/devices/Kconfig | 21 + + drivers/mtd/devices/m25p80.c | 136 +++-- + drivers/mtd/devices/mtd_dataflash.c | 214 +++++- + drivers/mtd/maps/Kconfig | 31 - + drivers/mtd/maps/Makefile | 4 - + drivers/mtd/maps/ebony.c | 163 ---- + drivers/mtd/maps/ocotea.c | 154 ---- + drivers/mtd/maps/omap-toto-flash.c | 133 ---- + drivers/mtd/maps/walnut.c | 122 --- + drivers/mtd/mtdchar.c | 4 +- + drivers/mtd/mtdconcat.c | 4 +- + drivers/mtd/mtdpart.c | 4 +- + drivers/mtd/nand/Kconfig | 20 +- + drivers/mtd/nand/Makefile | 2 +- + drivers/mtd/nand/mxc_nand.c | 1077 ++++++++++++++++++++++++++ + drivers/mtd/nand/nand_base.c | 8 +- + drivers/mtd/nand/nand_ecc.c | 554 ++++++++++--- + drivers/mtd/nand/nandsim.c | 1 - + drivers/mtd/nand/pxa3xx_nand.c | 147 ++-- + drivers/mtd/nand/toto.c | 206 ----- + drivers/mtd/onenand/Kconfig | 8 + + drivers/mtd/onenand/Makefile | 1 + + drivers/mtd/onenand/omap2.c | 782 +++++++++++++++++++ + drivers/mtd/onenand/onenand_base.c | 2 +- + drivers/mtd/ssfdc.c | 3 +- + fs/Kconfig | 190 +----- + fs/jffs2/Kconfig | 188 +++++ + fs/jffs2/dir.c | 2 +- + fs/jffs2/erase.c | 4 +- + fs/jffs2/fs.c | 6 +- + include/linux/mtd/cfi.h | 9 +- + include/linux/mtd/flashchip.h | 4 + + include/linux/mtd/mtd.h | 4 +- + include/linux/mtd/nand.h | 1 + + include/linux/mtd/onenand_regs.h | 2 + + 45 files changed, 3835 insertions(+), 1356 deletions(-) + create mode 100644 Documentation/mtd/nand_ecc.txt + create mode 100644 arch/arm/plat-mxc/include/mach/mxc_nand.h + delete mode 100644 drivers/mtd/maps/ebony.c + delete mode 100644 drivers/mtd/maps/ocotea.c + delete mode 100644 drivers/mtd/maps/omap-toto-flash.c + delete mode 100644 drivers/mtd/maps/walnut.c + create mode 100644 drivers/mtd/nand/mxc_nand.c + delete mode 100644 drivers/mtd/nand/toto.c + create mode 100644 drivers/mtd/onenand/omap2.c + create mode 100644 fs/jffs2/Kconfig +Merging wireless/master +$ git merge wireless/master +Already up-to-date. +Merging crypto/master +$ git merge crypto/master +Merge made by recursive. + arch/x86/crypto/Makefile | 2 + + arch/x86/crypto/crc32c-intel.c | 197 + + crypto/Kconfig | 127 +- + crypto/Makefile | 12 +- + crypto/algapi.c | 147 +- + crypto/{cryptomgr.c => algboss.c} | 92 +- + crypto/ansi_cprng.c | 417 ++ + crypto/api.c | 81 +- + crypto/blkcipher.c | 29 - + crypto/chainiv.c | 44 +- + crypto/eseqiv.c | 35 +- + crypto/fips.c | 27 + + crypto/internal.h | 18 +- + crypto/krng.c | 66 + + crypto/proc.c | 57 +- + crypto/rng.c | 126 + + crypto/seqiv.c | 27 +- + crypto/tcrypt.c | 1347 +----- + crypto/tcrypt.h | 8709 +----------------------------------- + crypto/testmgr.c | 1868 ++++++++ + crypto/testmgr.h | 8738 ++++++++++++++++++++++++++++++++++++ + include/crypto/internal/rng.h | 26 + + include/crypto/internal/skcipher.h | 6 - + include/crypto/rng.h | 75 + + include/linux/crypto.h | 35 + + 25 files changed, 12249 insertions(+), 10059 deletions(-) + create mode 100644 arch/x86/crypto/crc32c-intel.c + rename crypto/{cryptomgr.c => algboss.c} (69%) + create mode 100644 crypto/ansi_cprng.c + create mode 100644 crypto/fips.c + create mode 100644 crypto/krng.c + create mode 100644 crypto/rng.c + create mode 100644 crypto/testmgr.c + create mode 100644 crypto/testmgr.h + create mode 100644 include/crypto/internal/rng.h + create mode 100644 include/crypto/rng.h +Merging vfs/for-next +$ git merge vfs/for-next +Auto-merged arch/parisc/hpux/fs.c +Auto-merged fs/jffs2/dir.c +Auto-merged fs/nfsd/vfs.c +Auto-merged include/linux/fs.h +Auto-merged init/main.c +Merge made by recursive. + arch/alpha/kernel/osf_sys.c | 7 +- + arch/parisc/hpux/fs.c | 5 +- + arch/powerpc/platforms/cell/spufs/syscalls.c | 4 +- + drivers/md/dm-table.c | 21 +--- + fs/block_dev.c | 14 ++-- + fs/char_dev.c | 21 +++-- + fs/compat.c | 22 ++--- + fs/configfs/symlink.c | 16 ++-- + fs/dcache.c | 85 +++++++++--------- + fs/dquot.c | 10 +- + fs/ecryptfs/main.c | 23 ++--- + fs/efs/namei.c | 29 +----- + fs/exportfs/expfs.c | 16 ++-- + fs/ext2/dir.c | 14 ++-- + fs/ext2/ext2.h | 4 +- + fs/ext2/namei.c | 30 ++----- + fs/ext3/namei.c | 84 +++++++---------- + fs/ext3/super.c | 22 ++-- + fs/ext4/namei.c | 14 +--- + fs/ext4/super.c | 22 ++-- + fs/fat/inode.c | 52 ++++------- + fs/fuse/inode.c | 23 ++--- + fs/gfs2/ops_export.c | 33 ++----- + fs/gfs2/ops_inode.c | 2 +- + fs/hpfs/file.c | 2 +- + fs/hpfs/hpfs_fn.h | 2 +- + fs/hpfs/inode.c | 29 ++++-- + fs/hpfs/namei.c | 2 +- + fs/isofs/export.c | 33 +------ + fs/jffs2/dir.c | 4 +- + fs/jffs2/super.c | 48 ++++++++++ + fs/jfs/namei.c | 15 +--- + fs/libfs.c | 26 +----- + fs/namei.c | 75 +++++++-------- + fs/namespace.c | 126 ++++++++++++------------- + fs/nfs/dir.c | 6 +- + fs/nfs/getroot.c | 6 +- + fs/nfsd/export.c | 125 ++++++++++++------------- + fs/nfsd/nfs4recover.c | 50 +++++----- + fs/nfsd/nfs4state.c | 8 +- + fs/nfsd/nfsctl.c | 8 +- + fs/nfsd/vfs.c | 126 ++++++++++++++++++++++--- + fs/ntfs/namei.c | 22 +---- + fs/ocfs2/export.c | 30 +----- + fs/read_write.c | 58 ++++++++---- + fs/readdir.c | 22 ++--- + fs/reiserfs/inode.c | 13 +-- + fs/reiserfs/namei.c | 11 +-- + fs/reiserfs/super.c | 18 ++-- + fs/super.c | 15 +-- + fs/udf/namei.c | 17 +--- + fs/xfs/linux-2.6/xfs_export.c | 32 +------ + fs/xfs/linux-2.6/xfs_file.c | 128 -------------------------- + fs/xfs/linux-2.6/xfs_ioctl.c | 3 +- + include/linux/dcache.h | 2 +- + include/linux/fs.h | 1 - + include/linux/namei.h | 7 +- + init/main.c | 1 - + kernel/audit_tree.c | 48 +++++----- + net/unix/af_unix.c | 18 ++-- + 60 files changed, 724 insertions(+), 986 deletions(-) +Merging sound/for-next +$ git merge sound/for-next +Auto-merged Documentation/sound/alsa/DocBook/writing-an-alsa-driver.tmpl +Auto-merged MAINTAINERS +Auto-merged include/sound/core.h +Removed include/sound/cs4231.h +Auto-merged include/sound/memalloc.h +Auto-merged sound/core/init.c +Auto-merged sound/core/memalloc.c +Auto-merged sound/core/sound.c +Removed sound/isa/cs423x/cs4231_lib.c +Removed sound/oss/hal2.c +Removed sound/oss/hal2.h +Auto-merged sound/sound_core.c +Auto-merged sound/sparc/amd7930.c +Auto-merged sound/sparc/cs4231.c +Auto-merged sound/sparc/dbri.c +Merge made by recursive. + Documentation/sound/alsa/ALSA-Configuration.txt | 60 +- + .../sound/alsa/DocBook/writing-an-alsa-driver.tmpl | 62 +- + MAINTAINERS | 2 + + arch/um/Kconfig.char | 4 + + drivers/media/video/saa7134/saa7134-alsa.c | 13 +- + include/sound/ad1848.h | 218 -- + include/sound/asound.h | 3 +- + include/sound/asoundef.h | 89 +- + include/sound/core.h | 30 +- + include/sound/cs4231.h | 175 -- + include/sound/jack.h | 75 + + include/sound/memalloc.h | 16 +- + include/sound/minors.h | 2 + + include/sound/pcm.h | 39 +- + include/sound/sb.h | 5 + + include/sound/snd_wavefront.h | 1 - + include/sound/soc-of-simple.h | 25 + + include/sound/soc.h | 74 +- + include/sound/version.h | 2 +- + include/sound/vx_core.h | 9 - + include/sound/wss.h | 235 ++ + sound/Kconfig | 5 + + sound/aoa/codecs/snd-aoa-codec-tas.c | 6 +- + sound/arm/aaci.c | 6 +- + sound/arm/sa11xx-uda1341.c | 5 +- + sound/core/Kconfig | 7 + + sound/core/Makefile | 1 + + sound/core/control.c | 50 +- + sound/core/control_compat.c | 3 +- + sound/core/device.c | 26 +- + sound/core/hwdep.c | 16 +- + sound/core/info.c | 23 +- + sound/core/info_oss.c | 6 +- + sound/core/init.c | 3 +- + sound/core/jack.c | 163 ++ + sound/core/memalloc.c | 52 +- + sound/core/oss/copy.c | 30 +- + sound/core/oss/io.c | 24 +- + sound/core/oss/linear.c | 29 +- + sound/core/oss/mixer_oss.c | 18 +- + sound/core/oss/mulaw.c | 27 +- + sound/core/oss/pcm_oss.c | 52 +- + sound/core/oss/pcm_plugin.c | 38 +- + sound/core/oss/rate.c | 42 +- + sound/core/oss/route.c | 12 +- + sound/core/pcm.c | 84 +- + sound/core/pcm_compat.c | 3 +- + sound/core/pcm_lib.c | 102 +- + sound/core/pcm_memory.c | 40 +- + sound/core/pcm_native.c | 140 +- + sound/core/pcm_timer.c | 6 +- + sound/core/rawmidi.c | 25 +- + sound/core/rtctimer.c | 6 +- + sound/core/seq/oss/seq_oss.c | 12 +- + sound/core/seq/oss/seq_oss_synth.c | 6 +- + sound/core/seq/seq_clientmgr.c | 30 +- + sound/core/seq/seq_compat.c | 3 +- + sound/core/seq/seq_device.c | 6 +- + sound/core/seq/seq_fifo.c | 15 +- + sound/core/seq/seq_memory.c | 12 +- + sound/core/seq/seq_midi.c | 15 +- + sound/core/seq/seq_ports.c | 13 +- + sound/core/seq/seq_prioq.c | 4 +- + sound/core/seq/seq_queue.c | 6 +- + sound/core/seq/seq_timer.c | 24 +- + sound/core/sgbuf.c | 62 +- + sound/core/sound.c | 14 +- + sound/core/sound_oss.c | 12 +- + sound/core/timer.c | 33 +- + sound/core/timer_compat.c | 9 +- + sound/drivers/dummy.c | 41 +- + sound/drivers/opl3/opl3_lib.c | 6 +- + sound/drivers/opl3/opl3_midi.c | 6 +- + sound/drivers/opl3/opl3_oss.c | 15 +- + sound/drivers/opl3/opl3_synth.c | 3 +- + sound/drivers/opl4/opl4_synth.c | 2 +- + sound/drivers/vx/vx_cmd.c | 3 +- + sound/drivers/vx/vx_core.c | 21 +- + sound/drivers/vx/vx_hwdep.c | 6 +- + sound/drivers/vx/vx_mixer.c | 3 +- + sound/drivers/vx/vx_pcm.c | 9 +- + sound/drivers/vx/vx_uer.c | 6 +- + sound/i2c/cs8427.c | 15 +- + sound/i2c/i2c.c | 6 +- + sound/i2c/l3/uda1341.c | 3 +- + sound/i2c/other/ak4114.c | 3 +- + sound/i2c/other/ak4117.c | 3 +- + sound/i2c/other/ak4xxx-adda.c | 4 +- + sound/isa/Kconfig | 44 +- + sound/isa/Makefile | 2 +- + sound/isa/ad1816a/ad1816a.c | 4 +- + sound/isa/ad1816a/ad1816a_lib.c | 6 +- + sound/isa/ad1848/Makefile | 2 - + sound/isa/ad1848/ad1848.c | 17 +- + sound/isa/ad1848/ad1848_lib.c | 1267 ----------- + sound/isa/azt2320.c | 29 +- + sound/isa/cmi8330.c | 106 +- + sound/isa/cs423x/Makefile | 2 - + sound/isa/cs423x/cs4231.c | 18 +- + sound/isa/cs423x/cs4231_lib.c | 1945 ---------------- + sound/isa/cs423x/cs4236.c | 51 +- + sound/isa/cs423x/cs4236_lib.c | 349 ++-- + sound/isa/es1688/es1688_lib.c | 3 +- + sound/isa/gus/gus_main.c | 6 +- + sound/isa/gus/gus_mixer.c | 6 +- + sound/isa/gus/gus_pcm.c | 12 +- + sound/isa/gus/gusmax.c | 50 +- + sound/isa/gus/interwave.c | 67 +- + sound/isa/opl3sa2.c | 99 +- + sound/isa/opti9xx/miro.c | 28 +- + sound/isa/opti9xx/opti92x-ad1848.c | 70 +- + sound/isa/sb/emu8000.c | 3 +- + sound/isa/sb/emu8000_patch.c | 3 +- + sound/isa/sb/sb16_csp.c | 9 +- + sound/isa/sb/sb16_main.c | 3 +- + sound/isa/sb/sb8_main.c | 8 +- + sound/isa/sb/sb_common.c | 3 +- + sound/isa/sb/sb_mixer.c | 9 +- + sound/isa/sc6000.c | 18 +- + sound/isa/sgalaxy.c | 43 +- + sound/isa/sscape.c | 63 +- + sound/isa/wavefront/wavefront.c | 62 +- + sound/isa/wavefront/wavefront_fx.c | 8 +- + sound/isa/wavefront/wavefront_midi.c | 24 +- + sound/isa/wavefront/wavefront_synth.c | 7 +- + sound/isa/wss/Makefile | 10 + + sound/isa/wss/wss_lib.c | 2322 ++++++++++++++++++++ + sound/mips/au1x00.c | 6 +- + sound/oss/Kconfig | 7 - + sound/oss/Makefile | 1 - + sound/oss/dmasound/Kconfig | 1 + + sound/oss/hal2.c | 1558 ------------- + sound/oss/hal2.h | 248 --- + sound/oss/mpu401.c | 2 +- + sound/parisc/harmony.c | 3 +- + sound/pci/Kconfig | 22 +- + sound/pci/ac97/ac97_codec.c | 41 +- + sound/pci/ac97/ac97_patch.c | 208 ++- + sound/pci/ad1889.c | 6 +- + sound/pci/ak4531_codec.c | 10 +- + sound/pci/als4000.c | 391 +++- + sound/pci/atiixp.c | 13 +- + sound/pci/atiixp_modem.c | 10 +- + sound/pci/au88x0/au88x0.h | 7 +- + sound/pci/au88x0/au88x0_core.c | 40 +- + sound/pci/au88x0/au88x0_pcm.c | 14 +- + sound/pci/azt3328.c | 6 +- + sound/pci/bt87x.c | 5 +- + sound/pci/ca0106/ca_midi.c | 20 +- + sound/pci/cmipci.c | 9 +- + sound/pci/cs4281.c | 13 +- + sound/pci/cs46xx/cs46xx_lib.c | 72 +- + sound/pci/cs46xx/dsp_spos.c | 51 +- + sound/pci/cs46xx/dsp_spos_scb_lib.c | 115 +- + sound/pci/echoaudio/darla20_dsp.c | 3 +- + sound/pci/echoaudio/darla24_dsp.c | 8 +- + sound/pci/echoaudio/echo3g_dsp.c | 9 +- + sound/pci/echoaudio/echoaudio.c | 22 +- + sound/pci/echoaudio/echoaudio_3g.c | 11 +- + sound/pci/echoaudio/echoaudio_dsp.c | 21 +- + sound/pci/echoaudio/echoaudio_gml.c | 6 +- + sound/pci/echoaudio/gina20_dsp.c | 6 +- + sound/pci/echoaudio/gina24_dsp.c | 11 +- + sound/pci/echoaudio/indigo_dsp.c | 8 +- + sound/pci/echoaudio/indigodj_dsp.c | 8 +- + sound/pci/echoaudio/indigoio_dsp.c | 8 +- + sound/pci/echoaudio/layla20_dsp.c | 9 +- + sound/pci/echoaudio/layla24_dsp.c | 11 +- + sound/pci/echoaudio/mia_dsp.c | 13 +- + sound/pci/echoaudio/midi.c | 6 +- + sound/pci/echoaudio/mona_dsp.c | 6 +- + sound/pci/emu10k1/emu10k1_callback.c | 6 +- + sound/pci/emu10k1/emu10k1_patch.c | 23 +- + sound/pci/emu10k1/emu10k1x.c | 18 +- + sound/pci/emu10k1/emufx.c | 6 +- + sound/pci/emu10k1/emumpu401.c | 18 +- + sound/pci/emu10k1/memory.c | 31 +- + sound/pci/emu10k1/voice.c | 9 +- + sound/pci/es1938.c | 3 +- + sound/pci/es1968.c | 6 +- + sound/pci/hda/Makefile | 1 + + sound/pci/hda/hda_beep.c | 134 ++ + sound/pci/hda/hda_beep.h | 44 + + sound/pci/hda/hda_codec.c | 29 +- + sound/pci/hda/hda_codec.h | 92 +- + sound/pci/hda/hda_generic.c | 3 +- + sound/pci/hda/hda_intel.c | 105 +- + sound/pci/hda/hda_proc.c | 23 +- + sound/pci/hda/patch_analog.c | 80 +- + sound/pci/hda/patch_atihdmi.c | 45 +- + sound/pci/hda/patch_realtek.c | 1788 ++++++++++++++-- + sound/pci/hda/patch_sigmatel.c | 485 ++++- + sound/pci/ice1712/ak4xxx.c | 3 +- + sound/pci/ice1712/aureon.c | 22 +- + sound/pci/ice1712/delta.h | 1 + + sound/pci/ice1712/ews.c | 9 +- + sound/pci/ice1712/ice1712.c | 3 +- + sound/pci/ice1712/ice1724.c | 8 +- + sound/pci/ice1712/juli.c | 3 +- + sound/pci/ice1712/phase.c | 35 +- + sound/pci/ice1712/phase.h | 4 +- + sound/pci/ice1712/revo.c | 17 +- + sound/pci/intel8x0.c | 44 +- + sound/pci/intel8x0m.c | 3 +- + sound/pci/korg1212/korg1212.c | 9 +- + sound/pci/maestro3.c | 10 +- + sound/pci/mixart/mixart.c | 4 +- + sound/pci/mixart/mixart_core.c | 18 +- + sound/pci/mixart/mixart_hwdep.c | 19 +- + sound/pci/mixart/mixart_mixer.c | 8 +- + sound/pci/nm256/nm256.c | 15 +- + sound/pci/pcxhr/pcxhr.c | 6 +- + sound/pci/pcxhr/pcxhr_core.c | 27 +- + sound/pci/pcxhr/pcxhr_hwdep.c | 15 +- + sound/pci/riptide/riptide.c | 31 +- + sound/pci/rme9652/hdsp.c | 25 +- + sound/pci/rme9652/hdspm.c | 52 +- + sound/pci/rme9652/rme9652.c | 23 +- + sound/pci/sonicvibes.c | 10 +- + sound/pci/trident/trident_main.c | 22 +- + sound/pci/trident/trident_memory.c | 37 +- + sound/pci/via82xx.c | 60 +- + sound/pci/via82xx_modem.c | 8 +- + sound/pci/vx222/vx222_ops.c | 12 +- + sound/pci/ymfpci/ymfpci_main.c | 21 +- + sound/pcmcia/vx/vxp_ops.c | 3 +- + sound/ppc/awacs.c | 73 +- + sound/ppc/beep.c | 6 +- + sound/ppc/tumbler.c | 17 +- + sound/sh/aica.c | 3 +- + sound/soc/at91/at91-ssc.c | 2 +- + sound/soc/at91/eti_b1_wm8731.c | 1 + + sound/soc/codecs/Kconfig | 43 + + sound/soc/codecs/Makefile | 10 + + sound/soc/codecs/ad1980.c | 309 +++ + sound/soc/codecs/ad1980.h | 23 + + sound/soc/codecs/ak4535.c | 116 +- + sound/soc/codecs/ak4535.h | 1 + + sound/soc/codecs/cs4270.c | 71 +- + sound/soc/codecs/tlv320aic26.c | 520 +++++ + sound/soc/codecs/tlv320aic26.h | 96 + + sound/soc/codecs/uda1380.c | 115 +- + sound/soc/codecs/uda1380.h | 1 + + sound/soc/codecs/wm8580.c | 1055 +++++++++ + sound/soc/codecs/wm8580.h | 42 + + sound/soc/codecs/wm8731.c | 177 +- + sound/soc/codecs/wm8731.h | 2 + + sound/soc/codecs/wm8750.c | 111 +- + sound/soc/codecs/wm8750.h | 1 + + sound/soc/codecs/wm8900.c | 1542 +++++++++++++ + sound/soc/codecs/wm8900.h | 64 + + sound/soc/codecs/wm8903.c | 1813 +++++++++++++++ + sound/soc/codecs/wm8903.h | 1463 ++++++++++++ + sound/soc/codecs/wm8990.c | 109 +- + sound/soc/codecs/wm8990.h | 1 + + sound/soc/davinci/davinci-i2s.c | 2 +- + sound/soc/fsl/Kconfig | 10 + + sound/soc/fsl/Makefile | 5 + + sound/soc/fsl/mpc5200_psc_i2s.c | 884 ++++++++ + sound/soc/fsl/mpc8610_hpcd.c | 26 +- + sound/soc/fsl/soc-of-simple.c | 171 ++ + sound/soc/pxa/corgi.c | 1 + + sound/soc/pxa/poodle.c | 1 + + sound/soc/pxa/pxa2xx-pcm.c | 4 +- + sound/soc/pxa/spitz.c | 1 + + sound/soc/soc-core.c | 132 +- + sound/soc/soc-dapm.c | 119 +- + sound/sound_core.c | 79 +- + sound/sparc/amd7930.c | 19 +- + sound/sparc/cs4231.c | 3 +- + sound/sparc/dbri.c | 17 +- + sound/synth/emux/emux.c | 8 +- + sound/synth/emux/emux_nrpn.c | 8 +- + sound/synth/emux/emux_oss.c | 42 +- + sound/synth/emux/emux_seq.c | 15 +- + sound/synth/emux/emux_synth.c | 47 +- + sound/synth/util_mem.c | 10 +- + sound/usb/Kconfig | 11 + + sound/usb/Makefile | 1 + + sound/usb/usbaudio.c | 19 +- + sound/usb/usbaudio.h | 4 +- + sound/usb/usbmidi.c | 39 + + sound/usb/usbmixer.c | 19 +- + sound/usb/usbquirks.h | 31 +- + sound/usb/usx2y/Makefile | 2 + + sound/usb/usx2y/us122l.c | 692 ++++++ + sound/usb/usx2y/us122l.h | 27 + + sound/usb/usx2y/usb_stream.c | 761 +++++++ + sound/usb/usx2y/usb_stream.h | 112 + + 289 files changed, 18980 insertions(+), 8108 deletions(-) + delete mode 100644 include/sound/cs4231.h + create mode 100644 include/sound/jack.h + create mode 100644 include/sound/soc-of-simple.h + create mode 100644 include/sound/wss.h + create mode 100644 sound/core/jack.c + delete mode 100644 sound/isa/cs423x/cs4231_lib.c + create mode 100644 sound/isa/wss/Makefile + create mode 100644 sound/isa/wss/wss_lib.c + delete mode 100644 sound/oss/hal2.c + delete mode 100644 sound/oss/hal2.h + create mode 100644 sound/pci/hda/hda_beep.c + create mode 100644 sound/pci/hda/hda_beep.h + create mode 100644 sound/soc/codecs/ad1980.c + create mode 100644 sound/soc/codecs/ad1980.h + create mode 100644 sound/soc/codecs/tlv320aic26.c + create mode 100644 sound/soc/codecs/tlv320aic26.h + create mode 100644 sound/soc/codecs/wm8580.c + create mode 100644 sound/soc/codecs/wm8580.h + create mode 100644 sound/soc/codecs/wm8900.c + create mode 100644 sound/soc/codecs/wm8900.h + create mode 100644 sound/soc/codecs/wm8903.c + create mode 100644 sound/soc/codecs/wm8903.h + create mode 100644 sound/soc/fsl/mpc5200_psc_i2s.c + create mode 100644 sound/soc/fsl/soc-of-simple.c + create mode 100644 sound/usb/usx2y/us122l.c + create mode 100644 sound/usb/usx2y/us122l.h + create mode 100644 sound/usb/usx2y/usb_stream.c + create mode 100644 sound/usb/usx2y/usb_stream.h +Merging cpufreq/next +$ git merge cpufreq/next +Auto-merged arch/x86/kernel/cpu/cpufreq/elanfreq.c +Auto-merged drivers/cpufreq/cpufreq_conservative.c +Auto-merged include/linux/tick.h +Auto-merged kernel/time/tick-sched.c +Merge made by recursive. + arch/x86/kernel/cpu/cpufreq/acpi-cpufreq.c | 13 ++- + arch/x86/kernel/cpu/cpufreq/elanfreq.c | 42 ++++---- + arch/x86/kernel/cpu/cpufreq/powernow-k6.c | 41 ++++---- + drivers/cpufreq/cpufreq.c | 30 ++++-- + drivers/cpufreq/cpufreq_conservative.c | 1 + + drivers/cpufreq/cpufreq_ondemand.c | 140 ++++++++++++++++++++-------- + include/linux/cpufreq.h | 7 +- + include/linux/tick.h | 2 +- + kernel/time/tick-sched.c | 11 ++- + 9 files changed, 186 insertions(+), 101 deletions(-) +Merging v9fs/for-next +$ git merge v9fs/for-next +Merge made by recursive. + include/net/9p/9p.h | 1 + + include/net/9p/transport.h | 9 +- + net/9p/client.c | 10 +- + net/9p/mod.c | 92 +++++++++---- + net/9p/trans_fd.c | 340 +++++++++++++++----------------------------- + net/9p/trans_virtio.c | 2 + + 6 files changed, 198 insertions(+), 256 deletions(-) +Merging quilt/rr +$ git merge quilt/rr +Auto-merged drivers/md/md.c +Auto-merged drivers/media/video/cpia.c +Auto-merged drivers/media/video/usbvision/usbvision-core.c +Auto-merged drivers/media/video/usbvision/usbvision-video.c +Auto-merged drivers/media/video/v4l2-common.c +Auto-merged drivers/media/video/vino.c +Auto-merged drivers/mtd/mtdpart.c +Auto-merged drivers/net/ppp_generic.c +Auto-merged drivers/video/fbmem.c +Auto-merged fs/char_dev.c +Auto-merged init/Kconfig +Auto-merged net/ipv4/devinet.c +Auto-merged net/ipv4/inet_diag.c +Auto-merged net/sched/cls_api.c +Auto-merged net/sched/sch_api.c +Merge made by recursive. + drivers/md/md.c | 7 ------- + drivers/media/video/cpia.c | 4 ---- + drivers/media/video/usbvision/usbvision-core.c | 4 ---- + drivers/media/video/usbvision/usbvision-video.c | 4 ---- + drivers/media/video/v4l1-compat.c | 4 ---- + drivers/media/video/v4l2-common.c | 4 ---- + drivers/media/video/vino.c | 5 +---- + drivers/media/video/w9968cf.c | 4 ++-- + drivers/mtd/mtdpart.c | 2 -- + drivers/net/irda/sir_dongle.c | 2 -- + drivers/net/ppp_generic.c | 10 +++------- + drivers/net/pppox.c | 9 ++------- + drivers/video/fbmem.c | 17 ++--------------- + fs/char_dev.c | 3 --- + fs/exec.c | 9 +++------ + fs/nls/nls_base.c | 21 +-------------------- + include/linux/netdevice.h | 5 ++++- + init/Kconfig | 6 ------ + kernel/kmod.c | 2 +- + net/bluetooth/af_bluetooth.c | 8 +------- + net/bridge/netfilter/ebtables.c | 15 +++------------ + net/can/af_can.c | 4 ++-- + net/core/dev.c | 2 -- + net/core/rtnetlink.c | 4 ++-- + net/dccp/ccid.c | 2 +- + net/decnet/dn_dev.c | 2 -- + net/ipv4/devinet.c | 2 -- + net/ipv4/inet_diag.c | 2 -- + net/ipv4/tcp_cong.c | 4 ++-- + net/netfilter/nfnetlink.c | 2 +- + net/netlink/af_netlink.c | 2 +- + net/sched/act_api.c | 2 +- + net/sched/cls_api.c | 2 +- + net/sched/ematch.c | 2 +- + net/sched/sch_api.c | 2 +- + net/socket.c | 2 +- + net/sunrpc/auth.c | 2 -- + 37 files changed, 37 insertions(+), 146 deletions(-) +Merging cifs/master +$ git merge cifs/master +Already up-to-date. +Merging mmc/next +$ git merge mmc/next +Auto-merged drivers/mmc/host/sdhci-pci.c +Merge made by recursive. + drivers/mmc/card/block.c | 46 +------- + drivers/mmc/card/queue.c | 23 +++- + drivers/mmc/core/sdio_io.c | 249 +++++++++++++++++++++++++++++++++++++++++ + drivers/mmc/core/sdio_irq.c | 16 ++- + drivers/mmc/core/sdio_ops.c | 10 ++- + drivers/mmc/host/sdhci-pci.c | 3 +- + drivers/mmc/host/sdhci.c | 44 ++++++-- + drivers/mmc/host/sdhci.h | 2 + + include/linux/mmc/sdio_func.h | 41 +++++++- + 9 files changed, 371 insertions(+), 63 deletions(-) +Merging gfs2/master +$ git merge gfs2/master +Auto-merged fs/gfs2/ops_inode.c +Merge made by recursive. + fs/gfs2/glock.c | 13 +- + fs/gfs2/incore.h | 7 +- + fs/gfs2/inode.c | 48 ----- + fs/gfs2/inode.h | 1 - + fs/gfs2/mount.c | 7 + + fs/gfs2/ops_fstype.c | 566 ++++++++++++++++++++++++++++++++++---------------- + fs/gfs2/ops_inode.c | 127 +++++++++--- + fs/gfs2/ops_super.c | 57 +++++- + fs/gfs2/super.c | 340 ------------------------------ + fs/gfs2/super.h | 6 - + 10 files changed, 554 insertions(+), 618 deletions(-) +Merging input/next +$ git merge input/next +Auto-merged drivers/input/keyboard/bf54x-keys.c +Auto-merged drivers/input/keyboard/gpio_keys.c +Auto-merged drivers/input/tablet/aiptek.c +Auto-merged include/linux/mod_devicetable.h +Merge made by recursive. + drivers/input/gameport/gameport.c | 88 +++- + drivers/input/joystick/a3d.c | 3 +- + drivers/input/joystick/adi.c | 3 +- + drivers/input/joystick/analog.c | 4 +- + drivers/input/joystick/cobra.c | 3 +- + drivers/input/joystick/gf2k.c | 3 +- + drivers/input/joystick/grip.c | 3 +- + drivers/input/joystick/grip_mp.c | 3 +- + drivers/input/joystick/guillemot.c | 3 +- + drivers/input/joystick/interact.c | 3 +- + drivers/input/joystick/joydump.c | 3 +- + drivers/input/joystick/sidewinder.c | 3 +- + drivers/input/joystick/tmdc.c | 3 +- + drivers/input/keyboard/atkbd.c | 30 +- + drivers/input/keyboard/bf54x-keys.c | 13 +- + drivers/input/keyboard/gpio_keys.c | 42 +- + drivers/input/misc/Kconfig | 13 + + drivers/input/misc/Makefile | 1 + + drivers/input/misc/ati_remote2.c | 263 ++++++++-- + drivers/input/misc/cm109.c | 884 ++++++++++++++++++++++++++++++ + drivers/input/misc/wistron_btns.c | 19 + + drivers/input/mouse/appletouch.c | 299 ++++++++--- + drivers/input/mouse/logips2pp.c | 4 +- + drivers/input/mouse/psmouse-base.c | 12 +- + drivers/input/mouse/trackpoint.c | 8 +- + drivers/input/tablet/aiptek.c | 53 ++- + drivers/input/touchscreen/ads7846.c | 6 +- + drivers/input/touchscreen/atmel_tsadcc.c | 37 +- + include/linux/gameport.h | 7 +- + include/linux/input.h | 15 +- + include/linux/mod_devicetable.h | 2 +- + 31 files changed, 1575 insertions(+), 258 deletions(-) + create mode 100644 drivers/input/misc/cm109.c +$ git am -3 ../patches/0001-rr-build-fix-for-remove-CONFIG_KMOD-from-net.patch +Applying rr: build fix for remove CONFIG_KMOD from net +Merging semaphore/semaphore +$ git merge semaphore/semaphore +Already up-to-date. +Merging semaphore-removal/semaphore-removal +$ git merge semaphore-removal/semaphore-removal +Auto-merged arch/arm/mach-lh7a40x/clocks.c +Auto-merged drivers/net/bonding/bond_main.c +Auto-merged drivers/net/bonding/bond_sysfs.c +Auto-merged drivers/net/ps3_gelic_wireless.c +Auto-merged drivers/scsi/qla2xxx/qla_def.h +Auto-merged net/9p/trans_virtio.c +Auto-merged sound/soc/s3c24xx/s3c2443-ac97.c +Merge made by recursive. + arch/arm/mach-lh7a40x/clocks.c | 15 ++++++++------- + drivers/net/bonding/bond_main.c | 21 +++++++++++---------- + drivers/net/bonding/bond_sysfs.c | 15 ++++++++------- + drivers/net/ppp_async.c | 8 ++++---- + drivers/net/ps3_gelic_net.c | 1 + + drivers/net/ps3_gelic_wireless.c | 1 + + drivers/pci/hotplug/ibmphp_hpc.c | 30 ++++++++++++++---------------- + include/net/bluetooth/hci_core.h | 7 ++++--- + net/9p/trans_virtio.c | 21 +++++++++++---------- + net/bluetooth/hci_core.c | 2 +- + sound/soc/s3c24xx/s3c2443-ac97.c | 11 ++++++----- + 11 files changed, 69 insertions(+), 63 deletions(-) +Merging bkl-removal/bkl-removal +$ git merge bkl-removal/bkl-removal +Auto-merged drivers/uio/uio.c +Merge made by recursive. + drivers/uio/uio.c | 14 ++++++++------ + 1 files changed, 8 insertions(+), 6 deletions(-) +Merging trivial/next +$ git merge trivial/next +Auto-merged Documentation/edac.txt +CONFLICT (content): Merge conflict in Documentation/edac.txt +Auto-merged arch/mips/kernel/vpe.c +Auto-merged drivers/base/sys.c +Auto-merged drivers/media/dvb/ttpci/av7110.c +Auto-merged drivers/net/spider_net.c +Auto-merged drivers/serial/mpc52xx_uart.c +Auto-merged drivers/usb/serial/ftdi_sio.c +Auto-merged fs/jffs2/fs.c +Auto-merged fs/ntfs/aops.c +Auto-merged fs/proc/nommu.c +Auto-merged include/linux/securebits.h +CONFLICT (content): Merge conflict in include/linux/securebits.h +Auto-merged mm/migrate.c +Auto-merged mm/slub.c +Auto-merged net/wireless/wext.c +Resolved 'Documentation/edac.txt' using previous resolution. +Resolved 'include/linux/securebits.h' using previous resolution. +Automatic merge failed; fix conflicts and then commit the result. +$ git commit -v -a +Created commit d8a131b: Merge commit 'trivial/next' +$ git diff -M --stat --summary HEAD^.. + Documentation/filesystems/hfs.txt | 2 +- + Documentation/ja_JP/SubmittingPatches | 4 ++-- + Documentation/zh_CN/SubmittingPatches | 4 ++-- + arch/mips/kernel/vpe.c | 2 +- + arch/sh/lib64/c-checksum.c | 4 ++-- + drivers/base/sys.c | 2 +- + drivers/char/serial167.c | 2 +- + drivers/media/dvb/ttpci/av7110.c | 2 +- + drivers/message/i2o/i2o_block.c | 2 +- + drivers/misc/ibmasm/event.c | 2 +- + drivers/net/spider_net.c | 2 +- + drivers/serial/mpc52xx_uart.c | 4 ++-- + drivers/usb/serial/ftdi_sio.c | 2 +- + fs/jffs2/fs.c | 2 +- + fs/ntfs/aops.c | 2 +- + fs/proc/nommu.c | 2 +- + mm/migrate.c | 2 +- + mm/slub.c | 4 ++-- + net/wireless/wext.c | 2 +- + 19 files changed, 24 insertions(+), 24 deletions(-) +Merging ubifs/linux-next +$ git merge ubifs/linux-next +Merge made by recursive. + fs/ubifs/budget.c | 113 +++++++++++++++++++++++++++++++++++++++------------ + fs/ubifs/dir.c | 1 - + fs/ubifs/file.c | 20 +++++++-- + fs/ubifs/find.c | 18 ++++----- + fs/ubifs/gc.c | 6 +++ + fs/ubifs/misc.h | 49 ++++++++--------------- + fs/ubifs/super.c | 22 ++++++---- + fs/ubifs/tnc.c | 116 ++++++++++++++++++++++++++++------------------------- + fs/ubifs/ubifs.h | 14 +++++- + 9 files changed, 219 insertions(+), 140 deletions(-) +Merging lsm/for-next +$ git merge lsm/for-next +Already up-to-date. +Merging block/for-next +$ git merge block/for-next +Auto-merged Documentation/DocBook/kernel-api.tmpl +Auto-merged block/blk-core.c +Auto-merged block/blk-integrity.c +Auto-merged block/blk-map.c +Auto-merged block/blk-settings.c +Auto-merged block/bsg.c +Auto-merged block/genhd.c +Auto-merged drivers/base/core.c +Auto-merged drivers/block/pktcdvd.c +Auto-merged drivers/ide/ide-cd.c +Auto-merged drivers/ide/ide-disk.c +CONFLICT (content): Merge conflict in drivers/ide/ide-disk.c +Auto-merged drivers/ide/ide-probe.c +Auto-merged drivers/md/dm-mpath.c +CONFLICT (content): Merge conflict in drivers/md/dm-mpath.c +Auto-merged drivers/md/md.c +Auto-merged drivers/mmc/card/block.c +Auto-merged drivers/s390/block/dcssblk.c +Auto-merged drivers/scsi/ide-scsi.c +Auto-merged drivers/scsi/ipr.c +Auto-merged drivers/scsi/scsi_error.c +Auto-merged drivers/scsi/scsi_tgt_lib.c +Auto-merged drivers/scsi/sg.c +Auto-merged fs/block_dev.c +Auto-merged include/linux/device.h +Auto-merged include/linux/fs.h +Auto-merged lib/Kconfig.debug +CONFLICT (content): Merge conflict in lib/Kconfig.debug +Resolved 'drivers/ide/ide-disk.c' using previous resolution. +Resolved 'drivers/md/dm-mpath.c' using previous resolution. +Resolved 'lib/Kconfig.debug' using previous resolution. +Automatic merge failed; fix conflicts and then commit the result. +$ git commit -v -a +Created commit a11a9d5: Merge commit 'block/for-next' +$ git diff -M --stat --summary HEAD^.. + Documentation/block/deadline-iosched.txt | 14 +- + block/Makefile | 4 +- + block/as-iosched.c | 6 +- + block/blk-barrier.c | 71 +++- + block/blk-core.c | 306 ++++------ + block/blk-integrity.c | 5 +- + block/blk-map.c | 52 +- + block/blk-merge.c | 129 +---- + block/blk-settings.c | 29 + + block/blk-softirq.c | 167 ++++++ + block/blk-sysfs.c | 35 +- + block/blk-timeout.c | 182 ++++++ + block/blk.h | 13 + + block/blktrace.c | 29 +- + block/bsg.c | 6 +- + block/cfq-iosched.c | 49 ++- + block/cmd-filter.c | 9 +- + block/compat_ioctl.c | 1 + + block/deadline-iosched.c | 40 +- + block/elevator.c | 30 +- + block/genhd.c | 952 +++++++++++++++++++----------- + block/ioctl.c | 124 ++++- + block/scsi_ioctl.c | 8 +- + drivers/ata/libata-eh.c | 13 +- + drivers/ata/libata.h | 2 +- + drivers/block/aoe/aoeblk.c | 6 +- + drivers/block/aoe/aoecmd.c | 19 +- + drivers/block/aoe/aoedev.c | 2 +- + drivers/block/nbd.c | 4 +- + drivers/block/pktcdvd.c | 2 +- + drivers/block/ps3disk.c | 11 +- + drivers/block/virtio_blk.c | 4 +- + drivers/cdrom/cdrom.c | 2 +- + drivers/char/random.c | 6 +- + drivers/ide/ide-cd.c | 2 +- + drivers/ide/ide-disk.c | 14 +- + drivers/ide/ide-probe.c | 2 +- + drivers/md/dm-ioctl.c | 6 +- + drivers/md/dm-mpath.c | 15 +- + drivers/md/dm-stripe.c | 4 +- + drivers/md/dm.c | 40 +- + drivers/md/linear.c | 8 +- + drivers/md/md.c | 15 +- + drivers/md/multipath.c | 8 +- + drivers/md/raid0.c | 8 +- + drivers/md/raid1.c | 13 +- + drivers/md/raid10.c | 12 +- + drivers/md/raid5.c | 75 ++- + drivers/memstick/core/mspro_block.c | 2 +- + drivers/mmc/card/block.c | 2 +- + drivers/mtd/ftl.c | 24 + + drivers/mtd/mtd_blkdevs.c | 16 + + drivers/s390/block/dasd_proc.c | 3 +- + drivers/s390/block/dcssblk.c | 4 +- + drivers/scsi/aacraid/aachba.c | 2 +- + drivers/scsi/gdth.c | 60 ++- + drivers/scsi/gdth.h | 2 +- + drivers/scsi/gdth_proc.c | 66 -- + drivers/scsi/gdth_proc.h | 3 - + drivers/scsi/ibmvscsi/ibmvscsi.c | 2 +- + drivers/scsi/ide-scsi.c | 2 +- + drivers/scsi/ipr.c | 3 +- + drivers/scsi/ips.c | 2 +- + drivers/scsi/libiscsi.c | 17 +- + drivers/scsi/libsas/sas_ata.c | 2 +- + drivers/scsi/libsas/sas_internal.h | 2 +- + drivers/scsi/libsas/sas_scsi_host.c | 30 +- + drivers/scsi/megaraid/megaraid_sas.c | 6 +- + drivers/scsi/ncr53c8xx.c | 4 +- + drivers/scsi/qla1280.c | 4 +- + drivers/scsi/qla4xxx/ql4_os.c | 4 +- + drivers/scsi/scsi.c | 94 +--- + drivers/scsi/scsi_error.c | 90 +--- + drivers/scsi/scsi_lib.c | 40 ++- + drivers/scsi/scsi_priv.h | 8 +- + drivers/scsi/scsi_sysfs.c | 7 +- + drivers/scsi/scsi_tgt_lib.c | 2 +- + drivers/scsi/scsi_transport_fc.c | 6 +- + drivers/scsi/sd.c | 91 ++- + drivers/scsi/sg.c | 594 ++++++-------------- + drivers/scsi/sr.c | 7 +- + drivers/scsi/sym53c8xx_2/sym_glue.c | 4 +- + fs/bio.c | 156 ++--- + fs/block_dev.c | 92 ++-- + fs/fat/fatent.c | 14 + + fs/partitions/check.c | 265 +++++---- + fs/partitions/check.h | 4 +- + include/linux/bio.h | 80 ++-- + include/linux/blkdev.h | 93 +++- + include/linux/blktrace_api.h | 6 + + include/linux/elevator.h | 9 +- + include/linux/fs.h | 6 +- + include/linux/genhd.h | 363 ++++++------ + include/linux/major.h | 2 + + include/linux/mtd/blktrans.h | 2 + + include/scsi/scsi_cmnd.h | 3 - + include/scsi/scsi_host.h | 9 +- + include/scsi/scsi_transport.h | 3 +- + init/do_mounts.c | 4 + + lib/Kconfig.debug | 22 + + mm/bounce.c | 2 +- + 101 files changed, 2756 insertions(+), 2138 deletions(-) + create mode 100644 block/blk-softirq.c + create mode 100644 block/blk-timeout.c +Merging embedded/master +$ git merge embedded/master +Already up-to-date. +Merging firmware/master +$ git merge firmware/master +Auto-merged drivers/media/dvb/ttpci/av7110.c +Removed drivers/media/dvb/ttpci/fdump.c +Removed drivers/net/acenic_firmware.h +Auto-merged drivers/net/e100.c +Removed drivers/net/starfire_firmware.h +Removed drivers/net/starfire_firmware.pl +Removed drivers/scsi/ql1040_fw.h +Removed drivers/scsi/ql12160_fw.h +Removed drivers/scsi/ql1280_fw.h +Auto-merged drivers/scsi/qla1280.c +Auto-merged drivers/scsi/qlogicpti.c +CONFLICT (content): Merge conflict in drivers/scsi/qlogicpti.c +Removed drivers/scsi/qlogicpti_asm.c +Auto-merged firmware/Makefile +Auto-merged sound/isa/Kconfig +Auto-merged sound/isa/wavefront/wavefront_fx.c +Removed sound/isa/wavefront/yss225.c +Resolved 'drivers/scsi/qlogicpti.c' using previous resolution. +Automatic merge failed; fix conflicts and then commit the result. +$ git commit -v -a +Created commit 5917925: Merge commit 'firmware/master' +$ git diff -M --stat --summary HEAD^.. + drivers/media/dvb/ttpci/Kconfig | 23 +- + drivers/media/dvb/ttpci/Makefile | 9 - + drivers/media/dvb/ttpci/av7110.c | 16 - + drivers/media/dvb/ttpci/av7110_hw.c | 35 +- + drivers/media/dvb/ttpci/av7110_hw.h | 3 +- + drivers/media/dvb/ttpci/fdump.c | 44 - + drivers/net/acenic.c | 117 +- + drivers/net/acenic.h | 4 + + drivers/net/acenic_firmware.h | 9456 ----------------------------- + drivers/net/e100.c | 283 +- + drivers/net/starfire.c | 51 +- + drivers/net/starfire_firmware.h | 346 -- + drivers/net/starfire_firmware.pl | 31 - + drivers/net/tg3.c | 789 +--- + drivers/net/tg3.h | 4 + + drivers/scsi/advansys.c | 1731 +----- + drivers/scsi/ql1040_fw.h | 2130 ------- + drivers/scsi/ql12160_fw.h | 1811 ------ + drivers/scsi/ql1280_fw.h | 2048 ------- + drivers/scsi/qla1280.c | 114 +- + drivers/scsi/qla1280.h | 6 + + drivers/scsi/qlogicpti.c | 63 +- + drivers/scsi/qlogicpti_asm.c | 1160 ---- + firmware/Makefile | 20 + + firmware/WHENCE | 121 + + firmware/acenic/tg1.bin.ihex | 4573 ++++++++++++++ + firmware/acenic/tg2.bin.ihex | 4844 +++++++++++++++ + firmware/adaptec/starfire_rx.bin.ihex | 53 + + firmware/adaptec/starfire_tx.bin.ihex | 53 + + firmware/advansys/3550.bin.ihex | 317 + + firmware/advansys/38C0800.bin.ihex | 336 + + firmware/advansys/38C1600.bin.ihex | 398 ++ + firmware/advansys/mcode.bin.ihex | 147 + + firmware/av7110/Boot.S | 109 + + firmware/av7110/bootcode.bin.ihex | 15 + + firmware/e100/d101m_ucode.bin.ihex | 38 + + firmware/e100/d101s_ucode.bin.ihex | 38 + + firmware/e100/d102e_ucode.bin.ihex | 38 + + firmware/qlogic/1040.bin.ihex | 2111 +++++++ + firmware/qlogic/12160.bin.ihex | 1771 ++++++ + firmware/qlogic/1280.bin.ihex | 2008 ++++++ + firmware/qlogic/isp1000.bin.ihex | 1158 ++++ + firmware/tigon/tg3.bin.ihex | 175 + + firmware/tigon/tg3_tso.bin.ihex | 446 ++ + firmware/tigon/tg3_tso5.bin.ihex | 252 + + firmware/yamaha/yss225_registers.bin.ihex | 998 +++ + sound/isa/Kconfig | 10 - + sound/isa/wavefront/wavefront_fx.c | 16 - + sound/isa/wavefront/yss225.c | 2739 --------- + 49 files changed, 20560 insertions(+), 22498 deletions(-) + delete mode 100644 drivers/media/dvb/ttpci/fdump.c + delete mode 100644 drivers/net/acenic_firmware.h + delete mode 100644 drivers/net/starfire_firmware.h + delete mode 100644 drivers/net/starfire_firmware.pl + delete mode 100644 drivers/scsi/ql1040_fw.h + delete mode 100644 drivers/scsi/ql12160_fw.h + delete mode 100644 drivers/scsi/ql1280_fw.h + delete mode 100644 drivers/scsi/qlogicpti_asm.c + create mode 100644 firmware/acenic/tg1.bin.ihex + create mode 100644 firmware/acenic/tg2.bin.ihex + create mode 100644 firmware/adaptec/starfire_rx.bin.ihex + create mode 100644 firmware/adaptec/starfire_tx.bin.ihex + create mode 100644 firmware/advansys/3550.bin.ihex + create mode 100644 firmware/advansys/38C0800.bin.ihex + create mode 100644 firmware/advansys/38C1600.bin.ihex + create mode 100644 firmware/advansys/mcode.bin.ihex + create mode 100644 firmware/av7110/Boot.S + create mode 100644 firmware/av7110/bootcode.bin.ihex + create mode 100644 firmware/e100/d101m_ucode.bin.ihex + create mode 100644 firmware/e100/d101s_ucode.bin.ihex + create mode 100644 firmware/e100/d102e_ucode.bin.ihex + create mode 100644 firmware/qlogic/1040.bin.ihex + create mode 100644 firmware/qlogic/12160.bin.ihex + create mode 100644 firmware/qlogic/1280.bin.ihex + create mode 100644 firmware/qlogic/isp1000.bin.ihex + create mode 100644 firmware/tigon/tg3.bin.ihex + create mode 100644 firmware/tigon/tg3_tso.bin.ihex + create mode 100644 firmware/tigon/tg3_tso5.bin.ihex + create mode 100644 firmware/yamaha/yss225_registers.bin.ihex + delete mode 100644 sound/isa/wavefront/yss225.c +Merging pcmcia/master +$ git merge pcmcia/master +Auto-merged drivers/bluetooth/bt3c_cs.c +Auto-merged drivers/char/pcmcia/cm4000_cs.c +Auto-merged drivers/char/pcmcia/cm4040_cs.c +Auto-merged drivers/ide/legacy/ide-cs.c +Auto-merged drivers/net/pcmcia/axnet_cs.c +Auto-merged drivers/net/pcmcia/pcnet_cs.c +Auto-merged drivers/net/wireless/orinoco_cs.c +Auto-merged drivers/net/wireless/spectrum_cs.c +Auto-merged drivers/net/wireless/wavelan_cs.c +Auto-merged drivers/net/wireless/wl3501_cs.c +Auto-merged drivers/pcmcia/Makefile +Removed drivers/pcmcia/ds_internal.h +Auto-merged drivers/pcmcia/pxa2xx_base.c +Auto-merged drivers/pcmcia/rsrc_nonstatic.c +Auto-merged drivers/pcmcia/soc_common.c +Auto-merged drivers/scsi/pcmcia/nsp_cs.c +Merge made by recursive. + Documentation/pcmcia/driver-changes.txt | 6 + + drivers/ata/pata_pcmcia.c | 168 ++++++-------- + drivers/bluetooth/bluecard_cs.c | 8 +- + drivers/bluetooth/bt3c_cs.c | 125 ++++------ + drivers/bluetooth/btuart_cs.c | 126 ++++------ + drivers/bluetooth/dtl1_cs.c | 67 ++---- + drivers/char/pcmcia/cm4000_cs.c | 73 ++---- + drivers/char/pcmcia/cm4040_cs.c | 80 +++---- + drivers/char/pcmcia/ipwireless/main.c | 46 ++--- + drivers/ide/legacy/ide-cs.c | 158 ++++++------- + drivers/isdn/hardware/avm/avm_cs.c | 85 ++----- + drivers/isdn/hisax/avma1_cs.c | 81 ++----- + drivers/isdn/hisax/elsa_cs.c | 79 ++----- + drivers/isdn/hisax/sedlbauer_cs.c | 197 ++++++++--------- + drivers/isdn/hisax/teles_cs.c | 79 ++----- + drivers/mtd/maps/pcmciamtd.c | 29 +-- + drivers/net/pcmcia/3c574_cs.c | 7 +- + drivers/net/pcmcia/3c589_cs.c | 7 +- + drivers/net/pcmcia/axnet_cs.c | 80 +++---- + drivers/net/pcmcia/com20020_cs.c | 8 +- + drivers/net/pcmcia/fmvj18x_cs.c | 19 +- + drivers/net/pcmcia/ibmtr_cs.c | 2 +- + drivers/net/pcmcia/pcnet_cs.c | 86 ++++---- + drivers/net/pcmcia/smc91c92_cs.c | 147 +++++------- + drivers/net/pcmcia/xirc2ps_cs.c | 75 ++++--- + drivers/net/wireless/airo_cs.c | 222 +++++++++--------- + drivers/net/wireless/atmel_cs.c | 119 ++++------ + drivers/net/wireless/b43/pcmcia.c | 14 +- + drivers/net/wireless/hostap/hostap_cs.c | 235 +++++++++----------- + drivers/net/wireless/netwave_cs.c | 5 +- + drivers/net/wireless/orinoco_cs.c | 163 ++++++-------- + drivers/net/wireless/ray_cs.c | 4 +- + drivers/net/wireless/spectrum_cs.c | 162 ++++++-------- + drivers/net/wireless/wavelan_cs.c | 16 +- + drivers/net/wireless/wl3501_cs.c | 4 +- + drivers/parport/parport_cs.c | 70 +++---- + drivers/pcmcia/Makefile | 4 - + drivers/pcmcia/au1000_generic.c | 2 +- + drivers/pcmcia/au1000_generic.h | 2 +- + drivers/pcmcia/au1000_pb1x00.c | 1 - + drivers/pcmcia/au1000_xxs1500.c | 1 - + drivers/pcmcia/cardbus.c | 2 +- + drivers/pcmcia/cistpl.c | 291 ++++++++++++++---------- + drivers/pcmcia/cs.c | 74 ++++--- + drivers/pcmcia/cs_internal.h | 214 +++++++++++++----- + drivers/pcmcia/ds.c | 239 ++++++++----------- + drivers/pcmcia/ds_internal.h | 23 -- + drivers/pcmcia/hd64465_ss.c | 1 - + drivers/pcmcia/i82365.c | 2 +- + drivers/pcmcia/m32r_cfc.c | 4 +- + drivers/pcmcia/m32r_pcc.c | 4 +- + drivers/pcmcia/m8xx_pcmcia.c | 4 +- + drivers/pcmcia/o2micro.h | 10 +- + drivers/pcmcia/pcmcia_ioctl.c | 116 ++++++++-- + drivers/pcmcia/pcmcia_resource.c | 381 +++++++++++++++++-------------- + drivers/pcmcia/pxa2xx_base.c | 1 - + drivers/pcmcia/rsrc_nonstatic.c | 67 +++--- + drivers/pcmcia/soc_common.c | 2 +- + drivers/pcmcia/soc_common.h | 3 +- + drivers/pcmcia/socket_sysfs.c | 13 +- + drivers/pcmcia/tcic.c | 2 +- + drivers/pcmcia/ti113x.h | 78 ++++--- + drivers/pcmcia/yenta_socket.c | 86 ++++---- + drivers/scsi/pcmcia/aha152x_stub.c | 58 +++--- + drivers/scsi/pcmcia/fdomain_stub.c | 37 ++-- + drivers/scsi/pcmcia/nsp_cs.c | 194 ++++++++-------- + drivers/scsi/pcmcia/qlogic_stub.c | 47 ++-- + drivers/scsi/pcmcia/sym53c500_cs.c | 46 ++-- + drivers/serial/serial_cs.c | 300 +++++++++++-------------- + drivers/ssb/pcmcia.c | 22 +- + drivers/telephony/ixj_pcmcia.c | 72 +++---- + drivers/usb/host/sl811_cs.c | 133 +++++------- + include/pcmcia/ciscode.h | 2 +- + include/pcmcia/cistpl.h | 18 +- + include/pcmcia/cs.h | 92 +-------- + include/pcmcia/cs_types.h | 8 - + include/pcmcia/device_id.h | 18 ++- + include/pcmcia/ds.h | 318 ++++++++++++++++++-------- + include/pcmcia/ss.h | 202 ++++++++--------- + 79 files changed, 2887 insertions(+), 3159 deletions(-) + delete mode 100644 drivers/pcmcia/ds_internal.h +Merging battery/master +$ git merge battery/master +Auto-merged drivers/power/power_supply_core.c +Merge made by recursive. + drivers/power/Kconfig | 6 + + drivers/power/Makefile | 1 + + drivers/power/bq27x00_battery.c | 382 +++++++++++++++++++++++++++++++++++++ + drivers/power/pda_power.c | 11 +- + drivers/power/power_supply_core.c | 25 +++ + include/linux/power_supply.h | 6 + + 6 files changed, 427 insertions(+), 4 deletions(-) + create mode 100644 drivers/power/bq27x00_battery.c +Merging leds/for-mm +$ git merge leds/for-mm +Already up-to-date. +Merging backlight/for-mm +$ git merge backlight/for-mm +Already up-to-date. +Merging kgdb/kgdb-next +$ git merge kgdb/kgdb-next +Auto-merged drivers/char/tty_io.c +Merge made by recursive. + drivers/char/tty_io.c | 17 +++++- + drivers/serial/serial_txx9.c | 113 ++++++++++++++++++++++++++++++++++-------- + 2 files changed, 106 insertions(+), 24 deletions(-) +Merging slab/for-next +$ git merge slab/for-next +Auto-merged Documentation/kernel-parameters.txt +Auto-merged MAINTAINERS +Auto-merged fs/buffer.c +Auto-merged fs/dcache.c +Auto-merged fs/ext3/super.c +Auto-merged fs/ext4/super.c +Auto-merged fs/inode.c +Auto-merged fs/reiserfs/super.c +Auto-merged fs/xfs/linux-2.6/xfs_super.c +Auto-merged include/linux/fs.h +Auto-merged include/linux/mm.h +Auto-merged init/main.c +Auto-merged kernel/sysctl.c +Auto-merged lib/Kconfig.debug +Auto-merged mm/slub.c +Auto-merged mm/vmstat.c +Merge made by recursive. + Documentation/ABI/testing/debugfs-kmemtrace | 71 ++++ + Documentation/kernel-parameters.txt | 10 + + Documentation/sysctl/vm.txt | 12 + + Documentation/vm/kmemtrace.txt | 126 +++++++ + Documentation/vm/slabinfo.c | 91 ++++- + MAINTAINERS | 6 + + fs/buffer.c | 99 +++++ + fs/dcache.c | 148 +++++++-- + fs/drop_caches.c | 2 +- + fs/ext2/super.c | 9 + + fs/ext3/super.c | 8 + + fs/ext4/super.c | 8 + + fs/inode.c | 123 +++++++ + fs/proc/inode.c | 8 + + fs/reiserfs/super.c | 8 + + fs/xfs/linux-2.6/xfs_super.c | 2 + + include/linux/fs.h | 6 + + include/linux/kmemtrace.h | 86 +++++ + include/linux/mm.h | 3 +- + include/linux/mmzone.h | 1 + + include/linux/page-flags.h | 2 + + include/linux/slab.h | 61 +++- + include/linux/slab_def.h | 68 +++- + include/linux/slob_def.h | 9 +- + include/linux/slub_def.h | 69 ++++- + include/linux/swap.h | 3 + + init/main.c | 2 + + kernel/sysctl.c | 20 + + lib/Kconfig.debug | 28 ++ + mm/Makefile | 2 +- + mm/kmemtrace.c | 335 +++++++++++++++++ + mm/slab.c | 79 ++++- + mm/slob.c | 37 ++- + mm/slub.c | 513 ++++++++++++++++++++++----- + mm/vmscan.c | 64 +++- + mm/vmstat.c | 4 +- + 36 files changed, 1945 insertions(+), 178 deletions(-) + create mode 100644 Documentation/ABI/testing/debugfs-kmemtrace + create mode 100644 Documentation/vm/kmemtrace.txt + create mode 100644 include/linux/kmemtrace.h + create mode 100644 mm/kmemtrace.c +Merging uclinux/for-next +$ git merge uclinux/for-next +Already up-to-date. +Merging md/for-next +$ git merge md/for-next +Already up-to-date. +Merging kmemcheck/auto-kmemcheck-next +$ git merge kmemcheck/auto-kmemcheck-next +Auto-merged MAINTAINERS +CONFLICT (content): Merge conflict in MAINTAINERS +Auto-merged arch/x86/Kconfig.debug +Auto-merged arch/x86/kernel/process_32.c +Auto-merged arch/x86/kernel/process_64.c +CONFLICT (content): Merge conflict in arch/x86/kernel/process_64.c +Auto-merged arch/x86/kernel/traps_32.c +Auto-merged arch/x86/kernel/traps_64.c +CONFLICT (content): Merge conflict in arch/x86/kernel/traps_64.c +Auto-merged arch/x86/mm/fault.c +Auto-merged include/asm-x86/kdebug.h +Auto-merged include/asm-x86/pgtable.h +Auto-merged include/asm-x86/pgtable_32.h +Auto-merged include/asm-x86/pgtable_64.h +Auto-merged include/asm-x86/string_32.h +Auto-merged include/asm-x86/string_64.h +Auto-merged include/linux/slab.h +Auto-merged include/linux/slab_def.h +Auto-merged init/main.c +CONFLICT (content): Merge conflict in init/main.c +Auto-merged kernel/fork.c +Auto-merged kernel/sysctl.c +Auto-merged mm/Makefile +CONFLICT (content): Merge conflict in mm/Makefile +Auto-merged mm/slab.c +CONFLICT (content): Merge conflict in mm/slab.c +Auto-merged mm/slub.c +CONFLICT (content): Merge conflict in mm/slub.c +Resolved 'MAINTAINERS' using previous resolution. +Resolved 'arch/x86/kernel/process_64.c' using previous resolution. +Resolved 'arch/x86/kernel/traps_64.c' using previous resolution. +Resolved 'init/main.c' using previous resolution. +Resolved 'mm/Makefile' using previous resolution. +Resolved 'mm/slab.c' using previous resolution. +Resolved 'mm/slub.c' using previous resolution. +Automatic merge failed; fix conflicts and then commit the result. +$ git commit -v -a +Created commit 67f4c86: Merge commit 'kmemcheck/auto-kmemcheck-next' +$ git diff -M --stat --summary HEAD^.. + Documentation/kmemcheck.txt | 135 ++++++++++ + MAINTAINERS | 8 + + arch/x86/Kconfig.debug | 109 +++++++++ + arch/x86/kernel/process.c | 2 +- + arch/x86/kernel/process_32.c | 4 +- + arch/x86/kernel/process_64.c | 12 +- + arch/x86/kernel/stacktrace.c | 7 + + arch/x86/kernel/traps_32.c | 11 +- + arch/x86/kernel/traps_64.c | 11 +- + arch/x86/mm/Makefile | 2 + + arch/x86/mm/fault.c | 18 ++- + arch/x86/mm/kmemcheck/Makefile | 3 + + arch/x86/mm/kmemcheck/error.c | 216 ++++++++++++++++ + arch/x86/mm/kmemcheck/error.h | 15 ++ + arch/x86/mm/kmemcheck/kmemcheck.c | 485 +++++++++++++++++++++++++++++++++++++ + arch/x86/mm/kmemcheck/opcode.c | 72 ++++++ + arch/x86/mm/kmemcheck/opcode.h | 9 + + arch/x86/mm/kmemcheck/pte.c | 22 ++ + arch/x86/mm/kmemcheck/pte.h | 10 + + arch/x86/mm/kmemcheck/shadow.c | 178 ++++++++++++++ + arch/x86/mm/kmemcheck/shadow.h | 16 ++ + arch/x86/mm/kmemcheck/smp.c | 80 ++++++ + arch/x86/mm/kmemcheck/smp.h | 23 ++ + arch/x86/mm/kmemcheck/string.c | 95 +++++++ + include/asm-x86/kdebug.h | 3 +- + include/asm-x86/kmemcheck.h | 36 +++ + include/asm-x86/pgtable.h | 4 +- + include/asm-x86/pgtable_32.h | 6 + + include/asm-x86/pgtable_64.h | 6 + + include/asm-x86/string_32.h | 8 + + include/asm-x86/string_64.h | 1 + + include/linux/gfp.h | 3 +- + include/linux/interrupt.h | 14 + + include/linux/kmemcheck.h | 70 ++++++ + include/linux/mm_types.h | 4 + + include/linux/slab.h | 7 + + include/linux/slab_def.h | 81 ++++++ + include/linux/stacktrace.h | 3 + + init/main.c | 4 + + kernel/fork.c | 16 +- + kernel/softirq.c | 11 + + kernel/sysctl.c | 26 ++- + mm/Makefile | 1 + + mm/kmemcheck.c | 97 ++++++++ + mm/slab.c | 101 ++------- + mm/slub.c | 20 ++- + 46 files changed, 1948 insertions(+), 117 deletions(-) + create mode 100644 Documentation/kmemcheck.txt + create mode 100644 arch/x86/mm/kmemcheck/Makefile + create mode 100644 arch/x86/mm/kmemcheck/error.c + create mode 100644 arch/x86/mm/kmemcheck/error.h + create mode 100644 arch/x86/mm/kmemcheck/kmemcheck.c + create mode 100644 arch/x86/mm/kmemcheck/opcode.c + create mode 100644 arch/x86/mm/kmemcheck/opcode.h + create mode 100644 arch/x86/mm/kmemcheck/pte.c + create mode 100644 arch/x86/mm/kmemcheck/pte.h + create mode 100644 arch/x86/mm/kmemcheck/shadow.c + create mode 100644 arch/x86/mm/kmemcheck/shadow.h + create mode 100644 arch/x86/mm/kmemcheck/smp.c + create mode 100644 arch/x86/mm/kmemcheck/smp.h + create mode 100644 arch/x86/mm/kmemcheck/string.c + create mode 100644 include/asm-x86/kmemcheck.h + create mode 100644 include/linux/kmemcheck.h + create mode 100644 mm/kmemcheck.c +Merging generic-ipi/auto-generic-ipi-next +$ git merge generic-ipi/auto-generic-ipi-next +Already up-to-date. +Merging mfd/for-next +$ git merge mfd/for-next +Merge made by recursive. + drivers/mfd/mfd-core.c | 15 +++++++++++---- + drivers/mfd/sm501.c | 6 +++--- + 2 files changed, 14 insertions(+), 7 deletions(-) +Merging hdlc/hdlc-next +$ git merge hdlc/hdlc-next +Removed Documentation/DocBook/wanbook.tmpl +Removed drivers/net/wan/syncppp.c +Removed include/net/syncppp.h +Merge made by recursive. + Documentation/DocBook/Makefile | 2 +- + Documentation/DocBook/networking.tmpl | 3 - + Documentation/DocBook/wanbook.tmpl | 99 -- + Documentation/networking/generic-hdlc.txt | 8 +- + drivers/net/wan/Makefile | 2 +- + drivers/net/wan/c101.c | 6 +- + drivers/net/wan/{hd6457x.c => hd64570.c} | 254 ++---- + drivers/net/wan/hd64572.c | 641 +++++++++++++ + drivers/net/wan/hdlc_ppp.c | 648 ++++++++++++- + drivers/net/wan/n2.c | 9 +- + drivers/net/wan/pc300too.c | 73 +- + drivers/net/wan/pci200syn.c | 77 +- + drivers/net/wan/syncppp.c | 1479 ----------------------------- + include/net/syncppp.h | 102 -- + 14 files changed, 1357 insertions(+), 2046 deletions(-) + delete mode 100644 Documentation/DocBook/wanbook.tmpl + rename drivers/net/wan/{hd6457x.c => hd64570.c} (78%) + create mode 100644 drivers/net/wan/hd64572.c + delete mode 100644 drivers/net/wan/syncppp.c + delete mode 100644 include/net/syncppp.h +Merging drm/drm-next +$ git merge drm/drm-next +Auto-merged drivers/gpu/drm/radeon/radeon_cp.c +Merge made by recursive. + drivers/gpu/drm/Kconfig | 1 + + drivers/gpu/drm/drm_fops.c | 2 +- + drivers/gpu/drm/drm_irq.c | 20 +- + drivers/gpu/drm/drm_sysfs.c | 2 +- + drivers/gpu/drm/i915/Makefile | 3 +- + drivers/gpu/drm/i915/i915_dma.c | 171 +++-- + drivers/gpu/drm/i915/i915_drv.c | 462 +----------- + drivers/gpu/drm/i915/i915_drv.h | 877 ++-------------------- + drivers/gpu/drm/i915/i915_irq.c | 189 ++++-- + drivers/gpu/drm/i915/i915_opregion.c | 371 +++++++++ + drivers/gpu/drm/i915/i915_reg.h | 1406 ++++++++++++++++++++++++++++++++++ + drivers/gpu/drm/i915/i915_suspend.c | 509 ++++++++++++ + drivers/gpu/drm/radeon/radeon_cp.c | 5 +- + drivers/gpu/drm/sis/sis_mm.c | 10 +- + include/drm/drm.h | 17 - + 15 files changed, 2610 insertions(+), 1435 deletions(-) + create mode 100644 drivers/gpu/drm/i915/i915_opregion.c + create mode 100644 drivers/gpu/drm/i915/i915_reg.h + create mode 100644 drivers/gpu/drm/i915/i915_suspend.c +Merging voltage/reg-for-linus +$ git merge voltage/reg-for-linus +Already up-to-date. +Merging security-testing/next +$ git merge security-testing/next +Auto-merged Documentation/DocBook/kernel-api.tmpl +Merge made by recursive. + Documentation/SELinux.txt | 27 ++++ + drivers/char/tpm/Kconfig | 1 + + include/linux/security.h | 54 +++++---- + scripts/Makefile | 3 +- + scripts/selinux/Makefile | 2 + + scripts/selinux/README | 2 + + scripts/selinux/install_policy.sh | 69 ++++++++++ + scripts/selinux/mdp/Makefile | 5 + + scripts/selinux/mdp/dbus_contexts | 6 + + scripts/selinux/mdp/mdp.c | 242 +++++++++++++++++++++++++++++++++++ + security/Kconfig | 8 + + security/Makefile | 3 +- + security/selinux/avc.c | 2 +- + security/selinux/hooks.c | 60 ++++++--- + security/selinux/include/avc.h | 4 + + security/selinux/include/security.h | 15 ++- + security/selinux/ss/avtab.c | 8 +- + security/selinux/ss/conditional.c | 18 ++-- + security/selinux/ss/conditional.h | 2 +- + security/selinux/ss/ebitmap.c | 4 +- + security/selinux/ss/hashtab.c | 6 +- + security/selinux/ss/mls.c | 14 +- + security/selinux/ss/policydb.c | 225 +++++++++++++++++++++++++++++---- + security/selinux/ss/policydb.h | 5 + + security/selinux/ss/services.c | 180 +++++++++++++++++++++++++- + security/selinux/ss/sidtab.c | 12 +- + security/smack/smack.h | 1 + + security/smack/smack_access.c | 10 ++- + security/smack/smackfs.c | 92 +++++++++++++ + 29 files changed, 967 insertions(+), 113 deletions(-) + create mode 100644 Documentation/SELinux.txt + create mode 100644 scripts/selinux/Makefile + create mode 100644 scripts/selinux/README + create mode 100644 scripts/selinux/install_policy.sh + create mode 100644 scripts/selinux/mdp/Makefile + create mode 100644 scripts/selinux/mdp/dbus_contexts + create mode 100644 scripts/selinux/mdp/mdp.c +Merging lblnet/master +$ git merge lblnet/master +Auto-merged security/selinux/hooks.c +Auto-merged security/selinux/ss/services.c +Auto-merged security/smack/smackfs.c +Merge made by recursive. + include/net/cipso_ipv4.h | 55 +++- + include/net/netlabel.h | 50 ++- + net/ipv4/cipso_ipv4.c | 609 ++++++++++++++++++++++++----------- + net/ipv4/ip_options.c | 2 +- + net/netlabel/Makefile | 3 +- + net/netlabel/netlabel_addrlist.c | 388 ++++++++++++++++++++++ + net/netlabel/netlabel_addrlist.h | 189 +++++++++++ + net/netlabel/netlabel_cipso_v4.c | 132 ++++++--- + net/netlabel/netlabel_cipso_v4.h | 10 +- + net/netlabel/netlabel_domainhash.c | 377 +++++++++++++++++----- + net/netlabel/netlabel_domainhash.h | 40 +++- + net/netlabel/netlabel_kapi.c | 270 +++++++++++----- + net/netlabel/netlabel_mgmt.c | 399 +++++++++++++++++------ + net/netlabel/netlabel_mgmt.h | 59 +++- + net/netlabel/netlabel_unlabeled.c | 425 ++++++++----------------- + security/selinux/hooks.c | 110 ++++++- + security/selinux/include/netlabel.h | 34 ++ + security/selinux/include/objsec.h | 9 +- + security/selinux/netlabel.c | 181 ++++++++++- + security/selinux/ss/services.c | 13 +- + security/smack/smack_lsm.c | 5 +- + security/smack/smackfs.c | 4 +- + 22 files changed, 2495 insertions(+), 869 deletions(-) + create mode 100644 net/netlabel/netlabel_addrlist.c + create mode 100644 net/netlabel/netlabel_addrlist.h +Merging quilt/ttydev +$ git merge quilt/ttydev +Auto-merged Documentation/feature-removal-schedule.txt +CONFLICT (content): Merge conflict in Documentation/feature-removal-schedule.txt +Auto-merged drivers/char/amiserial.c +Auto-merged drivers/char/ip2/ip2main.c +Auto-merged drivers/char/istallion.c +Auto-merged drivers/char/stallion.c +Auto-merged drivers/char/tty_io.c +CONFLICT (content): Merge conflict in drivers/char/tty_io.c +Auto-merged drivers/char/vt.c +CONFLICT (content): Merge conflict in drivers/char/vt.c +Auto-merged drivers/isdn/capi/capi.c +Auto-merged drivers/net/usb/hso.c +Auto-merged drivers/serial/8250.c +Auto-merged drivers/serial/Kconfig +Removed drivers/serial/mcfserial.c +Removed drivers/serial/mcfserial.h +Auto-merged drivers/usb/serial/aircable.c +CONFLICT (content): Merge conflict in drivers/usb/serial/aircable.c +Auto-merged drivers/usb/serial/belkin_sa.c +Auto-merged drivers/usb/serial/cyberjack.c +Auto-merged drivers/usb/serial/cypress_m8.c +Auto-merged drivers/usb/serial/digi_acceleport.c +Auto-merged drivers/usb/serial/empeg.c +Auto-merged drivers/usb/serial/ftdi_sio.c +Auto-merged drivers/usb/serial/garmin_gps.c +Auto-merged drivers/usb/serial/io_edgeport.c +Auto-merged drivers/usb/serial/io_ti.c +Auto-merged drivers/usb/serial/ipaq.c +Auto-merged drivers/usb/serial/ipw.c +Auto-merged drivers/usb/serial/ir-usb.c +Auto-merged drivers/usb/serial/iuu_phoenix.c +Auto-merged drivers/usb/serial/keyspan.c +Auto-merged drivers/usb/serial/keyspan_pda.c +CONFLICT (content): Merge conflict in drivers/usb/serial/keyspan_pda.c +Auto-merged drivers/usb/serial/kl5kusb105.c +Auto-merged drivers/usb/serial/kobil_sct.c +Auto-merged drivers/usb/serial/mct_u232.c +Auto-merged drivers/usb/serial/mos7720.c +Auto-merged drivers/usb/serial/mos7840.c +Auto-merged drivers/usb/serial/omninet.c +Auto-merged drivers/usb/serial/option.c +Auto-merged drivers/usb/serial/pl2303.c +Auto-merged drivers/usb/serial/safe_serial.c +CONFLICT (content): Merge conflict in drivers/usb/serial/safe_serial.c +Auto-merged drivers/usb/serial/sierra.c +Auto-merged drivers/usb/serial/spcp8x5.c +Auto-merged drivers/usb/serial/ti_usb_3410_5052.c +Auto-merged drivers/usb/serial/usb-serial.c +Auto-merged drivers/usb/serial/visor.c +Auto-merged drivers/usb/serial/whiteheat.c +Auto-merged fs/dquot.c +Auto-merged include/asm-x86/ioctls.h +Auto-merged kernel/auditsc.c +CONFLICT (content): Merge conflict in kernel/auditsc.c +Auto-merged kernel/fork.c +Auto-merged kernel/printk.c +Resolved 'Documentation/feature-removal-schedule.txt' using previous resolution. +Resolved 'drivers/char/tty_io.c' using previous resolution. +Resolved 'drivers/char/vt.c' using previous resolution. +Resolved 'drivers/usb/serial/aircable.c' using previous resolution. +Resolved 'drivers/usb/serial/keyspan_pda.c' using previous resolution. +Resolved 'drivers/usb/serial/safe_serial.c' using previous resolution. +Resolved 'kernel/auditsc.c' using previous resolution. +Automatic merge failed; fix conflicts and then commit the result. +$ git commit -v -a +Created commit 9ece802: Merge branch 'quilt/ttydev' +$ git diff -M --stat --summary HEAD^.. + Documentation/feature-removal-schedule.txt | 8 - + arch/blackfin/kernel/bfin_dma_5xx.c | 13 +- + .../mach-bf527/include/mach/bfin_serial_5xx.h | 6 +- + .../mach-bf533/include/mach/bfin_serial_5xx.h | 4 +- + .../mach-bf537/include/mach/bfin_serial_5xx.h | 6 +- + .../mach-bf548/include/mach/bfin_serial_5xx.h | 6 +- + .../mach-bf561/include/mach/bfin_serial_5xx.h | 4 +- + arch/um/drivers/line.c | 2 + + drivers/bluetooth/hci_ldisc.c | 2 +- + drivers/char/Kconfig | 4 +- + drivers/char/Makefile | 2 +- + drivers/char/amiserial.c | 6 - + drivers/char/cyclades.c | 21 +- + drivers/char/epca.c | 5 +- + drivers/char/generic_serial.c | 21 - + drivers/char/hvc_console.c | 4 +- + drivers/char/ip2/ip2main.c | 6 +- + drivers/char/isicom.c | 61 +- + drivers/char/istallion.c | 113 +- + drivers/char/moxa.c | 61 +- + drivers/char/mxser.c | 193 +- + drivers/char/n_hdlc.c | 2 +- + drivers/char/n_r3964.c | 9 +- + drivers/char/n_tty.c | 99 +- + drivers/char/pcmcia/ipwireless/tty.c | 19 +- + drivers/char/pty.c | 335 +++- + drivers/char/stallion.c | 139 +- + drivers/char/sx.c | 4 +- + drivers/char/tty_buffer.c | 511 +++++ + drivers/char/tty_io.c | 1371 ++++---------- + drivers/char/tty_ioctl.c | 212 ++- + drivers/char/tty_port.c | 96 + + drivers/char/vt.c | 80 +- + drivers/char/vt_ioctl.c | 2 + + drivers/isdn/capi/capi.c | 2 +- + drivers/isdn/gigaset/ser-gigaset.c | 27 +- + drivers/net/usb/hso.c | 46 +- + drivers/net/wan/Kconfig | 2 +- + drivers/serial/68328serial.c | 11 +- + drivers/serial/8250.c | 83 +- + drivers/serial/Kconfig | 16 +- + drivers/serial/Makefile | 1 - + drivers/serial/bfin_5xx.c | 123 +- + drivers/serial/crisv10.c | 5 +- + drivers/serial/mcfserial.c | 1965 -------------------- + drivers/serial/mcfserial.h | 74 - + drivers/usb/serial/aircable.c | 12 +- + drivers/usb/serial/belkin_sa.c | 3 +- + drivers/usb/serial/console.c | 8 +- + drivers/usb/serial/cyberjack.c | 3 +- + drivers/usb/serial/cypress_m8.c | 5 +- + drivers/usb/serial/digi_acceleport.c | 19 +- + drivers/usb/serial/empeg.c | 8 +- + drivers/usb/serial/ftdi_sio.c | 19 +- + drivers/usb/serial/garmin_gps.c | 3 +- + drivers/usb/serial/generic.c | 3 +- + drivers/usb/serial/io_edgeport.c | 43 +- + drivers/usb/serial/io_ti.c | 26 +- + drivers/usb/serial/ipaq.c | 3 +- + drivers/usb/serial/ipw.c | 3 +- + drivers/usb/serial/ir-usb.c | 3 +- + drivers/usb/serial/iuu_phoenix.c | 3 +- + drivers/usb/serial/keyspan.c | 77 +- + drivers/usb/serial/keyspan_pda.c | 11 +- + drivers/usb/serial/kl5kusb105.c | 3 +- + drivers/usb/serial/kobil_sct.c | 3 +- + drivers/usb/serial/mct_u232.c | 6 +- + drivers/usb/serial/mos7720.c | 36 +- + drivers/usb/serial/mos7840.c | 7 +- + drivers/usb/serial/navman.c | 3 +- + drivers/usb/serial/omninet.c | 10 +- + drivers/usb/serial/option.c | 18 +- + drivers/usb/serial/oti6858.c | 3 +- + drivers/usb/serial/pl2303.c | 4 +- + drivers/usb/serial/safe_serial.c | 11 +- + drivers/usb/serial/sierra.c | 16 +- + drivers/usb/serial/spcp8x5.c | 3 +- + drivers/usb/serial/ti_usb_3410_5052.c | 44 +- + drivers/usb/serial/usb-serial.c | 24 +- + drivers/usb/serial/visor.c | 18 +- + drivers/usb/serial/whiteheat.c | 8 +- + fs/devpts/inode.c | 66 +- + fs/dquot.c | 6 +- + fs/open.c | 3 +- + include/asm-x86/ioctls.h | 6 + + include/linux/devpts_fs.h | 31 +- + include/linux/serial.h | 16 + + include/linux/termios.h | 15 + + include/linux/tty.h | 45 +- + include/linux/tty_driver.h | 56 +- + include/linux/vt_kern.h | 2 +- + kernel/acct.c | 2 +- + kernel/auditsc.c | 9 +- + kernel/fork.c | 5 +- + kernel/printk.c | 16 - + kernel/sys.c | 4 +- + 96 files changed, 2587 insertions(+), 3946 deletions(-) + create mode 100644 drivers/char/tty_buffer.c + create mode 100644 drivers/char/tty_port.c + delete mode 100644 drivers/serial/mcfserial.c + delete mode 100644 drivers/serial/mcfserial.h +Merging agp/agp-next +$ git merge agp/agp-next +Already up-to-date. +Merging creds/next-creds +$ git merge creds/next-creds +Auto-merged arch/ia64/ia32/sys_ia32.c +Auto-merged arch/mips/kernel/vpe.c +Auto-merged arch/s390/kernel/compat_linux.c +Auto-merged arch/x86/ia32/ia32_aout.c +Auto-merged arch/x86/mm/fault.c +Auto-merged drivers/media/video/cpia.c +Auto-merged drivers/net/tun.c +Auto-merged drivers/net/wan/sbni.c +CONFLICT (content): Merge conflict in drivers/net/wan/sbni.c +Auto-merged drivers/usb/core/devio.c +Auto-merged drivers/usb/core/inode.c +Auto-merged fs/binfmt_flat.c +Auto-merged fs/cifs/connect.c +Auto-merged fs/cifs/inode.c +Auto-merged fs/compat.c +Auto-merged fs/devpts/inode.c +Auto-merged fs/dquot.c +Auto-merged fs/ecryptfs/main.c +Auto-merged fs/exec.c +Auto-merged fs/exportfs/expfs.c +Auto-merged fs/ext4/balloc.c +Auto-merged fs/ext4/ialloc.c +Auto-merged fs/fat/inode.c +Auto-merged fs/gfs2/inode.c +Auto-merged fs/hpfs/namei.c +Auto-merged fs/ioprio.c +Auto-merged fs/jffs2/fs.c +Auto-merged fs/namei.c +Auto-merged fs/namespace.c +CONFLICT (content): Merge conflict in fs/namespace.c +Auto-merged fs/nfsd/nfs4recover.c +CONFLICT (content): Merge conflict in fs/nfsd/nfs4recover.c +Auto-merged fs/nfsd/nfsfh.c +Auto-merged fs/nfsd/vfs.c +Auto-merged fs/ocfs2/namei.c +Auto-merged fs/omfs/inode.c +Auto-merged fs/open.c +Auto-merged fs/reiserfs/namei.c +Auto-merged fs/ubifs/budget.c +Auto-merged fs/ubifs/dir.c +Auto-merged fs/udf/ialloc.c +Auto-merged fs/udf/namei.c +Auto-merged fs/xfs/linux-2.6/xfs_ioctl.c +Auto-merged fs/xfs/linux-2.6/xfs_linux.h +CONFLICT (content): Merge conflict in fs/xfs/linux-2.6/xfs_linux.h +Auto-merged fs/xfs/xfs_inode.c +CONFLICT (content): Merge conflict in fs/xfs/xfs_inode.c +Auto-merged fs/xfs/xfs_vnodeops.c +CONFLICT (content): Merge conflict in fs/xfs/xfs_vnodeops.c +Auto-merged include/linux/capability.h +CONFLICT (content): Merge conflict in include/linux/capability.h +Auto-merged include/linux/cred.h +CONFLICT (add/add): Merge conflict in include/linux/cred.h +Auto-merged include/linux/fs.h +Removed include/linux/key-ui.h +Auto-merged include/linux/sched.h +Auto-merged include/linux/security.h +CONFLICT (content): Merge conflict in include/linux/security.h +Auto-merged init/main.c +Auto-merged kernel/Makefile +Auto-merged kernel/acct.c +Auto-merged kernel/auditsc.c +Auto-merged kernel/capability.c +Auto-merged kernel/exit.c +CONFLICT (content): Merge conflict in kernel/exit.c +Auto-merged kernel/fork.c +CONFLICT (content): Merge conflict in kernel/fork.c +Auto-merged kernel/kmod.c +Auto-merged kernel/ptrace.c +Auto-merged kernel/sched.c +Auto-merged kernel/signal.c +Auto-merged kernel/sys.c +Auto-merged kernel/sysctl.c +Auto-merged kernel/timer.c +Auto-merged kernel/trace/trace.c +Auto-merged kernel/user.c +Auto-merged kernel/user_namespace.c +Auto-merged lib/Makefile +Auto-merged mm/migrate.c +Auto-merged mm/oom_kill.c +Auto-merged net/9p/client.c +Auto-merged net/core/dev.c +Auto-merged net/socket.c +Auto-merged net/sunrpc/auth.c +Auto-merged net/unix/af_unix.c +Auto-merged security/capability.c +Auto-merged security/commoncap.c +CONFLICT (content): Merge conflict in security/commoncap.c +Auto-merged security/root_plug.c +Auto-merged security/security.c +Auto-merged security/selinux/hooks.c +CONFLICT (content): Merge conflict in security/selinux/hooks.c +Auto-merged security/selinux/include/objsec.h +Auto-merged security/smack/smack_lsm.c +CONFLICT (content): Merge conflict in security/smack/smack_lsm.c +Auto-merged security/smack/smackfs.c +Recorded preimage for 'security/smack/smack_lsm.c' +Resolved 'drivers/net/wan/sbni.c' using previous resolution. +Resolved 'fs/namespace.c' using previous resolution. +Resolved 'fs/nfsd/nfs4recover.c' using previous resolution. +Resolved 'fs/xfs/linux-2.6/xfs_linux.h' using previous resolution. +Resolved 'fs/xfs/xfs_inode.c' using previous resolution. +Resolved 'fs/xfs/xfs_vnodeops.c' using previous resolution. +Resolved 'include/linux/capability.h' using previous resolution. +Resolved 'include/linux/cred.h' using previous resolution. +Resolved 'include/linux/security.h' using previous resolution. +Resolved 'kernel/exit.c' using previous resolution. +Resolved 'kernel/fork.c' using previous resolution. +Resolved 'security/commoncap.c' using previous resolution. +Resolved 'security/selinux/hooks.c' using previous resolution. +Automatic merge failed; fix conflicts and then commit the result. +$ git commit -v -a +Recorded resolution for 'security/smack/smack_lsm.c'. +Created commit f87181a: Merge commit 'creds/next-creds' +$ git diff -M --stat --summary HEAD^.. + Documentation/credentials.txt | 582 +++++++++++++ + arch/alpha/kernel/asm-offsets.c | 11 +- + arch/alpha/kernel/entry.S | 10 +- + arch/ia64/ia32/sys_ia32.c | 7 +- + arch/ia64/kernel/mca_drv.c | 2 +- + arch/ia64/kernel/perfmon.c | 43 +- + arch/ia64/kernel/signal.c | 4 +- + arch/mips/kernel/kspd.c | 4 +- + arch/mips/kernel/mips-mt-fpaff.c | 5 +- + arch/mips/kernel/vpe.c | 4 +- + arch/parisc/kernel/signal.c | 2 +- + arch/powerpc/mm/fault.c | 2 +- + arch/powerpc/platforms/cell/spufs/inode.c | 9 +- + arch/s390/hypfs/inode.c | 4 +- + arch/s390/kernel/compat_linux.c | 28 +- + arch/x86/ia32/ia32_aout.c | 2 +- + arch/x86/mm/fault.c | 2 +- + drivers/block/loop.c | 6 +- + drivers/char/tty_audit.c | 6 +- + drivers/connector/cn_proc.c | 16 +- + drivers/isdn/capi/capifs.c | 4 +- + drivers/isdn/hysdn/hysdn_procconf.c | 6 +- + drivers/net/tun.c | 8 +- + drivers/usb/core/devio.c | 10 +- + drivers/usb/core/inode.c | 4 +- + fs/9p/fid.c | 2 +- + fs/9p/vfs_inode.c | 4 +- + fs/9p/vfs_super.c | 4 +- + fs/affs/inode.c | 4 +- + fs/affs/super.c | 4 +- + fs/anon_inodes.c | 4 +- + fs/attr.c | 4 +- + fs/autofs/inode.c | 4 +- + fs/autofs4/inode.c | 4 +- + fs/autofs4/waitq.c | 4 +- + fs/bfs/dir.c | 4 +- + fs/binfmt_aout.c | 2 +- + fs/binfmt_elf.c | 20 +- + fs/binfmt_elf_fdpic.c | 19 +- + fs/binfmt_flat.c | 2 +- + fs/binfmt_som.c | 2 +- + fs/cifs/cifs_fs_sb.h | 2 +- + fs/cifs/cifsproto.h | 2 +- + fs/cifs/connect.c | 4 +- + fs/cifs/dir.c | 12 +- + fs/cifs/inode.c | 8 +- + fs/cifs/ioctl.c | 2 +- + fs/cifs/misc.c | 4 +- + fs/coda/cache.c | 6 +- + fs/coda/file.c | 3 +- + fs/coda/upcall.c | 2 +- + fs/compat.c | 42 +- + fs/devpts/inode.c | 4 +- + fs/dquot.c | 4 +- + fs/ecryptfs/ecryptfs_kernel.h | 3 +- + fs/ecryptfs/kthread.c | 9 +- + fs/ecryptfs/main.c | 3 +- + fs/ecryptfs/messaging.c | 18 +- + fs/ecryptfs/miscdev.c | 20 +- + fs/exec.c | 183 +++-- + fs/exportfs/expfs.c | 4 +- + fs/ext2/balloc.c | 2 +- + fs/ext2/ialloc.c | 4 +- + fs/ext3/balloc.c | 2 +- + fs/ext3/ialloc.c | 4 +- + fs/ext4/balloc.c | 3 +- + fs/ext4/ialloc.c | 4 +- + fs/fat/file.c | 2 +- + fs/fat/inode.c | 4 +- + fs/fcntl.c | 18 +- + fs/file_table.c | 10 +- + fs/fuse/dev.c | 4 +- + fs/fuse/dir.c | 25 +- + fs/gfs2/inode.c | 10 +- + fs/hfs/inode.c | 4 +- + fs/hfs/super.c | 4 +- + fs/hfsplus/inode.c | 4 +- + fs/hfsplus/options.c | 4 +- + fs/hpfs/namei.c | 24 +- + fs/hpfs/super.c | 4 +- + fs/hppfs/hppfs.c | 6 +- + fs/hugetlbfs/inode.c | 21 +- + fs/inotify_user.c | 2 +- + fs/internal.h | 6 + + fs/ioprio.c | 18 +- + fs/jfs/jfs_inode.c | 4 +- + fs/locks.c | 2 +- + fs/minix/bitmap.c | 4 +- + fs/namei.c | 10 +- + fs/namespace.c | 2 +- + fs/ncpfs/ioctl.c | 91 +- + fs/nfsctl.c | 4 +- + fs/nfsd/auth.c | 95 ++- + fs/nfsd/nfs4recover.c | 71 +- + fs/nfsd/nfsfh.c | 11 +- + fs/nfsd/vfs.c | 9 +- + fs/ocfs2/dlm/dlmfs.c | 8 +- + fs/ocfs2/namei.c | 4 +- + fs/omfs/inode.c | 8 +- + fs/open.c | 59 +- + fs/pipe.c | 4 +- + fs/posix_acl.c | 4 +- + fs/proc/array.c | 32 +- + fs/proc/base.c | 32 +- + fs/quota.c | 4 +- + fs/ramfs/inode.c | 4 +- + fs/reiserfs/namei.c | 4 +- + fs/smbfs/dir.c | 3 +- + fs/smbfs/inode.c | 2 +- + fs/smbfs/proc.c | 2 +- + fs/sysv/ialloc.c | 4 +- + fs/ubifs/budget.c | 2 +- + fs/ubifs/dir.c | 4 +- + fs/udf/ialloc.c | 4 +- + fs/udf/namei.c | 2 +- + fs/ufs/ialloc.c | 4 +- + fs/xfs/linux-2.6/xfs_cred.h | 6 +- + fs/xfs/linux-2.6/xfs_globals.h | 2 +- + fs/xfs/linux-2.6/xfs_ioctl.c | 5 +- + fs/xfs/xfs_acl.c | 6 +- + fs/xfs/xfs_inode.h | 2 +- + fs/xfs/xfs_vnodeops.h | 10 +- + include/keys/keyring-type.h | 31 + + include/linux/binfmts.h | 16 +- + include/linux/capability.h | 2 - + include/linux/cred.h | 340 +++++++- + include/linux/fs.h | 8 +- + include/linux/init_task.h | 13 +- + include/linux/key-ui.h | 66 -- + include/linux/key.h | 32 +- + include/linux/keyctl.h | 4 +- + include/linux/sched.h | 64 +-- + include/linux/securebits.h | 2 +- + include/linux/security.h | 326 ++++---- + include/net/scm.h | 4 +- + init/main.c | 1 + + ipc/mqueue.c | 19 +- + ipc/shm.c | 9 +- + ipc/util.c | 18 +- + kernel/Makefile | 2 +- + kernel/acct.c | 7 +- + kernel/auditsc.c | 57 +- + kernel/capability.c | 268 +------ + kernel/cgroup.c | 17 +- + kernel/cred-internals.h | 26 + + kernel/cred.c | 591 +++++++++++++ + kernel/exit.c | 23 +- + kernel/fork.c | 45 +- + kernel/futex.c | 20 +- + kernel/futex_compat.c | 7 +- + kernel/kmod.c | 30 +- + kernel/ptrace.c | 29 +- + kernel/sched.c | 26 +- + kernel/signal.c | 60 +- + kernel/sys.c | 579 ++++++++------ + kernel/sysctl.c | 2 +- + kernel/timer.c | 8 +- + kernel/trace/trace.c | 2 +- + kernel/tsacct.c | 6 +- + kernel/uid16.c | 31 +- + kernel/user.c | 37 +- + kernel/user_namespace.c | 14 +- + kernel/workqueue.c | 8 +- + lib/Makefile | 2 +- + lib/is_single_threaded.c | 45 + + mm/mempolicy.c | 9 +- + mm/migrate.c | 9 +- + mm/oom_kill.c | 6 +- + mm/shmem.c | 8 +- + net/9p/client.c | 2 +- + net/ax25/af_ax25.c | 2 +- + net/ax25/ax25_route.c | 2 +- + net/core/dev.c | 8 +- + net/core/scm.c | 10 +- + net/ipv4/netfilter/ipt_LOG.c | 4 +- + net/ipv6/ip6_flowlabel.c | 2 +- + net/ipv6/netfilter/ip6t_LOG.c | 4 +- + net/netfilter/nfnetlink_log.c | 5 +- + net/netfilter/xt_owner.c | 16 +- + net/netrom/af_netrom.c | 4 +- + net/rose/af_rose.c | 4 +- + net/rxrpc/ar-key.c | 6 +- + net/sched/cls_flow.c | 4 +- + net/socket.c | 4 +- + net/sunrpc/auth.c | 14 +- + net/unix/af_unix.c | 11 +- + security/capability.c | 56 +- + security/commoncap.c | 699 ++++++++++------ + security/keys/internal.h | 47 +- + security/keys/key.c | 25 +- + security/keys/keyctl.c | 210 +++-- + security/keys/keyring.c | 15 +- + security/keys/permission.c | 29 +- + security/keys/proc.c | 8 +- + security/keys/process_keys.c | 468 +++++------ + security/keys/request_key.c | 133 ++-- + security/keys/request_key_auth.c | 46 +- + security/root_plug.c | 13 +- + security/security.c | 96 +-- + security/selinux/exports.c | 8 +- + security/selinux/hooks.c | 1154 ++++++++++++++------------ + security/selinux/include/av_perm_to_string.h | 2 + + security/selinux/include/av_permissions.h | 2 + + security/selinux/include/class_to_string.h | 5 + + security/selinux/include/flask.h | 1 + + security/selinux/include/objsec.h | 11 - + security/selinux/selinuxfs.c | 13 +- + security/selinux/xfrm.c | 6 +- + security/smack/smack_access.c | 4 +- + security/smack/smack_lsm.c | 173 +++-- + security/smack/smackfs.c | 6 +- + 211 files changed, 5082 insertions(+), 3095 deletions(-) + create mode 100644 Documentation/credentials.txt + create mode 100644 include/keys/keyring-type.h + delete mode 100644 include/linux/key-ui.h + create mode 100644 kernel/cred-internals.h + create mode 100644 kernel/cred.c + create mode 100644 lib/is_single_threaded.c +Merging oprofile/auto-oprofile-next +$ git merge oprofile/auto-oprofile-next +Auto-merged arch/x86/kernel/apic_32.c +CONFLICT (content): Merge conflict in arch/x86/kernel/apic_32.c +Auto-merged arch/x86/kernel/apic_64.c +Removed arch/x86/oprofile/op_model_athlon.c +Auto-merged drivers/oprofile/cpu_buffer.c +Auto-merged include/linux/pci_ids.h +Resolved 'arch/x86/kernel/apic_32.c' using previous resolution. +Automatic merge failed; fix conflicts and then commit the result. +$ git commit -v -a +Created commit ee702fa: Merge commit 'oprofile/auto-oprofile-next' +$ git diff -M --stat --summary HEAD^.. + arch/Kconfig | 14 + + arch/x86/kernel/apic_32.c | 4 + + arch/x86/kernel/apic_64.c | 4 + + arch/x86/oprofile/Makefile | 2 +- + arch/x86/oprofile/nmi_int.c | 127 +++++++- + arch/x86/oprofile/op_counter.h | 3 +- + arch/x86/oprofile/op_model_amd.c | 559 +++++++++++++++++++++++++++++++++++ + arch/x86/oprofile/op_model_athlon.c | 190 ------------ + arch/x86/oprofile/op_model_p4.c | 4 + + arch/x86/oprofile/op_model_ppro.c | 2 + + arch/x86/oprofile/op_x86_model.h | 7 +- + drivers/oprofile/buffer_sync.c | 209 +++++++++---- + drivers/oprofile/cpu_buffer.c | 74 +++++- + drivers/oprofile/cpu_buffer.h | 2 + + drivers/oprofile/oprof.c | 58 ++++- + drivers/oprofile/oprof.h | 4 +- + drivers/oprofile/oprofile_files.c | 39 +++- + include/linux/oprofile.h | 5 + + include/linux/pci_ids.h | 5 + + 19 files changed, 1031 insertions(+), 281 deletions(-) + create mode 100644 arch/x86/oprofile/op_model_amd.c + delete mode 100644 arch/x86/oprofile/op_model_athlon.c +Merging fastboot/auto-fastboot-next +$ git merge fastboot/auto-fastboot-next +Auto-merged drivers/pci/pci.c +Auto-merged drivers/usb/host/ehci-hcd.c +Auto-merged include/asm-generic/vmlinux.lds.h +Auto-merged include/linux/init.h +CONFLICT (content): Merge conflict in include/linux/init.h +Auto-merged init/Kconfig +Auto-merged init/do_mounts.c +Auto-merged init/main.c +Resolved 'include/linux/init.h' using previous resolution. +Automatic merge failed; fix conflicts and then commit the result. +$ git commit -v -a +Created commit ce2587a: Merge commit 'fastboot/auto-fastboot-next' +$ git diff -M --stat --summary HEAD^.. + drivers/acpi/battery.c | 2 +- + drivers/acpi/button.c | 2 +- + drivers/acpi/thermal.c | 2 +- + drivers/pci/pci.c | 2 +- + drivers/usb/host/ehci-hcd.c | 2 +- + drivers/usb/host/ohci-hcd.c | 2 +- + drivers/usb/host/uhci-hcd.c | 2 +- + include/asm-generic/vmlinux.lds.h | 6 ++- + include/linux/init.h | 8 ++++ + init/Kconfig | 11 +++++ + init/do_mounts.c | 2 + + init/do_mounts_md.c | 9 ++++ + init/initramfs.c | 71 +++++++++++++++++++++++++++------- + init/main.c | 77 +++++++++++++++++++++++++++++++++++- + 14 files changed, 172 insertions(+), 26 deletions(-) +Merging sparseirq/auto-sparseirq-next +$ git merge sparseirq/auto-sparseirq-next +Auto-merged arch/x86/Kconfig +Auto-merged arch/x86/configs/i386_defconfig +Auto-merged arch/x86/kernel/Makefile +Auto-merged arch/x86/kernel/acpi/boot.c +CONFLICT (delete/modify): arch/x86/kernel/apic_64.c deleted in sparseirq/auto-sparseirq-next and modified in HEAD. Version HEAD of arch/x86/kernel/apic_64.c left in tree. +Auto-merged arch/x86/kernel/entry_32.S +Removed arch/x86/kernel/io_apic_32.c +Auto-merged arch/x86/kernel/setup.c +Auto-merged arch/x86/kernel/visws_quirks.c +Auto-merged arch/x86/kernel/vmlinux_32.lds.S +Auto-merged arch/x86/lguest/boot.c +Auto-merged arch/x86/xen/enlighten.c +Auto-merged arch/x86/xen/spinlock.c +CONFLICT (content): Merge conflict in arch/x86/xen/spinlock.c +Auto-merged drivers/char/random.c +Auto-merged drivers/mfd/asic3.c +Auto-merged drivers/net/wan/sbni.c +Auto-merged drivers/pcmcia/hd64465_ss.c +Auto-merged drivers/scsi/qla2xxx/qla_def.h +Auto-merged drivers/serial/68328serial.c +CONFLICT (content): Merge conflict in drivers/serial/68328serial.c +Auto-merged drivers/serial/8250.c +CONFLICT (content): Merge conflict in drivers/serial/8250.c +Auto-merged drivers/xen/events.c +Auto-merged fs/proc/proc_misc.c +Auto-merged include/asm-generic/vmlinux.lds.h +Auto-merged include/asm-x86/apic.h +Auto-merged include/asm-x86/genapic_32.h +Auto-merged include/asm-x86/irq_vectors.h +Removed include/asm-x86/mach-generic/irq_vectors_limits.h +Removed include/asm-x86/summit/irq_vectors_limits.h +Auto-merged include/linux/init.h +Auto-merged include/linux/interrupt.h +Auto-merged include/linux/pci.h +Auto-merged init/main.c +Auto-merged kernel/irq/manage.c +Recorded preimage for 'drivers/serial/8250.c' +Resolved 'arch/x86/xen/spinlock.c' using previous resolution. +Resolved 'drivers/serial/68328serial.c' using previous resolution. +Automatic merge failed; fix conflicts and then commit the result. +$ git rm arch/x86/kernel/apic_64.c +rm 'arch/x86/kernel/apic_64.c' +rm 'arch/x86/kernel/apic_64.c' +$ git commit -v -a +Recorded resolution for 'drivers/serial/8250.c'. +Created commit ba120ed: Merge commit 'sparseirq/auto-sparseirq-next' +$ git diff -M --stat --summary HEAD^.. + arch/Kconfig | 3 + + arch/m68k/kernel/ints.c | 3 + + arch/s390/kernel/irq.c | 3 + + arch/sparc/kernel/irq.c | 4 + + arch/x86/Kconfig | 20 +- + arch/x86/configs/i386_defconfig | 1 - + arch/x86/kernel/Makefile | 4 +- + arch/x86/kernel/acpi/boot.c | 5 +- + arch/x86/kernel/{apic_32.c => apic.c} | 468 +++- + arch/x86/kernel/apic_64.c | 1848 ------------- + arch/x86/kernel/entry_32.S | 2 +- + arch/x86/kernel/{io_apic_64.c => io_apic.c} | 1470 +++++++++-- + arch/x86/kernel/io_apic_32.c | 2908 --------------------- + arch/x86/kernel/irq_32.c | 71 +- + arch/x86/kernel/irq_64.c | 74 +- + arch/x86/kernel/irqinit_32.c | 48 +- + arch/x86/kernel/irqinit_64.c | 28 +- + arch/x86/kernel/quirks.c | 3 - + arch/x86/kernel/setup.c | 4 + + arch/x86/kernel/setup_percpu.c | 19 +- + arch/x86/kernel/visws_quirks.c | 32 +- + arch/x86/kernel/vmiclock_32.c | 3 + + arch/x86/kernel/vmlinux_32.lds.S | 1 + + arch/x86/kernel/vmlinux_64.lds.S | 3 + + arch/x86/lguest/boot.c | 2 +- + arch/x86/mach-generic/bigsmp.c | 4 + + arch/x86/mach-generic/es7000.c | 14 + + arch/x86/mach-generic/numaq.c | 14 + + arch/x86/mach-generic/summit.c | 14 + + arch/x86/mach-voyager/voyager_smp.c | 4 +- + arch/x86/mm/init_32.c | 3 + + arch/x86/xen/irq.c | 2 - + arch/x86/xen/spinlock.c | 2 +- + drivers/char/hpet.c | 2 +- + drivers/char/random.c | 72 +- + drivers/char/vr41xx_giu.c | 2 +- + drivers/gpio/gpiolib.c | 2 +- + drivers/mfd/asic3.c | 4 +- + drivers/mfd/htc-egpio.c | 2 +- + drivers/net/3c59x.c | 4 +- + drivers/net/hamradio/baycom_ser_fdx.c | 4 +- + drivers/net/hamradio/scc.c | 6 +- + drivers/net/wan/sbni.c | 2 +- + drivers/parisc/dino.c | 6 +- + drivers/parisc/eisa.c | 4 +- + drivers/parisc/gsc.c | 12 +- + drivers/parisc/iosapic.c | 4 +- + drivers/parisc/superio.c | 4 +- + drivers/pci/htirq.c | 22 +- + drivers/pci/intr_remapping.c | 221 ++- + drivers/pcmcia/at91_cf.c | 2 +- + drivers/pcmcia/hd64465_ss.c | 12 +- + drivers/pcmcia/vrc4171_card.c | 2 +- + drivers/rtc/rtc-vr41xx.c | 4 +- + drivers/scsi/aha152x.c | 2 +- + drivers/serial/8250.c | 2 +- + drivers/serial/amba-pl010.c | 2 +- + drivers/serial/amba-pl011.c | 2 +- + drivers/serial/cpm_uart/cpm_uart_core.c | 2 +- + drivers/serial/m32r_sio.c | 4 +- + drivers/serial/serial_core.c | 2 +- + drivers/serial/serial_lh7a40x.c | 2 +- + drivers/serial/sh-sci.c | 2 +- + drivers/serial/ucc_uart.c | 2 +- + drivers/xen/events.c | 20 +- + fs/proc/proc_misc.c | 72 +- + include/asm-generic/vmlinux.lds.h | 13 + + include/asm-x86/apic.h | 2 - + include/asm-x86/bigsmp/apic.h | 15 +- + include/asm-x86/es7000/apic.h | 3 +- + include/asm-x86/genapic_32.h | 2 + + include/asm-x86/hw_irq.h | 13 +- + include/asm-x86/io_apic.h | 24 +- + include/asm-x86/irq_vectors.h | 24 +- + include/asm-x86/mach-default/entry_arch.h | 1 + + include/asm-x86/mach-default/mach_apic.h | 15 +- + include/asm-x86/mach-generic/irq_vectors_limits.h | 14 - + include/asm-x86/mach-generic/mach_apic.h | 1 + + include/asm-x86/numaq/apic.h | 2 - + include/asm-x86/summit/apic.h | 1 - + include/asm-x86/summit/irq_vectors_limits.h | 14 - + include/linux/init.h | 44 + + include/linux/interrupt.h | 7 + + include/linux/irq.h | 85 +- + include/linux/kernel_stat.h | 26 +- + init/Makefile | 2 +- + init/dyn_array.c | 124 + + init/main.c | 11 +- + kernel/irq/autoprobe.c | 30 +- + kernel/irq/chip.c | 100 +- + kernel/irq/handle.c | 272 ++- + kernel/irq/internals.h | 4 +- + kernel/irq/manage.c | 65 +- + kernel/irq/migration.c | 14 +- + kernel/irq/proc.c | 44 +- + kernel/irq/resend.c | 6 +- + kernel/irq/spurious.c | 9 +- + 97 files changed, 3044 insertions(+), 5534 deletions(-) + rename arch/x86/kernel/{apic_32.c => apic.c} (83%) + delete mode 100644 arch/x86/kernel/apic_64.c + rename arch/x86/kernel/{io_apic_64.c => io_apic.c} (69%) + delete mode 100644 arch/x86/kernel/io_apic_32.c + delete mode 100644 include/asm-x86/mach-generic/irq_vectors_limits.h + delete mode 100644 include/asm-x86/summit/irq_vectors_limits.h + create mode 100644 init/dyn_array.c +$ git revert -m 1 9ece80214deb25f39a5015c160f53191817cd990 +Removed drivers/char/tty_buffer.c +Removed drivers/char/tty_port.c +Auto-merged drivers/serial/8250.c +Auto-merged fs/devpts/inode.c +Auto-merged fs/dquot.c +Auto-merged fs/open.c +Auto-merged kernel/acct.c +Auto-merged kernel/auditsc.c +Auto-merged kernel/fork.c +CONFLICT (content): Merge conflict in kernel/fork.c +Auto-merged kernel/sys.c +Automatic revert failed. After resolving the conflicts, +mark the corrected paths with 'git add ' or 'git rm ' and commit the result. +$ git commit -v -a +Created commit 0f6dc77: Revert "Merge branch 'quilt/ttydev'" + 96 files changed, 3953 insertions(+), 2594 deletions(-) + delete mode 100644 drivers/char/tty_buffer.c + delete mode 100644 drivers/char/tty_port.c + create mode 100644 drivers/serial/mcfserial.c + create mode 100644 drivers/serial/mcfserial.h + rewrite include/linux/termios.h (75%) +$ git am -3 ../patches/0001-revert-BUILD_BUG_ON-change.patch +Applying revert BUILD_BUG_ON change +$ git am -3 ../patches/0001-ftrace-protect-the-definition-of-ftrace_release.patch +Applying ftrace: protect the definition of ftrace_release +$ git revert 16f9b13de93c8bfdac16b4d15577af2c132358ef +Auto-merged kernel/notifier.c +Auto-merged lib/Kconfig.debug +Finished one revert. +Created commit 201c2cd: Revert "debug: add notifier chain debugging" + 2 files changed, 0 insertions(+), 26 deletions(-) +$ git am -3 ../patches/0001-debug-add-notifier-chain-debugging.patch +Applying debug: add notifier chain debugging +$ git am -3 ../patches/0001-sparc-qlogicpti-fallout-from-sbus-removal.patch +Applying sparc: qlogicpti fallout from sbus removal +$ git am -3 ../patches/0001-powerpc-make-sure-all-kernel-test-is-before-_etext.patch +Applying powerpc: make sure all kernel test is before _etext diff --git a/Next/quilt-import.log b/Next/quilt-import.log new file mode 100644 index 0000000..0c8c518 --- /dev/null +++ b/Next/quilt-import.log @@ -0,0 +1,154 @@ +Unchanged quilt series driver-core.current +Importing usb.current based on quilt/driver-core.current +$ git checkout quilt/usb.current +Switched to branch "quilt/usb.current" +$ git reset --hard 24342c34a022ee90839873d91396045e12ef1090 +HEAD is now at 24342c3 Linux 2.6.27-rc5 +$ git quiltimport --author Greg KH --patches ../quilt/usb.current +usb-storage-sierra-non-configurable-tru-install.patch +usb-serial-sierra-device-addition-version-rev.patch +usb-ehci-fix-some-ehci-hangs-and-crashes.patch +usb-fix-the-nokia-6300-storage-mode.patch +usb-correct-sierra-wireless-usb-evdo-modem-device-id.patch +usb-fix-hcd-interrupt-disabling.patch +usb-update-of-documentation-usb-anchors.txt.patch +usb-gadget-fix-omap_udc-dma-regression.patch +usb-fixing-nokia-3310c-in-storage-mode.patch +usb-musb-fix-include-path.patch +usb-fix-ehci-periodic-transfers.patch +usb-added-driver-for-a-delcom-usb-7-segment-led-display.patch +usb-add-usb-test-and-measurement-class-driver.patch +Importing m68k based on afa153fd7b6afcd55dd6df6aea06bb53aa1d3608 +$ git checkout quilt/m68k +Switched to branch "quilt/m68k" +$ git reset --hard afa153fd7b6afcd55dd6df6aea06bb53aa1d3608 +HEAD is now at afa153f Merge git://git.kernel.org/pub/scm/linux/kernel/git/bart/ide-2.6 +$ git quiltimport --author Geert Uytterhoeven --patches ../quilt/m68k +m68k-update-defconfigs-for-2.6.27-rc4.diff +m68k-use-bcd2bin-bin2bcd.diff +m68k-use-percent-pS-infrastructure.diff +m68k-put-bss-at-end-of-data-section.diff +m68k-add-notes-to-init-data.diff +m68k-reverse-platform-mmu-logic-so-sun3-is-last.diff +amiga-amiserial-no-serial-console-if-modular.diff +amiga-export-key_maps.diff +atari-kill-unused-atari_kbd_translate.diff +atari-define-rtc_lock.diff +m68k-add-dma_sync_single_range_for_cpu-device.diff +m68k-asm-pci-h-needs-asm-generic-pci-dma-compat.h.diff +Importing driver-core based on quilt/usb.current +$ git checkout quilt/driver-core +Switched to branch "quilt/driver-core" +$ git reset --hard 05e42f727f1314b8d67f7595e4cb51714a40ee59 +HEAD is now at 05e42f7 USB: add USB test and measurement class driver +$ git quiltimport --author Greg KH --patches ../quilt/driver-core +sysfs-crash-debugging.patch +device-create-block-convert-device_create_drvdata-to-device_create.patch +device-create-char-convert-device_create_drvdata-to-device_create.patch +device-create-ieee1394-convert-device_create_drvdata-to-device_create.patch +.dotest/patch:35: space before tab in indent. + MKDEV(IEEE1394_MAJOR, +warning: 1 line adds whitespace errors. +device-create-infiniband-convert-device_create_drvdata-to-device_create.patch +device-create-misc-convert-device_create_drvdata-to-device_create.patch +device-create-net-convert-device_create_drvdata-to-device_create.patch +device-create-s390-convert-device_create_drvdata-to-device_create.patch +device-create-scsi-convert-device_create_drvdata-to-device_create.patch +device-create-sound-convert-device_create_drvdata-to-device_create.patch +device-create-usb-convert-device_create_drvdata-to-device_create.patch +device-create-video-convert-device_create_drvdata-to-device_create.patch +device-create-ide-convert-device_create_drvdata-to-device_create.patch +device-create-remove-device_create_drvdata.patch +usb-gadget-link-fixes-for-serial-gadget.patch +usb-gadget-link-fixes-for-gadget-zero.patch +usb-gadget-link-fixes-for-midi-gadget.patch +usb-gadget-link-fixes-for-printer-gadget.patch +usb-gadget-link-fixes-for-storage-gadget.patch +usb-gadget-link-fixes-for-cdc-composite-gadget.patch +usb-gadget-link-fixes-for-network-gadget.patch +driver-core-basic-infrastructure-for-per-module-dynamic-debug-messages.patch +.dotest/patch:737: space before tab in indent. + $echo "set enabled=1 " > dynamic_printk/modules +.dotest/patch:741: space before tab in indent. + $echo "set enabled=0 " > dynamic_printk/modules +warning: 2 lines add whitespace errors. +driver-core-make-struct-platform_pm_ops-static.patch +sysfs-support-sysfs_notify-from-atomic-context-with-new-sysfs_notify_dirent.patch +drivers-firmware-iscsi_ibft.c-make-3-functions-static.patch +kobject-fix-kobject_rename-and-config_sysfs.patch +kobject-cleanup-kobject_rename-and-config_sysfs.patch +sysfs-support-for-preventing-unmounts.patch +sysfs-sysfs_get_dentry-add-a-sb-parameter.patch +sysfs-implement-__sysfs_get_dentry.patch +sysfs-rename-support-multiple-superblocks.patch +sysfs-introduce-sysfs_sd_setattr-and-fix-sysfs_chmod.patch +sysfs-sysfs_chmod_file-handle-multiple-superblocks.patch +.dotest/patch:37: space before tab in indent. + goto out; +warning: 1 line adds whitespace errors. +klist-don-t-iterate-over-deleted-entries.patch +driver-core-use-klist-for-class-device-list-and-implement-iterator.patch +driver-core-add-bus_sort_breadthfirst-function.patch +.dotest/patch:21: space before tab in indent. + int (*compare)(const struct device *a, +.dotest/patch:42: space before tab in indent. + const struct device *b)) +.dotest/patch:141: space before tab in indent. + const struct device *b)); +warning: 3 lines add whitespace errors. +net-convert-the-phy_device-file-to-use-bus_find_device_by_name.patch +warn-when-statically-allocated-kobjects-are-used.patch +Importing usb based on quilt/driver-core +$ git checkout quilt/usb +Switched to branch "quilt/usb" +$ git reset --hard 961b49bafa56f4eaf3856db75c237b909ef2beb1 +HEAD is now at 961b49b warn when statically-allocated kobjects are used +$ git quiltimport --author Greg KH --patches ../quilt/usb +drivers-usb-class-usblp.c-adjust-error-handling-code.patch +usb-kill-urbs-permanently.patch +usb-extend-poisoning-to-anchors.patch +ub-remove-sg_stat.patch +usb-let-some-usb-host-controllers-get-irq-flags-from-resource.patch +usb-gadget-kconfig-cleanup.patch +usb-gadget-dummy_hcd-implement-set_wedge.patch +usb-gadget-net2280-implement-set_wedge.patch +usb-gadget-function-activation-deactivation.patch +usb-gadget-cdc-obex-glue.patch +usb-gadget-defer-obex-enumeration.patch +fsl_usb2_udc-make-dr_ep_setup-function-static.patch +fsl_usb2_udc-remove-check-for-udc-null-in-dr_controller_setup.patch +fsl_usb2_udc-fix-some-sparse-warnings-and-remove-redundant-code.patch +fsl_usb2_udc-clean-up-whitespace-in-errors-and-warnings.patch +fsl_usb2_udc-clean-up-whitespace-in-proc-debugging-output.patch +fsl_usb2_udc-initialize-spinlock-earlier.patch +fsl_usb2_udc-rename-the-arguments-of-the-fsl_writel-macro.patch +fsl_usb2_udc-uninline-udc_reset_ep_queue.patch +fsl_usb2_udc-make-fsl_queue_td-return-type-void.patch +fsl_usb2_udc-add-a-wmb-before-priming-endpoint.patch +fsl_usb2_udc-fix-oops-on-probe-failure.patch +hso-fix-hso_serial_close-refcounting.patch +hso-put-linefeeds-on-printk-s-in-hso.c.patch +usb-remove-warn-macro-from-usb.h.patch +usb-remove-info-macro-from-usb.h.patch +.dotest/patch:2027: space before tab in indent. + USB_ENDPOINT_DIR_MASK + info->epnum +warning: 1 line adds whitespace errors. +usb-remove-use-of-err-in-drivers-usb-serial.patch +usb-gotemp.patch +Importing device-mapper based on v2.6.27-rc4-278-g4c246ed +$ git checkout quilt/device-mapper +Switched to branch "quilt/device-mapper" +$ git reset --hard 4c246edd2550304df5b766cc841584b2bb058843 +HEAD is now at 4c246ed IB/mlx4: Actually return L_Key and R_Key for fast register MRs +$ git quiltimport --author Alasdair G Kergon --patches ../quilt/device-mapper +dm-mpath-use-more-error-codes.patch +dm-mpath-remove-is_active-from-struct-dm_path.patch +dm-raid1-kcopyd-should-stop-on-error-if-errors-handled.patch +dm-exception-store-introduce-area_location-function.patch +dm-exception-store-use-chunk_t-for_areas.patch +Unchanged quilt series i2c +Unchanged quilt series jdelvare-hwmon +Unchanged quilt series kernel-doc +Unchanged quilt series ide +Unchanged quilt series rr +Unchanged quilt series ttydev diff --git a/arch/Kconfig b/arch/Kconfig index 364c6da..c8a7c2e 100644 --- a/arch/Kconfig +++ b/arch/Kconfig @@ -13,6 +13,20 @@ config OPROFILE If unsure, say N. +config OPROFILE_IBS + bool "OProfile AMD IBS support (EXPERIMENTAL)" + default n + depends on OPROFILE && SMP && X86 + help + Instruction-Based Sampling (IBS) is a new profiling + technique that provides rich, precise program performance + information. IBS is introduced by AMD Family10h processors + (AMD Opteron Quad-Core processor “Barcelonaâ€) to overcome + the limitations of conventional performance counter + sampling. + + If unsure, say N. + config HAVE_OPROFILE def_bool n @@ -89,3 +103,6 @@ config HAVE_CLK The calls support software clock gating and thus are a key power management tool on many systems. +config HAVE_DYN_ARRAY + def_bool n + diff --git a/arch/alpha/include/asm/statfs.h b/arch/alpha/include/asm/statfs.h index ad15830..de35cd4 100644 --- a/arch/alpha/include/asm/statfs.h +++ b/arch/alpha/include/asm/statfs.h @@ -1,6 +1,10 @@ #ifndef _ALPHA_STATFS_H #define _ALPHA_STATFS_H +/* Alpha is the only 64-bit platform with 32-bit statfs. And doesn't + even seem to implement statfs64 */ +#define __statfs_word __u32 + #include #endif diff --git a/arch/alpha/include/asm/thread_info.h b/arch/alpha/include/asm/thread_info.h index 15fda43..c0d21eb 100644 --- a/arch/alpha/include/asm/thread_info.h +++ b/arch/alpha/include/asm/thread_info.h @@ -55,7 +55,7 @@ register struct thread_info *__current_thread_info __asm__("$8"); #endif /* __ASSEMBLY__ */ -#define PREEMPT_ACTIVE 0x40000000 +#define PREEMPT_ACTIVE 0x10000000 /* * Thread information flags: diff --git a/arch/alpha/kernel/asm-offsets.c b/arch/alpha/kernel/asm-offsets.c index 4b18cd9..6ff8886 100644 --- a/arch/alpha/kernel/asm-offsets.c +++ b/arch/alpha/kernel/asm-offsets.c @@ -19,15 +19,18 @@ void foo(void) BLANK(); DEFINE(TASK_BLOCKED, offsetof(struct task_struct, blocked)); - DEFINE(TASK_UID, offsetof(struct task_struct, uid)); - DEFINE(TASK_EUID, offsetof(struct task_struct, euid)); - DEFINE(TASK_GID, offsetof(struct task_struct, gid)); - DEFINE(TASK_EGID, offsetof(struct task_struct, egid)); + DEFINE(TASK_CRED, offsetof(struct task_struct, cred)); DEFINE(TASK_REAL_PARENT, offsetof(struct task_struct, real_parent)); DEFINE(TASK_GROUP_LEADER, offsetof(struct task_struct, group_leader)); DEFINE(TASK_TGID, offsetof(struct task_struct, tgid)); BLANK(); + DEFINE(CRED_UID, offsetof(struct cred, uid)); + DEFINE(CRED_EUID, offsetof(struct cred, euid)); + DEFINE(CRED_GID, offsetof(struct cred, gid)); + DEFINE(CRED_EGID, offsetof(struct cred, egid)); + BLANK(); + DEFINE(SIZEOF_PT_REGS, sizeof(struct pt_regs)); DEFINE(PT_PTRACED, PT_PTRACED); DEFINE(CLONE_VM, CLONE_VM); diff --git a/arch/alpha/kernel/entry.S b/arch/alpha/kernel/entry.S index 5fc61e2..f77345b 100644 --- a/arch/alpha/kernel/entry.S +++ b/arch/alpha/kernel/entry.S @@ -850,8 +850,9 @@ osf_getpriority: sys_getxuid: .prologue 0 ldq $2, TI_TASK($8) - ldl $0, TASK_UID($2) - ldl $1, TASK_EUID($2) + ldq $3, TASK_CRED($2) + ldl $0, CRED_UID($3) + ldl $1, CRED_EUID($3) stq $1, 80($sp) ret .end sys_getxuid @@ -862,8 +863,9 @@ sys_getxuid: sys_getxgid: .prologue 0 ldq $2, TI_TASK($8) - ldl $0, TASK_GID($2) - ldl $1, TASK_EGID($2) + ldq $3, TASK_CRED($2) + ldl $0, CRED_GID($3) + ldl $1, CRED_EGID($3) stq $1, 80($sp) ret .end sys_getxgid diff --git a/arch/alpha/kernel/osf_sys.c b/arch/alpha/kernel/osf_sys.c index 8509dad..f25f6c4 100644 --- a/arch/alpha/kernel/osf_sys.c +++ b/arch/alpha/kernel/osf_sys.c @@ -165,14 +165,11 @@ osf_getdirentries(unsigned int fd, struct osf_dirent __user *dirent, buf.error = 0; error = vfs_readdir(file, osf_filldir, &buf); - if (error < 0) - goto out_putf; - - error = buf.error; + if (error >= 0) + error = buf.error; if (count != buf.count) error = count - buf.count; - out_putf: fput(file); out: return error; diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig index 70dba16..51b8639 100644 --- a/arch/arm/Kconfig +++ b/arch/arm/Kconfig @@ -178,6 +178,11 @@ config OPROFILE_MPCORE config OPROFILE_ARM11_CORE bool +config OPROFILE_ARMV7 + def_bool y + depends on CPU_V7 && !SMP + bool + endif config VECTORS_BASE @@ -306,6 +311,7 @@ config ARCH_IOP13XX select PLAT_IOP select PCI select ARCH_SUPPORTS_MSI + select VMSPLIT_1G help Support for Intel's IOP13XX (XScale) family of processors. @@ -734,6 +740,29 @@ config SMP If you don't know what to do here, say N. +choice + prompt "Memory split" + default VMSPLIT_3G + help + Select the desired split between kernel and user memory. + + If you are not absolutely sure what you are doing, leave this + option alone! + + config VMSPLIT_3G + bool "3G/1G user/kernel split" + config VMSPLIT_2G + bool "2G/2G user/kernel split" + config VMSPLIT_1G + bool "1G/3G user/kernel split" +endchoice + +config PAGE_OFFSET + hex + default 0x40000000 if VMSPLIT_1G + default 0x80000000 if VMSPLIT_2G + default 0xC0000000 + config NR_CPUS int "Maximum number of CPUs (2-32)" range 2 32 @@ -1005,9 +1034,9 @@ config ATAGS_PROC endmenu -if (ARCH_SA1100 || ARCH_INTEGRATOR || ARCH_OMAP || ARCH_IMX || ARCH_PXA) +menu "CPU Power Management" -menu "CPU Frequency scaling" +if (ARCH_SA1100 || ARCH_INTEGRATOR || ARCH_OMAP || ARCH_IMX || ARCH_PXA) source "drivers/cpufreq/Kconfig" @@ -1047,10 +1076,12 @@ config CPU_FREQ_PXA default y select CPU_FREQ_DEFAULT_GOV_USERSPACE -endmenu - endif +source "drivers/cpuidle/Kconfig" + +endmenu + menu "Floating point emulation" comment "At least one emulation must be selected" @@ -1202,6 +1233,8 @@ source "drivers/power/Kconfig" source "drivers/hwmon/Kconfig" +source "drivers/thermal/Kconfig" + source "drivers/watchdog/Kconfig" source "drivers/ssb/Kconfig" @@ -1222,6 +1255,10 @@ source "drivers/usb/Kconfig" source "drivers/mmc/Kconfig" +source "drivers/memstick/Kconfig" + +source "drivers/accessibility/Kconfig" + source "drivers/leds/Kconfig" source "drivers/rtc/Kconfig" @@ -1230,6 +1267,8 @@ source "drivers/dma/Kconfig" source "drivers/dca/Kconfig" +source "drivers/auxdisplay/Kconfig" + source "drivers/regulator/Kconfig" source "drivers/uio/Kconfig" diff --git a/arch/arm/boot/compressed/head.S b/arch/arm/boot/compressed/head.S index d42f89b..1f1729b 100644 --- a/arch/arm/boot/compressed/head.S +++ b/arch/arm/boot/compressed/head.S @@ -421,6 +421,7 @@ __setup_mmu: sub r3, r4, #16384 @ Page directory size add r1, r1, #1048576 str r1, [r0] mov pc, lr +ENDPROC(__setup_mmu) __armv4_mmu_cache_on: mov r12, lr diff --git a/arch/arm/configs/afeb9260_defconfig b/arch/arm/configs/afeb9260_defconfig new file mode 100644 index 0000000..ce90958 --- /dev/null +++ b/arch/arm/configs/afeb9260_defconfig @@ -0,0 +1,1259 @@ +# +# Automatically generated make config: don't edit +# Linux kernel version: 2.6.27-rc2 +# Tue Aug 12 22:30:16 2008 +# +CONFIG_ARM=y +CONFIG_SYS_SUPPORTS_APM_EMULATION=y +CONFIG_GENERIC_GPIO=y +CONFIG_GENERIC_TIME=y +CONFIG_GENERIC_CLOCKEVENTS=y +CONFIG_MMU=y +# CONFIG_NO_IOPORT is not set +CONFIG_GENERIC_HARDIRQS=y +CONFIG_STACKTRACE_SUPPORT=y +CONFIG_HAVE_LATENCYTOP_SUPPORT=y +CONFIG_LOCKDEP_SUPPORT=y +CONFIG_TRACE_IRQFLAGS_SUPPORT=y +CONFIG_HARDIRQS_SW_RESEND=y +CONFIG_GENERIC_IRQ_PROBE=y +CONFIG_RWSEM_GENERIC_SPINLOCK=y +# CONFIG_ARCH_HAS_ILOG2_U32 is not set +# CONFIG_ARCH_HAS_ILOG2_U64 is not set +CONFIG_GENERIC_HWEIGHT=y +CONFIG_GENERIC_CALIBRATE_DELAY=y +CONFIG_ARCH_SUPPORTS_AOUT=y +CONFIG_ZONE_DMA=y +CONFIG_GENERIC_HARDIRQS_NO__DO_IRQ=y +CONFIG_VECTORS_BASE=0xffff0000 +CONFIG_DEFCONFIG_LIST="/lib/modules/$UNAME_RELEASE/.config" + +# +# General setup +# +CONFIG_EXPERIMENTAL=y +CONFIG_BROKEN_ON_SMP=y +CONFIG_LOCK_KERNEL=y +CONFIG_INIT_ENV_ARG_LIMIT=32 +CONFIG_LOCALVERSION="" +# CONFIG_LOCALVERSION_AUTO is not set +CONFIG_SWAP=y +CONFIG_SYSVIPC=y +CONFIG_SYSVIPC_SYSCTL=y +# CONFIG_POSIX_MQUEUE is not set +# CONFIG_BSD_PROCESS_ACCT is not set +# CONFIG_TASKSTATS is not set +# CONFIG_AUDIT is not set +# CONFIG_IKCONFIG is not set +CONFIG_LOG_BUF_SHIFT=14 +# CONFIG_CGROUPS is not set +# CONFIG_GROUP_SCHED is not set +CONFIG_SYSFS_DEPRECATED=y +CONFIG_SYSFS_DEPRECATED_V2=y +# CONFIG_RELAY is not set +CONFIG_NAMESPACES=y +# CONFIG_UTS_NS is not set +# CONFIG_IPC_NS is not set +# CONFIG_USER_NS is not set +# CONFIG_PID_NS is not set +CONFIG_BLK_DEV_INITRD=y +CONFIG_INITRAMFS_SOURCE="" +CONFIG_CC_OPTIMIZE_FOR_SIZE=y +CONFIG_SYSCTL=y +# CONFIG_EMBEDDED is not set +CONFIG_UID16=y +CONFIG_SYSCTL_SYSCALL=y +CONFIG_SYSCTL_SYSCALL_CHECK=y +CONFIG_KALLSYMS=y +# CONFIG_KALLSYMS_ALL is not set +# CONFIG_KALLSYMS_EXTRA_PASS is not set +CONFIG_HOTPLUG=y +CONFIG_PRINTK=y +CONFIG_BUG=y +CONFIG_ELF_CORE=y +CONFIG_COMPAT_BRK=y +CONFIG_BASE_FULL=y +CONFIG_FUTEX=y +CONFIG_ANON_INODES=y +CONFIG_EPOLL=y +CONFIG_SIGNALFD=y +CONFIG_TIMERFD=y +CONFIG_EVENTFD=y +CONFIG_SHMEM=y +CONFIG_VM_EVENT_COUNTERS=y +CONFIG_SLAB=y +# CONFIG_SLUB is not set +# CONFIG_SLOB is not set +# CONFIG_PROFILING is not set +# CONFIG_MARKERS is not set +CONFIG_HAVE_OPROFILE=y +# CONFIG_KPROBES is not set +# CONFIG_HAVE_EFFICIENT_UNALIGNED_ACCESS is not set +# CONFIG_HAVE_IOREMAP_PROT is not set +CONFIG_HAVE_KPROBES=y +CONFIG_HAVE_KRETPROBES=y +# CONFIG_HAVE_ARCH_TRACEHOOK is not set +# CONFIG_HAVE_DMA_ATTRS is not set +# CONFIG_USE_GENERIC_SMP_HELPERS is not set +CONFIG_HAVE_CLK=y +CONFIG_PROC_PAGE_MONITOR=y +CONFIG_HAVE_GENERIC_DMA_COHERENT=y +CONFIG_SLABINFO=y +CONFIG_RT_MUTEXES=y +# CONFIG_TINY_SHMEM is not set +CONFIG_BASE_SMALL=0 +CONFIG_MODULES=y +# CONFIG_MODULE_FORCE_LOAD is not set +CONFIG_MODULE_UNLOAD=y +# CONFIG_MODULE_FORCE_UNLOAD is not set +# CONFIG_MODVERSIONS is not set +# CONFIG_MODULE_SRCVERSION_ALL is not set +CONFIG_KMOD=y +CONFIG_BLOCK=y +# CONFIG_LBD is not set +# CONFIG_BLK_DEV_IO_TRACE is not set +# CONFIG_LSF is not set +# CONFIG_BLK_DEV_BSG is not set +# CONFIG_BLK_DEV_INTEGRITY is not set + +# +# IO Schedulers +# +CONFIG_IOSCHED_NOOP=y +CONFIG_IOSCHED_AS=y +# CONFIG_IOSCHED_DEADLINE is not set +# CONFIG_IOSCHED_CFQ is not set +CONFIG_DEFAULT_AS=y +# CONFIG_DEFAULT_DEADLINE is not set +# CONFIG_DEFAULT_CFQ is not set +# CONFIG_DEFAULT_NOOP is not set +CONFIG_DEFAULT_IOSCHED="anticipatory" +CONFIG_CLASSIC_RCU=y + +# +# System Type +# +# CONFIG_ARCH_AAEC2000 is not set +# CONFIG_ARCH_INTEGRATOR is not set +# CONFIG_ARCH_REALVIEW is not set +# CONFIG_ARCH_VERSATILE is not set +CONFIG_ARCH_AT91=y +# CONFIG_ARCH_CLPS7500 is not set +# CONFIG_ARCH_CLPS711X is not set +# CONFIG_ARCH_EBSA110 is not set +# CONFIG_ARCH_EP93XX is not set +# CONFIG_ARCH_FOOTBRIDGE is not set +# CONFIG_ARCH_NETX is not set +# CONFIG_ARCH_H720X is not set +# CONFIG_ARCH_IMX is not set +# CONFIG_ARCH_IOP13XX is not set +# CONFIG_ARCH_IOP32X is not set +# CONFIG_ARCH_IOP33X is not set +# CONFIG_ARCH_IXP23XX is not set +# CONFIG_ARCH_IXP2000 is not set +# CONFIG_ARCH_IXP4XX is not set +# CONFIG_ARCH_L7200 is not set +# CONFIG_ARCH_KIRKWOOD is not set +# CONFIG_ARCH_KS8695 is not set +# CONFIG_ARCH_NS9XXX is not set +# CONFIG_ARCH_LOKI is not set +# CONFIG_ARCH_MV78XX0 is not set +# CONFIG_ARCH_MXC is not set +# CONFIG_ARCH_ORION5X is not set +# CONFIG_ARCH_PNX4008 is not set +# CONFIG_ARCH_PXA is not set +# CONFIG_ARCH_RPC is not set +# CONFIG_ARCH_SA1100 is not set +# CONFIG_ARCH_S3C2410 is not set +# CONFIG_ARCH_SHARK is not set +# CONFIG_ARCH_LH7A40X is not set +# CONFIG_ARCH_DAVINCI is not set +# CONFIG_ARCH_OMAP is not set +# CONFIG_ARCH_MSM7X00A is not set + +# +# Boot options +# + +# +# Power management +# + +# +# Atmel AT91 System-on-Chip +# +# CONFIG_ARCH_AT91RM9200 is not set +CONFIG_ARCH_AT91SAM9260=y +# CONFIG_ARCH_AT91SAM9261 is not set +# CONFIG_ARCH_AT91SAM9263 is not set +# CONFIG_ARCH_AT91SAM9RL is not set +# CONFIG_ARCH_AT91SAM9G20 is not set +# CONFIG_ARCH_AT91CAP9 is not set +# CONFIG_ARCH_AT91X40 is not set +CONFIG_AT91_PMC_UNIT=y + +# +# AT91SAM9260 Variants +# +# CONFIG_ARCH_AT91SAM9260_SAM9XE is not set + +# +# AT91SAM9260 / AT91SAM9XE Board Type +# +# CONFIG_MACH_AT91SAM9260EK is not set +# CONFIG_MACH_CAM60 is not set +# CONFIG_MACH_SAM9_L9260 is not set +CONFIG_MACH_AFEB9260=y +# CONFIG_MACH_USB_A9260 is not set +# CONFIG_MACH_QIL_A9260 is not set + +# +# AT91 Board Options +# + +# +# AT91 Feature Selections +# +CONFIG_AT91_PROGRAMMABLE_CLOCKS=y +CONFIG_AT91_TIMER_HZ=100 +CONFIG_AT91_EARLY_DBGU=y +# CONFIG_AT91_EARLY_USART0 is not set +# CONFIG_AT91_EARLY_USART1 is not set +# CONFIG_AT91_EARLY_USART2 is not set +# CONFIG_AT91_EARLY_USART3 is not set +# CONFIG_AT91_EARLY_USART4 is not set +# CONFIG_AT91_EARLY_USART5 is not set + +# +# Processor Type +# +CONFIG_CPU_32=y +CONFIG_CPU_ARM926T=y +CONFIG_CPU_32v5=y +CONFIG_CPU_ABRT_EV5TJ=y +CONFIG_CPU_PABRT_NOIFAR=y +CONFIG_CPU_CACHE_VIVT=y +CONFIG_CPU_COPY_V4WB=y +CONFIG_CPU_TLB_V4WBI=y +CONFIG_CPU_CP15=y +CONFIG_CPU_CP15_MMU=y + +# +# Processor Features +# +CONFIG_ARM_THUMB=y +# CONFIG_CPU_ICACHE_DISABLE is not set +# CONFIG_CPU_DCACHE_DISABLE is not set +# CONFIG_CPU_DCACHE_WRITETHROUGH is not set +# CONFIG_CPU_CACHE_ROUND_ROBIN is not set +# CONFIG_OUTER_CACHE is not set + +# +# Bus support +# +# CONFIG_PCI_SYSCALL is not set +# CONFIG_ARCH_SUPPORTS_MSI is not set +# CONFIG_PCCARD is not set + +# +# Kernel Features +# +# CONFIG_TICK_ONESHOT is not set +# CONFIG_NO_HZ is not set +# CONFIG_HIGH_RES_TIMERS is not set +CONFIG_GENERIC_CLOCKEVENTS_BUILD=y +CONFIG_PREEMPT=y +CONFIG_HZ=100 +CONFIG_AEABI=y +CONFIG_OABI_COMPAT=y +# CONFIG_ARCH_DISCONTIGMEM_ENABLE is not set +CONFIG_SELECT_MEMORY_MODEL=y +CONFIG_FLATMEM_MANUAL=y +# CONFIG_DISCONTIGMEM_MANUAL is not set +# CONFIG_SPARSEMEM_MANUAL is not set +CONFIG_FLATMEM=y +CONFIG_FLAT_NODE_MEM_MAP=y +# CONFIG_SPARSEMEM_STATIC is not set +# CONFIG_SPARSEMEM_VMEMMAP_ENABLE is not set +CONFIG_PAGEFLAGS_EXTENDED=y +CONFIG_SPLIT_PTLOCK_CPUS=4096 +# CONFIG_RESOURCES_64BIT is not set +CONFIG_ZONE_DMA_FLAG=1 +CONFIG_BOUNCE=y +CONFIG_VIRT_TO_BUS=y +# CONFIG_LEDS is not set +CONFIG_ALIGNMENT_TRAP=y + +# +# Boot options +# +CONFIG_ZBOOT_ROM_TEXT=0x0 +CONFIG_ZBOOT_ROM_BSS=0x0 +CONFIG_CMDLINE="mem=64M console=ttyS0,115200 initrd=0x21100000,3145728 root=/dev/ram0 rw" +# CONFIG_XIP_KERNEL is not set +# CONFIG_KEXEC is not set + +# +# Floating point emulation +# + +# +# At least one emulation must be selected +# +CONFIG_FPE_NWFPE=y +# CONFIG_FPE_NWFPE_XP is not set +# CONFIG_FPE_FASTFPE is not set +# CONFIG_VFP is not set + +# +# Userspace binary formats +# +CONFIG_BINFMT_ELF=y +# CONFIG_BINFMT_AOUT is not set +# CONFIG_BINFMT_MISC is not set + +# +# Power management options +# +# CONFIG_PM is not set +CONFIG_ARCH_SUSPEND_POSSIBLE=y +CONFIG_NET=y + +# +# Networking options +# +CONFIG_PACKET=y +# CONFIG_PACKET_MMAP is not set +CONFIG_UNIX=y +# CONFIG_NET_KEY is not set +CONFIG_INET=y +# CONFIG_IP_MULTICAST is not set +# CONFIG_IP_ADVANCED_ROUTER is not set +CONFIG_IP_FIB_HASH=y +CONFIG_IP_PNP=y +# CONFIG_IP_PNP_DHCP is not set +CONFIG_IP_PNP_BOOTP=y +# CONFIG_IP_PNP_RARP is not set +# CONFIG_NET_IPIP is not set +# CONFIG_NET_IPGRE is not set +# CONFIG_ARPD is not set +# CONFIG_SYN_COOKIES is not set +# CONFIG_INET_AH is not set +# CONFIG_INET_ESP is not set +# CONFIG_INET_IPCOMP is not set +# CONFIG_INET_XFRM_TUNNEL is not set +# CONFIG_INET_TUNNEL is not set +# CONFIG_INET_XFRM_MODE_TRANSPORT is not set +# CONFIG_INET_XFRM_MODE_TUNNEL is not set +# CONFIG_INET_XFRM_MODE_BEET is not set +# CONFIG_INET_LRO is not set +CONFIG_INET_DIAG=y +CONFIG_INET_TCP_DIAG=y +# CONFIG_TCP_CONG_ADVANCED is not set +CONFIG_TCP_CONG_CUBIC=y +CONFIG_DEFAULT_TCP_CONG="cubic" +# CONFIG_TCP_MD5SIG is not set +# CONFIG_IPV6 is not set +# CONFIG_NETWORK_SECMARK is not set +# CONFIG_NETFILTER is not set +# CONFIG_IP_DCCP is not set +# CONFIG_IP_SCTP is not set +# CONFIG_TIPC is not set +# CONFIG_ATM is not set +# CONFIG_BRIDGE is not set +# CONFIG_VLAN_8021Q is not set +# CONFIG_DECNET is not set +# CONFIG_LLC2 is not set +# CONFIG_IPX is not set +# CONFIG_ATALK is not set +# CONFIG_X25 is not set +# CONFIG_LAPB is not set +# CONFIG_ECONET is not set +# CONFIG_WAN_ROUTER is not set +# CONFIG_NET_SCHED is not set + +# +# Network testing +# +# CONFIG_NET_PKTGEN is not set +# CONFIG_HAMRADIO is not set +# CONFIG_CAN is not set +# CONFIG_IRDA is not set +# CONFIG_BT is not set +# CONFIG_AF_RXRPC is not set + +# +# Wireless +# +# CONFIG_CFG80211 is not set +# CONFIG_WIRELESS_EXT is not set +# CONFIG_MAC80211 is not set +# CONFIG_IEEE80211 is not set +# CONFIG_RFKILL is not set +# CONFIG_NET_9P is not set + +# +# Device Drivers +# + +# +# Generic Driver Options +# +CONFIG_UEVENT_HELPER_PATH="/sbin/hotplug" +CONFIG_STANDALONE=y +CONFIG_PREVENT_FIRMWARE_BUILD=y +CONFIG_FW_LOADER=y +CONFIG_FIRMWARE_IN_KERNEL=y +CONFIG_EXTRA_FIRMWARE="" +# CONFIG_DEBUG_DRIVER is not set +# CONFIG_DEBUG_DEVRES is not set +# CONFIG_SYS_HYPERVISOR is not set +# CONFIG_CONNECTOR is not set +CONFIG_MTD=y +# CONFIG_MTD_DEBUG is not set +# CONFIG_MTD_CONCAT is not set +CONFIG_MTD_PARTITIONS=y +# CONFIG_MTD_REDBOOT_PARTS is not set +# CONFIG_MTD_CMDLINE_PARTS is not set +# CONFIG_MTD_AFS_PARTS is not set +# CONFIG_MTD_AR7_PARTS is not set + +# +# User Modules And Translation Layers +# +CONFIG_MTD_CHAR=y +CONFIG_MTD_BLKDEVS=y +CONFIG_MTD_BLOCK=y +# CONFIG_FTL is not set +# CONFIG_NFTL is not set +# CONFIG_INFTL is not set +# CONFIG_RFD_FTL is not set +# CONFIG_SSFDC is not set +# CONFIG_MTD_OOPS is not set + +# +# RAM/ROM/Flash chip drivers +# +# CONFIG_MTD_CFI is not set +# CONFIG_MTD_JEDECPROBE is not set +CONFIG_MTD_MAP_BANK_WIDTH_1=y +CONFIG_MTD_MAP_BANK_WIDTH_2=y +CONFIG_MTD_MAP_BANK_WIDTH_4=y +# CONFIG_MTD_MAP_BANK_WIDTH_8 is not set +# CONFIG_MTD_MAP_BANK_WIDTH_16 is not set +# CONFIG_MTD_MAP_BANK_WIDTH_32 is not set +CONFIG_MTD_CFI_I1=y +CONFIG_MTD_CFI_I2=y +# CONFIG_MTD_CFI_I4 is not set +# CONFIG_MTD_CFI_I8 is not set +# CONFIG_MTD_RAM is not set +# CONFIG_MTD_ROM is not set +# CONFIG_MTD_ABSENT is not set + +# +# Mapping drivers for chip access +# +# CONFIG_MTD_COMPLEX_MAPPINGS is not set +# CONFIG_MTD_PLATRAM is not set + +# +# Self-contained MTD device drivers +# +CONFIG_MTD_DATAFLASH=y +# CONFIG_MTD_M25P80 is not set +# CONFIG_MTD_SLRAM is not set +# CONFIG_MTD_PHRAM is not set +# CONFIG_MTD_MTDRAM is not set +# CONFIG_MTD_BLOCK2MTD is not set + +# +# Disk-On-Chip Device Drivers +# +# CONFIG_MTD_DOC2000 is not set +# CONFIG_MTD_DOC2001 is not set +# CONFIG_MTD_DOC2001PLUS is not set +CONFIG_MTD_NAND=y +# CONFIG_MTD_NAND_VERIFY_WRITE is not set +# CONFIG_MTD_NAND_ECC_SMC is not set +# CONFIG_MTD_NAND_MUSEUM_IDS is not set +CONFIG_MTD_NAND_IDS=y +# CONFIG_MTD_NAND_DISKONCHIP is not set +CONFIG_MTD_NAND_ATMEL=y +# CONFIG_MTD_NAND_ATMEL_ECC_HW is not set +CONFIG_MTD_NAND_ATMEL_ECC_SOFT=y +# CONFIG_MTD_NAND_ATMEL_ECC_NONE is not set +# CONFIG_MTD_NAND_NANDSIM is not set +# CONFIG_MTD_NAND_PLATFORM is not set +# CONFIG_MTD_ALAUDA is not set +# CONFIG_MTD_ONENAND is not set + +# +# UBI - Unsorted block images +# +# CONFIG_MTD_UBI is not set +# CONFIG_PARPORT is not set +CONFIG_BLK_DEV=y +# CONFIG_BLK_DEV_COW_COMMON is not set +# CONFIG_BLK_DEV_LOOP is not set +# CONFIG_BLK_DEV_NBD is not set +# CONFIG_BLK_DEV_UB is not set +CONFIG_BLK_DEV_RAM=y +CONFIG_BLK_DEV_RAM_COUNT=16 +CONFIG_BLK_DEV_RAM_SIZE=8192 +# CONFIG_BLK_DEV_XIP is not set +# CONFIG_CDROM_PKTCDVD is not set +# CONFIG_ATA_OVER_ETH is not set +CONFIG_MISC_DEVICES=y +# CONFIG_ATMEL_PWM is not set +# CONFIG_ATMEL_TCLIB is not set +# CONFIG_EEPROM_93CX6 is not set +CONFIG_ATMEL_SSC=y +# CONFIG_ENCLOSURE_SERVICES is not set +CONFIG_HAVE_IDE=y +# CONFIG_IDE is not set + +# +# SCSI device support +# +# CONFIG_RAID_ATTRS is not set +CONFIG_SCSI=y +CONFIG_SCSI_DMA=y +# CONFIG_SCSI_TGT is not set +# CONFIG_SCSI_NETLINK is not set +CONFIG_SCSI_PROC_FS=y + +# +# SCSI support type (disk, tape, CD-ROM) +# +CONFIG_BLK_DEV_SD=y +# CONFIG_CHR_DEV_ST is not set +# CONFIG_CHR_DEV_OSST is not set +# CONFIG_BLK_DEV_SR is not set +# CONFIG_CHR_DEV_SG is not set +# CONFIG_CHR_DEV_SCH is not set + +# +# Some SCSI devices (e.g. CD jukebox) support multiple LUNs +# +CONFIG_SCSI_MULTI_LUN=y +# CONFIG_SCSI_CONSTANTS is not set +# CONFIG_SCSI_LOGGING is not set +# CONFIG_SCSI_SCAN_ASYNC is not set +CONFIG_SCSI_WAIT_SCAN=m + +# +# SCSI Transports +# +# CONFIG_SCSI_SPI_ATTRS is not set +# CONFIG_SCSI_FC_ATTRS is not set +# CONFIG_SCSI_ISCSI_ATTRS is not set +# CONFIG_SCSI_SAS_LIBSAS is not set +# CONFIG_SCSI_SRP_ATTRS is not set +CONFIG_SCSI_LOWLEVEL=y +# CONFIG_ISCSI_TCP is not set +# CONFIG_SCSI_DEBUG is not set +# CONFIG_SCSI_DH is not set +# CONFIG_ATA is not set +# CONFIG_MD is not set +CONFIG_NETDEVICES=y +# CONFIG_DUMMY is not set +# CONFIG_BONDING is not set +# CONFIG_MACVLAN is not set +# CONFIG_EQUALIZER is not set +# CONFIG_TUN is not set +# CONFIG_VETH is not set +CONFIG_PHYLIB=y + +# +# MII PHY device drivers +# +# CONFIG_MARVELL_PHY is not set +# CONFIG_DAVICOM_PHY is not set +# CONFIG_QSEMI_PHY is not set +# CONFIG_LXT_PHY is not set +# CONFIG_CICADA_PHY is not set +# CONFIG_VITESSE_PHY is not set +# CONFIG_SMSC_PHY is not set +# CONFIG_BROADCOM_PHY is not set +# CONFIG_ICPLUS_PHY is not set +# CONFIG_REALTEK_PHY is not set +# CONFIG_FIXED_PHY is not set +# CONFIG_MDIO_BITBANG is not set +CONFIG_NET_ETHERNET=y +CONFIG_MII=y +CONFIG_MACB=y +# CONFIG_AX88796 is not set +# CONFIG_SMC91X is not set +# CONFIG_DM9000 is not set +# CONFIG_ENC28J60 is not set +# CONFIG_IBM_NEW_EMAC_ZMII is not set +# CONFIG_IBM_NEW_EMAC_RGMII is not set +# CONFIG_IBM_NEW_EMAC_TAH is not set +# CONFIG_IBM_NEW_EMAC_EMAC4 is not set +# CONFIG_B44 is not set +# CONFIG_NETDEV_1000 is not set +# CONFIG_NETDEV_10000 is not set + +# +# Wireless LAN +# +# CONFIG_WLAN_PRE80211 is not set +# CONFIG_WLAN_80211 is not set +# CONFIG_IWLWIFI_LEDS is not set + +# +# USB Network Adapters +# +# CONFIG_USB_CATC is not set +# CONFIG_USB_KAWETH is not set +# CONFIG_USB_PEGASUS is not set +# CONFIG_USB_RTL8150 is not set +# CONFIG_USB_USBNET is not set +# CONFIG_WAN is not set +# CONFIG_PPP is not set +# CONFIG_SLIP is not set +# CONFIG_NETCONSOLE is not set +# CONFIG_NETPOLL is not set +# CONFIG_NET_POLL_CONTROLLER is not set +# CONFIG_ISDN is not set + +# +# Input device support +# +CONFIG_INPUT=y +# CONFIG_INPUT_FF_MEMLESS is not set +# CONFIG_INPUT_POLLDEV is not set + +# +# Userland interfaces +# +CONFIG_INPUT_MOUSEDEV=y +# CONFIG_INPUT_MOUSEDEV_PSAUX is not set +CONFIG_INPUT_MOUSEDEV_SCREEN_X=1024 +CONFIG_INPUT_MOUSEDEV_SCREEN_Y=768 +# CONFIG_INPUT_JOYDEV is not set +# CONFIG_INPUT_EVDEV is not set +# CONFIG_INPUT_EVBUG is not set + +# +# Input Device Drivers +# +# CONFIG_INPUT_KEYBOARD is not set +# CONFIG_INPUT_MOUSE is not set +# CONFIG_INPUT_JOYSTICK is not set +# CONFIG_INPUT_TABLET is not set +# CONFIG_INPUT_TOUCHSCREEN is not set +# CONFIG_INPUT_MISC is not set + +# +# Hardware I/O ports +# +# CONFIG_SERIO is not set +# CONFIG_GAMEPORT is not set + +# +# Character devices +# +CONFIG_VT=y +CONFIG_CONSOLE_TRANSLATIONS=y +CONFIG_VT_CONSOLE=y +CONFIG_HW_CONSOLE=y +# CONFIG_VT_HW_CONSOLE_BINDING is not set +CONFIG_DEVKMEM=y +# CONFIG_SERIAL_NONSTANDARD is not set + +# +# Serial drivers +# +# CONFIG_SERIAL_8250 is not set + +# +# Non-8250 serial port support +# +CONFIG_SERIAL_ATMEL=y +CONFIG_SERIAL_ATMEL_CONSOLE=y +CONFIG_SERIAL_ATMEL_PDC=y +# CONFIG_SERIAL_ATMEL_TTYAT is not set +CONFIG_SERIAL_CORE=y +CONFIG_SERIAL_CORE_CONSOLE=y +CONFIG_UNIX98_PTYS=y +CONFIG_LEGACY_PTYS=y +CONFIG_LEGACY_PTY_COUNT=256 +# CONFIG_IPMI_HANDLER is not set +# CONFIG_HW_RANDOM is not set +# CONFIG_NVRAM is not set +# CONFIG_R3964 is not set +# CONFIG_RAW_DRIVER is not set +# CONFIG_TCG_TPM is not set +CONFIG_I2C=y +CONFIG_I2C_BOARDINFO=y +CONFIG_I2C_CHARDEV=y +CONFIG_I2C_HELPER_AUTO=y +CONFIG_I2C_ALGOBIT=y + +# +# I2C Hardware Bus support +# + +# +# I2C system bus drivers (mostly embedded / system-on-chip) +# +CONFIG_I2C_GPIO=y +# CONFIG_I2C_OCORES is not set +# CONFIG_I2C_SIMTEC is not set + +# +# External I2C/SMBus adapter drivers +# +# CONFIG_I2C_PARPORT_LIGHT is not set +# CONFIG_I2C_TAOS_EVM is not set +# CONFIG_I2C_TINY_USB is not set + +# +# Other I2C/SMBus bus drivers +# +# CONFIG_I2C_PCA_PLATFORM is not set +# CONFIG_I2C_STUB is not set + +# +# Miscellaneous I2C Chip support +# +# CONFIG_DS1682 is not set +CONFIG_AT24=y +# CONFIG_SENSORS_EEPROM is not set +# CONFIG_SENSORS_PCF8574 is not set +# CONFIG_PCF8575 is not set +# CONFIG_SENSORS_PCA9539 is not set +# CONFIG_SENSORS_PCF8591 is not set +# CONFIG_SENSORS_MAX6875 is not set +# CONFIG_SENSORS_TSL2550 is not set +# CONFIG_I2C_DEBUG_CORE is not set +# CONFIG_I2C_DEBUG_ALGO is not set +# CONFIG_I2C_DEBUG_BUS is not set +# CONFIG_I2C_DEBUG_CHIP is not set +CONFIG_SPI=y +CONFIG_SPI_DEBUG=y +CONFIG_SPI_MASTER=y + +# +# SPI Master Controller Drivers +# +CONFIG_SPI_ATMEL=y +# CONFIG_SPI_BITBANG is not set + +# +# SPI Protocol Masters +# +# CONFIG_SPI_AT25 is not set +CONFIG_SPI_SPIDEV=y +# CONFIG_SPI_TLE62X0 is not set +# CONFIG_W1 is not set +# CONFIG_POWER_SUPPLY is not set +# CONFIG_HWMON is not set +CONFIG_WATCHDOG=y +CONFIG_WATCHDOG_NOWAYOUT=y + +# +# Watchdog Device Drivers +# +# CONFIG_SOFT_WATCHDOG is not set + +# +# USB-based Watchdog Cards +# +# CONFIG_USBPCWATCHDOG is not set + +# +# Sonics Silicon Backplane +# +CONFIG_SSB_POSSIBLE=y +# CONFIG_SSB is not set + +# +# Multifunction device drivers +# +# CONFIG_MFD_CORE is not set +# CONFIG_MFD_SM501 is not set +# CONFIG_HTC_PASIC3 is not set +# CONFIG_MFD_TMIO is not set +# CONFIG_MFD_T7L66XB is not set +# CONFIG_MFD_TC6387XB is not set + +# +# Multimedia devices +# + +# +# Multimedia core support +# +# CONFIG_VIDEO_DEV is not set +# CONFIG_DVB_CORE is not set +# CONFIG_VIDEO_MEDIA is not set + +# +# Multimedia drivers +# +# CONFIG_DAB is not set + +# +# Graphics support +# +# CONFIG_VGASTATE is not set +# CONFIG_VIDEO_OUTPUT_CONTROL is not set +# CONFIG_FB is not set +# CONFIG_BACKLIGHT_LCD_SUPPORT is not set + +# +# Display device support +# +# CONFIG_DISPLAY_SUPPORT is not set + +# +# Console display driver support +# +# CONFIG_VGA_CONSOLE is not set +CONFIG_DUMMY_CONSOLE=y +# CONFIG_SOUND is not set +CONFIG_HID_SUPPORT=y +CONFIG_HID=y +# CONFIG_HID_DEBUG is not set +# CONFIG_HIDRAW is not set + +# +# USB Input Devices +# +# CONFIG_USB_HID is not set + +# +# USB HID Boot Protocol drivers +# +# CONFIG_USB_KBD is not set +# CONFIG_USB_MOUSE is not set +CONFIG_USB_SUPPORT=y +CONFIG_USB_ARCH_HAS_HCD=y +CONFIG_USB_ARCH_HAS_OHCI=y +# CONFIG_USB_ARCH_HAS_EHCI is not set +CONFIG_USB=y +# CONFIG_USB_DEBUG is not set +# CONFIG_USB_ANNOUNCE_NEW_DEVICES is not set + +# +# Miscellaneous USB options +# +CONFIG_USB_DEVICEFS=y +CONFIG_USB_DEVICE_CLASS=y +# CONFIG_USB_DYNAMIC_MINORS is not set +# CONFIG_USB_OTG is not set + +# +# USB Host Controller Drivers +# +# CONFIG_USB_C67X00_HCD is not set +# CONFIG_USB_ISP116X_HCD is not set +# CONFIG_USB_ISP1760_HCD is not set +CONFIG_USB_OHCI_HCD=y +# CONFIG_USB_OHCI_BIG_ENDIAN_DESC is not set +# CONFIG_USB_OHCI_BIG_ENDIAN_MMIO is not set +CONFIG_USB_OHCI_LITTLE_ENDIAN=y +# CONFIG_USB_SL811_HCD is not set +# CONFIG_USB_R8A66597_HCD is not set + +# +# USB Device Class drivers +# +# CONFIG_USB_ACM is not set +# CONFIG_USB_PRINTER is not set +# CONFIG_USB_WDM is not set + +# +# NOTE: USB_STORAGE enables SCSI, and 'SCSI disk support' +# + +# +# may also be needed; see USB_STORAGE Help for more information +# +CONFIG_USB_STORAGE=y +# CONFIG_USB_STORAGE_DEBUG is not set +# CONFIG_USB_STORAGE_DATAFAB is not set +# CONFIG_USB_STORAGE_FREECOM is not set +# CONFIG_USB_STORAGE_ISD200 is not set +# CONFIG_USB_STORAGE_DPCM is not set +# CONFIG_USB_STORAGE_USBAT is not set +# CONFIG_USB_STORAGE_SDDR09 is not set +# CONFIG_USB_STORAGE_SDDR55 is not set +# CONFIG_USB_STORAGE_JUMPSHOT is not set +# CONFIG_USB_STORAGE_ALAUDA is not set +# CONFIG_USB_STORAGE_ONETOUCH is not set +# CONFIG_USB_STORAGE_KARMA is not set +# CONFIG_USB_STORAGE_CYPRESS_ATACB is not set +# CONFIG_USB_LIBUSUAL is not set + +# +# USB Imaging devices +# +# CONFIG_USB_MDC800 is not set +# CONFIG_USB_MICROTEK is not set +CONFIG_USB_MON=y + +# +# USB port drivers +# +# CONFIG_USB_SERIAL is not set + +# +# USB Miscellaneous drivers +# +# CONFIG_USB_EMI62 is not set +# CONFIG_USB_EMI26 is not set +# CONFIG_USB_ADUTUX is not set +# CONFIG_USB_AUERSWALD is not set +# CONFIG_USB_RIO500 is not set +# CONFIG_USB_LEGOTOWER is not set +# CONFIG_USB_LCD is not set +# CONFIG_USB_BERRY_CHARGE is not set +# CONFIG_USB_LED is not set +# CONFIG_USB_CYPRESS_CY7C63 is not set +# CONFIG_USB_CYTHERM is not set +# CONFIG_USB_PHIDGET is not set +# CONFIG_USB_IDMOUSE is not set +# CONFIG_USB_FTDI_ELAN is not set +# CONFIG_USB_APPLEDISPLAY is not set +# CONFIG_USB_LD is not set +# CONFIG_USB_TRANCEVIBRATOR is not set +# CONFIG_USB_IOWARRIOR is not set +# CONFIG_USB_TEST is not set +# CONFIG_USB_ISIGHTFW is not set +CONFIG_USB_GADGET=y +# CONFIG_USB_GADGET_DEBUG is not set +# CONFIG_USB_GADGET_DEBUG_FILES is not set +CONFIG_USB_GADGET_SELECTED=y +# CONFIG_USB_GADGET_AMD5536UDC is not set +# CONFIG_USB_GADGET_ATMEL_USBA is not set +# CONFIG_USB_GADGET_FSL_USB2 is not set +# CONFIG_USB_GADGET_NET2280 is not set +# CONFIG_USB_GADGET_PXA25X is not set +# CONFIG_USB_GADGET_M66592 is not set +# CONFIG_USB_GADGET_PXA27X is not set +# CONFIG_USB_GADGET_GOKU is not set +# CONFIG_USB_GADGET_LH7A40X is not set +# CONFIG_USB_GADGET_OMAP is not set +# CONFIG_USB_GADGET_S3C2410 is not set +CONFIG_USB_GADGET_AT91=y +CONFIG_USB_AT91=y +# CONFIG_USB_GADGET_DUMMY_HCD is not set +# CONFIG_USB_GADGET_DUALSPEED is not set +CONFIG_USB_ZERO=m +# CONFIG_USB_ETH is not set +CONFIG_USB_GADGETFS=m +CONFIG_USB_FILE_STORAGE=m +# CONFIG_USB_FILE_STORAGE_TEST is not set +CONFIG_USB_G_SERIAL=m +# CONFIG_USB_MIDI_GADGET is not set +# CONFIG_USB_G_PRINTER is not set +# CONFIG_USB_CDC_COMPOSITE is not set +# CONFIG_MMC is not set +# CONFIG_NEW_LEDS is not set +CONFIG_RTC_LIB=y +CONFIG_RTC_CLASS=y +CONFIG_RTC_HCTOSYS=y +CONFIG_RTC_HCTOSYS_DEVICE="rtc0" +CONFIG_RTC_DEBUG=y + +# +# RTC interfaces +# +CONFIG_RTC_INTF_SYSFS=y +CONFIG_RTC_INTF_PROC=y +CONFIG_RTC_INTF_DEV=y +# CONFIG_RTC_INTF_DEV_UIE_EMUL is not set +# CONFIG_RTC_DRV_TEST is not set + +# +# I2C RTC drivers +# +# CONFIG_RTC_DRV_DS1307 is not set +# CONFIG_RTC_DRV_DS1374 is not set +# CONFIG_RTC_DRV_DS1672 is not set +# CONFIG_RTC_DRV_MAX6900 is not set +# CONFIG_RTC_DRV_RS5C372 is not set +# CONFIG_RTC_DRV_ISL1208 is not set +# CONFIG_RTC_DRV_X1205 is not set +# CONFIG_RTC_DRV_PCF8563 is not set +# CONFIG_RTC_DRV_PCF8583 is not set +# CONFIG_RTC_DRV_M41T80 is not set +# CONFIG_RTC_DRV_S35390A is not set +CONFIG_RTC_DRV_FM3130=y + +# +# SPI RTC drivers +# +# CONFIG_RTC_DRV_M41T94 is not set +# CONFIG_RTC_DRV_DS1305 is not set +# CONFIG_RTC_DRV_MAX6902 is not set +# CONFIG_RTC_DRV_R9701 is not set +# CONFIG_RTC_DRV_RS5C348 is not set + +# +# Platform RTC drivers +# +# CONFIG_RTC_DRV_CMOS is not set +# CONFIG_RTC_DRV_DS1511 is not set +# CONFIG_RTC_DRV_DS1553 is not set +# CONFIG_RTC_DRV_DS1742 is not set +# CONFIG_RTC_DRV_STK17TA8 is not set +# CONFIG_RTC_DRV_M48T86 is not set +# CONFIG_RTC_DRV_M48T59 is not set +# CONFIG_RTC_DRV_V3020 is not set + +# +# on-CPU RTC drivers +# +# CONFIG_RTC_DRV_AT91SAM9 is not set +# CONFIG_DMADEVICES is not set + +# +# Voltage and Current regulators +# +# CONFIG_REGULATOR is not set +# CONFIG_REGULATOR_FIXED_VOLTAGE is not set +# CONFIG_REGULATOR_VIRTUAL_CONSUMER is not set +# CONFIG_REGULATOR_BQ24022 is not set +# CONFIG_UIO is not set + +# +# File systems +# +CONFIG_EXT2_FS=y +# CONFIG_EXT2_FS_XATTR is not set +# CONFIG_EXT2_FS_XIP is not set +CONFIG_EXT3_FS=y +CONFIG_EXT3_FS_XATTR=y +# CONFIG_EXT3_FS_POSIX_ACL is not set +# CONFIG_EXT3_FS_SECURITY is not set +# CONFIG_EXT4DEV_FS is not set +CONFIG_JBD=y +CONFIG_FS_MBCACHE=y +# CONFIG_REISERFS_FS is not set +# CONFIG_JFS_FS is not set +# CONFIG_FS_POSIX_ACL is not set +# CONFIG_XFS_FS is not set +# CONFIG_OCFS2_FS is not set +CONFIG_DNOTIFY=y +CONFIG_INOTIFY=y +CONFIG_INOTIFY_USER=y +# CONFIG_QUOTA is not set +# CONFIG_AUTOFS_FS is not set +# CONFIG_AUTOFS4_FS is not set +# CONFIG_FUSE_FS is not set + +# +# CD-ROM/DVD Filesystems +# +# CONFIG_ISO9660_FS is not set +# CONFIG_UDF_FS is not set + +# +# DOS/FAT/NT Filesystems +# +CONFIG_FAT_FS=y +# CONFIG_MSDOS_FS is not set +CONFIG_VFAT_FS=y +CONFIG_FAT_DEFAULT_CODEPAGE=437 +CONFIG_FAT_DEFAULT_IOCHARSET="iso8859-1" +# CONFIG_NTFS_FS is not set + +# +# Pseudo filesystems +# +CONFIG_PROC_FS=y +CONFIG_PROC_SYSCTL=y +CONFIG_SYSFS=y +CONFIG_TMPFS=y +# CONFIG_TMPFS_POSIX_ACL is not set +# CONFIG_HUGETLB_PAGE is not set +# CONFIG_CONFIGFS_FS is not set + +# +# Miscellaneous filesystems +# +# CONFIG_ADFS_FS is not set +# CONFIG_AFFS_FS is not set +# CONFIG_HFS_FS is not set +# CONFIG_HFSPLUS_FS is not set +# CONFIG_BEFS_FS is not set +# CONFIG_BFS_FS is not set +# CONFIG_EFS_FS is not set +CONFIG_JFFS2_FS=y +CONFIG_JFFS2_FS_DEBUG=0 +CONFIG_JFFS2_FS_WRITEBUFFER=y +# CONFIG_JFFS2_FS_WBUF_VERIFY is not set +# CONFIG_JFFS2_SUMMARY is not set +# CONFIG_JFFS2_FS_XATTR is not set +# CONFIG_JFFS2_COMPRESSION_OPTIONS is not set +CONFIG_JFFS2_ZLIB=y +# CONFIG_JFFS2_LZO is not set +CONFIG_JFFS2_RTIME=y +# CONFIG_JFFS2_RUBIN is not set +CONFIG_CRAMFS=y +# CONFIG_VXFS_FS is not set +# CONFIG_MINIX_FS is not set +# CONFIG_OMFS_FS is not set +# CONFIG_HPFS_FS is not set +# CONFIG_QNX4FS_FS is not set +# CONFIG_ROMFS_FS is not set +# CONFIG_SYSV_FS is not set +# CONFIG_UFS_FS is not set +CONFIG_NETWORK_FILESYSTEMS=y +CONFIG_NFS_FS=y +CONFIG_NFS_V3=y +# CONFIG_NFS_V3_ACL is not set +# CONFIG_NFS_V4 is not set +CONFIG_ROOT_NFS=y +# CONFIG_NFSD is not set +CONFIG_LOCKD=y +CONFIG_LOCKD_V4=y +CONFIG_NFS_COMMON=y +CONFIG_SUNRPC=y +# CONFIG_RPCSEC_GSS_KRB5 is not set +# CONFIG_RPCSEC_GSS_SPKM3 is not set +# CONFIG_SMB_FS is not set +# CONFIG_CIFS is not set +# CONFIG_NCP_FS is not set +# CONFIG_CODA_FS is not set +# CONFIG_AFS_FS is not set + +# +# Partition Types +# +# CONFIG_PARTITION_ADVANCED is not set +CONFIG_MSDOS_PARTITION=y +CONFIG_NLS=y +CONFIG_NLS_DEFAULT="iso8859-1" +CONFIG_NLS_CODEPAGE_437=y +# CONFIG_NLS_CODEPAGE_737 is not set +# CONFIG_NLS_CODEPAGE_775 is not set +CONFIG_NLS_CODEPAGE_850=y +# CONFIG_NLS_CODEPAGE_852 is not set +# CONFIG_NLS_CODEPAGE_855 is not set +# CONFIG_NLS_CODEPAGE_857 is not set +# CONFIG_NLS_CODEPAGE_860 is not set +# CONFIG_NLS_CODEPAGE_861 is not set +# CONFIG_NLS_CODEPAGE_862 is not set +# CONFIG_NLS_CODEPAGE_863 is not set +# CONFIG_NLS_CODEPAGE_864 is not set +# CONFIG_NLS_CODEPAGE_865 is not set +# CONFIG_NLS_CODEPAGE_866 is not set +# CONFIG_NLS_CODEPAGE_869 is not set +# CONFIG_NLS_CODEPAGE_936 is not set +# CONFIG_NLS_CODEPAGE_950 is not set +# CONFIG_NLS_CODEPAGE_932 is not set +# CONFIG_NLS_CODEPAGE_949 is not set +# CONFIG_NLS_CODEPAGE_874 is not set +# CONFIG_NLS_ISO8859_8 is not set +# CONFIG_NLS_CODEPAGE_1250 is not set +# CONFIG_NLS_CODEPAGE_1251 is not set +# CONFIG_NLS_ASCII is not set +CONFIG_NLS_ISO8859_1=y +# CONFIG_NLS_ISO8859_2 is not set +# CONFIG_NLS_ISO8859_3 is not set +# CONFIG_NLS_ISO8859_4 is not set +# CONFIG_NLS_ISO8859_5 is not set +# CONFIG_NLS_ISO8859_6 is not set +# CONFIG_NLS_ISO8859_7 is not set +# CONFIG_NLS_ISO8859_9 is not set +# CONFIG_NLS_ISO8859_13 is not set +# CONFIG_NLS_ISO8859_14 is not set +# CONFIG_NLS_ISO8859_15 is not set +# CONFIG_NLS_KOI8_R is not set +# CONFIG_NLS_KOI8_U is not set +# CONFIG_NLS_UTF8 is not set +# CONFIG_DLM is not set + +# +# Kernel hacking +# +# CONFIG_PRINTK_TIME is not set +CONFIG_ENABLE_WARN_DEPRECATED=y +CONFIG_ENABLE_MUST_CHECK=y +CONFIG_FRAME_WARN=1024 +# CONFIG_MAGIC_SYSRQ is not set +# CONFIG_UNUSED_SYMBOLS is not set +# CONFIG_DEBUG_FS is not set +# CONFIG_HEADERS_CHECK is not set +CONFIG_DEBUG_KERNEL=y +# CONFIG_DEBUG_SHIRQ is not set +CONFIG_DETECT_SOFTLOCKUP=y +# CONFIG_BOOTPARAM_SOFTLOCKUP_PANIC is not set +CONFIG_BOOTPARAM_SOFTLOCKUP_PANIC_VALUE=0 +CONFIG_SCHED_DEBUG=y +# CONFIG_SCHEDSTATS is not set +# CONFIG_TIMER_STATS is not set +# CONFIG_DEBUG_OBJECTS is not set +# CONFIG_DEBUG_SLAB is not set +CONFIG_DEBUG_PREEMPT=y +# CONFIG_DEBUG_RT_MUTEXES is not set +# CONFIG_RT_MUTEX_TESTER is not set +# CONFIG_DEBUG_SPINLOCK is not set +# CONFIG_DEBUG_MUTEXES is not set +# CONFIG_DEBUG_LOCK_ALLOC is not set +# CONFIG_PROVE_LOCKING is not set +# CONFIG_LOCK_STAT is not set +# CONFIG_DEBUG_SPINLOCK_SLEEP is not set +# CONFIG_DEBUG_LOCKING_API_SELFTESTS is not set +# CONFIG_DEBUG_KOBJECT is not set +CONFIG_DEBUG_BUGVERBOSE=y +CONFIG_DEBUG_INFO=y +# CONFIG_DEBUG_VM is not set +# CONFIG_DEBUG_WRITECOUNT is not set +CONFIG_DEBUG_MEMORY_INIT=y +# CONFIG_DEBUG_LIST is not set +# CONFIG_DEBUG_SG is not set +CONFIG_FRAME_POINTER=y +# CONFIG_BOOT_PRINTK_DELAY is not set +# CONFIG_RCU_TORTURE_TEST is not set +# CONFIG_BACKTRACE_SELF_TEST is not set +# CONFIG_FAULT_INJECTION is not set +# CONFIG_LATENCYTOP is not set +CONFIG_HAVE_FTRACE=y +CONFIG_HAVE_DYNAMIC_FTRACE=y +# CONFIG_FTRACE is not set +# CONFIG_IRQSOFF_TRACER is not set +# CONFIG_PREEMPT_TRACER is not set +# CONFIG_SCHED_TRACER is not set +# CONFIG_CONTEXT_SWITCH_TRACER is not set +# CONFIG_SAMPLES is not set +CONFIG_HAVE_ARCH_KGDB=y +# CONFIG_KGDB is not set +CONFIG_DEBUG_USER=y +# CONFIG_DEBUG_ERRORS is not set +# CONFIG_DEBUG_STACK_USAGE is not set +CONFIG_DEBUG_LL=y +# CONFIG_DEBUG_ICEDCC is not set + +# +# Security options +# +# CONFIG_KEYS is not set +# CONFIG_SECURITY is not set +# CONFIG_SECURITY_FILE_CAPABILITIES is not set +# CONFIG_CRYPTO is not set + +# +# Library routines +# +CONFIG_BITREVERSE=y +# CONFIG_GENERIC_FIND_FIRST_BIT is not set +# CONFIG_GENERIC_FIND_NEXT_BIT is not set +# CONFIG_CRC_CCITT is not set +# CONFIG_CRC16 is not set +CONFIG_CRC_T10DIF=y +# CONFIG_CRC_ITU_T is not set +CONFIG_CRC32=y +# CONFIG_CRC7 is not set +# CONFIG_LIBCRC32C is not set +CONFIG_ZLIB_INFLATE=y +CONFIG_ZLIB_DEFLATE=y +CONFIG_PLIST=y +CONFIG_HAS_IOMEM=y +CONFIG_HAS_IOPORT=y +CONFIG_HAS_DMA=y diff --git a/arch/arm/configs/cm_x300_defconfig b/arch/arm/configs/cm_x300_defconfig new file mode 100644 index 0000000..46f1c9d --- /dev/null +++ b/arch/arm/configs/cm_x300_defconfig @@ -0,0 +1,1466 @@ +# +# Automatically generated make config: don't edit +# Linux kernel version: 2.6.27-rc3 +# Tue Aug 19 11:26:54 2008 +# +CONFIG_ARM=y +CONFIG_SYS_SUPPORTS_APM_EMULATION=y +CONFIG_GENERIC_GPIO=y +CONFIG_GENERIC_TIME=y +CONFIG_GENERIC_CLOCKEVENTS=y +CONFIG_MMU=y +# CONFIG_NO_IOPORT is not set +CONFIG_GENERIC_HARDIRQS=y +CONFIG_STACKTRACE_SUPPORT=y +CONFIG_HAVE_LATENCYTOP_SUPPORT=y +CONFIG_LOCKDEP_SUPPORT=y +CONFIG_TRACE_IRQFLAGS_SUPPORT=y +CONFIG_HARDIRQS_SW_RESEND=y +CONFIG_GENERIC_IRQ_PROBE=y +CONFIG_RWSEM_GENERIC_SPINLOCK=y +# CONFIG_ARCH_HAS_ILOG2_U32 is not set +# CONFIG_ARCH_HAS_ILOG2_U64 is not set +CONFIG_GENERIC_HWEIGHT=y +CONFIG_GENERIC_CALIBRATE_DELAY=y +CONFIG_ARCH_SUPPORTS_AOUT=y +CONFIG_ZONE_DMA=y +CONFIG_ARCH_MTD_XIP=y +CONFIG_GENERIC_HARDIRQS_NO__DO_IRQ=y +CONFIG_VECTORS_BASE=0xffff0000 +CONFIG_DEFCONFIG_LIST="/lib/modules/$UNAME_RELEASE/.config" + +# +# General setup +# +CONFIG_EXPERIMENTAL=y +CONFIG_BROKEN_ON_SMP=y +CONFIG_INIT_ENV_ARG_LIMIT=32 +CONFIG_LOCALVERSION="-cm-x300" +# CONFIG_LOCALVERSION_AUTO is not set +CONFIG_SWAP=y +CONFIG_SYSVIPC=y +CONFIG_SYSVIPC_SYSCTL=y +# CONFIG_POSIX_MQUEUE is not set +# CONFIG_BSD_PROCESS_ACCT is not set +# CONFIG_TASKSTATS is not set +# CONFIG_AUDIT is not set +CONFIG_IKCONFIG=y +CONFIG_IKCONFIG_PROC=y +CONFIG_LOG_BUF_SHIFT=18 +# CONFIG_CGROUPS is not set +CONFIG_GROUP_SCHED=y +CONFIG_FAIR_GROUP_SCHED=y +# CONFIG_RT_GROUP_SCHED is not set +CONFIG_USER_SCHED=y +# CONFIG_CGROUP_SCHED is not set +CONFIG_SYSFS_DEPRECATED=y +CONFIG_SYSFS_DEPRECATED_V2=y +# CONFIG_RELAY is not set +CONFIG_NAMESPACES=y +# CONFIG_UTS_NS is not set +# CONFIG_IPC_NS is not set +# CONFIG_USER_NS is not set +# CONFIG_PID_NS is not set +CONFIG_BLK_DEV_INITRD=y +CONFIG_INITRAMFS_SOURCE="" +# CONFIG_CC_OPTIMIZE_FOR_SIZE is not set +CONFIG_SYSCTL=y +# CONFIG_EMBEDDED is not set +CONFIG_UID16=y +CONFIG_SYSCTL_SYSCALL=y +CONFIG_KALLSYMS=y +# CONFIG_KALLSYMS_ALL is not set +# CONFIG_KALLSYMS_EXTRA_PASS is not set +CONFIG_HOTPLUG=y +CONFIG_PRINTK=y +CONFIG_BUG=y +CONFIG_ELF_CORE=y +CONFIG_COMPAT_BRK=y +CONFIG_BASE_FULL=y +CONFIG_FUTEX=y +CONFIG_ANON_INODES=y +CONFIG_EPOLL=y +CONFIG_SIGNALFD=y +CONFIG_TIMERFD=y +CONFIG_EVENTFD=y +CONFIG_SHMEM=y +CONFIG_VM_EVENT_COUNTERS=y +CONFIG_SLUB_DEBUG=y +# CONFIG_SLAB is not set +CONFIG_SLUB=y +# CONFIG_SLOB is not set +# CONFIG_PROFILING is not set +# CONFIG_MARKERS is not set +CONFIG_HAVE_OPROFILE=y +# CONFIG_KPROBES is not set +# CONFIG_HAVE_EFFICIENT_UNALIGNED_ACCESS is not set +# CONFIG_HAVE_IOREMAP_PROT is not set +CONFIG_HAVE_KPROBES=y +CONFIG_HAVE_KRETPROBES=y +# CONFIG_HAVE_ARCH_TRACEHOOK is not set +# CONFIG_HAVE_DMA_ATTRS is not set +# CONFIG_USE_GENERIC_SMP_HELPERS is not set +CONFIG_HAVE_CLK=y +CONFIG_PROC_PAGE_MONITOR=y +CONFIG_HAVE_GENERIC_DMA_COHERENT=y +CONFIG_SLABINFO=y +CONFIG_RT_MUTEXES=y +# CONFIG_TINY_SHMEM is not set +CONFIG_BASE_SMALL=0 +CONFIG_MODULES=y +# CONFIG_MODULE_FORCE_LOAD is not set +CONFIG_MODULE_UNLOAD=y +# CONFIG_MODULE_FORCE_UNLOAD is not set +# CONFIG_MODVERSIONS is not set +# CONFIG_MODULE_SRCVERSION_ALL is not set +CONFIG_KMOD=y +CONFIG_BLOCK=y +# CONFIG_LBD is not set +# CONFIG_BLK_DEV_IO_TRACE is not set +# CONFIG_LSF is not set +# CONFIG_BLK_DEV_BSG is not set +# CONFIG_BLK_DEV_INTEGRITY is not set + +# +# IO Schedulers +# +CONFIG_IOSCHED_NOOP=y +CONFIG_IOSCHED_AS=y +CONFIG_IOSCHED_DEADLINE=y +CONFIG_IOSCHED_CFQ=y +# CONFIG_DEFAULT_AS is not set +# CONFIG_DEFAULT_DEADLINE is not set +CONFIG_DEFAULT_CFQ=y +# CONFIG_DEFAULT_NOOP is not set +CONFIG_DEFAULT_IOSCHED="cfq" +CONFIG_CLASSIC_RCU=y + +# +# System Type +# +# CONFIG_ARCH_AAEC2000 is not set +# CONFIG_ARCH_INTEGRATOR is not set +# CONFIG_ARCH_REALVIEW is not set +# CONFIG_ARCH_VERSATILE is not set +# CONFIG_ARCH_AT91 is not set +# CONFIG_ARCH_CLPS7500 is not set +# CONFIG_ARCH_CLPS711X is not set +# CONFIG_ARCH_EBSA110 is not set +# CONFIG_ARCH_EP93XX is not set +# CONFIG_ARCH_FOOTBRIDGE is not set +# CONFIG_ARCH_NETX is not set +# CONFIG_ARCH_H720X is not set +# CONFIG_ARCH_IMX is not set +# CONFIG_ARCH_IOP13XX is not set +# CONFIG_ARCH_IOP32X is not set +# CONFIG_ARCH_IOP33X is not set +# CONFIG_ARCH_IXP23XX is not set +# CONFIG_ARCH_IXP2000 is not set +# CONFIG_ARCH_IXP4XX is not set +# CONFIG_ARCH_L7200 is not set +# CONFIG_ARCH_KIRKWOOD is not set +# CONFIG_ARCH_KS8695 is not set +# CONFIG_ARCH_NS9XXX is not set +# CONFIG_ARCH_LOKI is not set +# CONFIG_ARCH_MV78XX0 is not set +# CONFIG_ARCH_MXC is not set +# CONFIG_ARCH_ORION5X is not set +# CONFIG_ARCH_PNX4008 is not set +CONFIG_ARCH_PXA=y +# CONFIG_ARCH_RPC is not set +# CONFIG_ARCH_SA1100 is not set +# CONFIG_ARCH_S3C2410 is not set +# CONFIG_ARCH_SHARK is not set +# CONFIG_ARCH_LH7A40X is not set +# CONFIG_ARCH_DAVINCI is not set +# CONFIG_ARCH_OMAP is not set +# CONFIG_ARCH_MSM7X00A is not set + +# +# Intel PXA2xx/PXA3xx Implementations +# + +# +# Supported PXA3xx Processor Variants +# +CONFIG_CPU_PXA300=y +# CONFIG_CPU_PXA310 is not set +# CONFIG_CPU_PXA320 is not set +# CONFIG_CPU_PXA930 is not set +# CONFIG_ARCH_GUMSTIX is not set +# CONFIG_ARCH_LUBBOCK is not set +# CONFIG_MACH_LOGICPD_PXA270 is not set +# CONFIG_MACH_MAINSTONE is not set +# CONFIG_ARCH_PXA_IDP is not set +# CONFIG_PXA_SHARPSL is not set +# CONFIG_ARCH_PXA_ESERIES is not set +# CONFIG_MACH_TRIZEPS4 is not set +# CONFIG_MACH_EM_X270 is not set +# CONFIG_MACH_COLIBRI is not set +# CONFIG_MACH_ZYLONITE is not set +# CONFIG_MACH_LITTLETON is not set +# CONFIG_MACH_TAVOREVB is not set +# CONFIG_MACH_SAAR is not set +# CONFIG_MACH_ARMCORE is not set +CONFIG_MACH_CM_X300=y +# CONFIG_MACH_MAGICIAN is not set +# CONFIG_MACH_PCM027 is not set +# CONFIG_ARCH_PXA_PALM is not set +# CONFIG_PXA_EZX is not set +CONFIG_PXA3xx=y +# CONFIG_PXA_PWM is not set + +# +# Boot options +# + +# +# Power management +# + +# +# Processor Type +# +CONFIG_CPU_32=y +CONFIG_CPU_XSC3=y +CONFIG_CPU_32v5=y +CONFIG_CPU_ABRT_EV5T=y +CONFIG_CPU_PABRT_NOIFAR=y +CONFIG_CPU_CACHE_VIVT=y +CONFIG_CPU_TLB_V4WBI=y +CONFIG_CPU_CP15=y +CONFIG_CPU_CP15_MMU=y +CONFIG_IO_36=y + +# +# Processor Features +# +# CONFIG_ARM_THUMB is not set +# CONFIG_CPU_DCACHE_DISABLE is not set +# CONFIG_CPU_BPREDICT_DISABLE is not set +CONFIG_OUTER_CACHE=y +CONFIG_CACHE_XSC3L2=y +CONFIG_IWMMXT=y + +# +# Bus support +# +# CONFIG_PCI_SYSCALL is not set +# CONFIG_ARCH_SUPPORTS_MSI is not set +# CONFIG_PCCARD is not set + +# +# Kernel Features +# +CONFIG_TICK_ONESHOT=y +CONFIG_NO_HZ=y +# CONFIG_HIGH_RES_TIMERS is not set +CONFIG_GENERIC_CLOCKEVENTS_BUILD=y +# CONFIG_PREEMPT is not set +CONFIG_HZ=100 +CONFIG_AEABI=y +CONFIG_OABI_COMPAT=y +# CONFIG_ARCH_DISCONTIGMEM_ENABLE is not set +CONFIG_SELECT_MEMORY_MODEL=y +CONFIG_FLATMEM_MANUAL=y +# CONFIG_DISCONTIGMEM_MANUAL is not set +# CONFIG_SPARSEMEM_MANUAL is not set +CONFIG_FLATMEM=y +CONFIG_FLAT_NODE_MEM_MAP=y +# CONFIG_SPARSEMEM_STATIC is not set +# CONFIG_SPARSEMEM_VMEMMAP_ENABLE is not set +CONFIG_PAGEFLAGS_EXTENDED=y +CONFIG_SPLIT_PTLOCK_CPUS=4096 +# CONFIG_RESOURCES_64BIT is not set +CONFIG_ZONE_DMA_FLAG=1 +CONFIG_BOUNCE=y +CONFIG_VIRT_TO_BUS=y +CONFIG_ALIGNMENT_TRAP=y + +# +# Boot options +# +CONFIG_ZBOOT_ROM_TEXT=0x0 +CONFIG_ZBOOT_ROM_BSS=0x0 +CONFIG_CMDLINE="root=/dev/mtdblock5 rootfstype=jffs2 console=ttyS2,38400" +# CONFIG_XIP_KERNEL is not set +# CONFIG_KEXEC is not set + +# +# CPU Frequency scaling +# +CONFIG_CPU_FREQ=y +CONFIG_CPU_FREQ_TABLE=y +# CONFIG_CPU_FREQ_DEBUG is not set +CONFIG_CPU_FREQ_STAT=y +# CONFIG_CPU_FREQ_STAT_DETAILS is not set +CONFIG_CPU_FREQ_DEFAULT_GOV_PERFORMANCE=y +# CONFIG_CPU_FREQ_DEFAULT_GOV_POWERSAVE is not set +# CONFIG_CPU_FREQ_DEFAULT_GOV_USERSPACE is not set +# CONFIG_CPU_FREQ_DEFAULT_GOV_ONDEMAND is not set +# CONFIG_CPU_FREQ_DEFAULT_GOV_CONSERVATIVE is not set +CONFIG_CPU_FREQ_GOV_PERFORMANCE=y +# CONFIG_CPU_FREQ_GOV_POWERSAVE is not set +CONFIG_CPU_FREQ_GOV_USERSPACE=y +# CONFIG_CPU_FREQ_GOV_ONDEMAND is not set +# CONFIG_CPU_FREQ_GOV_CONSERVATIVE is not set + +# +# Floating point emulation +# + +# +# At least one emulation must be selected +# +CONFIG_FPE_NWFPE=y +# CONFIG_FPE_NWFPE_XP is not set +# CONFIG_FPE_FASTFPE is not set + +# +# Userspace binary formats +# +CONFIG_BINFMT_ELF=y +# CONFIG_BINFMT_AOUT is not set +# CONFIG_BINFMT_MISC is not set + +# +# Power management options +# +CONFIG_PM=y +# CONFIG_PM_DEBUG is not set +CONFIG_PM_SLEEP=y +CONFIG_SUSPEND=y +CONFIG_SUSPEND_FREEZER=y +CONFIG_APM_EMULATION=y +CONFIG_ARCH_SUSPEND_POSSIBLE=y +CONFIG_NET=y + +# +# Networking options +# +CONFIG_PACKET=y +# CONFIG_PACKET_MMAP is not set +CONFIG_UNIX=y +# CONFIG_NET_KEY is not set +CONFIG_INET=y +# CONFIG_IP_MULTICAST is not set +# CONFIG_IP_ADVANCED_ROUTER is not set +CONFIG_IP_FIB_HASH=y +CONFIG_IP_PNP=y +CONFIG_IP_PNP_DHCP=y +CONFIG_IP_PNP_BOOTP=y +CONFIG_IP_PNP_RARP=y +# CONFIG_NET_IPIP is not set +# CONFIG_NET_IPGRE is not set +# CONFIG_ARPD is not set +# CONFIG_SYN_COOKIES is not set +# CONFIG_INET_AH is not set +# CONFIG_INET_ESP is not set +# CONFIG_INET_IPCOMP is not set +# CONFIG_INET_XFRM_TUNNEL is not set +# CONFIG_INET_TUNNEL is not set +# CONFIG_INET_XFRM_MODE_TRANSPORT is not set +# CONFIG_INET_XFRM_MODE_TUNNEL is not set +# CONFIG_INET_XFRM_MODE_BEET is not set +# CONFIG_INET_LRO is not set +# CONFIG_INET_DIAG is not set +# CONFIG_TCP_CONG_ADVANCED is not set +CONFIG_TCP_CONG_CUBIC=y +CONFIG_DEFAULT_TCP_CONG="cubic" +# CONFIG_TCP_MD5SIG is not set +# CONFIG_IPV6 is not set +# CONFIG_NETWORK_SECMARK is not set +# CONFIG_NETFILTER is not set +# CONFIG_IP_DCCP is not set +# CONFIG_IP_SCTP is not set +# CONFIG_TIPC is not set +# CONFIG_ATM is not set +# CONFIG_BRIDGE is not set +# CONFIG_VLAN_8021Q is not set +# CONFIG_DECNET is not set +# CONFIG_LLC2 is not set +# CONFIG_IPX is not set +# CONFIG_ATALK is not set +# CONFIG_X25 is not set +# CONFIG_LAPB is not set +# CONFIG_ECONET is not set +# CONFIG_WAN_ROUTER is not set +# CONFIG_NET_SCHED is not set + +# +# Network testing +# +# CONFIG_NET_PKTGEN is not set +# CONFIG_HAMRADIO is not set +# CONFIG_CAN is not set +# CONFIG_IRDA is not set +CONFIG_BT=m +CONFIG_BT_L2CAP=m +CONFIG_BT_SCO=m +CONFIG_BT_RFCOMM=m +CONFIG_BT_RFCOMM_TTY=y +CONFIG_BT_BNEP=m +CONFIG_BT_BNEP_MC_FILTER=y +CONFIG_BT_BNEP_PROTO_FILTER=y +CONFIG_BT_HIDP=m + +# +# Bluetooth device drivers +# +CONFIG_BT_HCIUSB=m +CONFIG_BT_HCIUSB_SCO=y +# CONFIG_BT_HCIBTSDIO is not set +# CONFIG_BT_HCIUART is not set +# CONFIG_BT_HCIBCM203X is not set +# CONFIG_BT_HCIBPA10X is not set +# CONFIG_BT_HCIBFUSB is not set +# CONFIG_BT_HCIVHCI is not set +# CONFIG_AF_RXRPC is not set + +# +# Wireless +# +# CONFIG_CFG80211 is not set +CONFIG_WIRELESS_EXT=y +CONFIG_WIRELESS_EXT_SYSFS=y +# CONFIG_MAC80211 is not set +CONFIG_IEEE80211=m +# CONFIG_IEEE80211_DEBUG is not set +CONFIG_IEEE80211_CRYPT_WEP=m +CONFIG_IEEE80211_CRYPT_CCMP=m +CONFIG_IEEE80211_CRYPT_TKIP=m +# CONFIG_RFKILL is not set +# CONFIG_NET_9P is not set + +# +# Device Drivers +# + +# +# Generic Driver Options +# +CONFIG_UEVENT_HELPER_PATH="/sbin/hotplug" +CONFIG_STANDALONE=y +CONFIG_PREVENT_FIRMWARE_BUILD=y +CONFIG_FW_LOADER=y +CONFIG_FIRMWARE_IN_KERNEL=y +CONFIG_EXTRA_FIRMWARE="" +# CONFIG_DEBUG_DRIVER is not set +# CONFIG_DEBUG_DEVRES is not set +# CONFIG_SYS_HYPERVISOR is not set +# CONFIG_CONNECTOR is not set +CONFIG_MTD=y +# CONFIG_MTD_DEBUG is not set +# CONFIG_MTD_CONCAT is not set +CONFIG_MTD_PARTITIONS=y +# CONFIG_MTD_REDBOOT_PARTS is not set +# CONFIG_MTD_CMDLINE_PARTS is not set +# CONFIG_MTD_AFS_PARTS is not set +# CONFIG_MTD_AR7_PARTS is not set + +# +# User Modules And Translation Layers +# +CONFIG_MTD_CHAR=y +CONFIG_MTD_BLKDEVS=y +CONFIG_MTD_BLOCK=y +# CONFIG_FTL is not set +# CONFIG_NFTL is not set +# CONFIG_INFTL is not set +# CONFIG_RFD_FTL is not set +# CONFIG_SSFDC is not set +# CONFIG_MTD_OOPS is not set + +# +# RAM/ROM/Flash chip drivers +# +# CONFIG_MTD_CFI is not set +# CONFIG_MTD_JEDECPROBE is not set +CONFIG_MTD_MAP_BANK_WIDTH_1=y +CONFIG_MTD_MAP_BANK_WIDTH_2=y +CONFIG_MTD_MAP_BANK_WIDTH_4=y +# CONFIG_MTD_MAP_BANK_WIDTH_8 is not set +# CONFIG_MTD_MAP_BANK_WIDTH_16 is not set +# CONFIG_MTD_MAP_BANK_WIDTH_32 is not set +CONFIG_MTD_CFI_I1=y +CONFIG_MTD_CFI_I2=y +# CONFIG_MTD_CFI_I4 is not set +# CONFIG_MTD_CFI_I8 is not set +# CONFIG_MTD_RAM is not set +# CONFIG_MTD_ROM is not set +# CONFIG_MTD_ABSENT is not set + +# +# Mapping drivers for chip access +# +# CONFIG_MTD_COMPLEX_MAPPINGS is not set +# CONFIG_MTD_SHARP_SL is not set +# CONFIG_MTD_PLATRAM is not set + +# +# Self-contained MTD device drivers +# +# CONFIG_MTD_SLRAM is not set +# CONFIG_MTD_PHRAM is not set +# CONFIG_MTD_MTDRAM is not set +# CONFIG_MTD_BLOCK2MTD is not set + +# +# Disk-On-Chip Device Drivers +# +# CONFIG_MTD_DOC2000 is not set +# CONFIG_MTD_DOC2001 is not set +# CONFIG_MTD_DOC2001PLUS is not set +CONFIG_MTD_NAND=y +# CONFIG_MTD_NAND_VERIFY_WRITE is not set +# CONFIG_MTD_NAND_ECC_SMC is not set +# CONFIG_MTD_NAND_MUSEUM_IDS is not set +# CONFIG_MTD_NAND_H1900 is not set +CONFIG_MTD_NAND_IDS=y +# CONFIG_MTD_NAND_DISKONCHIP is not set +# CONFIG_MTD_NAND_SHARPSL is not set +CONFIG_MTD_NAND_PXA3xx=y +# CONFIG_MTD_NAND_NANDSIM is not set +# CONFIG_MTD_NAND_PLATFORM is not set +# CONFIG_MTD_ALAUDA is not set +# CONFIG_MTD_ONENAND is not set + +# +# UBI - Unsorted block images +# +# CONFIG_MTD_UBI is not set +# CONFIG_PARPORT is not set +CONFIG_BLK_DEV=y +# CONFIG_BLK_DEV_COW_COMMON is not set +CONFIG_BLK_DEV_LOOP=y +# CONFIG_BLK_DEV_CRYPTOLOOP is not set +# CONFIG_BLK_DEV_NBD is not set +# CONFIG_BLK_DEV_UB is not set +CONFIG_BLK_DEV_RAM=y +CONFIG_BLK_DEV_RAM_COUNT=16 +CONFIG_BLK_DEV_RAM_SIZE=4096 +# CONFIG_BLK_DEV_XIP is not set +# CONFIG_CDROM_PKTCDVD is not set +# CONFIG_ATA_OVER_ETH is not set +# CONFIG_MISC_DEVICES is not set +CONFIG_HAVE_IDE=y +# CONFIG_IDE is not set + +# +# SCSI device support +# +# CONFIG_RAID_ATTRS is not set +CONFIG_SCSI=y +CONFIG_SCSI_DMA=y +# CONFIG_SCSI_TGT is not set +# CONFIG_SCSI_NETLINK is not set +CONFIG_SCSI_PROC_FS=y + +# +# SCSI support type (disk, tape, CD-ROM) +# +CONFIG_BLK_DEV_SD=y +# CONFIG_CHR_DEV_ST is not set +# CONFIG_CHR_DEV_OSST is not set +# CONFIG_BLK_DEV_SR is not set +# CONFIG_CHR_DEV_SG is not set +# CONFIG_CHR_DEV_SCH is not set + +# +# Some SCSI devices (e.g. CD jukebox) support multiple LUNs +# +# CONFIG_SCSI_MULTI_LUN is not set +# CONFIG_SCSI_CONSTANTS is not set +# CONFIG_SCSI_LOGGING is not set +# CONFIG_SCSI_SCAN_ASYNC is not set +CONFIG_SCSI_WAIT_SCAN=m + +# +# SCSI Transports +# +# CONFIG_SCSI_SPI_ATTRS is not set +# CONFIG_SCSI_FC_ATTRS is not set +# CONFIG_SCSI_ISCSI_ATTRS is not set +# CONFIG_SCSI_SAS_LIBSAS is not set +# CONFIG_SCSI_SRP_ATTRS is not set +CONFIG_SCSI_LOWLEVEL=y +# CONFIG_ISCSI_TCP is not set +# CONFIG_SCSI_DEBUG is not set +# CONFIG_SCSI_DH is not set +# CONFIG_ATA is not set +# CONFIG_MD is not set +CONFIG_NETDEVICES=y +# CONFIG_DUMMY is not set +# CONFIG_BONDING is not set +# CONFIG_MACVLAN is not set +# CONFIG_EQUALIZER is not set +# CONFIG_TUN is not set +# CONFIG_VETH is not set +# CONFIG_PHYLIB is not set +CONFIG_NET_ETHERNET=y +CONFIG_MII=y +# CONFIG_AX88796 is not set +# CONFIG_SMC91X is not set +CONFIG_DM9000=y +CONFIG_DM9000_DEBUGLEVEL=0 +CONFIG_DM9000_FORCE_SIMPLE_PHY_POLL=y +# CONFIG_SMC911X is not set +# CONFIG_IBM_NEW_EMAC_ZMII is not set +# CONFIG_IBM_NEW_EMAC_RGMII is not set +# CONFIG_IBM_NEW_EMAC_TAH is not set +# CONFIG_IBM_NEW_EMAC_EMAC4 is not set +# CONFIG_B44 is not set +# CONFIG_NETDEV_1000 is not set +# CONFIG_NETDEV_10000 is not set + +# +# Wireless LAN +# +# CONFIG_WLAN_PRE80211 is not set +CONFIG_WLAN_80211=y +CONFIG_LIBERTAS=m +# CONFIG_LIBERTAS_USB is not set +CONFIG_LIBERTAS_SDIO=m +# CONFIG_LIBERTAS_DEBUG is not set +# CONFIG_USB_ZD1201 is not set +# CONFIG_USB_NET_RNDIS_WLAN is not set +# CONFIG_IWLWIFI_LEDS is not set +# CONFIG_HOSTAP is not set + +# +# USB Network Adapters +# +# CONFIG_USB_CATC is not set +# CONFIG_USB_KAWETH is not set +# CONFIG_USB_PEGASUS is not set +# CONFIG_USB_RTL8150 is not set +# CONFIG_USB_USBNET is not set +# CONFIG_WAN is not set +# CONFIG_PPP is not set +# CONFIG_SLIP is not set +# CONFIG_NETCONSOLE is not set +# CONFIG_NETPOLL is not set +# CONFIG_NET_POLL_CONTROLLER is not set +# CONFIG_ISDN is not set + +# +# Input device support +# +CONFIG_INPUT=y +# CONFIG_INPUT_FF_MEMLESS is not set +# CONFIG_INPUT_POLLDEV is not set + +# +# Userland interfaces +# +CONFIG_INPUT_MOUSEDEV=y +# CONFIG_INPUT_MOUSEDEV_PSAUX is not set +CONFIG_INPUT_MOUSEDEV_SCREEN_X=1024 +CONFIG_INPUT_MOUSEDEV_SCREEN_Y=768 +# CONFIG_INPUT_JOYDEV is not set +CONFIG_INPUT_EVDEV=y +# CONFIG_INPUT_EVBUG is not set + +# +# Input Device Drivers +# +CONFIG_INPUT_KEYBOARD=y +# CONFIG_KEYBOARD_ATKBD is not set +# CONFIG_KEYBOARD_SUNKBD is not set +# CONFIG_KEYBOARD_LKKBD is not set +# CONFIG_KEYBOARD_XTKBD is not set +# CONFIG_KEYBOARD_NEWTON is not set +# CONFIG_KEYBOARD_STOWAWAY is not set +CONFIG_KEYBOARD_PXA27x=m +# CONFIG_KEYBOARD_GPIO is not set +# CONFIG_INPUT_MOUSE is not set +# CONFIG_INPUT_JOYSTICK is not set +# CONFIG_INPUT_TABLET is not set +CONFIG_INPUT_TOUCHSCREEN=y +# CONFIG_TOUCHSCREEN_FUJITSU is not set +# CONFIG_TOUCHSCREEN_GUNZE is not set +# CONFIG_TOUCHSCREEN_ELO is not set +# CONFIG_TOUCHSCREEN_MTOUCH is not set +# CONFIG_TOUCHSCREEN_INEXIO is not set +# CONFIG_TOUCHSCREEN_MK712 is not set +# CONFIG_TOUCHSCREEN_PENMOUNT is not set +# CONFIG_TOUCHSCREEN_TOUCHRIGHT is not set +# CONFIG_TOUCHSCREEN_TOUCHWIN is not set +# CONFIG_TOUCHSCREEN_UCB1400 is not set +# CONFIG_TOUCHSCREEN_USB_COMPOSITE is not set +# CONFIG_TOUCHSCREEN_TOUCHIT213 is not set +# CONFIG_INPUT_MISC is not set + +# +# Hardware I/O ports +# +# CONFIG_SERIO is not set +# CONFIG_GAMEPORT is not set + +# +# Character devices +# +CONFIG_VT=y +CONFIG_CONSOLE_TRANSLATIONS=y +CONFIG_VT_CONSOLE=y +CONFIG_HW_CONSOLE=y +# CONFIG_VT_HW_CONSOLE_BINDING is not set +CONFIG_DEVKMEM=y +# CONFIG_SERIAL_NONSTANDARD is not set + +# +# Serial drivers +# +# CONFIG_SERIAL_8250 is not set + +# +# Non-8250 serial port support +# +CONFIG_SERIAL_PXA=y +CONFIG_SERIAL_PXA_CONSOLE=y +CONFIG_SERIAL_CORE=y +CONFIG_SERIAL_CORE_CONSOLE=y +CONFIG_UNIX98_PTYS=y +# CONFIG_LEGACY_PTYS is not set +# CONFIG_IPMI_HANDLER is not set +# CONFIG_HW_RANDOM is not set +# CONFIG_NVRAM is not set +# CONFIG_R3964 is not set +# CONFIG_RAW_DRIVER is not set +# CONFIG_TCG_TPM is not set +CONFIG_I2C=y +CONFIG_I2C_BOARDINFO=y +# CONFIG_I2C_CHARDEV is not set +CONFIG_I2C_HELPER_AUTO=y + +# +# I2C Hardware Bus support +# + +# +# I2C system bus drivers (mostly embedded / system-on-chip) +# +# CONFIG_I2C_GPIO is not set +# CONFIG_I2C_OCORES is not set +CONFIG_I2C_PXA=y +# CONFIG_I2C_PXA_SLAVE is not set +# CONFIG_I2C_SIMTEC is not set + +# +# External I2C/SMBus adapter drivers +# +# CONFIG_I2C_PARPORT_LIGHT is not set +# CONFIG_I2C_TAOS_EVM is not set +# CONFIG_I2C_TINY_USB is not set + +# +# Other I2C/SMBus bus drivers +# +# CONFIG_I2C_PCA_PLATFORM is not set +# CONFIG_I2C_STUB is not set + +# +# Miscellaneous I2C Chip support +# +# CONFIG_DS1682 is not set +# CONFIG_AT24 is not set +# CONFIG_SENSORS_EEPROM is not set +# CONFIG_SENSORS_PCF8574 is not set +# CONFIG_PCF8575 is not set +# CONFIG_SENSORS_PCF8591 is not set +# CONFIG_TPS65010 is not set +# CONFIG_SENSORS_MAX6875 is not set +# CONFIG_SENSORS_TSL2550 is not set +# CONFIG_I2C_DEBUG_CORE is not set +# CONFIG_I2C_DEBUG_ALGO is not set +# CONFIG_I2C_DEBUG_BUS is not set +# CONFIG_I2C_DEBUG_CHIP is not set +# CONFIG_SPI is not set +CONFIG_ARCH_REQUIRE_GPIOLIB=y +CONFIG_GPIOLIB=y +# CONFIG_DEBUG_GPIO is not set +# CONFIG_GPIO_SYSFS is not set + +# +# I2C GPIO expanders: +# +# CONFIG_GPIO_MAX732X is not set +CONFIG_GPIO_PCA953X=y +# CONFIG_GPIO_PCF857X is not set + +# +# PCI GPIO expanders: +# + +# +# SPI GPIO expanders: +# +# CONFIG_W1 is not set +# CONFIG_POWER_SUPPLY is not set +# CONFIG_HWMON is not set +# CONFIG_WATCHDOG is not set + +# +# Sonics Silicon Backplane +# +CONFIG_SSB_POSSIBLE=y +# CONFIG_SSB is not set + +# +# Multifunction device drivers +# +# CONFIG_MFD_CORE is not set +# CONFIG_MFD_SM501 is not set +# CONFIG_HTC_EGPIO is not set +# CONFIG_HTC_PASIC3 is not set +# CONFIG_MFD_TMIO is not set +# CONFIG_MFD_T7L66XB is not set +# CONFIG_MFD_TC6387XB is not set +# CONFIG_MFD_TC6393XB is not set + +# +# Multimedia devices +# + +# +# Multimedia core support +# +# CONFIG_VIDEO_DEV is not set +# CONFIG_DVB_CORE is not set +# CONFIG_VIDEO_MEDIA is not set + +# +# Multimedia drivers +# +# CONFIG_DAB is not set + +# +# Graphics support +# +# CONFIG_VGASTATE is not set +# CONFIG_VIDEO_OUTPUT_CONTROL is not set +CONFIG_FB=y +# CONFIG_FIRMWARE_EDID is not set +# CONFIG_FB_DDC is not set +CONFIG_FB_CFB_FILLRECT=y +CONFIG_FB_CFB_COPYAREA=y +CONFIG_FB_CFB_IMAGEBLIT=y +# CONFIG_FB_CFB_REV_PIXELS_IN_BYTE is not set +# CONFIG_FB_SYS_FILLRECT is not set +# CONFIG_FB_SYS_COPYAREA is not set +# CONFIG_FB_SYS_IMAGEBLIT is not set +# CONFIG_FB_FOREIGN_ENDIAN is not set +# CONFIG_FB_SYS_FOPS is not set +# CONFIG_FB_SVGALIB is not set +# CONFIG_FB_MACMODES is not set +# CONFIG_FB_BACKLIGHT is not set +# CONFIG_FB_MODE_HELPERS is not set +# CONFIG_FB_TILEBLITTING is not set + +# +# Frame buffer hardware drivers +# +# CONFIG_FB_S1D13XXX is not set +CONFIG_FB_PXA=y +# CONFIG_FB_PXA_SMARTPANEL is not set +# CONFIG_FB_PXA_PARAMETERS is not set +# CONFIG_FB_MBX is not set +# CONFIG_FB_W100 is not set +# CONFIG_FB_AM200EPD is not set +# CONFIG_FB_VIRTUAL is not set +# CONFIG_BACKLIGHT_LCD_SUPPORT is not set + +# +# Display device support +# +# CONFIG_DISPLAY_SUPPORT is not set + +# +# Console display driver support +# +# CONFIG_VGA_CONSOLE is not set +CONFIG_DUMMY_CONSOLE=y +CONFIG_FRAMEBUFFER_CONSOLE=y +CONFIG_FRAMEBUFFER_CONSOLE_DETECT_PRIMARY=y +# CONFIG_FRAMEBUFFER_CONSOLE_ROTATION is not set +CONFIG_FONTS=y +# CONFIG_FONT_8x8 is not set +# CONFIG_FONT_8x16 is not set +CONFIG_FONT_6x11=y +# CONFIG_FONT_7x14 is not set +# CONFIG_FONT_PEARL_8x8 is not set +# CONFIG_FONT_ACORN_8x8 is not set +# CONFIG_FONT_MINI_4x6 is not set +# CONFIG_FONT_SUN8x16 is not set +# CONFIG_FONT_SUN12x22 is not set +# CONFIG_FONT_10x18 is not set +CONFIG_LOGO=y +CONFIG_LOGO_LINUX_MONO=y +CONFIG_LOGO_LINUX_VGA16=y +CONFIG_LOGO_LINUX_CLUT224=y +CONFIG_SOUND=m +CONFIG_SND=m +CONFIG_SND_TIMER=m +CONFIG_SND_PCM=m +# CONFIG_SND_SEQUENCER is not set +# CONFIG_SND_MIXER_OSS is not set +# CONFIG_SND_PCM_OSS is not set +# CONFIG_SND_DYNAMIC_MINORS is not set +CONFIG_SND_SUPPORT_OLD_API=y +CONFIG_SND_VERBOSE_PROCFS=y +# CONFIG_SND_VERBOSE_PRINTK is not set +# CONFIG_SND_DEBUG is not set +CONFIG_SND_DRIVERS=y +# CONFIG_SND_DUMMY is not set +# CONFIG_SND_MTPAV is not set +# CONFIG_SND_SERIAL_U16550 is not set +# CONFIG_SND_MPU401 is not set +CONFIG_SND_ARM=y +# CONFIG_SND_PXA2XX_AC97 is not set +CONFIG_SND_USB=y +# CONFIG_SND_USB_AUDIO is not set +# CONFIG_SND_USB_CAIAQ is not set +CONFIG_SND_SOC=m +CONFIG_SND_PXA2XX_SOC=m +# CONFIG_SOUND_PRIME is not set +CONFIG_HID_SUPPORT=y +CONFIG_HID=y +CONFIG_HID_DEBUG=y +# CONFIG_HIDRAW is not set + +# +# USB Input Devices +# +CONFIG_USB_HID=y +# CONFIG_USB_HIDINPUT_POWERBOOK is not set +# CONFIG_HID_FF is not set +# CONFIG_USB_HIDDEV is not set +CONFIG_USB_SUPPORT=y +CONFIG_USB_ARCH_HAS_HCD=y +CONFIG_USB_ARCH_HAS_OHCI=y +# CONFIG_USB_ARCH_HAS_EHCI is not set +CONFIG_USB=y +# CONFIG_USB_DEBUG is not set +# CONFIG_USB_ANNOUNCE_NEW_DEVICES is not set + +# +# Miscellaneous USB options +# +CONFIG_USB_DEVICEFS=y +# CONFIG_USB_DEVICE_CLASS is not set +# CONFIG_USB_DYNAMIC_MINORS is not set +# CONFIG_USB_SUSPEND is not set +# CONFIG_USB_OTG is not set +CONFIG_USB_MON=y + +# +# USB Host Controller Drivers +# +# CONFIG_USB_C67X00_HCD is not set +# CONFIG_USB_ISP116X_HCD is not set +# CONFIG_USB_ISP1760_HCD is not set +CONFIG_USB_OHCI_HCD=y +# CONFIG_USB_OHCI_BIG_ENDIAN_DESC is not set +# CONFIG_USB_OHCI_BIG_ENDIAN_MMIO is not set +CONFIG_USB_OHCI_LITTLE_ENDIAN=y +# CONFIG_USB_SL811_HCD is not set +# CONFIG_USB_R8A66597_HCD is not set +# CONFIG_USB_MUSB_HDRC is not set + +# +# USB Device Class drivers +# +# CONFIG_USB_ACM is not set +# CONFIG_USB_PRINTER is not set +# CONFIG_USB_WDM is not set + +# +# NOTE: USB_STORAGE enables SCSI, and 'SCSI disk support' +# + +# +# may also be needed; see USB_STORAGE Help for more information +# +CONFIG_USB_STORAGE=y +# CONFIG_USB_STORAGE_DEBUG is not set +# CONFIG_USB_STORAGE_DATAFAB is not set +# CONFIG_USB_STORAGE_FREECOM is not set +# CONFIG_USB_STORAGE_ISD200 is not set +# CONFIG_USB_STORAGE_DPCM is not set +# CONFIG_USB_STORAGE_USBAT is not set +# CONFIG_USB_STORAGE_SDDR09 is not set +# CONFIG_USB_STORAGE_SDDR55 is not set +# CONFIG_USB_STORAGE_JUMPSHOT is not set +# CONFIG_USB_STORAGE_ALAUDA is not set +# CONFIG_USB_STORAGE_ONETOUCH is not set +# CONFIG_USB_STORAGE_KARMA is not set +# CONFIG_USB_STORAGE_SIERRA is not set +# CONFIG_USB_STORAGE_CYPRESS_ATACB is not set +# CONFIG_USB_LIBUSUAL is not set + +# +# USB Imaging devices +# +# CONFIG_USB_MDC800 is not set +# CONFIG_USB_MICROTEK is not set + +# +# USB port drivers +# +# CONFIG_USB_SERIAL is not set + +# +# USB Miscellaneous drivers +# +# CONFIG_USB_EMI62 is not set +# CONFIG_USB_EMI26 is not set +# CONFIG_USB_ADUTUX is not set +# CONFIG_USB_RIO500 is not set +# CONFIG_USB_LEGOTOWER is not set +# CONFIG_USB_LCD is not set +# CONFIG_USB_BERRY_CHARGE is not set +# CONFIG_USB_LED is not set +# CONFIG_USB_CYPRESS_CY7C63 is not set +# CONFIG_USB_CYTHERM is not set +# CONFIG_USB_PHIDGET is not set +# CONFIG_USB_IDMOUSE is not set +# CONFIG_USB_FTDI_ELAN is not set +# CONFIG_USB_APPLEDISPLAY is not set +# CONFIG_USB_LD is not set +# CONFIG_USB_TRANCEVIBRATOR is not set +# CONFIG_USB_IOWARRIOR is not set +# CONFIG_USB_TEST is not set +# CONFIG_USB_ISIGHTFW is not set +# CONFIG_USB_GADGET is not set +CONFIG_MMC=m +# CONFIG_MMC_DEBUG is not set +# CONFIG_MMC_UNSAFE_RESUME is not set + +# +# MMC/SD Card Drivers +# +CONFIG_MMC_BLOCK=m +CONFIG_MMC_BLOCK_BOUNCE=y +# CONFIG_SDIO_UART is not set +# CONFIG_MMC_TEST is not set + +# +# MMC/SD Host Controller Drivers +# +CONFIG_MMC_PXA=m +# CONFIG_MMC_SDHCI is not set +CONFIG_NEW_LEDS=y +CONFIG_LEDS_CLASS=y + +# +# LED drivers +# +# CONFIG_LEDS_PCA9532 is not set +CONFIG_LEDS_GPIO=y +# CONFIG_LEDS_PCA955X is not set + +# +# LED Triggers +# +CONFIG_LEDS_TRIGGERS=y +# CONFIG_LEDS_TRIGGER_TIMER is not set +CONFIG_LEDS_TRIGGER_HEARTBEAT=y +# CONFIG_LEDS_TRIGGER_DEFAULT_ON is not set +CONFIG_RTC_LIB=y +CONFIG_RTC_CLASS=y +CONFIG_RTC_HCTOSYS=y +CONFIG_RTC_HCTOSYS_DEVICE="rtc0" +# CONFIG_RTC_DEBUG is not set + +# +# RTC interfaces +# +CONFIG_RTC_INTF_SYSFS=y +CONFIG_RTC_INTF_PROC=y +CONFIG_RTC_INTF_DEV=y +# CONFIG_RTC_INTF_DEV_UIE_EMUL is not set +# CONFIG_RTC_DRV_TEST is not set + +# +# I2C RTC drivers +# +# CONFIG_RTC_DRV_DS1307 is not set +# CONFIG_RTC_DRV_DS1374 is not set +# CONFIG_RTC_DRV_DS1672 is not set +# CONFIG_RTC_DRV_MAX6900 is not set +# CONFIG_RTC_DRV_RS5C372 is not set +# CONFIG_RTC_DRV_ISL1208 is not set +# CONFIG_RTC_DRV_X1205 is not set +# CONFIG_RTC_DRV_PCF8563 is not set +# CONFIG_RTC_DRV_PCF8583 is not set +# CONFIG_RTC_DRV_M41T80 is not set +# CONFIG_RTC_DRV_S35390A is not set +# CONFIG_RTC_DRV_FM3130 is not set + +# +# SPI RTC drivers +# + +# +# Platform RTC drivers +# +# CONFIG_RTC_DRV_CMOS is not set +# CONFIG_RTC_DRV_DS1511 is not set +# CONFIG_RTC_DRV_DS1553 is not set +# CONFIG_RTC_DRV_DS1742 is not set +# CONFIG_RTC_DRV_STK17TA8 is not set +# CONFIG_RTC_DRV_M48T86 is not set +# CONFIG_RTC_DRV_M48T59 is not set +# CONFIG_RTC_DRV_V3020 is not set + +# +# on-CPU RTC drivers +# +CONFIG_RTC_DRV_SA1100=y +# CONFIG_DMADEVICES is not set + +# +# Voltage and Current regulators +# +# CONFIG_REGULATOR is not set +# CONFIG_REGULATOR_FIXED_VOLTAGE is not set +# CONFIG_REGULATOR_VIRTUAL_CONSUMER is not set +# CONFIG_REGULATOR_BQ24022 is not set +# CONFIG_UIO is not set + +# +# File systems +# +CONFIG_EXT2_FS=y +# CONFIG_EXT2_FS_XATTR is not set +# CONFIG_EXT2_FS_XIP is not set +CONFIG_EXT3_FS=y +# CONFIG_EXT3_FS_XATTR is not set +# CONFIG_EXT4DEV_FS is not set +CONFIG_JBD=y +# CONFIG_JBD_DEBUG is not set +# CONFIG_REISERFS_FS is not set +# CONFIG_JFS_FS is not set +CONFIG_FS_POSIX_ACL=y +# CONFIG_XFS_FS is not set +# CONFIG_OCFS2_FS is not set +CONFIG_DNOTIFY=y +CONFIG_INOTIFY=y +CONFIG_INOTIFY_USER=y +# CONFIG_QUOTA is not set +# CONFIG_AUTOFS_FS is not set +# CONFIG_AUTOFS4_FS is not set +# CONFIG_FUSE_FS is not set + +# +# CD-ROM/DVD Filesystems +# +# CONFIG_ISO9660_FS is not set +# CONFIG_UDF_FS is not set + +# +# DOS/FAT/NT Filesystems +# +CONFIG_FAT_FS=m +CONFIG_MSDOS_FS=m +CONFIG_VFAT_FS=m +CONFIG_FAT_DEFAULT_CODEPAGE=437 +CONFIG_FAT_DEFAULT_IOCHARSET="iso8859-1" +# CONFIG_NTFS_FS is not set + +# +# Pseudo filesystems +# +CONFIG_PROC_FS=y +CONFIG_PROC_SYSCTL=y +CONFIG_SYSFS=y +CONFIG_TMPFS=y +# CONFIG_TMPFS_POSIX_ACL is not set +# CONFIG_HUGETLB_PAGE is not set +# CONFIG_CONFIGFS_FS is not set + +# +# Miscellaneous filesystems +# +# CONFIG_ADFS_FS is not set +# CONFIG_AFFS_FS is not set +# CONFIG_HFS_FS is not set +# CONFIG_HFSPLUS_FS is not set +# CONFIG_BEFS_FS is not set +# CONFIG_BFS_FS is not set +# CONFIG_EFS_FS is not set +CONFIG_JFFS2_FS=y +CONFIG_JFFS2_FS_DEBUG=0 +CONFIG_JFFS2_FS_WRITEBUFFER=y +# CONFIG_JFFS2_FS_WBUF_VERIFY is not set +CONFIG_JFFS2_SUMMARY=y +# CONFIG_JFFS2_FS_XATTR is not set +# CONFIG_JFFS2_COMPRESSION_OPTIONS is not set +CONFIG_JFFS2_ZLIB=y +# CONFIG_JFFS2_LZO is not set +CONFIG_JFFS2_RTIME=y +# CONFIG_JFFS2_RUBIN is not set +# CONFIG_CRAMFS is not set +# CONFIG_VXFS_FS is not set +# CONFIG_MINIX_FS is not set +# CONFIG_OMFS_FS is not set +# CONFIG_HPFS_FS is not set +# CONFIG_QNX4FS_FS is not set +# CONFIG_ROMFS_FS is not set +# CONFIG_SYSV_FS is not set +# CONFIG_UFS_FS is not set +CONFIG_NETWORK_FILESYSTEMS=y +CONFIG_NFS_FS=y +CONFIG_NFS_V3=y +CONFIG_NFS_V3_ACL=y +CONFIG_NFS_V4=y +CONFIG_ROOT_NFS=y +# CONFIG_NFSD is not set +CONFIG_LOCKD=y +CONFIG_LOCKD_V4=y +CONFIG_NFS_ACL_SUPPORT=y +CONFIG_NFS_COMMON=y +CONFIG_SUNRPC=y +CONFIG_SUNRPC_GSS=y +CONFIG_RPCSEC_GSS_KRB5=y +# CONFIG_RPCSEC_GSS_SPKM3 is not set +CONFIG_SMB_FS=m +# CONFIG_SMB_NLS_DEFAULT is not set +CONFIG_CIFS=m +# CONFIG_CIFS_STATS is not set +CONFIG_CIFS_WEAK_PW_HASH=y +# CONFIG_CIFS_XATTR is not set +# CONFIG_CIFS_DEBUG2 is not set +# CONFIG_CIFS_EXPERIMENTAL is not set +# CONFIG_NCP_FS is not set +# CONFIG_CODA_FS is not set +# CONFIG_AFS_FS is not set + +# +# Partition Types +# +CONFIG_PARTITION_ADVANCED=y +# CONFIG_ACORN_PARTITION is not set +# CONFIG_OSF_PARTITION is not set +# CONFIG_AMIGA_PARTITION is not set +# CONFIG_ATARI_PARTITION is not set +# CONFIG_MAC_PARTITION is not set +CONFIG_MSDOS_PARTITION=y +# CONFIG_BSD_DISKLABEL is not set +# CONFIG_MINIX_SUBPARTITION is not set +# CONFIG_SOLARIS_X86_PARTITION is not set +# CONFIG_UNIXWARE_DISKLABEL is not set +# CONFIG_LDM_PARTITION is not set +# CONFIG_SGI_PARTITION is not set +# CONFIG_ULTRIX_PARTITION is not set +# CONFIG_SUN_PARTITION is not set +# CONFIG_KARMA_PARTITION is not set +# CONFIG_EFI_PARTITION is not set +# CONFIG_SYSV68_PARTITION is not set +CONFIG_NLS=m +CONFIG_NLS_DEFAULT="iso8859-1" +CONFIG_NLS_CODEPAGE_437=m +# CONFIG_NLS_CODEPAGE_737 is not set +# CONFIG_NLS_CODEPAGE_775 is not set +# CONFIG_NLS_CODEPAGE_850 is not set +# CONFIG_NLS_CODEPAGE_852 is not set +# CONFIG_NLS_CODEPAGE_855 is not set +# CONFIG_NLS_CODEPAGE_857 is not set +# CONFIG_NLS_CODEPAGE_860 is not set +# CONFIG_NLS_CODEPAGE_861 is not set +# CONFIG_NLS_CODEPAGE_862 is not set +# CONFIG_NLS_CODEPAGE_863 is not set +# CONFIG_NLS_CODEPAGE_864 is not set +# CONFIG_NLS_CODEPAGE_865 is not set +# CONFIG_NLS_CODEPAGE_866 is not set +# CONFIG_NLS_CODEPAGE_869 is not set +# CONFIG_NLS_CODEPAGE_936 is not set +# CONFIG_NLS_CODEPAGE_950 is not set +# CONFIG_NLS_CODEPAGE_932 is not set +# CONFIG_NLS_CODEPAGE_949 is not set +# CONFIG_NLS_CODEPAGE_874 is not set +# CONFIG_NLS_ISO8859_8 is not set +# CONFIG_NLS_CODEPAGE_1250 is not set +# CONFIG_NLS_CODEPAGE_1251 is not set +# CONFIG_NLS_ASCII is not set +CONFIG_NLS_ISO8859_1=m +# CONFIG_NLS_ISO8859_2 is not set +# CONFIG_NLS_ISO8859_3 is not set +# CONFIG_NLS_ISO8859_4 is not set +# CONFIG_NLS_ISO8859_5 is not set +# CONFIG_NLS_ISO8859_6 is not set +# CONFIG_NLS_ISO8859_7 is not set +# CONFIG_NLS_ISO8859_9 is not set +# CONFIG_NLS_ISO8859_13 is not set +# CONFIG_NLS_ISO8859_14 is not set +# CONFIG_NLS_ISO8859_15 is not set +# CONFIG_NLS_KOI8_R is not set +# CONFIG_NLS_KOI8_U is not set +# CONFIG_NLS_UTF8 is not set +# CONFIG_DLM is not set + +# +# Kernel hacking +# +# CONFIG_PRINTK_TIME is not set +CONFIG_ENABLE_WARN_DEPRECATED=y +CONFIG_ENABLE_MUST_CHECK=y +CONFIG_FRAME_WARN=1024 +# CONFIG_MAGIC_SYSRQ is not set +# CONFIG_UNUSED_SYMBOLS is not set +CONFIG_DEBUG_FS=y +# CONFIG_HEADERS_CHECK is not set +CONFIG_DEBUG_KERNEL=y +# CONFIG_DEBUG_SHIRQ is not set +# CONFIG_DETECT_SOFTLOCKUP is not set +# CONFIG_SCHED_DEBUG is not set +# CONFIG_SCHEDSTATS is not set +# CONFIG_TIMER_STATS is not set +# CONFIG_DEBUG_OBJECTS is not set +# CONFIG_SLUB_DEBUG_ON is not set +# CONFIG_SLUB_STATS is not set +# CONFIG_DEBUG_RT_MUTEXES is not set +# CONFIG_RT_MUTEX_TESTER is not set +# CONFIG_DEBUG_SPINLOCK is not set +# CONFIG_DEBUG_MUTEXES is not set +# CONFIG_DEBUG_LOCK_ALLOC is not set +# CONFIG_PROVE_LOCKING is not set +# CONFIG_LOCK_STAT is not set +# CONFIG_DEBUG_SPINLOCK_SLEEP is not set +# CONFIG_DEBUG_LOCKING_API_SELFTESTS is not set +# CONFIG_DEBUG_KOBJECT is not set +CONFIG_DEBUG_BUGVERBOSE=y +# CONFIG_DEBUG_INFO is not set +# CONFIG_DEBUG_VM is not set +# CONFIG_DEBUG_WRITECOUNT is not set +CONFIG_DEBUG_MEMORY_INIT=y +# CONFIG_DEBUG_LIST is not set +# CONFIG_DEBUG_SG is not set +CONFIG_FRAME_POINTER=y +# CONFIG_BOOT_PRINTK_DELAY is not set +# CONFIG_RCU_TORTURE_TEST is not set +# CONFIG_BACKTRACE_SELF_TEST is not set +# CONFIG_FAULT_INJECTION is not set +# CONFIG_LATENCYTOP is not set +CONFIG_SYSCTL_SYSCALL_CHECK=y +CONFIG_HAVE_FTRACE=y +CONFIG_HAVE_DYNAMIC_FTRACE=y +# CONFIG_FTRACE is not set +# CONFIG_IRQSOFF_TRACER is not set +# CONFIG_SCHED_TRACER is not set +# CONFIG_CONTEXT_SWITCH_TRACER is not set +# CONFIG_SAMPLES is not set +CONFIG_HAVE_ARCH_KGDB=y +# CONFIG_KGDB is not set +CONFIG_DEBUG_USER=y +# CONFIG_DEBUG_ERRORS is not set +# CONFIG_DEBUG_STACK_USAGE is not set +CONFIG_DEBUG_LL=y +# CONFIG_DEBUG_ICEDCC is not set + +# +# Security options +# +# CONFIG_KEYS is not set +# CONFIG_SECURITY is not set +# CONFIG_SECURITY_FILE_CAPABILITIES is not set +CONFIG_CRYPTO=y + +# +# Crypto core or helper +# +CONFIG_CRYPTO_ALGAPI=y +CONFIG_CRYPTO_BLKCIPHER=y +CONFIG_CRYPTO_MANAGER=y +# CONFIG_CRYPTO_GF128MUL is not set +# CONFIG_CRYPTO_NULL is not set +# CONFIG_CRYPTO_CRYPTD is not set +# CONFIG_CRYPTO_AUTHENC is not set +# CONFIG_CRYPTO_TEST is not set + +# +# Authenticated Encryption with Associated Data +# +# CONFIG_CRYPTO_CCM is not set +# CONFIG_CRYPTO_GCM is not set +# CONFIG_CRYPTO_SEQIV is not set + +# +# Block modes +# +CONFIG_CRYPTO_CBC=y +# CONFIG_CRYPTO_CTR is not set +# CONFIG_CRYPTO_CTS is not set +CONFIG_CRYPTO_ECB=m +# CONFIG_CRYPTO_LRW is not set +# CONFIG_CRYPTO_PCBC is not set +# CONFIG_CRYPTO_XTS is not set + +# +# Hash modes +# +# CONFIG_CRYPTO_HMAC is not set +# CONFIG_CRYPTO_XCBC is not set + +# +# Digest +# +# CONFIG_CRYPTO_CRC32C is not set +# CONFIG_CRYPTO_MD4 is not set +CONFIG_CRYPTO_MD5=y +CONFIG_CRYPTO_MICHAEL_MIC=m +# CONFIG_CRYPTO_RMD128 is not set +# CONFIG_CRYPTO_RMD160 is not set +# CONFIG_CRYPTO_RMD256 is not set +# CONFIG_CRYPTO_RMD320 is not set +# CONFIG_CRYPTO_SHA1 is not set +# CONFIG_CRYPTO_SHA256 is not set +# CONFIG_CRYPTO_SHA512 is not set +# CONFIG_CRYPTO_TGR192 is not set +# CONFIG_CRYPTO_WP512 is not set + +# +# Ciphers +# +CONFIG_CRYPTO_AES=m +# CONFIG_CRYPTO_ANUBIS is not set +CONFIG_CRYPTO_ARC4=m +# CONFIG_CRYPTO_BLOWFISH is not set +# CONFIG_CRYPTO_CAMELLIA is not set +# CONFIG_CRYPTO_CAST5 is not set +# CONFIG_CRYPTO_CAST6 is not set +CONFIG_CRYPTO_DES=y +# CONFIG_CRYPTO_FCRYPT is not set +# CONFIG_CRYPTO_KHAZAD is not set +# CONFIG_CRYPTO_SALSA20 is not set +# CONFIG_CRYPTO_SEED is not set +# CONFIG_CRYPTO_SERPENT is not set +# CONFIG_CRYPTO_TEA is not set +# CONFIG_CRYPTO_TWOFISH is not set + +# +# Compression +# +# CONFIG_CRYPTO_DEFLATE is not set +# CONFIG_CRYPTO_LZO is not set +# CONFIG_CRYPTO_HW is not set + +# +# Library routines +# +CONFIG_BITREVERSE=y +# CONFIG_GENERIC_FIND_FIRST_BIT is not set +# CONFIG_GENERIC_FIND_NEXT_BIT is not set +# CONFIG_CRC_CCITT is not set +# CONFIG_CRC16 is not set +CONFIG_CRC_T10DIF=y +# CONFIG_CRC_ITU_T is not set +CONFIG_CRC32=y +# CONFIG_CRC7 is not set +# CONFIG_LIBCRC32C is not set +CONFIG_ZLIB_INFLATE=y +CONFIG_ZLIB_DEFLATE=y +CONFIG_PLIST=y +CONFIG_HAS_IOMEM=y +CONFIG_HAS_IOPORT=y +CONFIG_HAS_DMA=y diff --git a/arch/arm/configs/palmz72_defconfig b/arch/arm/configs/palmz72_defconfig new file mode 100644 index 0000000..3245f8f --- /dev/null +++ b/arch/arm/configs/palmz72_defconfig @@ -0,0 +1,951 @@ +# +# Automatically generated make config: don't edit +# Linux kernel version: 2.6.27-rc4 +# Sun Aug 24 02:29:27 2008 +# +CONFIG_ARM=y +CONFIG_HAVE_PWM=y +CONFIG_SYS_SUPPORTS_APM_EMULATION=y +CONFIG_GENERIC_GPIO=y +CONFIG_GENERIC_TIME=y +CONFIG_GENERIC_CLOCKEVENTS=y +CONFIG_MMU=y +# CONFIG_NO_IOPORT is not set +CONFIG_GENERIC_HARDIRQS=y +CONFIG_STACKTRACE_SUPPORT=y +CONFIG_HAVE_LATENCYTOP_SUPPORT=y +CONFIG_LOCKDEP_SUPPORT=y +CONFIG_TRACE_IRQFLAGS_SUPPORT=y +CONFIG_HARDIRQS_SW_RESEND=y +CONFIG_GENERIC_IRQ_PROBE=y +CONFIG_RWSEM_GENERIC_SPINLOCK=y +# CONFIG_ARCH_HAS_ILOG2_U32 is not set +# CONFIG_ARCH_HAS_ILOG2_U64 is not set +CONFIG_GENERIC_HWEIGHT=y +CONFIG_GENERIC_CALIBRATE_DELAY=y +CONFIG_ARCH_SUPPORTS_AOUT=y +CONFIG_ZONE_DMA=y +CONFIG_ARCH_MTD_XIP=y +CONFIG_GENERIC_HARDIRQS_NO__DO_IRQ=y +CONFIG_VECTORS_BASE=0xffff0000 +CONFIG_DEFCONFIG_LIST="/lib/modules/$UNAME_RELEASE/.config" + +# +# General setup +# +CONFIG_EXPERIMENTAL=y +CONFIG_BROKEN_ON_SMP=y +CONFIG_LOCK_KERNEL=y +CONFIG_INIT_ENV_ARG_LIMIT=32 +CONFIG_LOCALVERSION="" +# CONFIG_LOCALVERSION_AUTO is not set +CONFIG_SWAP=y +CONFIG_SYSVIPC=y +CONFIG_SYSVIPC_SYSCTL=y +# CONFIG_POSIX_MQUEUE is not set +# CONFIG_BSD_PROCESS_ACCT is not set +# CONFIG_TASKSTATS is not set +# CONFIG_AUDIT is not set +# CONFIG_IKCONFIG is not set +CONFIG_LOG_BUF_SHIFT=14 +# CONFIG_CGROUPS is not set +# CONFIG_GROUP_SCHED is not set +CONFIG_SYSFS_DEPRECATED=y +CONFIG_SYSFS_DEPRECATED_V2=y +# CONFIG_RELAY is not set +CONFIG_NAMESPACES=y +# CONFIG_UTS_NS is not set +# CONFIG_IPC_NS is not set +# CONFIG_USER_NS is not set +# CONFIG_PID_NS is not set +CONFIG_BLK_DEV_INITRD=y +CONFIG_INITRAMFS_SOURCE="" +CONFIG_CC_OPTIMIZE_FOR_SIZE=y +CONFIG_SYSCTL=y +# CONFIG_EMBEDDED is not set +CONFIG_UID16=y +CONFIG_SYSCTL_SYSCALL=y +CONFIG_KALLSYMS=y +# CONFIG_KALLSYMS_EXTRA_PASS is not set +CONFIG_HOTPLUG=y +CONFIG_PRINTK=y +CONFIG_BUG=y +CONFIG_ELF_CORE=y +CONFIG_COMPAT_BRK=y +CONFIG_BASE_FULL=y +CONFIG_FUTEX=y +CONFIG_ANON_INODES=y +CONFIG_EPOLL=y +CONFIG_SIGNALFD=y +CONFIG_TIMERFD=y +CONFIG_EVENTFD=y +CONFIG_SHMEM=y +CONFIG_VM_EVENT_COUNTERS=y +CONFIG_SLAB=y +# CONFIG_SLUB is not set +# CONFIG_SLOB is not set +# CONFIG_PROFILING is not set +# CONFIG_MARKERS is not set +CONFIG_HAVE_OPROFILE=y +# CONFIG_KPROBES is not set +# CONFIG_HAVE_EFFICIENT_UNALIGNED_ACCESS is not set +# CONFIG_HAVE_IOREMAP_PROT is not set +CONFIG_HAVE_KPROBES=y +CONFIG_HAVE_KRETPROBES=y +# CONFIG_HAVE_ARCH_TRACEHOOK is not set +# CONFIG_HAVE_DMA_ATTRS is not set +# CONFIG_USE_GENERIC_SMP_HELPERS is not set +CONFIG_HAVE_CLK=y +CONFIG_PROC_PAGE_MONITOR=y +CONFIG_HAVE_GENERIC_DMA_COHERENT=y +CONFIG_SLABINFO=y +CONFIG_RT_MUTEXES=y +# CONFIG_TINY_SHMEM is not set +CONFIG_BASE_SMALL=0 +CONFIG_MODULES=y +# CONFIG_MODULE_FORCE_LOAD is not set +CONFIG_MODULE_UNLOAD=y +# CONFIG_MODULE_FORCE_UNLOAD is not set +# CONFIG_MODVERSIONS is not set +# CONFIG_MODULE_SRCVERSION_ALL is not set +CONFIG_KMOD=y +CONFIG_BLOCK=y +# CONFIG_LBD is not set +# CONFIG_BLK_DEV_IO_TRACE is not set +# CONFIG_LSF is not set +# CONFIG_BLK_DEV_BSG is not set +# CONFIG_BLK_DEV_INTEGRITY is not set + +# +# IO Schedulers +# +CONFIG_IOSCHED_NOOP=y +CONFIG_IOSCHED_AS=y +# CONFIG_IOSCHED_DEADLINE is not set +# CONFIG_IOSCHED_CFQ is not set +CONFIG_DEFAULT_AS=y +# CONFIG_DEFAULT_DEADLINE is not set +# CONFIG_DEFAULT_CFQ is not set +# CONFIG_DEFAULT_NOOP is not set +CONFIG_DEFAULT_IOSCHED="anticipatory" +CONFIG_CLASSIC_RCU=y + +# +# System Type +# +# CONFIG_ARCH_AAEC2000 is not set +# CONFIG_ARCH_INTEGRATOR is not set +# CONFIG_ARCH_REALVIEW is not set +# CONFIG_ARCH_VERSATILE is not set +# CONFIG_ARCH_AT91 is not set +# CONFIG_ARCH_CLPS7500 is not set +# CONFIG_ARCH_CLPS711X is not set +# CONFIG_ARCH_EBSA110 is not set +# CONFIG_ARCH_EP93XX is not set +# CONFIG_ARCH_FOOTBRIDGE is not set +# CONFIG_ARCH_NETX is not set +# CONFIG_ARCH_H720X is not set +# CONFIG_ARCH_IMX is not set +# CONFIG_ARCH_IOP13XX is not set +# CONFIG_ARCH_IOP32X is not set +# CONFIG_ARCH_IOP33X is not set +# CONFIG_ARCH_IXP23XX is not set +# CONFIG_ARCH_IXP2000 is not set +# CONFIG_ARCH_IXP4XX is not set +# CONFIG_ARCH_L7200 is not set +# CONFIG_ARCH_KIRKWOOD is not set +# CONFIG_ARCH_KS8695 is not set +# CONFIG_ARCH_NS9XXX is not set +# CONFIG_ARCH_LOKI is not set +# CONFIG_ARCH_MV78XX0 is not set +# CONFIG_ARCH_MXC is not set +# CONFIG_ARCH_ORION5X is not set +# CONFIG_ARCH_PNX4008 is not set +CONFIG_ARCH_PXA=y +# CONFIG_ARCH_RPC is not set +# CONFIG_ARCH_SA1100 is not set +# CONFIG_ARCH_S3C2410 is not set +# CONFIG_ARCH_SHARK is not set +# CONFIG_ARCH_LH7A40X is not set +# CONFIG_ARCH_DAVINCI is not set +# CONFIG_ARCH_OMAP is not set +# CONFIG_ARCH_MSM7X00A is not set + +# +# Intel PXA2xx/PXA3xx Implementations +# +# CONFIG_ARCH_GUMSTIX is not set +# CONFIG_ARCH_LUBBOCK is not set +# CONFIG_MACH_LOGICPD_PXA270 is not set +# CONFIG_MACH_MAINSTONE is not set +# CONFIG_ARCH_PXA_IDP is not set +# CONFIG_PXA_SHARPSL is not set +# CONFIG_ARCH_PXA_ESERIES is not set +# CONFIG_MACH_TRIZEPS4 is not set +# CONFIG_MACH_EM_X270 is not set +# CONFIG_MACH_COLIBRI is not set +# CONFIG_MACH_ZYLONITE is not set +# CONFIG_MACH_LITTLETON is not set +# CONFIG_MACH_TAVOREVB is not set +# CONFIG_MACH_SAAR is not set +# CONFIG_MACH_ARMCORE is not set +# CONFIG_MACH_MAGICIAN is not set +# CONFIG_MACH_PCM027 is not set +CONFIG_ARCH_PXA_PALM=y +# CONFIG_MACH_PALMTX is not set +CONFIG_MACH_PALMZ72=y +# CONFIG_PXA_EZX is not set +CONFIG_PXA27x=y +CONFIG_PXA_PWM=y + +# +# Boot options +# + +# +# Power management +# + +# +# Processor Type +# +CONFIG_CPU_32=y +CONFIG_CPU_XSCALE=y +CONFIG_CPU_32v5=y +CONFIG_CPU_ABRT_EV5T=y +CONFIG_CPU_PABRT_NOIFAR=y +CONFIG_CPU_CACHE_VIVT=y +CONFIG_CPU_TLB_V4WBI=y +CONFIG_CPU_CP15=y +CONFIG_CPU_CP15_MMU=y + +# +# Processor Features +# +CONFIG_ARM_THUMB=y +# CONFIG_CPU_DCACHE_DISABLE is not set +# CONFIG_OUTER_CACHE is not set +CONFIG_IWMMXT=y +CONFIG_XSCALE_PMU=y + +# +# Bus support +# +# CONFIG_PCI_SYSCALL is not set +# CONFIG_ARCH_SUPPORTS_MSI is not set +# CONFIG_PCCARD is not set + +# +# Kernel Features +# +CONFIG_TICK_ONESHOT=y +# CONFIG_NO_HZ is not set +# CONFIG_HIGH_RES_TIMERS is not set +CONFIG_GENERIC_CLOCKEVENTS_BUILD=y +CONFIG_PREEMPT=y +CONFIG_HZ=100 +CONFIG_AEABI=y +CONFIG_OABI_COMPAT=y +# CONFIG_ARCH_DISCONTIGMEM_ENABLE is not set +CONFIG_SELECT_MEMORY_MODEL=y +CONFIG_FLATMEM_MANUAL=y +# CONFIG_DISCONTIGMEM_MANUAL is not set +# CONFIG_SPARSEMEM_MANUAL is not set +CONFIG_FLATMEM=y +CONFIG_FLAT_NODE_MEM_MAP=y +# CONFIG_SPARSEMEM_STATIC is not set +# CONFIG_SPARSEMEM_VMEMMAP_ENABLE is not set +CONFIG_PAGEFLAGS_EXTENDED=y +CONFIG_SPLIT_PTLOCK_CPUS=4096 +# CONFIG_RESOURCES_64BIT is not set +CONFIG_ZONE_DMA_FLAG=1 +CONFIG_BOUNCE=y +CONFIG_VIRT_TO_BUS=y +CONFIG_ALIGNMENT_TRAP=y + +# +# Boot options +# +CONFIG_ZBOOT_ROM_TEXT=0x0 +CONFIG_ZBOOT_ROM_BSS=0x0 +CONFIG_CMDLINE="mem=32M console=tty root=/dev/mmcblk0" +# CONFIG_XIP_KERNEL is not set +# CONFIG_KEXEC is not set + +# +# CPU Frequency scaling +# +# CONFIG_CPU_FREQ is not set + +# +# Floating point emulation +# + +# +# At least one emulation must be selected +# +CONFIG_FPE_NWFPE=y +# CONFIG_FPE_NWFPE_XP is not set +# CONFIG_FPE_FASTFPE is not set + +# +# Userspace binary formats +# +CONFIG_BINFMT_ELF=y +# CONFIG_BINFMT_AOUT is not set +# CONFIG_BINFMT_MISC is not set + +# +# Power management options +# +CONFIG_PM=y +# CONFIG_PM_DEBUG is not set +CONFIG_PM_SLEEP=y +CONFIG_SUSPEND=y +CONFIG_SUSPEND_FREEZER=y +CONFIG_APM_EMULATION=y +CONFIG_ARCH_SUSPEND_POSSIBLE=y +CONFIG_NET=y + +# +# Networking options +# +CONFIG_PACKET=y +# CONFIG_PACKET_MMAP is not set +CONFIG_UNIX=y +# CONFIG_NET_KEY is not set +CONFIG_INET=y +# CONFIG_IP_MULTICAST is not set +# CONFIG_IP_ADVANCED_ROUTER is not set +CONFIG_IP_FIB_HASH=y +CONFIG_IP_PNP=y +# CONFIG_IP_PNP_DHCP is not set +CONFIG_IP_PNP_BOOTP=y +# CONFIG_IP_PNP_RARP is not set +# CONFIG_NET_IPIP is not set +# CONFIG_NET_IPGRE is not set +# CONFIG_ARPD is not set +# CONFIG_SYN_COOKIES is not set +# CONFIG_INET_AH is not set +# CONFIG_INET_ESP is not set +# CONFIG_INET_IPCOMP is not set +# CONFIG_INET_XFRM_TUNNEL is not set +# CONFIG_INET_TUNNEL is not set +# CONFIG_INET_XFRM_MODE_TRANSPORT is not set +# CONFIG_INET_XFRM_MODE_TUNNEL is not set +# CONFIG_INET_XFRM_MODE_BEET is not set +# CONFIG_INET_LRO is not set +CONFIG_INET_DIAG=y +CONFIG_INET_TCP_DIAG=y +# CONFIG_TCP_CONG_ADVANCED is not set +CONFIG_TCP_CONG_CUBIC=y +CONFIG_DEFAULT_TCP_CONG="cubic" +# CONFIG_TCP_MD5SIG is not set +# CONFIG_IPV6 is not set +# CONFIG_NETWORK_SECMARK is not set +# CONFIG_NETFILTER is not set +# CONFIG_IP_DCCP is not set +# CONFIG_IP_SCTP is not set +# CONFIG_TIPC is not set +# CONFIG_ATM is not set +# CONFIG_BRIDGE is not set +# CONFIG_VLAN_8021Q is not set +# CONFIG_DECNET is not set +# CONFIG_LLC2 is not set +# CONFIG_IPX is not set +# CONFIG_ATALK is not set +# CONFIG_X25 is not set +# CONFIG_LAPB is not set +# CONFIG_ECONET is not set +# CONFIG_WAN_ROUTER is not set +# CONFIG_NET_SCHED is not set + +# +# Network testing +# +# CONFIG_NET_PKTGEN is not set +# CONFIG_HAMRADIO is not set +# CONFIG_CAN is not set +# CONFIG_IRDA is not set +# CONFIG_BT is not set +# CONFIG_AF_RXRPC is not set + +# +# Wireless +# +# CONFIG_CFG80211 is not set +# CONFIG_WIRELESS_EXT is not set +# CONFIG_MAC80211 is not set +# CONFIG_IEEE80211 is not set +# CONFIG_RFKILL is not set +# CONFIG_NET_9P is not set + +# +# Device Drivers +# + +# +# Generic Driver Options +# +CONFIG_UEVENT_HELPER_PATH="/sbin/hotplug" +CONFIG_STANDALONE=y +CONFIG_PREVENT_FIRMWARE_BUILD=y +CONFIG_FW_LOADER=y +CONFIG_FIRMWARE_IN_KERNEL=y +CONFIG_EXTRA_FIRMWARE="" +# CONFIG_SYS_HYPERVISOR is not set +# CONFIG_CONNECTOR is not set +# CONFIG_MTD is not set +# CONFIG_PARPORT is not set +CONFIG_BLK_DEV=y +# CONFIG_BLK_DEV_COW_COMMON is not set +CONFIG_BLK_DEV_LOOP=y +# CONFIG_BLK_DEV_CRYPTOLOOP is not set +# CONFIG_BLK_DEV_NBD is not set +# CONFIG_BLK_DEV_RAM is not set +# CONFIG_CDROM_PKTCDVD is not set +# CONFIG_ATA_OVER_ETH is not set +# CONFIG_MISC_DEVICES is not set +CONFIG_HAVE_IDE=y +# CONFIG_IDE is not set + +# +# SCSI device support +# +# CONFIG_RAID_ATTRS is not set +# CONFIG_SCSI is not set +# CONFIG_SCSI_DMA is not set +# CONFIG_SCSI_NETLINK is not set +# CONFIG_ATA is not set +# CONFIG_MD is not set +# CONFIG_NETDEVICES is not set +# CONFIG_ISDN is not set + +# +# Input device support +# +CONFIG_INPUT=y +# CONFIG_INPUT_FF_MEMLESS is not set +# CONFIG_INPUT_POLLDEV is not set + +# +# Userland interfaces +# +CONFIG_INPUT_MOUSEDEV=y +# CONFIG_INPUT_MOUSEDEV_PSAUX is not set +CONFIG_INPUT_MOUSEDEV_SCREEN_X=1024 +CONFIG_INPUT_MOUSEDEV_SCREEN_Y=768 +# CONFIG_INPUT_JOYDEV is not set +CONFIG_INPUT_EVDEV=y +# CONFIG_INPUT_EVBUG is not set + +# +# Input Device Drivers +# +CONFIG_INPUT_KEYBOARD=y +# CONFIG_KEYBOARD_ATKBD is not set +# CONFIG_KEYBOARD_SUNKBD is not set +# CONFIG_KEYBOARD_LKKBD is not set +# CONFIG_KEYBOARD_XTKBD is not set +# CONFIG_KEYBOARD_NEWTON is not set +# CONFIG_KEYBOARD_STOWAWAY is not set +CONFIG_KEYBOARD_PXA27x=y +# CONFIG_KEYBOARD_GPIO is not set +# CONFIG_KEYBOARD_MATRIX is not set +# CONFIG_INPUT_MOUSE is not set +# CONFIG_INPUT_JOYSTICK is not set +# CONFIG_INPUT_TABLET is not set +# CONFIG_INPUT_TOUCHSCREEN is not set +# CONFIG_INPUT_MISC is not set + +# +# Hardware I/O ports +# +# CONFIG_SERIO is not set +# CONFIG_GAMEPORT is not set + +# +# Character devices +# +CONFIG_VT=y +CONFIG_CONSOLE_TRANSLATIONS=y +CONFIG_VT_CONSOLE=y +CONFIG_HW_CONSOLE=y +# CONFIG_VT_HW_CONSOLE_BINDING is not set +CONFIG_DEVKMEM=y +# CONFIG_SERIAL_NONSTANDARD is not set + +# +# Serial drivers +# +# CONFIG_SERIAL_8250 is not set + +# +# Non-8250 serial port support +# +# CONFIG_SERIAL_PXA is not set +CONFIG_UNIX98_PTYS=y +CONFIG_LEGACY_PTYS=y +CONFIG_LEGACY_PTY_COUNT=256 +# CONFIG_IPMI_HANDLER is not set +# CONFIG_HW_RANDOM is not set +# CONFIG_NVRAM is not set +# CONFIG_R3964 is not set +# CONFIG_RAW_DRIVER is not set +# CONFIG_TCG_TPM is not set +CONFIG_I2C=y +CONFIG_I2C_BOARDINFO=y +# CONFIG_I2C_CHARDEV is not set +CONFIG_I2C_HELPER_AUTO=y + +# +# I2C Hardware Bus support +# + +# +# I2C system bus drivers (mostly embedded / system-on-chip) +# +# CONFIG_I2C_GPIO is not set +# CONFIG_I2C_OCORES is not set +CONFIG_I2C_PXA=y +# CONFIG_I2C_PXA_SLAVE is not set +# CONFIG_I2C_SIMTEC is not set + +# +# External I2C/SMBus adapter drivers +# +# CONFIG_I2C_PARPORT_LIGHT is not set +# CONFIG_I2C_TAOS_EVM is not set + +# +# Other I2C/SMBus bus drivers +# +# CONFIG_I2C_PCA_PLATFORM is not set +# CONFIG_I2C_STUB is not set + +# +# Miscellaneous I2C Chip support +# +# CONFIG_DS1682 is not set +# CONFIG_AT24 is not set +# CONFIG_SENSORS_EEPROM is not set +# CONFIG_SENSORS_PCF8574 is not set +# CONFIG_PCF8575 is not set +# CONFIG_SENSORS_PCA9539 is not set +# CONFIG_SENSORS_PCF8591 is not set +# CONFIG_TPS65010 is not set +# CONFIG_SENSORS_MAX6875 is not set +# CONFIG_SENSORS_TSL2550 is not set +# CONFIG_I2C_DEBUG_CORE is not set +# CONFIG_I2C_DEBUG_ALGO is not set +# CONFIG_I2C_DEBUG_BUS is not set +# CONFIG_I2C_DEBUG_CHIP is not set +CONFIG_SPI=y +CONFIG_SPI_MASTER=y + +# +# SPI Master Controller Drivers +# +# CONFIG_SPI_BITBANG is not set +# CONFIG_SPI_PXA2XX is not set + +# +# SPI Protocol Masters +# +# CONFIG_SPI_AT25 is not set +CONFIG_SPI_SPIDEV=y +# CONFIG_SPI_TLE62X0 is not set +CONFIG_ARCH_REQUIRE_GPIOLIB=y +CONFIG_GPIOLIB=y +CONFIG_GPIO_SYSFS=y + +# +# I2C GPIO expanders: +# +# CONFIG_GPIO_MAX732X is not set +# CONFIG_GPIO_PCA953X is not set +# CONFIG_GPIO_PCF857X is not set + +# +# PCI GPIO expanders: +# + +# +# SPI GPIO expanders: +# +# CONFIG_GPIO_MAX7301 is not set +# CONFIG_GPIO_MCP23S08 is not set +# CONFIG_W1 is not set +CONFIG_POWER_SUPPLY=y +# CONFIG_POWER_SUPPLY_DEBUG is not set +CONFIG_PDA_POWER=y +# CONFIG_APM_POWER is not set +# CONFIG_BATTERY_DS2760 is not set +# CONFIG_HWMON is not set +# CONFIG_WATCHDOG is not set + +# +# Sonics Silicon Backplane +# +CONFIG_SSB_POSSIBLE=y +# CONFIG_SSB is not set + +# +# Multifunction device drivers +# +# CONFIG_MFD_CORE is not set +# CONFIG_MFD_SM501 is not set +# CONFIG_HTC_EGPIO is not set +# CONFIG_HTC_PASIC3 is not set +# CONFIG_MFD_TMIO is not set +# CONFIG_MFD_T7L66XB is not set +# CONFIG_MFD_TC6387XB is not set +# CONFIG_MFD_TC6393XB is not set + +# +# Multimedia devices +# + +# +# Multimedia core support +# +# CONFIG_VIDEO_DEV is not set +# CONFIG_DVB_CORE is not set +# CONFIG_VIDEO_MEDIA is not set + +# +# Multimedia drivers +# +# CONFIG_DAB is not set + +# +# Graphics support +# +# CONFIG_VGASTATE is not set +# CONFIG_VIDEO_OUTPUT_CONTROL is not set +CONFIG_FB=y +# CONFIG_FIRMWARE_EDID is not set +# CONFIG_FB_DDC is not set +CONFIG_FB_CFB_FILLRECT=y +CONFIG_FB_CFB_COPYAREA=y +CONFIG_FB_CFB_IMAGEBLIT=y +# CONFIG_FB_CFB_REV_PIXELS_IN_BYTE is not set +# CONFIG_FB_SYS_FILLRECT is not set +# CONFIG_FB_SYS_COPYAREA is not set +# CONFIG_FB_SYS_IMAGEBLIT is not set +# CONFIG_FB_FOREIGN_ENDIAN is not set +# CONFIG_FB_SYS_FOPS is not set +# CONFIG_FB_SVGALIB is not set +# CONFIG_FB_MACMODES is not set +# CONFIG_FB_BACKLIGHT is not set +# CONFIG_FB_MODE_HELPERS is not set +# CONFIG_FB_TILEBLITTING is not set + +# +# Frame buffer hardware drivers +# +# CONFIG_FB_S1D13XXX is not set +CONFIG_FB_PXA=y +# CONFIG_FB_PXA_SMARTPANEL is not set +# CONFIG_FB_PXA_PARAMETERS is not set +# CONFIG_FB_MBX is not set +# CONFIG_FB_W100 is not set +# CONFIG_FB_AM200EPD is not set +# CONFIG_FB_VIRTUAL is not set +CONFIG_BACKLIGHT_LCD_SUPPORT=y +# CONFIG_LCD_CLASS_DEVICE is not set +CONFIG_BACKLIGHT_CLASS_DEVICE=y +# CONFIG_BACKLIGHT_CORGI is not set +CONFIG_BACKLIGHT_PWM=y + +# +# Display device support +# +CONFIG_DISPLAY_SUPPORT=y + +# +# Display hardware drivers +# + +# +# Console display driver support +# +# CONFIG_VGA_CONSOLE is not set +CONFIG_DUMMY_CONSOLE=y +CONFIG_FRAMEBUFFER_CONSOLE=y +# CONFIG_FRAMEBUFFER_CONSOLE_DETECT_PRIMARY is not set +# CONFIG_FRAMEBUFFER_CONSOLE_ROTATION is not set +CONFIG_FONTS=y +CONFIG_FONT_8x8=y +# CONFIG_FONT_8x16 is not set +# CONFIG_FONT_6x11 is not set +# CONFIG_FONT_7x14 is not set +# CONFIG_FONT_PEARL_8x8 is not set +# CONFIG_FONT_ACORN_8x8 is not set +# CONFIG_FONT_MINI_4x6 is not set +# CONFIG_FONT_SUN8x16 is not set +# CONFIG_FONT_SUN12x22 is not set +# CONFIG_FONT_10x18 is not set +# CONFIG_LOGO is not set +# CONFIG_SOUND is not set +# CONFIG_HID_SUPPORT is not set +# CONFIG_USB_SUPPORT is not set +CONFIG_MMC=y +CONFIG_MMC_DEBUG=y +# CONFIG_MMC_UNSAFE_RESUME is not set + +# +# MMC/SD Card Drivers +# +CONFIG_MMC_BLOCK=y +CONFIG_MMC_BLOCK_BOUNCE=y +# CONFIG_SDIO_UART is not set +# CONFIG_MMC_TEST is not set + +# +# MMC/SD Host Controller Drivers +# +CONFIG_MMC_PXA=y +# CONFIG_MMC_SDHCI is not set +# CONFIG_MMC_SPI is not set +# CONFIG_NEW_LEDS is not set +CONFIG_RTC_LIB=y +CONFIG_RTC_CLASS=y +CONFIG_RTC_HCTOSYS=y +CONFIG_RTC_HCTOSYS_DEVICE="rtc0" +# CONFIG_RTC_DEBUG is not set + +# +# RTC interfaces +# +CONFIG_RTC_INTF_SYSFS=y +CONFIG_RTC_INTF_PROC=y +CONFIG_RTC_INTF_DEV=y +# CONFIG_RTC_INTF_DEV_UIE_EMUL is not set +# CONFIG_RTC_DRV_TEST is not set + +# +# I2C RTC drivers +# +# CONFIG_RTC_DRV_DS1307 is not set +# CONFIG_RTC_DRV_DS1374 is not set +# CONFIG_RTC_DRV_DS1672 is not set +# CONFIG_RTC_DRV_MAX6900 is not set +# CONFIG_RTC_DRV_RS5C372 is not set +# CONFIG_RTC_DRV_ISL1208 is not set +# CONFIG_RTC_DRV_X1205 is not set +# CONFIG_RTC_DRV_PCF8563 is not set +# CONFIG_RTC_DRV_PCF8583 is not set +# CONFIG_RTC_DRV_M41T80 is not set +# CONFIG_RTC_DRV_S35390A is not set +# CONFIG_RTC_DRV_FM3130 is not set + +# +# SPI RTC drivers +# +# CONFIG_RTC_DRV_M41T94 is not set +# CONFIG_RTC_DRV_DS1305 is not set +# CONFIG_RTC_DRV_MAX6902 is not set +# CONFIG_RTC_DRV_R9701 is not set +# CONFIG_RTC_DRV_RS5C348 is not set + +# +# Platform RTC drivers +# +# CONFIG_RTC_DRV_CMOS is not set +# CONFIG_RTC_DRV_DS1511 is not set +# CONFIG_RTC_DRV_DS1553 is not set +# CONFIG_RTC_DRV_DS1742 is not set +# CONFIG_RTC_DRV_STK17TA8 is not set +# CONFIG_RTC_DRV_M48T86 is not set +# CONFIG_RTC_DRV_M48T59 is not set +# CONFIG_RTC_DRV_V3020 is not set + +# +# on-CPU RTC drivers +# +CONFIG_RTC_DRV_SA1100=y +# CONFIG_DMADEVICES is not set + +# +# Voltage and Current regulators +# +# CONFIG_REGULATOR is not set +# CONFIG_REGULATOR_FIXED_VOLTAGE is not set +# CONFIG_REGULATOR_VIRTUAL_CONSUMER is not set +# CONFIG_REGULATOR_BQ24022 is not set +# CONFIG_UIO is not set + +# +# File systems +# +CONFIG_EXT2_FS=y +# CONFIG_EXT2_FS_XATTR is not set +# CONFIG_EXT2_FS_XIP is not set +CONFIG_EXT3_FS=y +CONFIG_EXT3_FS_XATTR=y +# CONFIG_EXT3_FS_POSIX_ACL is not set +# CONFIG_EXT3_FS_SECURITY is not set +# CONFIG_EXT4DEV_FS is not set +CONFIG_JBD=y +CONFIG_FS_MBCACHE=y +# CONFIG_REISERFS_FS is not set +# CONFIG_JFS_FS is not set +# CONFIG_FS_POSIX_ACL is not set +# CONFIG_XFS_FS is not set +# CONFIG_OCFS2_FS is not set +# CONFIG_DNOTIFY is not set +# CONFIG_INOTIFY is not set +# CONFIG_QUOTA is not set +# CONFIG_AUTOFS_FS is not set +# CONFIG_AUTOFS4_FS is not set +# CONFIG_FUSE_FS is not set + +# +# CD-ROM/DVD Filesystems +# +# CONFIG_ISO9660_FS is not set +# CONFIG_UDF_FS is not set + +# +# DOS/FAT/NT Filesystems +# +CONFIG_FAT_FS=y +CONFIG_MSDOS_FS=y +CONFIG_VFAT_FS=y +CONFIG_FAT_DEFAULT_CODEPAGE=866 +CONFIG_FAT_DEFAULT_IOCHARSET="utf8" +# CONFIG_NTFS_FS is not set + +# +# Pseudo filesystems +# +CONFIG_PROC_FS=y +CONFIG_PROC_SYSCTL=y +CONFIG_SYSFS=y +CONFIG_TMPFS=y +# CONFIG_TMPFS_POSIX_ACL is not set +# CONFIG_HUGETLB_PAGE is not set +# CONFIG_CONFIGFS_FS is not set + +# +# Miscellaneous filesystems +# +# CONFIG_ADFS_FS is not set +# CONFIG_AFFS_FS is not set +# CONFIG_HFS_FS is not set +# CONFIG_HFSPLUS_FS is not set +# CONFIG_BEFS_FS is not set +# CONFIG_BFS_FS is not set +# CONFIG_EFS_FS is not set +# CONFIG_CRAMFS is not set +# CONFIG_VXFS_FS is not set +# CONFIG_MINIX_FS is not set +# CONFIG_OMFS_FS is not set +# CONFIG_HPFS_FS is not set +# CONFIG_QNX4FS_FS is not set +# CONFIG_ROMFS_FS is not set +# CONFIG_SYSV_FS is not set +# CONFIG_UFS_FS is not set +# CONFIG_NETWORK_FILESYSTEMS is not set + +# +# Partition Types +# +# CONFIG_PARTITION_ADVANCED is not set +CONFIG_MSDOS_PARTITION=y +CONFIG_NLS=y +CONFIG_NLS_DEFAULT="utf8" +# CONFIG_NLS_CODEPAGE_437 is not set +# CONFIG_NLS_CODEPAGE_737 is not set +# CONFIG_NLS_CODEPAGE_775 is not set +# CONFIG_NLS_CODEPAGE_850 is not set +# CONFIG_NLS_CODEPAGE_852 is not set +# CONFIG_NLS_CODEPAGE_855 is not set +# CONFIG_NLS_CODEPAGE_857 is not set +# CONFIG_NLS_CODEPAGE_860 is not set +# CONFIG_NLS_CODEPAGE_861 is not set +# CONFIG_NLS_CODEPAGE_862 is not set +# CONFIG_NLS_CODEPAGE_863 is not set +# CONFIG_NLS_CODEPAGE_864 is not set +# CONFIG_NLS_CODEPAGE_865 is not set +CONFIG_NLS_CODEPAGE_866=y +# CONFIG_NLS_CODEPAGE_869 is not set +# CONFIG_NLS_CODEPAGE_936 is not set +# CONFIG_NLS_CODEPAGE_950 is not set +# CONFIG_NLS_CODEPAGE_932 is not set +# CONFIG_NLS_CODEPAGE_949 is not set +# CONFIG_NLS_CODEPAGE_874 is not set +# CONFIG_NLS_ISO8859_8 is not set +# CONFIG_NLS_CODEPAGE_1250 is not set +# CONFIG_NLS_CODEPAGE_1251 is not set +# CONFIG_NLS_ASCII is not set +# CONFIG_NLS_ISO8859_1 is not set +# CONFIG_NLS_ISO8859_2 is not set +# CONFIG_NLS_ISO8859_3 is not set +# CONFIG_NLS_ISO8859_4 is not set +# CONFIG_NLS_ISO8859_5 is not set +# CONFIG_NLS_ISO8859_6 is not set +# CONFIG_NLS_ISO8859_7 is not set +# CONFIG_NLS_ISO8859_9 is not set +# CONFIG_NLS_ISO8859_13 is not set +# CONFIG_NLS_ISO8859_14 is not set +# CONFIG_NLS_ISO8859_15 is not set +# CONFIG_NLS_KOI8_R is not set +# CONFIG_NLS_KOI8_U is not set +CONFIG_NLS_UTF8=y +# CONFIG_DLM is not set + +# +# Kernel hacking +# +# CONFIG_PRINTK_TIME is not set +CONFIG_ENABLE_WARN_DEPRECATED=y +CONFIG_ENABLE_MUST_CHECK=y +CONFIG_FRAME_WARN=1024 +# CONFIG_MAGIC_SYSRQ is not set +# CONFIG_UNUSED_SYMBOLS is not set +# CONFIG_DEBUG_FS is not set +# CONFIG_HEADERS_CHECK is not set +# CONFIG_DEBUG_KERNEL is not set +CONFIG_DEBUG_BUGVERBOSE=y +CONFIG_DEBUG_MEMORY_INIT=y +CONFIG_FRAME_POINTER=y +# CONFIG_LATENCYTOP is not set +CONFIG_SYSCTL_SYSCALL_CHECK=y +CONFIG_HAVE_FTRACE=y +CONFIG_HAVE_DYNAMIC_FTRACE=y +# CONFIG_FTRACE is not set +# CONFIG_IRQSOFF_TRACER is not set +# CONFIG_PREEMPT_TRACER is not set +# CONFIG_SCHED_TRACER is not set +# CONFIG_CONTEXT_SWITCH_TRACER is not set +# CONFIG_SAMPLES is not set +CONFIG_HAVE_ARCH_KGDB=y +CONFIG_DEBUG_USER=y + +# +# Security options +# +# CONFIG_KEYS is not set +# CONFIG_SECURITY is not set +# CONFIG_SECURITY_FILE_CAPABILITIES is not set +# CONFIG_CRYPTO is not set + +# +# Library routines +# +CONFIG_BITREVERSE=y +# CONFIG_GENERIC_FIND_FIRST_BIT is not set +# CONFIG_GENERIC_FIND_NEXT_BIT is not set +# CONFIG_CRC_CCITT is not set +# CONFIG_CRC16 is not set +CONFIG_CRC_T10DIF=y +# CONFIG_CRC_ITU_T is not set +CONFIG_CRC32=y +# CONFIG_CRC7 is not set +# CONFIG_LIBCRC32C is not set +CONFIG_PLIST=y +CONFIG_HAS_IOMEM=y +CONFIG_HAS_IOPORT=y +CONFIG_HAS_DMA=y diff --git a/arch/arm/include/asm/bug.h b/arch/arm/include/asm/bug.h index 7b62351..4d88425 100644 --- a/arch/arm/include/asm/bug.h +++ b/arch/arm/include/asm/bug.h @@ -12,7 +12,7 @@ extern void __bug(const char *file, int line) __attribute__((noreturn)); #else /* this just causes an oops */ -#define BUG() (*(int *)0 = 0) +#define BUG() do { *(int *)0 = 0; } while (1) #endif diff --git a/arch/arm/include/asm/cacheflush.h b/arch/arm/include/asm/cacheflush.h index 9073d9c..de6c59f 100644 --- a/arch/arm/include/asm/cacheflush.h +++ b/arch/arm/include/asm/cacheflush.h @@ -444,94 +444,4 @@ static inline void flush_ioremap_region(unsigned long phys, void __iomem *virt, dmac_inv_range(start, start + size); } -#define __cacheid_present(val) (val != read_cpuid(CPUID_ID)) -#define __cacheid_type_v7(val) ((val & (7 << 29)) == (4 << 29)) - -#define __cacheid_vivt_prev7(val) ((val & (15 << 25)) != (14 << 25)) -#define __cacheid_vipt_prev7(val) ((val & (15 << 25)) == (14 << 25)) -#define __cacheid_vipt_nonaliasing_prev7(val) ((val & (15 << 25 | 1 << 23)) == (14 << 25)) -#define __cacheid_vipt_aliasing_prev7(val) ((val & (15 << 25 | 1 << 23)) == (14 << 25 | 1 << 23)) - -#define __cacheid_vivt(val) (__cacheid_type_v7(val) ? 0 : __cacheid_vivt_prev7(val)) -#define __cacheid_vipt(val) (__cacheid_type_v7(val) ? 1 : __cacheid_vipt_prev7(val)) -#define __cacheid_vipt_nonaliasing(val) (__cacheid_type_v7(val) ? 1 : __cacheid_vipt_nonaliasing_prev7(val)) -#define __cacheid_vipt_aliasing(val) (__cacheid_type_v7(val) ? 0 : __cacheid_vipt_aliasing_prev7(val)) -#define __cacheid_vivt_asid_tagged_instr(val) (__cacheid_type_v7(val) ? ((val & (3 << 14)) == (1 << 14)) : 0) - -#if defined(CONFIG_CPU_CACHE_VIVT) && !defined(CONFIG_CPU_CACHE_VIPT) -/* - * VIVT caches only - */ -#define cache_is_vivt() 1 -#define cache_is_vipt() 0 -#define cache_is_vipt_nonaliasing() 0 -#define cache_is_vipt_aliasing() 0 -#define icache_is_vivt_asid_tagged() 0 - -#elif !defined(CONFIG_CPU_CACHE_VIVT) && defined(CONFIG_CPU_CACHE_VIPT) -/* - * VIPT caches only - */ -#define cache_is_vivt() 0 -#define cache_is_vipt() 1 -#define cache_is_vipt_nonaliasing() \ - ({ \ - unsigned int __val = read_cpuid(CPUID_CACHETYPE); \ - __cacheid_vipt_nonaliasing(__val); \ - }) - -#define cache_is_vipt_aliasing() \ - ({ \ - unsigned int __val = read_cpuid(CPUID_CACHETYPE); \ - __cacheid_vipt_aliasing(__val); \ - }) - -#define icache_is_vivt_asid_tagged() \ - ({ \ - unsigned int __val = read_cpuid(CPUID_CACHETYPE); \ - __cacheid_vivt_asid_tagged_instr(__val); \ - }) - -#else -/* - * VIVT or VIPT caches. Note that this is unreliable since ARM926 - * and V6 CPUs satisfy the "(val & (15 << 25)) == (14 << 25)" test. - * There's no way to tell from the CacheType register what type (!) - * the cache is. - */ -#define cache_is_vivt() \ - ({ \ - unsigned int __val = read_cpuid(CPUID_CACHETYPE); \ - (!__cacheid_present(__val)) || __cacheid_vivt(__val); \ - }) - -#define cache_is_vipt() \ - ({ \ - unsigned int __val = read_cpuid(CPUID_CACHETYPE); \ - __cacheid_present(__val) && __cacheid_vipt(__val); \ - }) - -#define cache_is_vipt_nonaliasing() \ - ({ \ - unsigned int __val = read_cpuid(CPUID_CACHETYPE); \ - __cacheid_present(__val) && \ - __cacheid_vipt_nonaliasing(__val); \ - }) - -#define cache_is_vipt_aliasing() \ - ({ \ - unsigned int __val = read_cpuid(CPUID_CACHETYPE); \ - __cacheid_present(__val) && \ - __cacheid_vipt_aliasing(__val); \ - }) - -#define icache_is_vivt_asid_tagged() \ - ({ \ - unsigned int __val = read_cpuid(CPUID_CACHETYPE); \ - __cacheid_present(__val) && \ - __cacheid_vivt_asid_tagged_instr(__val); \ - }) - -#endif - #endif diff --git a/arch/arm/include/asm/cachetype.h b/arch/arm/include/asm/cachetype.h new file mode 100644 index 0000000..b52386b --- /dev/null +++ b/arch/arm/include/asm/cachetype.h @@ -0,0 +1,96 @@ +#ifndef __ASM_ARM_CACHETYPE_H +#define __ASM_ARM_CACHETYPE_H + +#include + +#define __cacheid_present(val) (val != read_cpuid_id()) +#define __cacheid_type_v7(val) ((val & (7 << 29)) == (4 << 29)) + +#define __cacheid_vivt_prev7(val) ((val & (15 << 25)) != (14 << 25)) +#define __cacheid_vipt_prev7(val) ((val & (15 << 25)) == (14 << 25)) +#define __cacheid_vipt_nonaliasing_prev7(val) ((val & (15 << 25 | 1 << 23)) == (14 << 25)) +#define __cacheid_vipt_aliasing_prev7(val) ((val & (15 << 25 | 1 << 23)) == (14 << 25 | 1 << 23)) + +#define __cacheid_vivt(val) (__cacheid_type_v7(val) ? 0 : __cacheid_vivt_prev7(val)) +#define __cacheid_vipt(val) (__cacheid_type_v7(val) ? 1 : __cacheid_vipt_prev7(val)) +#define __cacheid_vipt_nonaliasing(val) (__cacheid_type_v7(val) ? 1 : __cacheid_vipt_nonaliasing_prev7(val)) +#define __cacheid_vipt_aliasing(val) (__cacheid_type_v7(val) ? 0 : __cacheid_vipt_aliasing_prev7(val)) +#define __cacheid_vivt_asid_tagged_instr(val) (__cacheid_type_v7(val) ? ((val & (3 << 14)) == (1 << 14)) : 0) + +#if defined(CONFIG_CPU_CACHE_VIVT) && !defined(CONFIG_CPU_CACHE_VIPT) +/* + * VIVT caches only + */ +#define cache_is_vivt() 1 +#define cache_is_vipt() 0 +#define cache_is_vipt_nonaliasing() 0 +#define cache_is_vipt_aliasing() 0 +#define icache_is_vivt_asid_tagged() 0 + +#elif !defined(CONFIG_CPU_CACHE_VIVT) && defined(CONFIG_CPU_CACHE_VIPT) +/* + * VIPT caches only + */ +#define cache_is_vivt() 0 +#define cache_is_vipt() 1 +#define cache_is_vipt_nonaliasing() \ + ({ \ + unsigned int __val = read_cpuid_cachetype(); \ + __cacheid_vipt_nonaliasing(__val); \ + }) + +#define cache_is_vipt_aliasing() \ + ({ \ + unsigned int __val = read_cpuid_cachetype(); \ + __cacheid_vipt_aliasing(__val); \ + }) + +#define icache_is_vivt_asid_tagged() \ + ({ \ + unsigned int __val = read_cpuid_cachetype(); \ + __cacheid_vivt_asid_tagged_instr(__val); \ + }) + +#else +/* + * VIVT or VIPT caches. Note that this is unreliable since ARM926 + * and V6 CPUs satisfy the "(val & (15 << 25)) == (14 << 25)" test. + * There's no way to tell from the CacheType register what type (!) + * the cache is. + */ +#define cache_is_vivt() \ + ({ \ + unsigned int __val = read_cpuid_cachetype(); \ + (!__cacheid_present(__val)) || __cacheid_vivt(__val); \ + }) + +#define cache_is_vipt() \ + ({ \ + unsigned int __val = read_cpuid_cachetype(); \ + __cacheid_present(__val) && __cacheid_vipt(__val); \ + }) + +#define cache_is_vipt_nonaliasing() \ + ({ \ + unsigned int __val = read_cpuid_cachetype(); \ + __cacheid_present(__val) && \ + __cacheid_vipt_nonaliasing(__val); \ + }) + +#define cache_is_vipt_aliasing() \ + ({ \ + unsigned int __val = read_cpuid_cachetype(); \ + __cacheid_present(__val) && \ + __cacheid_vipt_aliasing(__val); \ + }) + +#define icache_is_vivt_asid_tagged() \ + ({ \ + unsigned int __val = read_cpuid_cachetype(); \ + __cacheid_present(__val) && \ + __cacheid_vivt_asid_tagged_instr(__val); \ + }) + +#endif + +#endif diff --git a/arch/arm/include/asm/cputype.h b/arch/arm/include/asm/cputype.h new file mode 100644 index 0000000..7b9d27e --- /dev/null +++ b/arch/arm/include/asm/cputype.h @@ -0,0 +1,64 @@ +#ifndef __ASM_ARM_CPUTYPE_H +#define __ASM_ARM_CPUTYPE_H + +#include + +#define CPUID_ID 0 +#define CPUID_CACHETYPE 1 +#define CPUID_TCM 2 +#define CPUID_TLBTYPE 3 + +#ifdef CONFIG_CPU_CP15 +#define read_cpuid(reg) \ + ({ \ + unsigned int __val; \ + asm("mrc p15, 0, %0, c0, c0, " __stringify(reg) \ + : "=r" (__val) \ + : \ + : "cc"); \ + __val; \ + }) +#else +extern unsigned int processor_id; +#define read_cpuid(reg) (processor_id) +#endif + +/* + * The CPU ID never changes at run time, so we might as well tell the + * compiler that it's constant. Use this function to read the CPU ID + * rather than directly reading processor_id or read_cpuid() directly. + */ +static inline unsigned int __attribute_const__ read_cpuid_id(void) +{ + return read_cpuid(CPUID_ID); +} + +static inline unsigned int __attribute_const__ read_cpuid_cachetype(void) +{ + return read_cpuid(CPUID_CACHETYPE); +} + +/* + * Intel's XScale3 core supports some v6 features (supersections, L2) + * but advertises itself as v5 as it does not support the v6 ISA. For + * this reason, we need a way to explicitly test for this type of CPU. + */ +#ifndef CONFIG_CPU_XSC3 +#define cpu_is_xsc3() 0 +#else +static inline int cpu_is_xsc3(void) +{ + if ((read_cpuid_id() & 0xffffe000) == 0x69056000) + return 1; + + return 0; +} +#endif + +#if !defined(CONFIG_CPU_XSCALE) && !defined(CONFIG_CPU_XSC3) +#define cpu_is_xscale() 0 +#else +#define cpu_is_xscale() 1 +#endif + +#endif diff --git a/arch/arm/include/asm/futex.h b/arch/arm/include/asm/futex.h index 6a332a9..9ee743b 100644 --- a/arch/arm/include/asm/futex.h +++ b/arch/arm/include/asm/futex.h @@ -1,6 +1,124 @@ -#ifndef _ASM_FUTEX_H -#define _ASM_FUTEX_H +#ifndef _ASM_ARM_FUTEX_H +#define _ASM_ARM_FUTEX_H + +#ifdef __KERNEL__ + +#ifdef CONFIG_SMP #include -#endif +#else /* !SMP, we can work around lack of atomic ops by disabling preemption */ + +#include +#include +#include +#include + +#define __futex_atomic_op(insn, ret, oldval, uaddr, oparg) \ + __asm__ __volatile__( \ + "1: ldrt %1, [%2]\n" \ + " " insn "\n" \ + "2: strt %0, [%2]\n" \ + " mov %0, #0\n" \ + "3:\n" \ + " .section __ex_table,\"a\"\n" \ + " .align 3\n" \ + " .long 1b, 4f, 2b, 4f\n" \ + " .previous\n" \ + " .section .fixup,\"ax\"\n" \ + "4: mov %0, %4\n" \ + " b 3b\n" \ + " .previous" \ + : "=&r" (ret), "=&r" (oldval) \ + : "r" (uaddr), "r" (oparg), "Ir" (-EFAULT) \ + : "cc", "memory") + +static inline int +futex_atomic_op_inuser (int encoded_op, int __user *uaddr) +{ + int op = (encoded_op >> 28) & 7; + int cmp = (encoded_op >> 24) & 15; + int oparg = (encoded_op << 8) >> 20; + int cmparg = (encoded_op << 20) >> 20; + int oldval = 0, ret; + + if (encoded_op & (FUTEX_OP_OPARG_SHIFT << 28)) + oparg = 1 << oparg; + + if (!access_ok(VERIFY_WRITE, uaddr, sizeof(int))) + return -EFAULT; + + pagefault_disable(); /* implies preempt_disable() */ + + switch (op) { + case FUTEX_OP_SET: + __futex_atomic_op("mov %0, %3", ret, oldval, uaddr, oparg); + break; + case FUTEX_OP_ADD: + __futex_atomic_op("add %0, %1, %3", ret, oldval, uaddr, oparg); + break; + case FUTEX_OP_OR: + __futex_atomic_op("orr %0, %1, %3", ret, oldval, uaddr, oparg); + break; + case FUTEX_OP_ANDN: + __futex_atomic_op("and %0, %1, %3", ret, oldval, uaddr, ~oparg); + break; + case FUTEX_OP_XOR: + __futex_atomic_op("eor %0, %1, %3", ret, oldval, uaddr, oparg); + break; + default: + ret = -ENOSYS; + } + + pagefault_enable(); /* subsumes preempt_enable() */ + + if (!ret) { + switch (cmp) { + case FUTEX_OP_CMP_EQ: ret = (oldval == cmparg); break; + case FUTEX_OP_CMP_NE: ret = (oldval != cmparg); break; + case FUTEX_OP_CMP_LT: ret = (oldval < cmparg); break; + case FUTEX_OP_CMP_GE: ret = (oldval >= cmparg); break; + case FUTEX_OP_CMP_LE: ret = (oldval <= cmparg); break; + case FUTEX_OP_CMP_GT: ret = (oldval > cmparg); break; + default: ret = -ENOSYS; + } + } + return ret; +} + +static inline int +futex_atomic_cmpxchg_inatomic(int __user *uaddr, int oldval, int newval) +{ + int val; + + if (!access_ok(VERIFY_WRITE, uaddr, sizeof(int))) + return -EFAULT; + + pagefault_disable(); /* implies preempt_disable() */ + + __asm__ __volatile__("@futex_atomic_cmpxchg_inatomic\n" + "1: ldrt %0, [%3]\n" + " teq %0, %1\n" + "2: streqt %2, [%3]\n" + "3:\n" + " .section __ex_table,\"a\"\n" + " .align 3\n" + " .long 1b, 4f, 2b, 4f\n" + " .previous\n" + " .section .fixup,\"ax\"\n" + "4: mov %0, %4\n" + " b 3b\n" + " .previous" + : "=&r" (val) + : "r" (oldval), "r" (newval), "r" (uaddr), "Ir" (-EFAULT) + : "cc", "memory"); + + pagefault_enable(); /* subsumes preempt_enable() */ + + return val; +} + +#endif /* !SMP */ + +#endif /* __KERNEL__ */ +#endif /* _ASM_ARM_FUTEX_H */ diff --git a/arch/arm/include/asm/kprobes.h b/arch/arm/include/asm/kprobes.h index a5d0d99..bb8a19b 100644 --- a/arch/arm/include/asm/kprobes.h +++ b/arch/arm/include/asm/kprobes.h @@ -61,7 +61,6 @@ struct kprobe_ctlblk { void arch_remove_kprobe(struct kprobe *); void kretprobe_trampoline(void); -int kprobe_trap_handler(struct pt_regs *regs, unsigned int instr); int kprobe_fault_handler(struct pt_regs *regs, unsigned int fsr); int kprobe_exceptions_notify(struct notifier_block *self, unsigned long val, void *data); diff --git a/arch/arm/include/asm/memory.h b/arch/arm/include/asm/memory.h index bf7c737..7e8d22f 100644 --- a/arch/arm/include/asm/memory.h +++ b/arch/arm/include/asm/memory.h @@ -13,30 +13,27 @@ #ifndef __ASM_ARM_MEMORY_H #define __ASM_ARM_MEMORY_H +#include +#include +#include +#include + /* * Allow for constants defined here to be used from assembly code * by prepending the UL suffix only with actual C code compilation. */ -#ifndef __ASSEMBLY__ -#define UL(x) (x##UL) -#else -#define UL(x) (x) -#endif - -#include -#include -#include +#define UL(x) _AC(x, UL) #ifdef CONFIG_MMU -#ifndef TASK_SIZE /* + * PAGE_OFFSET - the virtual address of the start of the kernel image * TASK_SIZE - the maximum size of a user space task. * TASK_UNMAPPED_BASE - the lower boundary of the mmap VM area */ -#define TASK_SIZE UL(0xbf000000) -#define TASK_UNMAPPED_BASE UL(0x40000000) -#endif +#define PAGE_OFFSET UL(CONFIG_PAGE_OFFSET) +#define TASK_SIZE (UL(CONFIG_PAGE_OFFSET) - UL(0x01000000)) +#define TASK_UNMAPPED_BASE (UL(CONFIG_PAGE_OFFSET) / 3) /* * The maximum size of a 26-bit user space task. @@ -44,13 +41,6 @@ #define TASK_SIZE_26 UL(0x04000000) /* - * Page offset: 3GB - */ -#ifndef PAGE_OFFSET -#define PAGE_OFFSET UL(0xc0000000) -#endif - -/* * The module space lives between the addresses given by TASK_SIZE * and PAGE_OFFSET - it must be within 32MB of the kernel text. */ diff --git a/arch/arm/include/asm/mmu_context.h b/arch/arm/include/asm/mmu_context.h index a301e44..0559f37 100644 --- a/arch/arm/include/asm/mmu_context.h +++ b/arch/arm/include/asm/mmu_context.h @@ -15,6 +15,7 @@ #include #include +#include #include #include diff --git a/arch/arm/include/asm/statfs.h b/arch/arm/include/asm/statfs.h index a02e6a8..079447c 100644 --- a/arch/arm/include/asm/statfs.h +++ b/arch/arm/include/asm/statfs.h @@ -1,42 +1,12 @@ #ifndef _ASMARM_STATFS_H #define _ASMARM_STATFS_H -#ifndef __KERNEL_STRICT_NAMES -# include -typedef __kernel_fsid_t fsid_t; -#endif - -struct statfs { - __u32 f_type; - __u32 f_bsize; - __u32 f_blocks; - __u32 f_bfree; - __u32 f_bavail; - __u32 f_files; - __u32 f_ffree; - __kernel_fsid_t f_fsid; - __u32 f_namelen; - __u32 f_frsize; - __u32 f_spare[5]; -}; - /* * With EABI there is 4 bytes of padding added to this structure. * Let's pack it so the padding goes away to simplify dual ABI support. * Note that user space does NOT have to pack this structure. */ -struct statfs64 { - __u32 f_type; - __u32 f_bsize; - __u64 f_blocks; - __u64 f_bfree; - __u64 f_bavail; - __u64 f_files; - __u64 f_ffree; - __kernel_fsid_t f_fsid; - __u32 f_namelen; - __u32 f_frsize; - __u32 f_spare[5]; -} __attribute__ ((packed,aligned(4))); +#define ARCH_PACK_STATFS64 __attribute__((packed,aligned(4))) +#include #endif diff --git a/arch/arm/include/asm/system.h b/arch/arm/include/asm/system.h index 514af79..7aad784 100644 --- a/arch/arm/include/asm/system.h +++ b/arch/arm/include/asm/system.h @@ -43,11 +43,6 @@ #define CR_XP (1 << 23) /* Extended page tables */ #define CR_VE (1 << 24) /* Vectored interrupts */ -#define CPUID_ID 0 -#define CPUID_CACHETYPE 1 -#define CPUID_TCM 2 -#define CPUID_TLBTYPE 3 - /* * This is used to ensure the compiler did actually allocate the register we * asked it for some inline assembly sequences. Apparently we can't trust @@ -61,36 +56,8 @@ #ifndef __ASSEMBLY__ #include -#include #include -#ifdef CONFIG_CPU_CP15 -#define read_cpuid(reg) \ - ({ \ - unsigned int __val; \ - asm("mrc p15, 0, %0, c0, c0, " __stringify(reg) \ - : "=r" (__val) \ - : \ - : "cc"); \ - __val; \ - }) -#else -extern unsigned int processor_id; -#define read_cpuid(reg) (processor_id) -#endif - -/* - * The CPU ID never changes at run time, so we might as well tell the - * compiler that it's constant. Use this function to read the CPU ID - * rather than directly reading processor_id or read_cpuid() directly. - */ -static inline unsigned int read_cpuid_id(void) __attribute_const__; - -static inline unsigned int read_cpuid_id(void) -{ - return read_cpuid(CPUID_ID); -} - #define __exception __attribute__((section(".exception.text"))) struct thread_info; @@ -131,31 +98,6 @@ extern void cpu_init(void); void arm_machine_restart(char mode); extern void (*arm_pm_restart)(char str); -/* - * Intel's XScale3 core supports some v6 features (supersections, L2) - * but advertises itself as v5 as it does not support the v6 ISA. For - * this reason, we need a way to explicitly test for this type of CPU. - */ -#ifndef CONFIG_CPU_XSC3 -#define cpu_is_xsc3() 0 -#else -static inline int cpu_is_xsc3(void) -{ - extern unsigned int processor_id; - - if ((processor_id & 0xffffe000) == 0x69056000) - return 1; - - return 0; -} -#endif - -#if !defined(CONFIG_CPU_XSCALE) && !defined(CONFIG_CPU_XSC3) -#define cpu_is_xscale() 0 -#else -#define cpu_is_xscale() 1 -#endif - #define UDBG_UNDEFINED (1 << 0) #define UDBG_SYSCALL (1 << 1) #define UDBG_BADABORT (1 << 2) diff --git a/arch/arm/include/asm/uaccess.h b/arch/arm/include/asm/uaccess.h index d0f51ff..e98ec60 100644 --- a/arch/arm/include/asm/uaccess.h +++ b/arch/arm/include/asm/uaccess.h @@ -225,7 +225,7 @@ do { \ #define __get_user_asm_byte(x,addr,err) \ __asm__ __volatile__( \ - "1: ldrbt %1,[%2],#0\n" \ + "1: ldrbt %1,[%2]\n" \ "2:\n" \ " .section .fixup,\"ax\"\n" \ " .align 2\n" \ @@ -261,7 +261,7 @@ do { \ #define __get_user_asm_word(x,addr,err) \ __asm__ __volatile__( \ - "1: ldrt %1,[%2],#0\n" \ + "1: ldrt %1,[%2]\n" \ "2:\n" \ " .section .fixup,\"ax\"\n" \ " .align 2\n" \ @@ -306,7 +306,7 @@ do { \ #define __put_user_asm_byte(x,__pu_addr,err) \ __asm__ __volatile__( \ - "1: strbt %1,[%2],#0\n" \ + "1: strbt %1,[%2]\n" \ "2:\n" \ " .section .fixup,\"ax\"\n" \ " .align 2\n" \ @@ -339,7 +339,7 @@ do { \ #define __put_user_asm_word(x,__pu_addr,err) \ __asm__ __volatile__( \ - "1: strt %1,[%2],#0\n" \ + "1: strt %1,[%2]\n" \ "2:\n" \ " .section .fixup,\"ax\"\n" \ " .align 2\n" \ @@ -365,7 +365,7 @@ do { \ #define __put_user_asm_dword(x,__pu_addr,err) \ __asm__ __volatile__( \ "1: strt " __reg_oper1 ", [%1], #4\n" \ - "2: strt " __reg_oper0 ", [%1], #0\n" \ + "2: strt " __reg_oper0 ", [%1]\n" \ "3:\n" \ " .section .fixup,\"ax\"\n" \ " .align 2\n" \ diff --git a/arch/arm/kernel/debug.S b/arch/arm/kernel/debug.S index 9550ff0..f53c582 100644 --- a/arch/arm/kernel/debug.S +++ b/arch/arm/kernel/debug.S @@ -89,10 +89,12 @@ ENTRY(printhex8) mov r1, #8 b printhex +ENDPROC(printhex8) ENTRY(printhex4) mov r1, #4 b printhex +ENDPROC(printhex4) ENTRY(printhex2) mov r1, #2 @@ -110,6 +112,7 @@ printhex: adr r2, hexbuf bne 1b mov r0, r2 b printascii +ENDPROC(printhex2) .ltorg @@ -127,11 +130,13 @@ ENTRY(printascii) teqne r1, #0 bne 1b mov pc, lr +ENDPROC(printascii) ENTRY(printch) addruart r3 mov r1, r0 mov r0, #0 b 1b +ENDPROC(printch) hexbuf: .space 16 diff --git a/arch/arm/kernel/entry-armv.S b/arch/arm/kernel/entry-armv.S index 617e509..77b0474 100644 --- a/arch/arm/kernel/entry-armv.S +++ b/arch/arm/kernel/entry-armv.S @@ -76,14 +76,17 @@ __pabt_invalid: inv_entry BAD_PREFETCH b common_invalid +ENDPROC(__pabt_invalid) __dabt_invalid: inv_entry BAD_DATA b common_invalid +ENDPROC(__dabt_invalid) __irq_invalid: inv_entry BAD_IRQ b common_invalid +ENDPROC(__irq_invalid) __und_invalid: inv_entry BAD_UNDEFINSTR @@ -107,6 +110,7 @@ common_invalid: mov r0, sp b bad_mode +ENDPROC(__und_invalid) /* * SVC mode handlers @@ -192,6 +196,7 @@ __dabt_svc: ldr r0, [sp, #S_PSR] msr spsr_cxsf, r0 ldmia sp, {r0 - pc}^ @ load r0 - pc, cpsr +ENDPROC(__dabt_svc) .align 5 __irq_svc: @@ -223,6 +228,7 @@ __irq_svc: bleq trace_hardirqs_on #endif ldmia sp, {r0 - pc}^ @ load r0 - pc, cpsr +ENDPROC(__irq_svc) .ltorg @@ -272,6 +278,7 @@ __und_svc: ldr lr, [sp, #S_PSR] @ Get SVC cpsr msr spsr_cxsf, lr ldmia sp, {r0 - pc}^ @ Restore SVC registers +ENDPROC(__und_svc) .align 5 __pabt_svc: @@ -313,6 +320,7 @@ __pabt_svc: ldr r0, [sp, #S_PSR] msr spsr_cxsf, r0 ldmia sp, {r0 - pc}^ @ load r0 - pc, cpsr +ENDPROC(__pabt_svc) .align 5 .LCcralign: @@ -412,6 +420,7 @@ __dabt_usr: mov r2, sp adr lr, ret_from_exception b do_DataAbort +ENDPROC(__dabt_usr) .align 5 __irq_usr: @@ -441,6 +450,7 @@ __irq_usr: mov why, #0 b ret_to_user +ENDPROC(__irq_usr) .ltorg @@ -474,6 +484,7 @@ __und_usr: #else b __und_usr_unknown #endif +ENDPROC(__und_usr) @ @ fallthrough to call_fpe @@ -642,6 +653,7 @@ __und_usr_unknown: mov r0, sp adr lr, ret_from_exception b do_undefinstr +ENDPROC(__und_usr_unknown) .align 5 __pabt_usr: @@ -666,6 +678,8 @@ ENTRY(ret_from_exception) get_thread_info tsk mov why, #0 b ret_to_user +ENDPROC(__pabt_usr) +ENDPROC(ret_from_exception) /* * Register switch for ARMv3 and ARMv4 processors @@ -702,6 +716,7 @@ ENTRY(__switch_to) bl atomic_notifier_call_chain mov r0, r5 ldmia r4, {r4 - sl, fp, sp, pc} @ Load all regs saved previously +ENDPROC(__switch_to) __INIT @@ -1029,6 +1044,7 @@ vector_\name: mov r0, sp ldr lr, [pc, lr, lsl #2] movs pc, lr @ branch to handler in SVC mode +ENDPROC(vector_\name) .endm .globl __stubs_start diff --git a/arch/arm/kernel/entry-common.S b/arch/arm/kernel/entry-common.S index 060d7e2..3aa14dc 100644 --- a/arch/arm/kernel/entry-common.S +++ b/arch/arm/kernel/entry-common.S @@ -77,6 +77,7 @@ no_work_pending: mov r0, r0 add sp, sp, #S_FRAME_SIZE - S_PC movs pc, lr @ return & move spsr_svc into cpsr +ENDPROC(ret_to_user) /* * This is how we return from a fork. @@ -92,7 +93,7 @@ ENTRY(ret_from_fork) mov r0, #1 @ trace exit [IP = 1] bl syscall_trace b ret_slow_syscall - +ENDPROC(ret_from_fork) .equ NR_syscalls,0 #define CALL(x) .equ NR_syscalls,NR_syscalls+1 @@ -269,6 +270,7 @@ ENTRY(vector_swi) eor r0, scno, #__NR_SYSCALL_BASE @ put OS number back bcs arm_syscall b sys_ni_syscall @ not private func +ENDPROC(vector_swi) /* * This is the really slow path. We're going to be doing @@ -326,7 +328,6 @@ ENTRY(sys_call_table) */ @ r0 = syscall number @ r8 = syscall table - .type sys_syscall, #function sys_syscall: bic scno, r0, #__NR_OABI_SYSCALL_BASE cmp scno, #__NR_syscall - __NR_SYSCALL_BASE @@ -338,53 +339,65 @@ sys_syscall: movlo r3, r4 ldrlo pc, [tbl, scno, lsl #2] b sys_ni_syscall +ENDPROC(sys_syscall) sys_fork_wrapper: add r0, sp, #S_OFF b sys_fork +ENDPROC(sys_fork_wrapper) sys_vfork_wrapper: add r0, sp, #S_OFF b sys_vfork +ENDPROC(sys_vfork_wrapper) sys_execve_wrapper: add r3, sp, #S_OFF b sys_execve +ENDPROC(sys_execve_wrapper) sys_clone_wrapper: add ip, sp, #S_OFF str ip, [sp, #4] b sys_clone +ENDPROC(sys_clone_wrapper) sys_sigsuspend_wrapper: add r3, sp, #S_OFF b sys_sigsuspend +ENDPROC(sys_sigsuspend_wrapper) sys_rt_sigsuspend_wrapper: add r2, sp, #S_OFF b sys_rt_sigsuspend +ENDPROC(sys_rt_sigsuspend_wrapper) sys_sigreturn_wrapper: add r0, sp, #S_OFF b sys_sigreturn +ENDPROC(sys_sigreturn_wrapper) sys_rt_sigreturn_wrapper: add r0, sp, #S_OFF b sys_rt_sigreturn +ENDPROC(sys_rt_sigreturn_wrapper) sys_sigaltstack_wrapper: ldr r2, [sp, #S_OFF + S_SP] b do_sigaltstack +ENDPROC(sys_sigaltstack_wrapper) sys_statfs64_wrapper: teq r1, #88 moveq r1, #84 b sys_statfs64 +ENDPROC(sys_statfs64_wrapper) sys_fstatfs64_wrapper: teq r1, #88 moveq r1, #84 b sys_fstatfs64 +ENDPROC(sys_fstatfs64_wrapper) /* * Note: off_4k (r5) is always units of 4K. If we can't do the requested @@ -402,11 +415,14 @@ sys_mmap2: str r5, [sp, #4] b do_mmap2 #endif +ENDPROC(sys_mmap2) ENTRY(pabort_ifar) mrc p15, 0, r0, cr6, cr0, 2 ENTRY(pabort_noifar) mov pc, lr +ENDPROC(pabort_ifar) +ENDPROC(pabort_noifar) #ifdef CONFIG_OABI_COMPAT @@ -417,26 +433,31 @@ ENTRY(pabort_noifar) sys_oabi_pread64: stmia sp, {r3, r4} b sys_pread64 +ENDPROC(sys_oabi_pread64) sys_oabi_pwrite64: stmia sp, {r3, r4} b sys_pwrite64 +ENDPROC(sys_oabi_pwrite64) sys_oabi_truncate64: mov r3, r2 mov r2, r1 b sys_truncate64 +ENDPROC(sys_oabi_truncate64) sys_oabi_ftruncate64: mov r3, r2 mov r2, r1 b sys_ftruncate64 +ENDPROC(sys_oabi_ftruncate64) sys_oabi_readahead: str r3, [sp] mov r3, r2 mov r2, r1 b sys_readahead +ENDPROC(sys_oabi_readahead) /* * Let's declare a second syscall table for old ABI binaries diff --git a/arch/arm/kernel/head-common.S b/arch/arm/kernel/head-common.S index 1c3c6ea..bde52df 100644 --- a/arch/arm/kernel/head-common.S +++ b/arch/arm/kernel/head-common.S @@ -36,7 +36,6 @@ __switch_data: * r2 = atags pointer * r9 = processor ID */ - .type __mmap_switched, %function __mmap_switched: adr r3, __switch_data + 4 @@ -59,6 +58,7 @@ __mmap_switched: bic r4, r0, #CR_A @ Clear 'A' bit stmia r7, {r0, r4} @ Save control register values b start_kernel +ENDPROC(__mmap_switched) /* * Exception handling. Something went wrong and we can't proceed. We @@ -69,8 +69,6 @@ __mmap_switched: * and hope for the best (useful if bootloader fails to pass a proper * machine ID for example). */ - - .type __error_p, %function __error_p: #ifdef CONFIG_DEBUG_LL adr r0, str_p1 @@ -84,8 +82,8 @@ str_p1: .asciz "\nError: unrecognized/unsupported processor variant (0x" str_p2: .asciz ").\n" .align #endif +ENDPROC(__error_p) - .type __error_a, %function __error_a: #ifdef CONFIG_DEBUG_LL mov r4, r1 @ preserve machine ID @@ -115,13 +113,14 @@ __error_a: adr r0, str_a3 bl printascii b __error +ENDPROC(__error_a) + str_a1: .asciz "\nError: unrecognized/unsupported machine ID (r1 = 0x" str_a2: .asciz ").\n\nAvailable machine support:\n\nID (hex)\tNAME\n" str_a3: .asciz "\nPlease check your kernel config and/or bootloader.\n" .align #endif - .type __error, %function __error: #ifdef CONFIG_ARCH_RPC /* @@ -138,6 +137,7 @@ __error: #endif 1: mov r0, r0 b 1b +ENDPROC(__error) /* @@ -153,7 +153,6 @@ __error: * r5 = proc_info pointer in physical address space * r9 = cpuid (preserved) */ - .type __lookup_processor_type, %function __lookup_processor_type: adr r3, 3f ldmda r3, {r5 - r7} @@ -169,6 +168,7 @@ __lookup_processor_type: blo 1b mov r5, #0 @ unknown processor 2: mov pc, lr +ENDPROC(__lookup_processor_type) /* * This provides a C-API version of the above function. @@ -179,6 +179,7 @@ ENTRY(lookup_processor_type) bl __lookup_processor_type mov r0, r5 ldmfd sp!, {r4 - r7, r9, pc} +ENDPROC(lookup_processor_type) /* * Look in and arch/arm/kernel/arch.[ch] for @@ -201,7 +202,6 @@ ENTRY(lookup_processor_type) * r3, r4, r6 corrupted * r5 = mach_info pointer in physical address space */ - .type __lookup_machine_type, %function __lookup_machine_type: adr r3, 3b ldmia r3, {r4, r5, r6} @@ -216,6 +216,7 @@ __lookup_machine_type: blo 1b mov r5, #0 @ unknown machine 2: mov pc, lr +ENDPROC(__lookup_machine_type) /* * This provides a C-API version of the above function. @@ -226,6 +227,7 @@ ENTRY(lookup_machine_type) bl __lookup_machine_type mov r0, r5 ldmfd sp!, {r4 - r6, pc} +ENDPROC(lookup_machine_type) /* Determine validity of the r2 atags pointer. The heuristic requires * that the pointer be aligned, in the first 16k of physical RAM and @@ -239,8 +241,6 @@ ENTRY(lookup_machine_type) * r2 either valid atags pointer, or zero * r5, r6 corrupted */ - - .type __vet_atags, %function __vet_atags: tst r2, #0x3 @ aligned? bne 1f @@ -257,3 +257,4 @@ __vet_atags: 1: mov r2, #0 mov pc, lr +ENDPROC(__vet_atags) diff --git a/arch/arm/kernel/head-nommu.S b/arch/arm/kernel/head-nommu.S index 27329bd..cc87e17 100644 --- a/arch/arm/kernel/head-nommu.S +++ b/arch/arm/kernel/head-nommu.S @@ -33,7 +33,6 @@ * */ .section ".text.head", "ax" - .type stext, %function ENTRY(stext) msr cpsr_c, #PSR_F_BIT | PSR_I_BIT | SVC_MODE @ ensure svc mode @ and irqs disabled @@ -53,11 +52,11 @@ ENTRY(stext) @ the initialization is done adr lr, __after_proc_init @ return (PIC) address add pc, r10, #PROCINFO_INITFUNC +ENDPROC(stext) /* * Set the Control Register and Read the process ID. */ - .type __after_proc_init, %function __after_proc_init: #ifdef CONFIG_CPU_CP15 mrc p15, 0, r0, c1, c0, 0 @ read control reg @@ -85,6 +84,7 @@ __after_proc_init: mov pc, r13 @ clear the BSS and jump @ to start_kernel +ENDPROC(__after_proc_init) .ltorg #include "head-common.S" diff --git a/arch/arm/kernel/head.S b/arch/arm/kernel/head.S index bff4c6e..21e17dc 100644 --- a/arch/arm/kernel/head.S +++ b/arch/arm/kernel/head.S @@ -75,7 +75,6 @@ * circumstances, zImage) is for. */ .section ".text.head", "ax" - .type stext, %function ENTRY(stext) msr cpsr_c, #PSR_F_BIT | PSR_I_BIT | SVC_MODE @ ensure svc mode @ and irqs disabled @@ -100,9 +99,9 @@ ENTRY(stext) @ mmu has been enabled adr lr, __enable_mmu @ return (PIC) address add pc, r10, #PROCINFO_INITFUNC +ENDPROC(stext) #if defined(CONFIG_SMP) - .type secondary_startup, #function ENTRY(secondary_startup) /* * Common entry point for secondary CPUs. @@ -128,6 +127,7 @@ ENTRY(secondary_startup) adr lr, __enable_mmu @ return address add pc, r10, #PROCINFO_INITFUNC @ initialise processor @ (return control reg) +ENDPROC(secondary_startup) /* * r6 = &secondary_data @@ -136,6 +136,7 @@ ENTRY(__secondary_switched) ldr sp, [r7, #4] @ get secondary_data.stack mov fp, #0 b secondary_start_kernel +ENDPROC(__secondary_switched) .type __secondary_data, %object __secondary_data: @@ -151,7 +152,6 @@ __secondary_data: * this is just loading the page table pointer and domain access * registers. */ - .type __enable_mmu, %function __enable_mmu: #ifdef CONFIG_ALIGNMENT_TRAP orr r0, r0, #CR_A @@ -174,6 +174,7 @@ __enable_mmu: mcr p15, 0, r5, c3, c0, 0 @ load domain access register mcr p15, 0, r4, c2, c0, 0 @ load page table pointer b __turn_mmu_on +ENDPROC(__enable_mmu) /* * Enable the MMU. This completely changes the structure of the visible @@ -187,7 +188,6 @@ __enable_mmu: * other registers depend on the function called upon completion */ .align 5 - .type __turn_mmu_on, %function __turn_mmu_on: mov r0, r0 mcr p15, 0, r0, c1, c0, 0 @ write control reg @@ -195,7 +195,7 @@ __turn_mmu_on: mov r3, r3 mov r3, r3 mov pc, r13 - +ENDPROC(__turn_mmu_on) /* @@ -211,7 +211,6 @@ __turn_mmu_on: * r0, r3, r6, r7 corrupted * r4 = physical page table address */ - .type __create_page_tables, %function __create_page_tables: pgtbl r4 @ page table address @@ -325,6 +324,7 @@ __create_page_tables: #endif #endif mov pc, lr +ENDPROC(__create_page_tables) .ltorg #include "head-common.S" diff --git a/arch/arm/kernel/kprobes-decode.c b/arch/arm/kernel/kprobes-decode.c index b4565bb..da1f949 100644 --- a/arch/arm/kernel/kprobes-decode.c +++ b/arch/arm/kernel/kprobes-decode.c @@ -488,7 +488,7 @@ static void __kprobes simulate_ldm1stm1(struct kprobe *p, struct pt_regs *regs) if (!ubit) addr -= reg_count; - addr += (!pbit ^ !ubit); + addr += (!pbit == !ubit); reg_bit_vector = insn & 0xffff; while (reg_bit_vector) { @@ -503,7 +503,7 @@ static void __kprobes simulate_ldm1stm1(struct kprobe *p, struct pt_regs *regs) if (wbit) { if (!ubit) addr -= reg_count; - addr -= (!pbit ^ !ubit); + addr -= (!pbit == !ubit); regs->uregs[rn] = (long)addr; } } diff --git a/arch/arm/kernel/kprobes.c b/arch/arm/kernel/kprobes.c index d28513f..3f9abe0 100644 --- a/arch/arm/kernel/kprobes.c +++ b/arch/arm/kernel/kprobes.c @@ -200,9 +200,12 @@ void __kprobes kprobe_handler(struct pt_regs *regs) } } -int kprobe_trap_handler(struct pt_regs *regs, unsigned int instr) +static int __kprobes kprobe_trap_handler(struct pt_regs *regs, unsigned int instr) { + unsigned long flags; + local_irq_save(flags); kprobe_handler(regs); + local_irq_restore(flags); return 0; } diff --git a/arch/arm/kernel/setup.c b/arch/arm/kernel/setup.c index 2ca7038..e90422d 100644 --- a/arch/arm/kernel/setup.c +++ b/arch/arm/kernel/setup.c @@ -26,11 +26,13 @@ #include #include +#include #include #include #include #include #include +#include #include #include @@ -280,9 +282,9 @@ static inline void dump_cache(const char *prefix, int cpu, unsigned int cache) static void __init dump_cpu_info(int cpu) { - unsigned int info = read_cpuid(CPUID_CACHETYPE); + unsigned int info = read_cpuid_cachetype(); - if (info != processor_id) { + if (info != read_cpuid_id()) { printk("CPU%u: D %s %s cache\n", cpu, cache_is_vivt() ? "VIVT" : "VIPT", cache_types[CACHE_TYPE(info)]); if (CACHE_S(info)) { @@ -301,15 +303,15 @@ int cpu_architecture(void) { int cpu_arch; - if ((processor_id & 0x0008f000) == 0) { + if ((read_cpuid_id() & 0x0008f000) == 0) { cpu_arch = CPU_ARCH_UNKNOWN; - } else if ((processor_id & 0x0008f000) == 0x00007000) { - cpu_arch = (processor_id & (1 << 23)) ? CPU_ARCH_ARMv4T : CPU_ARCH_ARMv3; - } else if ((processor_id & 0x00080000) == 0x00000000) { - cpu_arch = (processor_id >> 16) & 7; + } else if ((read_cpuid_id() & 0x0008f000) == 0x00007000) { + cpu_arch = (read_cpuid_id() & (1 << 23)) ? CPU_ARCH_ARMv4T : CPU_ARCH_ARMv3; + } else if ((read_cpuid_id() & 0x00080000) == 0x00000000) { + cpu_arch = (read_cpuid_id() >> 16) & 7; if (cpu_arch) cpu_arch += CPU_ARCH_ARMv3; - } else if ((processor_id & 0x000f0000) == 0x000f0000) { + } else if ((read_cpuid_id() & 0x000f0000) == 0x000f0000) { unsigned int mmfr0; /* Revised CPUID format. Read the Memory Model Feature @@ -346,10 +348,10 @@ static void __init setup_processor(void) * types. The linker builds this table for us from the * entries in arch/arm/mm/proc-*.S */ - list = lookup_processor_type(processor_id); + list = lookup_processor_type(read_cpuid_id()); if (!list) { printk("CPU configuration botched (ID %08x), unable " - "to continue.\n", processor_id); + "to continue.\n", read_cpuid_id()); while (1); } @@ -369,7 +371,7 @@ static void __init setup_processor(void) #endif printk("CPU: %s [%08x] revision %d (ARMv%s), cr=%08lx\n", - cpu_name, processor_id, (int)processor_id & 15, + cpu_name, read_cpuid_id(), read_cpuid_id() & 15, proc_arch[cpu_architecture()], cr_alignment); sprintf(init_utsname()->machine, "%s%c", list->arch_name, ENDIANNESS); @@ -922,7 +924,7 @@ static int c_show(struct seq_file *m, void *v) int i; seq_printf(m, "Processor\t: %s rev %d (%s)\n", - cpu_name, (int)processor_id & 15, elf_platform); + cpu_name, read_cpuid_id() & 15, elf_platform); #if defined(CONFIG_SMP) for_each_online_cpu(i) { @@ -949,30 +951,30 @@ static int c_show(struct seq_file *m, void *v) if (elf_hwcap & (1 << i)) seq_printf(m, "%s ", hwcap_str[i]); - seq_printf(m, "\nCPU implementer\t: 0x%02x\n", processor_id >> 24); + seq_printf(m, "\nCPU implementer\t: 0x%02x\n", read_cpuid_id() >> 24); seq_printf(m, "CPU architecture: %s\n", proc_arch[cpu_architecture()]); - if ((processor_id & 0x0008f000) == 0x00000000) { + if ((read_cpuid_id() & 0x0008f000) == 0x00000000) { /* pre-ARM7 */ - seq_printf(m, "CPU part\t: %07x\n", processor_id >> 4); + seq_printf(m, "CPU part\t: %07x\n", read_cpuid_id() >> 4); } else { - if ((processor_id & 0x0008f000) == 0x00007000) { + if ((read_cpuid_id() & 0x0008f000) == 0x00007000) { /* ARM7 */ seq_printf(m, "CPU variant\t: 0x%02x\n", - (processor_id >> 16) & 127); + (read_cpuid_id() >> 16) & 127); } else { /* post-ARM7 */ seq_printf(m, "CPU variant\t: 0x%x\n", - (processor_id >> 20) & 15); + (read_cpuid_id() >> 20) & 15); } seq_printf(m, "CPU part\t: 0x%03x\n", - (processor_id >> 4) & 0xfff); + (read_cpuid_id() >> 4) & 0xfff); } - seq_printf(m, "CPU revision\t: %d\n", processor_id & 15); + seq_printf(m, "CPU revision\t: %d\n", read_cpuid_id() & 15); { - unsigned int cache_info = read_cpuid(CPUID_CACHETYPE); - if (cache_info != processor_id) { + unsigned int cache_info = read_cpuid_cachetype(); + if (cache_info != read_cpuid_id()) { seq_printf(m, "Cache type\t: %s\n" "Cache clean\t: %s\n" "Cache lockdown\t: %s\n" diff --git a/arch/arm/kernel/traps.c b/arch/arm/kernel/traps.c index 872f1f8..46e2c83 100644 --- a/arch/arm/kernel/traps.c +++ b/arch/arm/kernel/traps.c @@ -19,7 +19,6 @@ #include #include #include -#include #include #include @@ -328,17 +327,6 @@ asmlinkage void __exception do_undefinstr(struct pt_regs *regs) get_user(instr, (u32 __user *)pc); } -#ifdef CONFIG_KPROBES - /* - * It is possible to have recursive kprobes, so we can't call - * the kprobe trap handler with the undef_lock held. - */ - if (instr == KPROBE_BREAKPOINT_INSTRUCTION && !user_mode(regs)) { - kprobe_trap_handler(regs, instr); - return; - } -#endif - if (call_undef_hook(regs, instr) == 0) return; diff --git a/arch/arm/lib/ashldi3.S b/arch/arm/lib/ashldi3.S index 55e57a1..1154d92 100644 --- a/arch/arm/lib/ashldi3.S +++ b/arch/arm/lib/ashldi3.S @@ -47,3 +47,5 @@ ENTRY(__aeabi_llsl) mov al, al, lsl r2 mov pc, lr +ENDPROC(__ashldi3) +ENDPROC(__aeabi_llsl) diff --git a/arch/arm/lib/ashrdi3.S b/arch/arm/lib/ashrdi3.S index 0b31398..9f8b355 100644 --- a/arch/arm/lib/ashrdi3.S +++ b/arch/arm/lib/ashrdi3.S @@ -47,3 +47,5 @@ ENTRY(__aeabi_lasr) mov ah, ah, asr r2 mov pc, lr +ENDPROC(__ashrdi3) +ENDPROC(__aeabi_lasr) diff --git a/arch/arm/lib/backtrace.S b/arch/arm/lib/backtrace.S index 84dc890..b0951d0 100644 --- a/arch/arm/lib/backtrace.S +++ b/arch/arm/lib/backtrace.S @@ -30,6 +30,8 @@ ENTRY(c_backtrace) #if !defined(CONFIG_FRAME_POINTER) || !defined(CONFIG_PRINTK) mov pc, lr +ENDPROC(__backtrace) +ENDPROC(c_backtrace) #else stmfd sp!, {r4 - r8, lr} @ Save an extra register so we have a location... movs frame, r0 @ if frame pointer is zero @@ -103,6 +105,8 @@ for_each_frame: tst frame, mask @ Check for address exceptions mov r1, frame bl printk no_frame: ldmfd sp!, {r4 - r8, pc} +ENDPROC(__backtrace) +ENDPROC(c_backtrace) .section __ex_table,"a" .align 3 diff --git a/arch/arm/lib/changebit.S b/arch/arm/lib/changebit.S index 389567c..80f3115 100644 --- a/arch/arm/lib/changebit.S +++ b/arch/arm/lib/changebit.S @@ -19,3 +19,5 @@ ENTRY(_change_bit_be) eor r0, r0, #0x18 @ big endian byte ordering ENTRY(_change_bit_le) bitop eor +ENDPROC(_change_bit_be) +ENDPROC(_change_bit_le) diff --git a/arch/arm/lib/clear_user.S b/arch/arm/lib/clear_user.S index ecb28dc..4d6bc71 100644 --- a/arch/arm/lib/clear_user.S +++ b/arch/arm/lib/clear_user.S @@ -41,9 +41,10 @@ USER( strplt r2, [r0], #4) USER( strnebt r2, [r0], #1) USER( strnebt r2, [r0], #1) tst r1, #1 @ x1 x0 x1 x0 x1 x0 x1 -USER( strnebt r2, [r0], #1) +USER( strnebt r2, [r0]) mov r0, #0 ldmfd sp!, {r1, pc} +ENDPROC(__clear_user) .section .fixup,"ax" .align 0 diff --git a/arch/arm/lib/clearbit.S b/arch/arm/lib/clearbit.S index 3475165..1a63e43 100644 --- a/arch/arm/lib/clearbit.S +++ b/arch/arm/lib/clearbit.S @@ -20,3 +20,5 @@ ENTRY(_clear_bit_be) eor r0, r0, #0x18 @ big endian byte ordering ENTRY(_clear_bit_le) bitop bic +ENDPROC(_clear_bit_be) +ENDPROC(_clear_bit_le) diff --git a/arch/arm/lib/copy_from_user.S b/arch/arm/lib/copy_from_user.S index 6b7363c..56799a1 100644 --- a/arch/arm/lib/copy_from_user.S +++ b/arch/arm/lib/copy_from_user.S @@ -87,6 +87,8 @@ ENTRY(__copy_from_user) #include "copy_template.S" +ENDPROC(__copy_from_user) + .section .fixup,"ax" .align 0 copy_abort_preamble diff --git a/arch/arm/lib/copy_page.S b/arch/arm/lib/copy_page.S index 666c99c..6ae04db 100644 --- a/arch/arm/lib/copy_page.S +++ b/arch/arm/lib/copy_page.S @@ -44,3 +44,4 @@ ENTRY(copy_page) PLD( ldmeqia r1!, {r3, r4, ip, lr} ) PLD( beq 2b ) ldmfd sp!, {r4, pc} @ 3 +ENDPROC(copy_page) diff --git a/arch/arm/lib/copy_to_user.S b/arch/arm/lib/copy_to_user.S index 5224d94..22f968b 100644 --- a/arch/arm/lib/copy_to_user.S +++ b/arch/arm/lib/copy_to_user.S @@ -90,6 +90,8 @@ ENTRY(__copy_to_user) #include "copy_template.S" +ENDPROC(__copy_to_user) + .section .fixup,"ax" .align 0 copy_abort_preamble diff --git a/arch/arm/lib/csumipv6.S b/arch/arm/lib/csumipv6.S index 9621469..3ac6ef0 100644 --- a/arch/arm/lib/csumipv6.S +++ b/arch/arm/lib/csumipv6.S @@ -29,4 +29,5 @@ ENTRY(__csum_ipv6_magic) adcs r0, r0, r2 adcs r0, r0, #0 ldmfd sp!, {pc} +ENDPROC(__csum_ipv6_magic) diff --git a/arch/arm/lib/csumpartial.S b/arch/arm/lib/csumpartial.S index a78dae5..31d3cb3 100644 --- a/arch/arm/lib/csumpartial.S +++ b/arch/arm/lib/csumpartial.S @@ -139,3 +139,4 @@ ENTRY(csum_partial) tst len, #0x1c bne 4b b .Lless4 +ENDPROC(csum_partial) diff --git a/arch/arm/lib/csumpartialcopy.S b/arch/arm/lib/csumpartialcopy.S index 21effe0..d03fc71 100644 --- a/arch/arm/lib/csumpartialcopy.S +++ b/arch/arm/lib/csumpartialcopy.S @@ -18,13 +18,11 @@ */ .macro save_regs - mov ip, sp - stmfd sp!, {r1, r4 - r8, fp, ip, lr, pc} - sub fp, ip, #4 + stmfd sp!, {r1, r4 - r8, lr} .endm .macro load_regs - ldmfd sp, {r1, r4 - r8, fp, sp, pc} + ldmfd sp!, {r1, r4 - r8, pc} .endm .macro load1b, reg1 @@ -50,5 +48,6 @@ .endm #define FN_ENTRY ENTRY(csum_partial_copy_nocheck) +#define FN_EXIT ENDPROC(csum_partial_copy_nocheck) #include "csumpartialcopygeneric.S" diff --git a/arch/arm/lib/csumpartialcopygeneric.S b/arch/arm/lib/csumpartialcopygeneric.S index c50e8f5..d620a5f 100644 --- a/arch/arm/lib/csumpartialcopygeneric.S +++ b/arch/arm/lib/csumpartialcopygeneric.S @@ -329,3 +329,4 @@ FN_ENTRY adcs sum, sum, r4, push #24 mov r5, r4, get_byte_1 b .Lexit +FN_EXIT diff --git a/arch/arm/lib/csumpartialcopyuser.S b/arch/arm/lib/csumpartialcopyuser.S index c3b93e2..14677fb 100644 --- a/arch/arm/lib/csumpartialcopyuser.S +++ b/arch/arm/lib/csumpartialcopyuser.S @@ -18,13 +18,11 @@ .text .macro save_regs - mov ip, sp - stmfd sp!, {r1 - r2, r4 - r8, fp, ip, lr, pc} - sub fp, ip, #4 + stmfd sp!, {r1, r2, r4 - r8, lr} .endm .macro load_regs - ldmfd sp, {r1, r2, r4-r8, fp, sp, pc} + ldmfd sp!, {r1, r2, r4 - r8, pc} .endm .macro load1b, reg1 @@ -82,6 +80,7 @@ */ #define FN_ENTRY ENTRY(csum_partial_copy_from_user) +#define FN_EXIT ENDPROC(csum_partial_copy_from_user) #include "csumpartialcopygeneric.S" diff --git a/arch/arm/lib/delay.S b/arch/arm/lib/delay.S index 930a702..8d6a876 100644 --- a/arch/arm/lib/delay.S +++ b/arch/arm/lib/delay.S @@ -60,3 +60,6 @@ ENTRY(__delay) #endif bhi __delay mov pc, lr +ENDPROC(__udelay) +ENDPROC(__const_udelay) +ENDPROC(__delay) diff --git a/arch/arm/lib/div64.S b/arch/arm/lib/div64.S index 58eef66..1425e78 100644 --- a/arch/arm/lib/div64.S +++ b/arch/arm/lib/div64.S @@ -198,3 +198,4 @@ ENTRY(__do_div64) mov xh, #0 ldr pc, [sp], #8 +ENDPROC(__do_div64) diff --git a/arch/arm/lib/findbit.S b/arch/arm/lib/findbit.S index a5ca024..8c4defc 100644 --- a/arch/arm/lib/findbit.S +++ b/arch/arm/lib/findbit.S @@ -33,6 +33,7 @@ ENTRY(_find_first_zero_bit_le) blo 1b 3: mov r0, r1 @ no free bits mov pc, lr +ENDPROC(_find_first_zero_bit_le) /* * Purpose : Find next 'zero' bit @@ -50,6 +51,7 @@ ENTRY(_find_next_zero_bit_le) orr r2, r2, #7 @ if zero, then no bits here add r2, r2, #1 @ align bit pointer b 2b @ loop for next bit +ENDPROC(_find_next_zero_bit_le) /* * Purpose : Find a 'one' bit @@ -67,6 +69,7 @@ ENTRY(_find_first_bit_le) blo 1b 3: mov r0, r1 @ no free bits mov pc, lr +ENDPROC(_find_first_bit_le) /* * Purpose : Find next 'one' bit @@ -83,6 +86,7 @@ ENTRY(_find_next_bit_le) orr r2, r2, #7 @ if zero, then no bits here add r2, r2, #1 @ align bit pointer b 2b @ loop for next bit +ENDPROC(_find_next_bit_le) #ifdef __ARMEB__ @@ -99,6 +103,7 @@ ENTRY(_find_first_zero_bit_be) blo 1b 3: mov r0, r1 @ no free bits mov pc, lr +ENDPROC(_find_first_zero_bit_be) ENTRY(_find_next_zero_bit_be) teq r1, #0 @@ -113,6 +118,7 @@ ENTRY(_find_next_zero_bit_be) orr r2, r2, #7 @ if zero, then no bits here add r2, r2, #1 @ align bit pointer b 2b @ loop for next bit +ENDPROC(_find_next_zero_bit_be) ENTRY(_find_first_bit_be) teq r1, #0 @@ -127,6 +133,7 @@ ENTRY(_find_first_bit_be) blo 1b 3: mov r0, r1 @ no free bits mov pc, lr +ENDPROC(_find_first_bit_be) ENTRY(_find_next_bit_be) teq r1, #0 @@ -140,6 +147,7 @@ ENTRY(_find_next_bit_be) orr r2, r2, #7 @ if zero, then no bits here add r2, r2, #1 @ align bit pointer b 2b @ loop for next bit +ENDPROC(_find_next_bit_be) #endif diff --git a/arch/arm/lib/getuser.S b/arch/arm/lib/getuser.S index 2034d4d..6763088 100644 --- a/arch/arm/lib/getuser.S +++ b/arch/arm/lib/getuser.S @@ -26,16 +26,16 @@ * Note that ADDR_LIMIT is either 0 or 0xc0000000. * Note also that it is intended that __get_user_bad is not global. */ +#include #include - .global __get_user_1 -__get_user_1: +ENTRY(__get_user_1) 1: ldrbt r2, [r0] mov r0, #0 mov pc, lr +ENDPROC(__get_user_1) - .global __get_user_2 -__get_user_2: +ENTRY(__get_user_2) 2: ldrbt r2, [r0], #1 3: ldrbt r3, [r0] #ifndef __ARMEB__ @@ -45,17 +45,19 @@ __get_user_2: #endif mov r0, #0 mov pc, lr +ENDPROC(__get_user_2) - .global __get_user_4 -__get_user_4: +ENTRY(__get_user_4) 4: ldrt r2, [r0] mov r0, #0 mov pc, lr +ENDPROC(__get_user_4) __get_user_bad: mov r2, #0 mov r0, #-EFAULT mov pc, lr +ENDPROC(__get_user_bad) .section __ex_table, "a" .long 1b, __get_user_bad diff --git a/arch/arm/lib/io-readsb.S b/arch/arm/lib/io-readsb.S index fb966ad..9f42389 100644 --- a/arch/arm/lib/io-readsb.S +++ b/arch/arm/lib/io-readsb.S @@ -120,3 +120,4 @@ ENTRY(__raw_readsb) strgtb r3, [r1] ldmfd sp!, {r4 - r6, pc} +ENDPROC(__raw_readsb) diff --git a/arch/arm/lib/io-readsl.S b/arch/arm/lib/io-readsl.S index 75a9121..5fb97e7 100644 --- a/arch/arm/lib/io-readsl.S +++ b/arch/arm/lib/io-readsl.S @@ -76,3 +76,4 @@ ENTRY(__raw_readsl) 8: mov r3, ip, get_byte_0 strb r3, [r1, #0] mov pc, lr +ENDPROC(__raw_readsl) diff --git a/arch/arm/lib/io-readsw-armv4.S b/arch/arm/lib/io-readsw-armv4.S index 4db1c5f..1f393d4 100644 --- a/arch/arm/lib/io-readsw-armv4.S +++ b/arch/arm/lib/io-readsw-armv4.S @@ -128,3 +128,4 @@ ENTRY(__raw_readsw) _BE_ONLY_( movne ip, ip, lsr #24 ) strneb ip, [r1] ldmfd sp!, {r4, pc} +ENDPROC(__raw_readsw) diff --git a/arch/arm/lib/io-writesb.S b/arch/arm/lib/io-writesb.S index 7eba2b6..68b92f4 100644 --- a/arch/arm/lib/io-writesb.S +++ b/arch/arm/lib/io-writesb.S @@ -91,3 +91,4 @@ ENTRY(__raw_writesb) strgtb r3, [r0] ldmfd sp!, {r4, r5, pc} +ENDPROC(__raw_writesb) diff --git a/arch/arm/lib/io-writesl.S b/arch/arm/lib/io-writesl.S index f8f14dd..8d3b781 100644 --- a/arch/arm/lib/io-writesl.S +++ b/arch/arm/lib/io-writesl.S @@ -64,3 +64,4 @@ ENTRY(__raw_writesl) str ip, [r0] bne 6b mov pc, lr +ENDPROC(__raw_writesl) diff --git a/arch/arm/lib/io-writesw-armv4.S b/arch/arm/lib/io-writesw-armv4.S index c8e85bd..d658561 100644 --- a/arch/arm/lib/io-writesw-armv4.S +++ b/arch/arm/lib/io-writesw-armv4.S @@ -94,3 +94,4 @@ ENTRY(__raw_writesw) 3: movne ip, r3, lsr #8 strneh ip, [r0] mov pc, lr +ENDPROC(__raw_writesw) diff --git a/arch/arm/lib/lib1funcs.S b/arch/arm/lib/lib1funcs.S index 4e492f4..67964bc 100644 --- a/arch/arm/lib/lib1funcs.S +++ b/arch/arm/lib/lib1funcs.S @@ -230,6 +230,8 @@ ENTRY(__aeabi_uidiv) mov r0, r0, lsr r2 mov pc, lr +ENDPROC(__udivsi3) +ENDPROC(__aeabi_uidiv) ENTRY(__umodsi3) @@ -245,6 +247,7 @@ ENTRY(__umodsi3) mov pc, lr +ENDPROC(__umodsi3) ENTRY(__divsi3) ENTRY(__aeabi_idiv) @@ -284,6 +287,8 @@ ENTRY(__aeabi_idiv) rsbmi r0, r0, #0 mov pc, lr +ENDPROC(__divsi3) +ENDPROC(__aeabi_idiv) ENTRY(__modsi3) @@ -305,6 +310,8 @@ ENTRY(__modsi3) rsbmi r0, r0, #0 mov pc, lr +ENDPROC(__modsi3) + #ifdef CONFIG_AEABI ENTRY(__aeabi_uidivmod) @@ -316,6 +323,8 @@ ENTRY(__aeabi_uidivmod) sub r1, r1, r3 mov pc, lr +ENDPROC(__aeabi_uidivmod) + ENTRY(__aeabi_idivmod) stmfd sp!, {r0, r1, ip, lr} @@ -325,6 +334,8 @@ ENTRY(__aeabi_idivmod) sub r1, r1, r3 mov pc, lr +ENDPROC(__aeabi_idivmod) + #endif Ldiv0: diff --git a/arch/arm/lib/lshrdi3.S b/arch/arm/lib/lshrdi3.S index a86dbdd..99ea338 100644 --- a/arch/arm/lib/lshrdi3.S +++ b/arch/arm/lib/lshrdi3.S @@ -47,3 +47,5 @@ ENTRY(__aeabi_llsr) mov ah, ah, lsr r2 mov pc, lr +ENDPROC(__lshrdi3) +ENDPROC(__aeabi_llsr) diff --git a/arch/arm/lib/memchr.S b/arch/arm/lib/memchr.S index e7ab1ea..1da8699 100644 --- a/arch/arm/lib/memchr.S +++ b/arch/arm/lib/memchr.S @@ -23,3 +23,4 @@ ENTRY(memchr) sub r0, r0, #1 2: movne r0, #0 mov pc, lr +ENDPROC(memchr) diff --git a/arch/arm/lib/memcpy.S b/arch/arm/lib/memcpy.S index 7e71d67..e0d0026 100644 --- a/arch/arm/lib/memcpy.S +++ b/arch/arm/lib/memcpy.S @@ -57,3 +57,4 @@ ENTRY(memcpy) #include "copy_template.S" +ENDPROC(memcpy) diff --git a/arch/arm/lib/memmove.S b/arch/arm/lib/memmove.S index 2e301b7..1254918 100644 --- a/arch/arm/lib/memmove.S +++ b/arch/arm/lib/memmove.S @@ -196,3 +196,4 @@ ENTRY(memmove) 18: backward_copy_shift push=24 pull=8 +ENDPROC(memmove) diff --git a/arch/arm/lib/memset.S b/arch/arm/lib/memset.S index b477d4a..761eefa 100644 --- a/arch/arm/lib/memset.S +++ b/arch/arm/lib/memset.S @@ -124,3 +124,4 @@ ENTRY(memset) tst r2, #1 strneb r1, [r0], #1 mov pc, lr +ENDPROC(memset) diff --git a/arch/arm/lib/memzero.S b/arch/arm/lib/memzero.S index b8f79d8..3fbdef5 100644 --- a/arch/arm/lib/memzero.S +++ b/arch/arm/lib/memzero.S @@ -122,3 +122,4 @@ ENTRY(__memzero) tst r1, #1 @ 1 a byte left over strneb r2, [r0], #1 @ 1 mov pc, lr @ 1 +ENDPROC(__memzero) diff --git a/arch/arm/lib/muldi3.S b/arch/arm/lib/muldi3.S index d89c606..36c91b4 100644 --- a/arch/arm/lib/muldi3.S +++ b/arch/arm/lib/muldi3.S @@ -43,3 +43,5 @@ ENTRY(__aeabi_lmul) adc xh, xh, ip, lsr #16 mov pc, lr +ENDPROC(__muldi3) +ENDPROC(__aeabi_lmul) diff --git a/arch/arm/lib/putuser.S b/arch/arm/lib/putuser.S index 08ec7df..864f3c1 100644 --- a/arch/arm/lib/putuser.S +++ b/arch/arm/lib/putuser.S @@ -26,16 +26,16 @@ * Note that ADDR_LIMIT is either 0 or 0xc0000000 * Note also that it is intended that __put_user_bad is not global. */ +#include #include - .global __put_user_1 -__put_user_1: +ENTRY(__put_user_1) 1: strbt r2, [r0] mov r0, #0 mov pc, lr +ENDPROC(__put_user_1) - .global __put_user_2 -__put_user_2: +ENTRY(__put_user_2) mov ip, r2, lsr #8 #ifndef __ARMEB__ 2: strbt r2, [r0], #1 @@ -46,23 +46,25 @@ __put_user_2: #endif mov r0, #0 mov pc, lr +ENDPROC(__put_user_2) - .global __put_user_4 -__put_user_4: +ENTRY(__put_user_4) 4: strt r2, [r0] mov r0, #0 mov pc, lr +ENDPROC(__put_user_4) - .global __put_user_8 -__put_user_8: +ENTRY(__put_user_8) 5: strt r2, [r0], #4 6: strt r3, [r0] mov r0, #0 mov pc, lr +ENDPROC(__put_user_8) __put_user_bad: mov r0, #-EFAULT mov pc, lr +ENDPROC(__put_user_bad) .section __ex_table, "a" .long 1b, __put_user_bad diff --git a/arch/arm/lib/setbit.S b/arch/arm/lib/setbit.S index 83bc23d..1dd7176 100644 --- a/arch/arm/lib/setbit.S +++ b/arch/arm/lib/setbit.S @@ -20,3 +20,5 @@ ENTRY(_set_bit_be) eor r0, r0, #0x18 @ big endian byte ordering ENTRY(_set_bit_le) bitop orr +ENDPROC(_set_bit_be) +ENDPROC(_set_bit_le) diff --git a/arch/arm/lib/sha1.S b/arch/arm/lib/sha1.S index 67c2bf4..a16fb20 100644 --- a/arch/arm/lib/sha1.S +++ b/arch/arm/lib/sha1.S @@ -185,6 +185,8 @@ ENTRY(sha_transform) ldmfd sp!, {r4 - r8, pc} +ENDPROC(sha_transform) + .L_sha_K: .word 0x5a827999, 0x6ed9eba1, 0x8f1bbcdc, 0xca62c1d6 @@ -204,3 +206,4 @@ ENTRY(sha_init) stmia r0, {r1, r2, r3, ip, lr} ldr pc, [sp], #4 +ENDPROC(sha_init) diff --git a/arch/arm/lib/strchr.S b/arch/arm/lib/strchr.S index 9f18d6f..d8f2a1c 100644 --- a/arch/arm/lib/strchr.S +++ b/arch/arm/lib/strchr.S @@ -24,3 +24,4 @@ ENTRY(strchr) movne r0, #0 subeq r0, r0, #1 mov pc, lr +ENDPROC(strchr) diff --git a/arch/arm/lib/strncpy_from_user.S b/arch/arm/lib/strncpy_from_user.S index 36e3741..330373c 100644 --- a/arch/arm/lib/strncpy_from_user.S +++ b/arch/arm/lib/strncpy_from_user.S @@ -31,6 +31,7 @@ USER( ldrplbt r3, [r1], #1) sub r1, r1, #1 @ take NUL character out of count 2: sub r0, r1, ip mov pc, lr +ENDPROC(__strncpy_from_user) .section .fixup,"ax" .align 0 diff --git a/arch/arm/lib/strnlen_user.S b/arch/arm/lib/strnlen_user.S index 18d8fa4..90bb9d0 100644 --- a/arch/arm/lib/strnlen_user.S +++ b/arch/arm/lib/strnlen_user.S @@ -31,6 +31,7 @@ USER( ldrbt r3, [r0], #1) add r0, r0, #1 2: sub r0, r0, r2 mov pc, lr +ENDPROC(__strnlen_user) .section .fixup,"ax" .align 0 diff --git a/arch/arm/lib/strrchr.S b/arch/arm/lib/strrchr.S index 538df22..302f20c 100644 --- a/arch/arm/lib/strrchr.S +++ b/arch/arm/lib/strrchr.S @@ -23,3 +23,4 @@ ENTRY(strrchr) bne 1b mov r0, r3 mov pc, lr +ENDPROC(strrchr) diff --git a/arch/arm/lib/testchangebit.S b/arch/arm/lib/testchangebit.S index b25dcd2..5c98dc5 100644 --- a/arch/arm/lib/testchangebit.S +++ b/arch/arm/lib/testchangebit.S @@ -16,3 +16,5 @@ ENTRY(_test_and_change_bit_be) eor r0, r0, #0x18 @ big endian byte ordering ENTRY(_test_and_change_bit_le) testop eor, strb +ENDPROC(_test_and_change_bit_be) +ENDPROC(_test_and_change_bit_le) diff --git a/arch/arm/lib/testclearbit.S b/arch/arm/lib/testclearbit.S index 2dcc4b1..543d709 100644 --- a/arch/arm/lib/testclearbit.S +++ b/arch/arm/lib/testclearbit.S @@ -16,3 +16,5 @@ ENTRY(_test_and_clear_bit_be) eor r0, r0, #0x18 @ big endian byte ordering ENTRY(_test_and_clear_bit_le) testop bicne, strneb +ENDPROC(_test_and_clear_bit_be) +ENDPROC(_test_and_clear_bit_le) diff --git a/arch/arm/lib/testsetbit.S b/arch/arm/lib/testsetbit.S index 9011c96..0b3f390 100644 --- a/arch/arm/lib/testsetbit.S +++ b/arch/arm/lib/testsetbit.S @@ -16,3 +16,5 @@ ENTRY(_test_and_set_bit_be) eor r0, r0, #0x18 @ big endian byte ordering ENTRY(_test_and_set_bit_le) testop orreq, streqb +ENDPROC(_test_and_set_bit_be) +ENDPROC(_test_and_set_bit_le) diff --git a/arch/arm/lib/uaccess.S b/arch/arm/lib/uaccess.S index b48bd6d..ffdd274 100644 --- a/arch/arm/lib/uaccess.S +++ b/arch/arm/lib/uaccess.S @@ -277,6 +277,7 @@ USER( strgebt r3, [r0], #1) @ May fault ldrgtb r3, [r1], #0 USER( strgtbt r3, [r0], #1) @ May fault b .Lc2u_finished +ENDPROC(__copy_to_user) .section .fixup,"ax" .align 0 @@ -542,6 +543,7 @@ USER( ldrgebt r3, [r1], #1) @ May fault USER( ldrgtbt r3, [r1], #1) @ May fault strgtb r3, [r0], #1 b .Lcfu_finished +ENDPROC(__copy_from_user) .section .fixup,"ax" .align 0 diff --git a/arch/arm/lib/ucmpdi2.S b/arch/arm/lib/ucmpdi2.S index f76de07..f0df6a9 100644 --- a/arch/arm/lib/ucmpdi2.S +++ b/arch/arm/lib/ucmpdi2.S @@ -33,6 +33,8 @@ ENTRY(__ucmpdi2) movhi r0, #2 mov pc, lr +ENDPROC(__ucmpdi2) + #ifdef CONFIG_AEABI ENTRY(__aeabi_ulcmp) @@ -44,5 +46,7 @@ ENTRY(__aeabi_ulcmp) movhi r0, #1 mov pc, lr +ENDPROC(__aeabi_ulcmp) + #endif diff --git a/arch/arm/mach-at91/Kconfig b/arch/arm/mach-at91/Kconfig index a048b92..68537e3 100644 --- a/arch/arm/mach-at91/Kconfig +++ b/arch/arm/mach-at91/Kconfig @@ -175,6 +175,15 @@ config MACH_SAM9_L9260 Select this if you are using Olimex's SAM9-L9260 board based on the Atmel AT91SAM9260. +config MACH_AFEB9260 + bool "Custom afeb9260 board v1" + depends on ARCH_AT91SAM9260 + help + Select this if you are using custom afeb9260 board based on + open hardware design. Select this for revision 1 of the board. + + + config MACH_USB_A9260 bool "CALAO USB-A9260" depends on ARCH_AT91SAM9260 diff --git a/arch/arm/mach-at91/Makefile b/arch/arm/mach-at91/Makefile index 7d641f9..a95c49b 100644 --- a/arch/arm/mach-at91/Makefile +++ b/arch/arm/mach-at91/Makefile @@ -39,6 +39,7 @@ obj-$(CONFIG_MACH_CAM60) += board-cam60.o obj-$(CONFIG_MACH_SAM9_L9260) += board-sam9-l9260.o obj-$(CONFIG_MACH_USB_A9260) += board-usb-a9260.o obj-$(CONFIG_MACH_QIL_A9260) += board-qil-a9260.o +obj-$(CONFIG_MACH_AFEB9260) += board-afeb-9260v1.o # AT91SAM9261 board-specific support obj-$(CONFIG_MACH_AT91SAM9261EK) += board-sam9261ek.o diff --git a/arch/arm/mach-at91/board-afeb-9260v1.c b/arch/arm/mach-at91/board-afeb-9260v1.c new file mode 100644 index 0000000..9c040c7 --- /dev/null +++ b/arch/arm/mach-at91/board-afeb-9260v1.c @@ -0,0 +1,210 @@ +/* + * linux/arch/arm/mach-at91/board-afeb-9260v1.c + * + * Copyright (C) 2005 SAN People + * Copyright (C) 2006 Atmel + * Copyright (C) 2008 Sergey Lapin + * + * A custom board designed as open hardware; PCBs and various information + * is available at http://groups.google.com/group/arm9fpga-evolution-board/ + * Subversion repository: svn://194.85.238.22/home/users/george/svn/arm9eb + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + */ + +#include +#include +#include +#include +#include +#include +#include +#include + +#include +#include +#include +#include + +#include +#include +#include + +#include +#include + +#include "generic.h" + + +static void __init afeb9260_map_io(void) +{ + /* Initialize processor: 18.432 MHz crystal */ + at91sam9260_initialize(18432000); + + /* DGBU on ttyS0. (Rx & Tx only) */ + at91_register_uart(0, 0, 0); + + /* USART0 on ttyS1. (Rx, Tx, CTS, RTS, DTR, DSR, DCD, RI) */ + at91_register_uart(AT91SAM9260_ID_US0, 1, + ATMEL_UART_CTS | ATMEL_UART_RTS + | ATMEL_UART_DTR | ATMEL_UART_DSR + | ATMEL_UART_DCD | ATMEL_UART_RI); + + /* USART1 on ttyS2. (Rx, Tx, RTS, CTS) */ + at91_register_uart(AT91SAM9260_ID_US1, 2, + ATMEL_UART_CTS | ATMEL_UART_RTS); + + /* set serial console to ttyS0 (ie, DBGU) */ + at91_set_serial_console(0); +} + +static void __init afeb9260_init_irq(void) +{ + at91sam9260_init_interrupts(NULL); +} + + +/* + * USB Host port + */ +static struct at91_usbh_data __initdata afeb9260_usbh_data = { + .ports = 1, +}; + +/* + * USB Device port + */ +static struct at91_udc_data __initdata afeb9260_udc_data = { + .vbus_pin = AT91_PIN_PC5, + .pullup_pin = 0, /* pull-up driven by UDC */ +}; + + + +/* + * SPI devices. + */ +static struct spi_board_info afeb9260_spi_devices[] = { + { /* DataFlash chip */ + .modalias = "mtd_dataflash", + .chip_select = 1, + .max_speed_hz = 15 * 1000 * 1000, + .bus_num = 0, + }, +}; + + +/* + * MACB Ethernet device + */ +static struct at91_eth_data __initdata afeb9260_macb_data = { + .phy_irq_pin = AT91_PIN_PA9, + .is_rmii = 0, +}; + + +/* + * NAND flash + */ +static struct mtd_partition __initdata afeb9260_nand_partition[] = { + { + .name = "bootloader", + .offset = 0, + .size = (640 * SZ_1K), + }, + { + .name = "kernel", + .offset = MTDPART_OFS_NXTBLK, + .size = SZ_2M, + }, + { + .name = "rootfs", + .offset = MTDPART_OFS_NXTBLK, + .size = MTDPART_SIZ_FULL, + }, +}; + +static struct mtd_partition * __init nand_partitions(int size, int *num_partitions) +{ + *num_partitions = ARRAY_SIZE(afeb9260_nand_partition); + return afeb9260_nand_partition; +} + +static struct atmel_nand_data __initdata afeb9260_nand_data = { + .ale = 21, + .cle = 22, + .rdy_pin = AT91_PIN_PC13, + .enable_pin = AT91_PIN_PC14, + .partition_info = nand_partitions, + .bus_width_16 = 0, +}; + + +/* + * MCI (SD/MMC) + */ +static struct at91_mmc_data __initdata afeb9260_mmc_data = { + .slot_b = 1, + .wire4 = 1, +}; + + + +static struct i2c_board_info __initdata afeb9260_i2c_devices[] = { + { + I2C_BOARD_INFO("fm3130", 0x68), + I2C_BOARD_INFO("24c64", 0x50), + }, +}; + +static void __init afeb9260_board_init(void) +{ + /* Serial */ + at91_add_device_serial(); + /* USB Host */ + at91_add_device_usbh(&afeb9260_usbh_data); + /* USB Device */ + at91_add_device_udc(&afeb9260_udc_data); + /* SPI */ + at91_add_device_spi(afeb9260_spi_devices, + ARRAY_SIZE(afeb9260_spi_devices)); + /* NAND */ + at91_add_device_nand(&afeb9260_nand_data); + /* Ethernet */ + at91_add_device_eth(&afeb9260_macb_data); + + /* Standard function's pin assignments are not + * appropriate for us and generic code provide + * no API to configure these pins any other way */ + at91_set_B_periph(AT91_PIN_PA10, 0); /* ETX2 */ + at91_set_B_periph(AT91_PIN_PA11, 0); /* ETX3 */ + /* MMC */ + at91_add_device_mmc(0, &afeb9260_mmc_data); + /* I2C */ + at91_add_device_i2c(afeb9260_i2c_devices, + ARRAY_SIZE(afeb9260_i2c_devices)); +} + +MACHINE_START(AFEB9260, "Custom afeb9260 board") + /* Maintainer: Sergey Lapin */ + .phys_io = AT91_BASE_SYS, + .io_pg_offst = (AT91_VA_BASE_SYS >> 18) & 0xfffc, + .boot_params = AT91_SDRAM_BASE + 0x100, + .timer = &at91sam926x_timer, + .map_io = afeb9260_map_io, + .init_irq = afeb9260_init_irq, + .init_machine = afeb9260_board_init, +MACHINE_END + diff --git a/arch/arm/mach-footbridge/include/mach/memory.h b/arch/arm/mach-footbridge/include/mach/memory.h index e9cae99..6ae2f1a 100644 --- a/arch/arm/mach-footbridge/include/mach/memory.h +++ b/arch/arm/mach-footbridge/include/mach/memory.h @@ -42,10 +42,6 @@ extern unsigned long __bus_to_virt(unsigned long); #endif -/* Task size and page offset at 3GB */ -#define TASK_SIZE UL(0xbf000000) -#define PAGE_OFFSET UL(0xc0000000) - /* * Cache flushing area. */ @@ -56,12 +52,6 @@ extern unsigned long __bus_to_virt(unsigned long); */ #define PHYS_OFFSET UL(0x00000000) -/* - * This decides where the kernel will search for a free chunk of vm - * space during mmap's. - */ -#define TASK_UNMAPPED_BASE ((TASK_SIZE + 0x01000000) / 3) - #define FLUSH_BASE_PHYS 0x50000000 #endif diff --git a/arch/arm/mach-iop13xx/include/mach/memory.h b/arch/arm/mach-iop13xx/include/mach/memory.h index e8b59d8..a74b027 100644 --- a/arch/arm/mach-iop13xx/include/mach/memory.h +++ b/arch/arm/mach-iop13xx/include/mach/memory.h @@ -7,9 +7,6 @@ * Physical DRAM offset. */ #define PHYS_OFFSET UL(0x00000000) -#define TASK_SIZE UL(0x3f000000) -#define PAGE_OFFSET UL(0x40000000) -#define TASK_UNMAPPED_BASE ((TASK_SIZE + 0x01000000) / 3) #ifndef __ASSEMBLY__ diff --git a/arch/arm/mach-iop32x/iq31244.c b/arch/arm/mach-iop32x/iq31244.c index 082818a..1845643 100644 --- a/arch/arm/mach-iop32x/iq31244.c +++ b/arch/arm/mach-iop32x/iq31244.c @@ -27,6 +27,7 @@ #include #include #include +#include #include #include #include @@ -49,8 +50,7 @@ static int force_ep80219; static int is_80219(void) { - extern int processor_id; - return !!((processor_id & 0xffffffe0) == 0x69052e20); + return !!((read_cpuid_id() & 0xffffffe0) == 0x69052e20); } static int is_ep80219(void) diff --git a/arch/arm/mach-ixp4xx/common-pci.c b/arch/arm/mach-ixp4xx/common-pci.c index 192538a..f74a460 100644 --- a/arch/arm/mach-ixp4xx/common-pci.c +++ b/arch/arm/mach-ixp4xx/common-pci.c @@ -27,6 +27,7 @@ #include #include +#include #include #include #include @@ -366,15 +367,13 @@ void __init ixp4xx_adjust_zones(int node, unsigned long *zone_size, void __init ixp4xx_pci_preinit(void) { - unsigned long processor_id; - - asm("mrc p15, 0, %0, cr0, cr0, 0;" : "=r"(processor_id) :); + unsigned long cpuid = read_cpuid_id(); /* * Determine which PCI read method to use. * Rev 0 IXP425 requires workaround. */ - if (!(processor_id & 0xf) && cpu_is_ixp42x()) { + if (!(cpuid & 0xf) && cpu_is_ixp42x()) { printk("PCI: IXP42x A0 silicon detected - " "PCI Non-Prefetch Workaround Enabled\n"); ixp4xx_pci_read = ixp4xx_pci_read_errata; diff --git a/arch/arm/mach-ixp4xx/include/mach/cpu.h b/arch/arm/mach-ixp4xx/include/mach/cpu.h index ff8aa23..51bd69c 100644 --- a/arch/arm/mach-ixp4xx/include/mach/cpu.h +++ b/arch/arm/mach-ixp4xx/include/mach/cpu.h @@ -14,18 +14,19 @@ #ifndef __ASM_ARCH_CPU_H__ #define __ASM_ARCH_CPU_H__ -extern unsigned int processor_id; +#include + /* Processor id value in CP15 Register 0 */ #define IXP425_PROCESSOR_ID_VALUE 0x690541c0 #define IXP435_PROCESSOR_ID_VALUE 0x69054040 #define IXP465_PROCESSOR_ID_VALUE 0x69054200 #define IXP4XX_PROCESSOR_ID_MASK 0xfffffff0 -#define cpu_is_ixp42x() ((processor_id & IXP4XX_PROCESSOR_ID_MASK) == \ +#define cpu_is_ixp42x() ((read_cpuid_id() & IXP4XX_PROCESSOR_ID_MASK) == \ IXP425_PROCESSOR_ID_VALUE) -#define cpu_is_ixp43x() ((processor_id & IXP4XX_PROCESSOR_ID_MASK) == \ +#define cpu_is_ixp43x() ((read_cpuid_id() & IXP4XX_PROCESSOR_ID_MASK) == \ IXP435_PROCESSOR_ID_VALUE) -#define cpu_is_ixp46x() ((processor_id & IXP4XX_PROCESSOR_ID_MASK) == \ +#define cpu_is_ixp46x() ((read_cpuid_id() & IXP4XX_PROCESSOR_ID_MASK) == \ IXP465_PROCESSOR_ID_VALUE) static inline u32 ixp4xx_read_feature_bits(void) diff --git a/arch/arm/mach-lh7a40x/clocks.c b/arch/arm/mach-lh7a40x/clocks.c index 4fb23ac..6929188 100644 --- a/arch/arm/mach-lh7a40x/clocks.c +++ b/arch/arm/mach-lh7a40x/clocks.c @@ -12,6 +12,7 @@ #include #include #include +#include struct module; struct icst525_params; @@ -80,14 +81,14 @@ unsigned int pclkfreq_get (void) /* ----- */ static LIST_HEAD(clocks); -static DECLARE_MUTEX(clocks_sem); +static DEFINE_SPINLOCK(clocks_lock); struct clk *clk_get (struct device *dev, const char *id) { struct clk *p; struct clk *clk = ERR_PTR(-ENOENT); - down (&clocks_sem); + spin_lock(&clocks_lock); list_for_each_entry (p, &clocks, node) { if (strcmp (id, p->name) == 0 && try_module_get(p->owner)) { @@ -95,7 +96,7 @@ struct clk *clk_get (struct device *dev, const char *id) break; } } - up (&clocks_sem); + spin_unlock(&clocks_lock); return clk; } @@ -175,18 +176,18 @@ static struct clk clcd_clk = { int clk_register (struct clk *clk) { - down (&clocks_sem); + spin_lock(&clocks_lock); list_add (&clk->node, &clocks); - up (&clocks_sem); + spin_unlock(&clocks_lock); return 0; } EXPORT_SYMBOL(clk_register); void clk_unregister (struct clk *clk) { - down (&clocks_sem); + spin_lock(&clocks_lock); list_del (&clk->node); - up (&clocks_sem); + spin_unlock(&clocks_lock); } EXPORT_SYMBOL(clk_unregister); diff --git a/arch/arm/mach-omap1/board-h3.c b/arch/arm/mach-omap1/board-h3.c index 2ced6d9..adfcd7b 100644 --- a/arch/arm/mach-omap1/board-h3.c +++ b/arch/arm/mach-omap1/board-h3.c @@ -476,6 +476,10 @@ static struct i2c_board_info __initdata h3_i2c_board_info[] = { I2C_BOARD_INFO("tps65013", 0x48), /* .irq = OMAP_GPIO_IRQ(??), */ }, + { + I2C_BOARD_INFO("isp1301_omap", 0x2d), + .irq = OMAP_GPIO_IRQ(14), + }, }; static struct omap_gpio_switch h3_gpio_switches[] __initdata = { diff --git a/arch/arm/mach-omap1/mcbsp.c b/arch/arm/mach-omap1/mcbsp.c index 826010d..c812e9a 100644 --- a/arch/arm/mach-omap1/mcbsp.c +++ b/arch/arm/mach-omap1/mcbsp.c @@ -159,7 +159,7 @@ static struct omap_mcbsp_ops omap1_mcbsp_ops = { #ifdef CONFIG_ARCH_OMAP730 static struct omap_mcbsp_platform_data omap730_mcbsp_pdata[] = { { - .virt_base = io_p2v(OMAP730_MCBSP1_BASE), + .virt_base = IO_ADDRESS(OMAP730_MCBSP1_BASE), .dma_rx_sync = OMAP_DMA_MCBSP1_RX, .dma_tx_sync = OMAP_DMA_MCBSP1_TX, .rx_irq = INT_730_McBSP1RX, @@ -167,7 +167,7 @@ static struct omap_mcbsp_platform_data omap730_mcbsp_pdata[] = { .ops = &omap1_mcbsp_ops, }, { - .virt_base = io_p2v(OMAP730_MCBSP2_BASE), + .virt_base = IO_ADDRESS(OMAP730_MCBSP2_BASE), .dma_rx_sync = OMAP_DMA_MCBSP3_RX, .dma_tx_sync = OMAP_DMA_MCBSP3_TX, .rx_irq = INT_730_McBSP2RX, @@ -184,7 +184,7 @@ static struct omap_mcbsp_platform_data omap730_mcbsp_pdata[] = { #ifdef CONFIG_ARCH_OMAP15XX static struct omap_mcbsp_platform_data omap15xx_mcbsp_pdata[] = { { - .virt_base = OMAP1510_MCBSP1_BASE, + .virt_base = io_p2v(OMAP1510_MCBSP1_BASE), .dma_rx_sync = OMAP_DMA_MCBSP1_RX, .dma_tx_sync = OMAP_DMA_MCBSP1_TX, .rx_irq = INT_McBSP1RX, @@ -193,7 +193,7 @@ static struct omap_mcbsp_platform_data omap15xx_mcbsp_pdata[] = { .clk_name = "mcbsp_clk", }, { - .virt_base = io_p2v(OMAP1510_MCBSP2_BASE), + .virt_base = IO_ADDRESS(OMAP1510_MCBSP2_BASE), .dma_rx_sync = OMAP_DMA_MCBSP2_RX, .dma_tx_sync = OMAP_DMA_MCBSP2_TX, .rx_irq = INT_1510_SPI_RX, @@ -201,7 +201,7 @@ static struct omap_mcbsp_platform_data omap15xx_mcbsp_pdata[] = { .ops = &omap1_mcbsp_ops, }, { - .virt_base = OMAP1510_MCBSP3_BASE, + .virt_base = io_p2v(OMAP1510_MCBSP3_BASE), .dma_rx_sync = OMAP_DMA_MCBSP3_RX, .dma_tx_sync = OMAP_DMA_MCBSP3_TX, .rx_irq = INT_McBSP3RX, @@ -219,7 +219,7 @@ static struct omap_mcbsp_platform_data omap15xx_mcbsp_pdata[] = { #ifdef CONFIG_ARCH_OMAP16XX static struct omap_mcbsp_platform_data omap16xx_mcbsp_pdata[] = { { - .virt_base = OMAP1610_MCBSP1_BASE, + .virt_base = io_p2v(OMAP1610_MCBSP1_BASE), .dma_rx_sync = OMAP_DMA_MCBSP1_RX, .dma_tx_sync = OMAP_DMA_MCBSP1_TX, .rx_irq = INT_McBSP1RX, @@ -228,7 +228,7 @@ static struct omap_mcbsp_platform_data omap16xx_mcbsp_pdata[] = { .clk_name = "mcbsp_clk", }, { - .virt_base = io_p2v(OMAP1610_MCBSP2_BASE), + .virt_base = IO_ADDRESS(OMAP1610_MCBSP2_BASE), .dma_rx_sync = OMAP_DMA_MCBSP2_RX, .dma_tx_sync = OMAP_DMA_MCBSP2_TX, .rx_irq = INT_1610_McBSP2_RX, @@ -236,7 +236,7 @@ static struct omap_mcbsp_platform_data omap16xx_mcbsp_pdata[] = { .ops = &omap1_mcbsp_ops, }, { - .virt_base = OMAP1610_MCBSP3_BASE, + .virt_base = io_p2v(OMAP1610_MCBSP3_BASE), .dma_rx_sync = OMAP_DMA_MCBSP3_RX, .dma_tx_sync = OMAP_DMA_MCBSP3_TX, .rx_irq = INT_McBSP3RX, diff --git a/arch/arm/mach-omap1/serial.c b/arch/arm/mach-omap1/serial.c index 0e25a99..4965986 100644 --- a/arch/arm/mach-omap1/serial.c +++ b/arch/arm/mach-omap1/serial.c @@ -67,8 +67,8 @@ static void __init omap_serial_reset(struct plat_serial8250_port *p) static struct plat_serial8250_port serial_platform_data[] = { { - .membase = (char*)IO_ADDRESS(OMAP_UART1_BASE), - .mapbase = (unsigned long)OMAP_UART1_BASE, + .membase = IO_ADDRESS(OMAP_UART1_BASE), + .mapbase = OMAP_UART1_BASE, .irq = INT_UART1, .flags = UPF_BOOT_AUTOCONF, .iotype = UPIO_MEM, @@ -76,8 +76,8 @@ static struct plat_serial8250_port serial_platform_data[] = { .uartclk = OMAP16XX_BASE_BAUD * 16, }, { - .membase = (char*)IO_ADDRESS(OMAP_UART2_BASE), - .mapbase = (unsigned long)OMAP_UART2_BASE, + .membase = IO_ADDRESS(OMAP_UART2_BASE), + .mapbase = OMAP_UART2_BASE, .irq = INT_UART2, .flags = UPF_BOOT_AUTOCONF, .iotype = UPIO_MEM, @@ -85,8 +85,8 @@ static struct plat_serial8250_port serial_platform_data[] = { .uartclk = OMAP16XX_BASE_BAUD * 16, }, { - .membase = (char*)IO_ADDRESS(OMAP_UART3_BASE), - .mapbase = (unsigned long)OMAP_UART3_BASE, + .membase = IO_ADDRESS(OMAP_UART3_BASE), + .mapbase = OMAP_UART3_BASE, .irq = INT_UART3, .flags = UPF_BOOT_AUTOCONF, .iotype = UPIO_MEM, diff --git a/arch/arm/mach-omap2/Makefile b/arch/arm/mach-omap2/Makefile index 93ee990..e7cf1b4 100644 --- a/arch/arm/mach-omap2/Makefile +++ b/arch/arm/mach-omap2/Makefile @@ -4,7 +4,8 @@ # Common support obj-y := irq.o id.o io.o memory.o control.o prcm.o clock.o mux.o \ - devices.o serial.o gpmc.o timer-gp.o + devices.o serial.o gpmc.o timer-gp.o powerdomain.o \ + clockdomain.o obj-$(CONFIG_OMAP_MCBSP) += mcbsp.o diff --git a/arch/arm/mach-omap2/board-h4.c b/arch/arm/mach-omap2/board-h4.c index 9e2624c..d443720 100644 --- a/arch/arm/mach-omap2/board-h4.c +++ b/arch/arm/mach-omap2/board-h4.c @@ -18,6 +18,7 @@ #include #include #include +#include #include #include #include @@ -392,6 +393,13 @@ static struct omap_board_config_kernel h4_config[] = { { OMAP_TAG_LCD, &h4_lcd_config }, }; +static struct i2c_board_info __initdata h4_i2c_board_info[] = { + { + I2C_BOARD_INFO("isp1301_omap", 0x2d), + .irq = OMAP_GPIO_IRQ(125), + }, +}; + static void __init omap_h4_init(void) { /* @@ -412,6 +420,9 @@ static void __init omap_h4_init(void) } #endif + i2c_register_board_info(1, h4_i2c_board_info, + ARRAY_SIZE(h4_i2c_board_info)); + platform_add_devices(h4_devices, ARRAY_SIZE(h4_devices)); omap_board_config = h4_config; omap_board_config_size = ARRAY_SIZE(h4_config); diff --git a/arch/arm/mach-omap2/clock.c b/arch/arm/mach-omap2/clock.c index 1d891e4..aa9b373 100644 --- a/arch/arm/mach-omap2/clock.c +++ b/arch/arm/mach-omap2/clock.c @@ -26,6 +26,7 @@ #include #include +#include #include #include #include @@ -62,10 +63,36 @@ u8 cpu_mask; /*------------------------------------------------------------------------- - * Omap2 specific clock functions + * OMAP2/3 specific clock functions *-------------------------------------------------------------------------*/ /** + * omap2_init_clk_clkdm - look up a clockdomain name, store pointer in clk + * @clk: OMAP clock struct ptr to use + * + * Convert a clockdomain name stored in a struct clk 'clk' into a + * clockdomain pointer, and save it into the struct clk. Intended to be + * called during clk_register(). No return value. + */ +void omap2_init_clk_clkdm(struct clk *clk) +{ + struct clockdomain *clkdm; + + if (!clk->clkdm_name) + return; + + clkdm = clkdm_lookup(clk->clkdm_name); + if (clkdm) { + pr_debug("clock: associated clk %s to clkdm %s\n", + clk->name, clk->clkdm_name); + clk->clkdm = clkdm; + } else { + pr_debug("clock: could not associate clk %s to " + "clkdm %s\n", clk->name, clk->clkdm_name); + } +} + +/** * omap2_init_clksel_parent - set a clksel clk's parent field from the hardware * @clk: OMAP clock struct ptr to use * @@ -308,6 +335,9 @@ void omap2_clk_disable(struct clk *clk) _omap2_clk_disable(clk); if (likely((u32)clk->parent)) omap2_clk_disable(clk->parent); + if (clk->clkdm) + omap2_clkdm_clk_disable(clk->clkdm, clk); + } } @@ -324,11 +354,19 @@ int omap2_clk_enable(struct clk *clk) return ret; } + if (clk->clkdm) + omap2_clkdm_clk_enable(clk->clkdm, clk); + ret = _omap2_clk_enable(clk); - if (unlikely(ret != 0) && clk->parent) { - omap2_clk_disable(clk->parent); - clk->usecount--; + if (unlikely(ret != 0)) { + if (clk->clkdm) + omap2_clkdm_clk_disable(clk->clkdm, clk); + + if (clk->parent) { + omap2_clk_disable(clk->parent); + clk->usecount--; + } } } diff --git a/arch/arm/mach-omap2/clock.h b/arch/arm/mach-omap2/clock.h index 626e5fa..ea55f28 100644 --- a/arch/arm/mach-omap2/clock.h +++ b/arch/arm/mach-omap2/clock.h @@ -36,6 +36,7 @@ void omap2_clk_disable_unused(struct clk *clk); #endif void omap2_clksel_recalc(struct clk *clk); +void omap2_init_clk_clkdm(struct clk *clk); void omap2_init_clksel_parent(struct clk *clk); u32 omap2_clksel_get_divisor(struct clk *clk); u32 omap2_clksel_round_rate_div(struct clk *clk, unsigned long target_rate, diff --git a/arch/arm/mach-omap2/clock24xx.h b/arch/arm/mach-omap2/clock24xx.h index be4e255..242a19d 100644 --- a/arch/arm/mach-omap2/clock24xx.h +++ b/arch/arm/mach-omap2/clock24xx.h @@ -626,6 +626,7 @@ static struct clk func_32k_ck = { .rate = 32000, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X | RATE_FIXED | ALWAYS_ENABLED | RATE_PROPAGATES, + .clkdm_name = "wkup_clkdm", .recalc = &propagate_rate, }; @@ -634,17 +635,19 @@ static struct clk osc_ck = { /* (*12, *13, 19.2, *26, 38.4)MHz */ .name = "osc_ck", .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X | RATE_PROPAGATES, + .clkdm_name = "wkup_clkdm", .enable = &omap2_enable_osc_ck, .disable = &omap2_disable_osc_ck, .recalc = &omap2_osc_clk_recalc, }; -/* With out modem likely 12MHz, with modem likely 13MHz */ +/* Without modem likely 12MHz, with modem likely 13MHz */ static struct clk sys_ck = { /* (*12, *13, 19.2, 26, 38.4)MHz */ .name = "sys_ck", /* ~ ref_clk also */ .parent = &osc_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X | ALWAYS_ENABLED | RATE_PROPAGATES, + .clkdm_name = "wkup_clkdm", .recalc = &omap2_sys_clk_recalc, }; @@ -653,6 +656,7 @@ static struct clk alt_ck = { /* Typical 54M or 48M, may not exist */ .rate = 54000000, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X | RATE_FIXED | ALWAYS_ENABLED | RATE_PROPAGATES, + .clkdm_name = "wkup_clkdm", .recalc = &propagate_rate, }; @@ -684,6 +688,7 @@ static struct clk dpll_ck = { .dpll_data = &dpll_dd, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X | RATE_PROPAGATES | ALWAYS_ENABLED, + .clkdm_name = "wkup_clkdm", .recalc = &omap2_dpllcore_recalc, .set_rate = &omap2_reprogram_dpllcore, }; @@ -694,6 +699,7 @@ static struct clk apll96_ck = { .rate = 96000000, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X | RATE_FIXED | RATE_PROPAGATES | ENABLE_ON_INIT, + .clkdm_name = "wkup_clkdm", .enable_reg = OMAP_CM_REGADDR(PLL_MOD, CM_CLKEN), .enable_bit = OMAP24XX_EN_96M_PLL_SHIFT, .enable = &omap2_clk_fixed_enable, @@ -707,6 +713,7 @@ static struct clk apll54_ck = { .rate = 54000000, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X | RATE_FIXED | RATE_PROPAGATES | ENABLE_ON_INIT, + .clkdm_name = "wkup_clkdm", .enable_reg = OMAP_CM_REGADDR(PLL_MOD, CM_CLKEN), .enable_bit = OMAP24XX_EN_54M_PLL_SHIFT, .enable = &omap2_clk_fixed_enable, @@ -741,6 +748,7 @@ static struct clk func_54m_ck = { .parent = &apll54_ck, /* can also be alt_clk */ .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X | RATE_PROPAGATES | PARENT_CONTROLS_CLOCK, + .clkdm_name = "wkup_clkdm", .init = &omap2_init_clksel_parent, .clksel_reg = OMAP_CM_REGADDR(PLL_MOD, CM_CLKSEL1), .clksel_mask = OMAP24XX_54M_SOURCE, @@ -753,6 +761,7 @@ static struct clk core_ck = { .parent = &dpll_ck, /* can also be 32k */ .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X | ALWAYS_ENABLED | RATE_PROPAGATES, + .clkdm_name = "wkup_clkdm", .recalc = &followparent_recalc, }; @@ -779,6 +788,7 @@ static struct clk func_96m_ck = { .parent = &apll96_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X | RATE_PROPAGATES | PARENT_CONTROLS_CLOCK, + .clkdm_name = "wkup_clkdm", .init = &omap2_init_clksel_parent, .clksel_reg = OMAP_CM_REGADDR(PLL_MOD, CM_CLKSEL1), .clksel_mask = OMAP2430_96M_SOURCE, @@ -811,6 +821,7 @@ static struct clk func_48m_ck = { .parent = &apll96_ck, /* 96M or Alt */ .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X | RATE_PROPAGATES | PARENT_CONTROLS_CLOCK, + .clkdm_name = "wkup_clkdm", .init = &omap2_init_clksel_parent, .clksel_reg = OMAP_CM_REGADDR(PLL_MOD, CM_CLKSEL1), .clksel_mask = OMAP24XX_48M_SOURCE, @@ -826,6 +837,7 @@ static struct clk func_12m_ck = { .fixed_div = 4, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X | RATE_PROPAGATES | PARENT_CONTROLS_CLOCK, + .clkdm_name = "wkup_clkdm", .recalc = &omap2_fixed_divisor_recalc, }; @@ -878,6 +890,7 @@ static struct clk sys_clkout_src = { .parent = &func_54m_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X | RATE_PROPAGATES, + .clkdm_name = "wkup_clkdm", .enable_reg = OMAP24XX_PRCM_CLKOUT_CTRL, .enable_bit = OMAP24XX_CLKOUT_EN_SHIFT, .init = &omap2_init_clksel_parent, @@ -908,6 +921,7 @@ static struct clk sys_clkout = { .parent = &sys_clkout_src, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X | PARENT_CONTROLS_CLOCK, + .clkdm_name = "wkup_clkdm", .clksel_reg = OMAP24XX_PRCM_CLKOUT_CTRL, .clksel_mask = OMAP24XX_CLKOUT_DIV_MASK, .clksel = sys_clkout_clksel, @@ -921,6 +935,7 @@ static struct clk sys_clkout2_src = { .name = "sys_clkout2_src", .parent = &func_54m_ck, .flags = CLOCK_IN_OMAP242X | RATE_PROPAGATES, + .clkdm_name = "wkup_clkdm", .enable_reg = OMAP24XX_PRCM_CLKOUT_CTRL, .enable_bit = OMAP2420_CLKOUT2_EN_SHIFT, .init = &omap2_init_clksel_parent, @@ -942,6 +957,7 @@ static struct clk sys_clkout2 = { .name = "sys_clkout2", .parent = &sys_clkout2_src, .flags = CLOCK_IN_OMAP242X | PARENT_CONTROLS_CLOCK, + .clkdm_name = "wkup_clkdm", .clksel_reg = OMAP24XX_PRCM_CLKOUT_CTRL, .clksel_mask = OMAP2420_CLKOUT2_DIV_MASK, .clksel = sys_clkout2_clksel, @@ -954,6 +970,7 @@ static struct clk emul_ck = { .name = "emul_ck", .parent = &func_54m_ck, .flags = CLOCK_IN_OMAP242X, + .clkdm_name = "wkup_clkdm", .enable_reg = OMAP24XX_PRCM_CLKEMUL_CTRL, .enable_bit = OMAP24XX_EMULATION_EN_SHIFT, .recalc = &followparent_recalc, @@ -990,12 +1007,13 @@ static struct clk mpu_ck = { /* Control cpu */ .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X | ALWAYS_ENABLED | DELAYED_APP | CONFIG_PARTICIPANT | RATE_PROPAGATES, + .clkdm_name = "mpu_clkdm", .init = &omap2_init_clksel_parent, .clksel_reg = OMAP_CM_REGADDR(MPU_MOD, CM_CLKSEL), .clksel_mask = OMAP24XX_CLKSEL_MPU_MASK, .clksel = mpu_clksel, .recalc = &omap2_clksel_recalc, - .round_rate = &omap2_clksel_round_rate, + .round_rate = &omap2_clksel_round_rate, .set_rate = &omap2_clksel_set_rate }; @@ -1031,6 +1049,7 @@ static struct clk dsp_fck = { .parent = &core_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X | DELAYED_APP | CONFIG_PARTICIPANT | RATE_PROPAGATES, + .clkdm_name = "dsp_clkdm", .enable_reg = OMAP_CM_REGADDR(OMAP24XX_DSP_MOD, CM_FCLKEN), .enable_bit = OMAP24XX_CM_FCLKEN_DSP_EN_DSP_SHIFT, .clksel_reg = OMAP_CM_REGADDR(OMAP24XX_DSP_MOD, CM_CLKSEL), @@ -1054,10 +1073,7 @@ static const struct clksel dsp_irate_ick_clksel[] = { { .parent = NULL } }; -/* - * This clock does not exist as such in the TRM, but is added to - * separate source selection from XXX - */ +/* This clock does not exist as such in the TRM. */ static struct clk dsp_irate_ick = { .name = "dsp_irate_ick", .parent = &dsp_fck, @@ -1089,11 +1105,17 @@ static struct clk iva2_1_ick = { .enable_bit = OMAP24XX_CM_FCLKEN_DSP_EN_DSP_SHIFT, }; +/* + * The IVA1 is an ARM7 core on the 2420 that has nothing to do with + * the C54x, but which is contained in the DSP powerdomain. Does not + * exist on later OMAPs. + */ static struct clk iva1_ifck = { .name = "iva1_ifck", .parent = &core_ck, .flags = CLOCK_IN_OMAP242X | CONFIG_PARTICIPANT | RATE_PROPAGATES | DELAYED_APP, + .clkdm_name = "iva1_clkdm", .enable_reg = OMAP_CM_REGADDR(OMAP24XX_DSP_MOD, CM_FCLKEN), .enable_bit = OMAP2420_EN_IVA_COP_SHIFT, .clksel_reg = OMAP_CM_REGADDR(OMAP24XX_DSP_MOD, CM_CLKSEL), @@ -1109,6 +1131,7 @@ static struct clk iva1_mpu_int_ifck = { .name = "iva1_mpu_int_ifck", .parent = &iva1_ifck, .flags = CLOCK_IN_OMAP242X, + .clkdm_name = "iva1_clkdm", .enable_reg = OMAP_CM_REGADDR(OMAP24XX_DSP_MOD, CM_FCLKEN), .enable_bit = OMAP2420_EN_IVA_MPU_SHIFT, .fixed_div = 2, @@ -1156,6 +1179,7 @@ static struct clk core_l3_ck = { /* Used for ick and fck, interconnect */ .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X | ALWAYS_ENABLED | DELAYED_APP | CONFIG_PARTICIPANT | RATE_PROPAGATES, + .clkdm_name = "core_l3_clkdm", .clksel_reg = OMAP_CM_REGADDR(CORE_MOD, CM_CLKSEL1), .clksel_mask = OMAP24XX_CLKSEL_L3_MASK, .clksel = core_l3_clksel, @@ -1177,11 +1201,13 @@ static const struct clksel usb_l4_ick_clksel[] = { { .parent = NULL }, }; +/* It is unclear from TRM whether usb_l4_ick is really in L3 or L4 clkdm */ static struct clk usb_l4_ick = { /* FS-USB interface clock */ .name = "usb_l4_ick", .parent = &core_l3_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X | DELAYED_APP | CONFIG_PARTICIPANT, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN2), .enable_bit = OMAP24XX_EN_USB_SHIFT, .clksel_reg = OMAP_CM_REGADDR(CORE_MOD, CM_CLKSEL1), @@ -1193,10 +1219,42 @@ static struct clk usb_l4_ick = { /* FS-USB interface clock */ }; /* + * L4 clock management domain + * + * This domain contains lots of interface clocks from the L4 interface, some + * functional clocks. Fixed APLL functional source clocks are managed in + * this domain. + */ +static const struct clksel_rate l4_core_l3_rates[] = { + { .div = 1, .val = 1, .flags = RATE_IN_24XX | DEFAULT_RATE }, + { .div = 2, .val = 2, .flags = RATE_IN_24XX }, + { .div = 0 } +}; + +static const struct clksel l4_clksel[] = { + { .parent = &core_l3_ck, .rates = l4_core_l3_rates }, + { .parent = NULL } +}; + +static struct clk l4_ck = { /* used both as an ick and fck */ + .name = "l4_ck", + .parent = &core_l3_ck, + .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X | + ALWAYS_ENABLED | DELAYED_APP | RATE_PROPAGATES, + .clkdm_name = "core_l4_clkdm", + .clksel_reg = OMAP_CM_REGADDR(CORE_MOD, CM_CLKSEL1), + .clksel_mask = OMAP24XX_CLKSEL_L4_MASK, + .clksel = l4_clksel, + .recalc = &omap2_clksel_recalc, + .round_rate = &omap2_clksel_round_rate, + .set_rate = &omap2_clksel_set_rate +}; + +/* * SSI is in L3 management domain, its direct parent is core not l3, * many core power domain entities are grouped into the L3 clock * domain. - * SSI_SSR_FCLK, SSI_SST_FCLK, SSI_L4_CLIK + * SSI_SSR_FCLK, SSI_SST_FCLK, SSI_L4_ICLK * * ssr = core/1/2/3/4/5, sst = 1/2 ssr. */ @@ -1221,6 +1279,7 @@ static struct clk ssi_ssr_sst_fck = { .parent = &core_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X | DELAYED_APP, + .clkdm_name = "core_l3_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, OMAP24XX_CM_FCLKEN2), .enable_bit = OMAP24XX_EN_SSI_SHIFT, .clksel_reg = OMAP_CM_REGADDR(CORE_MOD, CM_CLKSEL1), @@ -1231,6 +1290,7 @@ static struct clk ssi_ssr_sst_fck = { .set_rate = &omap2_clksel_set_rate }; + /* * GFX clock domain * Clocks: @@ -1254,6 +1314,7 @@ static struct clk gfx_3d_fck = { .name = "gfx_3d_fck", .parent = &core_l3_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X, + .clkdm_name = "gfx_clkdm", .enable_reg = OMAP_CM_REGADDR(GFX_MOD, CM_FCLKEN), .enable_bit = OMAP24XX_EN_3D_SHIFT, .clksel_reg = OMAP_CM_REGADDR(GFX_MOD, CM_CLKSEL), @@ -1268,6 +1329,7 @@ static struct clk gfx_2d_fck = { .name = "gfx_2d_fck", .parent = &core_l3_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X, + .clkdm_name = "gfx_clkdm", .enable_reg = OMAP_CM_REGADDR(GFX_MOD, CM_FCLKEN), .enable_bit = OMAP24XX_EN_2D_SHIFT, .clksel_reg = OMAP_CM_REGADDR(GFX_MOD, CM_CLKSEL), @@ -1282,6 +1344,7 @@ static struct clk gfx_ick = { .name = "gfx_ick", /* From l3 */ .parent = &core_l3_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X, + .clkdm_name = "gfx_clkdm", .enable_reg = OMAP_CM_REGADDR(GFX_MOD, CM_ICLKEN), .enable_bit = OMAP_EN_GFX_SHIFT, .recalc = &followparent_recalc, @@ -1311,6 +1374,7 @@ static struct clk mdm_ick = { /* used both as a ick and fck */ .name = "mdm_ick", .parent = &core_ck, .flags = CLOCK_IN_OMAP243X | DELAYED_APP | CONFIG_PARTICIPANT, + .clkdm_name = "mdm_clkdm", .enable_reg = OMAP_CM_REGADDR(OMAP2430_MDM_MOD, CM_ICLKEN), .enable_bit = OMAP2430_CM_ICLKEN_MDM_EN_MDM_SHIFT, .clksel_reg = OMAP_CM_REGADDR(OMAP2430_MDM_MOD, CM_CLKSEL), @@ -1325,52 +1389,13 @@ static struct clk mdm_osc_ck = { .name = "mdm_osc_ck", .parent = &osc_ck, .flags = CLOCK_IN_OMAP243X, + .clkdm_name = "mdm_clkdm", .enable_reg = OMAP_CM_REGADDR(OMAP2430_MDM_MOD, CM_FCLKEN), .enable_bit = OMAP2430_EN_OSC_SHIFT, .recalc = &followparent_recalc, }; /* - * L4 clock management domain - * - * This domain contains lots of interface clocks from the L4 interface, some - * functional clocks. Fixed APLL functional source clocks are managed in - * this domain. - */ -static const struct clksel_rate l4_core_l3_rates[] = { - { .div = 1, .val = 1, .flags = RATE_IN_24XX | DEFAULT_RATE }, - { .div = 2, .val = 2, .flags = RATE_IN_24XX }, - { .div = 0 } -}; - -static const struct clksel l4_clksel[] = { - { .parent = &core_l3_ck, .rates = l4_core_l3_rates }, - { .parent = NULL } -}; - -static struct clk l4_ck = { /* used both as an ick and fck */ - .name = "l4_ck", - .parent = &core_l3_ck, - .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X | - ALWAYS_ENABLED | DELAYED_APP | RATE_PROPAGATES, - .clksel_reg = OMAP_CM_REGADDR(CORE_MOD, CM_CLKSEL1), - .clksel_mask = OMAP24XX_CLKSEL_L4_MASK, - .clksel = l4_clksel, - .recalc = &omap2_clksel_recalc, - .round_rate = &omap2_clksel_round_rate, - .set_rate = &omap2_clksel_set_rate -}; - -static struct clk ssi_l4_ick = { - .name = "ssi_l4_ick", - .parent = &l4_ck, - .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X, - .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN2), - .enable_bit = OMAP24XX_EN_SSI_SHIFT, - .recalc = &followparent_recalc, -}; - -/* * DSS clock domain * CLOCKs: * DSS_L4_ICLK, DSS_L3_ICLK, @@ -1409,6 +1434,7 @@ static struct clk dss_ick = { /* Enables both L3,L4 ICLK's */ .name = "dss_ick", .parent = &l4_ck, /* really both l3 and l4 */ .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X, + .clkdm_name = "dss_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN1), .enable_bit = OMAP24XX_EN_DSS1_SHIFT, .recalc = &followparent_recalc, @@ -1419,6 +1445,7 @@ static struct clk dss1_fck = { .parent = &core_ck, /* Core or sys */ .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X | DELAYED_APP, + .clkdm_name = "dss_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_FCLKEN1), .enable_bit = OMAP24XX_EN_DSS1_SHIFT, .init = &omap2_init_clksel_parent, @@ -1451,6 +1478,7 @@ static struct clk dss2_fck = { /* Alt clk used in power management */ .parent = &sys_ck, /* fixed at sys_ck or 48MHz */ .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X | DELAYED_APP, + .clkdm_name = "dss_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_FCLKEN1), .enable_bit = OMAP24XX_EN_DSS2_SHIFT, .init = &omap2_init_clksel_parent, @@ -1464,6 +1492,7 @@ static struct clk dss_54m_fck = { /* Alt clk used in power management */ .name = "dss_54m_fck", /* 54m tv clk */ .parent = &func_54m_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X, + .clkdm_name = "dss_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_FCLKEN1), .enable_bit = OMAP24XX_EN_TV_SHIFT, .recalc = &followparent_recalc, @@ -1491,6 +1520,7 @@ static struct clk gpt1_ick = { .name = "gpt1_ick", .parent = &l4_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(WKUP_MOD, CM_ICLKEN), .enable_bit = OMAP24XX_EN_GPT1_SHIFT, .recalc = &followparent_recalc, @@ -1500,6 +1530,7 @@ static struct clk gpt1_fck = { .name = "gpt1_fck", .parent = &func_32k_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(WKUP_MOD, CM_FCLKEN), .enable_bit = OMAP24XX_EN_GPT1_SHIFT, .init = &omap2_init_clksel_parent, @@ -1515,6 +1546,7 @@ static struct clk gpt2_ick = { .name = "gpt2_ick", .parent = &l4_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN1), .enable_bit = OMAP24XX_EN_GPT2_SHIFT, .recalc = &followparent_recalc, @@ -1524,6 +1556,7 @@ static struct clk gpt2_fck = { .name = "gpt2_fck", .parent = &func_32k_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_FCLKEN1), .enable_bit = OMAP24XX_EN_GPT2_SHIFT, .init = &omap2_init_clksel_parent, @@ -1537,6 +1570,7 @@ static struct clk gpt3_ick = { .name = "gpt3_ick", .parent = &l4_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN1), .enable_bit = OMAP24XX_EN_GPT3_SHIFT, .recalc = &followparent_recalc, @@ -1546,6 +1580,7 @@ static struct clk gpt3_fck = { .name = "gpt3_fck", .parent = &func_32k_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_FCLKEN1), .enable_bit = OMAP24XX_EN_GPT3_SHIFT, .init = &omap2_init_clksel_parent, @@ -1559,6 +1594,7 @@ static struct clk gpt4_ick = { .name = "gpt4_ick", .parent = &l4_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN1), .enable_bit = OMAP24XX_EN_GPT4_SHIFT, .recalc = &followparent_recalc, @@ -1568,6 +1604,7 @@ static struct clk gpt4_fck = { .name = "gpt4_fck", .parent = &func_32k_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_FCLKEN1), .enable_bit = OMAP24XX_EN_GPT4_SHIFT, .init = &omap2_init_clksel_parent, @@ -1581,6 +1618,7 @@ static struct clk gpt5_ick = { .name = "gpt5_ick", .parent = &l4_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN1), .enable_bit = OMAP24XX_EN_GPT5_SHIFT, .recalc = &followparent_recalc, @@ -1590,6 +1628,7 @@ static struct clk gpt5_fck = { .name = "gpt5_fck", .parent = &func_32k_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_FCLKEN1), .enable_bit = OMAP24XX_EN_GPT5_SHIFT, .init = &omap2_init_clksel_parent, @@ -1603,6 +1642,7 @@ static struct clk gpt6_ick = { .name = "gpt6_ick", .parent = &l4_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN1), .enable_bit = OMAP24XX_EN_GPT6_SHIFT, .recalc = &followparent_recalc, @@ -1612,6 +1652,7 @@ static struct clk gpt6_fck = { .name = "gpt6_fck", .parent = &func_32k_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_FCLKEN1), .enable_bit = OMAP24XX_EN_GPT6_SHIFT, .init = &omap2_init_clksel_parent, @@ -1634,6 +1675,7 @@ static struct clk gpt7_fck = { .name = "gpt7_fck", .parent = &func_32k_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_FCLKEN1), .enable_bit = OMAP24XX_EN_GPT7_SHIFT, .init = &omap2_init_clksel_parent, @@ -1647,6 +1689,7 @@ static struct clk gpt8_ick = { .name = "gpt8_ick", .parent = &l4_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN1), .enable_bit = OMAP24XX_EN_GPT8_SHIFT, .recalc = &followparent_recalc, @@ -1656,6 +1699,7 @@ static struct clk gpt8_fck = { .name = "gpt8_fck", .parent = &func_32k_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_FCLKEN1), .enable_bit = OMAP24XX_EN_GPT8_SHIFT, .init = &omap2_init_clksel_parent, @@ -1669,6 +1713,7 @@ static struct clk gpt9_ick = { .name = "gpt9_ick", .parent = &l4_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN1), .enable_bit = OMAP24XX_EN_GPT9_SHIFT, .recalc = &followparent_recalc, @@ -1678,6 +1723,7 @@ static struct clk gpt9_fck = { .name = "gpt9_fck", .parent = &func_32k_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_FCLKEN1), .enable_bit = OMAP24XX_EN_GPT9_SHIFT, .init = &omap2_init_clksel_parent, @@ -1691,6 +1737,7 @@ static struct clk gpt10_ick = { .name = "gpt10_ick", .parent = &l4_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN1), .enable_bit = OMAP24XX_EN_GPT10_SHIFT, .recalc = &followparent_recalc, @@ -1700,6 +1747,7 @@ static struct clk gpt10_fck = { .name = "gpt10_fck", .parent = &func_32k_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_FCLKEN1), .enable_bit = OMAP24XX_EN_GPT10_SHIFT, .init = &omap2_init_clksel_parent, @@ -1713,6 +1761,7 @@ static struct clk gpt11_ick = { .name = "gpt11_ick", .parent = &l4_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN1), .enable_bit = OMAP24XX_EN_GPT11_SHIFT, .recalc = &followparent_recalc, @@ -1722,6 +1771,7 @@ static struct clk gpt11_fck = { .name = "gpt11_fck", .parent = &func_32k_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_FCLKEN1), .enable_bit = OMAP24XX_EN_GPT11_SHIFT, .init = &omap2_init_clksel_parent, @@ -1735,6 +1785,7 @@ static struct clk gpt12_ick = { .name = "gpt12_ick", .parent = &l4_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN1), .enable_bit = OMAP24XX_EN_GPT12_SHIFT, .recalc = &followparent_recalc, @@ -1744,6 +1795,7 @@ static struct clk gpt12_fck = { .name = "gpt12_fck", .parent = &func_32k_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_FCLKEN1), .enable_bit = OMAP24XX_EN_GPT12_SHIFT, .init = &omap2_init_clksel_parent, @@ -1758,6 +1810,7 @@ static struct clk mcbsp1_ick = { .id = 1, .parent = &l4_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN1), .enable_bit = OMAP24XX_EN_MCBSP1_SHIFT, .recalc = &followparent_recalc, @@ -1768,6 +1821,7 @@ static struct clk mcbsp1_fck = { .id = 1, .parent = &func_96m_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_FCLKEN1), .enable_bit = OMAP24XX_EN_MCBSP1_SHIFT, .recalc = &followparent_recalc, @@ -1778,6 +1832,7 @@ static struct clk mcbsp2_ick = { .id = 2, .parent = &l4_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN1), .enable_bit = OMAP24XX_EN_MCBSP2_SHIFT, .recalc = &followparent_recalc, @@ -1788,6 +1843,7 @@ static struct clk mcbsp2_fck = { .id = 2, .parent = &func_96m_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_FCLKEN1), .enable_bit = OMAP24XX_EN_MCBSP2_SHIFT, .recalc = &followparent_recalc, @@ -1798,6 +1854,7 @@ static struct clk mcbsp3_ick = { .id = 3, .parent = &l4_ck, .flags = CLOCK_IN_OMAP243X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN2), .enable_bit = OMAP2430_EN_MCBSP3_SHIFT, .recalc = &followparent_recalc, @@ -1808,6 +1865,7 @@ static struct clk mcbsp3_fck = { .id = 3, .parent = &func_96m_ck, .flags = CLOCK_IN_OMAP243X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, OMAP24XX_CM_FCLKEN2), .enable_bit = OMAP2430_EN_MCBSP3_SHIFT, .recalc = &followparent_recalc, @@ -1818,6 +1876,7 @@ static struct clk mcbsp4_ick = { .id = 4, .parent = &l4_ck, .flags = CLOCK_IN_OMAP243X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN2), .enable_bit = OMAP2430_EN_MCBSP4_SHIFT, .recalc = &followparent_recalc, @@ -1828,6 +1887,7 @@ static struct clk mcbsp4_fck = { .id = 4, .parent = &func_96m_ck, .flags = CLOCK_IN_OMAP243X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, OMAP24XX_CM_FCLKEN2), .enable_bit = OMAP2430_EN_MCBSP4_SHIFT, .recalc = &followparent_recalc, @@ -1838,6 +1898,7 @@ static struct clk mcbsp5_ick = { .id = 5, .parent = &l4_ck, .flags = CLOCK_IN_OMAP243X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN2), .enable_bit = OMAP2430_EN_MCBSP5_SHIFT, .recalc = &followparent_recalc, @@ -1848,6 +1909,7 @@ static struct clk mcbsp5_fck = { .id = 5, .parent = &func_96m_ck, .flags = CLOCK_IN_OMAP243X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, OMAP24XX_CM_FCLKEN2), .enable_bit = OMAP2430_EN_MCBSP5_SHIFT, .recalc = &followparent_recalc, @@ -1857,6 +1919,7 @@ static struct clk mcspi1_ick = { .name = "mcspi_ick", .id = 1, .parent = &l4_ck, + .clkdm_name = "core_l4_clkdm", .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X, .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN1), .enable_bit = OMAP24XX_EN_MCSPI1_SHIFT, @@ -1868,6 +1931,7 @@ static struct clk mcspi1_fck = { .id = 1, .parent = &func_48m_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_FCLKEN1), .enable_bit = OMAP24XX_EN_MCSPI1_SHIFT, .recalc = &followparent_recalc, @@ -1878,6 +1942,7 @@ static struct clk mcspi2_ick = { .id = 2, .parent = &l4_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN1), .enable_bit = OMAP24XX_EN_MCSPI2_SHIFT, .recalc = &followparent_recalc, @@ -1888,6 +1953,7 @@ static struct clk mcspi2_fck = { .id = 2, .parent = &func_48m_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_FCLKEN1), .enable_bit = OMAP24XX_EN_MCSPI2_SHIFT, .recalc = &followparent_recalc, @@ -1898,6 +1964,7 @@ static struct clk mcspi3_ick = { .id = 3, .parent = &l4_ck, .flags = CLOCK_IN_OMAP243X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN2), .enable_bit = OMAP2430_EN_MCSPI3_SHIFT, .recalc = &followparent_recalc, @@ -1908,6 +1975,7 @@ static struct clk mcspi3_fck = { .id = 3, .parent = &func_48m_ck, .flags = CLOCK_IN_OMAP243X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, OMAP24XX_CM_FCLKEN2), .enable_bit = OMAP2430_EN_MCSPI3_SHIFT, .recalc = &followparent_recalc, @@ -1917,6 +1985,7 @@ static struct clk uart1_ick = { .name = "uart1_ick", .parent = &l4_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN1), .enable_bit = OMAP24XX_EN_UART1_SHIFT, .recalc = &followparent_recalc, @@ -1926,6 +1995,7 @@ static struct clk uart1_fck = { .name = "uart1_fck", .parent = &func_48m_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_FCLKEN1), .enable_bit = OMAP24XX_EN_UART1_SHIFT, .recalc = &followparent_recalc, @@ -1935,6 +2005,7 @@ static struct clk uart2_ick = { .name = "uart2_ick", .parent = &l4_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN1), .enable_bit = OMAP24XX_EN_UART2_SHIFT, .recalc = &followparent_recalc, @@ -1944,6 +2015,7 @@ static struct clk uart2_fck = { .name = "uart2_fck", .parent = &func_48m_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_FCLKEN1), .enable_bit = OMAP24XX_EN_UART2_SHIFT, .recalc = &followparent_recalc, @@ -1953,6 +2025,7 @@ static struct clk uart3_ick = { .name = "uart3_ick", .parent = &l4_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN2), .enable_bit = OMAP24XX_EN_UART3_SHIFT, .recalc = &followparent_recalc, @@ -1962,6 +2035,7 @@ static struct clk uart3_fck = { .name = "uart3_fck", .parent = &func_48m_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, OMAP24XX_CM_FCLKEN2), .enable_bit = OMAP24XX_EN_UART3_SHIFT, .recalc = &followparent_recalc, @@ -1971,6 +2045,7 @@ static struct clk gpios_ick = { .name = "gpios_ick", .parent = &l4_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(WKUP_MOD, CM_ICLKEN), .enable_bit = OMAP24XX_EN_GPIOS_SHIFT, .recalc = &followparent_recalc, @@ -1980,6 +2055,7 @@ static struct clk gpios_fck = { .name = "gpios_fck", .parent = &func_32k_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X, + .clkdm_name = "wkup_clkdm", .enable_reg = OMAP_CM_REGADDR(WKUP_MOD, CM_FCLKEN), .enable_bit = OMAP24XX_EN_GPIOS_SHIFT, .recalc = &followparent_recalc, @@ -1989,6 +2065,7 @@ static struct clk mpu_wdt_ick = { .name = "mpu_wdt_ick", .parent = &l4_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(WKUP_MOD, CM_ICLKEN), .enable_bit = OMAP24XX_EN_MPU_WDT_SHIFT, .recalc = &followparent_recalc, @@ -1998,6 +2075,7 @@ static struct clk mpu_wdt_fck = { .name = "mpu_wdt_fck", .parent = &func_32k_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X, + .clkdm_name = "wkup_clkdm", .enable_reg = OMAP_CM_REGADDR(WKUP_MOD, CM_FCLKEN), .enable_bit = OMAP24XX_EN_MPU_WDT_SHIFT, .recalc = &followparent_recalc, @@ -2006,31 +2084,40 @@ static struct clk mpu_wdt_fck = { static struct clk sync_32k_ick = { .name = "sync_32k_ick", .parent = &l4_ck, - .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X | ENABLE_ON_INIT, + .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X | + ENABLE_ON_INIT, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(WKUP_MOD, CM_ICLKEN), .enable_bit = OMAP24XX_EN_32KSYNC_SHIFT, .recalc = &followparent_recalc, }; + static struct clk wdt1_ick = { .name = "wdt1_ick", .parent = &l4_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(WKUP_MOD, CM_ICLKEN), .enable_bit = OMAP24XX_EN_WDT1_SHIFT, .recalc = &followparent_recalc, }; + static struct clk omapctrl_ick = { .name = "omapctrl_ick", .parent = &l4_ck, - .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X | ENABLE_ON_INIT, + .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X | + ENABLE_ON_INIT, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(WKUP_MOD, CM_ICLKEN), .enable_bit = OMAP24XX_EN_OMAPCTRL_SHIFT, .recalc = &followparent_recalc, }; + static struct clk icr_ick = { .name = "icr_ick", .parent = &l4_ck, .flags = CLOCK_IN_OMAP243X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(WKUP_MOD, CM_ICLKEN), .enable_bit = OMAP2430_EN_ICR_SHIFT, .recalc = &followparent_recalc, @@ -2040,15 +2127,22 @@ static struct clk cam_ick = { .name = "cam_ick", .parent = &l4_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN1), .enable_bit = OMAP24XX_EN_CAM_SHIFT, .recalc = &followparent_recalc, }; +/* + * cam_fck controls both CAM_MCLK and CAM_FCLK. It should probably be + * split into two separate clocks, since the parent clocks are different + * and the clockdomains are also different. + */ static struct clk cam_fck = { .name = "cam_fck", .parent = &func_96m_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X, + .clkdm_name = "core_l3_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_FCLKEN1), .enable_bit = OMAP24XX_EN_CAM_SHIFT, .recalc = &followparent_recalc, @@ -2058,6 +2152,7 @@ static struct clk mailboxes_ick = { .name = "mailboxes_ick", .parent = &l4_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN1), .enable_bit = OMAP24XX_EN_MAILBOXES_SHIFT, .recalc = &followparent_recalc, @@ -2067,6 +2162,7 @@ static struct clk wdt4_ick = { .name = "wdt4_ick", .parent = &l4_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN1), .enable_bit = OMAP24XX_EN_WDT4_SHIFT, .recalc = &followparent_recalc, @@ -2076,6 +2172,7 @@ static struct clk wdt4_fck = { .name = "wdt4_fck", .parent = &func_32k_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_FCLKEN1), .enable_bit = OMAP24XX_EN_WDT4_SHIFT, .recalc = &followparent_recalc, @@ -2085,6 +2182,7 @@ static struct clk wdt3_ick = { .name = "wdt3_ick", .parent = &l4_ck, .flags = CLOCK_IN_OMAP242X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN1), .enable_bit = OMAP2420_EN_WDT3_SHIFT, .recalc = &followparent_recalc, @@ -2094,6 +2192,7 @@ static struct clk wdt3_fck = { .name = "wdt3_fck", .parent = &func_32k_ck, .flags = CLOCK_IN_OMAP242X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_FCLKEN1), .enable_bit = OMAP2420_EN_WDT3_SHIFT, .recalc = &followparent_recalc, @@ -2103,6 +2202,7 @@ static struct clk mspro_ick = { .name = "mspro_ick", .parent = &l4_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN1), .enable_bit = OMAP24XX_EN_MSPRO_SHIFT, .recalc = &followparent_recalc, @@ -2112,6 +2212,7 @@ static struct clk mspro_fck = { .name = "mspro_fck", .parent = &func_96m_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_FCLKEN1), .enable_bit = OMAP24XX_EN_MSPRO_SHIFT, .recalc = &followparent_recalc, @@ -2121,6 +2222,7 @@ static struct clk mmc_ick = { .name = "mmc_ick", .parent = &l4_ck, .flags = CLOCK_IN_OMAP242X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN1), .enable_bit = OMAP2420_EN_MMC_SHIFT, .recalc = &followparent_recalc, @@ -2130,6 +2232,7 @@ static struct clk mmc_fck = { .name = "mmc_fck", .parent = &func_96m_ck, .flags = CLOCK_IN_OMAP242X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_FCLKEN1), .enable_bit = OMAP2420_EN_MMC_SHIFT, .recalc = &followparent_recalc, @@ -2139,6 +2242,7 @@ static struct clk fac_ick = { .name = "fac_ick", .parent = &l4_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN1), .enable_bit = OMAP24XX_EN_FAC_SHIFT, .recalc = &followparent_recalc, @@ -2148,6 +2252,7 @@ static struct clk fac_fck = { .name = "fac_fck", .parent = &func_12m_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_FCLKEN1), .enable_bit = OMAP24XX_EN_FAC_SHIFT, .recalc = &followparent_recalc, @@ -2157,6 +2262,7 @@ static struct clk eac_ick = { .name = "eac_ick", .parent = &l4_ck, .flags = CLOCK_IN_OMAP242X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN1), .enable_bit = OMAP2420_EN_EAC_SHIFT, .recalc = &followparent_recalc, @@ -2166,6 +2272,7 @@ static struct clk eac_fck = { .name = "eac_fck", .parent = &func_96m_ck, .flags = CLOCK_IN_OMAP242X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_FCLKEN1), .enable_bit = OMAP2420_EN_EAC_SHIFT, .recalc = &followparent_recalc, @@ -2175,6 +2282,7 @@ static struct clk hdq_ick = { .name = "hdq_ick", .parent = &l4_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN1), .enable_bit = OMAP24XX_EN_HDQ_SHIFT, .recalc = &followparent_recalc, @@ -2184,6 +2292,7 @@ static struct clk hdq_fck = { .name = "hdq_fck", .parent = &func_12m_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_FCLKEN1), .enable_bit = OMAP24XX_EN_HDQ_SHIFT, .recalc = &followparent_recalc, @@ -2194,6 +2303,7 @@ static struct clk i2c2_ick = { .id = 2, .parent = &l4_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN1), .enable_bit = OMAP2420_EN_I2C2_SHIFT, .recalc = &followparent_recalc, @@ -2204,6 +2314,7 @@ static struct clk i2c2_fck = { .id = 2, .parent = &func_12m_ck, .flags = CLOCK_IN_OMAP242X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_FCLKEN1), .enable_bit = OMAP2420_EN_I2C2_SHIFT, .recalc = &followparent_recalc, @@ -2214,6 +2325,7 @@ static struct clk i2chs2_fck = { .id = 2, .parent = &func_96m_ck, .flags = CLOCK_IN_OMAP243X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, OMAP24XX_CM_FCLKEN2), .enable_bit = OMAP2430_EN_I2CHS2_SHIFT, .recalc = &followparent_recalc, @@ -2224,6 +2336,7 @@ static struct clk i2c1_ick = { .id = 1, .parent = &l4_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN1), .enable_bit = OMAP2420_EN_I2C1_SHIFT, .recalc = &followparent_recalc, @@ -2234,6 +2347,7 @@ static struct clk i2c1_fck = { .id = 1, .parent = &func_12m_ck, .flags = CLOCK_IN_OMAP242X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_FCLKEN1), .enable_bit = OMAP2420_EN_I2C1_SHIFT, .recalc = &followparent_recalc, @@ -2244,6 +2358,7 @@ static struct clk i2chs1_fck = { .id = 1, .parent = &func_96m_ck, .flags = CLOCK_IN_OMAP243X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, OMAP24XX_CM_FCLKEN2), .enable_bit = OMAP2430_EN_I2CHS1_SHIFT, .recalc = &followparent_recalc, @@ -2252,7 +2367,9 @@ static struct clk i2chs1_fck = { static struct clk gpmc_fck = { .name = "gpmc_fck", .parent = &core_l3_ck, - .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X | ENABLE_ON_INIT, + .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X | + ENABLE_ON_INIT, + .clkdm_name = "core_l3_clkdm", .recalc = &followparent_recalc, }; @@ -2260,6 +2377,7 @@ static struct clk sdma_fck = { .name = "sdma_fck", .parent = &core_l3_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X, + .clkdm_name = "core_l3_clkdm", .recalc = &followparent_recalc, }; @@ -2267,6 +2385,7 @@ static struct clk sdma_ick = { .name = "sdma_ick", .parent = &l4_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X, + .clkdm_name = "core_l3_clkdm", .recalc = &followparent_recalc, }; @@ -2274,6 +2393,7 @@ static struct clk vlynq_ick = { .name = "vlynq_ick", .parent = &core_l3_ck, .flags = CLOCK_IN_OMAP242X, + .clkdm_name = "core_l3_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN1), .enable_bit = OMAP2420_EN_VLYNQ_SHIFT, .recalc = &followparent_recalc, @@ -2308,6 +2428,7 @@ static struct clk vlynq_fck = { .name = "vlynq_fck", .parent = &func_96m_ck, .flags = CLOCK_IN_OMAP242X | DELAYED_APP, + .clkdm_name = "core_l3_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_FCLKEN1), .enable_bit = OMAP2420_EN_VLYNQ_SHIFT, .init = &omap2_init_clksel_parent, @@ -2323,6 +2444,7 @@ static struct clk sdrc_ick = { .name = "sdrc_ick", .parent = &l4_ck, .flags = CLOCK_IN_OMAP243X | ENABLE_ON_INIT, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN3), .enable_bit = OMAP2430_EN_SDRC_SHIFT, .recalc = &followparent_recalc, @@ -2332,6 +2454,7 @@ static struct clk des_ick = { .name = "des_ick", .parent = &l4_ck, .flags = CLOCK_IN_OMAP243X | CLOCK_IN_OMAP242X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, OMAP24XX_CM_ICLKEN4), .enable_bit = OMAP24XX_EN_DES_SHIFT, .recalc = &followparent_recalc, @@ -2341,6 +2464,7 @@ static struct clk sha_ick = { .name = "sha_ick", .parent = &l4_ck, .flags = CLOCK_IN_OMAP243X | CLOCK_IN_OMAP242X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, OMAP24XX_CM_ICLKEN4), .enable_bit = OMAP24XX_EN_SHA_SHIFT, .recalc = &followparent_recalc, @@ -2350,6 +2474,7 @@ static struct clk rng_ick = { .name = "rng_ick", .parent = &l4_ck, .flags = CLOCK_IN_OMAP243X | CLOCK_IN_OMAP242X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, OMAP24XX_CM_ICLKEN4), .enable_bit = OMAP24XX_EN_RNG_SHIFT, .recalc = &followparent_recalc, @@ -2359,6 +2484,7 @@ static struct clk aes_ick = { .name = "aes_ick", .parent = &l4_ck, .flags = CLOCK_IN_OMAP243X | CLOCK_IN_OMAP242X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, OMAP24XX_CM_ICLKEN4), .enable_bit = OMAP24XX_EN_AES_SHIFT, .recalc = &followparent_recalc, @@ -2368,6 +2494,7 @@ static struct clk pka_ick = { .name = "pka_ick", .parent = &l4_ck, .flags = CLOCK_IN_OMAP243X | CLOCK_IN_OMAP242X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, OMAP24XX_CM_ICLKEN4), .enable_bit = OMAP24XX_EN_PKA_SHIFT, .recalc = &followparent_recalc, @@ -2377,6 +2504,7 @@ static struct clk usb_fck = { .name = "usb_fck", .parent = &func_48m_ck, .flags = CLOCK_IN_OMAP243X | CLOCK_IN_OMAP242X, + .clkdm_name = "core_l3_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, OMAP24XX_CM_FCLKEN2), .enable_bit = OMAP24XX_EN_USB_SHIFT, .recalc = &followparent_recalc, @@ -2386,6 +2514,7 @@ static struct clk usbhs_ick = { .name = "usbhs_ick", .parent = &core_l3_ck, .flags = CLOCK_IN_OMAP243X, + .clkdm_name = "core_l3_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN2), .enable_bit = OMAP2430_EN_USBHS_SHIFT, .recalc = &followparent_recalc, @@ -2396,6 +2525,7 @@ static struct clk mmchs1_ick = { .id = 1, .parent = &l4_ck, .flags = CLOCK_IN_OMAP243X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN2), .enable_bit = OMAP2430_EN_MMCHS1_SHIFT, .recalc = &followparent_recalc, @@ -2406,6 +2536,7 @@ static struct clk mmchs1_fck = { .id = 1, .parent = &func_96m_ck, .flags = CLOCK_IN_OMAP243X, + .clkdm_name = "core_l3_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, OMAP24XX_CM_FCLKEN2), .enable_bit = OMAP2430_EN_MMCHS1_SHIFT, .recalc = &followparent_recalc, @@ -2416,6 +2547,7 @@ static struct clk mmchs2_ick = { .id = 2, .parent = &l4_ck, .flags = CLOCK_IN_OMAP243X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN2), .enable_bit = OMAP2430_EN_MMCHS2_SHIFT, .recalc = &followparent_recalc, @@ -2435,6 +2567,7 @@ static struct clk gpio5_ick = { .name = "gpio5_ick", .parent = &l4_ck, .flags = CLOCK_IN_OMAP243X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN2), .enable_bit = OMAP2430_EN_GPIO5_SHIFT, .recalc = &followparent_recalc, @@ -2444,6 +2577,7 @@ static struct clk gpio5_fck = { .name = "gpio5_fck", .parent = &func_32k_ck, .flags = CLOCK_IN_OMAP243X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, OMAP24XX_CM_FCLKEN2), .enable_bit = OMAP2430_EN_GPIO5_SHIFT, .recalc = &followparent_recalc, @@ -2453,6 +2587,7 @@ static struct clk mdm_intc_ick = { .name = "mdm_intc_ick", .parent = &l4_ck, .flags = CLOCK_IN_OMAP243X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN2), .enable_bit = OMAP2430_EN_MDM_INTC_SHIFT, .recalc = &followparent_recalc, @@ -2463,6 +2598,7 @@ static struct clk mmchsdb1_fck = { .id = 1, .parent = &func_32k_ck, .flags = CLOCK_IN_OMAP243X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, OMAP24XX_CM_FCLKEN2), .enable_bit = OMAP2430_EN_MMCHSDB1_SHIFT, .recalc = &followparent_recalc, @@ -2473,6 +2609,7 @@ static struct clk mmchsdb2_fck = { .id = 2, .parent = &func_32k_ck, .flags = CLOCK_IN_OMAP243X, + .clkdm_name = "core_l4_clkdm", .enable_reg = OMAP_CM_REGADDR(CORE_MOD, OMAP24XX_CM_FCLKEN2), .enable_bit = OMAP2430_EN_MMCHSDB2_SHIFT, .recalc = &followparent_recalc, @@ -2551,7 +2688,6 @@ static struct clk *onchip_24xx_clks[] __initdata = { &usb_l4_ick, /* L4 domain clocks */ &l4_ck, /* used as both core_l4 and wu_l4 */ - &ssi_l4_ick, /* virtual meta-group clock */ &virt_prcm_set, /* general l4 interface ck, multi-parent functional clk */ diff --git a/arch/arm/mach-omap2/clock34xx.c b/arch/arm/mach-omap2/clock34xx.c index 3ff7495..0bf661d 100644 --- a/arch/arm/mach-omap2/clock34xx.c +++ b/arch/arm/mach-omap2/clock34xx.c @@ -62,11 +62,14 @@ static void omap3_dpll_recalc(struct clk *clk) static void _omap3_dpll_write_clken(struct clk *clk, u8 clken_bits) { const struct dpll_data *dd; + u32 v; dd = clk->dpll_data; - cm_rmw_reg_bits(dd->enable_mask, clken_bits << __ffs(dd->enable_mask), - dd->control_reg); + v = __raw_readl(dd->control_reg); + v &= ~dd->enable_mask; + v |= clken_bits << __ffs(dd->enable_mask); + __raw_writel(v, dd->control_reg); } /* _omap3_wait_dpll_status: wait for a DPLL to enter a specific state */ @@ -82,7 +85,7 @@ static int _omap3_wait_dpll_status(struct clk *clk, u8 state) state <<= dd->idlest_bit; idlest_mask = 1 << dd->idlest_bit; - while (((cm_read_reg(dd->idlest_reg) & idlest_mask) != state) && + while (((__raw_readl(dd->idlest_reg) & idlest_mask) != state) && i < MAX_DPLL_WAIT_TRIES) { i++; udelay(1); @@ -285,7 +288,7 @@ static u32 omap3_dpll_autoidle_read(struct clk *clk) dd = clk->dpll_data; - v = cm_read_reg(dd->autoidle_reg); + v = __raw_readl(dd->autoidle_reg); v &= dd->autoidle_mask; v >>= __ffs(dd->autoidle_mask); @@ -304,6 +307,7 @@ static u32 omap3_dpll_autoidle_read(struct clk *clk) static void omap3_dpll_allow_idle(struct clk *clk) { const struct dpll_data *dd; + u32 v; if (!clk || !clk->dpll_data) return; @@ -315,9 +319,10 @@ static void omap3_dpll_allow_idle(struct clk *clk) * by writing 0x5 instead of 0x1. Add some mechanism to * optionally enter this mode. */ - cm_rmw_reg_bits(dd->autoidle_mask, - DPLL_AUTOIDLE_LOW_POWER_STOP << __ffs(dd->autoidle_mask), - dd->autoidle_reg); + v = __raw_readl(dd->autoidle_reg); + v &= ~dd->autoidle_mask; + v |= DPLL_AUTOIDLE_LOW_POWER_STOP << __ffs(dd->autoidle_mask); + __raw_writel(v, dd->autoidle_reg); } /** @@ -329,15 +334,17 @@ static void omap3_dpll_allow_idle(struct clk *clk) static void omap3_dpll_deny_idle(struct clk *clk) { const struct dpll_data *dd; + u32 v; if (!clk || !clk->dpll_data) return; dd = clk->dpll_data; - cm_rmw_reg_bits(dd->autoidle_mask, - DPLL_AUTOIDLE_DISABLE << __ffs(dd->autoidle_mask), - dd->autoidle_reg); + v = __raw_readl(dd->autoidle_reg); + v &= ~dd->autoidle_mask; + v |= DPLL_AUTOIDLE_DISABLE << __ffs(dd->autoidle_mask); + __raw_writel(v, dd->autoidle_reg); } /* Clock control for DPLL outputs */ @@ -482,8 +489,10 @@ int __init omap2_clk_init(void) for (clkp = onchip_34xx_clks; clkp < onchip_34xx_clks + ARRAY_SIZE(onchip_34xx_clks); clkp++) { - if ((*clkp)->flags & cpu_clkflg) + if ((*clkp)->flags & cpu_clkflg) { clk_register(*clkp); + omap2_init_clk_clkdm(*clkp); + } } /* REVISIT: Not yet ready for OMAP3 */ diff --git a/arch/arm/mach-omap2/clock34xx.h b/arch/arm/mach-omap2/clock34xx.h index ec66445..c38a8a0 100644 --- a/arch/arm/mach-omap2/clock34xx.h +++ b/arch/arm/mach-omap2/clock34xx.h @@ -478,7 +478,7 @@ static struct clk dpll3_m2_ck = { }; static const struct clksel core_ck_clksel[] = { - { .parent = &sys_ck, .rates = dpll_bypass_rates }, + { .parent = &sys_ck, .rates = dpll_bypass_rates }, { .parent = &dpll3_m2_ck, .rates = dpll_locked_rates }, { .parent = NULL } }; @@ -495,7 +495,7 @@ static struct clk core_ck = { }; static const struct clksel dpll3_m2x2_ck_clksel[] = { - { .parent = &sys_ck, .rates = dpll_bypass_rates }, + { .parent = &sys_ck, .rates = dpll_bypass_rates }, { .parent = &dpll3_x2_ck, .rates = dpll_locked_rates }, { .parent = NULL } }; @@ -541,7 +541,7 @@ static struct clk dpll3_m3x2_ck = { }; static const struct clksel emu_core_alwon_ck_clksel[] = { - { .parent = &sys_ck, .rates = dpll_bypass_rates }, + { .parent = &sys_ck, .rates = dpll_bypass_rates }, { .parent = &dpll3_m3x2_ck, .rates = dpll_locked_rates }, { .parent = NULL } }; @@ -633,7 +633,7 @@ static struct clk dpll4_m2x2_ck = { }; static const struct clksel omap_96m_alwon_fck_clksel[] = { - { .parent = &sys_ck, .rates = dpll_bypass_rates }, + { .parent = &sys_ck, .rates = dpll_bypass_rates }, { .parent = &dpll4_m2x2_ck, .rates = dpll_locked_rates }, { .parent = NULL } }; @@ -659,7 +659,7 @@ static struct clk omap_96m_fck = { }; static const struct clksel cm_96m_fck_clksel[] = { - { .parent = &sys_ck, .rates = dpll_bypass_rates }, + { .parent = &sys_ck, .rates = dpll_bypass_rates }, { .parent = &dpll4_m2x2_ck, .rates = dpll_locked_rates }, { .parent = NULL } }; @@ -701,7 +701,7 @@ static struct clk dpll4_m3x2_ck = { }; static const struct clksel virt_omap_54m_fck_clksel[] = { - { .parent = &sys_ck, .rates = dpll_bypass_rates }, + { .parent = &sys_ck, .rates = dpll_bypass_rates }, { .parent = &dpll4_m3x2_ck, .rates = dpll_locked_rates }, { .parent = NULL } }; @@ -911,7 +911,7 @@ static struct clk dpll5_m2_ck = { }; static const struct clksel omap_120m_fck_clksel[] = { - { .parent = &sys_ck, .rates = dpll_bypass_rates }, + { .parent = &sys_ck, .rates = dpll_bypass_rates }, { .parent = &dpll5_m2_ck, .rates = dpll_locked_rates }, { .parent = NULL } }; @@ -919,13 +919,13 @@ static const struct clksel omap_120m_fck_clksel[] = { static struct clk omap_120m_fck = { .name = "omap_120m_fck", .parent = &dpll5_m2_ck, - .init = &omap2_init_clksel_parent, - .clksel_reg = OMAP_CM_REGADDR(PLL_MOD, CM_IDLEST2), - .clksel_mask = OMAP3430ES2_ST_PERIPH2_CLK_MASK, - .clksel = omap_120m_fck_clksel, + .init = &omap2_init_clksel_parent, + .clksel_reg = OMAP_CM_REGADDR(PLL_MOD, CM_IDLEST2), + .clksel_mask = OMAP3430ES2_ST_PERIPH2_CLK_MASK, + .clksel = omap_120m_fck_clksel, .flags = CLOCK_IN_OMAP3430ES2 | RATE_PROPAGATES | PARENT_CONTROLS_CLOCK, - .recalc = &omap2_clksel_recalc, + .recalc = &omap2_clksel_recalc, }; /* CM EXTERNAL CLOCK OUTPUTS */ @@ -1034,7 +1034,7 @@ static struct clk dpll1_fck = { * called 'dpll1_fck' */ static const struct clksel mpu_clksel[] = { - { .parent = &dpll1_fck, .rates = dpll_bypass_rates }, + { .parent = &dpll1_fck, .rates = dpll_bypass_rates }, { .parent = &dpll1_x2m2_ck, .rates = dpll_locked_rates }, { .parent = NULL } }; @@ -1048,6 +1048,7 @@ static struct clk mpu_ck = { .clksel = mpu_clksel, .flags = CLOCK_IN_OMAP343X | RATE_PROPAGATES | PARENT_CONTROLS_CLOCK, + .clkdm_name = "mpu_clkdm", .recalc = &omap2_clksel_recalc, }; @@ -1075,6 +1076,8 @@ static struct clk arm_fck = { .recalc = &omap2_clksel_recalc, }; +/* XXX What about neon_clkdm ? */ + /* * REVISIT: This clock is never specifically defined in the 3430 TRM, * although it is referenced - so this is a guess @@ -1107,7 +1110,7 @@ static struct clk dpll2_fck = { */ static const struct clksel iva2_clksel[] = { - { .parent = &dpll2_fck, .rates = dpll_bypass_rates }, + { .parent = &dpll2_fck, .rates = dpll_bypass_rates }, { .parent = &dpll2_m2_ck, .rates = dpll_locked_rates }, { .parent = NULL } }; @@ -1123,6 +1126,7 @@ static struct clk iva2_ck = { .clksel_mask = OMAP3430_ST_IVA2_CLK_MASK, .clksel = iva2_clksel, .flags = CLOCK_IN_OMAP343X | RATE_PROPAGATES, + .clkdm_name = "iva2_clkdm", .recalc = &omap2_clksel_recalc, }; @@ -1137,6 +1141,7 @@ static struct clk l3_ick = { .clksel = div2_core_clksel, .flags = CLOCK_IN_OMAP343X | RATE_PROPAGATES | PARENT_CONTROLS_CLOCK, + .clkdm_name = "core_l3_clkdm", .recalc = &omap2_clksel_recalc, }; @@ -1154,6 +1159,7 @@ static struct clk l4_ick = { .clksel = div2_l3_clksel, .flags = CLOCK_IN_OMAP343X | RATE_PROPAGATES | PARENT_CONTROLS_CLOCK, + .clkdm_name = "core_l4_clkdm", .recalc = &omap2_clksel_recalc, }; @@ -1183,43 +1189,57 @@ static const struct clksel gfx_l3_clksel[] = { { .parent = NULL } }; -static struct clk gfx_l3_fck = { - .name = "gfx_l3_fck", +/* Virtual parent clock for gfx_l3_ick and gfx_l3_fck */ +static struct clk gfx_l3_ck = { + .name = "gfx_l3_ck", .parent = &l3_ick, .init = &omap2_init_clksel_parent, .enable_reg = OMAP_CM_REGADDR(GFX_MOD, CM_ICLKEN), .enable_bit = OMAP_EN_GFX_SHIFT, + .flags = CLOCK_IN_OMAP3430ES1, + .recalc = &followparent_recalc, +}; + +static struct clk gfx_l3_fck = { + .name = "gfx_l3_fck", + .parent = &gfx_l3_ck, + .init = &omap2_init_clksel_parent, .clksel_reg = OMAP_CM_REGADDR(GFX_MOD, CM_CLKSEL), .clksel_mask = OMAP_CLKSEL_GFX_MASK, .clksel = gfx_l3_clksel, - .flags = CLOCK_IN_OMAP3430ES1 | RATE_PROPAGATES, + .flags = CLOCK_IN_OMAP3430ES1 | RATE_PROPAGATES | + PARENT_CONTROLS_CLOCK, + .clkdm_name = "gfx_3430es1_clkdm", .recalc = &omap2_clksel_recalc, }; static struct clk gfx_l3_ick = { .name = "gfx_l3_ick", - .parent = &l3_ick, - .enable_reg = OMAP_CM_REGADDR(GFX_MOD, CM_ICLKEN), - .enable_bit = OMAP_EN_GFX_SHIFT, - .flags = CLOCK_IN_OMAP3430ES1, + .parent = &gfx_l3_ck, + .flags = CLOCK_IN_OMAP3430ES1 | PARENT_CONTROLS_CLOCK, + .clkdm_name = "gfx_3430es1_clkdm", .recalc = &followparent_recalc, }; static struct clk gfx_cg1_ck = { .name = "gfx_cg1_ck", .parent = &gfx_l3_fck, /* REVISIT: correct? */ + .init = &omap2_init_clk_clkdm, .enable_reg = OMAP_CM_REGADDR(GFX_MOD, CM_FCLKEN), .enable_bit = OMAP3430ES1_EN_2D_SHIFT, .flags = CLOCK_IN_OMAP3430ES1, + .clkdm_name = "gfx_3430es1_clkdm", .recalc = &followparent_recalc, }; static struct clk gfx_cg2_ck = { .name = "gfx_cg2_ck", .parent = &gfx_l3_fck, /* REVISIT: correct? */ + .init = &omap2_init_clk_clkdm, .enable_reg = OMAP_CM_REGADDR(GFX_MOD, CM_FCLKEN), .enable_bit = OMAP3430ES1_EN_3D_SHIFT, .flags = CLOCK_IN_OMAP3430ES1, + .clkdm_name = "gfx_3430es1_clkdm", .recalc = &followparent_recalc, }; @@ -1252,15 +1272,18 @@ static struct clk sgx_fck = { .clksel_mask = OMAP3430ES2_CLKSEL_SGX_MASK, .clksel = sgx_clksel, .flags = CLOCK_IN_OMAP3430ES2, + .clkdm_name = "sgx_clkdm", .recalc = &omap2_clksel_recalc, }; static struct clk sgx_ick = { .name = "sgx_ick", .parent = &l3_ick, + .init = &omap2_init_clk_clkdm, .enable_reg = OMAP_CM_REGADDR(OMAP3430ES2_SGX_MOD, CM_ICLKEN), .enable_bit = OMAP3430ES2_EN_SGX_SHIFT, .flags = CLOCK_IN_OMAP3430ES2, + .clkdm_name = "sgx_clkdm", .recalc = &followparent_recalc, }; @@ -1269,9 +1292,11 @@ static struct clk sgx_ick = { static struct clk d2d_26m_fck = { .name = "d2d_26m_fck", .parent = &sys_ck, + .init = &omap2_init_clk_clkdm, .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_FCLKEN1), .enable_bit = OMAP3430ES1_EN_D2D_SHIFT, .flags = CLOCK_IN_OMAP3430ES1, + .clkdm_name = "d2d_clkdm", .recalc = &followparent_recalc, }; @@ -1291,6 +1316,7 @@ static struct clk gpt10_fck = { .clksel_mask = OMAP3430_CLKSEL_GPT10_MASK, .clksel = omap343x_gpt_clksel, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "core_l4_clkdm", .recalc = &omap2_clksel_recalc, }; @@ -1304,6 +1330,7 @@ static struct clk gpt11_fck = { .clksel_mask = OMAP3430_CLKSEL_GPT11_MASK, .clksel = omap343x_gpt_clksel, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "core_l4_clkdm", .recalc = &omap2_clksel_recalc, }; @@ -1341,6 +1368,7 @@ static struct clk core_96m_fck = { .parent = &omap_96m_fck, .flags = CLOCK_IN_OMAP343X | RATE_PROPAGATES | PARENT_CONTROLS_CLOCK, + .clkdm_name = "core_l4_clkdm", .recalc = &followparent_recalc, }; @@ -1351,6 +1379,7 @@ static struct clk mmchs3_fck = { .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_FCLKEN1), .enable_bit = OMAP3430ES2_EN_MMC3_SHIFT, .flags = CLOCK_IN_OMAP3430ES2, + .clkdm_name = "core_l4_clkdm", .recalc = &followparent_recalc, }; @@ -1361,6 +1390,7 @@ static struct clk mmchs2_fck = { .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_FCLKEN1), .enable_bit = OMAP3430_EN_MMC2_SHIFT, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "core_l4_clkdm", .recalc = &followparent_recalc, }; @@ -1370,6 +1400,7 @@ static struct clk mspro_fck = { .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_FCLKEN1), .enable_bit = OMAP3430_EN_MSPRO_SHIFT, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "core_l4_clkdm", .recalc = &followparent_recalc, }; @@ -1380,6 +1411,7 @@ static struct clk mmchs1_fck = { .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_FCLKEN1), .enable_bit = OMAP3430_EN_MMC1_SHIFT, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "core_l4_clkdm", .recalc = &followparent_recalc, }; @@ -1390,16 +1422,18 @@ static struct clk i2c3_fck = { .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_FCLKEN1), .enable_bit = OMAP3430_EN_I2C3_SHIFT, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "core_l4_clkdm", .recalc = &followparent_recalc, }; static struct clk i2c2_fck = { .name = "i2c_fck", - .id = 2, + .id = 2, .parent = &core_96m_fck, .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_FCLKEN1), .enable_bit = OMAP3430_EN_I2C2_SHIFT, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "core_l4_clkdm", .recalc = &followparent_recalc, }; @@ -1410,6 +1444,7 @@ static struct clk i2c1_fck = { .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_FCLKEN1), .enable_bit = OMAP3430_EN_I2C1_SHIFT, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "core_l4_clkdm", .recalc = &followparent_recalc, }; @@ -1443,6 +1478,7 @@ static struct clk mcbsp5_fck = { .clksel_mask = OMAP2_MCBSP5_CLKS_MASK, .clksel = mcbsp_15_clksel, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "core_l4_clkdm", .recalc = &omap2_clksel_recalc, }; @@ -1456,6 +1492,7 @@ static struct clk mcbsp1_fck = { .clksel_mask = OMAP2_MCBSP1_CLKS_MASK, .clksel = mcbsp_15_clksel, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "core_l4_clkdm", .recalc = &omap2_clksel_recalc, }; @@ -1466,6 +1503,7 @@ static struct clk core_48m_fck = { .parent = &omap_48m_fck, .flags = CLOCK_IN_OMAP343X | RATE_PROPAGATES | PARENT_CONTROLS_CLOCK, + .clkdm_name = "core_l4_clkdm", .recalc = &followparent_recalc, }; @@ -1543,6 +1581,7 @@ static struct clk core_12m_fck = { .parent = &omap_12m_fck, .flags = CLOCK_IN_OMAP343X | RATE_PROPAGATES | PARENT_CONTROLS_CLOCK, + .clkdm_name = "core_l4_clkdm", .recalc = &followparent_recalc, }; @@ -1581,6 +1620,7 @@ static struct clk ssi_ssr_fck = { .clksel_mask = OMAP3430_CLKSEL_SSI_MASK, .clksel = ssi_ssr_clksel, .flags = CLOCK_IN_OMAP343X | RATE_PROPAGATES, + .clkdm_name = "core_l4_clkdm", .recalc = &omap2_clksel_recalc, }; @@ -1596,11 +1636,17 @@ static struct clk ssi_sst_fck = { /* CORE_L3_ICK based clocks */ +/* + * XXX must add clk_enable/clk_disable for these if standard code won't + * handle it + */ static struct clk core_l3_ick = { .name = "core_l3_ick", .parent = &l3_ick, + .init = &omap2_init_clk_clkdm, .flags = CLOCK_IN_OMAP343X | RATE_PROPAGATES | PARENT_CONTROLS_CLOCK, + .clkdm_name = "core_l3_clkdm", .recalc = &followparent_recalc, }; @@ -1610,6 +1656,7 @@ static struct clk hsotgusb_ick = { .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN1), .enable_bit = OMAP3430_EN_HSOTGUSB_SHIFT, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "core_l3_clkdm", .recalc = &followparent_recalc, }; @@ -1619,6 +1666,7 @@ static struct clk sdrc_ick = { .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN1), .enable_bit = OMAP3430_EN_SDRC_SHIFT, .flags = CLOCK_IN_OMAP343X | ENABLE_ON_INIT, + .clkdm_name = "core_l3_clkdm", .recalc = &followparent_recalc, }; @@ -1627,6 +1675,7 @@ static struct clk gpmc_fck = { .parent = &core_l3_ick, .flags = CLOCK_IN_OMAP343X | PARENT_CONTROLS_CLOCK | ENABLE_ON_INIT, + .clkdm_name = "core_l3_clkdm", .recalc = &followparent_recalc, }; @@ -1654,8 +1703,10 @@ static struct clk pka_ick = { static struct clk core_l4_ick = { .name = "core_l4_ick", .parent = &l4_ick, + .init = &omap2_init_clk_clkdm, .flags = CLOCK_IN_OMAP343X | RATE_PROPAGATES | PARENT_CONTROLS_CLOCK, + .clkdm_name = "core_l4_clkdm", .recalc = &followparent_recalc, }; @@ -1665,6 +1716,7 @@ static struct clk usbtll_ick = { .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN3), .enable_bit = OMAP3430ES2_EN_USBTLL_SHIFT, .flags = CLOCK_IN_OMAP3430ES2, + .clkdm_name = "core_l4_clkdm", .recalc = &followparent_recalc, }; @@ -1675,6 +1727,7 @@ static struct clk mmchs3_ick = { .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN1), .enable_bit = OMAP3430ES2_EN_MMC3_SHIFT, .flags = CLOCK_IN_OMAP3430ES2, + .clkdm_name = "core_l4_clkdm", .recalc = &followparent_recalc, }; @@ -1685,6 +1738,7 @@ static struct clk icr_ick = { .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN1), .enable_bit = OMAP3430_EN_ICR_SHIFT, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "core_l4_clkdm", .recalc = &followparent_recalc, }; @@ -1694,6 +1748,7 @@ static struct clk aes2_ick = { .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN1), .enable_bit = OMAP3430_EN_AES2_SHIFT, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "core_l4_clkdm", .recalc = &followparent_recalc, }; @@ -1703,6 +1758,7 @@ static struct clk sha12_ick = { .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN1), .enable_bit = OMAP3430_EN_SHA12_SHIFT, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "core_l4_clkdm", .recalc = &followparent_recalc, }; @@ -1712,6 +1768,7 @@ static struct clk des2_ick = { .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN1), .enable_bit = OMAP3430_EN_DES2_SHIFT, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "core_l4_clkdm", .recalc = &followparent_recalc, }; @@ -1722,6 +1779,7 @@ static struct clk mmchs2_ick = { .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN1), .enable_bit = OMAP3430_EN_MMC2_SHIFT, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "core_l4_clkdm", .recalc = &followparent_recalc, }; @@ -1732,6 +1790,7 @@ static struct clk mmchs1_ick = { .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN1), .enable_bit = OMAP3430_EN_MMC1_SHIFT, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "core_l4_clkdm", .recalc = &followparent_recalc, }; @@ -1741,6 +1800,7 @@ static struct clk mspro_ick = { .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN1), .enable_bit = OMAP3430_EN_MSPRO_SHIFT, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "core_l4_clkdm", .recalc = &followparent_recalc, }; @@ -1750,6 +1810,7 @@ static struct clk hdq_ick = { .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN1), .enable_bit = OMAP3430_EN_HDQ_SHIFT, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "core_l4_clkdm", .recalc = &followparent_recalc, }; @@ -1760,6 +1821,7 @@ static struct clk mcspi4_ick = { .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN1), .enable_bit = OMAP3430_EN_MCSPI4_SHIFT, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "core_l4_clkdm", .recalc = &followparent_recalc, }; @@ -1770,6 +1832,7 @@ static struct clk mcspi3_ick = { .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN1), .enable_bit = OMAP3430_EN_MCSPI3_SHIFT, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "core_l4_clkdm", .recalc = &followparent_recalc, }; @@ -1780,6 +1843,7 @@ static struct clk mcspi2_ick = { .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN1), .enable_bit = OMAP3430_EN_MCSPI2_SHIFT, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "core_l4_clkdm", .recalc = &followparent_recalc, }; @@ -1790,6 +1854,7 @@ static struct clk mcspi1_ick = { .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN1), .enable_bit = OMAP3430_EN_MCSPI1_SHIFT, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "core_l4_clkdm", .recalc = &followparent_recalc, }; @@ -1800,6 +1865,7 @@ static struct clk i2c3_ick = { .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN1), .enable_bit = OMAP3430_EN_I2C3_SHIFT, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "core_l4_clkdm", .recalc = &followparent_recalc, }; @@ -1810,6 +1876,7 @@ static struct clk i2c2_ick = { .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN1), .enable_bit = OMAP3430_EN_I2C2_SHIFT, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "core_l4_clkdm", .recalc = &followparent_recalc, }; @@ -1820,6 +1887,7 @@ static struct clk i2c1_ick = { .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN1), .enable_bit = OMAP3430_EN_I2C1_SHIFT, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "core_l4_clkdm", .recalc = &followparent_recalc, }; @@ -1829,6 +1897,7 @@ static struct clk uart2_ick = { .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN1), .enable_bit = OMAP3430_EN_UART2_SHIFT, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "core_l4_clkdm", .recalc = &followparent_recalc, }; @@ -1838,6 +1907,7 @@ static struct clk uart1_ick = { .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN1), .enable_bit = OMAP3430_EN_UART1_SHIFT, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "core_l4_clkdm", .recalc = &followparent_recalc, }; @@ -1847,6 +1917,7 @@ static struct clk gpt11_ick = { .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN1), .enable_bit = OMAP3430_EN_GPT11_SHIFT, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "core_l4_clkdm", .recalc = &followparent_recalc, }; @@ -1856,6 +1927,7 @@ static struct clk gpt10_ick = { .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN1), .enable_bit = OMAP3430_EN_GPT10_SHIFT, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "core_l4_clkdm", .recalc = &followparent_recalc, }; @@ -1866,6 +1938,7 @@ static struct clk mcbsp5_ick = { .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN1), .enable_bit = OMAP3430_EN_MCBSP5_SHIFT, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "core_l4_clkdm", .recalc = &followparent_recalc, }; @@ -1876,6 +1949,7 @@ static struct clk mcbsp1_ick = { .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN1), .enable_bit = OMAP3430_EN_MCBSP1_SHIFT, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "core_l4_clkdm", .recalc = &followparent_recalc, }; @@ -1885,6 +1959,7 @@ static struct clk fac_ick = { .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN1), .enable_bit = OMAP3430ES1_EN_FAC_SHIFT, .flags = CLOCK_IN_OMAP3430ES1, + .clkdm_name = "core_l4_clkdm", .recalc = &followparent_recalc, }; @@ -1894,6 +1969,7 @@ static struct clk mailboxes_ick = { .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN1), .enable_bit = OMAP3430_EN_MAILBOXES_SHIFT, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "core_l4_clkdm", .recalc = &followparent_recalc, }; @@ -1913,6 +1989,7 @@ static struct clk ssi_l4_ick = { .parent = &l4_ick, .flags = CLOCK_IN_OMAP343X | RATE_PROPAGATES | PARENT_CONTROLS_CLOCK, + .clkdm_name = "core_l4_clkdm", .recalc = &followparent_recalc, }; @@ -1922,6 +1999,7 @@ static struct clk ssi_ick = { .enable_reg = OMAP_CM_REGADDR(CORE_MOD, CM_ICLKEN1), .enable_bit = OMAP3430_EN_SSI_SHIFT, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "core_l4_clkdm", .recalc = &followparent_recalc, }; @@ -1996,7 +2074,7 @@ static struct clk des1_ick = { /* DSS */ static const struct clksel dss1_alwon_fck_clksel[] = { - { .parent = &sys_ck, .rates = dpll_bypass_rates }, + { .parent = &sys_ck, .rates = dpll_bypass_rates }, { .parent = &dpll4_m4x2_ck, .rates = dpll_locked_rates }, { .parent = NULL } }; @@ -2011,33 +2089,40 @@ static struct clk dss1_alwon_fck = { .clksel_mask = OMAP3430_ST_PERIPH_CLK_MASK, .clksel = dss1_alwon_fck_clksel, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "dss_clkdm", .recalc = &omap2_clksel_recalc, }; static struct clk dss_tv_fck = { .name = "dss_tv_fck", .parent = &omap_54m_fck, + .init = &omap2_init_clk_clkdm, .enable_reg = OMAP_CM_REGADDR(OMAP3430_DSS_MOD, CM_FCLKEN), .enable_bit = OMAP3430_EN_TV_SHIFT, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "dss_clkdm", .recalc = &followparent_recalc, }; static struct clk dss_96m_fck = { .name = "dss_96m_fck", .parent = &omap_96m_fck, + .init = &omap2_init_clk_clkdm, .enable_reg = OMAP_CM_REGADDR(OMAP3430_DSS_MOD, CM_FCLKEN), .enable_bit = OMAP3430_EN_TV_SHIFT, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "dss_clkdm", .recalc = &followparent_recalc, }; static struct clk dss2_alwon_fck = { .name = "dss2_alwon_fck", .parent = &sys_ck, + .init = &omap2_init_clk_clkdm, .enable_reg = OMAP_CM_REGADDR(OMAP3430_DSS_MOD, CM_FCLKEN), .enable_bit = OMAP3430_EN_DSS2_SHIFT, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "dss_clkdm", .recalc = &followparent_recalc, }; @@ -2045,16 +2130,18 @@ static struct clk dss_ick = { /* Handles both L3 and L4 clocks */ .name = "dss_ick", .parent = &l4_ick, + .init = &omap2_init_clk_clkdm, .enable_reg = OMAP_CM_REGADDR(OMAP3430_DSS_MOD, CM_ICLKEN), .enable_bit = OMAP3430_CM_ICLKEN_DSS_EN_DSS_SHIFT, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "dss_clkdm", .recalc = &followparent_recalc, }; /* CAM */ static const struct clksel cam_mclk_clksel[] = { - { .parent = &sys_ck, .rates = dpll_bypass_rates }, + { .parent = &sys_ck, .rates = dpll_bypass_rates }, { .parent = &dpll4_m5x2_ck, .rates = dpll_locked_rates }, { .parent = NULL } }; @@ -2069,24 +2156,19 @@ static struct clk cam_mclk = { .enable_reg = OMAP_CM_REGADDR(OMAP3430_CAM_MOD, CM_FCLKEN), .enable_bit = OMAP3430_EN_CAM_SHIFT, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "cam_clkdm", .recalc = &omap2_clksel_recalc, }; -static struct clk cam_l3_ick = { - .name = "cam_l3_ick", - .parent = &l3_ick, - .enable_reg = OMAP_CM_REGADDR(OMAP3430_CAM_MOD, CM_ICLKEN), - .enable_bit = OMAP3430_EN_CAM_SHIFT, - .flags = CLOCK_IN_OMAP343X, - .recalc = &followparent_recalc, -}; - -static struct clk cam_l4_ick = { - .name = "cam_l4_ick", +static struct clk cam_ick = { + /* Handles both L3 and L4 clocks */ + .name = "cam_ick", .parent = &l4_ick, + .init = &omap2_init_clk_clkdm, .enable_reg = OMAP_CM_REGADDR(OMAP3430_CAM_MOD, CM_ICLKEN), .enable_bit = OMAP3430_EN_CAM_SHIFT, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "cam_clkdm", .recalc = &followparent_recalc, }; @@ -2095,45 +2177,45 @@ static struct clk cam_l4_ick = { static struct clk usbhost_120m_fck = { .name = "usbhost_120m_fck", .parent = &omap_120m_fck, + .init = &omap2_init_clk_clkdm, .enable_reg = OMAP_CM_REGADDR(OMAP3430ES2_USBHOST_MOD, CM_FCLKEN), .enable_bit = OMAP3430ES2_EN_USBHOST2_SHIFT, .flags = CLOCK_IN_OMAP3430ES2, + .clkdm_name = "usbhost_clkdm", .recalc = &followparent_recalc, }; static struct clk usbhost_48m_fck = { .name = "usbhost_48m_fck", .parent = &omap_48m_fck, + .init = &omap2_init_clk_clkdm, .enable_reg = OMAP_CM_REGADDR(OMAP3430ES2_USBHOST_MOD, CM_FCLKEN), .enable_bit = OMAP3430ES2_EN_USBHOST1_SHIFT, .flags = CLOCK_IN_OMAP3430ES2, + .clkdm_name = "usbhost_clkdm", .recalc = &followparent_recalc, }; -static struct clk usbhost_l3_ick = { - .name = "usbhost_l3_ick", - .parent = &l3_ick, - .enable_reg = OMAP_CM_REGADDR(OMAP3430ES2_USBHOST_MOD, CM_ICLKEN), - .enable_bit = OMAP3430ES2_EN_USBHOST_SHIFT, - .flags = CLOCK_IN_OMAP3430ES2, - .recalc = &followparent_recalc, -}; - -static struct clk usbhost_l4_ick = { - .name = "usbhost_l4_ick", +static struct clk usbhost_ick = { + /* Handles both L3 and L4 clocks */ + .name = "usbhost_ick", .parent = &l4_ick, + .init = &omap2_init_clk_clkdm, .enable_reg = OMAP_CM_REGADDR(OMAP3430ES2_USBHOST_MOD, CM_ICLKEN), .enable_bit = OMAP3430ES2_EN_USBHOST_SHIFT, .flags = CLOCK_IN_OMAP3430ES2, + .clkdm_name = "usbhost_clkdm", .recalc = &followparent_recalc, }; static struct clk usbhost_sar_fck = { .name = "usbhost_sar_fck", .parent = &osc_sys_ck, + .init = &omap2_init_clk_clkdm, .enable_reg = OMAP_PRM_REGADDR(OMAP3430ES2_USBHOST_MOD, PM_PWSTCTRL), .enable_bit = OMAP3430ES2_SAVEANDRESTORE_SHIFT, .flags = CLOCK_IN_OMAP3430ES2, + .clkdm_name = "usbhost_clkdm", .recalc = &followparent_recalc, }; @@ -2175,6 +2257,7 @@ static struct clk usim_fck = { .recalc = &omap2_clksel_recalc, }; +/* XXX should gpt1's clksel have wkup_32k_fck as the 32k opt? */ static struct clk gpt1_fck = { .name = "gpt1_fck", .init = &omap2_init_clksel_parent, @@ -2184,13 +2267,16 @@ static struct clk gpt1_fck = { .clksel_mask = OMAP3430_CLKSEL_GPT1_MASK, .clksel = omap343x_gpt_clksel, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "wkup_clkdm", .recalc = &omap2_clksel_recalc, }; static struct clk wkup_32k_fck = { .name = "wkup_32k_fck", + .init = &omap2_init_clk_clkdm, .parent = &omap_32k_fck, .flags = CLOCK_IN_OMAP343X | RATE_PROPAGATES | ALWAYS_ENABLED, + .clkdm_name = "wkup_clkdm", .recalc = &followparent_recalc, }; @@ -2200,6 +2286,7 @@ static struct clk gpio1_fck = { .enable_reg = OMAP_CM_REGADDR(WKUP_MOD, CM_FCLKEN), .enable_bit = OMAP3430_EN_GPIO1_SHIFT, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "wkup_clkdm", .recalc = &followparent_recalc, }; @@ -2209,6 +2296,7 @@ static struct clk wdt2_fck = { .enable_reg = OMAP_CM_REGADDR(WKUP_MOD, CM_FCLKEN), .enable_bit = OMAP3430_EN_WDT2_SHIFT, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "wkup_clkdm", .recalc = &followparent_recalc, }; @@ -2216,6 +2304,7 @@ static struct clk wkup_l4_ick = { .name = "wkup_l4_ick", .parent = &sys_ck, .flags = CLOCK_IN_OMAP343X | RATE_PROPAGATES | ALWAYS_ENABLED, + .clkdm_name = "wkup_clkdm", .recalc = &followparent_recalc, }; @@ -2227,6 +2316,7 @@ static struct clk usim_ick = { .enable_reg = OMAP_CM_REGADDR(WKUP_MOD, CM_ICLKEN), .enable_bit = OMAP3430ES2_EN_USIMOCP_SHIFT, .flags = CLOCK_IN_OMAP3430ES2, + .clkdm_name = "wkup_clkdm", .recalc = &followparent_recalc, }; @@ -2236,6 +2326,7 @@ static struct clk wdt2_ick = { .enable_reg = OMAP_CM_REGADDR(WKUP_MOD, CM_ICLKEN), .enable_bit = OMAP3430_EN_WDT2_SHIFT, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "wkup_clkdm", .recalc = &followparent_recalc, }; @@ -2245,6 +2336,7 @@ static struct clk wdt1_ick = { .enable_reg = OMAP_CM_REGADDR(WKUP_MOD, CM_ICLKEN), .enable_bit = OMAP3430_EN_WDT1_SHIFT, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "wkup_clkdm", .recalc = &followparent_recalc, }; @@ -2254,6 +2346,7 @@ static struct clk gpio1_ick = { .enable_reg = OMAP_CM_REGADDR(WKUP_MOD, CM_ICLKEN), .enable_bit = OMAP3430_EN_GPIO1_SHIFT, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "wkup_clkdm", .recalc = &followparent_recalc, }; @@ -2263,15 +2356,18 @@ static struct clk omap_32ksync_ick = { .enable_reg = OMAP_CM_REGADDR(WKUP_MOD, CM_ICLKEN), .enable_bit = OMAP3430_EN_32KSYNC_SHIFT, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "wkup_clkdm", .recalc = &followparent_recalc, }; +/* XXX This clock no longer exists in 3430 TRM rev F */ static struct clk gpt12_ick = { .name = "gpt12_ick", .parent = &wkup_l4_ick, .enable_reg = OMAP_CM_REGADDR(WKUP_MOD, CM_ICLKEN), .enable_bit = OMAP3430_EN_GPT12_SHIFT, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "wkup_clkdm", .recalc = &followparent_recalc, }; @@ -2281,6 +2377,7 @@ static struct clk gpt1_ick = { .enable_reg = OMAP_CM_REGADDR(WKUP_MOD, CM_ICLKEN), .enable_bit = OMAP3430_EN_GPT1_SHIFT, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "wkup_clkdm", .recalc = &followparent_recalc, }; @@ -2291,16 +2388,20 @@ static struct clk gpt1_ick = { static struct clk per_96m_fck = { .name = "per_96m_fck", .parent = &omap_96m_alwon_fck, + .init = &omap2_init_clk_clkdm, .flags = CLOCK_IN_OMAP343X | RATE_PROPAGATES | PARENT_CONTROLS_CLOCK, + .clkdm_name = "per_clkdm", .recalc = &followparent_recalc, }; static struct clk per_48m_fck = { .name = "per_48m_fck", .parent = &omap_48m_fck, + .init = &omap2_init_clk_clkdm, .flags = CLOCK_IN_OMAP343X | RATE_PROPAGATES | PARENT_CONTROLS_CLOCK, + .clkdm_name = "per_clkdm", .recalc = &followparent_recalc, }; @@ -2310,6 +2411,7 @@ static struct clk uart3_fck = { .enable_reg = OMAP_CM_REGADDR(OMAP3430_PER_MOD, CM_FCLKEN), .enable_bit = OMAP3430_EN_UART3_SHIFT, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "per_clkdm", .recalc = &followparent_recalc, }; @@ -2322,6 +2424,7 @@ static struct clk gpt2_fck = { .clksel_mask = OMAP3430_CLKSEL_GPT2_MASK, .clksel = omap343x_gpt_clksel, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "per_clkdm", .recalc = &omap2_clksel_recalc, }; @@ -2334,6 +2437,7 @@ static struct clk gpt3_fck = { .clksel_mask = OMAP3430_CLKSEL_GPT3_MASK, .clksel = omap343x_gpt_clksel, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "per_clkdm", .recalc = &omap2_clksel_recalc, }; @@ -2346,6 +2450,7 @@ static struct clk gpt4_fck = { .clksel_mask = OMAP3430_CLKSEL_GPT4_MASK, .clksel = omap343x_gpt_clksel, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "per_clkdm", .recalc = &omap2_clksel_recalc, }; @@ -2358,6 +2463,7 @@ static struct clk gpt5_fck = { .clksel_mask = OMAP3430_CLKSEL_GPT5_MASK, .clksel = omap343x_gpt_clksel, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "per_clkdm", .recalc = &omap2_clksel_recalc, }; @@ -2370,6 +2476,7 @@ static struct clk gpt6_fck = { .clksel_mask = OMAP3430_CLKSEL_GPT6_MASK, .clksel = omap343x_gpt_clksel, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "per_clkdm", .recalc = &omap2_clksel_recalc, }; @@ -2382,6 +2489,7 @@ static struct clk gpt7_fck = { .clksel_mask = OMAP3430_CLKSEL_GPT7_MASK, .clksel = omap343x_gpt_clksel, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "per_clkdm", .recalc = &omap2_clksel_recalc, }; @@ -2394,6 +2502,7 @@ static struct clk gpt8_fck = { .clksel_mask = OMAP3430_CLKSEL_GPT8_MASK, .clksel = omap343x_gpt_clksel, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "per_clkdm", .recalc = &omap2_clksel_recalc, }; @@ -2406,12 +2515,14 @@ static struct clk gpt9_fck = { .clksel_mask = OMAP3430_CLKSEL_GPT9_MASK, .clksel = omap343x_gpt_clksel, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "per_clkdm", .recalc = &omap2_clksel_recalc, }; static struct clk per_32k_alwon_fck = { .name = "per_32k_alwon_fck", .parent = &omap_32k_fck, + .clkdm_name = "per_clkdm", .flags = CLOCK_IN_OMAP343X | RATE_PROPAGATES | ALWAYS_ENABLED, .recalc = &followparent_recalc, }; @@ -2422,6 +2533,7 @@ static struct clk gpio6_fck = { .enable_reg = OMAP_CM_REGADDR(OMAP3430_PER_MOD, CM_FCLKEN), .enable_bit = OMAP3430_EN_GPIO6_SHIFT, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "per_clkdm", .recalc = &followparent_recalc, }; @@ -2431,6 +2543,7 @@ static struct clk gpio5_fck = { .enable_reg = OMAP_CM_REGADDR(OMAP3430_PER_MOD, CM_FCLKEN), .enable_bit = OMAP3430_EN_GPIO5_SHIFT, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "per_clkdm", .recalc = &followparent_recalc, }; @@ -2440,6 +2553,7 @@ static struct clk gpio4_fck = { .enable_reg = OMAP_CM_REGADDR(OMAP3430_PER_MOD, CM_FCLKEN), .enable_bit = OMAP3430_EN_GPIO4_SHIFT, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "per_clkdm", .recalc = &followparent_recalc, }; @@ -2449,6 +2563,7 @@ static struct clk gpio3_fck = { .enable_reg = OMAP_CM_REGADDR(OMAP3430_PER_MOD, CM_FCLKEN), .enable_bit = OMAP3430_EN_GPIO3_SHIFT, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "per_clkdm", .recalc = &followparent_recalc, }; @@ -2458,6 +2573,7 @@ static struct clk gpio2_fck = { .enable_reg = OMAP_CM_REGADDR(OMAP3430_PER_MOD, CM_FCLKEN), .enable_bit = OMAP3430_EN_GPIO2_SHIFT, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "per_clkdm", .recalc = &followparent_recalc, }; @@ -2467,6 +2583,7 @@ static struct clk wdt3_fck = { .enable_reg = OMAP_CM_REGADDR(OMAP3430_PER_MOD, CM_FCLKEN), .enable_bit = OMAP3430_EN_WDT3_SHIFT, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "per_clkdm", .recalc = &followparent_recalc, }; @@ -2475,6 +2592,7 @@ static struct clk per_l4_ick = { .parent = &l4_ick, .flags = CLOCK_IN_OMAP343X | RATE_PROPAGATES | PARENT_CONTROLS_CLOCK, + .clkdm_name = "per_clkdm", .recalc = &followparent_recalc, }; @@ -2484,6 +2602,7 @@ static struct clk gpio6_ick = { .enable_reg = OMAP_CM_REGADDR(OMAP3430_PER_MOD, CM_ICLKEN), .enable_bit = OMAP3430_EN_GPIO6_SHIFT, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "per_clkdm", .recalc = &followparent_recalc, }; @@ -2493,6 +2612,7 @@ static struct clk gpio5_ick = { .enable_reg = OMAP_CM_REGADDR(OMAP3430_PER_MOD, CM_ICLKEN), .enable_bit = OMAP3430_EN_GPIO5_SHIFT, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "per_clkdm", .recalc = &followparent_recalc, }; @@ -2502,6 +2622,7 @@ static struct clk gpio4_ick = { .enable_reg = OMAP_CM_REGADDR(OMAP3430_PER_MOD, CM_ICLKEN), .enable_bit = OMAP3430_EN_GPIO4_SHIFT, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "per_clkdm", .recalc = &followparent_recalc, }; @@ -2511,6 +2632,7 @@ static struct clk gpio3_ick = { .enable_reg = OMAP_CM_REGADDR(OMAP3430_PER_MOD, CM_ICLKEN), .enable_bit = OMAP3430_EN_GPIO3_SHIFT, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "per_clkdm", .recalc = &followparent_recalc, }; @@ -2520,6 +2642,7 @@ static struct clk gpio2_ick = { .enable_reg = OMAP_CM_REGADDR(OMAP3430_PER_MOD, CM_ICLKEN), .enable_bit = OMAP3430_EN_GPIO2_SHIFT, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "per_clkdm", .recalc = &followparent_recalc, }; @@ -2529,6 +2652,7 @@ static struct clk wdt3_ick = { .enable_reg = OMAP_CM_REGADDR(OMAP3430_PER_MOD, CM_ICLKEN), .enable_bit = OMAP3430_EN_WDT3_SHIFT, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "per_clkdm", .recalc = &followparent_recalc, }; @@ -2538,6 +2662,7 @@ static struct clk uart3_ick = { .enable_reg = OMAP_CM_REGADDR(OMAP3430_PER_MOD, CM_ICLKEN), .enable_bit = OMAP3430_EN_UART3_SHIFT, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "per_clkdm", .recalc = &followparent_recalc, }; @@ -2547,6 +2672,7 @@ static struct clk gpt9_ick = { .enable_reg = OMAP_CM_REGADDR(OMAP3430_PER_MOD, CM_ICLKEN), .enable_bit = OMAP3430_EN_GPT9_SHIFT, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "per_clkdm", .recalc = &followparent_recalc, }; @@ -2556,6 +2682,7 @@ static struct clk gpt8_ick = { .enable_reg = OMAP_CM_REGADDR(OMAP3430_PER_MOD, CM_ICLKEN), .enable_bit = OMAP3430_EN_GPT8_SHIFT, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "per_clkdm", .recalc = &followparent_recalc, }; @@ -2565,6 +2692,7 @@ static struct clk gpt7_ick = { .enable_reg = OMAP_CM_REGADDR(OMAP3430_PER_MOD, CM_ICLKEN), .enable_bit = OMAP3430_EN_GPT7_SHIFT, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "per_clkdm", .recalc = &followparent_recalc, }; @@ -2574,6 +2702,7 @@ static struct clk gpt6_ick = { .enable_reg = OMAP_CM_REGADDR(OMAP3430_PER_MOD, CM_ICLKEN), .enable_bit = OMAP3430_EN_GPT6_SHIFT, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "per_clkdm", .recalc = &followparent_recalc, }; @@ -2583,6 +2712,7 @@ static struct clk gpt5_ick = { .enable_reg = OMAP_CM_REGADDR(OMAP3430_PER_MOD, CM_ICLKEN), .enable_bit = OMAP3430_EN_GPT5_SHIFT, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "per_clkdm", .recalc = &followparent_recalc, }; @@ -2592,6 +2722,7 @@ static struct clk gpt4_ick = { .enable_reg = OMAP_CM_REGADDR(OMAP3430_PER_MOD, CM_ICLKEN), .enable_bit = OMAP3430_EN_GPT4_SHIFT, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "per_clkdm", .recalc = &followparent_recalc, }; @@ -2601,6 +2732,7 @@ static struct clk gpt3_ick = { .enable_reg = OMAP_CM_REGADDR(OMAP3430_PER_MOD, CM_ICLKEN), .enable_bit = OMAP3430_EN_GPT3_SHIFT, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "per_clkdm", .recalc = &followparent_recalc, }; @@ -2610,6 +2742,7 @@ static struct clk gpt2_ick = { .enable_reg = OMAP_CM_REGADDR(OMAP3430_PER_MOD, CM_ICLKEN), .enable_bit = OMAP3430_EN_GPT2_SHIFT, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "per_clkdm", .recalc = &followparent_recalc, }; @@ -2620,6 +2753,7 @@ static struct clk mcbsp2_ick = { .enable_reg = OMAP_CM_REGADDR(OMAP3430_PER_MOD, CM_ICLKEN), .enable_bit = OMAP3430_EN_MCBSP2_SHIFT, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "per_clkdm", .recalc = &followparent_recalc, }; @@ -2630,6 +2764,7 @@ static struct clk mcbsp3_ick = { .enable_reg = OMAP_CM_REGADDR(OMAP3430_PER_MOD, CM_ICLKEN), .enable_bit = OMAP3430_EN_MCBSP3_SHIFT, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "per_clkdm", .recalc = &followparent_recalc, }; @@ -2640,12 +2775,13 @@ static struct clk mcbsp4_ick = { .enable_reg = OMAP_CM_REGADDR(OMAP3430_PER_MOD, CM_ICLKEN), .enable_bit = OMAP3430_EN_MCBSP4_SHIFT, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "per_clkdm", .recalc = &followparent_recalc, }; static const struct clksel mcbsp_234_clksel[] = { { .parent = &per_96m_fck, .rates = common_mcbsp_96m_rates }, - { .parent = &mcbsp_clks, .rates = common_mcbsp_mcbsp_rates }, + { .parent = &mcbsp_clks, .rates = common_mcbsp_mcbsp_rates }, { .parent = NULL } }; @@ -2659,6 +2795,7 @@ static struct clk mcbsp2_fck = { .clksel_mask = OMAP2_MCBSP2_CLKS_MASK, .clksel = mcbsp_234_clksel, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "per_clkdm", .recalc = &omap2_clksel_recalc, }; @@ -2672,6 +2809,7 @@ static struct clk mcbsp3_fck = { .clksel_mask = OMAP2_MCBSP3_CLKS_MASK, .clksel = mcbsp_234_clksel, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "per_clkdm", .recalc = &omap2_clksel_recalc, }; @@ -2685,6 +2823,7 @@ static struct clk mcbsp4_fck = { .clksel_mask = OMAP2_MCBSP4_CLKS_MASK, .clksel = mcbsp_234_clksel, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "per_clkdm", .recalc = &omap2_clksel_recalc, }; @@ -2732,6 +2871,7 @@ static struct clk emu_src_ck = { .clksel_mask = OMAP3430_MUX_CTRL_MASK, .clksel = emu_src_clksel, .flags = CLOCK_IN_OMAP343X | RATE_PROPAGATES | ALWAYS_ENABLED, + .clkdm_name = "emu_clkdm", .recalc = &omap2_clksel_recalc, }; @@ -2755,6 +2895,7 @@ static struct clk pclk_fck = { .clksel_mask = OMAP3430_CLKSEL_PCLK_MASK, .clksel = pclk_emu_clksel, .flags = CLOCK_IN_OMAP343X | RATE_PROPAGATES | ALWAYS_ENABLED, + .clkdm_name = "emu_clkdm", .recalc = &omap2_clksel_recalc, }; @@ -2777,6 +2918,7 @@ static struct clk pclkx2_fck = { .clksel_mask = OMAP3430_CLKSEL_PCLKX2_MASK, .clksel = pclkx2_emu_clksel, .flags = CLOCK_IN_OMAP343X | RATE_PROPAGATES | ALWAYS_ENABLED, + .clkdm_name = "emu_clkdm", .recalc = &omap2_clksel_recalc, }; @@ -2792,6 +2934,7 @@ static struct clk atclk_fck = { .clksel_mask = OMAP3430_CLKSEL_ATCLK_MASK, .clksel = atclk_emu_clksel, .flags = CLOCK_IN_OMAP343X | RATE_PROPAGATES | ALWAYS_ENABLED, + .clkdm_name = "emu_clkdm", .recalc = &omap2_clksel_recalc, }; @@ -2802,6 +2945,7 @@ static struct clk traceclk_src_fck = { .clksel_mask = OMAP3430_TRACE_MUX_CTRL_MASK, .clksel = emu_src_clksel, .flags = CLOCK_IN_OMAP343X | RATE_PROPAGATES | ALWAYS_ENABLED, + .clkdm_name = "emu_clkdm", .recalc = &omap2_clksel_recalc, }; @@ -2824,6 +2968,7 @@ static struct clk traceclk_fck = { .clksel_mask = OMAP3430_CLKSEL_TRACECLK_MASK, .clksel = traceclk_clksel, .flags = CLOCK_IN_OMAP343X | ALWAYS_ENABLED, + .clkdm_name = "emu_clkdm", .recalc = &omap2_clksel_recalc, }; @@ -2853,11 +2998,13 @@ static struct clk sr_l4_ick = { .name = "sr_l4_ick", .parent = &l4_ick, .flags = CLOCK_IN_OMAP343X, + .clkdm_name = "core_l4_clkdm", .recalc = &followparent_recalc, }; /* SECURE_32K_FCK clocks */ +/* XXX This clock no longer exists in 3430 TRM rev F */ static struct clk gpt12_fck = { .name = "gpt12_fck", .parent = &secure_32k_fck, @@ -2933,6 +3080,7 @@ static struct clk *onchip_34xx_clks[] __initdata = { &l3_ick, &l4_ick, &rm_ick, + &gfx_l3_ck, &gfx_l3_fck, &gfx_l3_ick, &gfx_cg1_ck, @@ -3014,12 +3162,10 @@ static struct clk *onchip_34xx_clks[] __initdata = { &dss2_alwon_fck, &dss_ick, &cam_mclk, - &cam_l3_ick, - &cam_l4_ick, + &cam_ick, &usbhost_120m_fck, &usbhost_48m_fck, - &usbhost_l3_ick, - &usbhost_l4_ick, + &usbhost_ick, &usbhost_sar_fck, &usim_fck, &gpt1_fck, diff --git a/arch/arm/mach-omap2/clockdomain.c b/arch/arm/mach-omap2/clockdomain.c new file mode 100644 index 0000000..4c3ce9c --- /dev/null +++ b/arch/arm/mach-omap2/clockdomain.c @@ -0,0 +1,623 @@ +/* + * OMAP2/3 clockdomain framework functions + * + * Copyright (C) 2008 Texas Instruments, Inc. + * Copyright (C) 2008 Nokia Corporation + * + * Written by Paul Walmsley and Jouni Högander + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License version 2 as + * published by the Free Software Foundation. + */ +#ifdef CONFIG_OMAP_DEBUG_CLOCKDOMAIN +# define DEBUG +#endif + +#include +#include +#include +#include +#include +#include +#include +#include + +#include + +#include + +#include + +#include "prm.h" +#include "prm-regbits-24xx.h" +#include "cm.h" + +#include +#include + +/* clkdm_list contains all registered struct clockdomains */ +static LIST_HEAD(clkdm_list); + +/* clkdm_mutex protects clkdm_list add and del ops */ +static DEFINE_MUTEX(clkdm_mutex); + +/* array of powerdomain deps to be added/removed when clkdm in hwsup mode */ +static struct clkdm_pwrdm_autodep *autodeps; + + +/* Private functions */ + +/* + * _autodep_lookup - resolve autodep pwrdm names to pwrdm pointers; store + * @autodep: struct clkdm_pwrdm_autodep * to resolve + * + * Resolve autodep powerdomain names to powerdomain pointers via + * pwrdm_lookup() and store the pointers in the autodep structure. An + * "autodep" is a powerdomain sleep/wakeup dependency that is + * automatically added and removed whenever clocks in the associated + * clockdomain are enabled or disabled (respectively) when the + * clockdomain is in hardware-supervised mode. Meant to be called + * once at clockdomain layer initialization, since these should remain + * fixed for a particular architecture. No return value. + */ +static void _autodep_lookup(struct clkdm_pwrdm_autodep *autodep) +{ + struct powerdomain *pwrdm; + + if (!autodep) + return; + + if (!omap_chip_is(autodep->omap_chip)) + return; + + pwrdm = pwrdm_lookup(autodep->pwrdm_name); + if (!pwrdm) { + pr_debug("clockdomain: _autodep_lookup: powerdomain %s " + "does not exist\n", autodep->pwrdm_name); + WARN_ON(1); + return; + } + autodep->pwrdm = pwrdm; + + return; +} + +/* + * _clkdm_add_autodeps - add auto sleepdeps/wkdeps to clkdm upon clock enable + * @clkdm: struct clockdomain * + * + * Add the "autodep" sleep & wakeup dependencies to clockdomain 'clkdm' + * in hardware-supervised mode. Meant to be called from clock framework + * when a clock inside clockdomain 'clkdm' is enabled. No return value. + */ +static void _clkdm_add_autodeps(struct clockdomain *clkdm) +{ + struct clkdm_pwrdm_autodep *autodep; + + for (autodep = autodeps; autodep->pwrdm_name; autodep++) { + if (!autodep->pwrdm) + continue; + + pr_debug("clockdomain: adding %s sleepdep/wkdep for " + "pwrdm %s\n", autodep->pwrdm_name, + clkdm->pwrdm->name); + + pwrdm_add_sleepdep(clkdm->pwrdm, autodep->pwrdm); + pwrdm_add_wkdep(clkdm->pwrdm, autodep->pwrdm); + } +} + +/* + * _clkdm_add_autodeps - remove auto sleepdeps/wkdeps from clkdm + * @clkdm: struct clockdomain * + * + * Remove the "autodep" sleep & wakeup dependencies from clockdomain 'clkdm' + * in hardware-supervised mode. Meant to be called from clock framework + * when a clock inside clockdomain 'clkdm' is disabled. No return value. + */ +static void _clkdm_del_autodeps(struct clockdomain *clkdm) +{ + struct clkdm_pwrdm_autodep *autodep; + + for (autodep = autodeps; autodep->pwrdm_name; autodep++) { + if (!autodep->pwrdm) + continue; + + pr_debug("clockdomain: removing %s sleepdep/wkdep for " + "pwrdm %s\n", autodep->pwrdm_name, + clkdm->pwrdm->name); + + pwrdm_del_sleepdep(clkdm->pwrdm, autodep->pwrdm); + pwrdm_del_wkdep(clkdm->pwrdm, autodep->pwrdm); + } +} + + +static struct clockdomain *_clkdm_lookup(const char *name) +{ + struct clockdomain *clkdm, *temp_clkdm; + + if (!name) + return NULL; + + clkdm = NULL; + + list_for_each_entry(temp_clkdm, &clkdm_list, node) { + if (!strcmp(name, temp_clkdm->name)) { + clkdm = temp_clkdm; + break; + } + } + + return clkdm; +} + + +/* Public functions */ + +/** + * clkdm_init - set up the clockdomain layer + * @clkdms: optional pointer to an array of clockdomains to register + * @init_autodeps: optional pointer to an array of autodeps to register + * + * Set up internal state. If a pointer to an array of clockdomains + * was supplied, loop through the list of clockdomains, register all + * that are available on the current platform. Similarly, if a + * pointer to an array of clockdomain-powerdomain autodependencies was + * provided, register those. No return value. + */ +void clkdm_init(struct clockdomain **clkdms, + struct clkdm_pwrdm_autodep *init_autodeps) +{ + struct clockdomain **c = NULL; + struct clkdm_pwrdm_autodep *autodep = NULL; + + if (clkdms) + for (c = clkdms; *c; c++) + clkdm_register(*c); + + autodeps = init_autodeps; + if (autodeps) + for (autodep = autodeps; autodep->pwrdm_name; autodep++) + _autodep_lookup(autodep); +} + +/** + * clkdm_register - register a clockdomain + * @clkdm: struct clockdomain * to register + * + * Adds a clockdomain to the internal clockdomain list. + * Returns -EINVAL if given a null pointer, -EEXIST if a clockdomain is + * already registered by the provided name, or 0 upon success. + */ +int clkdm_register(struct clockdomain *clkdm) +{ + int ret = -EINVAL; + struct powerdomain *pwrdm; + + if (!clkdm || !clkdm->name) + return -EINVAL; + + if (!omap_chip_is(clkdm->omap_chip)) + return -EINVAL; + + pwrdm = pwrdm_lookup(clkdm->pwrdm_name); + if (!pwrdm) { + pr_debug("clockdomain: clkdm_register %s: powerdomain %s " + "does not exist\n", clkdm->name, clkdm->pwrdm_name); + return -EINVAL; + } + clkdm->pwrdm = pwrdm; + + mutex_lock(&clkdm_mutex); + /* Verify that the clockdomain is not already registered */ + if (_clkdm_lookup(clkdm->name)) { + ret = -EEXIST; + goto cr_unlock; + }; + + list_add(&clkdm->node, &clkdm_list); + + pwrdm_add_clkdm(pwrdm, clkdm); + + pr_debug("clockdomain: registered %s\n", clkdm->name); + ret = 0; + +cr_unlock: + mutex_unlock(&clkdm_mutex); + + return ret; +} + +/** + * clkdm_unregister - unregister a clockdomain + * @clkdm: struct clockdomain * to unregister + * + * Removes a clockdomain from the internal clockdomain list. Returns + * -EINVAL if clkdm argument is NULL. + */ +int clkdm_unregister(struct clockdomain *clkdm) +{ + if (!clkdm) + return -EINVAL; + + pwrdm_del_clkdm(clkdm->pwrdm, clkdm); + + mutex_lock(&clkdm_mutex); + list_del(&clkdm->node); + mutex_unlock(&clkdm_mutex); + + pr_debug("clockdomain: unregistered %s\n", clkdm->name); + + return 0; +} + +/** + * clkdm_lookup - look up a clockdomain by name, return a pointer + * @name: name of clockdomain + * + * Find a registered clockdomain by its name. Returns a pointer to the + * struct clockdomain if found, or NULL otherwise. + */ +struct clockdomain *clkdm_lookup(const char *name) +{ + struct clockdomain *clkdm, *temp_clkdm; + + if (!name) + return NULL; + + clkdm = NULL; + + mutex_lock(&clkdm_mutex); + list_for_each_entry(temp_clkdm, &clkdm_list, node) { + if (!strcmp(name, temp_clkdm->name)) { + clkdm = temp_clkdm; + break; + } + } + mutex_unlock(&clkdm_mutex); + + return clkdm; +} + +/** + * clkdm_for_each - call function on each registered clockdomain + * @fn: callback function * + * + * Call the supplied function for each registered clockdomain. + * The callback function can return anything but 0 to bail + * out early from the iterator. The callback function is called with + * the clkdm_mutex held, so no clockdomain structure manipulation + * functions should be called from the callback, although hardware + * clockdomain control functions are fine. Returns the last return + * value of the callback function, which should be 0 for success or + * anything else to indicate failure; or -EINVAL if the function pointer + * is null. + */ +int clkdm_for_each(int (*fn)(struct clockdomain *clkdm)) +{ + struct clockdomain *clkdm; + int ret = 0; + + if (!fn) + return -EINVAL; + + mutex_lock(&clkdm_mutex); + list_for_each_entry(clkdm, &clkdm_list, node) { + ret = (*fn)(clkdm); + if (ret) + break; + } + mutex_unlock(&clkdm_mutex); + + return ret; +} + + +/** + * clkdm_get_pwrdm - return a ptr to the pwrdm that this clkdm resides in + * @clkdm: struct clockdomain * + * + * Return a pointer to the struct powerdomain that the specified clockdomain + * 'clkdm' exists in, or returns NULL if clkdm argument is NULL. + */ +struct powerdomain *clkdm_get_pwrdm(struct clockdomain *clkdm) +{ + if (!clkdm) + return NULL; + + return clkdm->pwrdm; +} + + +/* Hardware clockdomain control */ + +/** + * omap2_clkdm_clktrctrl_read - read the clkdm's current state transition mode + * @clk: struct clk * of a clockdomain + * + * Return the clockdomain's current state transition mode from the + * corresponding domain CM_CLKSTCTRL register. Returns -EINVAL if clk + * is NULL or the current mode upon success. + */ +static int omap2_clkdm_clktrctrl_read(struct clockdomain *clkdm) +{ + u32 v; + + if (!clkdm) + return -EINVAL; + + v = cm_read_mod_reg(clkdm->pwrdm->prcm_offs, CM_CLKSTCTRL); + v &= clkdm->clktrctrl_mask; + v >>= __ffs(clkdm->clktrctrl_mask); + + return v; +} + +/** + * omap2_clkdm_sleep - force clockdomain sleep transition + * @clkdm: struct clockdomain * + * + * Instruct the CM to force a sleep transition on the specified + * clockdomain 'clkdm'. Returns -EINVAL if clk is NULL or if + * clockdomain does not support software-initiated sleep; 0 upon + * success. + */ +int omap2_clkdm_sleep(struct clockdomain *clkdm) +{ + if (!clkdm) + return -EINVAL; + + if (!(clkdm->flags & CLKDM_CAN_FORCE_SLEEP)) { + pr_debug("clockdomain: %s does not support forcing " + "sleep via software\n", clkdm->name); + return -EINVAL; + } + + pr_debug("clockdomain: forcing sleep on %s\n", clkdm->name); + + if (cpu_is_omap24xx()) { + + cm_set_mod_reg_bits(OMAP24XX_FORCESTATE, + clkdm->pwrdm->prcm_offs, PM_PWSTCTRL); + + } else if (cpu_is_omap34xx()) { + + u32 v = (OMAP34XX_CLKSTCTRL_FORCE_SLEEP << + __ffs(clkdm->clktrctrl_mask)); + + cm_rmw_mod_reg_bits(clkdm->clktrctrl_mask, v, + clkdm->pwrdm->prcm_offs, CM_CLKSTCTRL); + + } else { + BUG(); + }; + + return 0; +} + +/** + * omap2_clkdm_wakeup - force clockdomain wakeup transition + * @clkdm: struct clockdomain * + * + * Instruct the CM to force a wakeup transition on the specified + * clockdomain 'clkdm'. Returns -EINVAL if clkdm is NULL or if the + * clockdomain does not support software-controlled wakeup; 0 upon + * success. + */ +int omap2_clkdm_wakeup(struct clockdomain *clkdm) +{ + if (!clkdm) + return -EINVAL; + + if (!(clkdm->flags & CLKDM_CAN_FORCE_WAKEUP)) { + pr_debug("clockdomain: %s does not support forcing " + "wakeup via software\n", clkdm->name); + return -EINVAL; + } + + pr_debug("clockdomain: forcing wakeup on %s\n", clkdm->name); + + if (cpu_is_omap24xx()) { + + cm_clear_mod_reg_bits(OMAP24XX_FORCESTATE, + clkdm->pwrdm->prcm_offs, PM_PWSTCTRL); + + } else if (cpu_is_omap34xx()) { + + u32 v = (OMAP34XX_CLKSTCTRL_FORCE_WAKEUP << + __ffs(clkdm->clktrctrl_mask)); + + cm_rmw_mod_reg_bits(clkdm->clktrctrl_mask, v, + clkdm->pwrdm->prcm_offs, CM_CLKSTCTRL); + + } else { + BUG(); + }; + + return 0; +} + +/** + * omap2_clkdm_allow_idle - enable hwsup idle transitions for clkdm + * @clkdm: struct clockdomain * + * + * Allow the hardware to automatically switch the clockdomain into + * active or idle states, as needed by downstream clocks. If the + * clockdomain has any downstream clocks enabled in the clock + * framework, wkdep/sleepdep autodependencies are added; this is so + * device drivers can read and write to the device. No return value. + */ +void omap2_clkdm_allow_idle(struct clockdomain *clkdm) +{ + u32 v; + + if (!clkdm) + return; + + if (!(clkdm->flags & CLKDM_CAN_ENABLE_AUTO)) { + pr_debug("clock: automatic idle transitions cannot be enabled " + "on clockdomain %s\n", clkdm->name); + return; + } + + pr_debug("clockdomain: enabling automatic idle transitions for %s\n", + clkdm->name); + + if (atomic_read(&clkdm->usecount) > 0) + _clkdm_add_autodeps(clkdm); + + if (cpu_is_omap24xx()) + v = OMAP24XX_CLKSTCTRL_ENABLE_AUTO; + else if (cpu_is_omap34xx()) + v = OMAP34XX_CLKSTCTRL_ENABLE_AUTO; + else + BUG(); + + + cm_rmw_mod_reg_bits(clkdm->clktrctrl_mask, + v << __ffs(clkdm->clktrctrl_mask), + clkdm->pwrdm->prcm_offs, + CM_CLKSTCTRL); +} + +/** + * omap2_clkdm_deny_idle - disable hwsup idle transitions for clkdm + * @clkdm: struct clockdomain * + * + * Prevent the hardware from automatically switching the clockdomain + * into inactive or idle states. If the clockdomain has downstream + * clocks enabled in the clock framework, wkdep/sleepdep + * autodependencies are removed. No return value. + */ +void omap2_clkdm_deny_idle(struct clockdomain *clkdm) +{ + u32 v; + + if (!clkdm) + return; + + if (!(clkdm->flags & CLKDM_CAN_DISABLE_AUTO)) { + pr_debug("clockdomain: automatic idle transitions cannot be " + "disabled on %s\n", clkdm->name); + return; + } + + pr_debug("clockdomain: disabling automatic idle transitions for %s\n", + clkdm->name); + + if (cpu_is_omap24xx()) + v = OMAP24XX_CLKSTCTRL_DISABLE_AUTO; + else if (cpu_is_omap34xx()) + v = OMAP34XX_CLKSTCTRL_DISABLE_AUTO; + else + BUG(); + + cm_rmw_mod_reg_bits(clkdm->clktrctrl_mask, + v << __ffs(clkdm->clktrctrl_mask), + clkdm->pwrdm->prcm_offs, CM_CLKSTCTRL); + + if (atomic_read(&clkdm->usecount) > 0) + _clkdm_del_autodeps(clkdm); +} + + +/* Clockdomain-to-clock framework interface code */ + +/** + * omap2_clkdm_clk_enable - add an enabled downstream clock to this clkdm + * @clkdm: struct clockdomain * + * @clk: struct clk * of the enabled downstream clock + * + * Increment the usecount of this clockdomain 'clkdm' and ensure that + * it is awake. Intended to be called by clk_enable() code. If the + * clockdomain is in software-supervised idle mode, force the + * clockdomain to wake. If the clockdomain is in hardware-supervised + * idle mode, add clkdm-pwrdm autodependencies, to ensure that devices + * in the clockdomain can be read from/written to by on-chip processors. + * Returns -EINVAL if passed null pointers; returns 0 upon success or + * if the clockdomain is in hwsup idle mode. + */ +int omap2_clkdm_clk_enable(struct clockdomain *clkdm, struct clk *clk) +{ + int v; + + /* + * XXX Rewrite this code to maintain a list of enabled + * downstream clocks for debugging purposes? + */ + + if (!clkdm || !clk) + return -EINVAL; + + if (atomic_inc_return(&clkdm->usecount) > 1) + return 0; + + /* Clockdomain now has one enabled downstream clock */ + + pr_debug("clockdomain: clkdm %s: clk %s now enabled\n", clkdm->name, + clk->name); + + v = omap2_clkdm_clktrctrl_read(clkdm); + + if ((cpu_is_omap34xx() && v == OMAP34XX_CLKSTCTRL_ENABLE_AUTO) || + (cpu_is_omap24xx() && v == OMAP24XX_CLKSTCTRL_ENABLE_AUTO)) + _clkdm_add_autodeps(clkdm); + else + omap2_clkdm_wakeup(clkdm); + + return 0; +} + +/** + * omap2_clkdm_clk_disable - remove an enabled downstream clock from this clkdm + * @clkdm: struct clockdomain * + * @clk: struct clk * of the disabled downstream clock + * + * Decrement the usecount of this clockdomain 'clkdm'. Intended to be + * called by clk_disable() code. If the usecount goes to 0, put the + * clockdomain to sleep (software-supervised mode) or remove the + * clkdm-pwrdm autodependencies (hardware-supervised mode). Returns + * -EINVAL if passed null pointers; -ERANGE if the clkdm usecount + * underflows and debugging is enabled; or returns 0 upon success or + * if the clockdomain is in hwsup idle mode. + */ +int omap2_clkdm_clk_disable(struct clockdomain *clkdm, struct clk *clk) +{ + int v; + + /* + * XXX Rewrite this code to maintain a list of enabled + * downstream clocks for debugging purposes? + */ + + if (!clkdm || !clk) + return -EINVAL; + +#ifdef DEBUG + if (atomic_read(&clkdm->usecount) == 0) { + WARN_ON(1); /* underflow */ + return -ERANGE; + } +#endif + + if (atomic_dec_return(&clkdm->usecount) > 0) + return 0; + + /* All downstream clocks of this clockdomain are now disabled */ + + pr_debug("clockdomain: clkdm %s: clk %s now disabled\n", clkdm->name, + clk->name); + + v = omap2_clkdm_clktrctrl_read(clkdm); + + if ((cpu_is_omap34xx() && v == OMAP34XX_CLKSTCTRL_ENABLE_AUTO) || + (cpu_is_omap24xx() && v == OMAP24XX_CLKSTCTRL_ENABLE_AUTO)) + _clkdm_del_autodeps(clkdm); + else + omap2_clkdm_sleep(clkdm); + + return 0; +} + diff --git a/arch/arm/mach-omap2/clockdomains.h b/arch/arm/mach-omap2/clockdomains.h new file mode 100644 index 0000000..cd86dcc --- /dev/null +++ b/arch/arm/mach-omap2/clockdomains.h @@ -0,0 +1,305 @@ +/* + * OMAP2/3 clockdomains + * + * Copyright (C) 2008 Texas Instruments, Inc. + * Copyright (C) 2008 Nokia Corporation + * + * Written by Paul Walmsley + */ + +#ifndef __ARCH_ARM_MACH_OMAP2_CLOCKDOMAINS_H +#define __ARCH_ARM_MACH_OMAP2_CLOCKDOMAINS_H + +#include + +/* + * OMAP2/3-common clockdomains + */ + +/* This is an implicit clockdomain - it is never defined as such in TRM */ +static struct clockdomain wkup_clkdm = { + .name = "wkup_clkdm", + .pwrdm_name = "wkup_pwrdm", + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP24XX | CHIP_IS_OMAP3430), +}; + +/* + * 2420-only clockdomains + */ + +#if defined(CONFIG_ARCH_OMAP2420) + +static struct clockdomain mpu_2420_clkdm = { + .name = "mpu_clkdm", + .pwrdm_name = "mpu_pwrdm", + .flags = CLKDM_CAN_HWSUP, + .clktrctrl_mask = OMAP24XX_AUTOSTATE_MPU_MASK, + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP2420), +}; + +static struct clockdomain iva1_2420_clkdm = { + .name = "iva1_clkdm", + .pwrdm_name = "dsp_pwrdm", + .flags = CLKDM_CAN_HWSUP_SWSUP, + .clktrctrl_mask = OMAP2420_AUTOSTATE_IVA_MASK, + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP2420), +}; + +#endif /* CONFIG_ARCH_OMAP2420 */ + + +/* + * 2430-only clockdomains + */ + +#if defined(CONFIG_ARCH_OMAP2430) + +static struct clockdomain mpu_2430_clkdm = { + .name = "mpu_clkdm", + .pwrdm_name = "mpu_pwrdm", + .flags = CLKDM_CAN_HWSUP_SWSUP, + .clktrctrl_mask = OMAP24XX_AUTOSTATE_MPU_MASK, + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP2430), +}; + +static struct clockdomain mdm_clkdm = { + .name = "mdm_clkdm", + .pwrdm_name = "mdm_pwrdm", + .flags = CLKDM_CAN_HWSUP_SWSUP, + .clktrctrl_mask = OMAP2430_AUTOSTATE_MDM_MASK, + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP2430), +}; + +#endif /* CONFIG_ARCH_OMAP2430 */ + + +/* + * 24XX-only clockdomains + */ + +#if defined(CONFIG_ARCH_OMAP24XX) + +static struct clockdomain dsp_clkdm = { + .name = "dsp_clkdm", + .pwrdm_name = "dsp_pwrdm", + .flags = CLKDM_CAN_HWSUP_SWSUP, + .clktrctrl_mask = OMAP24XX_AUTOSTATE_DSP_MASK, + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP24XX), +}; + +static struct clockdomain gfx_24xx_clkdm = { + .name = "gfx_clkdm", + .pwrdm_name = "gfx_pwrdm", + .flags = CLKDM_CAN_HWSUP_SWSUP, + .clktrctrl_mask = OMAP24XX_AUTOSTATE_GFX_MASK, + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP24XX), +}; + +static struct clockdomain core_l3_24xx_clkdm = { + .name = "core_l3_clkdm", + .pwrdm_name = "core_pwrdm", + .flags = CLKDM_CAN_HWSUP, + .clktrctrl_mask = OMAP24XX_AUTOSTATE_L3_MASK, + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP24XX), +}; + +static struct clockdomain core_l4_24xx_clkdm = { + .name = "core_l4_clkdm", + .pwrdm_name = "core_pwrdm", + .flags = CLKDM_CAN_HWSUP, + .clktrctrl_mask = OMAP24XX_AUTOSTATE_L4_MASK, + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP24XX), +}; + +static struct clockdomain dss_24xx_clkdm = { + .name = "dss_clkdm", + .pwrdm_name = "core_pwrdm", + .flags = CLKDM_CAN_HWSUP, + .clktrctrl_mask = OMAP24XX_AUTOSTATE_DSS_MASK, + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP24XX), +}; + +#endif /* CONFIG_ARCH_OMAP24XX */ + + +/* + * 34xx clockdomains + */ + +#if defined(CONFIG_ARCH_OMAP34XX) + +static struct clockdomain mpu_34xx_clkdm = { + .name = "mpu_clkdm", + .pwrdm_name = "mpu_pwrdm", + .flags = CLKDM_CAN_HWSUP | CLKDM_CAN_FORCE_WAKEUP, + .clktrctrl_mask = OMAP3430_CLKTRCTRL_MPU_MASK, + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430), +}; + +static struct clockdomain neon_clkdm = { + .name = "neon_clkdm", + .pwrdm_name = "neon_pwrdm", + .flags = CLKDM_CAN_HWSUP_SWSUP, + .clktrctrl_mask = OMAP3430_CLKTRCTRL_NEON_MASK, + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430), +}; + +static struct clockdomain iva2_clkdm = { + .name = "iva2_clkdm", + .pwrdm_name = "iva2_pwrdm", + .flags = CLKDM_CAN_HWSUP_SWSUP, + .clktrctrl_mask = OMAP3430_CLKTRCTRL_IVA2_MASK, + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430), +}; + +static struct clockdomain gfx_3430es1_clkdm = { + .name = "gfx_clkdm", + .pwrdm_name = "gfx_pwrdm", + .flags = CLKDM_CAN_HWSUP_SWSUP, + .clktrctrl_mask = OMAP3430ES1_CLKTRCTRL_GFX_MASK, + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430ES1), +}; + +static struct clockdomain sgx_clkdm = { + .name = "sgx_clkdm", + .pwrdm_name = "sgx_pwrdm", + .flags = CLKDM_CAN_HWSUP_SWSUP, + .clktrctrl_mask = OMAP3430ES2_CLKTRCTRL_SGX_MASK, + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430ES2), +}; + +/* + * The die-to-die clockdomain was documented in the 34xx ES1 TRM, but + * then that information was removed from the 34xx ES2+ TRM. It is + * unclear whether the core is still there, but the clockdomain logic + * is there, and must be programmed to an appropriate state if the + * CORE clockdomain is to become inactive. + */ +static struct clockdomain d2d_clkdm = { + .name = "d2d_clkdm", + .pwrdm_name = "core_pwrdm", + .flags = CLKDM_CAN_HWSUP, + .clktrctrl_mask = OMAP3430ES1_CLKTRCTRL_D2D_MASK, + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430), +}; + +static struct clockdomain core_l3_34xx_clkdm = { + .name = "core_l3_clkdm", + .pwrdm_name = "core_pwrdm", + .flags = CLKDM_CAN_HWSUP, + .clktrctrl_mask = OMAP3430_CLKTRCTRL_L3_MASK, + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430), +}; + +static struct clockdomain core_l4_34xx_clkdm = { + .name = "core_l4_clkdm", + .pwrdm_name = "core_pwrdm", + .flags = CLKDM_CAN_HWSUP, + .clktrctrl_mask = OMAP3430_CLKTRCTRL_L4_MASK, + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430), +}; + +static struct clockdomain dss_34xx_clkdm = { + .name = "dss_clkdm", + .pwrdm_name = "dss_pwrdm", + .flags = CLKDM_CAN_HWSUP_SWSUP, + .clktrctrl_mask = OMAP3430_CLKTRCTRL_DSS_MASK, + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430), +}; + +static struct clockdomain cam_clkdm = { + .name = "cam_clkdm", + .pwrdm_name = "cam_pwrdm", + .flags = CLKDM_CAN_HWSUP_SWSUP, + .clktrctrl_mask = OMAP3430_CLKTRCTRL_CAM_MASK, + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430), +}; + +static struct clockdomain usbhost_clkdm = { + .name = "usbhost_clkdm", + .pwrdm_name = "usbhost_pwrdm", + .flags = CLKDM_CAN_HWSUP_SWSUP, + .clktrctrl_mask = OMAP3430ES2_CLKTRCTRL_USBHOST_MASK, + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430ES2), +}; + +static struct clockdomain per_clkdm = { + .name = "per_clkdm", + .pwrdm_name = "per_pwrdm", + .flags = CLKDM_CAN_HWSUP_SWSUP, + .clktrctrl_mask = OMAP3430_CLKTRCTRL_PER_MASK, + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430), +}; + +static struct clockdomain emu_clkdm = { + .name = "emu_clkdm", + .pwrdm_name = "emu_pwrdm", + .flags = CLKDM_CAN_ENABLE_AUTO | CLKDM_CAN_SWSUP, + .clktrctrl_mask = OMAP3430_CLKTRCTRL_EMU_MASK, + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430), +}; + +#endif /* CONFIG_ARCH_OMAP34XX */ + +/* + * Clockdomain-powerdomain hwsup dependencies (34XX only) + */ + +static struct clkdm_pwrdm_autodep clkdm_pwrdm_autodeps[] = { + { + .pwrdm_name = "mpu_pwrdm", + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430) + }, + { + .pwrdm_name = "iva2_pwrdm", + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430) + }, + { NULL } +}; + +/* + * + */ + +static struct clockdomain *clockdomains_omap[] = { + + &wkup_clkdm, + +#ifdef CONFIG_ARCH_OMAP2420 + &mpu_2420_clkdm, + &iva1_2420_clkdm, +#endif + +#ifdef CONFIG_ARCH_OMAP2430 + &mpu_2430_clkdm, + &mdm_clkdm, +#endif + +#ifdef CONFIG_ARCH_OMAP24XX + &dsp_clkdm, + &gfx_24xx_clkdm, + &core_l3_24xx_clkdm, + &core_l4_24xx_clkdm, + &dss_24xx_clkdm, +#endif + +#ifdef CONFIG_ARCH_OMAP34XX + &mpu_34xx_clkdm, + &neon_clkdm, + &iva2_clkdm, + &gfx_3430es1_clkdm, + &sgx_clkdm, + &d2d_clkdm, + &core_l3_34xx_clkdm, + &core_l4_34xx_clkdm, + &dss_34xx_clkdm, + &cam_clkdm, + &usbhost_clkdm, + &per_clkdm, + &emu_clkdm, +#endif + + NULL, +}; + +#endif diff --git a/arch/arm/mach-omap2/cm-regbits-24xx.h b/arch/arm/mach-omap2/cm-regbits-24xx.h index 20ac381..1098ecf 100644 --- a/arch/arm/mach-omap2/cm-regbits-24xx.h +++ b/arch/arm/mach-omap2/cm-regbits-24xx.h @@ -63,7 +63,8 @@ #define OMAP24XX_CLKSEL_MPU_MASK (0x1f << 0) /* CM_CLKSTCTRL_MPU */ -#define OMAP24XX_AUTOSTATE_MPU (1 << 0) +#define OMAP24XX_AUTOSTATE_MPU_SHIFT 0 +#define OMAP24XX_AUTOSTATE_MPU_MASK (1 << 0) /* CM_FCLKEN1_CORE specific bits*/ #define OMAP24XX_EN_TV_SHIFT 2 @@ -238,9 +239,12 @@ #define OMAP24XX_CLKSEL_GPT2_MASK (0x3 << 2) /* CM_CLKSTCTRL_CORE */ -#define OMAP24XX_AUTOSTATE_DSS (1 << 2) -#define OMAP24XX_AUTOSTATE_L4 (1 << 1) -#define OMAP24XX_AUTOSTATE_L3 (1 << 0) +#define OMAP24XX_AUTOSTATE_DSS_SHIFT 2 +#define OMAP24XX_AUTOSTATE_DSS_MASK (1 << 2) +#define OMAP24XX_AUTOSTATE_L4_SHIFT 1 +#define OMAP24XX_AUTOSTATE_L4_MASK (1 << 1) +#define OMAP24XX_AUTOSTATE_L3_SHIFT 0 +#define OMAP24XX_AUTOSTATE_L3_MASK (1 << 0) /* CM_FCLKEN_GFX */ #define OMAP24XX_EN_3D_SHIFT 2 @@ -255,7 +259,8 @@ /* CM_CLKSEL_GFX specific bits */ /* CM_CLKSTCTRL_GFX */ -#define OMAP24XX_AUTOSTATE_GFX (1 << 0) +#define OMAP24XX_AUTOSTATE_GFX_SHIFT 0 +#define OMAP24XX_AUTOSTATE_GFX_MASK (1 << 0) /* CM_FCLKEN_WKUP specific bits */ @@ -367,8 +372,10 @@ #define OMAP24XX_CLKSEL_DSP_MASK (0x1f << 0) /* CM_CLKSTCTRL_DSP */ -#define OMAP2420_AUTOSTATE_IVA (1 << 8) -#define OMAP24XX_AUTOSTATE_DSP (1 << 0) +#define OMAP2420_AUTOSTATE_IVA_SHIFT 8 +#define OMAP2420_AUTOSTATE_IVA_MASK (1 << 8) +#define OMAP24XX_AUTOSTATE_DSP_SHIFT 0 +#define OMAP24XX_AUTOSTATE_DSP_MASK (1 << 0) /* CM_FCLKEN_MDM */ /* 2430 only */ @@ -396,6 +403,7 @@ /* CM_CLKSTCTRL_MDM */ /* 2430 only */ -#define OMAP2430_AUTOSTATE_MDM (1 << 0) +#define OMAP2430_AUTOSTATE_MDM_SHIFT 0 +#define OMAP2430_AUTOSTATE_MDM_MASK (1 << 0) #endif diff --git a/arch/arm/mach-omap2/cm-regbits-34xx.h b/arch/arm/mach-omap2/cm-regbits-34xx.h index ee4c0ca..219f5c8 100644 --- a/arch/arm/mach-omap2/cm-regbits-34xx.h +++ b/arch/arm/mach-omap2/cm-regbits-34xx.h @@ -96,7 +96,8 @@ #define OMAP3430_CLKTRCTRL_IVA2_MASK (0x3 << 0) /* CM_CLKSTST_IVA2 */ -#define OMAP3430_CLKACTIVITY_IVA2 (1 << 0) +#define OMAP3430_CLKACTIVITY_IVA2_SHIFT 0 +#define OMAP3430_CLKACTIVITY_IVA2_MASK (1 << 0) /* CM_REVISION specific bits */ @@ -140,7 +141,8 @@ #define OMAP3430_CLKTRCTRL_MPU_MASK (0x3 << 0) /* CM_CLKSTST_MPU */ -#define OMAP3430_CLKACTIVITY_MPU (1 << 0) +#define OMAP3430_CLKACTIVITY_MPU_SHIFT 0 +#define OMAP3430_CLKACTIVITY_MPU_MASK (1 << 0) /* CM_FCLKEN1_CORE specific bits */ @@ -300,9 +302,12 @@ #define OMAP3430_CLKTRCTRL_L3_MASK (0x3 << 0) /* CM_CLKSTST_CORE */ -#define OMAP3430ES1_CLKACTIVITY_D2D (1 << 2) -#define OMAP3430_CLKACTIVITY_L4 (1 << 1) -#define OMAP3430_CLKACTIVITY_L3 (1 << 0) +#define OMAP3430ES1_CLKACTIVITY_D2D_SHIFT 2 +#define OMAP3430ES1_CLKACTIVITY_D2D_MASK (1 << 2) +#define OMAP3430_CLKACTIVITY_L4_SHIFT 1 +#define OMAP3430_CLKACTIVITY_L4_MASK (1 << 1) +#define OMAP3430_CLKACTIVITY_L3_SHIFT 0 +#define OMAP3430_CLKACTIVITY_L3_MASK (1 << 0) /* CM_FCLKEN_GFX */ #define OMAP3430ES1_EN_3D (1 << 2) @@ -323,7 +328,8 @@ #define OMAP3430ES1_CLKTRCTRL_GFX_MASK (0x3 << 0) /* CM_CLKSTST_GFX */ -#define OMAP3430ES1_CLKACTIVITY_GFX (1 << 0) +#define OMAP3430ES1_CLKACTIVITY_GFX_SHIFT 0 +#define OMAP3430ES1_CLKACTIVITY_GFX_MASK (1 << 0) /* CM_FCLKEN_SGX */ #define OMAP3430ES2_EN_SGX_SHIFT 1 @@ -333,6 +339,14 @@ #define OMAP3430ES2_CLKSEL_SGX_SHIFT 0 #define OMAP3430ES2_CLKSEL_SGX_MASK (0x7 << 0) +/* CM_CLKSTCTRL_SGX */ +#define OMAP3430ES2_CLKTRCTRL_SGX_SHIFT 0 +#define OMAP3430ES2_CLKTRCTRL_SGX_MASK (0x3 << 0) + +/* CM_CLKSTST_SGX */ +#define OMAP3430ES2_CLKACTIVITY_SGX_SHIFT 0 +#define OMAP3430ES2_CLKACTIVITY_SGX_MASK (1 << 0) + /* CM_FCLKEN_WKUP specific bits */ #define OMAP3430ES2_EN_USIMOCP_SHIFT 9 @@ -498,7 +512,8 @@ #define OMAP3430_CLKTRCTRL_DSS_MASK (0x3 << 0) /* CM_CLKSTST_DSS */ -#define OMAP3430_CLKACTIVITY_DSS (1 << 0) +#define OMAP3430_CLKACTIVITY_DSS_SHIFT 0 +#define OMAP3430_CLKACTIVITY_DSS_MASK (1 << 0) /* CM_FCLKEN_CAM specific bits */ @@ -522,7 +537,8 @@ #define OMAP3430_CLKTRCTRL_CAM_MASK (0x3 << 0) /* CM_CLKSTST_CAM */ -#define OMAP3430_CLKACTIVITY_CAM (1 << 0) +#define OMAP3430_CLKACTIVITY_CAM_SHIFT 0 +#define OMAP3430_CLKACTIVITY_CAM_MASK (1 << 0) /* CM_FCLKEN_PER specific bits */ @@ -598,7 +614,8 @@ #define OMAP3430_CLKTRCTRL_PER_MASK (0x3 << 0) /* CM_CLKSTST_PER */ -#define OMAP3430_CLKACTIVITY_PER (1 << 0) +#define OMAP3430_CLKACTIVITY_PER_SHIFT 0 +#define OMAP3430_CLKACTIVITY_PER_MASK (1 << 0) /* CM_CLKSEL1_EMU */ #define OMAP3430_DIV_DPLL4_SHIFT 24 @@ -623,7 +640,8 @@ #define OMAP3430_CLKTRCTRL_EMU_MASK (0x3 << 0) /* CM_CLKSTST_EMU */ -#define OMAP3430_CLKACTIVITY_EMU (1 << 0) +#define OMAP3430_CLKACTIVITY_EMU_SHIFT 0 +#define OMAP3430_CLKACTIVITY_EMU_MASK (1 << 0) /* CM_CLKSEL2_EMU specific bits */ #define OMAP3430_CORE_DPLL_EMU_MULT_SHIFT 8 @@ -673,6 +691,8 @@ #define OMAP3430ES2_CLKTRCTRL_USBHOST_SHIFT 0 #define OMAP3430ES2_CLKTRCTRL_USBHOST_MASK (3 << 0) - +/* CM_CLKSTST_USBHOST */ +#define OMAP3430ES2_CLKACTIVITY_USBHOST_SHIFT 0 +#define OMAP3430ES2_CLKACTIVITY_USBHOST_MASK (1 << 0) #endif diff --git a/arch/arm/mach-omap2/cm.h b/arch/arm/mach-omap2/cm.h index 87a44c7..65fdf78 100644 --- a/arch/arm/mach-omap2/cm.h +++ b/arch/arm/mach-omap2/cm.h @@ -18,7 +18,7 @@ #ifndef __ASSEMBLER__ #define OMAP_CM_REGADDR(module, reg) \ - (void __iomem *)IO_ADDRESS(OMAP2_CM_BASE + (module) + (reg)) + IO_ADDRESS(OMAP2_CM_BASE + (module) + (reg)) #else #define OMAP2420_CM_REGADDR(module, reg) \ IO_ADDRESS(OMAP2420_CM_BASE + (module) + (reg)) diff --git a/arch/arm/mach-omap2/gpmc.c b/arch/arm/mach-omap2/gpmc.c index f51d69b..9b4e58e 100644 --- a/arch/arm/mach-omap2/gpmc.c +++ b/arch/arm/mach-omap2/gpmc.c @@ -64,10 +64,8 @@ static struct resource gpmc_cs_mem[GPMC_CS_NUM]; static DEFINE_SPINLOCK(gpmc_mem_lock); static unsigned gpmc_cs_map; -static void __iomem *gpmc_base = - (void __iomem *) IO_ADDRESS(GPMC_BASE); -static void __iomem *gpmc_cs_base = - (void __iomem *) IO_ADDRESS(GPMC_BASE) + GPMC_CS0; +static void __iomem *gpmc_base = IO_ADDRESS(GPMC_BASE); +static void __iomem *gpmc_cs_base = IO_ADDRESS(GPMC_BASE) + GPMC_CS0; static struct clk *gpmc_fck; diff --git a/arch/arm/mach-omap2/id.c b/arch/arm/mach-omap2/id.c index a5d4526..a5c31e6 100644 --- a/arch/arm/mach-omap2/id.c +++ b/arch/arm/mach-omap2/id.c @@ -15,17 +15,18 @@ #include #include +#include #include #include #include #if defined(CONFIG_ARCH_OMAP2420) -#define TAP_BASE io_p2v(0x48014000) +#define TAP_BASE IO_ADDRESS(0x48014000) #elif defined(CONFIG_ARCH_OMAP2430) -#define TAP_BASE io_p2v(0x4900A000) +#define TAP_BASE IO_ADDRESS(0x4900A000) #elif defined(CONFIG_ARCH_OMAP34XX) -#define TAP_BASE io_p2v(0x4830A000) +#define TAP_BASE IO_ADDRESS(0x4830A000) #endif #define OMAP_TAP_IDCODE 0x0204 diff --git a/arch/arm/mach-omap2/io.c b/arch/arm/mach-omap2/io.c index 987351f..371e540 100644 --- a/arch/arm/mach-omap2/io.c +++ b/arch/arm/mach-omap2/io.c @@ -24,6 +24,13 @@ #include #include +#include + +#include "powerdomains.h" + +#include +#include "clockdomains.h" + extern void omap_sram_init(void); extern int omap2_clk_init(void); extern void omap2_check_revision(void); @@ -101,6 +108,8 @@ void __init omap2_map_common_io(void) void __init omap2_init_common_hw(void) { omap2_mux_init(); + pwrdm_init(powerdomains_omap); + clkdm_init(clockdomains_omap, clkdm_pwrdm_autodeps); omap2_clk_init(); /* * Need to Fix this for 2430 diff --git a/arch/arm/mach-omap2/irq.c b/arch/arm/mach-omap2/irq.c index 9ef15b3..742bd00 100644 --- a/arch/arm/mach-omap2/irq.c +++ b/arch/arm/mach-omap2/irq.c @@ -32,7 +32,7 @@ * for each bank.. when in doubt, consult the TRM. */ static struct omap_irq_bank { - unsigned long base_reg; + void __iomem *base_reg; unsigned int nr_irqs; } __attribute__ ((aligned(4))) irq_banks[] = { { @@ -94,7 +94,7 @@ static void __init omap_irq_bank_init_one(struct omap_irq_bank *bank) unsigned long tmp; tmp = __raw_readl(bank->base_reg + INTC_REVISION) & 0xff; - printk(KERN_INFO "IRQ: Found an INTC at 0x%08lx " + printk(KERN_INFO "IRQ: Found an INTC at 0x%p " "(revision %ld.%ld) with %d interrupts\n", bank->base_reg, tmp >> 4, tmp & 0xf, bank->nr_irqs); diff --git a/arch/arm/mach-omap2/powerdomain.c b/arch/arm/mach-omap2/powerdomain.c new file mode 100644 index 0000000..73e2971 --- /dev/null +++ b/arch/arm/mach-omap2/powerdomain.c @@ -0,0 +1,1113 @@ +/* + * OMAP powerdomain control + * + * Copyright (C) 2007-2008 Texas Instruments, Inc. + * Copyright (C) 2007-2008 Nokia Corporation + * + * Written by Paul Walmsley + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License version 2 as + * published by the Free Software Foundation. + */ +#ifdef CONFIG_OMAP_DEBUG_POWERDOMAIN +# define DEBUG +#endif + +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#include + +#include "cm.h" +#include "cm-regbits-34xx.h" +#include "prm.h" +#include "prm-regbits-34xx.h" + +#include +#include +#include + +/* pwrdm_list contains all registered struct powerdomains */ +static LIST_HEAD(pwrdm_list); + +/* + * pwrdm_rwlock protects pwrdm_list add and del ops - also reused to + * protect pwrdm_clkdms[] during clkdm add/del ops + */ +static DEFINE_RWLOCK(pwrdm_rwlock); + + +/* Private functions */ + +static u32 prm_read_mod_bits_shift(s16 domain, s16 idx, u32 mask) +{ + u32 v; + + v = prm_read_mod_reg(domain, idx); + v &= mask; + v >>= __ffs(mask); + + return v; +} + +static struct powerdomain *_pwrdm_lookup(const char *name) +{ + struct powerdomain *pwrdm, *temp_pwrdm; + + pwrdm = NULL; + + list_for_each_entry(temp_pwrdm, &pwrdm_list, node) { + if (!strcmp(name, temp_pwrdm->name)) { + pwrdm = temp_pwrdm; + break; + } + } + + return pwrdm; +} + +/* _pwrdm_deps_lookup - look up the specified powerdomain in a pwrdm list */ +static struct powerdomain *_pwrdm_deps_lookup(struct powerdomain *pwrdm, + struct pwrdm_dep *deps) +{ + struct pwrdm_dep *pd; + + if (!pwrdm || !deps || !omap_chip_is(pwrdm->omap_chip)) + return ERR_PTR(-EINVAL); + + for (pd = deps; pd; pd++) { + + if (!omap_chip_is(pd->omap_chip)) + continue; + + if (!pd->pwrdm && pd->pwrdm_name) + pd->pwrdm = pwrdm_lookup(pd->pwrdm_name); + + if (pd->pwrdm == pwrdm) + break; + + } + + if (!pd) + return ERR_PTR(-ENOENT); + + return pd->pwrdm; +} + + +/* Public functions */ + +/** + * pwrdm_init - set up the powerdomain layer + * + * Loop through the list of powerdomains, registering all that are + * available on the current CPU. If pwrdm_list is supplied and not + * null, all of the referenced powerdomains will be registered. No + * return value. + */ +void pwrdm_init(struct powerdomain **pwrdm_list) +{ + struct powerdomain **p = NULL; + + if (pwrdm_list) + for (p = pwrdm_list; *p; p++) + pwrdm_register(*p); +} + +/** + * pwrdm_register - register a powerdomain + * @pwrdm: struct powerdomain * to register + * + * Adds a powerdomain to the internal powerdomain list. Returns + * -EINVAL if given a null pointer, -EEXIST if a powerdomain is + * already registered by the provided name, or 0 upon success. + */ +int pwrdm_register(struct powerdomain *pwrdm) +{ + unsigned long flags; + int ret = -EINVAL; + + if (!pwrdm) + return -EINVAL; + + if (!omap_chip_is(pwrdm->omap_chip)) + return -EINVAL; + + write_lock_irqsave(&pwrdm_rwlock, flags); + if (_pwrdm_lookup(pwrdm->name)) { + ret = -EEXIST; + goto pr_unlock; + } + + list_add(&pwrdm->node, &pwrdm_list); + + pr_debug("powerdomain: registered %s\n", pwrdm->name); + ret = 0; + +pr_unlock: + write_unlock_irqrestore(&pwrdm_rwlock, flags); + + return ret; +} + +/** + * pwrdm_unregister - unregister a powerdomain + * @pwrdm: struct powerdomain * to unregister + * + * Removes a powerdomain from the internal powerdomain list. Returns + * -EINVAL if pwrdm argument is NULL. + */ +int pwrdm_unregister(struct powerdomain *pwrdm) +{ + unsigned long flags; + + if (!pwrdm) + return -EINVAL; + + write_lock_irqsave(&pwrdm_rwlock, flags); + list_del(&pwrdm->node); + write_unlock_irqrestore(&pwrdm_rwlock, flags); + + pr_debug("powerdomain: unregistered %s\n", pwrdm->name); + + return 0; +} + +/** + * pwrdm_lookup - look up a powerdomain by name, return a pointer + * @name: name of powerdomain + * + * Find a registered powerdomain by its name. Returns a pointer to the + * struct powerdomain if found, or NULL otherwise. + */ +struct powerdomain *pwrdm_lookup(const char *name) +{ + struct powerdomain *pwrdm; + unsigned long flags; + + if (!name) + return NULL; + + read_lock_irqsave(&pwrdm_rwlock, flags); + pwrdm = _pwrdm_lookup(name); + read_unlock_irqrestore(&pwrdm_rwlock, flags); + + return pwrdm; +} + +/** + * pwrdm_for_each - call function on each registered clockdomain + * @fn: callback function * + * + * Call the supplied function for each registered powerdomain. The + * callback function can return anything but 0 to bail out early from + * the iterator. The callback function is called with the pwrdm_rwlock + * held for reading, so no powerdomain structure manipulation + * functions should be called from the callback, although hardware + * powerdomain control functions are fine. Returns the last return + * value of the callback function, which should be 0 for success or + * anything else to indicate failure; or -EINVAL if the function + * pointer is null. + */ +int pwrdm_for_each(int (*fn)(struct powerdomain *pwrdm)) +{ + struct powerdomain *temp_pwrdm; + unsigned long flags; + int ret = 0; + + if (!fn) + return -EINVAL; + + read_lock_irqsave(&pwrdm_rwlock, flags); + list_for_each_entry(temp_pwrdm, &pwrdm_list, node) { + ret = (*fn)(temp_pwrdm); + if (ret) + break; + } + read_unlock_irqrestore(&pwrdm_rwlock, flags); + + return ret; +} + +/** + * pwrdm_add_clkdm - add a clockdomain to a powerdomain + * @pwrdm: struct powerdomain * to add the clockdomain to + * @clkdm: struct clockdomain * to associate with a powerdomain + * + * Associate the clockdomain 'clkdm' with a powerdomain 'pwrdm'. This + * enables the use of pwrdm_for_each_clkdm(). Returns -EINVAL if + * presented with invalid pointers; -ENOMEM if memory could not be allocated; + * or 0 upon success. + */ +int pwrdm_add_clkdm(struct powerdomain *pwrdm, struct clockdomain *clkdm) +{ + unsigned long flags; + int i; + int ret = -EINVAL; + + if (!pwrdm || !clkdm) + return -EINVAL; + + pr_debug("powerdomain: associating clockdomain %s with powerdomain " + "%s\n", clkdm->name, pwrdm->name); + + write_lock_irqsave(&pwrdm_rwlock, flags); + + for (i = 0; i < PWRDM_MAX_CLKDMS; i++) { + if (!pwrdm->pwrdm_clkdms[i]) + break; +#ifdef DEBUG + if (pwrdm->pwrdm_clkdms[i] == clkdm) { + ret = -EINVAL; + goto pac_exit; + } +#endif + } + + if (i == PWRDM_MAX_CLKDMS) { + pr_debug("powerdomain: increase PWRDM_MAX_CLKDMS for " + "pwrdm %s clkdm %s\n", pwrdm->name, clkdm->name); + WARN_ON(1); + ret = -ENOMEM; + goto pac_exit; + } + + pwrdm->pwrdm_clkdms[i] = clkdm; + + ret = 0; + +pac_exit: + write_unlock_irqrestore(&pwrdm_rwlock, flags); + + return ret; +} + +/** + * pwrdm_del_clkdm - remove a clockdomain from a powerdomain + * @pwrdm: struct powerdomain * to add the clockdomain to + * @clkdm: struct clockdomain * to associate with a powerdomain + * + * Dissociate the clockdomain 'clkdm' from the powerdomain + * 'pwrdm'. Returns -EINVAL if presented with invalid pointers; + * -ENOENT if the clkdm was not associated with the powerdomain, or 0 + * upon success. + */ +int pwrdm_del_clkdm(struct powerdomain *pwrdm, struct clockdomain *clkdm) +{ + unsigned long flags; + int ret = -EINVAL; + int i; + + if (!pwrdm || !clkdm) + return -EINVAL; + + pr_debug("powerdomain: dissociating clockdomain %s from powerdomain " + "%s\n", clkdm->name, pwrdm->name); + + write_lock_irqsave(&pwrdm_rwlock, flags); + + for (i = 0; i < PWRDM_MAX_CLKDMS; i++) + if (pwrdm->pwrdm_clkdms[i] == clkdm) + break; + + if (i == PWRDM_MAX_CLKDMS) { + pr_debug("powerdomain: clkdm %s not associated with pwrdm " + "%s ?!\n", clkdm->name, pwrdm->name); + ret = -ENOENT; + goto pdc_exit; + } + + pwrdm->pwrdm_clkdms[i] = NULL; + + ret = 0; + +pdc_exit: + write_unlock_irqrestore(&pwrdm_rwlock, flags); + + return ret; +} + +/** + * pwrdm_for_each_clkdm - call function on each clkdm in a pwrdm + * @pwrdm: struct powerdomain * to iterate over + * @fn: callback function * + * + * Call the supplied function for each clockdomain in the powerdomain + * 'pwrdm'. The callback function can return anything but 0 to bail + * out early from the iterator. The callback function is called with + * the pwrdm_rwlock held for reading, so no powerdomain structure + * manipulation functions should be called from the callback, although + * hardware powerdomain control functions are fine. Returns -EINVAL + * if presented with invalid pointers; or passes along the last return + * value of the callback function, which should be 0 for success or + * anything else to indicate failure. + */ +int pwrdm_for_each_clkdm(struct powerdomain *pwrdm, + int (*fn)(struct powerdomain *pwrdm, + struct clockdomain *clkdm)) +{ + unsigned long flags; + int ret = 0; + int i; + + if (!fn) + return -EINVAL; + + read_lock_irqsave(&pwrdm_rwlock, flags); + + for (i = 0; i < PWRDM_MAX_CLKDMS && !ret; i++) + ret = (*fn)(pwrdm, pwrdm->pwrdm_clkdms[i]); + + read_unlock_irqrestore(&pwrdm_rwlock, flags); + + return ret; +} + + +/** + * pwrdm_add_wkdep - add a wakeup dependency from pwrdm2 to pwrdm1 + * @pwrdm1: wake this struct powerdomain * up (dependent) + * @pwrdm2: when this struct powerdomain * wakes up (source) + * + * When the powerdomain represented by pwrdm2 wakes up (due to an + * interrupt), wake up pwrdm1. Implemented in hardware on the OMAP, + * this feature is designed to reduce wakeup latency of the dependent + * powerdomain. Returns -EINVAL if presented with invalid powerdomain + * pointers, -ENOENT if pwrdm2 cannot wake up pwrdm1 in hardware, or + * 0 upon success. + */ +int pwrdm_add_wkdep(struct powerdomain *pwrdm1, struct powerdomain *pwrdm2) +{ + struct powerdomain *p; + + if (!pwrdm1) + return -EINVAL; + + p = _pwrdm_deps_lookup(pwrdm2, pwrdm1->wkdep_srcs); + if (IS_ERR(p)) { + pr_debug("powerdomain: hardware cannot set/clear wake up of " + "%s when %s wakes up\n", pwrdm1->name, pwrdm2->name); + return IS_ERR(p); + } + + pr_debug("powerdomain: hardware will wake up %s when %s wakes up\n", + pwrdm1->name, pwrdm2->name); + + prm_set_mod_reg_bits((1 << pwrdm2->dep_bit), + pwrdm1->prcm_offs, PM_WKDEP); + + return 0; +} + +/** + * pwrdm_del_wkdep - remove a wakeup dependency from pwrdm2 to pwrdm1 + * @pwrdm1: wake this struct powerdomain * up (dependent) + * @pwrdm2: when this struct powerdomain * wakes up (source) + * + * Remove a wakeup dependency that causes pwrdm1 to wake up when pwrdm2 + * wakes up. Returns -EINVAL if presented with invalid powerdomain + * pointers, -ENOENT if pwrdm2 cannot wake up pwrdm1 in hardware, or + * 0 upon success. + */ +int pwrdm_del_wkdep(struct powerdomain *pwrdm1, struct powerdomain *pwrdm2) +{ + struct powerdomain *p; + + if (!pwrdm1) + return -EINVAL; + + p = _pwrdm_deps_lookup(pwrdm2, pwrdm1->wkdep_srcs); + if (IS_ERR(p)) { + pr_debug("powerdomain: hardware cannot set/clear wake up of " + "%s when %s wakes up\n", pwrdm1->name, pwrdm2->name); + return IS_ERR(p); + } + + pr_debug("powerdomain: hardware will no longer wake up %s after %s " + "wakes up\n", pwrdm1->name, pwrdm2->name); + + prm_clear_mod_reg_bits((1 << pwrdm2->dep_bit), + pwrdm1->prcm_offs, PM_WKDEP); + + return 0; +} + +/** + * pwrdm_read_wkdep - read wakeup dependency state from pwrdm2 to pwrdm1 + * @pwrdm1: wake this struct powerdomain * up (dependent) + * @pwrdm2: when this struct powerdomain * wakes up (source) + * + * Return 1 if a hardware wakeup dependency exists wherein pwrdm1 will be + * awoken when pwrdm2 wakes up; 0 if dependency is not set; -EINVAL + * if either powerdomain pointer is invalid; or -ENOENT if the hardware + * is incapable. + * + * REVISIT: Currently this function only represents software-controllable + * wakeup dependencies. Wakeup dependencies fixed in hardware are not + * yet handled here. + */ +int pwrdm_read_wkdep(struct powerdomain *pwrdm1, struct powerdomain *pwrdm2) +{ + struct powerdomain *p; + + if (!pwrdm1) + return -EINVAL; + + p = _pwrdm_deps_lookup(pwrdm2, pwrdm1->wkdep_srcs); + if (IS_ERR(p)) { + pr_debug("powerdomain: hardware cannot set/clear wake up of " + "%s when %s wakes up\n", pwrdm1->name, pwrdm2->name); + return IS_ERR(p); + } + + return prm_read_mod_bits_shift(pwrdm1->prcm_offs, PM_WKDEP, + (1 << pwrdm2->dep_bit)); +} + +/** + * pwrdm_add_sleepdep - add a sleep dependency from pwrdm2 to pwrdm1 + * @pwrdm1: prevent this struct powerdomain * from sleeping (dependent) + * @pwrdm2: when this struct powerdomain * is active (source) + * + * Prevent pwrdm1 from automatically going inactive (and then to + * retention or off) if pwrdm2 is still active. Returns -EINVAL if + * presented with invalid powerdomain pointers or called on a machine + * that does not support software-configurable hardware sleep dependencies, + * -ENOENT if the specified dependency cannot be set in hardware, or + * 0 upon success. + */ +int pwrdm_add_sleepdep(struct powerdomain *pwrdm1, struct powerdomain *pwrdm2) +{ + struct powerdomain *p; + + if (!pwrdm1) + return -EINVAL; + + if (!cpu_is_omap34xx()) + return -EINVAL; + + p = _pwrdm_deps_lookup(pwrdm2, pwrdm1->sleepdep_srcs); + if (IS_ERR(p)) { + pr_debug("powerdomain: hardware cannot set/clear sleep " + "dependency affecting %s from %s\n", pwrdm1->name, + pwrdm2->name); + return IS_ERR(p); + } + + pr_debug("powerdomain: will prevent %s from sleeping if %s is active\n", + pwrdm1->name, pwrdm2->name); + + cm_set_mod_reg_bits((1 << pwrdm2->dep_bit), + pwrdm1->prcm_offs, OMAP3430_CM_SLEEPDEP); + + return 0; +} + +/** + * pwrdm_del_sleepdep - remove a sleep dependency from pwrdm2 to pwrdm1 + * @pwrdm1: prevent this struct powerdomain * from sleeping (dependent) + * @pwrdm2: when this struct powerdomain * is active (source) + * + * Allow pwrdm1 to automatically go inactive (and then to retention or + * off), independent of the activity state of pwrdm2. Returns -EINVAL + * if presented with invalid powerdomain pointers or called on a machine + * that does not support software-configurable hardware sleep dependencies, + * -ENOENT if the specified dependency cannot be cleared in hardware, or + * 0 upon success. + */ +int pwrdm_del_sleepdep(struct powerdomain *pwrdm1, struct powerdomain *pwrdm2) +{ + struct powerdomain *p; + + if (!pwrdm1) + return -EINVAL; + + if (!cpu_is_omap34xx()) + return -EINVAL; + + p = _pwrdm_deps_lookup(pwrdm2, pwrdm1->sleepdep_srcs); + if (IS_ERR(p)) { + pr_debug("powerdomain: hardware cannot set/clear sleep " + "dependency affecting %s from %s\n", pwrdm1->name, + pwrdm2->name); + return IS_ERR(p); + } + + pr_debug("powerdomain: will no longer prevent %s from sleeping if " + "%s is active\n", pwrdm1->name, pwrdm2->name); + + cm_clear_mod_reg_bits((1 << pwrdm2->dep_bit), + pwrdm1->prcm_offs, OMAP3430_CM_SLEEPDEP); + + return 0; +} + +/** + * pwrdm_read_sleepdep - read sleep dependency state from pwrdm2 to pwrdm1 + * @pwrdm1: prevent this struct powerdomain * from sleeping (dependent) + * @pwrdm2: when this struct powerdomain * is active (source) + * + * Return 1 if a hardware sleep dependency exists wherein pwrdm1 will + * not be allowed to automatically go inactive if pwrdm2 is active; + * 0 if pwrdm1's automatic power state inactivity transition is independent + * of pwrdm2's; -EINVAL if either powerdomain pointer is invalid or called + * on a machine that does not support software-configurable hardware sleep + * dependencies; or -ENOENT if the hardware is incapable. + * + * REVISIT: Currently this function only represents software-controllable + * sleep dependencies. Sleep dependencies fixed in hardware are not + * yet handled here. + */ +int pwrdm_read_sleepdep(struct powerdomain *pwrdm1, struct powerdomain *pwrdm2) +{ + struct powerdomain *p; + + if (!pwrdm1) + return -EINVAL; + + if (!cpu_is_omap34xx()) + return -EINVAL; + + p = _pwrdm_deps_lookup(pwrdm2, pwrdm1->sleepdep_srcs); + if (IS_ERR(p)) { + pr_debug("powerdomain: hardware cannot set/clear sleep " + "dependency affecting %s from %s\n", pwrdm1->name, + pwrdm2->name); + return IS_ERR(p); + } + + return prm_read_mod_bits_shift(pwrdm1->prcm_offs, OMAP3430_CM_SLEEPDEP, + (1 << pwrdm2->dep_bit)); +} + +/** + * pwrdm_get_mem_bank_count - get number of memory banks in this powerdomain + * @pwrdm: struct powerdomain * + * + * Return the number of controllable memory banks in powerdomain pwrdm, + * starting with 1. Returns -EINVAL if the powerdomain pointer is null. + */ +int pwrdm_get_mem_bank_count(struct powerdomain *pwrdm) +{ + if (!pwrdm) + return -EINVAL; + + return pwrdm->banks; +} + +/** + * pwrdm_set_next_pwrst - set next powerdomain power state + * @pwrdm: struct powerdomain * to set + * @pwrst: one of the PWRDM_POWER_* macros + * + * Set the powerdomain pwrdm's next power state to pwrst. The powerdomain + * may not enter this state immediately if the preconditions for this state + * have not been satisfied. Returns -EINVAL if the powerdomain pointer is + * null or if the power state is invalid for the powerdomin, or returns 0 + * upon success. + */ +int pwrdm_set_next_pwrst(struct powerdomain *pwrdm, u8 pwrst) +{ + if (!pwrdm) + return -EINVAL; + + if (!(pwrdm->pwrsts & (1 << pwrst))) + return -EINVAL; + + pr_debug("powerdomain: setting next powerstate for %s to %0x\n", + pwrdm->name, pwrst); + + prm_rmw_mod_reg_bits(OMAP_POWERSTATE_MASK, + (pwrst << OMAP_POWERSTATE_SHIFT), + pwrdm->prcm_offs, PM_PWSTCTRL); + + return 0; +} + +/** + * pwrdm_read_next_pwrst - get next powerdomain power state + * @pwrdm: struct powerdomain * to get power state + * + * Return the powerdomain pwrdm's next power state. Returns -EINVAL + * if the powerdomain pointer is null or returns the next power state + * upon success. + */ +int pwrdm_read_next_pwrst(struct powerdomain *pwrdm) +{ + if (!pwrdm) + return -EINVAL; + + return prm_read_mod_bits_shift(pwrdm->prcm_offs, PM_PWSTCTRL, + OMAP_POWERSTATE_MASK); +} + +/** + * pwrdm_read_pwrst - get current powerdomain power state + * @pwrdm: struct powerdomain * to get power state + * + * Return the powerdomain pwrdm's current power state. Returns -EINVAL + * if the powerdomain pointer is null or returns the current power state + * upon success. + */ +int pwrdm_read_pwrst(struct powerdomain *pwrdm) +{ + if (!pwrdm) + return -EINVAL; + + return prm_read_mod_bits_shift(pwrdm->prcm_offs, PM_PWSTST, + OMAP_POWERSTATEST_MASK); +} + +/** + * pwrdm_read_prev_pwrst - get previous powerdomain power state + * @pwrdm: struct powerdomain * to get previous power state + * + * Return the powerdomain pwrdm's previous power state. Returns -EINVAL + * if the powerdomain pointer is null or returns the previous power state + * upon success. + */ +int pwrdm_read_prev_pwrst(struct powerdomain *pwrdm) +{ + if (!pwrdm) + return -EINVAL; + + return prm_read_mod_bits_shift(pwrdm->prcm_offs, OMAP3430_PM_PREPWSTST, + OMAP3430_LASTPOWERSTATEENTERED_MASK); +} + +/** + * pwrdm_set_logic_retst - set powerdomain logic power state upon retention + * @pwrdm: struct powerdomain * to set + * @pwrst: one of the PWRDM_POWER_* macros + * + * Set the next power state that the logic portion of the powerdomain + * pwrdm will enter when the powerdomain enters retention. This will + * be either RETENTION or OFF, if supported. Returns -EINVAL if the + * powerdomain pointer is null or the target power state is not not + * supported, or returns 0 upon success. + */ +int pwrdm_set_logic_retst(struct powerdomain *pwrdm, u8 pwrst) +{ + if (!pwrdm) + return -EINVAL; + + if (!(pwrdm->pwrsts_logic_ret & (1 << pwrst))) + return -EINVAL; + + pr_debug("powerdomain: setting next logic powerstate for %s to %0x\n", + pwrdm->name, pwrst); + + /* + * The register bit names below may not correspond to the + * actual names of the bits in each powerdomain's register, + * but the type of value returned is the same for each + * powerdomain. + */ + prm_rmw_mod_reg_bits(OMAP3430_LOGICL1CACHERETSTATE, + (pwrst << __ffs(OMAP3430_LOGICL1CACHERETSTATE)), + pwrdm->prcm_offs, PM_PWSTCTRL); + + return 0; +} + +/** + * pwrdm_set_mem_onst - set memory power state while powerdomain ON + * @pwrdm: struct powerdomain * to set + * @bank: memory bank number to set (0-3) + * @pwrst: one of the PWRDM_POWER_* macros + * + * Set the next power state that memory bank x of the powerdomain + * pwrdm will enter when the powerdomain enters the ON state. Bank + * will be a number from 0 to 3, and represents different types of + * memory, depending on the powerdomain. Returns -EINVAL if the + * powerdomain pointer is null or the target power state is not not + * supported for this memory bank, -EEXIST if the target memory bank + * does not exist or is not controllable, or returns 0 upon success. + */ +int pwrdm_set_mem_onst(struct powerdomain *pwrdm, u8 bank, u8 pwrst) +{ + u32 m; + + if (!pwrdm) + return -EINVAL; + + if (pwrdm->banks < (bank + 1)) + return -EEXIST; + + if (!(pwrdm->pwrsts_mem_on[bank] & (1 << pwrst))) + return -EINVAL; + + pr_debug("powerdomain: setting next memory powerstate for domain %s " + "bank %0x while pwrdm-ON to %0x\n", pwrdm->name, bank, pwrst); + + /* + * The register bit names below may not correspond to the + * actual names of the bits in each powerdomain's register, + * but the type of value returned is the same for each + * powerdomain. + */ + switch (bank) { + case 0: + m = OMAP3430_SHAREDL1CACHEFLATONSTATE_MASK; + break; + case 1: + m = OMAP3430_L1FLATMEMONSTATE_MASK; + break; + case 2: + m = OMAP3430_SHAREDL2CACHEFLATONSTATE_MASK; + break; + case 3: + m = OMAP3430_L2FLATMEMONSTATE_MASK; + break; + default: + WARN_ON(1); /* should never happen */ + return -EEXIST; + } + + prm_rmw_mod_reg_bits(m, (pwrst << __ffs(m)), + pwrdm->prcm_offs, PM_PWSTCTRL); + + return 0; +} + +/** + * pwrdm_set_mem_retst - set memory power state while powerdomain in RET + * @pwrdm: struct powerdomain * to set + * @bank: memory bank number to set (0-3) + * @pwrst: one of the PWRDM_POWER_* macros + * + * Set the next power state that memory bank x of the powerdomain + * pwrdm will enter when the powerdomain enters the RETENTION state. + * Bank will be a number from 0 to 3, and represents different types + * of memory, depending on the powerdomain. pwrst will be either + * RETENTION or OFF, if supported. Returns -EINVAL if the powerdomain + * pointer is null or the target power state is not not supported for + * this memory bank, -EEXIST if the target memory bank does not exist + * or is not controllable, or returns 0 upon success. + */ +int pwrdm_set_mem_retst(struct powerdomain *pwrdm, u8 bank, u8 pwrst) +{ + u32 m; + + if (!pwrdm) + return -EINVAL; + + if (pwrdm->banks < (bank + 1)) + return -EEXIST; + + if (!(pwrdm->pwrsts_mem_ret[bank] & (1 << pwrst))) + return -EINVAL; + + pr_debug("powerdomain: setting next memory powerstate for domain %s " + "bank %0x while pwrdm-RET to %0x\n", pwrdm->name, bank, pwrst); + + /* + * The register bit names below may not correspond to the + * actual names of the bits in each powerdomain's register, + * but the type of value returned is the same for each + * powerdomain. + */ + switch (bank) { + case 0: + m = OMAP3430_SHAREDL1CACHEFLATRETSTATE; + break; + case 1: + m = OMAP3430_L1FLATMEMRETSTATE; + break; + case 2: + m = OMAP3430_SHAREDL2CACHEFLATRETSTATE; + break; + case 3: + m = OMAP3430_L2FLATMEMRETSTATE; + break; + default: + WARN_ON(1); /* should never happen */ + return -EEXIST; + } + + prm_rmw_mod_reg_bits(m, (pwrst << __ffs(m)), pwrdm->prcm_offs, + PM_PWSTCTRL); + + return 0; +} + +/** + * pwrdm_read_logic_pwrst - get current powerdomain logic retention power state + * @pwrdm: struct powerdomain * to get current logic retention power state + * + * Return the current power state that the logic portion of + * powerdomain pwrdm will enter + * Returns -EINVAL if the powerdomain pointer is null or returns the + * current logic retention power state upon success. + */ +int pwrdm_read_logic_pwrst(struct powerdomain *pwrdm) +{ + if (!pwrdm) + return -EINVAL; + + return prm_read_mod_bits_shift(pwrdm->prcm_offs, PM_PWSTST, + OMAP3430_LOGICSTATEST); +} + +/** + * pwrdm_read_prev_logic_pwrst - get previous powerdomain logic power state + * @pwrdm: struct powerdomain * to get previous logic power state + * + * Return the powerdomain pwrdm's logic power state. Returns -EINVAL + * if the powerdomain pointer is null or returns the previous logic + * power state upon success. + */ +int pwrdm_read_prev_logic_pwrst(struct powerdomain *pwrdm) +{ + if (!pwrdm) + return -EINVAL; + + /* + * The register bit names below may not correspond to the + * actual names of the bits in each powerdomain's register, + * but the type of value returned is the same for each + * powerdomain. + */ + return prm_read_mod_bits_shift(pwrdm->prcm_offs, OMAP3430_PM_PREPWSTST, + OMAP3430_LASTLOGICSTATEENTERED); +} + +/** + * pwrdm_read_mem_pwrst - get current memory bank power state + * @pwrdm: struct powerdomain * to get current memory bank power state + * @bank: memory bank number (0-3) + * + * Return the powerdomain pwrdm's current memory power state for bank + * x. Returns -EINVAL if the powerdomain pointer is null, -EEXIST if + * the target memory bank does not exist or is not controllable, or + * returns the current memory power state upon success. + */ +int pwrdm_read_mem_pwrst(struct powerdomain *pwrdm, u8 bank) +{ + u32 m; + + if (!pwrdm) + return -EINVAL; + + if (pwrdm->banks < (bank + 1)) + return -EEXIST; + + /* + * The register bit names below may not correspond to the + * actual names of the bits in each powerdomain's register, + * but the type of value returned is the same for each + * powerdomain. + */ + switch (bank) { + case 0: + m = OMAP3430_SHAREDL1CACHEFLATSTATEST_MASK; + break; + case 1: + m = OMAP3430_L1FLATMEMSTATEST_MASK; + break; + case 2: + m = OMAP3430_SHAREDL2CACHEFLATSTATEST_MASK; + break; + case 3: + m = OMAP3430_L2FLATMEMSTATEST_MASK; + break; + default: + WARN_ON(1); /* should never happen */ + return -EEXIST; + } + + return prm_read_mod_bits_shift(pwrdm->prcm_offs, PM_PWSTST, m); +} + +/** + * pwrdm_read_prev_mem_pwrst - get previous memory bank power state + * @pwrdm: struct powerdomain * to get previous memory bank power state + * @bank: memory bank number (0-3) + * + * Return the powerdomain pwrdm's previous memory power state for bank + * x. Returns -EINVAL if the powerdomain pointer is null, -EEXIST if + * the target memory bank does not exist or is not controllable, or + * returns the previous memory power state upon success. + */ +int pwrdm_read_prev_mem_pwrst(struct powerdomain *pwrdm, u8 bank) +{ + u32 m; + + if (!pwrdm) + return -EINVAL; + + if (pwrdm->banks < (bank + 1)) + return -EEXIST; + + /* + * The register bit names below may not correspond to the + * actual names of the bits in each powerdomain's register, + * but the type of value returned is the same for each + * powerdomain. + */ + switch (bank) { + case 0: + m = OMAP3430_LASTMEM1STATEENTERED_MASK; + break; + case 1: + m = OMAP3430_LASTMEM2STATEENTERED_MASK; + break; + case 2: + m = OMAP3430_LASTSHAREDL2CACHEFLATSTATEENTERED_MASK; + break; + case 3: + m = OMAP3430_LASTL2FLATMEMSTATEENTERED_MASK; + break; + default: + WARN_ON(1); /* should never happen */ + return -EEXIST; + } + + return prm_read_mod_bits_shift(pwrdm->prcm_offs, + OMAP3430_PM_PREPWSTST, m); +} + +/** + * pwrdm_clear_all_prev_pwrst - clear previous powerstate register for a pwrdm + * @pwrdm: struct powerdomain * to clear + * + * Clear the powerdomain's previous power state register. Clears the + * entire register, including logic and memory bank previous power states. + * Returns -EINVAL if the powerdomain pointer is null, or returns 0 upon + * success. + */ +int pwrdm_clear_all_prev_pwrst(struct powerdomain *pwrdm) +{ + if (!pwrdm) + return -EINVAL; + + /* + * XXX should get the powerdomain's current state here; + * warn & fail if it is not ON. + */ + + pr_debug("powerdomain: clearing previous power state reg for %s\n", + pwrdm->name); + + prm_write_mod_reg(0, pwrdm->prcm_offs, OMAP3430_PM_PREPWSTST); + + return 0; +} + +/** + * pwrdm_enable_hdwr_sar - enable automatic hardware SAR for a pwrdm + * @pwrdm: struct powerdomain * + * + * Enable automatic context save-and-restore upon power state change + * for some devices in a powerdomain. Warning: this only affects a + * subset of devices in a powerdomain; check the TRM closely. Returns + * -EINVAL if the powerdomain pointer is null or if the powerdomain + * does not support automatic save-and-restore, or returns 0 upon + * success. + */ +int pwrdm_enable_hdwr_sar(struct powerdomain *pwrdm) +{ + if (!pwrdm) + return -EINVAL; + + if (!(pwrdm->flags & PWRDM_HAS_HDWR_SAR)) + return -EINVAL; + + pr_debug("powerdomain: %s: setting SAVEANDRESTORE bit\n", + pwrdm->name); + + prm_rmw_mod_reg_bits(0, 1 << OMAP3430ES2_SAVEANDRESTORE_SHIFT, + pwrdm->prcm_offs, PM_PWSTCTRL); + + return 0; +} + +/** + * pwrdm_disable_hdwr_sar - disable automatic hardware SAR for a pwrdm + * @pwrdm: struct powerdomain * + * + * Disable automatic context save-and-restore upon power state change + * for some devices in a powerdomain. Warning: this only affects a + * subset of devices in a powerdomain; check the TRM closely. Returns + * -EINVAL if the powerdomain pointer is null or if the powerdomain + * does not support automatic save-and-restore, or returns 0 upon + * success. + */ +int pwrdm_disable_hdwr_sar(struct powerdomain *pwrdm) +{ + if (!pwrdm) + return -EINVAL; + + if (!(pwrdm->flags & PWRDM_HAS_HDWR_SAR)) + return -EINVAL; + + pr_debug("powerdomain: %s: clearing SAVEANDRESTORE bit\n", + pwrdm->name); + + prm_rmw_mod_reg_bits(1 << OMAP3430ES2_SAVEANDRESTORE_SHIFT, 0, + pwrdm->prcm_offs, PM_PWSTCTRL); + + return 0; +} + +/** + * pwrdm_has_hdwr_sar - test whether powerdomain supports hardware SAR + * @pwrdm: struct powerdomain * + * + * Returns 1 if powerdomain 'pwrdm' supports hardware save-and-restore + * for some devices, or 0 if it does not. + */ +bool pwrdm_has_hdwr_sar(struct powerdomain *pwrdm) +{ + return (pwrdm && pwrdm->flags & PWRDM_HAS_HDWR_SAR) ? 1 : 0; +} + +/** + * pwrdm_wait_transition - wait for powerdomain power transition to finish + * @pwrdm: struct powerdomain * to wait for + * + * If the powerdomain pwrdm is in the process of a state transition, + * spin until it completes the power transition, or until an iteration + * bailout value is reached. Returns -EINVAL if the powerdomain + * pointer is null, -EAGAIN if the bailout value was reached, or + * returns 0 upon success. + */ +int pwrdm_wait_transition(struct powerdomain *pwrdm) +{ + u32 c = 0; + + if (!pwrdm) + return -EINVAL; + + /* + * REVISIT: pwrdm_wait_transition() may be better implemented + * via a callback and a periodic timer check -- how long do we expect + * powerdomain transitions to take? + */ + + /* XXX Is this udelay() value meaningful? */ + while ((prm_read_mod_reg(pwrdm->prcm_offs, PM_PWSTST) & + OMAP_INTRANSITION) && + (c++ < PWRDM_TRANSITION_BAILOUT)) + udelay(1); + + if (c >= PWRDM_TRANSITION_BAILOUT) { + printk(KERN_ERR "powerdomain: waited too long for " + "powerdomain %s to complete transition\n", pwrdm->name); + return -EAGAIN; + } + + pr_debug("powerdomain: completed transition in %d loops\n", c); + + return 0; +} + + diff --git a/arch/arm/mach-omap2/powerdomains.h b/arch/arm/mach-omap2/powerdomains.h new file mode 100644 index 0000000..1e151fa --- /dev/null +++ b/arch/arm/mach-omap2/powerdomains.h @@ -0,0 +1,187 @@ +/* + * OMAP2/3 common powerdomain definitions + * + * Copyright (C) 2007-8 Texas Instruments, Inc. + * Copyright (C) 2007-8 Nokia Corporation + * + * Written by Paul Walmsley + * Debugging and integration fixes by Jouni Högander + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License version 2 as + * published by the Free Software Foundation. + */ + +#ifndef ARCH_ARM_MACH_OMAP2_POWERDOMAINS +#define ARCH_ARM_MACH_OMAP2_POWERDOMAINS + +/* + * This file contains all of the powerdomains that have some element + * of software control for the OMAP24xx and OMAP34XX chips. + * + * A few notes: + * + * This is not an exhaustive listing of powerdomains on the chips; only + * powerdomains that can be controlled in software. + * + * A useful validation rule for struct powerdomain: + * Any powerdomain referenced by a wkdep_srcs or sleepdep_srcs array + * must have a dep_bit assigned. So wkdep_srcs/sleepdep_srcs are really + * just software-controllable dependencies. Non-software-controllable + * dependencies do exist, but they are not encoded below (yet). + * + * 24xx does not support programmable sleep dependencies (SLEEPDEP) + * + */ + +/* + * The names for the DSP/IVA2 powerdomains are confusing. + * + * Most OMAP chips have an on-board DSP. + * + * On the 2420, this is a 'C55 DSP called, simply, the DSP. Its + * powerdomain is called the "DSP power domain." On the 2430, the + * on-board DSP is a 'C64 DSP, now called the IVA2 or IVA2.1. Its + * powerdomain is still called the "DSP power domain." On the 3430, + * the DSP is a 'C64 DSP like the 2430, also known as the IVA2; but + * its powerdomain is now called the "IVA2 power domain." + * + * The 2420 also has something called the IVA, which is a separate ARM + * core, and has nothing to do with the DSP/IVA2. + * + * Ideally the DSP/IVA2 could just be the same powerdomain, but the PRCM + * address offset is different between the C55 and C64 DSPs. + * + * The overly-specific dep_bit names are due to a bit name collision + * with CM_FCLKEN_{DSP,IVA2}. The DSP/IVA2 PM_WKDEP and CM_SLEEPDEP shift + * value are the same for all powerdomains: 2 + */ + +/* + * XXX should dep_bit be a mask, so we can test to see if it is 0 as a + * sanity check? + * XXX encode hardware fixed wakeup dependencies -- esp. for 3430 CORE + */ + +#include + +#include "prcm-common.h" +#include "prm.h" +#include "cm.h" + +/* OMAP2/3-common powerdomains and wakeup dependencies */ + +/* + * 2420/2430 PM_WKDEP_GFX: CORE, MPU, WKUP + * 3430ES1 PM_WKDEP_GFX: adds IVA2, removes CORE + * 3430ES2 PM_WKDEP_SGX: adds IVA2, removes CORE + */ +static struct pwrdm_dep gfx_sgx_wkdeps[] = { + { + .pwrdm_name = "core_pwrdm", + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP24XX) + }, + { + .pwrdm_name = "iva2_pwrdm", + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430) + }, + { + .pwrdm_name = "mpu_pwrdm", + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP24XX | + CHIP_IS_OMAP3430) + }, + { + .pwrdm_name = "wkup_pwrdm", + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP24XX | + CHIP_IS_OMAP3430) + }, + { NULL }, +}; + +/* + * 3430: CM_SLEEPDEP_CAM: MPU + * 3430ES1: CM_SLEEPDEP_GFX: MPU + * 3430ES2: CM_SLEEPDEP_SGX: MPU + */ +static struct pwrdm_dep cam_gfx_sleepdeps[] = { + { + .pwrdm_name = "mpu_pwrdm", + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430) + }, + { NULL }, +}; + + +#include "powerdomains24xx.h" +#include "powerdomains34xx.h" + + +/* + * OMAP2/3 common powerdomains + */ + +/* + * The GFX powerdomain is not present on 3430ES2, but currently we do not + * have a macro to filter it out at compile-time. + */ +static struct powerdomain gfx_pwrdm = { + .name = "gfx_pwrdm", + .prcm_offs = GFX_MOD, + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP24XX | + CHIP_IS_OMAP3430ES1), + .wkdep_srcs = gfx_sgx_wkdeps, + .sleepdep_srcs = cam_gfx_sleepdeps, + .pwrsts = PWRSTS_OFF_RET_ON, + .pwrsts_logic_ret = PWRDM_POWER_RET, + .banks = 1, + .pwrsts_mem_ret = { + [0] = PWRDM_POWER_RET, /* MEMRETSTATE */ + }, + .pwrsts_mem_on = { + [0] = PWRDM_POWER_ON, /* MEMONSTATE */ + }, +}; + +static struct powerdomain wkup_pwrdm = { + .name = "wkup_pwrdm", + .prcm_offs = WKUP_MOD, + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP24XX | CHIP_IS_OMAP3430), + .dep_bit = OMAP_EN_WKUP_SHIFT, +}; + + + +/* As powerdomains are added or removed above, this list must also be changed */ +static struct powerdomain *powerdomains_omap[] __initdata = { + + &gfx_pwrdm, + &wkup_pwrdm, + +#ifdef CONFIG_ARCH_OMAP24XX + &dsp_pwrdm, + &mpu_24xx_pwrdm, + &core_24xx_pwrdm, +#endif + +#ifdef CONFIG_ARCH_OMAP2430 + &mdm_pwrdm, +#endif + +#ifdef CONFIG_ARCH_OMAP34XX + &iva2_pwrdm, + &mpu_34xx_pwrdm, + &neon_pwrdm, + &core_34xx_pwrdm, + &cam_pwrdm, + &dss_pwrdm, + &per_pwrdm, + &emu_pwrdm, + &sgx_pwrdm, + &usbhost_pwrdm, +#endif + + NULL +}; + + +#endif diff --git a/arch/arm/mach-omap2/powerdomains24xx.h b/arch/arm/mach-omap2/powerdomains24xx.h new file mode 100644 index 0000000..9f08dc3 --- /dev/null +++ b/arch/arm/mach-omap2/powerdomains24xx.h @@ -0,0 +1,200 @@ +/* + * OMAP24XX powerdomain definitions + * + * Copyright (C) 2007-2008 Texas Instruments, Inc. + * Copyright (C) 2007-2008 Nokia Corporation + * + * Written by Paul Walmsley + * Debugging and integration fixes by Jouni Högander + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License version 2 as + * published by the Free Software Foundation. + */ + +#ifndef ARCH_ARM_MACH_OMAP2_POWERDOMAINS24XX +#define ARCH_ARM_MACH_OMAP2_POWERDOMAINS24XX + +/* + * N.B. If powerdomains are added or removed from this file, update + * the array in mach-omap2/powerdomains.h. + */ + +#include + +#include "prcm-common.h" +#include "prm.h" +#include "prm-regbits-24xx.h" +#include "cm.h" +#include "cm-regbits-24xx.h" + +/* 24XX powerdomains and dependencies */ + +#ifdef CONFIG_ARCH_OMAP24XX + + +/* Wakeup dependency source arrays */ + +/* + * 2420/2430 PM_WKDEP_DSP: CORE, MPU, WKUP + * 2430 PM_WKDEP_MDM: same as above + */ +static struct pwrdm_dep dsp_mdm_24xx_wkdeps[] = { + { + .pwrdm_name = "core_pwrdm", + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP24XX) + }, + { + .pwrdm_name = "mpu_pwrdm", + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP24XX) + }, + { + .pwrdm_name = "wkup_pwrdm", + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP24XX) + }, + { NULL }, +}; + +/* + * 2420 PM_WKDEP_MPU: CORE, DSP, WKUP + * 2430 adds MDM + */ +static struct pwrdm_dep mpu_24xx_wkdeps[] = { + { + .pwrdm_name = "core_pwrdm", + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP24XX) + }, + { + .pwrdm_name = "dsp_pwrdm", + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP24XX) + }, + { + .pwrdm_name = "wkup_pwrdm", + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP24XX) + }, + { + .pwrdm_name = "mdm_pwrdm", + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP2430) + }, + { NULL }, +}; + +/* + * 2420 PM_WKDEP_CORE: DSP, GFX, MPU, WKUP + * 2430 adds MDM + */ +static struct pwrdm_dep core_24xx_wkdeps[] = { + { + .pwrdm_name = "dsp_pwrdm", + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP24XX) + }, + { + .pwrdm_name = "gfx_pwrdm", + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP24XX) + }, + { + .pwrdm_name = "mpu_pwrdm", + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP24XX) + }, + { + .pwrdm_name = "wkup_pwrdm", + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP24XX) + }, + { + .pwrdm_name = "mdm_pwrdm", + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP2430) + }, + { NULL }, +}; + + +/* Powerdomains */ + +static struct powerdomain dsp_pwrdm = { + .name = "dsp_pwrdm", + .prcm_offs = OMAP24XX_DSP_MOD, + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP24XX), + .dep_bit = OMAP24XX_PM_WKDEP_MPU_EN_DSP_SHIFT, + .wkdep_srcs = dsp_mdm_24xx_wkdeps, + .pwrsts = PWRSTS_OFF_RET_ON, + .pwrsts_logic_ret = PWRDM_POWER_RET, + .banks = 1, + .pwrsts_mem_ret = { + [0] = PWRDM_POWER_RET, + }, + .pwrsts_mem_on = { + [0] = PWRDM_POWER_ON, + }, +}; + +static struct powerdomain mpu_24xx_pwrdm = { + .name = "mpu_pwrdm", + .prcm_offs = MPU_MOD, + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP24XX), + .dep_bit = OMAP24XX_EN_MPU_SHIFT, + .wkdep_srcs = mpu_24xx_wkdeps, + .pwrsts = PWRSTS_OFF_RET_ON, + .pwrsts_logic_ret = PWRSTS_OFF_RET, + .banks = 1, + .pwrsts_mem_ret = { + [0] = PWRDM_POWER_RET, + }, + .pwrsts_mem_on = { + [0] = PWRDM_POWER_ON, + }, +}; + +static struct powerdomain core_24xx_pwrdm = { + .name = "core_pwrdm", + .prcm_offs = CORE_MOD, + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP24XX), + .wkdep_srcs = core_24xx_wkdeps, + .pwrsts = PWRSTS_OFF_RET_ON, + .dep_bit = OMAP24XX_EN_CORE_SHIFT, + .banks = 3, + .pwrsts_mem_ret = { + [0] = PWRSTS_OFF_RET, /* MEM1RETSTATE */ + [1] = PWRSTS_OFF_RET, /* MEM2RETSTATE */ + [2] = PWRSTS_OFF_RET, /* MEM3RETSTATE */ + }, + .pwrsts_mem_on = { + [0] = PWRSTS_OFF_RET_ON, /* MEM1ONSTATE */ + [1] = PWRSTS_OFF_RET_ON, /* MEM2ONSTATE */ + [2] = PWRSTS_OFF_RET_ON, /* MEM3ONSTATE */ + }, +}; + +#endif /* CONFIG_ARCH_OMAP24XX */ + + + +/* + * 2430-specific powerdomains + */ + +#ifdef CONFIG_ARCH_OMAP2430 + +/* XXX 2430 KILLDOMAINWKUP bit? No current users apparently */ + +/* Another case of bit name collisions between several registers: EN_MDM */ +static struct powerdomain mdm_pwrdm = { + .name = "mdm_pwrdm", + .prcm_offs = OMAP2430_MDM_MOD, + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP2430), + .dep_bit = OMAP2430_PM_WKDEP_MPU_EN_MDM_SHIFT, + .wkdep_srcs = dsp_mdm_24xx_wkdeps, + .pwrsts = PWRSTS_OFF_RET_ON, + .pwrsts_logic_ret = PWRDM_POWER_RET, + .banks = 1, + .pwrsts_mem_ret = { + [0] = PWRDM_POWER_RET, /* MEMRETSTATE */ + }, + .pwrsts_mem_on = { + [0] = PWRDM_POWER_ON, /* MEMONSTATE */ + }, +}; + +#endif /* CONFIG_ARCH_OMAP2430 */ + + +#endif diff --git a/arch/arm/mach-omap2/powerdomains34xx.h b/arch/arm/mach-omap2/powerdomains34xx.h new file mode 100644 index 0000000..f573f71 --- /dev/null +++ b/arch/arm/mach-omap2/powerdomains34xx.h @@ -0,0 +1,327 @@ +/* + * OMAP34XX powerdomain definitions + * + * Copyright (C) 2007-2008 Texas Instruments, Inc. + * Copyright (C) 2007-2008 Nokia Corporation + * + * Written by Paul Walmsley + * Debugging and integration fixes by Jouni Högander + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License version 2 as + * published by the Free Software Foundation. + */ + +#ifndef ARCH_ARM_MACH_OMAP2_POWERDOMAINS34XX +#define ARCH_ARM_MACH_OMAP2_POWERDOMAINS34XX + +/* + * N.B. If powerdomains are added or removed from this file, update + * the array in mach-omap2/powerdomains.h. + */ + +#include + +#include "prcm-common.h" +#include "prm.h" +#include "prm-regbits-34xx.h" +#include "cm.h" +#include "cm-regbits-34xx.h" + +/* + * 34XX-specific powerdomains, dependencies + */ + +#ifdef CONFIG_ARCH_OMAP34XX + +/* + * 3430: PM_WKDEP_{PER,USBHOST}: CORE, IVA2, MPU, WKUP + * (USBHOST is ES2 only) + */ +static struct pwrdm_dep per_usbhost_wkdeps[] = { + { + .pwrdm_name = "core_pwrdm", + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430) + }, + { + .pwrdm_name = "iva2_pwrdm", + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430) + }, + { + .pwrdm_name = "mpu_pwrdm", + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430) + }, + { + .pwrdm_name = "wkup_pwrdm", + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430) + }, + { NULL }, +}; + +/* + * 3430 PM_WKDEP_MPU: CORE, IVA2, DSS, PER + */ +static struct pwrdm_dep mpu_34xx_wkdeps[] = { + { + .pwrdm_name = "core_pwrdm", + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430) + }, + { + .pwrdm_name = "iva2_pwrdm", + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430) + }, + { + .pwrdm_name = "dss_pwrdm", + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430) + }, + { + .pwrdm_name = "per_pwrdm", + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430) + }, + { NULL }, +}; + +/* + * 3430 PM_WKDEP_IVA2: CORE, MPU, WKUP, DSS, PER + */ +static struct pwrdm_dep iva2_wkdeps[] = { + { + .pwrdm_name = "core_pwrdm", + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430) + }, + { + .pwrdm_name = "mpu_pwrdm", + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430) + }, + { + .pwrdm_name = "wkup_pwrdm", + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430) + }, + { + .pwrdm_name = "dss_pwrdm", + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430) + }, + { + .pwrdm_name = "per_pwrdm", + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430) + }, + { NULL }, +}; + + +/* 3430 PM_WKDEP_{CAM,DSS}: IVA2, MPU, WKUP */ +static struct pwrdm_dep cam_dss_wkdeps[] = { + { + .pwrdm_name = "iva2_pwrdm", + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430) + }, + { + .pwrdm_name = "mpu_pwrdm", + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430) + }, + { + .pwrdm_name = "wkup_pwrdm", + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430) + }, + { NULL }, +}; + +/* 3430: PM_WKDEP_NEON: MPU */ +static struct pwrdm_dep neon_wkdeps[] = { + { + .pwrdm_name = "mpu_pwrdm", + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430) + }, + { NULL }, +}; + + +/* Sleep dependency source arrays for 34xx-specific pwrdms - 34XX only */ + +/* + * 3430: CM_SLEEPDEP_{DSS,PER}: MPU, IVA + * 3430ES2: CM_SLEEPDEP_USBHOST: MPU, IVA + */ +static struct pwrdm_dep dss_per_usbhost_sleepdeps[] = { + { + .pwrdm_name = "mpu_pwrdm", + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430) + }, + { + .pwrdm_name = "iva2_pwrdm", + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430) + }, + { NULL }, +}; + + +/* + * Powerdomains + */ + +static struct powerdomain iva2_pwrdm = { + .name = "iva2_pwrdm", + .prcm_offs = OMAP3430_IVA2_MOD, + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430), + .dep_bit = OMAP3430_PM_WKDEP_MPU_EN_IVA2_SHIFT, + .wkdep_srcs = iva2_wkdeps, + .pwrsts = PWRSTS_OFF_RET_ON, + .pwrsts_logic_ret = PWRSTS_OFF_RET, + .banks = 4, + .pwrsts_mem_ret = { + [0] = PWRSTS_OFF_RET, + [1] = PWRSTS_OFF_RET, + [2] = PWRSTS_OFF_RET, + [3] = PWRSTS_OFF_RET, + }, + .pwrsts_mem_on = { + [0] = PWRDM_POWER_ON, + [1] = PWRDM_POWER_ON, + [2] = PWRSTS_OFF_ON, + [3] = PWRDM_POWER_ON, + }, +}; + +static struct powerdomain mpu_34xx_pwrdm = { + .name = "mpu_pwrdm", + .prcm_offs = MPU_MOD, + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430), + .dep_bit = OMAP3430_EN_MPU_SHIFT, + .wkdep_srcs = mpu_34xx_wkdeps, + .pwrsts = PWRSTS_OFF_RET_ON, + .pwrsts_logic_ret = PWRSTS_OFF_RET, + .banks = 1, + .pwrsts_mem_ret = { + [0] = PWRSTS_OFF_RET, + }, + .pwrsts_mem_on = { + [0] = PWRSTS_OFF_ON, + }, +}; + +/* No wkdeps or sleepdeps for 34xx core apparently */ +static struct powerdomain core_34xx_pwrdm = { + .name = "core_pwrdm", + .prcm_offs = CORE_MOD, + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430), + .pwrsts = PWRSTS_OFF_RET_ON, + .dep_bit = OMAP3430_EN_CORE_SHIFT, + .banks = 2, + .pwrsts_mem_ret = { + [0] = PWRSTS_OFF_RET, /* MEM1RETSTATE */ + [1] = PWRSTS_OFF_RET, /* MEM2RETSTATE */ + }, + .pwrsts_mem_on = { + [0] = PWRSTS_OFF_RET_ON, /* MEM1ONSTATE */ + [1] = PWRSTS_OFF_RET_ON, /* MEM2ONSTATE */ + }, +}; + +/* Another case of bit name collisions between several registers: EN_DSS */ +static struct powerdomain dss_pwrdm = { + .name = "dss_pwrdm", + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430), + .prcm_offs = OMAP3430_DSS_MOD, + .dep_bit = OMAP3430_PM_WKDEP_MPU_EN_DSS_SHIFT, + .wkdep_srcs = cam_dss_wkdeps, + .sleepdep_srcs = dss_per_usbhost_sleepdeps, + .pwrsts = PWRSTS_OFF_RET_ON, + .pwrsts_logic_ret = PWRDM_POWER_RET, + .banks = 1, + .pwrsts_mem_ret = { + [0] = PWRDM_POWER_RET, /* MEMRETSTATE */ + }, + .pwrsts_mem_on = { + [0] = PWRDM_POWER_ON, /* MEMONSTATE */ + }, +}; + +static struct powerdomain sgx_pwrdm = { + .name = "sgx_pwrdm", + .prcm_offs = OMAP3430ES2_SGX_MOD, + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430ES2), + .wkdep_srcs = gfx_sgx_wkdeps, + .sleepdep_srcs = cam_gfx_sleepdeps, + /* XXX This is accurate for 3430 SGX, but what about GFX? */ + .pwrsts = PWRSTS_OFF_RET_ON, + .pwrsts_logic_ret = PWRDM_POWER_RET, + .banks = 1, + .pwrsts_mem_ret = { + [0] = PWRDM_POWER_RET, /* MEMRETSTATE */ + }, + .pwrsts_mem_on = { + [0] = PWRDM_POWER_ON, /* MEMONSTATE */ + }, +}; + +static struct powerdomain cam_pwrdm = { + .name = "cam_pwrdm", + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430), + .prcm_offs = OMAP3430_CAM_MOD, + .wkdep_srcs = cam_dss_wkdeps, + .sleepdep_srcs = cam_gfx_sleepdeps, + .pwrsts = PWRSTS_OFF_RET_ON, + .pwrsts_logic_ret = PWRDM_POWER_RET, + .banks = 1, + .pwrsts_mem_ret = { + [0] = PWRDM_POWER_RET, /* MEMRETSTATE */ + }, + .pwrsts_mem_on = { + [0] = PWRDM_POWER_ON, /* MEMONSTATE */ + }, +}; + +static struct powerdomain per_pwrdm = { + .name = "per_pwrdm", + .prcm_offs = OMAP3430_PER_MOD, + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430), + .dep_bit = OMAP3430_EN_PER_SHIFT, + .wkdep_srcs = per_usbhost_wkdeps, + .sleepdep_srcs = dss_per_usbhost_sleepdeps, + .pwrsts = PWRSTS_OFF_RET_ON, + .pwrsts_logic_ret = PWRSTS_OFF_RET, + .banks = 1, + .pwrsts_mem_ret = { + [0] = PWRDM_POWER_RET, /* MEMRETSTATE */ + }, + .pwrsts_mem_on = { + [0] = PWRDM_POWER_ON, /* MEMONSTATE */ + }, +}; + +static struct powerdomain emu_pwrdm = { + .name = "emu_pwrdm", + .prcm_offs = OMAP3430_EMU_MOD, + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430), +}; + +static struct powerdomain neon_pwrdm = { + .name = "neon_pwrdm", + .prcm_offs = OMAP3430_NEON_MOD, + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430), + .wkdep_srcs = neon_wkdeps, + .pwrsts = PWRSTS_OFF_RET_ON, + .pwrsts_logic_ret = PWRDM_POWER_RET, +}; + +static struct powerdomain usbhost_pwrdm = { + .name = "usbhost_pwrdm", + .prcm_offs = OMAP3430ES2_USBHOST_MOD, + .omap_chip = OMAP_CHIP_INIT(CHIP_IS_OMAP3430ES2), + .wkdep_srcs = per_usbhost_wkdeps, + .sleepdep_srcs = dss_per_usbhost_sleepdeps, + .pwrsts = PWRSTS_OFF_RET_ON, + .pwrsts_logic_ret = PWRDM_POWER_RET, + .banks = 1, + .pwrsts_mem_ret = { + [0] = PWRDM_POWER_RET, /* MEMRETSTATE */ + }, + .pwrsts_mem_on = { + [0] = PWRDM_POWER_ON, /* MEMONSTATE */ + }, +}; + +#endif /* CONFIG_ARCH_OMAP34XX */ + + +#endif diff --git a/arch/arm/mach-omap2/prcm-common.h b/arch/arm/mach-omap2/prcm-common.h index 54c32f4..4a32822 100644 --- a/arch/arm/mach-omap2/prcm-common.h +++ b/arch/arm/mach-omap2/prcm-common.h @@ -312,7 +312,8 @@ #define OMAP3430_ST_GPT2 (1 << 3) /* CM_SLEEPDEP_PER, PM_WKDEP_IVA2, PM_WKDEP_MPU, PM_WKDEP_PER shared bits */ -#define OMAP3430_EN_CORE (1 << 0) +#define OMAP3430_EN_CORE_SHIFT 0 +#define OMAP3430_EN_CORE_MASK (1 << 0) #endif diff --git a/arch/arm/mach-omap2/prm-regbits-24xx.h b/arch/arm/mach-omap2/prm-regbits-24xx.h index c6d17a3..4002051 100644 --- a/arch/arm/mach-omap2/prm-regbits-24xx.h +++ b/arch/arm/mach-omap2/prm-regbits-24xx.h @@ -29,8 +29,10 @@ #define OMAP24XX_WKUP1_EN (1 << 0) /* PM_WKDEP_GFX, PM_WKDEP_MPU, PM_WKDEP_DSP, PM_WKDEP_MDM shared bits */ -#define OMAP24XX_EN_MPU (1 << 1) -#define OMAP24XX_EN_CORE (1 << 0) +#define OMAP24XX_EN_MPU_SHIFT 1 +#define OMAP24XX_EN_MPU_MASK (1 << 1) +#define OMAP24XX_EN_CORE_SHIFT 0 +#define OMAP24XX_EN_CORE_MASK (1 << 0) /* * PM_PWSTCTRL_MPU, PM_PWSTCTRL_GFX, PM_PWSTCTRL_DSP, PM_PWSTCTRL_MDM @@ -140,8 +142,10 @@ /* 2430 calls GLOBALWMPU_RST "GLOBALWARM_RST" instead */ /* PM_WKDEP_MPU specific bits */ -#define OMAP2430_PM_WKDEP_MPU_EN_MDM (1 << 5) -#define OMAP24XX_PM_WKDEP_MPU_EN_DSP (1 << 2) +#define OMAP2430_PM_WKDEP_MPU_EN_MDM_SHIFT 5 +#define OMAP2430_PM_WKDEP_MPU_EN_MDM_MASK (1 << 5) +#define OMAP24XX_PM_WKDEP_MPU_EN_DSP_SHIFT 2 +#define OMAP24XX_PM_WKDEP_MPU_EN_DSP_MASK (1 << 2) /* PM_EVGENCTRL_MPU specific bits */ diff --git a/arch/arm/mach-omap2/prm-regbits-34xx.h b/arch/arm/mach-omap2/prm-regbits-34xx.h index b4686bc..5b5ecfe 100644 --- a/arch/arm/mach-omap2/prm-regbits-34xx.h +++ b/arch/arm/mach-omap2/prm-regbits-34xx.h @@ -68,7 +68,8 @@ #define OMAP3430_VPINIDLE (1 << 0) /* PM_WKDEP_IVA2, PM_WKDEP_MPU shared bits */ -#define OMAP3430_EN_PER (1 << 7) +#define OMAP3430_EN_PER_SHIFT 7 +#define OMAP3430_EN_PER_MASK (1 << 7) /* PM_PWSTCTRL_IVA2, PM_PWSTCTRL_MPU, PM_PWSTCTRL_CORE shared bits */ #define OMAP3430_MEMORYCHANGE (1 << 3) @@ -77,7 +78,7 @@ #define OMAP3430_LOGICSTATEST (1 << 2) /* PM_PREPWSTST_IVA2, PM_PREPWSTST_CORE shared bits */ -#define OMAP3430_LASTLOGICSTATEENTERED (1 << 2) +#define OMAP3430_LASTLOGICSTATEENTERED (1 << 2) /* * PM_PREPWSTST_IVA2, PM_PREPWSTST_MPU, PM_PREPWSTST_CORE, @@ -278,8 +279,10 @@ #define OMAP3430_EMULATION_MPU_RST (1 << 11) /* PM_WKDEP_MPU specific bits */ -#define OMAP3430_PM_WKDEP_MPU_EN_DSS (1 << 5) -#define OMAP3430_PM_WKDEP_MPU_EN_IVA2 (1 << 2) +#define OMAP3430_PM_WKDEP_MPU_EN_DSS_SHIFT 5 +#define OMAP3430_PM_WKDEP_MPU_EN_DSS_MASK (1 << 5) +#define OMAP3430_PM_WKDEP_MPU_EN_IVA2_SHIFT 2 +#define OMAP3430_PM_WKDEP_MPU_EN_IVA2_MASK (1 << 2) /* PM_EVGENCTRL_MPU */ #define OMAP3430_OFFLOADMODE_SHIFT 3 diff --git a/arch/arm/mach-omap2/prm.h b/arch/arm/mach-omap2/prm.h index bbf41fc..e4dc4b1 100644 --- a/arch/arm/mach-omap2/prm.h +++ b/arch/arm/mach-omap2/prm.h @@ -18,7 +18,7 @@ #ifndef __ASSEMBLER__ #define OMAP_PRM_REGADDR(module, reg) \ - (void __iomem *)IO_ADDRESS(OMAP2_PRM_BASE + (module) + (reg)) + IO_ADDRESS(OMAP2_PRM_BASE + (module) + (reg)) #else #define OMAP2420_PRM_REGADDR(module, reg) \ IO_ADDRESS(OMAP2420_PRM_BASE + (module) + (reg)) @@ -305,7 +305,8 @@ static inline u32 prm_clear_mod_reg_bits(u32 bits, s16 module, s16 idx) * 3430: PM_WKDEP_IVA2, PM_WKDEP_GFX, PM_WKDEP_DSS, PM_WKDEP_CAM, * PM_WKDEP_PER */ -#define OMAP_EN_WKUP (1 << 4) +#define OMAP_EN_WKUP_SHIFT 4 +#define OMAP_EN_WKUP_MASK (1 << 4) /* * 24XX: PM_PWSTCTRL_MPU, PM_PWSTCTRL_CORE, PM_PWSTCTRL_GFX, diff --git a/arch/arm/mach-omap2/serial.c b/arch/arm/mach-omap2/serial.c index adc8a26..7faa53c 100644 --- a/arch/arm/mach-omap2/serial.c +++ b/arch/arm/mach-omap2/serial.c @@ -32,24 +32,24 @@ static struct clk * uart3_fck = NULL; static struct plat_serial8250_port serial_platform_data[] = { { - .membase = (char *)IO_ADDRESS(OMAP_UART1_BASE), - .mapbase = (unsigned long)OMAP_UART1_BASE, + .membase = IO_ADDRESS(OMAP_UART1_BASE), + .mapbase = OMAP_UART1_BASE, .irq = 72, .flags = UPF_BOOT_AUTOCONF, .iotype = UPIO_MEM, .regshift = 2, .uartclk = OMAP16XX_BASE_BAUD * 16, }, { - .membase = (char *)IO_ADDRESS(OMAP_UART2_BASE), - .mapbase = (unsigned long)OMAP_UART2_BASE, + .membase = IO_ADDRESS(OMAP_UART2_BASE), + .mapbase = OMAP_UART2_BASE, .irq = 73, .flags = UPF_BOOT_AUTOCONF, .iotype = UPIO_MEM, .regshift = 2, .uartclk = OMAP16XX_BASE_BAUD * 16, }, { - .membase = (char *)IO_ADDRESS(OMAP_UART3_BASE), - .mapbase = (unsigned long)OMAP_UART3_BASE, + .membase = IO_ADDRESS(OMAP_UART3_BASE), + .mapbase = OMAP_UART3_BASE, .irq = 74, .flags = UPF_BOOT_AUTOCONF, .iotype = UPIO_MEM, @@ -71,7 +71,7 @@ static inline void serial_write_reg(struct plat_serial8250_port *p, int offset, int value) { offset <<= p->regshift; - __raw_writeb(value, (unsigned long)(p->membase + offset)); + __raw_writeb(value, p->membase + offset); } /* diff --git a/arch/arm/mach-pxa/Kconfig b/arch/arm/mach-pxa/Kconfig index e8ee7ec..ddb3ca4 100644 --- a/arch/arm/mach-pxa/Kconfig +++ b/arch/arm/mach-pxa/Kconfig @@ -38,16 +38,19 @@ config ARCH_LUBBOCK bool "Intel DBPXA250 Development Platform" select PXA25x select SA1111 + select PXA_HAVE_BOARD_IRQS config MACH_LOGICPD_PXA270 bool "LogicPD PXA270 Card Engine Development Platform" select PXA27x select HAVE_PWM + select PXA_HAVE_BOARD_IRQS config MACH_MAINSTONE bool "Intel HCDDBBVA0 Development Platform" select PXA27x select HAVE_PWM + select PXA_HAVE_BOARD_IRQS config ARCH_PXA_IDP bool "Accelent Xscale IDP" @@ -114,10 +117,12 @@ config MACH_TOSA bool "Enable Sharp SL-6000x (Tosa) Support" depends on PXA_SHARPSL select PXA25x + select PXA_HAVE_BOARD_IRQS config ARCH_PXA_ESERIES bool "PXA based Toshiba e-series PDAs" select PXA25x + select PXA_HAVE_BOARD_IRQS config MACH_E330 bool "Toshiba e330" @@ -170,13 +175,41 @@ config MACH_E800 Say Y here if you intend to run this kernel on a Toshiba e800 family PDA. +config TRIZEPS_PXA + bool "PXA based Keith und Koep Trizeps DIMM-Modules" + config MACH_TRIZEPS4 bool "Keith und Koep Trizeps4 DIMM-Module" + depends on TRIZEPS_PXA + select TRIZEPS_PCMCIA + select PXA27x + +config MACH_TRIZEPS4WL + bool "Keith und Koep Trizeps4-WL DIMM-Module" + depends on TRIZEPS_PXA + select TRIZEPS_PCMCIA select PXA27x + select PXA_SSP -config MACH_TRIZEPS4_CONXS +choice + prompt "Select base board for Trizeps module" + depends on TRIZEPS_PXA + +config MACH_TRIZEPS_CONXS bool "ConXS Eval Board" - depends on MACH_TRIZEPS4 + +config MACH_TRIZEPS_UCONXS + bool "uConXS Eval Board" + +config MACH_TRIZEPS_ANY + bool "another Board" + +endchoice + +config TRIZEPS_PCMCIA + bool + help + Enable PCMCIA support for Trizeps modules config MACH_EM_X270 bool "CompuLab EM-x270 platform" @@ -189,6 +222,7 @@ config MACH_COLIBRI config MACH_ZYLONITE bool "PXA3xx Development Platform (aka Zylonite)" select PXA3xx + select PXA_SSP select HAVE_PWM config MACH_LITTLETON @@ -211,16 +245,35 @@ config MACH_ARMCORE select PXA27x select IWMMXT +config MACH_CM_X300 + bool "CompuLab CM-X300 modules" + select PXA3xx + select CPU_PXA300 + config MACH_MAGICIAN bool "Enable HTC Magician Support" select PXA27x select IWMMXT + select PXA_HAVE_BOARD_IRQS + +config MACH_MIOA701 + bool "Mitac Mio A701 Support" + select PXA27x + select IWMMXT + select LEDS_GPIO + select HAVE_PWM + select GPIO_SYSFS + help + Say Y here if you intend to run this kernel on a + MIO A701. Currently there is only basic support + for this PDA. config MACH_PCM027 bool "Phytec phyCORE-PXA270 CPU module (PCM-027)" select PXA27x select IWMMXT select PXA_SSP + select PXA_HAVE_BOARD_IRQS config ARCH_PXA_PALM bool "PXA based Palm PDAs" @@ -236,6 +289,16 @@ config MACH_PALMTX Say Y here if you intend to run this kernel on a Palm T|X handheld computer. +config MACH_PALMZ72 + bool "Palm Zire 72" + default y + depends on ARCH_PXA_PALM + select PXA27x + select IWMMXT + help + Say Y here if you intend to run this kernel on Palm Zire 72 + handheld computer. + config MACH_PCM990_BASEBOARD bool "PHYTEC PCM-990 development board" select HAVE_PWM @@ -256,6 +319,9 @@ config PCM990_DISPLAY_NONE endchoice +config MACH_AM200EPD + depends on MACH_GUMSTIX_F + bool "Enable AM200EPD board support" config PXA_EZX bool "Motorola EZX Platform" @@ -343,4 +409,7 @@ config TOSA_BT This is a simple driver that is able to control the state of built in bluetooth chip on tosa. +config PXA_HAVE_BOARD_IRQS + bool + endif diff --git a/arch/arm/mach-pxa/Makefile b/arch/arm/mach-pxa/Makefile index 99ecbe7..7dfdd1b 100644 --- a/arch/arm/mach-pxa/Makefile +++ b/arch/arm/mach-pxa/Makefile @@ -22,6 +22,7 @@ obj-$(CONFIG_CPU_PXA930) += pxa930.o # Specific board support obj-$(CONFIG_ARCH_GUMSTIX) += gumstix.o +obj-$(CONFIG_MACH_AM200EPD) += am200epd.o obj-$(CONFIG_ARCH_LUBBOCK) += lubbock.o obj-$(CONFIG_MACH_LOGICPD_PXA270) += lpd270.o obj-$(CONFIG_MACH_MAINSTONE) += mainstone.o @@ -37,12 +38,16 @@ obj-$(CONFIG_MACH_PCM990_BASEBOARD) += pcm990-baseboard.o obj-$(CONFIG_MACH_TOSA) += tosa.o obj-$(CONFIG_MACH_EM_X270) += em-x270.o obj-$(CONFIG_MACH_MAGICIAN) += magician.o -obj-$(CONFIG_ARCH_PXA_ESERIES) += eseries.o eseries_udc.o -obj-$(CONFIG_MACH_E740) += e740_lcd.o -obj-$(CONFIG_MACH_E750) += e750_lcd.o -obj-$(CONFIG_MACH_E400) += e400_lcd.o -obj-$(CONFIG_MACH_E800) += e800_lcd.o +obj-$(CONFIG_MACH_MIOA701) += mioa701.o mioa701_bootresume.o +obj-$(CONFIG_ARCH_PXA_ESERIES) += eseries.o +obj-$(CONFIG_MACH_E330) += e330.o +obj-$(CONFIG_MACH_E350) += e350.o +obj-$(CONFIG_MACH_E740) += e740.o +obj-$(CONFIG_MACH_E750) += e750.o +obj-$(CONFIG_MACH_E400) += e400.o +obj-$(CONFIG_MACH_E800) += e800.o obj-$(CONFIG_MACH_PALMTX) += palmtx.o +obj-$(CONFIG_MACH_PALMZ72) += palmz72.o ifeq ($(CONFIG_MACH_ZYLONITE),y) obj-y += zylonite.o @@ -54,6 +59,7 @@ obj-$(CONFIG_MACH_TAVOREVB) += tavorevb.o obj-$(CONFIG_MACH_SAAR) += saar.o obj-$(CONFIG_MACH_ARMCORE) += cm-x270.o +obj-$(CONFIG_MACH_CM_X300) += cm-x300.o obj-$(CONFIG_PXA_EZX) += ezx.o # Support for blinky lights diff --git a/arch/arm/mach-pxa/am200epd.c b/arch/arm/mach-pxa/am200epd.c new file mode 100644 index 0000000..b965085 --- /dev/null +++ b/arch/arm/mach-pxa/am200epd.c @@ -0,0 +1,374 @@ +/* + * am200epd.c -- Platform device for AM200 EPD kit + * + * Copyright (C) 2008, Jaya Kumar + * + * This file is subject to the terms and conditions of the GNU General Public + * License. See the file COPYING in the main directory of this archive for + * more details. + * + * Layout is based on skeletonfb.c by James Simmons and Geert Uytterhoeven. + * + * This work was made possible by help and equipment support from E-Ink + * Corporation. http://support.eink.com/community + * + * This driver is written to be used with the Metronome display controller. + * on the AM200 EPD prototype kit/development kit with an E-Ink 800x600 + * Vizplex EPD on a Gumstix board using the Lyre interface board. + * + */ + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#include + +#include