commit 676165a8af7167f488abdcce6851a9bc36e83254 tree a9b2b8dc155b48ce073b5ada31f2ac0694118e69 parent c3a9d6541f84ac3ff566982d08389b87c1c36b4e author Nick Piggin Mon, 10 Apr 2006 11:21:48 +1000 committer Linus Torvalds Mon, 10 Apr 2006 10:16:37 -0700 [PATCH] Fix buddy list race that could lead to page lru list corruptions Rohit found an obscure bug causing buddy list corruption. page_is_buddy is using a non-atomic test (PagePrivate && page_count == 0) to determine whether or not a free page's buddy is itself free and in the buddy lists. Each of the conjuncts may be true at different times due to unrelated conditions, so the non-atomic page_is_buddy test may find each conjunct to be true even if they were not both true at the same time (ie. the page was not on the buddy lists). Signed-off-by: Martin Bligh Signed-off-by: Rohit Seth Signed-off-by: Nick Piggin Signed-off-by: KAMEZAWA Hiroyuki Signed-off-by: Linus Torvalds commit c3a9d6541f84ac3ff566982d08389b87c1c36b4e tree 161e507b276105b35dadf0c2637be9f018b0f664 parent 460fbf82c0842cad3f3c744c4dcb81978b7829f3 author David Howells Mon, 10 Apr 2006 15:15:21 +0100 committer Linus Torvalds Mon, 10 Apr 2006 09:33:46 -0700 [Security] Keys: Fix oops when adding key to non-keyring This fixes the problem of an oops occuring when a user attempts to add a key to a non-keyring key [CVE-2006-1522]. The problem is that __keyring_search_one() doesn't check that the keyring it's been given is actually a keyring. I've fixed this problem by: (1) declaring that caller of __keyring_search_one() must guarantee that the keyring is a keyring; and (2) making key_create_or_update() check that the keyring is a keyring, and return -ENOTDIR if it isn't. This can be tested by: keyctl add user b b `keyctl add user a a @s` Signed-off-by: David Howells Signed-off-by: Linus Torvalds commit 460fbf82c0842cad3f3c744c4dcb81978b7829f3 tree d19b6d7d18491a8fa423f3ac9f2b422863b8c373 parent 68491d5892defca59ad4f604cace2b1e30889c14 parent b1a7ffcb7a047e99ab02424e651e0492f36095f7 author Linus Torvalds Mon, 10 Apr 2006 08:46:00 -0700 committer Linus Torvalds Mon, 10 Apr 2006 08:46:00 -0700 Merge master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6 * master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6: (35 commits) [IPV6]: Deinline few large functions in inet6 code [IPV4] ip_fragment: Always compute hash with ipfrag_lock held. [NETFILTER]: Fix DNAT in LOCAL_OUT [X25]: Restore skb->dev setting in x25_type_trans(). [NET]: Fix hotplug race during device registration. [IPV6]: Unexport secure_ipv6_port_ephemeral [NETFILTER]: Fix build with CONFIG_NETFILTER=y/m on IA64 [NET]: More kzalloc conversions. [NET] kzalloc: use in alloc_netdev [PKT_SCHED] act_police: Rename methods. [TG3]: Speed up SRAM access (2nd version) [TG3]: Kill some less useful flags [NETFILTER]: H.323 helper: remove changelog [NETFILTER]: Convert conntrack/ipt_REJECT to new checksumming functions [NETFILTER]: Add address family specific checksum helpers [NETFILTER]: Introduce infrastructure for address family specific operations [NETFILTER]: Fix IP_NF_CONNTRACK_NETLINK dependency [NETFILTER]: H.323 helper: add parameter 'default_rrq_ttl' [NETFILTER]: H.323 helper: make get_h245_addr() static [NETFILTER]: H.323 helper: change EXPORT_SYMBOL to EXPORT_SYMBOL_GPL ... commit 68491d5892defca59ad4f604cace2b1e30889c14 tree 6d4a023ec88ef043808798b7539de0a9c7fa765a parent aa1d1a0af6022f02fb601508d3feaabafd405299 author David S. Miller Thu, 06 Apr 2006 20:28:11 -0700 committer David S. Miller Sun, 09 Apr 2006 22:56:45 -0700 [SPARC64]: Set ARCH_SELECT_MEMORY_MODEL Otherwise the build breaks with EXPERIMENTAL disabled because SPARSEMEM will not get selected properly. See mm/Kconfig for how that works. Signed-off-by: David S. Miller commit aa1d1a0af6022f02fb601508d3feaabafd405299 tree ef472a0c4df262b26366eb0d25fa2d03c87a444b parent 731bbe431f7dbbcbdc5293cfb187a916c375e83b author David S. Miller Thu, 06 Apr 2006 16:54:33 -0700 committer David S. Miller Sun, 09 Apr 2006 22:56:44 -0700 [SPARC64]: smp_call_function() fixups... 1) Take doc-book function comment from i386 implementation. 2) cacheline align call_lock, taken from powerpc 3) Need memory barrier after setting call_data 4) Remove timeout Signed-off-by: David S. Miller commit 731bbe431f7dbbcbdc5293cfb187a916c375e83b tree 6b4509828caff1cbed7526dcb514146d149e6056 parent 1608a96e7998bffd10fcb2440e8175cfb703fd95 author David S. Miller Tue, 04 Apr 2006 16:54:40 -0700 committer David S. Miller Sun, 09 Apr 2006 22:56:41 -0700 [SPARC64]: Translate PTRACE_GETEVENTMSG for 32-bit tasks. Signed-off-by: David S. Miller commit 1608a96e7998bffd10fcb2440e8175cfb703fd95 tree 2d14fb37fbfd5ff44654865dc8724b4fe8236903 parent 955c054f7905e0a9ee4483b03f866f61e6929bec author David S. Miller Sun, 02 Apr 2006 19:31:30 -0700 committer David S. Miller Sun, 09 Apr 2006 22:56:39 -0700 [SPARC64]: Update defconfig. Signed-off-by: David S. Miller commit 955c054f7905e0a9ee4483b03f866f61e6929bec tree 7e3f37f0f6b3c692dec00cc5351d65a3ccf46728 parent 1759e58ed2684b7a01cbb96864f23d18884f42ba author David S. Miller Sat, 01 Apr 2006 23:29:56 -0800 committer David S. Miller Sun, 09 Apr 2006 22:56:37 -0700 [SPARC64]: Print out return PC in cheetah_log_errors(). This makes debugging things a little bit easier. Signed-off-by: David S. Miller commit 1759e58ed2684b7a01cbb96864f23d18884f42ba tree e9c876d47c36093c3eb74456cbeb6b2f8cd69dbf parent 67644726317a8274be4a3d0ef85b9ccebaa90304 author David S. Miller Sat, 01 Apr 2006 23:28:10 -0800 committer David S. Miller Sun, 09 Apr 2006 22:56:35 -0700 [SPARC64]: Add dummy PTRACE_PEEKUSR for gdb. GDB uses a PTRACE_PEEKUSR call with offset 0 to see if a thread is alive, so provide a success return for this particular special case. Signed-off-by: David S. Miller commit b1a7ffcb7a047e99ab02424e651e0492f36095f7 tree ce84ddd2087b512ae484d6c6d21f985ef2e32a09 parent 55c0022e53452360064ea264c41410c70565d9f8 author Denis Vlasenko Sun, 09 Apr 2006 22:48:59 -0700 committer David S. Miller Sun, 09 Apr 2006 22:48:59 -0700 [IPV6]: Deinline few large functions in inet6 code Deinline a few functions which produce 200+ bytes of code. Size Uses Wasted Name and definition ===== ==== ====== ================================================ 429 3 818 __inet6_lookup include/net/inet6_hashtables.h 404 2 384 __inet6_lookup_established include/net/inet6_hashtables.h 206 3 372 __inet6_hash include/net/inet6_hashtables.h Signed-off-by: Denis Vlasenko Signed-off-by: David S. Miller commit 55c0022e53452360064ea264c41410c70565d9f8 tree cca5e75b12dfaaadf5620b59c7121a017a799117 parent 19910d1aec0b2b96ff4b4a93e2aed0d32643e850 author David S. Miller Sun, 09 Apr 2006 22:43:55 -0700 committer David S. Miller Sun, 09 Apr 2006 22:43:55 -0700 [IPV4] ip_fragment: Always compute hash with ipfrag_lock held. Otherwise we could compute an inaccurate hash due to the random seed changing. Noticed by Zach Brown and patch is based upon some feedback from Herbert Xu. Signed-off-by: David S. Miller commit 19910d1aec0b2b96ff4b4a93e2aed0d32643e850 tree 75d76070c55bc6564d27828ad251ac3fce462879 parent 9b591cbd4e0fc2911d105d88d354124467b2cc08 author Patrick McHardy Sun, 09 Apr 2006 22:38:29 -0700 committer David S. Miller Sun, 09 Apr 2006 22:38:29 -0700 [NETFILTER]: Fix DNAT in LOCAL_OUT Signed-off-by: Patrick McHardy Signed-off-by: David S. Miller commit 9b591cbd4e0fc2911d105d88d354124467b2cc08 tree 9da0f430be70d71e5d6f5f3105a225f3575a943e parent 9469d458b90bfb9117cbb488cfa645d94c3921b1 author David S. Miller Sun, 09 Apr 2006 22:37:18 -0700 committer David S. Miller Sun, 09 Apr 2006 22:37:18 -0700 [X25]: Restore skb->dev setting in x25_type_trans(). Noticed by Pascal Schlafer. Signed-off-by: David S. Miller commit 9469d458b90bfb9117cbb488cfa645d94c3921b1 tree 7b409ef16b310336edddcb396d1601896f39d33b parent 30aaa154fc21ad1ee4400e28009732a04a80862f author Sergey Vlasov Sun, 09 Apr 2006 22:32:48 -0700 committer David S. Miller Sun, 09 Apr 2006 22:32:48 -0700 [NET]: Fix hotplug race during device registration. From: Thomas de Grenier de Latour On Sun, 9 Apr 2006 21:56:59 +0400, Sergey Vlasov wrote: > However, show_address() does not output anything unless > dev->reg_state == NETREG_REGISTERED - and this state is set by > netdev_run_todo() only after netdev_register_sysfs() returns, so in > the meantime (while netdev_register_sysfs() is busy adding the > "statistics" attribute group) some process may see an empty "address" > attribute. I've tried the attached patch, suggested by Sergey Vlasov on hotplug-devel@, and as far as i can test it works just fine. Signed-off-by: David S. Miller commit 30aaa154fc21ad1ee4400e28009732a04a80862f tree 2486d6ea4bb00a5ed1e24c7ed5b5f76c07d7d49d parent 503e4faad18baa62bb818537b920ad939749823e author Adrian Bunk Sun, 09 Apr 2006 22:29:17 -0700 committer David S. Miller Sun, 09 Apr 2006 22:29:17 -0700 [IPV6]: Unexport secure_ipv6_port_ephemeral This patch removes the unused EXPORT_SYMBOL(secure_ipv6_port_ephemeral). Signed-off-by: Adrian Bunk Signed-off-by: David S. Miller commit 503e4faad18baa62bb818537b920ad939749823e tree 64ff33e6c80eee028fddf46de0a26a4dfeea4967 parent 77d04bd957ddca9d48a664e28b40f33993f4550e author Brian Haley Fri, 07 Apr 2006 15:00:06 -0700 committer David S. Miller Sun, 09 Apr 2006 22:25:49 -0700 [NETFILTER]: Fix build with CONFIG_NETFILTER=y/m on IA64 Can't build with CONFIG_NETFILTER=y/m on IA64, there's a missing #include in net/ipv6/netfilter.c net/ipv6/netfilter.c: In function `nf_ip6_checksum': net/ipv6/netfilter.c:92: warning: implicit declaration of function `csum_ipv6_magic' Signed-off-by: Brian Haley Signed-off-by: David S. Miller commit 77d04bd957ddca9d48a664e28b40f33993f4550e tree 8940d3ab7557aed03756e05eec13605e315c887e parent 31380de95cc3183bbb379339e67f83d69e56fbd6 author Andrew Morton Fri, 07 Apr 2006 14:52:59 -0700 committer David S. Miller Sun, 09 Apr 2006 22:25:48 -0700 [NET]: More kzalloc conversions. Signed-off-by: David S. Miller commit 31380de95cc3183bbb379339e67f83d69e56fbd6 tree 66eb2f4adf4ee02a0dffbe037f9340a3f7030544 parent 83b950c89c8cc0dcc1b079c638be25915c9945f1 author Paolo 'Blaisorblade' Giarrusso Thu, 06 Apr 2006 22:38:28 -0700 committer David S. Miller Sun, 09 Apr 2006 22:25:47 -0700 [NET] kzalloc: use in alloc_netdev Noticed this use, fixed it. Signed-off-by: Paolo 'Blaisorblade' Giarrusso Signed-off-by: David S. Miller commit 83b950c89c8cc0dcc1b079c638be25915c9945f1 tree d5216168fec6390a51ed371b80c42f6894380851 parent bbadf503d7c7e6efe0a4cd731f8855ba08276215 author Jamal Hadi Salim Thu, 06 Apr 2006 22:24:22 -0700 committer David S. Miller Sun, 09 Apr 2006 22:25:46 -0700 [PKT_SCHED] act_police: Rename methods. Rename policer specific _generic_ methods to be specific to _act_police_ Signed-off-by: Jamal Hadi Salim Signed-off-by: David S. Miller commit bbadf503d7c7e6efe0a4cd731f8855ba08276215 tree 1af228388f7f511525b7ef1d4b4777f4e258b2de parent d2d746f83b74022a50d28f7f0f496842c9cde330 author Michael Chan Thu, 06 Apr 2006 21:46:34 -0700 committer David S. Miller Sun, 09 Apr 2006 22:25:46 -0700 [TG3]: Speed up SRAM access (2nd version) Speed up SRAM read and write functions if possible by using MMIO instead of config. cycles. With this change, the post reset signature done at the end of D3 power change must now be moved before the D3 power change. IBM reported a problem on powerpc blades during ethtool self test that was caused by the memory test taking excessively long. Config. cycles are very slow on powerpc and the memory test can take more than 10 seconds to complete using config. cycles. David Miller informed me that an earlier version of the patch caused problems on sparc64 systems with built-in tg3 chips. This version fixes the problem by excluding all SUN built-in tg3 chips from doing MMIO SRAM access. TG3_FLAG_EEPROM_WRITE_PROT is also set unconditionally when TG3_FLG2_SUN_570X is set. This should be sane as all SUN chips are built-in and do not require Vaux switching. Signed-off-by: Michael Chan Signed-off-by: David S. Miller commit d2d746f83b74022a50d28f7f0f496842c9cde330 tree 4298a55e428e09a2643a53125e34caa6797b5f1e parent 7a43c9955178f1cc88374abe1186c0f2ef21e040 author Michael Chan Thu, 06 Apr 2006 21:45:39 -0700 committer David S. Miller Sun, 09 Apr 2006 22:25:44 -0700 [TG3]: Kill some less useful flags Kill the TG3_FLAG_NO_{TX|RX}_PSEUDO_CSUM flags because they are not very useful. This will free up some bits for new flags. Signed-off-by: Michael Chan Signed-off-by: David S. Miller commit 7a43c9955178f1cc88374abe1186c0f2ef21e040 tree a91b830c5cd11208f2eaf53bc6f3c07d16c81cb2 parent 96f6bf82ea3abc77d255d5d554df5f349651f6de author Patrick McHardy Thu, 06 Apr 2006 16:16:51 -0700 committer David S. Miller Sun, 09 Apr 2006 22:25:43 -0700 [NETFILTER]: H.323 helper: remove changelog Signed-off-by: Patrick McHardy Signed-off-by: David S. Miller commit 96f6bf82ea3abc77d255d5d554df5f349651f6de tree 7050071415f6e0ab56ee6d9a51680b30c3876a94 parent 422c346fad806e2abaeffac686860ebc98dfe33e author Patrick McHardy Thu, 06 Apr 2006 14:19:24 -0700 committer David S. Miller Sun, 09 Apr 2006 22:25:42 -0700 [NETFILTER]: Convert conntrack/ipt_REJECT to new checksumming functions Besides removing lots of duplicate code, all converted users benefit from improved HW checksum error handling. Tested with and without HW checksums in almost all combinations. Signed-off-by: Patrick McHardy Signed-off-by: David S. Miller commit 422c346fad806e2abaeffac686860ebc98dfe33e tree dd554d11e80ad33afef4b438ec4c2d8943ad37f4 parent bce8032ef3cc58170ab3550e9e271dba7b4c4764 author Patrick McHardy Thu, 06 Apr 2006 14:18:43 -0700 committer David S. Miller Sun, 09 Apr 2006 22:25:41 -0700 [NETFILTER]: Add address family specific checksum helpers Add checksum operation which takes care of verifying the checksum and dealing with HW checksum errors and avoids multiple checksum operations by setting ip_summed to CHECKSUM_UNNECESSARY after successful verification. Signed-off-by: Patrick McHardy Signed-off-by: David S. Miller commit bce8032ef3cc58170ab3550e9e271dba7b4c4764 tree 13dbdf12a6c567c3292daad4604eb55f7abd167e parent a0aed49bdb2bbb4234789f241cffb607fd2e213d author Patrick McHardy Thu, 06 Apr 2006 14:18:09 -0700 committer David S. Miller Sun, 09 Apr 2006 22:25:40 -0700 [NETFILTER]: Introduce infrastructure for address family specific operations Change the queue rerouter intrastructure to a generic usable infrastructure for address family specific operations as a base for some cleanups. Signed-off-by: Patrick McHardy Signed-off-by: David S. Miller commit a0aed49bdb2bbb4234789f241cffb607fd2e213d tree c1ce0b29ecb38427da529a8a5099be853200db46 parent a0b7db5e86d30f470dc1849f4fa44ff77a813091 author Patrick McHardy Thu, 06 Apr 2006 14:17:27 -0700 committer David S. Miller Sun, 09 Apr 2006 22:25:39 -0700 [NETFILTER]: Fix IP_NF_CONNTRACK_NETLINK dependency When NAT is built as a module, ip_conntrack_netlink can not be linked statically. Signed-off-by: Patrick McHardy Signed-off-by: David S. Miller commit a0b7db5e86d30f470dc1849f4fa44ff77a813091 tree 4b8bc7793dd25b2950b02b7f1576ffde4aa20d17 parent 51d42f5e4ee43fc98aa0c7a2a104808bb602276f author Jing Min Zhao Thu, 06 Apr 2006 14:15:33 -0700 committer David S. Miller Sun, 09 Apr 2006 22:25:38 -0700 [NETFILTER]: H.323 helper: add parameter 'default_rrq_ttl' default_rrq_ttl is used when no TTL is included in the RRQ. Signed-off-by: Jing Min Zhao Signed-off-by: Patrick McHardy Signed-off-by: David S. Miller commit 51d42f5e4ee43fc98aa0c7a2a104808bb602276f tree 75918387ba3d171765a4a33bb00bd70eaf12f41d parent 0f249685fde399c01e51a63f2bdfe4a667db083c author Jing Min Zhao Thu, 06 Apr 2006 14:14:59 -0700 committer David S. Miller Sun, 09 Apr 2006 22:25:37 -0700 [NETFILTER]: H.323 helper: make get_h245_addr() static Signed-off-by: Jing Min Zhao Signed-off-by: Patrick McHardy Signed-off-by: David S. Miller commit 0f249685fde399c01e51a63f2bdfe4a667db083c tree 87ae04aa3bca0a93506dc1d0f3667abc51f3a4dc parent 48bfee5fad0e46f4f18d46285efceba39e897482 author Jing Min Zhao Thu, 06 Apr 2006 14:14:11 -0700 committer David S. Miller Sun, 09 Apr 2006 22:25:36 -0700 [NETFILTER]: H.323 helper: change EXPORT_SYMBOL to EXPORT_SYMBOL_GPL Signed-off-by: Jing Min Zhao Signed-off-by: Patrick McHardy Signed-off-by: David S. Miller commit 48bfee5fad0e46f4f18d46285efceba39e897482 tree f527020c7163d519fdc6fd6d38f9473b6ce739bf parent 32292a7ff1d9306841a8da6ea286847b1070cc6a author Jing Min Zhao Thu, 06 Apr 2006 14:13:42 -0700 committer David S. Miller Sun, 09 Apr 2006 22:25:35 -0700 [NETFILTER]: H.323 helper: move some function prototypes to ip_conntrack_h323.h Move prototypes of NAT callbacks to ip_conntrack_h323.h. Because the use of typedefs as arguments, some header files need to be moved as well. Signed-off-by: Jing Min Zhao Signed-off-by: Patrick McHardy Signed-off-by: David S. Miller commit 32292a7ff1d9306841a8da6ea286847b1070cc6a tree e2149c5b4c7bc50a937f95657a2cb1814dea8ddb parent 964ddaa10de8f3aeed12bc2a30726514ff309e64 author Patrick McHardy Thu, 06 Apr 2006 14:11:30 -0700 committer David S. Miller Sun, 09 Apr 2006 22:25:34 -0700 [NETFILTER]: Fix section mismatch warnings Fix section mismatch warnings caused by netfilter's init_or_cleanup functions used in many places by splitting the init from the cleanup parts. Signed-off-by: Patrick McHardy Signed-off-by: David S. Miller commit 964ddaa10de8f3aeed12bc2a30726514ff309e64 tree 4cda0dcd4d5ec2bf8f06cd4375be4251e96c6a16 parent 972d1cb1427946f4980240363aac4e73fb375290 author Patrick McHardy Thu, 06 Apr 2006 14:09:49 -0700 committer David S. Miller Sun, 09 Apr 2006 22:25:33 -0700 [NETFILTER]: Clean up hook registration Clean up hook registration by makeing use of the new mass registration and unregistration helpers. Signed-off-by: Patrick McHardy Signed-off-by: David S. Miller commit 972d1cb1427946f4980240363aac4e73fb375290 tree 6b4af7fa66b358ab2d167093cd4bd43baa75f0a3 parent 137dc0233fba0bfa19679bdd96eb104f0e659c5a author Patrick McHardy Thu, 06 Apr 2006 14:09:12 -0700 committer David S. Miller Sun, 09 Apr 2006 22:25:32 -0700 [NETFILTER]: Add helper functions for mass hook registration/unregistration Signed-off-by: Patrick McHardy Signed-off-by: David S. Miller commit 137dc0233fba0bfa19679bdd96eb104f0e659c5a tree b1a087b443e6865478b6f99b54cbd562d3837886 parent c1e14a6ea2ae34993f431d2eb9a0f228ac3574eb author Samuel Ortiz Wed, 05 Apr 2006 22:39:14 -0700 committer David S. Miller Sun, 09 Apr 2006 22:25:31 -0700 [IRDA]: Support for Sigmatel STIR421x chip This patch enables support for the Sigmatel's STIR421x IrDA chip. Once patched with Sigmatel's firmware, this chip "almost" follows the USB-IrDA spec. Thus this patch is against irda-usb.[ch]. The code has been tested by Nick Fedchik on an STIR4210 chipset based dongle. Signed-off-by: Samuel Ortiz Signed-off-by: David S. Miller commit c1e14a6ea2ae34993f431d2eb9a0f228ac3574eb tree a49cbfdc16836115112e64d69780da7a7c2f2091 parent 45af08be6d120690d379cb8421ebaf9d9f86ba52 author Linus Walleij Wed, 05 Apr 2006 22:33:59 -0700 committer David S. Miller Sun, 09 Apr 2006 22:25:30 -0700 [IRDA]: smcinit merged into smsc-ircc driver This patch integrates the smcinit code into the smsc-ircc driver. Some laptops have their smsc-ircc chip not properly configured by the BIOS and needs some preconfiguration. Currently, this can be done from userspace with smcinit, a utility that comes with the irda-utils package. It messes with ioports and PCI settings, from userspace. Now with this patch, if we happen to be on one of the known to be faulty laptops, we preconfigure the chip from the driver. Patch from Linus Walleij Signed-off-by: Samuel Ortiz Signed-off-by: David S. Miller commit 45af08be6d120690d379cb8421ebaf9d9f86ba52 tree 5d0105eab9b524e0fa35b3caf9e6c1444e640010 parent cdee5751bf91d02616aaf30a5affef56105e3b79 author Herbert Xu Wed, 05 Apr 2006 22:31:19 -0700 committer David S. Miller Sun, 09 Apr 2006 22:25:29 -0700 [INET]: Use port unreachable instead of proto for tunnels This patch changes GRE and SIT to generate port unreachable instead of protocol unreachable errors when we can't find a matching tunnel for a packet. This removes the ambiguity as to whether the error is caused by no tunnel being found or by the lack of support for the given tunnel type. Signed-off-by: Herbert Xu Signed-off-by: David S. Miller commit cdee5751bf91d02616aaf30a5affef56105e3b79 tree 8a7d6f231dc9de03c7d9bb5b6623bd539900abce parent ad96b485b4224785bcca478cfba02d06c46ee575 author Eric Sesterhenn Wed, 05 Apr 2006 22:28:14 -0700 committer David S. Miller Sun, 09 Apr 2006 22:25:29 -0700 [BLUETOOTH] sco: Possible double free. this fixes coverity bug id #1068. hci_send_sco() frees skb if (skb->len > hdev->sco_mtu). Since it returns a negative error value only in this case, we can directly return here. Signed-off-by: Eric Sesterhenn Signed-off-by: David S. Miller commit ad96b485b4224785bcca478cfba02d06c46ee575 tree 9f5ef069ffef7e02e37d771c23444b6b73d1a6f1 parent e3a5cd9edff9a7a20de3c88c9d479704da98fb85 author Adrian Bunk Wed, 05 Apr 2006 22:21:04 -0700 committer David S. Miller Sun, 09 Apr 2006 22:25:27 -0700 [TG3]: Fix a memory leak. This patch fixes a memory leak (buf wasn't freed) spotted by the Coverity checker. Signed-off-by: Adrian Bunk Signed-off-by: David S. Miller commit e3a5cd9edff9a7a20de3c88c9d479704da98fb85 tree 2667fc69e67a58a49515e56d480ae61b984ab301 parent d938ab44c0c5418bb74a97b422a070e2cdccce22 author Adrian Bunk Wed, 05 Apr 2006 22:19:47 -0700 committer David S. Miller Sun, 09 Apr 2006 22:25:26 -0700 [NET]: Fix an off-by-21-or-49 error. This patch fixes an off-by-21-or-49 error ;-) spotted by the Coverity checker. Signed-off-by: Adrian Bunk Signed-off-by: David S. Miller commit d938ab44c0c5418bb74a97b422a070e2cdccce22 tree 4404cad3bc941be9f25e51a478ba61a94c2c5ed4 parent 50fba2aa7cefa6b0e1768cb350c9e69042320c03 author Randy Dunlap Tue, 04 Apr 2006 20:11:56 -0700 committer David S. Miller Sun, 09 Apr 2006 22:25:25 -0700 [NET] netconsole: set .name in struct console Set .name in netconsole's struct console to identify the struct's owner. Signed-off-by: Randy Dunlap Acked-by: Matt Mackall Signed-off-by: David S. Miller commit 50fba2aa7cefa6b0e1768cb350c9e69042320c03 tree d9d229be1cc489759994e3860e3d2c60e6e6239f parent 2e2f7aefa8a8ba4adb6ecee8cbb43fbe9ca4cc89 author Herbert Xu Tue, 04 Apr 2006 13:50:45 -0700 committer David S. Miller Sun, 09 Apr 2006 22:25:25 -0700 [INET]: Move no-tunnel ICMP error to tunnel4/tunnel6 This patch moves the sending of ICMP messages when there are no IPv4/IPv6 tunnels present to tunnel4/tunnel6 respectively. Please note that for now if xfrm4_tunnel/xfrm6_tunnel is loaded then no ICMP messages will ever be sent. This is similar to how we handle AH/ESP/IPCOMP. This move fixes the bug where we always send an ICMP message when there is no ip6_tunnel device present for a given packet even if it is later handled by IPsec. It also causes ICMP messages to be sent when no IPIP tunnel is present. I've decided to use the "port unreachable" ICMP message over the current value of "address unreachable" (and "protocol unreachable" by GRE) because it is not ambiguous unlike the other ones which can be triggered by other conditions. There seems to be no standard specifying what value must be used so this change should be OK. In fact we should change GRE to use this value as well. Incidentally, this patch also fixes a fairly serious bug in xfrm6_tunnel where we don't check whether the embedded IPv6 header is present before dereferencing it for the inside source address. This patch is inspired by a previous patch by Hugo Santos . Signed-off-by: Herbert Xu Signed-off-by: David S. Miller commit 2e2f7aefa8a8ba4adb6ecee8cbb43fbe9ca4cc89 tree 891921c05dbf5ac2436473d77b8dbfda91a1b9bc parent 550e29bc96e6f1ced2bca82dace197b009434367 author Patrick McHardy Tue, 04 Apr 2006 13:42:35 -0700 committer David S. Miller Sun, 09 Apr 2006 22:25:23 -0700 [NETFILTER]: Fix fragmentation issues with bridge netfilter The conntrack code doesn't do re-fragmentation of defragmented packets anymore but relies on fragmentation in the IP layer. Purely bridged packets don't pass through the IP layer, so the bridge netfilter code needs to take care of fragmentation itself. Signed-off-by: Patrick McHardy Signed-off-by: David S. Miller commit 550e29bc96e6f1ced2bca82dace197b009434367 tree 423cb5460e1a25eff3d578003252b2de1b8ccaf5 parent 8bf4b8a1083694d5aac292f92705ddd3aec29be6 author Robert Olsson Tue, 04 Apr 2006 12:53:35 -0700 committer David S. Miller Sun, 09 Apr 2006 22:25:23 -0700 [FIB_TRIE]: Fix leaf freeing. Seems like leaf (end-nodes) has been freed by __tnode_free_rcu and not by __leaf_free_rcu. This fixes the problem. Only tnode_free is now used which checks for appropriate node type. free_leaf can be removed. Signed-off-by: Robert Olsson Signed-off-by: David S. Miller commit 8bf4b8a1083694d5aac292f92705ddd3aec29be6 tree a8bbf0bb32b7e286659eae12326c54671430560f parent 67644726317a8274be4a3d0ef85b9ccebaa90304 author Herbert Xu Tue, 04 Apr 2006 12:51:05 -0700 committer David S. Miller Sun, 09 Apr 2006 22:25:22 -0700 [IPSEC]: Check x->encap before dereferencing it We need to dereference x->encap before dereferencing it for encap_type. If it's absent then the encap_type is zero. Signed-off-by: Herbert Xu Signed-off-by: David S. Miller commit 67644726317a8274be4a3d0ef85b9ccebaa90304 tree c2bcf873d19d1b18d65e4f5d6d5c3cd613e9cb13 parent 66004a6ca23f2a2408b32cbe27fda0389fb8f9dc author Dave Jones Sun, 02 Apr 2006 23:34:19 -0700 committer Linus Torvalds Sun, 09 Apr 2006 12:35:53 -0700 [SELINUX] Fix build after ipsec decap state changes. security/selinux/xfrm.c: In function 'selinux_socket_getpeer_dgram': security/selinux/xfrm.c:284: error: 'struct sec_path' has no member named 'x' security/selinux/xfrm.c: In function 'selinux_xfrm_sock_rcv_skb': security/selinux/xfrm.c:317: error: 'struct sec_path' has no member named 'x' Signed-off-by: Dave Jones Signed-off-by: David S. Miller Signed-off-by: Linus Torvalds commit 66004a6ca23f2a2408b32cbe27fda0389fb8f9dc tree 7f11359eec8c511e5fcf7340c93f9a84a2bad0e2 parent b8feb47f992d314c956add15c1118430120635bb author Linus Torvalds Sun, 09 Apr 2006 12:14:02 -0700 committer Linus Torvalds Sun, 09 Apr 2006 12:14:02 -0700 Move request_standard_resources() back to before PCI probing This effectively undoes the PCI resource allocation changes done in commit b408cbc704352eccee301e1103b23203ba1c3a0e, but leaves the cleanups of that commit in place. We're going back to marking the resources reported by e820 busy _before_ doing PCI probing, so that any PCI resource that clashes with the BIOS- reported memory map will be reloacted to a non-clashing area. The reason? Larry Finger reports that his laptop has the cardbus controller set up by the BIOS so that it conflicts with the e820 memory map, and needs to be relocated. See http://bugzilla.kernel.org/show_bug.cgi?id=6337 for more details. We'll have to work out how to handle the fbcon problem that caused that commit in the first place in some other way. Cc: Ivan Kokshaysky Cc: Greg Kroah-Hartman Cc: Antonino A. Daplas Cc: Tested-by: Larry Finger Signed-off-by: Linus Torvalds commit b8feb47f992d314c956add15c1118430120635bb tree fa134a28d0696edbe76bb3191ac00969440c7398 parent 67d53ea5a3d42aadeb1584e757ca4660c0e8a810 author Andi Kleen Fri, 07 Apr 2006 19:50:34 +0200 committer Linus Torvalds Sun, 09 Apr 2006 11:53:53 -0700 [PATCH] x86_64: Update 32-bit system call table Signed-off-by: Andi Kleen Signed-off-by: Linus Torvalds commit 67d53ea5a3d42aadeb1584e757ca4660c0e8a810 tree 054906bb672c6faad287ede5b34c53d56afdc629 parent bbd3aff89d4b34ef17a748e4c001ecc5b43e3e55 author Andi Kleen Fri, 07 Apr 2006 19:50:31 +0200 committer Linus Torvalds Sun, 09 Apr 2006 11:53:53 -0700 [PATCH] x86_64: Eliminate IA32_NR_syscalls define Or rather compute it based on the table length automatically. This also has the intended side effect of not warning for new system calls anymore. Signed-off-by: Andi Kleen Signed-off-by: Linus Torvalds commit bbd3aff89d4b34ef17a748e4c001ecc5b43e3e55 tree 26e9521b03e9cff515a96774cf3ac67c9b612bce parent 97c2803c9c694cafbd9f5e43a25903e0abf25188 author Sam Ravnborg Fri, 07 Apr 2006 19:50:28 +0200 committer Linus Torvalds Sun, 09 Apr 2006 11:53:53 -0700 [PATCH] x86_64: fix CONFIG_REORDER Fix CONFIG_REORDER. The value of cflags-y was assined to CFLAGS before cflags-y was assigned the value used for CONFIG_REORDER. Use cflags-y for all CFLAGS options in the Makefile to avoid this happening again. Signed-off-by: Sam Ravnborg Signed-off-by: Andi Kleen Signed-off-by: Linus Torvalds commit 97c2803c9c694cafbd9f5e43a25903e0abf25188 tree e70f35adaae6c95cf5e4557a92ccaa3f827ae2d3 parent e48c4729d23a026f3711d5e36add5cce894b4913 author John Blackwood Fri, 07 Apr 2006 19:50:25 +0200 committer Linus Torvalds Sun, 09 Apr 2006 11:53:53 -0700 [PATCH] x86_64: Plug GS leak in arch_prctl() In linux-2.6.16, we have noticed a problem where the gs base value returned from an arch_prtcl(ARCH_GET_GS, ...) call will be incorrect if: - the current/calling task has NOT set its own gs base yet to a non-zero value, - some other task that ran on the same processor previously set their own gs base to a non-zero value. In this situation, the ARCH_GET_GS code will read and return the MSR_KERNEL_GS_BASE msr register. However, since the __switch_to() code does NOT load/zero the MSR_KERNEL_GS_BASE register when the task that is switched IN has a zero next->gs value, the caller of arch_prctl(ARCH_GET_GS, ...) will get back the value of some previous tasks's gs base value instead of 0. Change the arch_prctl() ARCH_GET_GS code to only read and return the MSR_KERNEL_GS_BASE msr register if the 'gs' register of the calling task is non-zero. Side note: Since in addition to using arch_prctl(ARCH_SET_GS, ...), a task can also setup a gs base value by using modify_ldt() and write an index value into 'gs' from user space, the patch below reads 'gs' instead of using thread.gs, since in the modify_ldt() case, the thread.gs value will be 0, and incorrect value would be returned (the task->thread.gs value). When the user has not set its own gs base value and the 'gs' register is zero, then the MSR_KERNEL_GS_BASE register will not be read and a value of zero will be returned by reading and returning 'task->thread.gs'. The first patch shown below is an attempt at implementing this approach. Signed-off-by: Andi Kleen Signed-off-by: Linus Torvalds commit e48c4729d23a026f3711d5e36add5cce894b4913 tree 9f5556934bcba4d5ced8f06d0215a7534b3a8bbc parent b20367a6c2a0cd937cb1f0a8cf848f1402fef99c author Andi Kleen Fri, 07 Apr 2006 19:50:21 +0200 committer Linus Torvalds Sun, 09 Apr 2006 11:53:53 -0700 [PATCH] i386: Remove printk about reboot fixups at reboot Printk doesn't have any value Signed-off-by: Andi Kleen Signed-off-by: Linus Torvalds commit b20367a6c2a0cd937cb1f0a8cf848f1402fef99c tree 8624096baed40f8f89e757b2d170a7b4d1844575 parent 49c93e84d8b2d602a07c302c7e3cd4fa09095fbb author Jordan Hargrave Fri, 07 Apr 2006 19:50:18 +0200 committer Linus Torvalds Sun, 09 Apr 2006 11:53:53 -0700 [PATCH] x86_64: Fix drift with HPET timer enabled If the HPET timer is enabled, the clock can drift by ~3 seconds a day. This is due to the HPET timer not being initialized with the correct setting (still using PIT count). If HZ changes, this drift can become even more pronounced. HPET patch initializes tick_nsec with correct tick_nsec settings for HPET timer. Vojtech comments: "It's not entirely correct (it assumes the HPET ticks totally exactly), but it's significantly better than assuming the PIT error there." Signed-off-by: Andi Kleen Signed-off-by: Linus Torvalds commit 49c93e84d8b2d602a07c302c7e3cd4fa09095fbb tree a59d0bb7a9f1df9f3187e466e3937ea9ffd83343 parent 8c30b1a74aed4041f183e183a149b7dfbdc6c20e author Andi Kleen Fri, 07 Apr 2006 19:50:15 +0200 committer Linus Torvalds Sun, 09 Apr 2006 11:53:52 -0700 [PATCH] i386/x86-64: Return defined error value for bad PCI config space accesses Mostly to get better handling when a extended config space access has to fallback to Type1. Cc: gregkh@suse.de Signed-off-by: Andi Kleen Signed-off-by: Linus Torvalds commit 8c30b1a74aed4041f183e183a149b7dfbdc6c20e tree 1476500ffdefa842c632e960196fefdadb04ca04 parent e405d067298b2b960bf20318e91ed842157c65bc author Andi Kleen Fri, 07 Apr 2006 19:50:12 +0200 committer Linus Torvalds Sun, 09 Apr 2006 11:53:52 -0700 [PATCH] i386/x86_64: Check if MCFG works for the first 16 busses Previously only the first bus would be checked against Type 1. Why 16? Checking all would need too much memory and we can assume that systems with more than 16 busses have better than average quality BIOS. This is an additional defense against bad MCFG tables. Signed-off-by: Andi Kleen Signed-off-by: Linus Torvalds commit e405d067298b2b960bf20318e91ed842157c65bc tree edb9bf3a90c70e7b7d490504f7ea695b39aa6a08 parent 3d34ee6891e274dfb6a22930546d37738cdbe9c4 author Ravikiran G Thirumalai Fri, 07 Apr 2006 19:50:09 +0200 committer Linus Torvalds Sun, 09 Apr 2006 11:53:52 -0700 [PATCH] x86_64: Fixup read_mostly section on internode cache line size for vSMP Fixup the read mostly section to start at internode cacheline boundary. Signed-off-by: Ravikiran Thirumalai Signed-off-by: Shai Fultheim Signed-off-by: Andi Kleen Signed-off-by: Linus Torvalds commit 3d34ee6891e274dfb6a22930546d37738cdbe9c4 tree 46b5ea716446d598bfb5680af05aac4aed5c6284 parent ac04dcaf6f567307fbeef9c3c1fff35280e53f02 author Andi Kleen Fri, 07 Apr 2006 19:50:06 +0200 committer Linus Torvalds Sun, 09 Apr 2006 11:53:52 -0700 [PATCH] x86_64: Don't return error for HPET initialization in initcall Signed-off-by: Andi Kleen Signed-off-by: Linus Torvalds commit ac04dcaf6f567307fbeef9c3c1fff35280e53f02 tree 0af1ec91c2cfda958e2320aa4030df5c312c91e4 parent 7bf36bbc5e0c09271f9efe22162f8cc3f8ebd3d2 author Andi Kleen Fri, 07 Apr 2006 19:50:03 +0200 committer Linus Torvalds Sun, 09 Apr 2006 11:53:52 -0700 [PATCH] x86_64: Don't export strlen twice Fix WARNING: vmlinux: 'strlen' exported twice. Previous export was in vmlinux Reported by Mats Johannesson Signed-off-by: Andi Kleen Signed-off-by: Linus Torvalds commit 7bf36bbc5e0c09271f9efe22162f8cc3f8ebd3d2 tree 9e97e2f5774824f0e2fbff1d4e7c49e9938285f5 parent 553f265fe883a23502ee351845f09334790f18b8 author Andi Kleen Fri, 07 Apr 2006 19:50:00 +0200 committer Linus Torvalds Sun, 09 Apr 2006 11:53:52 -0700 [PATCH] x86_64: When user could have changed RIP always force IRET Intel EM64T CPUs handle uncanonical return addresses differently from AMD CPUs. The exception is reported in the SYSRET, not the next instruction. This leads to the kernel exception handler running on the user stack with the wrong GS because the kernel didn't expect exceptions on this instruction. This version of the patch has the teething problems that plagued an earlier version fixed. This is CVE-2006-0744 Thanks to Ernie Petrides and Asit B. Mallick for analysis and initial patches. Signed-off-by: Andi Kleen Signed-off-by: Linus Torvalds commit 553f265fe883a23502ee351845f09334790f18b8 tree 1fd60e72d7d5cbed34812eb6763899d2bd37c152 parent be56db6186999a8571ae480cf2b929578f6dfd68 author Andi Kleen Fri, 07 Apr 2006 19:49:57 +0200 committer Linus Torvalds Sun, 09 Apr 2006 11:53:52 -0700 [PATCH] x86_64: Don't run NMI watchdog during machine checks Machine checks can stall the machine for a long time and it's not good to trigger the nmi watchdog during that. Signed-off-by: Andi Kleen Signed-off-by: Linus Torvalds commit be56db6186999a8571ae480cf2b929578f6dfd68 tree df0760d15a76b9615c02f37ad5941fd5b52c5658 parent 4211a30349e8d2b724cfb4ce2584604f5e59c299 author Dave Hansen Fri, 07 Apr 2006 19:49:54 +0200 committer Linus Torvalds Sun, 09 Apr 2006 11:53:51 -0700 [PATCH] x86_64: extra NODES_SHIFT definition The generic linux/numa.h file defines NODES_SHIFT to 0 in case the architecture did not. Every architecture which has a NUMA config option defines NODES_SHIFT in its asm-$ARCH headers, but only if NUMA is enabled, except for x86_64. This should make it like all the rest. Signed-off-by: Dave Hansen Signed-off-by: Andi Kleen Signed-off-by: Linus Torvalds commit 4211a30349e8d2b724cfb4ce2584604f5e59c299 tree 59fdb0b812156bbff2266cc51b22d9d608898ecf parent d7fa706ce2c29cb751c15ca00f3aa7b223e3c9f0 author Jacob Shin Fri, 07 Apr 2006 19:49:51 +0200 committer Linus Torvalds Sun, 09 Apr 2006 11:53:51 -0700 [PATCH] x86_64: Proper null pointer check in powernow_k8_get This prevents crashes on dual core system when enough ticks are lost. Replaces earlier patch by me. Cc: Dave Jones Signed-off-by: Thomas Renninger Signed-off-by: Andi Kleen Signed-off-by: Linus Torvalds commit d7fa706ce2c29cb751c15ca00f3aa7b223e3c9f0 tree 0e19431741ca192c8c98d6f06edc56e0d4be08db parent 95d769aaf47abfc77b600631403ff5af6c990cff author Andi Kleen Fri, 07 Apr 2006 19:49:48 +0200 committer Linus Torvalds Sun, 09 Apr 2006 11:53:51 -0700 [PATCH] x86_64: Revert earlier powernow-k8 change Signed-off-by: Andi Kleen Signed-off-by: Linus Torvalds commit 95d769aaf47abfc77b600631403ff5af6c990cff tree 738fff854613a086e7c1ad04074fa596b8554760 parent d1530d82e02fd96d4634a6d6f6538c8b778c43af author Andi Kleen Fri, 07 Apr 2006 19:49:45 +0200 committer Linus Torvalds Sun, 09 Apr 2006 11:53:51 -0700 [PATCH] i386: Consolidate modern APIC handling AMD systems have a modern APIC that supports 8 bit IDs, but don't have a XAPIC version number. Add a new "modern_apic" subfunction that handles this correctly and use it (nearly) everywhere where XAPIC is tested for. I removed one wart: the code specified that external APICs would use an 8bit APIC ID. But I checked a real 82093 data sheet and it says clearly that they only use 4bit. So I removed this special case since it would a bit awkward to implement now. I removed the valid APIC tests in mptable parsing completely. On any modern system they only check against the full field width (8bit) anyways and are no-ops. This also fixes them doing the wrong thing on >8 core Opterons. This makes i386 boot again on 16 core Opterons. Cc: Ingo Molnar Signed-off-by: Andi Kleen Signed-off-by: Linus Torvalds commit d1530d82e02fd96d4634a6d6f6538c8b778c43af tree f825ae536b1ee15208b0917de54e42e528b59be6 parent d3b6a349d233aecf2c52f7f4c150ca09f684f2d8 author Andi Kleen Fri, 07 Apr 2006 19:49:42 +0200 committer Linus Torvalds Sun, 09 Apr 2006 11:53:51 -0700 [PATCH] x86_64: Clear APIC feature bit when local APIC is disabled Needed for other checks later in ACPI. Pointed out by Len Brown Signed-off-by: Andi Kleen Signed-off-by: Linus Torvalds commit d3b6a349d233aecf2c52f7f4c150ca09f684f2d8 tree 3ab86b3ffc1dbe2eaa69c5bb041644975df60da7 parent ec0f08eeea6ac1d8c925f47e3677e4c985fd8f63 author Andi Kleen Fri, 07 Apr 2006 19:49:39 +0200 committer Linus Torvalds Sun, 09 Apr 2006 11:53:51 -0700 [PATCH] x86-64/i386: Don't process APICs/IO-APICs in ACPI when APIC is disabled. When nolapic was passed or the local APIC was disabled for another reason ACPI would still parse the IO-APICs until these were explicitely disabled with noapic. Usually this resulted in a non booting configuration unless "nolapic noapic" was used. I also disabled the local APIC parsing in this case, although that's only cosmetic (suppresses a few printks) This hopefully makes nolapic work in all cases. Signed-off-by: Andi Kleen Signed-off-by: Linus Torvalds commit ec0f08eeea6ac1d8c925f47e3677e4c985fd8f63 tree 053ede4e6c6648dc8d927a2ad17ef5e03069b3a2 parent fa47dd0ba303599f8adf8d8336ed2fb74efc47c5 author Andi Kleen Fri, 07 Apr 2006 19:49:36 +0200 committer Linus Torvalds Sun, 09 Apr 2006 11:53:51 -0700 [PATCH] x86_64: Don't sanity check Type 1 PCI bus access on newer systems Horus systems don't have anything on bus 0 which makes the Type 1 sanity checks fail. Use the DMI BIOS year to check for newer systems and always assume Type 1 works on them. I used 2001 as an pretty arbitary cutoff year. Cc: gregkh@suse.de Cc: Navin Boppuri Signed-off-by: Andi Kleen Signed-off-by: Linus Torvalds commit fa47dd0ba303599f8adf8d8336ed2fb74efc47c5 tree 5aad31f503964dafb047f15bf327e99e5ddbd5c7 parent 946f2ee5c7312e8acac4f3ab6629e7e2d36a3646 author Andi Kleen Fri, 07 Apr 2006 19:49:33 +0200 committer Linus Torvalds Sun, 09 Apr 2006 11:53:51 -0700 [PATCH] x86_64: Fix compilation with CONFIG_PCI=n / allnoconfig Signed-off-by: Andi Kleen Signed-off-by: Linus Torvalds commit 946f2ee5c7312e8acac4f3ab6629e7e2d36a3646 tree 0821a2f3f59a089b73d33f64f59331460e20355a parent 952223683ec989e86328c24808fdb962c4dbeb0a author Arjan van de Ven Fri, 07 Apr 2006 19:49:30 +0200 committer Linus Torvalds Sun, 09 Apr 2006 11:53:51 -0700 [PATCH] i386/x86-64: Check that MCFG points to an e820 reserved area This patch introduces a user for the e820_all_mapped function: There have been several machines that don't have a working MMCONFIG, often because of a buggy MCFG table in the ACPI bios. This patch adds a simple sanity check that detects a whole bunch of these cases, and when it detects it, linux now boots rather than crash-and-burns. The accuracy of this detection can in principle be improved if there was a "is this entire range in e820 with THIS attribute", but no such function exist and the complexity needed for this is not really worth it; this simple check already catches most cases anyway. Signed-off-by: Arjan van de Ven Signed-off-by: Andi Kleen Signed-off-by: Linus Torvalds commit 952223683ec989e86328c24808fdb962c4dbeb0a tree 0c7473d4469cba883bf880bbaa04900960806742 parent eee5a9fa63c97366cdea6ab3aa2ed9e3601812d0 author Arjan van de Ven Fri, 07 Apr 2006 19:49:27 +0200 committer Linus Torvalds Sun, 09 Apr 2006 11:53:50 -0700 [PATCH] x86_64: Introduce e820_all_mapped Introduce a e820_all_mapped() function which checks if the entire range is mapped with type. This is done by moving the local start variable to the end of each known-good region; if at the end of the function the start address is still before end, there must be a part that's not of the correct type; otherwise it's a good region. Signed-off-by: Arjan van de Ven Signed-off-by: Andi Kleen Signed-off-by: Linus Torvalds commit eee5a9fa63c97366cdea6ab3aa2ed9e3601812d0 tree b01876c5417f52173e9ab3d76c124df2042c9f62 parent a8062231d80239cf3405982858c02aea21a6066a author Arjan van de Ven Fri, 07 Apr 2006 19:49:24 +0200 committer Linus Torvalds Sun, 09 Apr 2006 11:53:17 -0700 [PATCH] x86_64: Rename e820_mapped to e820_any_mapped Rename e820_mapped to e820_any_mapped since it tests if any part of the range is mapped according to the type. Later steps will introduce e820_all_mapped which will check if the entire range is mapped with the type. Both have their merit. Signed-off-by: Arjan van de Ven Signed-off-by: Andi Kleen Signed-off-by: Linus Torvalds commit a8062231d80239cf3405982858c02aea21a6066a tree 0576493fa99cda91069fe3b67c19bd024858e69e parent 68a3a7feb08f960095072f28ec20f7900793c506 author Andi Kleen Fri, 07 Apr 2006 19:49:21 +0200 committer Linus Torvalds Sun, 09 Apr 2006 11:53:16 -0700 [PATCH] x86_64: Handle empty PXMs that only contain hotplug memory The node setup code would try to allocate the node metadata in the node itself, but that fails if there is no memory in there. This can happen with memory hotplug when the hotplug area defines an so far empty node. Now use bootmem to try to allocate the mem_map in other nodes. And if it fails don't panic, but just ignore the node. To make this work I added a new __alloc_bootmem_nopanic function that does what its name implies. TBD should try to use nearby nodes here. Currently we just use any. It's hard to do it better because bootmem doesn't have proper fallback lists yet. Signed-off-by: Andi Kleen Signed-off-by: Linus Torvalds commit 68a3a7feb08f960095072f28ec20f7900793c506 tree 1d458822fd4414997b6f12ad8a915f785d7e730f parent 9d99aaa31f5994d1923c3713ce9144c4c42332e1 author Andi Kleen Fri, 07 Apr 2006 19:49:18 +0200 committer Linus Torvalds Sun, 09 Apr 2006 11:53:16 -0700 [PATCH] x86_64: Reserve SRAT hotadd memory on x86-64 From: Keith Mannthey, Andi Kleen Implement memory hotadd without sparsemem. The memory in the SRAT hotadd area is just preserved instead and can be activated later. There are a few restrictions: - Only one continuous hotadd area allowed per node The main problem is dealing with the many buggy SRAT tables that are out there. The strategy here is to reject anything suspicious. Originally from Keith Mannthey, with several hacks and changes by AK and also contributions from Andrew Morton [ TBD: Problems pointed out by KAMEZAWA Hiroyuki : 1) Goto's rebuild_zonelist patch will not work if CONFIG_MEMORY_HOTPLUG=n. Rebuilding zonelist is necessary when the system has just memory < 4G at boot, and hot add memory > 4G. because x86_64 has DMA32, ZONE_NORAML is not included into zonelist at boot time if system doesn't have memory >4G at boot. [AK: should just force the higher zones at boot time when SRAT tells us] 2) zone and node's spanned_pages and present_pages are not incremented. They should be. For example, our server (ia64/Fujitsu PrimeQuest) can equip memory from 4G to 1T(maybe 2T in future), and SRAT will *always* say we have possible 1T +memory. (Microsoft requires "write all possible memory in SRAT") When we reserve memmap for possible 1T memory, Linux will not work well in +minimum 4G configuraion ;) [AK: needs limiting to 5-10% of max memory] ] Signed-off-by: Andi Kleen Signed-off-by: Linus Torvalds commit 9d99aaa31f5994d1923c3713ce9144c4c42332e1 tree ae608593ca196dd6493cccbdfc1b8dd098e91ee8 parent 805e8c03c9ea9bdb402a36341e02ec24825d5417 author Andi Kleen Fri, 07 Apr 2006 19:49:15 +0200 committer Linus Torvalds Sun, 09 Apr 2006 11:53:16 -0700 [PATCH] x86_64: Support memory hotadd without sparsemem Memory hotadd doesn't need SPARSEMEM, but can be handled by just preallocating mem_maps. This only needs some untangling of ifdefs to enable the necessary code even without SPARSEMEM. Originally from Keith Mannthey, hacked by AK. Signed-off-by: Andi Kleen Signed-off-by: Linus Torvalds commit 805e8c03c9ea9bdb402a36341e02ec24825d5417 tree c7047d0e3b2e72a7885bfce80369c25c89936821 parent 903fcc608e9f531749024172277dc2fd15d5a587 author Andi Kleen Fri, 07 Apr 2006 19:49:12 +0200 committer Linus Torvalds Sun, 09 Apr 2006 11:53:16 -0700 [PATCH] x86_64: Clean up execve path Just call IRET always, no need for any special cases. Needed for the next bug fix. Signed-off-by: Andi Kleen Signed-off-by: Linus Torvalds commit 903fcc608e9f531749024172277dc2fd15d5a587 tree 6844416b377a7f4f7aaf29eb53ed140afa47699e parent 6246b6128bbe34d0752f119cf7c5111c85fe481d author Andi Kleen Fri, 07 Apr 2006 19:49:09 +0200 committer Linus Torvalds Sun, 09 Apr 2006 11:53:16 -0700 [PATCH] x86_64: Update defconfig Signed-off-by: Andi Kleen Signed-off-by: Linus Torvalds