commit afe8a887550f7cc24eb16449670b93f6b43c32d8 Merge: 405b864 de93c3c Author: Linus Torvalds Date: Wed Feb 2 10:23:58 2011 +1100 Merge branch 'next' of git://git.monstr.eu/linux-2.6-microblaze * 'next' of git://git.monstr.eu/linux-2.6-microblaze: microblaze: Fix ASM optimized code for LE microblaze: Fix unaligned issue on MMU system with BS=0 DIV=1 microblaze: Fix DTB passing from bootloader commit 405b864d3fd579d3e8a1002f7452343fbb6dbe99 Merge: fdf4c58 6284644 Author: Linus Torvalds Date: Wed Feb 2 10:22:40 2011 +1100 Merge git://git.kernel.org/pub/scm/linux/kernel/git/sfrench/cifs-2.6 * git://git.kernel.org/pub/scm/linux/kernel/git/sfrench/cifs-2.6: cifs: fix length checks in checkSMB [CIFS] Update cifs minor version cifs: No need to check crypto blockcipher allocation cifs: clean up some compiler warnings cifs: make CIFS depend on CRYPTO_MD4 cifs: force a reconnect if there are too many MIDs in flight cifs: don't pop a printk when sending on a socket is interrupted cifs: simplify SMB header check routine cifs: send an NT_CANCEL request when a process is signalled cifs: handle cancelled requests better cifs: fix two compiler warning about uninitialized vars commit fdf4c587a793ba87935e38e7f25a9540bc9a7b95 Author: Michel Lespinasse Date: Mon Jan 31 17:03:41 2011 -0800 mlock: operate on any regions with protection != PROT_NONE As Tao Ma noticed, change 5ecfda0 breaks blktrace. This is because blktrace mmaps a file with PROT_WRITE permissions but without PROT_READ, so my attempt to not unnecessarity break COW during mlock ended up causing mlock to fail with a permission problem. I am proposing to let mlock ignore vma protection in all cases except PROT_NONE. In particular, mlock should not fail for PROT_WRITE regions (as in the blktrace case, which broke at 5ecfda0) or for PROT_EXEC regions (which seem to me like they were always broken). Signed-off-by: Michel Lespinasse Acked-by: Rik van Riel Signed-off-by: Linus Torvalds commit 69bc70d4f97ce82153bed0afc9f432700c60390b Author: Randy Dunlap Date: Tue Feb 1 11:17:28 2011 -0800 gpu/stub: fix acpi_video build error, fix stub kconfig dependencies The comments under "config STUB_POULSBO" are close to correct, but they are not being followed. This patch updates them to reflect the requirements for THERMAL. This build error is caused by STUB_POULSBO selecting ACPI_VIDEO when ACPI_VIDEO's config requirements are not met. ERROR: "thermal_cooling_device_register" [drivers/acpi/video.ko] undefined! ERROR: "thermal_cooling_device_unregister" [drivers/acpi/video.ko] undefined! Signed-off-by: Randy Dunlap Signed-off-by: Linus Torvalds commit 6284644e8de1f4005166c918c3d2aa4c510ab9f6 Author: Jeff Layton Date: Mon Jan 31 09:14:17 2011 -0500 cifs: fix length checks in checkSMB The cERROR message in checkSMB when the calculated length doesn't match the RFC1001 length is incorrect in many cases. It always says that the RFC1001 length is bigger than the SMB, even when it's actually the reverse. Fix the error message to say the reverse of what it does now when the SMB length goes beyond the end of the received data. Also, clarify the error message when the RFC length is too big. Finally, clarify the comments to show that the 512 byte limit on extra data at the end of the packet is arbitrary. Signed-off-by: Jeff Layton Signed-off-by: Steve French commit cab6958da0094e36a098751f844409fc9ee26251 Author: Steve French Date: Mon Jan 31 21:56:35 2011 +0000 [CIFS] Update cifs minor version Signed-off-by: Steve French commit 7a8587e7c8e4e32ba778bfbbb822a0a7e8d5f3e3 Author: Shirish Pargaonkar Date: Sat Jan 29 13:54:58 2011 -0600 cifs: No need to check crypto blockcipher allocation Missed one change as per earlier suggestion. Signed-off-by: Shirish Pargaonkar Reviewed-by: Jeff Layton Signed-off-by: Steve French commit 31c2659d78c8be970833bc1e633593d291553ed3 Author: Jeff Layton Date: Mon Jan 31 07:24:46 2011 -0500 cifs: clean up some compiler warnings New compiler warnings that I noticed when building a patchset based on recent Fedora kernel: fs/cifs/cifssmb.c: In function 'CIFSSMBSetFileSize': fs/cifs/cifssmb.c:4813:8: warning: variable 'data_offset' set but not used [-Wunused-but-set-variable] fs/cifs/file.c: In function 'cifs_open': fs/cifs/file.c:349:24: warning: variable 'pCifsInode' set but not used [-Wunused-but-set-variable] fs/cifs/file.c: In function 'cifs_partialpagewrite': fs/cifs/file.c:1149:23: warning: variable 'cifs_sb' set but not used [-Wunused-but-set-variable] fs/cifs/file.c: In function 'cifs_iovec_write': fs/cifs/file.c:1740:9: warning: passing argument 6 of 'CIFSSMBWrite2' from incompatible pointer type [enabled by default] fs/cifs/cifsproto.h:337:12: note: expected 'unsigned int *' but argument is of type 'size_t *' fs/cifs/readdir.c: In function 'cifs_readdir': fs/cifs/readdir.c:767:23: warning: variable 'cifs_sb' set but not used [-Wunused-but-set-variable] fs/cifs/cifs_dfs_ref.c: In function 'cifs_dfs_d_automount': fs/cifs/cifs_dfs_ref.c:342:2: warning: 'rc' may be used uninitialized in this function [-Wuninitialized] fs/cifs/cifs_dfs_ref.c:278:6: note: 'rc' was declared here Signed-off-by: Jeff Layton Reviewed-by: Pavel Shilovsky Signed-off-by: Steve French commit f855f6cbeb4f94cd4e4a225c2246ee8012c384a2 Author: Jeff Layton Date: Mon Jan 31 08:41:36 2011 -0500 cifs: make CIFS depend on CRYPTO_MD4 Recently CIFS was changed to use the kernel crypto API for MD4 hashes, but the Kconfig dependencies were not changed to reflect this. Signed-off-by: Jeff Layton Reported-and-Tested-by: Suresh Jayaraman Reviewed-by: Shirish Pargaonkar Signed-off-by: Steve French commit 92a4e0f0169498867ecb19c2244510dd4beba149 Author: Jeff Layton Date: Sat Jan 29 07:02:28 2011 -0500 cifs: force a reconnect if there are too many MIDs in flight Currently, we allow the pending_mid_q to grow without bound with SIGKILL'ed processes. This could eventually be a DoS'able problem. An unprivileged user could a process that does a long-running call and then SIGKILL it. If he can also intercept the NT_CANCEL calls or the replies from the server, then the pending_mid_q could grow very large, possibly even to 2^16 entries which might leave GetNextMid in an infinite loop. Fix this by imposing a hard limit of 32k calls per server. If we cross that limit, set the tcpStatus to CifsNeedReconnect to force cifsd to eventually reconnect the socket and clean out the pending_mid_q. While we're at it, clean up the function a bit and eliminate an unnecessary NULL pointer check. Signed-off-by: Jeff Layton Reviewed-by: Shirish Pargaonkar Signed-off-by: Steve French commit d804d41d163c0975d2890c82d7135ada7a2f23a4 Author: Jeff Layton Date: Fri Jan 28 15:05:43 2011 -0500 cifs: don't pop a printk when sending on a socket is interrupted If we kill the process while it's sending on a socket then the kernel_sendmsg will return -EINTR. This is normal. No need to spam the ring buffer with this info. Signed-off-by: Jeff Layton Signed-off-by: Steve French commit 68abaffa6bbd3cadfaa4b7216d10bcd32406090b Author: Jeff Layton Date: Fri Jan 28 15:05:42 2011 -0500 cifs: simplify SMB header check routine ...just cleanup. There should be no behavior change. Signed-off-by: Jeff Layton Reviewed-by: Pavel Shilovsky Signed-off-by: Steve French commit 2db7c5815555d8daabf7d4ab1253ce690852c140 Author: Jeff Layton Date: Fri Jan 28 07:08:28 2011 -0500 cifs: send an NT_CANCEL request when a process is signalled Use the new send_nt_cancel function to send an NT_CANCEL when the process is delivered a fatal signal. This is a "best effort" enterprise however, so don't bother to check the return code. There's nothing we can reasonably do if it fails anyway. Reviewed-by: Pavel Shilovsky Reviewed-by: Suresh Jayaraman Signed-off-by: Jeff Layton Signed-off-by: Steve French commit 1be912dde772b77aaaa21770eeabb0a7a5e297a6 Author: Jeff Layton Date: Fri Jan 28 07:08:28 2011 -0500 cifs: handle cancelled requests better Currently, when a request is cancelled via signal, we delete the mid immediately. If the request was already transmitted however, the client is still likely to receive a response. When it does, it won't recognize it however and will pop a printk. It's also a little dangerous to just delete the mid entry like this. We may end up reusing that mid. If we do then we could potentially get the response from the first request confused with the later one. Prevent the reuse of mids by marking them as cancelled and keeping them on the pending_mid_q list. If the reply comes in, we'll delete it from the list then. If it never comes, then we'll delete it at reconnect or when cifsd comes down. Reviewed-by: Pavel Shilovsky Signed-off-by: Jeff Layton Signed-off-by: Steve French commit 58b8a5b45a097b477c037bc376e65dc5f214bf3d Merge: ffeb414 70d1f36 Author: Steve French Date: Mon Jan 31 04:17:03 2011 +0000 Merge branch 'master' of /pub/scm/linux/kernel/git/torvalds/linux-2.6 commit ffeb414a59291d5891f09727beb793c109f19f08 Author: Jeff Layton Date: Sat Jan 29 07:03:02 2011 -0500 cifs: fix two compiler warning about uninitialized vars fs/cifs/link.c: In function ‘symlink_hash’: fs/cifs/link.c:58:3: warning: ‘rc’ may be used uninitialized in this function [-Wuninitialized] fs/cifs/smbencrypt.c: In function ‘mdfour’: fs/cifs/smbencrypt.c:61:3: warning: ‘rc’ may be used uninitialized in this function [-Wuninitialized] Reviewed-by: Shirish Pargaonkar Signed-off-by: Jeff Layton Signed-off-by: Steve French commit de93c3c119382cb888ca8a94b642dbcf8035525e Author: Michal Simek Date: Fri Jan 28 13:26:54 2011 +0100 microblaze: Fix ASM optimized code for LE Microblaze little-endian doesn't support ASM optimized library functions(memcpy/memmove). Kconfig doens't contain any information about endian that's why it is necessary to check it in the source code. The code is used with barrel shifter is used. Signed-off-by: Michal Simek commit 9c749e177ccc0b3ee9589425c7255079e7a726fc Author: Michal Simek Date: Fri Jan 28 13:14:58 2011 +0100 microblaze: Fix unaligned issue on MMU system with BS=0 DIV=1 Unaligned code use shift for finding register operand. There is used BSRLI(r8,r8,2) macro which is expand for BS=0, DIV=1 by ori rD, r0, (1 << imm); \ idivu rD, rD, rA but if rD is equal rA then ori instruction rewrite value which should be devide. The patch remove this macro which use idivu instruction because idivu takes 32/34 cycles. The highest shifting is 20 which takes 20 cycles. Signed-off-by: Michal Simek commit 026a2078791b64aede220b1b1a3e4dfe4ab175e7 Author: Michal Simek Date: Wed Jan 26 13:41:05 2011 +0100 microblaze: Fix DTB passing from bootloader Little endian system needs to check OF_DT_HEADER but it is swapped because it is in big-endian. Microblaze LE provides lwr instruction which loads magic number in BIG endian format which can be compared. There is used the fact that if you write 0x1 as word and load it as byte then you get for big-endian zero and 1 for little-endian. Signed-off-by: Michal Simek