Skip to content

Commit bd721ea

Browse files
Fabian Fredericktorvalds
authored andcommitted
treewide: replace obsolete _refok by __ref
There was only one use of __initdata_refok and __exit_refok __init_refok was used 46 times against 82 for __ref. Those definitions are obsolete since commit 312b148 ("Introduce new section reference annotations tags: __ref, __refdata, __refconst") This patch removes the following compatibility definitions and replaces them treewide. /* compatibility defines */ #define __init_refok __ref #define __initdata_refok __refdata #define __exit_refok __ref I can also provide separate patches if necessary. (One patch per tree and check in 1 month or 2 to remove old definitions) [[email protected]: coding-style fixes] Link: http://lkml.kernel.org/r/[email protected] Signed-off-by: Fabian Frederick <[email protected]> Cc: Ingo Molnar <[email protected]> Cc: Sam Ravnborg <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
1 parent ca945e7 commit bd721ea

File tree

36 files changed

+46
-53
lines changed

36 files changed

+46
-53
lines changed

arch/alpha/kernel/machvec_impl.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -137,7 +137,7 @@
137137
#define __initmv __initdata
138138
#define ALIAS_MV(x)
139139
#else
140-
#define __initmv __initdata_refok
140+
#define __initmv __refdata
141141

142142
/* GCC actually has a syntax for defining aliases, but is under some
143143
delusion that you shouldn't be able to declare it extern somewhere

arch/arc/mm/init.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -220,7 +220,7 @@ void __init mem_init(void)
220220
/*
221221
* free_initmem: Free all the __init memory.
222222
*/
223-
void __init_refok free_initmem(void)
223+
void __ref free_initmem(void)
224224
{
225225
free_initmem_default(-1);
226226
}

arch/arm/mach-integrator/impd1.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -320,11 +320,11 @@ static struct impd1_device impd1_devs[] = {
320320
#define IMPD1_VALID_IRQS 0x00000bffU
321321

322322
/*
323-
* As this module is bool, it is OK to have this as __init_refok() - no
323+
* As this module is bool, it is OK to have this as __ref() - no
324324
* probe calls will be done after the initial system bootup, as devices
325325
* are discovered as part of the machine startup.
326326
*/
327-
static int __init_refok impd1_probe(struct lm_device *dev)
327+
static int __ref impd1_probe(struct lm_device *dev)
328328
{
329329
struct impd1_module *impd1;
330330
int irq_base;

arch/arm/mach-mv78xx0/common.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -343,7 +343,7 @@ void __init mv78xx0_init_early(void)
343343
DDR_WINDOW_CPU1_BASE, DDR_WINDOW_CPU_SZ);
344344
}
345345

346-
void __init_refok mv78xx0_timer_init(void)
346+
void __ref mv78xx0_timer_init(void)
347347
{
348348
orion_time_init(BRIDGE_VIRT_BASE, BRIDGE_INT_TIMER1_CLR,
349349
IRQ_MV78XX0_TIMER_1, get_tclk());

arch/blackfin/mm/init.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -112,7 +112,7 @@ void __init free_initrd_mem(unsigned long start, unsigned long end)
112112
}
113113
#endif
114114

115-
void __init_refok free_initmem(void)
115+
void __ref free_initmem(void)
116116
{
117117
#if defined CONFIG_RAMKERNEL && !defined CONFIG_MPU
118118
free_initmem_default(-1);

arch/hexagon/mm/init.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,7 @@ void __init mem_init(void)
9393
* Todo: free pages between __init_begin and __init_end; possibly
9494
* some devtree related stuff as well.
9595
*/
96-
void __init_refok free_initmem(void)
96+
void __ref free_initmem(void)
9797
{
9898
}
9999

arch/ia64/kernel/mca.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1831,7 +1831,7 @@ format_mca_init_stack(void *mca_data, unsigned long offset,
18311831
}
18321832

18331833
/* Caller prevents this from being called after init */
1834-
static void * __init_refok mca_bootmem(void)
1834+
static void * __ref mca_bootmem(void)
18351835
{
18361836
return __alloc_bootmem(sizeof(struct ia64_mca_cpu),
18371837
KERNEL_STACK_SIZE, 0);

arch/microblaze/mm/init.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -414,15 +414,15 @@ void __init *early_get_page(void)
414414

415415
#endif /* CONFIG_MMU */
416416

417-
void * __init_refok alloc_maybe_bootmem(size_t size, gfp_t mask)
417+
void * __ref alloc_maybe_bootmem(size_t size, gfp_t mask)
418418
{
419419
if (mem_init_done)
420420
return kmalloc(size, mask);
421421
else
422422
return alloc_bootmem(size);
423423
}
424424

425-
void * __init_refok zalloc_maybe_bootmem(size_t size, gfp_t mask)
425+
void * __ref zalloc_maybe_bootmem(size_t size, gfp_t mask)
426426
{
427427
void *p;
428428

arch/microblaze/mm/pgtable.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -234,7 +234,7 @@ unsigned long iopa(unsigned long addr)
234234
return pa;
235235
}
236236

237-
__init_refok pte_t *pte_alloc_one_kernel(struct mm_struct *mm,
237+
__ref pte_t *pte_alloc_one_kernel(struct mm_struct *mm,
238238
unsigned long address)
239239
{
240240
pte_t *pte;

arch/mips/mm/init.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -504,7 +504,7 @@ void free_initrd_mem(unsigned long start, unsigned long end)
504504

505505
void (*free_init_pages_eva)(void *begin, void *end) = NULL;
506506

507-
void __init_refok free_initmem(void)
507+
void __ref free_initmem(void)
508508
{
509509
prom_free_prom_memory();
510510
/*

0 commit comments

Comments
 (0)