[linux] 02/04: Update to 4.8.4

debian-kernel at lists.debian.org debian-kernel at lists.debian.org
Sun Oct 23 03:47:51 UTC 2016


This is an automated email from the git hooks/post-receive script.

benh pushed a commit to branch master
in repository linux.

commit bc7a3c1c037a42a147914ad677178f83707f59e7
Author: Ben Hutchings <ben at decadent.org.uk>
Date:   Sun Oct 23 04:37:22 2016 +0100

    Update to 4.8.4
    
    [rt] Drop fixes included in 4.8.4
---
 debian/changelog                                   |   5 +-
 ...ckdep-annotation-in-add_transaction_credi.patch |  65 -------
 ...don-t-plant-shadow-entries-without-radix-.patch | 186 ---------------------
 ...fix-mapping-nrpages-double-accounting-in-.patch |  41 -----
 debian/patches/series-rt                           |   3 -
 5 files changed, 4 insertions(+), 296 deletions(-)

diff --git a/debian/changelog b/debian/changelog
index 8f5ff8a..3955988 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,8 +1,11 @@
-linux (4.8.1-1~exp1) UNRELEASED; urgency=medium
+linux (4.8.4-1~exp1) UNRELEASED; urgency=medium
 
   * New upstream release: https://kernelnewbies.org/Linux_4.8
   * New upstream stable update:
     https://www.kernel.org/pub/linux/kernel/v4.x/ChangeLog-4.8.1
+    https://www.kernel.org/pub/linux/kernel/v4.x/ChangeLog-4.8.2
+    https://www.kernel.org/pub/linux/kernel/v4.x/ChangeLog-4.8.3
+    https://www.kernel.org/pub/linux/kernel/v4.x/ChangeLog-4.8.4
 
   [ Ben Hutchings ]
   * [amd64] Enable LEGACY_VSYSCALL_NONE instead of LEGACY_VSYSCALL_EMULATE.
