Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Merge branch 'akpm' (patches from Andrew)

Merge fixes from Andrew Morton:
"5 fixes"

* emailed patches from Andrew Morton <akpm@linux-foundation.org>:
mm: memcg: fix use after free in mem_cgroup_iter()
mm/huge_memory.c: fix data loss when splitting a file pmd
fat: fix memory allocation failure handling of match_strdup()
MAINTAINERS: Peter has moved
mm/memblock: add missing include <linux/bootmem.h>

+20 -9
+1 -1
MAINTAINERS
··· 9074 9074 F: drivers/usb/mtu3/ 9075 9075 9076 9076 MEGACHIPS STDPXXXX-GE-B850V3-FW LVDS/DP++ BRIDGES 9077 - M: Peter Senna Tschudin <peter.senna@collabora.com> 9077 + M: Peter Senna Tschudin <peter.senna@gmail.com> 9078 9078 M: Martin Donnelly <martin.donnelly@ge.com> 9079 9079 M: Martyn Welch <martyn.welch@collabora.co.uk> 9080 9080 S: Maintained
+13 -7
fs/fat/inode.c
··· 707 707 brelse(bh); 708 708 } 709 709 710 + static void fat_reset_iocharset(struct fat_mount_options *opts) 711 + { 712 + if (opts->iocharset != fat_default_iocharset) { 713 + /* Note: opts->iocharset can be NULL here */ 714 + kfree(opts->iocharset); 715 + opts->iocharset = fat_default_iocharset; 716 + } 717 + } 718 + 710 719 static void delayed_free(struct rcu_head *p) 711 720 { 712 721 struct msdos_sb_info *sbi = container_of(p, struct msdos_sb_info, rcu); 713 722 unload_nls(sbi->nls_disk); 714 723 unload_nls(sbi->nls_io); 715 - if (sbi->options.iocharset != fat_default_iocharset) 716 - kfree(sbi->options.iocharset); 724 + fat_reset_iocharset(&sbi->options); 717 725 kfree(sbi); 718 726 } 719 727 ··· 1140 1132 opts->fs_fmask = opts->fs_dmask = current_umask(); 1141 1133 opts->allow_utime = -1; 1142 1134 opts->codepage = fat_default_codepage; 1143 - opts->iocharset = fat_default_iocharset; 1135 + fat_reset_iocharset(opts); 1144 1136 if (is_vfat) { 1145 1137 opts->shortname = VFAT_SFN_DISPLAY_WINNT|VFAT_SFN_CREATE_WIN95; 1146 1138 opts->rodir = 0; ··· 1297 1289 1298 1290 /* vfat specific */ 1299 1291 case Opt_charset: 1300 - if (opts->iocharset != fat_default_iocharset) 1301 - kfree(opts->iocharset); 1292 + fat_reset_iocharset(opts); 1302 1293 iocharset = match_strdup(&args[0]); 1303 1294 if (!iocharset) 1304 1295 return -ENOMEM; ··· 1888 1881 iput(fat_inode); 1889 1882 unload_nls(sbi->nls_io); 1890 1883 unload_nls(sbi->nls_disk); 1891 - if (sbi->options.iocharset != fat_default_iocharset) 1892 - kfree(sbi->options.iocharset); 1884 + fat_reset_iocharset(&sbi->options); 1893 1885 sb->s_fs_info = NULL; 1894 1886 kfree(sbi); 1895 1887 return error;
+2
mm/huge_memory.c
··· 2084 2084 if (vma_is_dax(vma)) 2085 2085 return; 2086 2086 page = pmd_page(_pmd); 2087 + if (!PageDirty(page) && pmd_dirty(_pmd)) 2088 + set_page_dirty(page); 2087 2089 if (!PageReferenced(page) && pmd_young(_pmd)) 2088 2090 SetPageReferenced(page); 2089 2091 page_remove_rmap(page, true);
+3
mm/memblock.c
··· 20 20 #include <linux/kmemleak.h> 21 21 #include <linux/seq_file.h> 22 22 #include <linux/memblock.h> 23 + #include <linux/bootmem.h> 23 24 24 25 #include <asm/sections.h> 25 26 #include <linux/io.h> ··· 1226 1225 return memblock_alloc_base(size, align, MEMBLOCK_ALLOC_ACCESSIBLE); 1227 1226 } 1228 1227 1228 + #if defined(CONFIG_NO_BOOTMEM) 1229 1229 /** 1230 1230 * memblock_virt_alloc_internal - allocate boot memory block 1231 1231 * @size: size of memory block to be allocated in bytes ··· 1434 1432 (u64)max_addr); 1435 1433 return NULL; 1436 1434 } 1435 + #endif 1437 1436 1438 1437 /** 1439 1438 * __memblock_free_early - free boot memory block
+1 -1
mm/memcontrol.c
··· 850 850 int nid; 851 851 int i; 852 852 853 - while ((memcg = parent_mem_cgroup(memcg))) { 853 + for (; memcg; memcg = parent_mem_cgroup(memcg)) { 854 854 for_each_node(nid) { 855 855 mz = mem_cgroup_nodeinfo(memcg, nid); 856 856 for (i = 0; i <= DEF_PRIORITY; i++) {