diff options
author | Dave Airlie <airlied@redhat.com> | 2014-12-07 19:33:52 -0500 |
---|---|---|
committer | Dave Airlie <airlied@redhat.com> | 2014-12-07 19:33:52 -0500 |
commit | 8c8639447063ddaa7966b0effd6029037fc86599 (patch) | |
tree | 33f948ef3502faa964aca24fd88daa37c43e9d30 /mm/memory.c | |
parent | 7608867d0c4d9da30e9efe6a53ff4ee1e6c4990b (diff) | |
parent | b2776bf7149bddd1f4161f14f79520f17fc1d71d (diff) |
Merge tag 'v3.18' into drm-next
Linux 3.18
Backmerge Linus tree into -next as we had conflicts in i915/radeon/nouveau,
and everyone was solving them individually.
* tag 'v3.18': (57 commits)
Linux 3.18
watchdog: s3c2410_wdt: Fix the mask bit offset for Exynos7
uapi: fix to export linux/vm_sockets.h
i2c: cadence: Set the hardware time-out register to maximum value
i2c: davinci: generate STP always when NACK is received
ahci: disable MSI on SAMSUNG 0xa800 SSD
context_tracking: Restore previous state in schedule_user
slab: fix nodeid bounds check for non-contiguous node IDs
lib/genalloc.c: export devm_gen_pool_create() for modules
mm: fix anon_vma_clone() error treatment
mm: fix swapoff hang after page migration and fork
fat: fix oops on corrupted vfat fs
ipc/sem.c: fully initialize sem_array before making it visible
drivers/input/evdev.c: don't kfree() a vmalloc address
cxgb4: Fill in supported link mode for SFP modules
xen-netfront: Remove BUGs on paged skb data which crosses a page boundary
mm/vmpressure.c: fix race in vmpressure_work_fn()
mm: frontswap: invalidate expired data on a dup-store failure
mm: do not overwrite reserved pages counter at show_mem()
drm/radeon: kernel panic in drm_calc_vbltimestamp_from_scanoutpos with 3.18.0-rc6
...
Conflicts:
drivers/gpu/drm/i915/intel_display.c
drivers/gpu/drm/nouveau/nouveau_drm.c
drivers/gpu/drm/radeon/radeon_cs.c
Diffstat (limited to 'mm/memory.c')
-rw-r--r-- | mm/memory.c | 26 |
1 files changed, 13 insertions, 13 deletions
diff --git a/mm/memory.c b/mm/memory.c index 655fd3d34bb0..d3cb2ef66ee2 100644 --- a/mm/memory.c +++ b/mm/memory.c | |||
@@ -816,20 +816,20 @@ copy_one_pte(struct mm_struct *dst_mm, struct mm_struct *src_mm, | |||
816 | if (!pte_file(pte)) { | 816 | if (!pte_file(pte)) { |
817 | swp_entry_t entry = pte_to_swp_entry(pte); | 817 | swp_entry_t entry = pte_to_swp_entry(pte); |
818 | 818 | ||
819 | if (swap_duplicate(entry) < 0) | 819 | if (likely(!non_swap_entry(entry))) { |
820 | return entry.val; | 820 | if (swap_duplicate(entry) < 0) |
821 | 821 | return entry.val; | |
822 | /* make sure dst_mm is on swapoff's mmlist. */ | 822 | |
823 | if (unlikely(list_empty(&dst_mm->mmlist))) { | 823 | /* make sure dst_mm is on swapoff's mmlist. */ |
824 | spin_lock(&mmlist_lock); | 824 | if (unlikely(list_empty(&dst_mm->mmlist))) { |
825 | if (list_empty(&dst_mm->mmlist)) | 825 | spin_lock(&mmlist_lock); |
826 | list_add(&dst_mm->mmlist, | 826 | if (list_empty(&dst_mm->mmlist)) |
827 | &src_mm->mmlist); | 827 | list_add(&dst_mm->mmlist, |
828 | spin_unlock(&mmlist_lock); | 828 | &src_mm->mmlist); |
829 | } | 829 | spin_unlock(&mmlist_lock); |
830 | if (likely(!non_swap_entry(entry))) | 830 | } |
831 | rss[MM_SWAPENTS]++; | 831 | rss[MM_SWAPENTS]++; |
832 | else if (is_migration_entry(entry)) { | 832 | } else if (is_migration_entry(entry)) { |
833 | page = migration_entry_to_page(entry); | 833 | page = migration_entry_to_page(entry); |
834 | 834 | ||
835 | if (PageAnon(page)) | 835 | if (PageAnon(page)) |