aboutsummaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2010-03-24[S390] smp: fix lowcore allocationHeiko Carstens1-2/+2
The intermediate lowcore for CONFIG_SMP is allocated using a call to __alloc_bootmem() with a goal of 0. That however doesn't guarantee that the allocated piece of memory is below 2GB. Instead we should call __alloc_bootmem_low(). Signed-off-by: Heiko Carstens <[email protected]> Signed-off-by: Martin Schwidefsky <[email protected]>
2010-03-24[S390] zcore: CPU registers are not saved under LPARMichael Holzheu4-32/+32
To save the registers for all CPUs a sigp "store status" is done that stores the registers to address absolute zero. To access storage at absolute zero, normally the address of the prefix register of the accessing CPU has to be used. This does not work when large pages are active (currently only under LPAR). In order to fix that problem, instead of memcpy memcpy_real is used, which switches to real mode where prefixing works. Signed-off-by: Michael Holzheu <[email protected]> Signed-off-by: Martin Schwidefsky <[email protected]>
2010-03-24pcmcia: use dev_pm_ops for class pcmcia_socket_classDominik Brodowski19-288/+66
Instead of requiring PCMCIA socket drivers to call various functions during their (bus) resume and suspend functions, register an own dev_pm_ops for this class. This fixes several suspend/resume bugs seen on db1xxx-ss, and probably on some other socket drivers, too. With regard to the asymmetry with only _noirq suspend, but split up resume, please see bug 14334 and commit 9905d1b411946fb3 . Signed-off-by: Dominik Brodowski <[email protected]>
2010-03-24power: support _noirq actions on device types and classesDominik Brodowski1-0/+31
The new-style dev_pm_ops provide callbacks for both IRQs enabled and disabled. However, the _noirq variants were only called for buses registered with a device, not for classes and types. In order to properly use dev_pm_ops in class pcmcia_socket_class, support _noirq actions also on classes and types. Signed-off-by: Dominik Brodowski <[email protected]> Acked-by: Rafael J. Wysocki <[email protected]>
2010-03-24pcmcia: allow for four multifunction subdevices (again)Dominik Brodowski1-2/+6
Commit aa584ca4 broke what 6cf5be51 had already fixed: there may be four multifunction devices, but just two pseudo-multifunction devices per PCMCIA card. Signed-off-by: Dominik Brodowski <[email protected]>
2010-03-24Merge branch 'fix/hda' into for-linusTakashi Iwai4-8/+29
2010-03-24Merge branch 'fix/asoc' into for-linusTakashi Iwai5-9/+7
2010-03-24ALSA: cmipci: work around invalid PCM pointerClemens Ladisch1-3/+11
When the CMI8738 FRAME2 register is read, the chip sometimes (probably when wrapping around) returns an invalid value that would be outside the programmed DMA buffer. This leads to an inconsistent PCM pointer that is likely to result in an underrun. To work around this, read the register multiple times until we get a valid value; the error state seems to be very short-lived. Signed-off-by: Clemens Ladisch <[email protected]> Reported-and-tested-by: Matija Nalis <[email protected]> Cc: <[email protected]> Signed-off-by: Takashi Iwai <[email protected]>
2010-03-23igb: only use vlan_gro_receive if vlans are registeredAlexander Duyck1-1/+1
This change makes it so that vlan_gro_receive is only used if vlans have been registered to the adapter structure. Previously we were just sending all vlan tagged frames in via this function but this results in a null pointer dereference when vlans are not registered. [ This fixes bugzilla entry 15582 -Eric Dumazet] Signed-off-by: Alexander Duyck <[email protected]> Signed-off-by: Jeff Kirsher <[email protected]> Acked-by: Eric Dumazet <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2010-03-23igb: do not modify tx_queue_len on link speed changeEmil Tantilov2-10/+1
Previously the driver tweaked txqueuelen to avoid false Tx hang reports seen at half duplex. This had the effect of overriding user set values on link change/reset. Testing shows that adjusting only the timeout factor is sufficient to prevent Tx hang reports at half duplex. Based on e1000e patch by Franco Fichtner <[email protected]> Signed-off-by: Emil Tantilov <[email protected]> Signed-off-by: Jeff Kirsher <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2010-03-23igb: count Rx FIFO errors correctlyMitch Williams1-5/+5
Don't aggregate rx_no_buffer_count into rx_fifo_errors. RNBC counts packets that get queued temporarily in the adapter's FIFO. These packets are not dropped and are not errors. The correct counter is rx_missed_errors (MPC). Signed-off-by: Mitch Williams <[email protected]> Signed-off-by: Jeff Kirsher <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2010-03-23bnx2: Use proper handler during netpoll.Michael Chan1-3/+5
Netpoll needs to call the proper handler depending on the IRQ mode and the vector. Signed-off-by: Michael Chan <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2010-03-23bnx2: Fix netpoll crash.Benjamin Li1-2/+4
The bnx2 driver calls netif_napi_add() for all the NAPI structs during ->probe() time but not all of them will be used if we're not in MSI-X mode. This creates a problem for netpoll since it will poll all the NAPI structs in the dev_list whether or not they are scheduled, resulting in a crash when we access structure fields not initialized for that vector. We fix it by moving the netif_napi_add() call to ->open() after the number of IRQ vectors has been determined. Signed-off-by: Benjamin Li <[email protected]> Signed-off-by: Michael Chan <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2010-03-23ext4: Fixed inode allocator to correctly track a flex_bg's used_dirsEric Sandeen1-2/+2
When used_dirs was introduced for the flex_groups struct, it looks like the accounting was not put into place properly, in some places manipulating free_inodes rather than used_dirs. Signed-off-by: Eric Sandeen <[email protected]> Signed-off-by: "Theodore Ts'o" <[email protected]>
2010-03-24ext4: Don't use delayed allocation by default when used instead of ext3Jan Kara1-9/+16
When ext4 driver is used to mount a filesystem instead of the ext3 file system driver (through CONFIG_EXT4_USE_FOR_EXT23), do not enable delayed allocation by default since some ext3 users and application writers have developed unfortunate expectations about the safety of writing files on systems subject to sudden and violent death without using fsync(). Signed-off-by: Jan Kara <[email protected]> Signed-off-by: "Theodore Ts'o" <[email protected]>
2010-03-24ext4: Fix spelling of CONTIG_FS_EXT3 to CONFIG_FS_EXT3Theodore Ts'o1-2/+2
Oops. (Blush.) Thanks to Sedat Dilek for pointing this out. Signed-off-by: "Theodore Ts'o" <[email protected]>
2010-03-23ocfs2: Fix a race in o2dlm lockres masterySrinivas Eeda1-3/+1
In o2dlm, the master of a lock resource keeps a map of all interested nodes. This prevents the master from purging the resource before an interested node can create a lock. A race between the mastery thread and the mastery handler allowed an interested node to discover who the master is without informing the master directly. This is easily fixed by holding the dlm spinlock a little longer in the mastery handler. Signed-off-by: Srinivas Eeda <[email protected]> Signed-off-by: Joel Becker <[email protected]>
2010-03-23Ocfs2: Handle deletion of reflinked oprhan inodes correctly.Tristan Ye1-0/+15
The rule is that all inodes in the orphan dir have ORPHANED_FL, otherwise we treated it as an ERROR. This rule works well except for some rare cases of reflink operation: http://oss.oracle.com/bugzilla/show_bug.cgi?id=1215 The problem is caused by how reflink and our orphan_scan thread interact. * The orphan scan pulls the orphans into a queue first, then runs the queue at a later time. We only hold the orphan_dir's lock during scanning. * Reflink create a oprhaned target in orphan_dir as its first step. It removes the target and clears the flag as the final step. These two steps take the orphan_dir's lock, but it is not held for the duration. Based on the above semantics, a reflink inode can be moved out of the orphan dir and have its ORPHANED_FL cleared before the queue of orphans is run. This leads to a ERROR in ocfs2_query_wipde_inode(). This patch teaches ocfs2_query_wipe_inode() to detect previously orphaned reflink targets. If a reflink fails or a crash occurs during the relfink operation, the inode will retain ORPHANED_FL and will be properly wiped. Signed-off-by: Tristan Ye <[email protected]> Signed-off-by: Joel Becker <[email protected]>
2010-03-23Ocfs2: Journaling i_flags and i_orphaned_slot when adding inode to orphan dir.Tristan Ye1-5/+23
Currently, some callers were missing to journal the dirty inode after adding it to orphan dir. Now we're going to journal such modifications within the ocfs2_orphan_add() itself, It's safe to do so, though some existing caller may duplicate this, and it makes the logic look more straightforward anyway. Signed-off-by: Tristan Ye <[email protected]> Signed-off-by: Joel Becker <[email protected]>
2010-03-23ocfs2: Clear undo bits when local alloc is freedMark Fasheh4-46/+95
When the local alloc file changes windows, unused bits are freed back to the global bitmap. By defnition, those bits can not be in use by any file. Also, the local alloc will never have been able to allocate those bits if they were part of a previous truncate. Therefore it makes sense that we should clear unused local alloc bits in the undo buffer so that they can be used immediatly. [ Modified to call it ocfs2_release_clusters() -- Joel ] Signed-off-by: Mark Fasheh <[email protected]> Signed-off-by: Joel Becker <[email protected]>
2010-03-23resources: add interfaces that return conflict informationBjorn Helgaas2-7/+39
request_resource() and insert_resource() only return success or failure, which no information about what existing resource conflicted with the proposed new reservation. This patch adds request_resource_conflict() and insert_resource_conflict(), which return the conflicting resource. Callers may use this for better error messages or to adjust the new resource and retry the request. Signed-off-by: Bjorn Helgaas <[email protected]> Signed-off-by: Jesse Barnes <[email protected]>
2010-03-23ksz884x: fix return value of netdev_set_eepromJens Rottmann1-1/+1
ksz884x: fix return value of netdev_set_eeprom netdev_set_eeprom() confused ethtool by just returning 1 on error instead of a proper -EINVAL. Signed-off-by: Jens Rottmann <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2010-03-23cgroups: net_cls as moduleBen Blum2-10/+31
Allows the net_cls cgroup subsystem to be compiled as a module This patch modifies net/sched/cls_cgroup.c to allow the net_cls subsystem to be optionally compiled as a module instead of builtin. The cgroup_subsys struct is moved around a bit to allow the subsys_id to be either declared as a compile-time constant by the cgroup_subsys.h include in cgroup.h, or, if it's a module, initialized within the struct by cgroup_load_subsys. Signed-off-by: Ben Blum <[email protected]> Acked-by: Li Zefan <[email protected]> Cc: Paul Menage <[email protected]> Cc: "David S. Miller" <[email protected]> Cc: KAMEZAWA Hiroyuki <[email protected]> Cc: Lai Jiangshan <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2010-03-23drm/i915: Stop trying to use ACPI lid status to determine LVDS connection.Eric Anholt1-51/+1
I've been getting more and more quirk reports about this. It seems clear at this point that other OSes are not using this for determining whether the integrated panel should be turned on, and it is not reliable for doing so. Better to light up an unintended panel than to not light up the only usable output on the system. Signed-off-by: Eric Anholt <[email protected]> Acked-by: Jesse Barnes <[email protected]>
2010-03-23pcmcia: do not use ioports < 0x100 on x86Dominik Brodowski1-0/+7
On x86 systems using ACPI _CRS information -- now the default for post-2008 systems -- the PCI root bus no longer pretends to be offering the root ioport_resource. To avoid accidentally hitting some platform / system device, use only I/O ports >= 0x100 for PCMCIA devices on x86. Reported-by: Komuro <[email protected]> CC: Bjorn Helgaas <[email protected]> Signed-off-by: Dominik Brodowski <[email protected]>
2010-03-23[ARM] Orion5x: replace KEY_WLAN with KEY_WPS_BUTTONChristian Lamparter1-1/+1
"Input: add KEY_WPS_BUTTON definition" introduced a generic keycode for WPS input events. Signed-off-by: Christian Lamparter <[email protected]> Signed-off-by: Nicolas Pitre <[email protected]>
2010-03-23[ARM] Kirkwood: WPS button keycode mappingChristian Lamparter1-2/+2
Commit "Input: add KEY_WPS_BUTTON definition" added a generic keycode for WPS button. Let's use it, instead of "F1" mapping. Signed-off-by: Christian Lamparter <[email protected]> Signed-off-by: Nicolas Pitre <[email protected]>
2010-03-24nilfs2: fix imperfect completion wait in nilfs_wait_on_logsRyusuke Konishi1-4/+4
nilfs_wait_on_logs has a potential to slip out before completion of all bio requests when it met an error. This synchronization fault may cause unexpected results, for instance, violative access to freed segment buffers from an end-bio callback routine. This fixes the issue by ensuring that nilfs_wait_on_logs waits all given logs. Signed-off-by: Ryusuke Konishi <[email protected]>
2010-03-23time: Fix accumulation bug triggered by long delay.John Stultz1-1/+2
The logarithmic accumulation done in the timekeeping has some overflow protection that limits the max shift value. That means it will take more then shift loops to accumulate all of the cycles. This causes the shift decrement to underflow, which causes the loop to never exit. The simplest fix would be simply to do a: if (shift) shift--; However that is not optimal, as we know the cycle offset is larger then the interval << shift, the above would make shift drop to zero, then we would be spinning for quite awhile accumulating at interval chunks at a time. Instead, this patch only decreases shift if the offset is smaller then cycle_interval << shift. This makes sure we accumulate using the largest chunks possible without overflowing tick_length, and limits the number of iterations through the loop. This issue was found and reported by Sonic Zhang, who also tested the fix. Many thanks your explanation and testing! Reported-by: Sonic Zhang <[email protected]> Signed-off-by: John Stultz <[email protected]> Tested-by: Sonic Zhang <[email protected]> LKML-Reference: <[email protected]> Signed-off-by: Thomas Gleixner <[email protected]>
2010-03-23pd6729: Coding Style fixesKomuro1-25/+39
Signed-off-by: Komuro <[email protected]> Signed-off-by: Dominik Brodowski <[email protected]>
2010-03-24nilfs2: fix hang-up of cleaner after log writer returned with errorRyusuke Konishi1-2/+1
According to the report from Andreas Beckmann (Message-ID: <[email protected]>), nilfs in 2.6.33 kernel got stuck after a disk full error. This turned out to be a regression by log writer updates merged at kernel 2.6.33. nilfs_segctor_abort_construction, which is a cleanup function for erroneous cases, was skipping writeback completion for some logs. This fixes the bug and would resolve the hang issue. Reported-by: Andreas Beckmann <[email protected]> Signed-off-by: Ryusuke Konishi <[email protected]> Tested-by: Ryusuke Konishi <[email protected]> Cc: stable <[email protected]> [2.6.33.x]
2010-03-23ceph: avoid loaded term 'OSD' in documentionSage Weil1-1/+1
'OSD' means different things to different people; avoid it here to avoid confusion. Signed-off-by: Sage Weil <[email protected]>
2010-03-23ceph: fix possible double-free of mds request referenceSage Weil1-1/+3
Clear pointer to mds request after dropping the reference to ensure we don't drop it again, as there is at least one error path through this function that does not reset fi->last_readdir to a new value. Signed-off-by: Sage Weil <[email protected]>
2010-03-23ceph: fix session check on mds replySage Weil1-1/+1
Fix a broken check that a reply came back from the same MDS we sent the request to. I don't think a case that actually triggers this would ever come up in practice, but it's clearly wrong and easy to fix. Reported-by: Dan Carpenter <[email protected]> Signed-off-by: Sage Weil <[email protected]>
2010-03-23ceph: handle kmalloc() failureDan Carpenter1-0/+2
Return ERR_PTR(-ENOMEM) if kmalloc() fails. We handle allocation failures the same way later in the function. Signed-off-by: Dan Carpenter <[email protected]> Signed-off-by: Sage Weil <[email protected]>
2010-03-23ceph: propagate mds session allocation failures to callerSage Weil1-1/+6
Return error to original caller if register_session() fails. Signed-off-by: Sage Weil <[email protected]>
2010-03-23ceph: make write_begin wait propagate ERESTARTSYSSage Weil1-2/+8
Currently, if the wait_event_interruptible is interrupted, we return EAGAIN unconditionally and loop, such that we aren't, in fact, interruptible. So, propagate ERESTARTSYS if we get it. Signed-off-by: Sage Weil <[email protected]>
2010-03-23ceph: fix snap rebuild conditionSage Weil1-2/+2
We were rebuilding the snap context when it was not necessary (i.e. when the realm seq hadn't changed _and_ the parent seq was still older), which caused page snapc pointers to not match the realm's snapc pointer (even though the snap context itself was identical). This confused begin_write and put it into an endless loop. The correct logic is: rebuild snapc if _my_ realm seq changed, or if my parent realm's seq is newer than mine (and thus mine needs to be rebuilt too). Signed-off-by: Sage Weil <[email protected]>
2010-03-23ceph: avoid reopening osd connections when address hasn't changedSage Weil3-1/+23
We get a fault callback on _every_ tcp connection fault. Normally, we want to reopen the connection when that happens. If the address we have is bad, however, and connection attempts always result in a connection refused or similar error, explicitly closing and reopening the msgr connection just prevents the messenger's backoff logic from kicking in. The result can be a console full of [ 3974.417106] ceph: osd11 10.3.14.138:6800 connection failed [ 3974.423295] ceph: osd11 10.3.14.138:6800 connection failed [ 3974.429709] ceph: osd11 10.3.14.138:6800 connection failed Instead, if we get a fault, and have outstanding requests, but the osd address hasn't changed and the connection never successfully connected in the first place, do nothing to the osd connection. The messenger layer will back off and retry periodically, because we never connected and thus the lossy bit is not set. Instead, touch each request's r_stamp so that handle_timeout can tell the request is still alive and kicking. Signed-off-by: Sage Weil <[email protected]>
2010-03-23ceph: rename r_sent_stamp r_stampSage Weil2-7/+7
Make variable name slightly more generic, since it will (soon) reflect either the time the request was sent OR the time it was last determined to be still retrying. Signed-off-by: Sage Weil <[email protected]>
2010-03-23ceph: fix connection fault con_work reentrancy problemSage Weil1-2/+0
The messenger fault was clearing the BUSY bit, for reasons unclear. This made it possible for the con->ops->fault function to reopen the connection, and requeue work in the workqueue--even though the current thread was already in con_work. This avoids a problem where the client busy loops with connection failures on an unreachable OSD, but doesn't address the root cause of that problem. Signed-off-by: Sage Weil <[email protected]>
2010-03-23ceph: prevent dup stale messages to console for restarting mdsSage Weil1-1/+1
Prevent duplicate 'mds0 caps stale' message from spamming the console every few seconds while the MDS restarts. Set s_renew_requested earlier, so that we only print the message once, even if we don't send an actual request. Signed-off-by: Sage Weil <[email protected]>
2010-03-23ceph: fix pg pool decoding from incremental osdmap updateSage Weil1-7/+10
The incremental map decoding of pg pool updates wasn't skipping the snaps and removed_snaps vectors. This caused osd requests to stall when pool snapshots were created or fs snapshots were deleted. Use a common helper for full and incremental map decoders that decodes pools properly. Signed-off-by: Sage Weil <[email protected]>
2010-03-23ceph: fix mds sync() race with completing requestsSage Weil1-7/+20
The wait_unsafe_requests() helper dropped the mdsc mutex to wait for each request to complete, and then examined r_node to get the next request after retaking the lock. But the request completion removes the request from the tree, so r_node was always undefined at this point. Since it's a small race, it usually led to a valid request, but not always. The result was an occasional crash in rb_next() while dereferencing node->rb_left. Fix this by clearing the rb_node when removing the request from the request tree, and not walking off into the weeds when we are done waiting for a request. Since the request we waited on will _always_ be out of the request tree, take a ref on the next request, in the hopes that it won't be. But if it is, it's ok: we can start over from the beginning (and traverse over older read requests again). Signed-off-by: Sage Weil <[email protected]>
2010-03-23ceph: only release unused caps with mds requestsSage Weil1-3/+10
We were releasing used caps (e.g. FILE_CACHE) from encode_inode_release with MDS requests (e.g. setattr). We don't carry refs on most caps, so this code worked most of the time, but for setattr (utimes) we try to drop Fscr. This causes cap state to get slightly out of sync with reality, and may result in subsequent mds revoke messages getting ignored. Fix by only releasing unused caps. Signed-off-by: Sage Weil <[email protected]>
2010-03-23ceph: clean up handle_cap_grant, handle_caps wrt session mutexSage Weil1-32/+25
Drop session mutex unconditionally in handle_cap_grant, and do the check_caps from the handle_cap_grant helper. This avoids using a magic return value. Also avoid using a flag variable in the IMPORT case and call check_caps at the appropriate point. Signed-off-by: Sage Weil <[email protected]>
2010-03-23ceph: fix session locking in handle_caps, ceph_check_capsSage Weil1-5/+9
Passing a session pointer to ceph_check_caps() used to mean it would leave the session mutex locked. That wasn't always possible if it wasn't passed CHECK_CAPS_AUTHONLY. If could unlock the passed session and lock a differet session mutex, which was clearly wrong, and also emitted a warning when it a racing CPU retook it and we did an unlock from the wrong context. This was only a problem when there was more than one MDS. First, make ceph_check_caps unconditionally drop the session mutex, so that it is free to lock other sessions as needed. Then adjust the one caller that passes in a session (handle_cap_grant) accordingly. Signed-off-by: Sage Weil <[email protected]>
2010-03-23ceph: drop unnecessary WARN_ON in caps migrationSage Weil1-2/+1
If we don't have the exported cap it's because we already released it. No need to WARN. Signed-off-by: Sage Weil <[email protected]>
2010-03-23ceph: fix null pointer deref of r_osd in debug outputSage Weil1-1/+1
This causes an oops when debug output is enabled and we kick an osd request with no current r_osd (sometime after an osd failure). Check the pointer before dereferencing. Signed-off-by: Sage Weil <[email protected]>
2010-03-23ceph: clean up service ticket decodingSage Weil1-8/+20
Previously we would decode state directly into our current ticket_handler. This is problematic if for some reason we fail to decode, because we end up with half new state and half old state. We are probably already in bad shape if we get an update we can't decode, but we may as well be tidy anyway. Decode into new_* temporaries and update the ticket_handler only on success. Signed-off-by: Sage Weil <[email protected]>