diff --git a/debian/patches/features/all/rt/jbd2-Fix-lockdep-annotation-in-add_transaction_credi.patch b/debian/patches/features/all/rt/jbd2-Fix-lockdep-annotation-in-add_transaction_credi.patch
deleted file mode 100644
index 5778c08..0000000
--- a/debian/patches/features/all/rt/jbd2-Fix-lockdep-annotation-in-add_transaction_credi.patch
+++ /dev/null
@@ -1,65 +0,0 @@
-From: Jan Kara <jack at suse.cz>
-Date: Mon, 19 Sep 2016 14:30:43 +0200
-Subject: [PATCH] jbd2: Fix lockdep annotation in add_transaction_credits()
-Origin: https://www.kernel.org/pub/linux/kernel/projects/rt/4.8/older/patches-4.8-rt1.tar.xz
-
-Thomas has reported a lockdep splat hitting in
-add_transaction_credits(). The problem is that that function calls
-jbd2_might_wait_for_commit() while holding j_state_lock which is wrong
-(we do not really wait for transaction commit while holding that lock).
-
-Fix the problem by moving jbd2_might_wait_for_commit() into places where
-we are ready to wait for transaction commit and thus j_state_lock is
-unlocked.
-
-Fixes: 1eaa566d368b214d99cbb973647c1b0b8102a9ae
-Reported-by: Thomas Gleixner <tglx at linutronix.de>
-Signed-off-by: Jan Kara <jack at suse.cz>
-Signed-off-by: Sebastian Andrzej Siewior <bigeasy at linutronix.de>
----
- fs/jbd2/transaction.c |    6 ++++--
- 1 file changed, 4 insertions(+), 2 deletions(-)
-
---- a/fs/jbd2/transaction.c
-+++ b/fs/jbd2/transaction.c
-@@ -159,6 +159,7 @@ static void wait_transaction_locked(jour
- 	read_unlock(&journal->j_state_lock);
- 	if (need_to_start)
- 		jbd2_log_start_commit(journal, tid);
-+	jbd2_might_wait_for_commit(journal);
- 	schedule();
- 	finish_wait(&journal->j_wait_transaction_locked, &wait);
- }
-@@ -182,8 +183,6 @@ static int add_transaction_credits(journ
- 	int needed;
- 	int total = blocks + rsv_blocks;
- 
--	jbd2_might_wait_for_commit(journal);
--
- 	/*
- 	 * If the current transaction is locked down for commit, wait
- 	 * for the lock to be released.
-@@ -214,6 +213,7 @@ static int add_transaction_credits(journ
- 		if (atomic_read(&journal->j_reserved_credits) + total >
- 		    journal->j_max_transaction_buffers) {
- 			read_unlock(&journal->j_state_lock);
-+			jbd2_might_wait_for_commit(journal);
- 			wait_event(journal->j_wait_reserved,
- 				   atomic_read(&journal->j_reserved_credits) + total <=
- 				   journal->j_max_transaction_buffers);
-@@ -238,6 +238,7 @@ static int add_transaction_credits(journ
- 	if (jbd2_log_space_left(journal) < jbd2_space_needed(journal)) {
- 		atomic_sub(total, &t->t_outstanding_credits);
- 		read_unlock(&journal->j_state_lock);
-+		jbd2_might_wait_for_commit(journal);
- 		write_lock(&journal->j_state_lock);
- 		if (jbd2_log_space_left(journal) < jbd2_space_needed(journal))
- 			__jbd2_log_wait_for_space(journal);
-@@ -255,6 +256,7 @@ static int add_transaction_credits(journ
- 		sub_reserved_credits(journal, rsv_blocks);
- 		atomic_sub(total, &t->t_outstanding_credits);
- 		read_unlock(&journal->j_state_lock);
-+		jbd2_might_wait_for_commit(journal);
- 		wait_event(journal->j_wait_reserved,
- 			 atomic_read(&journal->j_reserved_credits) + rsv_blocks
- 			 <= journal->j_max_transaction_buffers / 2);
diff --git a/debian/patches/features/all/rt/mm-filemap-don-t-plant-shadow-entries-without-radix-.patch b/debian/patches/features/all/rt/mm-filemap-don-t-plant-shadow-entries-without-radix-.patch
deleted file mode 100644
index bc19191..0000000
--- a/debian/patches/features/all/rt/mm-filemap-don-t-plant-shadow-entries-without-radix-.patch
+++ /dev/null
@@ -1,186 +0,0 @@
-From: Johannes Weiner <hannes at cmpxchg.org>
-Date: Tue, 4 Oct 2016 22:02:08 +0200
-Subject: [PATCH] mm: filemap: don't plant shadow entries without radix tree
- node
-Origin: https://www.kernel.org/pub/linux/kernel/projects/rt/4.8/older/patches-4.8-rt1.tar.xz
-
-Upstream commit d3798ae8c6f3767c726403c2ca6ecc317752c9dd
-
-When the underflow checks were added to workingset_node_shadow_dec(),
-they triggered immediately:
-
-  kernel BUG at ./include/linux/swap.h:276!
-  invalid opcode: 0000 [#1] SMP
-  Modules linked in: isofs usb_storage fuse xt_CHECKSUM ipt_MASQUERADE nf_nat_masquerade_ipv4 tun nf_conntrack_netbios_ns nf_conntrack_broadcast ip6t_REJECT nf_reject_ipv6
-   soundcore wmi acpi_als pinctrl_sunrisepoint kfifo_buf tpm_tis industrialio acpi_pad pinctrl_intel tpm_tis_core tpm nfsd auth_rpcgss nfs_acl lockd grace sunrpc dm_crypt
-  CPU: 0 PID: 20929 Comm: blkid Not tainted 4.8.0-rc8-00087-gbe67d60ba944 #1
-  Hardware name: System manufacturer System Product Name/Z170-K, BIOS 1803 05/06/2016
-  task: ffff8faa93ecd940 task.stack: ffff8faa7f478000
-  RIP: page_cache_tree_insert+0xf1/0x100
-  Call Trace:
-    __add_to_page_cache_locked+0x12e/0x270
-    add_to_page_cache_lru+0x4e/0xe0
-    mpage_readpages+0x112/0x1d0
-    blkdev_readpages+0x1d/0x20
-    __do_page_cache_readahead+0x1ad/0x290
-    force_page_cache_readahead+0xaa/0x100
-    page_cache_sync_readahead+0x3f/0x50
-    generic_file_read_iter+0x5af/0x740
-    blkdev_read_iter+0x35/0x40
-    __vfs_read+0xe1/0x130
-    vfs_read+0x96/0x130
-    SyS_read+0x55/0xc0
-    entry_SYSCALL_64_fastpath+0x13/0x8f
-  Code: 03 00 48 8b 5d d8 65 48 33 1c 25 28 00 00 00 44 89 e8 75 19 48 83 c4 18 5b 41 5c 41 5d 41 5e 5d c3 0f 0b 41 bd ef ff ff ff eb d7 <0f> 0b e8 88 68 ef ff 0f 1f 84 00
-  RIP  page_cache_tree_insert+0xf1/0x100
-
-This is a long-standing bug in the way shadow entries are accounted in
-the radix tree nodes. The shrinker needs to know when radix tree nodes
-contain only shadow entries, no pages, so node->count is split in half
-to count shadows in the upper bits and pages in the lower bits.
-
-Unfortunately, the radix tree implementation doesn't know of this and
-assumes all entries are in node->count. When there is a shadow entry
-directly in root->rnode and the tree is later extended, the radix tree
-implementation will copy that entry into the new node and and bump its
-node->count, i.e. increases the page count bits. Once the shadow gets
-removed and we subtract from the upper counter, node->count underflows
-and triggers the warning. Afterwards, without node->count reaching 0
-again, the radix tree node is leaked.
-
-Limit shadow entries to when we have actual radix tree nodes and can
-count them properly. That means we lose the ability to detect refaults
-from files that had only the first page faulted in at eviction time.
-
-Fixes: 449dd6984d0e ("mm: keep page cache radix tree nodes in check")
-Signed-off-by: Johannes Weiner <hannes at cmpxchg.org>
-Reported-and-tested-by: Linus Torvalds <torvalds at linux-foundation.org>
-Reviewed-by: Jan Kara <jack at suse.cz>
-Cc: Andrew Morton <akpm at linux-foundation.org>
-Cc: stable at vger.kernel.org
-Signed-off-by: Linus Torvalds <torvalds at linux-foundation.org>
----
- include/linux/radix-tree.h |    6 ++---
- lib/radix-tree.c           |   14 ++-----------
- mm/filemap.c               |   46 +++++++++++++++++++++++++++++----------------
- 3 files changed, 36 insertions(+), 30 deletions(-)
-
---- a/include/linux/radix-tree.h
-+++ b/include/linux/radix-tree.h
-@@ -280,9 +280,9 @@ bool __radix_tree_delete_node(struct rad
- 			      struct radix_tree_node *node);
- void *radix_tree_delete_item(struct radix_tree_root *, unsigned long, void *);
- void *radix_tree_delete(struct radix_tree_root *, unsigned long);
--struct radix_tree_node *radix_tree_replace_clear_tags(
--				struct radix_tree_root *root,
--				unsigned long index, void *entry);
-+void radix_tree_clear_tags(struct radix_tree_root *root,
-+			   struct radix_tree_node *node,
-+			   void **slot);
- unsigned int radix_tree_gang_lookup(struct radix_tree_root *root,
- 			void **results, unsigned long first_index,
- 			unsigned int max_items);
---- a/lib/radix-tree.c
-+++ b/lib/radix-tree.c
-@@ -1583,15 +1583,10 @@ void *radix_tree_delete(struct radix_tre
- }
- EXPORT_SYMBOL(radix_tree_delete);
- 
--struct radix_tree_node *radix_tree_replace_clear_tags(
--			struct radix_tree_root *root,
--			unsigned long index, void *entry)
-+void radix_tree_clear_tags(struct radix_tree_root *root,
-+			   struct radix_tree_node *node,
-+			   void **slot)
- {
--	struct radix_tree_node *node;
--	void **slot;
--
--	__radix_tree_lookup(root, index, &node, &slot);
--
- 	if (node) {
- 		unsigned int tag, offset = get_slot_offset(node, slot);
- 		for (tag = 0; tag < RADIX_TREE_MAX_TAGS; tag++)
-@@ -1600,9 +1595,6 @@ struct radix_tree_node *radix_tree_repla
- 		/* Clear root node tags */
- 		root->gfp_mask &= __GFP_BITS_MASK;
- 	}
--
--	radix_tree_replace_slot(slot, entry);
--	return node;
- }
- 
- /**
---- a/mm/filemap.c
-+++ b/mm/filemap.c
-@@ -169,33 +169,35 @@ static int page_cache_tree_insert(struct
- static void page_cache_tree_delete(struct address_space *mapping,
- 				   struct page *page, void *shadow)
- {
--	struct radix_tree_node *node;
- 	int i, nr = PageHuge(page) ? 1 : hpage_nr_pages(page);
- 
- 	VM_BUG_ON_PAGE(!PageLocked(page), page);
- 	VM_BUG_ON_PAGE(PageTail(page), page);
- 	VM_BUG_ON_PAGE(nr != 1 && shadow, page);
- 
--	if (shadow) {
--		mapping->nrexceptional += nr;
--		/*
--		 * Make sure the nrexceptional update is committed before
--		 * the nrpages update so that final truncate racing
--		 * with reclaim does not see both counters 0 at the
--		 * same time and miss a shadow entry.
--		 */
--		smp_wmb();
--	}
--	mapping->nrpages -= nr;
--
- 	for (i = 0; i < nr; i++) {
--		node = radix_tree_replace_clear_tags(&mapping->page_tree,
--				page->index + i, shadow);
-+		struct radix_tree_node *node;
-+		void **slot;
-+
-+		__radix_tree_lookup(&mapping->page_tree, page->index + i,
-+				    &node, &slot);
-+
-+		radix_tree_clear_tags(&mapping->page_tree, node, slot);
-+
- 		if (!node) {
- 			VM_BUG_ON_PAGE(nr != 1, page);
--			return;
-+			/*
-+			 * We need a node to properly account shadow
-+			 * entries. Don't plant any without. XXX
-+			 */
-+			shadow = NULL;
- 		}
- 
-+		radix_tree_replace_slot(slot, shadow);
-+
-+		if (!node)
-+			break;
-+
- 		workingset_node_pages_dec(node);
- 		if (shadow)
- 			workingset_node_shadows_inc(node);
-@@ -219,6 +221,18 @@ static void page_cache_tree_delete(struc
- 					&node->private_list);
- 		}
- 	}
-+
-+	if (shadow) {
-+		mapping->nrexceptional += nr;
-+		/*
-+		 * Make sure the nrexceptional update is committed before
-+		 * the nrpages update so that final truncate racing
-+		 * with reclaim does not see both counters 0 at the
-+		 * same time and miss a shadow entry.
-+		 */
-+		smp_wmb();
-+	}
-+	mapping->nrpages -= nr;
- }
- 
- /*
diff --git a/debian/patches/features/all/rt/mm-filemap-fix-mapping-nrpages-double-accounting-in-.patch b/debian/patches/features/all/rt/mm-filemap-fix-mapping-nrpages-double-accounting-in-.patch
deleted file mode 100644
index 3dff2aa..0000000
--- a/debian/patches/features/all/rt/mm-filemap-fix-mapping-nrpages-double-accounting-in-.patch
+++ /dev/null
@@ -1,41 +0,0 @@
-From: Johannes Weiner <hannes at cmpxchg.org>
-Date: Tue, 4 Oct 2016 16:58:06 +0200
-Subject: [PATCH] mm: filemap: fix mapping->nrpages double accounting in fuse
-Origin: https://www.kernel.org/pub/linux/kernel/projects/rt/4.8/older/patches-4.8-rt1.tar.xz
-
-Upstream commit 3ddf40e8c31964b744ff10abb48c8e36a83ec6e7
-
-Commit 22f2ac51b6d6 ("mm: workingset: fix crash in shadow node shrinker
-caused by replace_page_cache_page()") switched replace_page_cache() from
-raw radix tree operations to page_cache_tree_insert() but didn't take
-into account that the latter function, unlike the raw radix tree op,
-handles mapping->nrpages.  As a result, that counter is bumped for each
-page replacement rather than balanced out even.
-
-The mapping->nrpages counter is used to skip needless radix tree walks
-when invalidating, truncating, syncing inodes without pages, as well as
-statistics for userspace.  Since the error is positive, we'll do more
-page cache tree walks than necessary; we won't miss a necessary one.
-And we'll report more buffer pages to userspace than there are.  The
-error is limited to fuse inodes.
-
-Fixes: 22f2ac51b6d6 ("mm: workingset: fix crash in shadow node shrinker caused by replace_page_cache_page()")
-Signed-off-by: Johannes Weiner <hannes at cmpxchg.org>
-Cc: Andrew Morton <akpm at linux-foundation.org>
-Cc: Miklos Szeredi <miklos at szeredi.hu>
-Cc: stable at vger.kernel.org
-Signed-off-by: Linus Torvalds <torvalds at linux-foundation.org>
----
- mm/filemap.c |    1 -
- 1 file changed, 1 deletion(-)
-
---- a/mm/filemap.c
-+++ b/mm/filemap.c
-@@ -633,7 +633,6 @@ int replace_page_cache_page(struct page
- 		__delete_from_page_cache(old, NULL);
- 		error = page_cache_tree_insert(mapping, new, NULL);
- 		BUG_ON(error);
--		mapping->nrpages++;
- 
- 		/*
- 		 * hugetlb pages do not participate in page cache accounting.
diff --git a/debian/patches/series-rt b/debian/patches/series-rt
index 0523783..71b8241 100644
--- a/debian/patches/series-rt
+++ b/debian/patches/series-rt
@@ -1,8 +1,6 @@
 ###########################################################
 # DELTA against a known Linus release
 ###########################################################
-features/all/rt/mm-filemap-don-t-plant-shadow-entries-without-radix-.patch
-features/all/rt/mm-filemap-fix-mapping-nrpages-double-accounting-in-.patch
 
 ############################################################
 # UPSTREAM changes queued
@@ -12,7 +10,6 @@ features/all/rt/mm-filemap-fix-mapping-nrpages-double-accounting-in-.patch
 # UPSTREAM FIXES, patches pending
 ############################################################
 features/all/rt/timer-make-the-base-lock-raw.patch
-features/all/rt/jbd2-Fix-lockdep-annotation-in-add_transaction_credi.patch
 
 ############################################################
 # Stuff broken upstream, patches submitted

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/kernel/linux.git



More information about the Kernel-svn-changes mailing list