Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit4a51c60

Browse files
committed
Merge branch 'akpm' (patches from Andrew)
Merge misc fixes from Andrew Morton: "8 patches. Subsystems affected by this patch series: mm (madvise, pagemap, readahead, memcg, userfaultfd), kbuild, and vfs"* emailed patches from Andrew Morton <akpm@linux-foundation.org>: mm: fix madvise WILLNEED performance problem libfs: fix error cast of negative value in simple_attr_write() mm/userfaultfd: do not access vma->vm_mm after calling handle_userfault() mm: memcg/slab: fix root memcg vmstats mm: fix readahead_page_batch for retry entries mm: fix phys_to_target_node() and memory_add_physaddr_to_nid() exports compiler-clang: remove version check for BPF Tracing mm/madvise: fix memory leak from process_madvise
2 parentsd27637e +6638380 commit4a51c60

File tree

16 files changed

+75
-49
lines changed

16 files changed

+75
-49
lines changed

‎arch/ia64/include/asm/sparsemem.h‎

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,4 +18,10 @@
1818
#endif
1919

2020
#endif/* CONFIG_SPARSEMEM */
21+
22+
#ifdefCONFIG_MEMORY_HOTPLUG
23+
intmemory_add_physaddr_to_nid(u64addr);
24+
#definememory_add_physaddr_to_nid memory_add_physaddr_to_nid
25+
#endif
26+
2127
#endif/* _ASM_IA64_SPARSEMEM_H */

‎arch/powerpc/include/asm/mmzone.h‎

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -46,5 +46,10 @@ u64 memory_hotplug_max(void);
4646
#define__HAVE_ARCH_RESERVED_KERNEL_PAGES
4747
#endif
4848

49+
#ifdefCONFIG_MEMORY_HOTPLUG
50+
externintcreate_section_mapping(unsigned longstart,unsigned longend,
51+
intnid,pgprot_tprot);
52+
#endif
53+
4954
#endif/* __KERNEL__ */
5055
#endif/* _ASM_MMZONE_H_ */

‎arch/powerpc/include/asm/sparsemem.h‎

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,9 +13,9 @@
1313
#endif/* CONFIG_SPARSEMEM */
1414

1515
#ifdefCONFIG_MEMORY_HOTPLUG
16-
externintcreate_section_mapping(unsigned longstart,unsigned longend,
17-
intnid,pgprot_tprot);
1816
externintremove_section_mapping(unsigned longstart,unsigned longend);
17+
externintmemory_add_physaddr_to_nid(u64start);
18+
#definememory_add_physaddr_to_nid memory_add_physaddr_to_nid
1919

2020
#ifdefCONFIG_NUMA
2121
externinthot_add_scn_to_nid(unsigned longscn_addr);
@@ -26,6 +26,5 @@ static inline int hot_add_scn_to_nid(unsigned long scn_addr)
2626
}
2727
#endif/* CONFIG_NUMA */
2828
#endif/* CONFIG_MEMORY_HOTPLUG */
29-
3029
#endif/* __KERNEL__ */
3130
#endif/* _ASM_POWERPC_SPARSEMEM_H */

‎arch/powerpc/mm/mem.c‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,7 @@
5050
#include<asm/rtas.h>
5151
#include<asm/kasan.h>
5252
#include<asm/svm.h>
53+
#include<asm/mmzone.h>
5354

5455
#include<mm/mmu_decl.h>
5556

‎arch/x86/include/asm/sparsemem.h‎

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,4 +28,14 @@
2828
#endif
2929

3030
#endif/* CONFIG_SPARSEMEM */
31+
32+
#ifndef__ASSEMBLY__
33+
#ifdefCONFIG_NUMA_KEEP_MEMINFO
34+
externintphys_to_target_node(phys_addr_tstart);
35+
#definephys_to_target_node phys_to_target_node
36+
externintmemory_add_physaddr_to_nid(u64start);
37+
#definememory_add_physaddr_to_nid memory_add_physaddr_to_nid
38+
#endif
39+
#endif/* __ASSEMBLY__ */
40+
3141
#endif/* _ASM_X86_SPARSEMEM_H */

‎arch/x86/mm/numa.c‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -938,6 +938,7 @@ int phys_to_target_node(phys_addr_t start)
938938

939939
returnmeminfo_to_nid(&numa_reserved_meminfo,start);
940940
}
941+
EXPORT_SYMBOL_GPL(phys_to_target_node);
941942

942943
intmemory_add_physaddr_to_nid(u64start)
943944
{
@@ -947,4 +948,5 @@ int memory_add_physaddr_to_nid(u64 start)
947948
nid=numa_meminfo.blk[0].nid;
948949
returnnid;
949950
}
951+
EXPORT_SYMBOL_GPL(memory_add_physaddr_to_nid);
950952
#endif

‎drivers/dax/Kconfig‎

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,6 @@ config DEV_DAX_HMEM
5050
Say M if unsure.
5151

5252
config DEV_DAX_HMEM_DEVICES
53-
depends on NUMA_KEEP_MEMINFO # for phys_to_target_node()
5453
depends on DEV_DAX_HMEM && DAX=y
5554
def_bool y
5655

‎fs/libfs.c‎

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -959,7 +959,7 @@ ssize_t simple_attr_write(struct file *file, const char __user *buf,
959959
size_tlen,loff_t*ppos)
960960
{
961961
structsimple_attr*attr;
962-
u64val;
962+
unsigned long longval;
963963
size_tsize;
964964
ssize_tret;
965965

@@ -977,7 +977,9 @@ ssize_t simple_attr_write(struct file *file, const char __user *buf,
977977
gotoout;
978978

979979
attr->set_buf[size]='\0';
980-
val=simple_strtoll(attr->set_buf,NULL,0);
980+
ret=kstrtoull(attr->set_buf,0,&val);
981+
if (ret)
982+
gotoout;
981983
ret=attr->set(attr->data,val);
982984
if (ret==0)
983985
ret=len;/* on success, claim we got the whole input */

‎include/linux/compiler-clang.h‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,10 @@
88
+ __clang_patchlevel__)
99

1010
#ifCLANG_VERSION<100001
11+
#ifndef__BPF_TRACING__
1112
# error Sorry, your version of Clang is too old - please use 10.0.1 or newer.
1213
#endif
14+
#endif
1315

1416
/* Compiler specific definitions for Clang compiler */
1517

‎include/linux/memory_hotplug.h‎

Lines changed: 0 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -281,20 +281,6 @@ static inline bool movable_node_is_enabled(void)
281281
}
282282
#endif/* ! CONFIG_MEMORY_HOTPLUG */
283283

284-
#ifdefCONFIG_NUMA
285-
externintmemory_add_physaddr_to_nid(u64start);
286-
externintphys_to_target_node(u64start);
287-
#else
288-
staticinlineintmemory_add_physaddr_to_nid(u64start)
289-
{
290-
return0;
291-
}
292-
staticinlineintphys_to_target_node(u64start)
293-
{
294-
return0;
295-
}
296-
#endif
297-
298284
#if defined(CONFIG_MEMORY_HOTPLUG)|| defined(CONFIG_DEFERRED_STRUCT_PAGE_INIT)
299285
/*
300286
* pgdat resizing functions

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp