summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2012-02-08staging: pohmelfs: remove drivers/staging/pohmelfsstaging-3.3-rc3Evgeniy Polyakov
New pohmelfs is coming, and it is time to remove deadly old design https://lkml.org/lkml/2012/2/8/293 Signed-off-by: Evgeniy Polyakov <zbr@ioremap.net> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-08staging: android/ram_console: Don't build on arches w/o ioremapAnton Vorontsov
This patch fixes UML build: CC drivers/staging/android/ram_console.o drivers/staging/android/ram_console.c: In function 'ram_console_driver_probe': drivers/staging/android/ram_console.c:358:2: error: implicit declaration of function 'ioremap' [-Werror=implicit-function-declaration] cc1: some warnings being treated as errors make[3]: *** [drivers/staging/android/ram_console.o] Error 1 Signed-off-by: Anton Vorontsov <anton.vorontsov@linaro.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-08staging: r8712u: Use asynchronous firmware loadingLarry Finger
In https://bugs.archlinux.org/task/27996, failure of driver r8712u is reported, with a timeout during module loading due to synchronous loading of the firmware. The code now uses request_firmware_nowait(). Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Cc: stable <stable@vger.kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-08staging: usbip: fix to prevent potentially using uninitialized spinlockBart Westgeest
The stub_probe function can be called as soon as the stub_driver is registered. This can lead to the busid_table_lock being used before it is initialized. Moved calling the init_busid_table function (which initalizes this spinlock) to be called earlier in the init function to prevent this from happening. Signed-off-by: Bart Westgeest <bart@elbrys.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-08staging: r8712u: Fix problem when CONFIG_R8712_AP is setLarry Finger
When this driver was upgraded to the vendor 20100831 version in commit 93c55dda092c7 et al,, one listhead initialization was missed. This broke complete operation of the driver whenever AP mode was enabled. This patch fixes https://bugs.archlinux.org/task/27996. Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Cc: Stable <stable@vger.stable.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-08staging: tidspbridge: fix incorrect free to drv_datapOmar Ramirez Luna
This structure is still used after it has been freed, since it is being allocated in probe, calls to free it have been moved to module's remove routine. This should fix the follwoing messages when attempting to remove the module: drv_get_first_dev_extension: Failed to retrieve the object handle drv_get_first_dev_extension: Failed to retrieve the object handle drv_destroy: Failed to store DRV object mgr_destroy: Failed to store MGR object Signed-off-by: Omar Ramirez Luna <omar.ramirez@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-08staging: tidspbridge: fix bridge_open memory leaksOmar Ramirez Luna
There are two members of pr_ctxt allocated during bridge_open that are never freed resulting in memory leaks, these are stream_id and node_id, they are now freed on release of the handle (bridge_release) right before freeing pr_ctxt. Error path for bridge_open was also fixed since the same variables could result in memory leaking due to missing handling of failure scenarios. While at it, the indentation changes were introduced to avoid interleaved goto statements inside big if blocks. Signed-off-by: Omar Ramirez Luna <omar.ramirez@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-08staging: android: lowmemorykiller: Don't wait more than one second for a ↵Arve Hjønnevåg
process to die If a process forked and the child process was killed by the lowmemorykiller, the lowmemory killer would be disabled until the parent process reaped the child or it died itself. Signed-off-by: Arve Hjønnevåg <arve@android.com> Signed-off-by: Anton Vorontsov <anton.vorontsov@linaro.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-08MAINTAINERS: staging: iio: add iio informationAmeya Palande
Signed-off-by: Ameya Palande <ameya.palande@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-08staging: zcache: fix serialization bug in zv statsSeth Jennings
In a multithreaded workload, the zv_curr_dist_counts and zv_cumul_dist_counts statistics are being corrupted because the increments and decrements in zv_create and zv_free are not atomic. This patch converts these statistics and their corresponding increments/decrements/reads to atomic operations. Signed-off-by: Seth Jennings <sjenning@linux.vnet.ibm.com> Acked-by: Dan Magenheimer <dan.magenheimer@oracle.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-08staging: fix go7007-usb licenseRandy Dunlap
Add MODULE_LICENSE() for this source module to fix build warning: WARNING: modpost: missing MODULE_LICENSE() in drivers/staging/media/go7007/go7007-usb.o see include/linux/module.h for more information Signed-off-by: Randy Dunlap <rdunlap@xenotime.net> Cc: Ross Cohen <rcohen@snurgle.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-08Staging: android: binder: Fix crashes when sharing a binder file between ↵Arve Hjønnevåg
processes Opening the binder driver and sharing the file returned with other processes (e.g. by calling fork) can crash the kernel. Prevent these crashes with the following changes: - Add a mutex to protect against two processes mmapping the same binder_proc. - After locking mmap_sem, check that the vma we want to access (still) points to the same mm_struct. - Use proc->tsk instead of current to get the files struct since this is where we get the rlimit from. Signed-off-by: Arve Hjønnevåg <arve@android.com> Cc: stable <stable@vger.kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-08Staging: android: Remove pmem driverShuah Khan
Addroid pmem driver is no longer used in any of the Android products. This patch removes pmem driver from Android staging area Reference: https://lkml.org/lkml/2012/1/23/183 Signed-off-by: Shuah Khan <shuahkhan@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2012-02-08Staging: asus_oled: fix NULL-ptr crash on unloadingPekka Paalanen
Asus_oled triggers the following bug on module unloading: usbcore: deregistering interface driver asus-oled BUG: unable to handle kernel NULL pointer dereference at 0000000000000038 IP: [<ffffffff8111292b>] sysfs_delete_link+0x30/0x66 Call Trace: [<ffffffff81225373>] device_remove_class_symlinks+0x6b/0x70 [<ffffffff812256a8>] device_del+0x9f/0x1ab [<ffffffff812257c5>] device_unregister+0x11/0x1e [<ffffffffa000cb82>] asus_oled_disconnect+0x4f/0x9e [asus_oled] [<ffffffff81277430>] usb_unbind_interface+0x54/0x103 [<ffffffff812276c4>] __device_release_driver+0xa2/0xeb [<ffffffff81227794>] driver_detach+0x87/0xad [<ffffffff812269e9>] bus_remove_driver+0x91/0xc1 [<ffffffff81227fb4>] driver_unregister+0x66/0x6e [<ffffffff812771ed>] usb_deregister+0xbb/0xc4 [<ffffffffa000ce87>] asus_oled_exit+0x2f/0x31 [asus_oled] [<ffffffff81068365>] sys_delete_module+0x1b8/0x21b [<ffffffff810ae3de>] ? do_munmap+0x2ef/0x313 [<ffffffff813699bb>] system_call_fastpath+0x16/0x1b This is due to an incorrect destruction sequence in asus_oled_exit(). Fix the order, fixes the bug. Tested on an Asus G50V laptop only. Cc: Jakub Schmidtke <sjakub@gmail.com> Signed-off-by: Pekka Paalanen <pq@iki.fi> Cc: stable <stable@vger.kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2012-02-08Staging: asus_oled: fix image processingPekka Paalanen
Programming an image was broken, because odev->buf_offs was not advanced for val == 0 in append_values(). This regression was introduced in: commit 1ff12a4aa354bed093a0240d5e6347b1e27601bc Author: Kevin A. Granade <kevin.granade@gmail.com> Date: Sat Sep 5 01:03:39 2009 -0500 Staging: asus_oled: Cleaned up checkpatch issues. Fix the image processing by special-casing val == 0. I have tested this change on an Asus G50V laptop only. Cc: Jakub Schmidtke <sjakub@gmail.com> Cc: Kevin A. Granade <kevin.granade@gmail.com> Signed-off-by: Pekka Paalanen <pq@iki.fi> Cc: stable <stable@vger.kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2012-02-08Staging: android: binder: Don't call dump_stack in binder_vma_openArve Hjønnevåg
If user-space partially unmaps the driver, binder_vma_open would dump the kernel stack. This is not a kernel bug however and will be treated as if the whole area was unmapped once binder_vma_close gets called. Signed-off-by: Arve Hjønnevåg <arve@android.com> Cc: stable <stable@vger.kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2012-02-08staging: r8712u: Add new Sitecom UsB IDLarry Finger
Add USB ID for SITECOM WLA-1000 V1 001 WLAN Reported-and-tested-by: Roland Gruber <post@rolandgruber.de> Reported-and-tested-by: Dario Lucia <dario.lucia@gmail.com> Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Cc: Stable <stable@vger.kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2012-02-08zcache: Set SWIZ_BITS to 8 to reduce tmem bucket lock contention.Dan Magenheimer
SWIZ_BITS > 8 results in a much larger number of "tmem_obj" allocations, likely one per page-placed-in-frontswap. The tmem_obj is not huge (roughly 100 bytes), but it is large enough to add a not-insignificant memory overhead to zcache. The SWIZ_BITS=8 will get roughly the same lock contention without the space wastage. The effect of SWIZ_BITS can be thought of as "2^SWIZ_BITS is the number of unique oids that be generated" (This concept is limited to frontswap's use of tmem). Acked-by: Seth Jennings <sjenning@linux.vnet.ibm.com> Signed-off-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com> Cc: stable <stable@vger.kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2012-02-08zcache: fix deadlock conditionDan Magenheimer
I discovered this deadlock condition awhile ago working on RAMster but it affects zcache as well. The list spinlock must be locked prior to the page spinlock and released after. As a result, the page copy must also be done while the locks are held. Applies to 3.2. Konrad, please push (via GregKH?)... this is definitely a bug fix so need not be pushed during a -rc0 window. Signed-off-by: Dan Magenheimer <dan.magenheimer@oracle.com> Acked-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com> Cc: stable <stable@vger.kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2012-02-08staging: drm/omap: fix locking issueRob Clark
The create/free mmap offset code must be synchronized. Yet only some callers of omap_gem_mmap_offset() held struct_mutex. Leading to various crashes around drm_mm_insert_helper_range(). (In the free-object path, which is currently the only place we drm_gem_free_mmap_offset(), struct_mutex is already held.) Signed-off-by: Rob Clark <rob@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2012-02-08drivers/staging/omapdrm/omap_fbdev.c: move free after usesJulia Lawall
Move the free after the final uses. The semantic patch that makes this report is available in scripts/coccinelle/free/kfree.cocci. More information about semantic patching is available at http://coccinelle.lip6.fr/ Signed-off-by: Julia Lawall <julia@diku.dk> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2012-02-08staging: drm/omap: fix minimum width/heightRob Clark
Fix minimum width/height so planes could be used to implement hw mouse cursor. Signed-off-by: Rob Clark <rob@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2012-02-08staging: drm/omap: updates for DSS fifomerge API changesRob Clark
Signed-off-by: Rob Clark <rob@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2012-02-08staging: drm/omap: multiplanar and YUV supportRob Clark
Add support in framebuffer objects for other color formats and multi- planar YUV (NV12). Since this requires changing the API between the plane and fb for getting scanout information (paddr, etc), take advantage of the opportunity and put in place a way to allow fb's to be unpinned when they are not being scanned out. Now, before start of scanout the plane calls omap_framebuffer_pin() which takes care to pin all the backing bo's, then omap_framebuffer_update_scanout() however many times to update the scanout address(es), etc, and then when finished omap_framebuffer_unpin(). Signed-off-by: Rob Clark <rob@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2012-02-08staging: drm/omap: add drm_plane supportRob Clark
Because framebuffer layer and overlay scanout video pipes are basically thing in OMAP display subsystem (the only difference being that the first video pipe does not support scaling or YUV formats), much of the CRTC code is pulled into the plane implementation, and a private plane object is used by the CRTC object. This avoids code duplication between the plane and CRTC. Signed-off-by: Rob Clark <rob@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2012-02-08staging: drm/omap: drm API update: addfb2Rob Clark
Update to reflect changes in: "drm: add an fb creation ioctl that takes a pixel format v5" Signed-off-by: Rob Clark <rob@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2012-02-08staging: drm/omap: drm API update: make fops struct constRob Clark
Update to reflect changes in: "Make the per-driver file_operations struct const" Signed-off-by: Rob Clark <rob@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2012-02-08staging: delete gma500 driverGreg Kroah-Hartman
It's now "properly" merged into the DRM tree in the kernel, so delete the staging version of the driver as it is far obsolete and broken. Requested-by: Alan Cox <alan@linux.intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2012-01-31Linux 3.3-rc2v3.3-rc2Linus Torvalds
2012-01-31Merge tag 'for-linus' of git://github.com/prasad-joshi/logfs_upstreamLinus Torvalds
There are few important bug fixes for LogFS * tag 'for-linus' of git://github.com/prasad-joshi/logfs_upstream: Logfs: Allow NULL block_isbad() methods logfs: Grow inode in delete path logfs: Free areas before calling generic_shutdown_super() logfs: remove useless BUG_ON MAINTAINERS: Add Prasad Joshi in LogFS maintiners logfs: Propagate page parameter to __logfs_write_inode logfs: set superblock shutdown flag after generic sb shutdown logfs: take write mutex lock during fsync and sync logfs: Prevent memory corruption logfs: update page reference count for pined pages Fix up conflict in fs/logfs/dev_mtd.c due to semantic change in what "mtd->block_isbad" means in commit f2933e86ad93: "Logfs: Allow NULL block_isbad() methods" clashing with the abstraction changes in the commits 7086c19d0742: "mtd: introduce mtd_block_isbad interface" and d58b27ed58a3: "logfs: do not use 'mtd->block_isbad' directly". This resolution takes the semantics from commit f2933e86ad93, and just makes mtd_block_isbad() return zero (false) if the 'block_isbad' function is NULL. But that also means that now "mtd_can_have_bb()" always returns 0. Now, "mtd_block_markbad()" will obviously return an error if the low-level driver doesn't support bad blocks, so this is somewhat non-symmetric, but it actually makes sense if a NULL "block_isbad" function is considered to mean "I assume that all my blocks are always good".
2012-01-30Merge branch 'hwmon-for-linus' of ↵Linus Torvalds
git://git.kernel.org/pub/scm/linux/kernel/git/groeck/linux-staging * 'hwmon-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/groeck/linux-staging: hwmon: (w83627ehf) Disable setting DC mode for pwm2, pwm3 on NCT6776F hwmon: (sht15) fix bad error code MAINTAINERS: Drop maintainer for MAX1668 hwmon driver MAINTAINERS: Add hwmon entries for Wolfson hwmon: (f71805f) Fix clamping of temperature limits
2012-01-30Merge branch 'for-torvalds' of ↵Linus Torvalds
git://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-pinctrl Here are some fixes to the pin control system that has accumulated since -rc1. Mainly Tony Lindgren fixed the module load/unload logic and the rest are minor fixes and documentation. * 'for-torvalds' of git://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-pinctrl: pinctrl: add checks for empty function names pinctrl: fix pinmux_hog_maps when ctrl_dev_name is not set pinctrl: fix some pinmux typos pinctrl: free debugfs entries when unloading a pinmux driver pinctrl: unbreak error messages Documentation/pinctrl: fix a few syntax errors in code examples pinctrl: fix pinconf_pins_show iteration
2012-01-30Merge tag 'tty-3.3-rc1' of ↵Linus Torvalds
git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/tty Here are some tty/serial patches for 3.3-rc1 Big thing here is the movement of the 8250 serial drivers to their own directory, now that the patch churn has calmed down. Other than that, only minor stuff (omap patches were reverted as they were found to be wrong), and another broken driver removed from the system. Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> * tag 'tty-3.3-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/tty: serial: Kill off Moorestown code Revert "tty: serial: OMAP: ensure FIFO levels are set correctly in non-DMA mode" Revert "tty: serial: OMAP: transmit FIFO threshold interrupts don't wake the chip" serial: Fix wakeup init logic to speed up startup docbook: don't use serial_core.h in device-drivers book serial: amba-pl011: lock console writes against interrupts amba-pl011: do not disable RTS during shutdown tty: serial: OMAP: transmit FIFO threshold interrupts don't wake the chip tty: serial: OMAP: ensure FIFO levels are set correctly in non-DMA mode omap-serial: make serial_omap_restore_context depend on CONFIG_PM_RUNTIME omap-serial :Make the suspend/resume functions depend on CONFIG_PM_SLEEP. TTY: fix UV serial console regression jsm: Fixed EEH recovery error Updated TTY MAINTAINERS info serial: group all the 8250 related code together
2012-01-30Merge tag 'usb-3.3-rc1' of ↵Linus Torvalds
git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb Here are a bunch of USB patches for 3.3-rc1. Nothing major, largest thing here is the removal of some drivers that did not work at all. Other than that, the normal collection of bugfixes and new device ids. Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> * tag 'usb-3.3-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb: (52 commits) uwb & wusb: fix kconfig error USB: Realtek cr: fix autopm scheduling while atomic USB: ftdi_sio: Add more identifiers xHCI: Cleanup isoc transfer ring when TD length mismatch found usb: musb: omap2430: minor cleanups. qcaux: add more Pantech UML190 and UML290 ports Revert "drivers: usb: Fix dependency for USB_HWA_HCD" usb: mv-otg - Fix build if CONFIG_USB is not set USB: cdc-wdm: Avoid hanging on interface with no USB_CDC_DMM_TYPE usb: add support for STA2X11 host driver drivers: usb: Fix dependency for USB_HWA_HCD kernel-doc: fix new warning in usb.h USB: OHCI: fix new compiler warnings usb: serial: kobil_sct: fix compile warning: drivers/usb/host/ehci-fsl.c: add missing iounmap USB: cdc-wdm: better allocate a buffer that is at least as big as we tell the USB core USB: cdc-wdm: call wake_up_all to allow driver to shutdown on device removal USB: cdc-wdm: use two mutexes to allow simultaneous read and write USB: cdc-wdm: updating desc->length must be protected by spin_lock USB: usbsevseg: fix max length ...
2012-01-30Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/netLinus Torvalds
1) Setting link attributes can modify the size of the attributes that would be reported on a subsequent getlink netlink operation, therefore min_ifinfo_dump_size needs to be adjusted. From Stefan Gula. 2) Resegmentation of TSO frames while trimming can violate invariants expected by callers, namely that the number of segments can only stay the same or decrease, never increase. If MSS changes, however, we can trim data but then end up with more segments. Fix this by only segmenting to the MSS already recorded in the SKB. That's the simplest fix for now and if we want to get more fancy in the future that's a more involved change. This probably explains some retransmit counter inaccuracies. From Neal Cardwell. 3) Fix too-many-wakeups in POLL with AF_UNIX sockets, from Eric Dumazet. 4) Fix CAIF crashes wrt. namespace handling. From Eric Dumazet and Eric W. Biederman. 5) TCP port selection fixes from Flavio Leitner. 6) More socket memory cgroup build fixes in certain randonfig situations. From Glauber Costa. 7) Fix TCP memory sysctl regression reported by Ingo Molnar, also from Glauber Costa. * git://git.kernel.org/pub/scm/linux/kernel/git/davem/net: af_unix: fix EPOLLET regression for stream sockets tcp: fix tcp_trim_head() to adjust segment count with skb MSS net/tcp: Fix tcp memory limits initialization when !CONFIG_SYSCTL net caif: Register properly as a pernet subsystem. netns: Fail conspicously if someone uses net_generic at an inappropriate time. net: explicitly add jump_label.h header to sock.h net: RTNETLINK adjusting values of min_ifinfo_dump_size ipv6: Fix ip_gre lockless xmits. xen-netfront: correct MAX_TX_TARGET calculation. netns: fix net_alloc_generic() tcp: bind() optimize port allocation tcp: bind() fix autoselection to share ports l2tp: l2tp_ip - fix possible oops on packet receive iwlwifi: fix PCI-E transport "inta" race mac80211: set bss_conf.idle when vif is connected mac80211: update oper_channel on ibss join
2012-01-30Merge tag 'for-linus' of ↵Linus Torvalds
git://git.kernel.org/pub/scm/linux/kernel/git/broonie/regulator This fixes an integration issue with the regulator device tree bindings which shook out in -rc. The bindings were overly enthusiatic when deciding to set a voltage on a regulator and would try to set zero volts on an unconfigured regulator which isn't supported. * tag 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/regulator: regulator: Set apply_uV only when min and max voltages are defined
2012-01-30af_unix: fix EPOLLET regression for stream socketsEric Dumazet
Commit 0884d7aa24 (AF_UNIX: Fix poll blocking problem when reading from a stream socket) added a regression for epoll() in Edge Triggered mode (EPOLLET) Appropriate fix is to use skb_peek()/skb_unlink() instead of skb_dequeue(), and only call skb_unlink() when skb is fully consumed. This remove the need to requeue a partial skb into sk_receive_queue head and the extra sk->sk_data_ready() calls that added the regression. This is safe because once skb is given to sk_receive_queue, it is not modified by a writer, and readers are serialized by u->readlock mutex. This also reduce number of spinlock acquisition for small reads or MSG_PEEK users so should improve overall performance. Reported-by: Nick Mathewson <nickm@freehaven.net> Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com> Cc: Alexey Moiseytsev <himeraster@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2012-01-30tcp: fix tcp_trim_head() to adjust segment count with skb MSSNeal Cardwell
This commit fixes tcp_trim_head() to recalculate the number of segments in the skb with the skb's existing MSS, so trimming the head causes the skb segment count to be monotonically non-increasing - it should stay the same or go down, but not increase. Previously tcp_trim_head() used the current MSS of the connection. But if there was a decrease in MSS between original transmission and ACK (e.g. due to PMTUD), this could cause tcp_trim_head() to counter-intuitively increase the segment count when trimming bytes off the head of an skb. This violated assumptions in tcp_tso_acked() that tcp_trim_head() only decreases the packet count, so that packets_acked in tcp_tso_acked() could underflow, leading tcp_clean_rtx_queue() to pass u32 pkts_acked values as large as 0xffffffff to ca_ops->pkts_acked(). As an aside, if tcp_trim_head() had really wanted the skb to reflect the current MSS, it should have called tcp_set_skb_tso_segs() unconditionally, since a decrease in MSS would mean that a single-packet skb should now be sliced into multiple segments. Signed-off-by: Neal Cardwell <ncardwell@google.com> Acked-by: Nandita Dukkipati <nanditad@google.com> Acked-by: Ilpo Järvinen <ilpo.jarvinen@helsinki.fi> Signed-off-by: David S. Miller <davem@davemloft.net>
2012-01-30net/tcp: Fix tcp memory limits initialization when !CONFIG_SYSCTLGlauber Costa
sysctl_tcp_mem() initialization was moved to sysctl_tcp_ipv4.c in commit 3dc43e3e4d0b52197d3205214fe8f162f9e0c334, since it became a per-ns value. That code, however, will never run when CONFIG_SYSCTL is disabled, leading to bogus values on those fields - causing hung TCP sockets. This patch fixes it by keeping an initialization code in tcp_init(). It will be overwritten by the first net namespace init if CONFIG_SYSCTL is compiled in, and do the right thing if it is compiled out. It is also named properly as tcp_init_mem(), to properly signal its non-sysctl side effect on TCP limits. Reported-by: Ingo Molnar <mingo@elte.hu> Signed-off-by: Glauber Costa <glommer@parallels.com> Cc: David S. Miller <davem@davemloft.net> Link: http://lkml.kernel.org/r/4F22D05A.8030604@parallels.com [ renamed the function, tidied up the changelog a bit ] Signed-off-by: Ingo Molnar <mingo@elte.hu> Signed-off-by: David S. Miller <davem@davemloft.net>
2012-01-30Merge branch 'for-linus' of ↵Linus Torvalds
git://git.kernel.org/pub/scm/linux/kernel/git/s390/linux * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/s390/linux: [S390] dasd: revalidate server for new pathgroup [S390] dasd: revert LCU optimization [S390] cleanup entry point definition
2012-01-30Merge branch 'next' of git://git.monstr.eu/linux-2.6-microblazeLinus Torvalds
* 'next' of git://git.monstr.eu/linux-2.6-microblaze: microblaze: generic atomic64 support
2012-01-30Merge branch 'drm-fixes' of git://people.freedesktop.org/~airlied/linuxLinus Torvalds
* 'drm-fixes' of git://people.freedesktop.org/~airlied/linux: vmwgfx: Fix assignment in vmw_framebuffer_create_handle drm/radeon/kms: Fix device tree linkage of i2c buses drm: Pass the real error code back during GEM bo initialisation Revert "drm/i810: cleanup reclaim_buffers"
2012-01-30Merge tag 'nfs-for-3.3-3' of git://git.linux-nfs.org/projects/trondmy/linux-nfsLinus Torvalds
NFS client bugfixes for Linux 3.3 (pull 3) * tag 'nfs-for-3.3-3' of git://git.linux-nfs.org/projects/trondmy/linux-nfs: SUNRPC: Fix machine creds in generic_create_cred and generic_match
2012-01-30Merge tag 'pm-fix-for-3.3-rc2' of ↵Linus Torvalds
git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm Power management fix for 3.3-rc2 Fix for a hibernate (s2disk) regression introduced during the 3.2 merge window that causes s2disk to trigger BUG_ON() in freeze_workqueues_begin() if there is not enough swap space to save the image. * tag 'pm-fix-for-3.3-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm: PM / Hibernate: Fix s2disk regression related to freezing workqueues
2012-01-30vmwgfx: Fix assignment in vmw_framebuffer_create_handleRyan Mallon
The assignment of handle in vmw_framebuffer_create_handle doesn't actually do anything useful and is incorrectly assigning an integer value to a pointer argument. It appears that this is a typo and should be dereferencing handle rather than assigning to it directly. This fixes a bug where an undefined handle value is potentially returned to user-space. Signed-off-by: Ryan Mallon <rmallon@gmail.com> Reviewed-by: Jakob Bornecrantz<jakob@vmware.com> Cc: stable@vger.kernel.org Signed-off-by: Dave Airlie <airlied@redhat.com>
2012-01-30drm/radeon/kms: Fix device tree linkage of i2c busesJean Delvare
Properly set the parent device of i2c buses before registering them so that they will show at the right place in the device tree (rather than in /sys/devices directly.) Signed-off-by: Jean Delvare <jdelvare@suse.de> Cc: Dave Airlie <airlied@gmail.com> Reviewed-by: Alex Deucher <alexdeucher@gmail.com> Signed-off-by: Dave Airlie <airlied@redhat.com>
2012-01-30drm: Pass the real error code back during GEM bo initialisationChris Wilson
In particular, I found I was hitting the max-file limit in the VFS, and the EFILE was being magically transformed into ENOMEM. Confusion reigns. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Dave Airlie <airlied@redhat.com>
2012-01-30Revert "drm/i810: cleanup reclaim_buffers"Daniel Vetter
This reverts commit 87499ffdcb1c70f66988cd8febc4ead0ba2f9118. Where is that paper bag ... ah here. I've failed to take an odd interaction between my other cleanups and this reclaim_buffers patch into account and also failed to properly test it. Looks like there are more dragons and hidden trapdoors in the drm release path than actual lines of code. Until I get a clue, let's just revert this. Signed-Off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by: Dave Airlie <airlied@redhat.com>
2012-01-29hwmon: (w83627ehf) Disable setting DC mode for pwm2, pwm3 on NCT6776FGuenter Roeck
NCT6776F only supports pwm mode for pwm2 and pwm3. Return error if an attempt is made to set those pwm channels to DC mode. Signed-off-by: Guenter Roeck <linux@roeck-us.net> Acked-by: Jean Delvare <khali@linux-fr.org> Cc: stable@vger.kernel.org # 3.0+ Signed-off-by: Guenter Roeck <guenter.roeck@ericsson.com>
2012-01-29PM / Hibernate: Fix s2disk regression related to freezing workqueuesRafael J. Wysocki
Commit 2aede851ddf08666f68ffc17be446420e9d2a056 PM / Hibernate: Freeze kernel threads after preallocating memory introduced a mechanism by which kernel threads were frozen after the preallocation of hibernate image memory to avoid problems with frozen kernel threads not responding to memory freeing requests. However, it overlooked the s2disk code path in which the SNAPSHOT_CREATE_IMAGE ioctl was run directly after SNAPSHOT_FREE, which caused freeze_workqueues_begin() to BUG(), because it saw that worqueues had been already frozen. Although in principle this issue might be addressed by removing the relevant BUG_ON() from freeze_workqueues_begin(), that would reintroduce the very problem that commit 2aede851ddf08666f68ffc17be4 attempted to avoid into that particular code path. For this reason, to fix the issue at hand, introduce thaw_kernel_threads() and make the SNAPSHOT_FREE ioctl execute it. Special thanks to Srivatsa S. Bhat for detailed analysis of the problem. Reported-and-tested-by: Jiri Slaby <jslaby@suse.cz> Signed-off-by: Rafael J. Wysocki <rjw@sisk.pl> Acked-by: Srivatsa S. Bhat <srivatsa.bhat@linux.vnet.ibm.com> Cc: stable@kernel.org