aboutsummaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2013-01-11mm: memblock: fix wrong memmove size in memblock_merge_regions()Lin Feng1-1/+2
The memmove span covers from (next+1) to the end of the array, and the index of next is (i+1), so the index of (next+1) is (i+2). So the size of remaining array elements is (type->cnt - (i + 2)). Since the remaining elements of the memblock array are move forward by one element and there is only one additional element caused by this bug. So there won't be any write overflow here but read overflow. It may read one more element out of the array address if the array happens to be full. Commonly it doesn't matter at all but if the array happens to be located at the end a memblock, it may cause a invalid read operation for the physical address doesn't exist. There are 2 *happens to be* here, so I think the probability is quite low, I don't know if any guy is haunted by this bug before. Mostly I think it's user-invisible. Signed-off-by: Lin Feng <[email protected]> Acked-by: Tejun Heo <[email protected]> Reviewed-by: Wanpeng Li <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2013-01-11drivers/video/ssd1307fb.c: fix bit order bug in the byte translation functionMaxime Ripard1-2/+2
This was leading to a strange behaviour when using the fbcon driver on top of this one: the letters were in the right order, but each letter had a vertical symmetry. This was because the addressing was right for the byte, but the addressing of each individual bit was inverted. Signed-off-by: Maxime Ripard <[email protected]> Cc: Brian Lilly <[email protected]> Cc: Greg Kroah-Hartman <[email protected]> Cc: Florian Tobias Schandinat <[email protected]> Cc: Thomas Petazzoni <[email protected]> Cc: Tomi Valkeinen <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2013-01-11mm: migrate: check page_count of THP before migratingMel Gorman1-1/+13
Hugh Dickins pointed out that migrate_misplaced_transhuge_page() does not check page_count before migrating like base page migration and khugepage. He could not see why this was safe and he is right. The potential impact of the bug is avoided due to the limitations of NUMA balancing. The page_mapcount() check ensures that only a single address space is using this page and as THPs are typically private it should not be possible for another address space to fault it in parallel. If the address space has one associated task then it's difficult to have both a GUP pin and be referencing the page at the same time. If there are multiple tasks then a buggy scenario requires that another thread be accessing the page while the direct IO is in flight. This is dodgy behaviour as there is a possibility of corruption with or without THP migration. It would be While we happen to be safe for the most part it is shoddy to depend on such "safety" so this patch checks the page count similar to anonymous pages. Note that this does not mean that the page_mapcount() check can go away. If we were to remove the page_mapcount() check the the THP would have to be unmapped from all referencing PTEs, replaced with migration PTEs and restored properly afterwards. Signed-off-by: Mel Gorman <[email protected]> Reported-by: Hugh Dickins <[email protected]> Cc: Ingo Molnar <[email protected]> Cc: Andrea Arcangeli <[email protected]> Acked-by: Hugh Dickins <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2013-01-11drivers/rtc/rtc-da9055.c: fix cross-section referenceAndrew Morton1-1/+1
Fix the warning WARNING: drivers/rtc/rtc-da9055.o(.text+0xa71): Section mismatch in reference from the function da9055_rtc_probe() to the function .init.text:da9055_rtc_device_init() Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2013-01-11lib: cpu_rmap: avoid flushing all workqueuesDavid Decotigny3-19/+53
In some cases, free_irq_cpu_rmap() is called while holding a lock (eg rtnl). This can lead to deadlocks, because it invokes flush_scheduled_work() which ends up waiting for whole system workqueue to flush, but some pending works might try to acquire the lock we are already holding. This commit uses reference-counting to replace irq_run_affinity_notifiers(). It also removes irq_run_affinity_notifiers() altogether. [[email protected]: eliminate free_cpu_rmap, rename cpu_rmap_reclaim() to cpu_rmap_release(), propagate kref_put() retval from cpu_rmap_put()] Signed-off-by: David Decotigny <[email protected]> Reviewed-by: Ben Hutchings <[email protected]> Acked-by: Eric Dumazet <[email protected]> Reviewed-by: Josh Triplett <[email protected]> Cc: "David S. Miller" <[email protected]> Cc: Or Gerlitz <[email protected]> Acked-by: Amir Vadai <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2013-01-11x86/Sandy Bridge: reserve pages when integrated graphics is presentJesse Barnes1-0/+78
SNB graphics devices have a bug that prevent them from accessing certain memory ranges, namely anything below 1M and in the pages listed in the table. So reserve those at boot if set detect a SNB gfx device on the CPU to avoid GPU hangs. Stephane Marchesin had a similar patch to the page allocator awhile back, but rather than reserving pages up front, it leaked them at allocation time. [ hpa: made a number of stylistic changes, marked arrays as static const, and made less verbose; use "memblock=debug" for full verbosity. ] Signed-off-by: Jesse Barnes <[email protected]> Signed-off-by: H. Peter Anvin <[email protected]>
2013-01-11cpuidle: fix number of initialized/destroyed statesKrzysztof Mazur1-1/+1
Commit bf4d1b5ddb78f86078ac6ae0415802d5f0c68f92 (cpuidle: support multiple drivers) changed the number of initialized state kobjects in cpuidle_add_state_sysfs() from device->state_count to drv->state_count, but left device->state_count in cpuidle_remove_state_sysfs(). The values of these two fields may be different, in which case a NULL pointer dereference may happen in cpuidle_remove_state_sysfs(), for example. Fix this problem by making cpuidle_add_state_sysfs() use device->state_count too (which restores the original behavior of it). [rjw: Changelog] Signed-off-by: Krzysztof Mazur <[email protected]> Acked-by: Daniel Lezcano <[email protected]> Signed-off-by: Rafael J. Wysocki <[email protected]>
2013-01-11tracing: Fix regression with irqsoff tracer and tracing_on fileSteven Rostedt1-2/+9
Commit 02404baf1b47 "tracing: Remove deprecated tracing_enabled file" removed the tracing_enabled file as it never worked properly and the tracing_on file should be used instead. But the tracing_on file didn't call into the tracers start/stop routines like the tracing_enabled file did. This caused trace-cmd to break when it enabled the irqsoff tracer. If you just did "echo irqsoff > current_tracer" then it would work properly. But the tool trace-cmd disables tracing first by writing "0" into the tracing_on file. Then it writes "irqsoff" into current_tracer and then writes "1" into tracing_on. Unfortunately, the above commit changed the irqsoff tracer to check the tracing_on status instead of the tracing_enabled status. If it's disabled then it does not start the tracer internals. The problem is that writing "1" into tracing_on does not call the tracers "start" routine like writing "1" into tracing_enabled did. This makes the irqsoff tracer not start when using the trace-cmd tool, and is a regression for userspace. Simple fix is to have the tracing_on file call the tracers start() method when being enabled (and the stop() method when disabled). Signed-off-by: Steven Rostedt <[email protected]>
2013-01-11USB: hub: handle claim of enabled remote wakeup after resetOliver Neukum1-2/+8
Some touchscreens have buggy firmware which claims remote wakeup to be enabled after a reset. They nevertheless crash if the feature is cleared by the host. Add a check for reset resume before checking for an enabled remote wakeup feature. On compliant devices the feature must be cleared after a reset anyway. Signed-off-by: Oliver Neukum <[email protected]> Acked-by: Alan Stern <[email protected]> Cc: stable <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
2013-01-11Merge tag 'nfs-for-3.8-3' of git://git.linux-nfs.org/projects/trondmy/linux-nfsLinus Torvalds2-4/+11
Pull NFS client bugfix from Trond Myklebust: - Fix a socket lock leak in net/sunrpc/xprt.c * tag 'nfs-for-3.8-3' of git://git.linux-nfs.org/projects/trondmy/linux-nfs: SUNRPC: Ensure we release the socket write lock if the rpc_task exits early
2013-01-11USB: cdc-acm: Add support for "PSC Scanning, Magellan 800i"Denis N Ladin1-0/+3
Adding support "PSC Scanning, Magellan 800i" in cdc-acm Very simple, but very necessary. Suitable for all versions of the kernel > 2.6 Signed-off-by: Denis N Ladin <[email protected]> Cc: stable <[email protected]> Acked-by: Oliver Neukum <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
2013-01-11USB: option: add Nexpring NP10T terminal idDzianis Kahanovich1-0/+5
Hyundai Petatel Inc. Nexpring NP10T terminal (EV-DO rev.A USB modem) ID Signed-off-by: Denis Kaganovich <[email protected]> Cc: stable <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
2013-01-11USB: option: add Telekom Speedstick LTE IIBjørn Mork1-0/+3
also known as Alcatel One Touch L100V LTE The driver description files gives these names to the vendor specific functions on this modem: Application1: VID_1BBB&PID_011E&MI_00 Application2: VID_1BBB&PID_011E&MI_01 Modem: VID_1BBB&PID_011E&MI_03 Ethernet: VID_1BBB&PID_011E&MI_04 Reported-by: Thomas Schäfer <[email protected]> Cc: <[email protected]> Signed-off-by: Bjørn Mork <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
2013-01-11USB: option: blacklist network interface on ZTE MF880Bjørn Mork1-1/+2
The driver description files gives these names to the vendor specific functions on this modem: diag: VID_19D2&PID_0284&MI_00 nmea: VID_19D2&PID_0284&MI_01 at: VID_19D2&PID_0284&MI_02 mdm: VID_19D2&PID_0284&MI_03 net: VID_19D2&PID_0284&MI_04 Signed-off-by: Bjørn Mork <[email protected]> Cc: stable <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
2013-01-11usb: imx21-hcd: Include missing linux/module.hFabio Estevam1-0/+1
Include <linux/module.h>, so that the following errors are fixed: drivers/usb/host/imx21-hcd.c:1929:20: error: expected declaration specifiers or '...' before string constant drivers/usb/host/imx21-hcd.c:1930:15: error: expected declaration specifiers or '...' before string constant drivers/usb/host/imx21-hcd.c:1931:16: error: expected declaration specifiers or '...' before string constant drivers/usb/host/imx21-hcd.c:1932:14: error: expected declaration specifiers or '...' before string constant Signed-off-by: Fabio Estevam <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
2013-01-11USB: option: Add new MEDIATEK PID supportQuentin.Li1-0/+7
In option.c, add some new MEDIATEK PIDs support for MEDIATEK new products. This is a MEDIATEK inc. release patch. Signed-off-by: Quentin.Li <[email protected]> Cc: stable <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
2013-01-11xen/privcmd: Relax access control in privcmd_ioctl_mmapTamas Lengyel1-6/+0
In the privcmd Linux driver two checks in the functions privcmd_ioctl_mmap and privcmd_ioctl_mmap_batch are not needed as they are trying to enforce hypervisor-level access control. They should be removed as they break secondary control domains when performing dom0 disaggregation. Xen itself provides adequate security controls around these hypercalls and these checks prevent those controls from functioning as intended. Signed-off-by: Tamas K Lengyel <[email protected]> Cc: Daniel De Graaf <[email protected]> [v1: Fixed up the patch and commit description] Signed-off-by: Konrad Rzeszutek Wilk <[email protected]>
2013-01-11Merge branch 'drm-fixes' of git://people.freedesktop.org/~airlied/linuxLinus Torvalds7-67/+81
Pull intel DRM fixes from Dave Airlie: "Just intel fixes, including getting the Ironlake systems back to the state they were in for 3.6." * 'drm-fixes' of git://people.freedesktop.org/~airlied/linux: drm/i915: Revert shrinker changes from "Track unbound pages" drm/i915: Use pixel size for computing linear offsets into a sprite drm/i915: Add DEBUG messages to all intel_create_user_framebuffer error paths drm/i915: The sprite scaler on Ironlake also support YUV planes drm: Only evict the blocks required to create the requested hole drm/i915: Treat crtc->mode.clock == 0 as disabled Revert "drm/i915: no lvds quirk for Zotac ZDBOX SD ID12/ID13" drm/i915; Only increment the user-pin-count after successfully pinning the bo
2013-01-11mm: compaction: Partially revert capture of suitable high-order pageMel Gorman5-110/+23
Eric Wong reported on 3.7 and 3.8-rc2 that ppoll() got stuck when waiting for POLLIN on a local TCP socket. It was easier to trigger if there was disk IO and dirty pages at the same time and he bisected it to commit 1fb3f8ca0e92 ("mm: compaction: capture a suitable high-order page immediately when it is made available"). The intention of that patch was to improve high-order allocations under memory pressure after changes made to reclaim in 3.6 drastically hurt THP allocations but the approach was flawed. For Eric, the problem was that page->pfmemalloc was not being cleared for captured pages leading to a poor interaction with swap-over-NFS support causing the packets to be dropped. However, I identified a few more problems with the patch including the fact that it can increase contention on zone->lock in some cases which could result in async direct compaction being aborted early. In retrospect the capture patch took the wrong approach. What it should have done is mark the pageblock being migrated as MIGRATE_ISOLATE if it was allocating for THP and avoided races that way. While the patch was showing to improve allocation success rates at the time, the benefit is marginal given the relative complexity and it should be revisited from scratch in the context of the other reclaim-related changes that have taken place since the patch was first written and tested. This patch partially reverts commit 1fb3f8ca "mm: compaction: capture a suitable high-order page immediately when it is made available". Reported-and-tested-by: Eric Wong <[email protected]> Tested-by: Eric Dumazet <[email protected]> Cc: [email protected] Signed-off-by: Mel Gorman <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2013-01-11debugfs: convert gid= argument from decimal, not octalDave Reisner1-1/+1
This patch technically breaks userspace, but I suspect that anyone who actually used this flag would have encountered this brokenness, declared it lunacy, and already sent a patch. Signed-off-by: Dave Reisner <[email protected]> Reviewed-by: Vasiliy Kulikov <[email protected]> Acked-by: Kees Cook <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
2013-01-11sh: Fix FDPIC binary loaderThomas Schwinge1-2/+2
Ensure that the aux table is properly initialized, even when optional features are missing. Without this, the FDPIC loader did not work. This was meant to be included in commit d5ab780305bb6d60a7b5a74f18cf84eb6ad153b1. Signed-off-by: Thomas Schwinge <[email protected]> Cc: [email protected] Signed-off-by: Paul Mundt <[email protected]>
2013-01-11sh: clkfwk: bugfix: sh_clk_div_enable() care sh_clk_div_set_rate() if div6Kuninori Morimoto1-0/+6
764f4e4e33d18cde4dcaf8a0d860b749c6d6d08b (sh: clkfwk: Use shared sh_clk_div_enable/disable()) shared enable/disable funcions for div4/div6. But new sh_clk_div_enable() didn't care sh_clk_div_set_rate() which is required on div6 clock. This patch fixes it. Signed-off-by: Kuninori Morimoto <[email protected]> Signed-off-by: Paul Mundt <[email protected]>
2013-01-11sh: define TASK_UNMAPPED_BASE as a page aligned constantKuninori Morimoto2-2/+2
b4265f12340f809447b9a48055e88c444b480c89 (mm: use vm_unmapped_area() on sh architecture) broke sh boot. This patch define TASK_UNMAPPED_BASE as a page aligned constant to solve this issue. Special thanks to Michel Acked-by: Michel Lespinasse <[email protected]> Signed-off-by: Kuninori Morimoto <[email protected]> Signed-off-by: Paul Mundt <[email protected]>
2013-01-11ALSA: usb-audio: Fix NULL dereference by access to non-existing substreamTakashi Iwai1-0/+10
The commit [0d9741c0: ALSA: usb-audio: sync ep init fix for audioformat mismatch] introduced the correction of parameters to be set for sync EP. But since the new code assumes that the sync EP is always paired with the data EP of another direction, it triggers Oops when a device only with a single direction is used. This patch adds a proper check of sync EP type and the presence of the paired substream for avoiding the crash. Reported-and-tested-by: Jens Axboe <[email protected]> Signed-off-by: Takashi Iwai <[email protected]>
2013-01-10tcp: accept RST without ACK flagEric Dumazet1-2/+2
commit c3ae62af8e755 (tcp: should drop incoming frames without ACK flag set) added a regression on the handling of RST messages. RST should be allowed to come even without ACK bit set. We validate the RST by checking the exact sequence, as requested by RFC 793 and 5961 3.2, in tcp_validate_incoming() Reported-by: Eric Wong <[email protected]> Signed-off-by: Eric Dumazet <[email protected]> Acked-by: Neal Cardwell <[email protected]> Tested-by: Eric Wong <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2013-01-11f2fs: move f2fs_balance_fs to punch_holeJaegeuk Kim1-3/+2
The f2fs_fallocate() has two operations: punch_hole and expand_size. Only in the case of punch_hole, dirty node pages can be produced, so let's trigger f2fs_balance_fs() in this case only. Furthermore, let's trigger it at every data truncation routine. Signed-off-by: Namjae Jeon <[email protected]> Signed-off-by: Jaegeuk Kim <[email protected]>
2013-01-11f2fs: add f2fs_balance_fs in several interfacesJaegeuk Kim4-0/+10
The f2fs_balance_fs() is to check the number of free sections and decide whether it needs to conduct cleaning or not. If there are not enough free sections, the cleaning job should be started. In order to control an amount of free sections even under high utilization, f2fs should call f2fs_balance_fs at all the VFS interfaces that are able to produce dirty pages. This patch adds the function calls in the missing interfaces as follows. 1. f2fs_setxattr() The f2fs_setxattr() produces dirty node pages so that we should call f2fs_balance_fs() either likewise doing in other VFS interfaces such as f2fs_lookup(), f2fs_mkdir(), and so on. 2. f2fs_sync_file() We should guarantee serving free sections for syncing metadata during fsync. Previously, there is no space check before triggering checkpoint and sync_node_pages. Therefore, if a bunch of fsync calls are triggered under 100% of FS utilization, f2fs is able to be faced with no free sections, resulting in BUG_ON(). 3. f2fs_sync_fs() Before calling write_checkpoint(), we should guarantee that there are minimum free sections. 4. f2fs_write_inode() f2fs_write_inode() is also able to produce dirty node pages. Signed-off-by: Jaegeuk Kim <[email protected]>
2013-01-10iscsi-target: Fix CmdSN comparison (use cmd->cmd_sn instead of cmd->stat_sn)Roland Dreier1-1/+1
Commit 64c13330a389 ("iscsi-target: Fix bug in handling of ExpStatSN ACK during u32 wrap-around") introduced a bug where we compare the wrong SN against our ExpCmdSN. Reported-by: Ben Hutchings <[email protected]> Signed-off-by: Roland Dreier <[email protected]> Cc: [email protected] Signed-off-by: Nicholas Bellinger <[email protected]>
2013-01-10target: Release se_cmd when LUN lookup fails for TMRRoland Dreier1-0/+2
When transport_lookup_tmr_lun() fails and we return a task management response from target_complete_tmr_failure(), we need to call transport_cmd_check_stop_to_fabric() to release the last ref to the cmd after calling se_tfo->queue_tm_rsp(), or else we will never remove the failed TMR from the session command list (and we'll end up waiting forever when trying to tear down the session). (nab: Fix minor compile breakage) Signed-off-by: Roland Dreier <[email protected]> Cc: [email protected] Signed-off-by: Nicholas Bellinger <[email protected]>
2013-01-10target: Fix use-after-free in LUN RESET handlingRoland Dreier1-3/+2
If a backend IO takes a really long then an initiator might abort a command, and then when it gives up on the abort, send a LUN reset too, all before we process any of the original command or the abort. (The abort will wait for the backend IO to complete too) When the backend IO final completes (or fails), the abort handling will proceed and queue up a "return aborted status" operation. Then, while that's still pending, the LUN reset might find the original command still on the LUN's list of commands and try to return aborted status again, which leads to a use-after free when the first se_tfo->queue_status call frees the command and then the second se_tfo->queue_status call runs. Fix this by removing a command from the LUN state_list when we first are about to queue aborted status; we shouldn't do anything LUN-related after we've started returning status, so this seems like the correct thing to do. Signed-off-by: Roland Dreier <[email protected]> Cc: [email protected] Signed-off-by: Nicholas Bellinger <[email protected]>
2013-01-10target: Fix missing CMD_T_ACTIVE bit regression for pending WRITEsRoland Dreier1-0/+1
This patch fixes a regression bug introduced during v3.6.x code with the following commit to drop transport_add_cmd_to_queue(), which originally re-set CMD_T_ACTIVE during pending WRITE I/O submission: commit af8772926f019b7bddd7477b8de5f3b0f12bad21 Author: Christoph Hellwig <[email protected]> Date: Sun Jul 8 15:58:49 2012 -0400 target: replace the processing thread with a TMR work queue The following sequence happens for write commands (or any other commands with a data out phase): - The transport calls target_submit_cmd(), which sets CMD_T_ACTIVE in cmd->transport_state and sets cmd->t_state to TRANSPORT_NEW_CMD. - Things go on transport_generic_new_cmd(), which notices that the command needs to transfer data, so it sets cmd->t_state to TRANSPORT_WRITE_PENDING and calls transport_cmd_check_stop(). - transport_cmd_check_stop() clears CMD_T_ACTIVE in cmd->transport_state and returns in the normal case. - Then we continue on to call ->se_tfo->write_pending(). - The data comes back from the initiator, and the transport calls target_execute_cmd(), which sets cmd->t_state to TRANSPORT_PROCESSING and calls into the backend to actually write the data. At this point, the backend might take a long time to complete the command, since it has to do real IO. If an abort request comes in for this command at this point, it will not wait for the command to finish since CMD_T_ACTIVE is not set. Then when the command does finally finish, we blow up with use-after-free. Avoid this by setting CMD_T_ACTIVE in target_execute_cmd() so that transport_wait_for_tasks() waits for the command to finish executing. This matches the behavior from before commit 1389533ef944 ("target: remove transport_generic_handle_data"), when data was signaled via transport_generic_handle_data(), which set CMD_T_ACTIVE because it called transport_add_cmd_to_queue(). Signed-off-by: Roland Dreier <[email protected]> Reported-by: Martin Svec <[email protected]> Cc: Christoph Hellwig <[email protected]> Cc: [email protected] Signed-off-by: Nicholas Bellinger <[email protected]>
2013-01-10tcm_fc: Do not report target role when target is not definedMark Rustad1-2/+8
Clear the target role when no target is provided for the node performing a PRLI. Signed-off-by: Mark Rustad <[email protected]> Reviewed-by: Bhanu Prakash Gollapudi <[email protected]> Acked by Robert Love <[email protected]> Cc: [email protected] Signed-off-by: Nicholas Bellinger <[email protected]>
2013-01-10tcm_fc: Do not indicate retry capability to initiatorsMark Rustad1-1/+1
When generating a PRLI response to an initiator, clear the FCP_SPPF_RETRY bit in the response. Signed-off-by: Mark Rustad <[email protected]> Reviewed-by: Bhanu Prakash Gollapudi <[email protected]> Acked by Robert Love <[email protected]> Cc: [email protected] Signed-off-by: Nicholas Bellinger <[email protected]>
2013-01-10target: Use TCM_NO_SENSE for initialisationHannes Reinecke2-2/+2
The compiler complained about uninitialized variables, so use TCM_NO_SENSE here. Signed-off-by: Hannes Reinecke <[email protected]> Cc: Nicholas Bellinger <[email protected]> Signed-off-by: Nicholas Bellinger <[email protected]>
2013-01-10target: Introduce TCM_NO_SENSEHannes Reinecke2-0/+11
Introduce TCM_NO_SENSE, mapping to sense code 'Not ready, no additional sense information'. Signed-off-by: Hannes Reinecke <[email protected]> Cc: Nicholas Bellinger <[email protected]> Signed-off-by: Nicholas Bellinger <[email protected]>
2013-01-10seq_file: fix new kernel-doc warningsRandy Dunlap1-1/+1
Fix kernel-doc warnings in fs/seq_file.c: Warning(fs/seq_file.c:304): No description found for parameter 'whence' Warning(fs/seq_file.c:304): Excess function parameter 'origin' description in 'seq_lseek' Signed-off-by: Randy Dunlap <[email protected]> Cc: Alexander Viro <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2013-01-10pci: fix iov.c kernel-doc warningsRandy Dunlap1-1/+1
Fix kernel-doc warning in iov.c: Warning(drivers/pci/iov.c:752): No description found for parameter 'numvfs' Signed-off-by: Randy Dunlap <[email protected]> Sorry-by: Don Dutile <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2013-01-10audit: fix auditfilter.c kernel-doc warningsRandy Dunlap1-1/+0
Fix new kernel-doc warning in auditfilter.c: Warning(kernel/auditfilter.c:1157): Excess function parameter 'uid' description in 'audit_receive_filter' Signed-off-by: Randy Dunlap <[email protected]> Cc: Al Viro <[email protected]> Cc: Eric Paris <[email protected]> Cc: [email protected] (subscribers-only) Signed-off-by: Linus Torvalds <[email protected]>
2013-01-10nfs: fix sunrpc/clnt.c kernel-doc warningsRandy Dunlap1-1/+1
Fix new kernel-doc warnings in clnt.c: Warning(net/sunrpc/clnt.c:561): No description found for parameter 'flavor' Warning(net/sunrpc/clnt.c:561): Excess function parameter 'auth' description in 'rpc_clone_client_set_auth' Signed-off-by: Randy Dunlap <[email protected]> Cc: Trond Myklebust <[email protected]> Cc: "J. Bruce Fields" <[email protected]> Cc: [email protected] Signed-off-by: Linus Torvalds <[email protected]>
2013-01-10net: ethernet: xilinx: Do not use NO_IRQ in axienetMichal Simek1-1/+1
This driver is used on Microblaze and will be used on Arm Zynq. Microblaze doesn't define NO_IRQ and no IRQ is 0. Arm still uses NO_IRQ as -1 and there is no option to connect IRQ to irq 0. That's why <= 0 is only one option how to find out undefined IRQ. Signed-off-by: Michal Simek <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2013-01-10net: ethernet: xilinx: Do not use axienet on PPCMichal Simek1-1/+1
Axi ethernet can't be used on PPC because it is little endian IP and PPC is big endian. This system can't be designed. Signed-off-by: Michal Simek <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2013-01-10bnx2x: Allow management traffic after boot from SANBarak Witkowski1-8/+52
As part of the previous driver unload flow, whenever bnx2x is loaded after the UNDI driver it closes all Rx traffic. However, this leads to management traffic also being stopped until the network interface associated with one of its functions gets loaded. To remedy this, management traffic is re-opened once the 'cleaning' after the previous driver ends. Signed-off-by: Barak Witkowski <[email protected]> Signed-off-by: Yuval Mintz <[email protected]> Signed-off-by: Ariel Elior <[email protected]> Signed-off-by: Eilon Greenstein <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2013-01-10bnx2x: Fix fastpath structures when memory allocation failsYuval Mintz1-2/+28
When allocating Tx queues, if for some reason (e.g., lack of memory) allocation fails, driver will incorrectly calculate the pointers of the various queues. This patch repositions all pointers in such a case to point at sequential structures in memory, allowing the bnx2x macros to be used correctly when accessing them. Signed-off-by: Yuval Mintz <[email protected]> Signed-off-by: Ariel Elior <[email protected]> Signed-off-by: Eilon Greenstein <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2013-01-10bfin_mac: Restore hardware time-stamping dependency on BF518Lars-Peter Clausen1-0/+1
Commit 70ac618c07 ("ptp: fixup Kconfig for two PHC drivers.") removed all dependencies for the blackfin hardware time-stamping Kconfig entry. Hardware time-stamping is only available on BF518 though. Since the Kconfig entry is 'default y', just updateing your kernel source and running `make defconfig` will result in the the following build errors: drivers/net/ethernet/adi/bfin_mac.c:694: error: implicit declaration of function ‘bfin_read_EMAC_PTP_CTL’ drivers/net/ethernet/adi/bfin_mac.c:702: error: implicit declaration of function ‘bfin_write_EMAC_PTP_FV3’ drivers/net/ethernet/adi/bfin_mac.c:712: error: implicit declaration of function ‘bfin_write_EMAC_PTP_CTL’ drivers/net/ethernet/adi/bfin_mac.c:717: error: implicit declaration of function ‘bfin_write_EMAC_PTP_FOFF’ ... This patch adds back the dependency on BF518, and since it does not make sense to expose this config option when the blackfin MAC driver is not enabled also restore the dependency on BFIN_MAC. Signed-off-by: Lars-Peter Clausen <[email protected]> Acked-by: Richard Cochran <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2013-01-10tun: avoid owner checks on IFF_ATTACH_QUEUEMichael S. Tsirkin1-2/+0
At the moment, we check owner when we enable queue in tun. This seems redundant and will break some valid uses where fd is passed around: I think TUNSETOWNER is there to prevent others from attaching to a persistent device not owned by them. Here the fd is already attached, enabling/disabling queue is more like read/write. Signed-off-by: Michael S. Tsirkin <[email protected]> Reviewed-by: Stefan Hajnoczi <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2013-01-10bnx2x: move debugging code before the returnDan Carpenter1-1/+1
I move the return down a line after the debugging printk. Signed-off-by: Dan Carpenter <[email protected]> Acked-by: Ariel Elior <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2013-01-10tuntap: refuse to re-attach to different tun_structStefan Hajnoczi1-0/+2
Multiqueue tun devices support detaching a tun_file from its tun_struct and re-attaching at a later point in time. This allows users to disable a specific queue temporarily. ioctl(TUNSETIFF) allows the user to specify the network interface to attach by name. This means the user can attempt to attach to interface "B" after detaching from interface "A". The driver is not designed to support this so check we are re-attaching to the right tun_struct. Failure to do so may lead to oops. Signed-off-by: Stefan Hajnoczi <[email protected]> Acked-by: Jason Wang <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2013-01-10ipv6: use addrconf_get_prefix_route for prefix route lookup [v2]Romain Kuntz1-14/+11
Replace ip6_route_lookup() with addrconf_get_prefix_route() when looking up for a prefix route. This ensures that the connected prefix is looked up in the main table, and avoids the selection of other matching routes located in different tables as well as blackhole or prohibited entries. In addition, this fixes an Opps introduced by commit 64c6d08e (ipv6: del unreachable route when an addr is deleted on lo), that would occur when a blackhole or prohibited entry is selected by ip6_route_lookup(). Such entries have a NULL rt6i_table argument, which is accessed by __ip6_del_rt() when trying to lock rt6i_table->tb6_lock. The function addrconf_is_prefix_route() is not used anymore and is removed. [v2] Minor indentation cleanup and log updates. Signed-off-by: Romain Kuntz <[email protected]> Acked-by: Nicolas Dichtel <[email protected]> Acked-by: YOSHIFUJI Hideaki <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2013-01-10ipv6: fix the noflags test in addrconf_get_prefix_routeRomain Kuntz1-1/+1
The tests on the flags in addrconf_get_prefix_route() does no make much sense: the 'noflags' parameter contains the set of flags that must not match with the route flags, so the test must be done against 'noflags', and not against 'flags'. Signed-off-by: Romain Kuntz <[email protected]> Acked-by: YOSHIFUJI Hideaki <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2013-01-10tcp: fix splice() and tcp collapsing interactionEric Dumazet1-3/+10
Under unusual circumstances, TCP collapse can split a big GRO TCP packet while its being used in a splice(socket->pipe) operation. skb_splice_bits() releases the socket lock before calling splice_to_pipe(). [ 1081.353685] WARNING: at net/ipv4/tcp.c:1330 tcp_cleanup_rbuf+0x4d/0xfc() [ 1081.371956] Hardware name: System x3690 X5 -[7148Z68]- [ 1081.391820] cleanup rbuf bug: copied AD3BCF1 seq AD370AF rcvnxt AD3CF13 To fix this problem, we must eat skbs in tcp_recv_skb(). Remove the inline keyword from tcp_recv_skb() definition since it has three call sites. Reported-by: Christian Becker <[email protected]> Cc: Willy Tarreau <[email protected]> Signed-off-by: Eric Dumazet <[email protected]> Tested-by: Willy Tarreau <[email protected]> Signed-off-by: David S. Miller <[email protected]>