| .. | .. |
|---|
| 1 | +/* SPDX-License-Identifier: GPL-2.0-only */ |
|---|
| 1 | 2 | /* |
|---|
| 2 | 3 | * linux/percpu-defs.h - basic definitions for percpu areas |
|---|
| 3 | 4 | * |
|---|
| .. | .. |
|---|
| 50 | 51 | PER_CPU_ATTRIBUTES |
|---|
| 51 | 52 | |
|---|
| 52 | 53 | #define __PCPU_DUMMY_ATTRS \ |
|---|
| 53 | | - __attribute__((section(".discard"), unused)) |
|---|
| 54 | + __section(".discard") __attribute__((unused)) |
|---|
| 54 | 55 | |
|---|
| 55 | 56 | /* |
|---|
| 56 | 57 | * s390 and alpha modules require percpu variables to be defined as |
|---|
| .. | .. |
|---|
| 91 | 92 | extern __PCPU_DUMMY_ATTRS char __pcpu_unique_##name; \ |
|---|
| 92 | 93 | __PCPU_DUMMY_ATTRS char __pcpu_unique_##name; \ |
|---|
| 93 | 94 | extern __PCPU_ATTRS(sec) __typeof__(type) name; \ |
|---|
| 94 | | - __PCPU_ATTRS(sec) PER_CPU_DEF_ATTRIBUTES __weak \ |
|---|
| 95 | | - __typeof__(type) name |
|---|
| 95 | + __PCPU_ATTRS(sec) __weak __typeof__(type) name |
|---|
| 96 | 96 | #else |
|---|
| 97 | 97 | /* |
|---|
| 98 | 98 | * Normal declaration and definition macros. |
|---|
| .. | .. |
|---|
| 101 | 101 | extern __PCPU_ATTRS(sec) __typeof__(type) name |
|---|
| 102 | 102 | |
|---|
| 103 | 103 | #define DEFINE_PER_CPU_SECTION(type, name, sec) \ |
|---|
| 104 | | - __PCPU_ATTRS(sec) PER_CPU_DEF_ATTRIBUTES \ |
|---|
| 105 | | - __typeof__(type) name |
|---|
| 104 | + __PCPU_ATTRS(sec) __typeof__(type) name |
|---|
| 106 | 105 | #endif |
|---|
| 107 | 106 | |
|---|
| 108 | 107 | /* |
|---|