.. | .. |
---|
| 1 | +/* SPDX-License-Identifier: GPL-2.0-only */ |
---|
1 | 2 | /* |
---|
2 | 3 | * Based on arch/arm/lib/strchr.S |
---|
3 | 4 | * |
---|
4 | 5 | * Copyright (C) 1995-2000 Russell King |
---|
5 | 6 | * Copyright (C) 2013 ARM Ltd. |
---|
6 | | - * |
---|
7 | | - * This program is free software; you can redistribute it and/or modify |
---|
8 | | - * it under the terms of the GNU General Public License version 2 as |
---|
9 | | - * published by the Free Software Foundation. |
---|
10 | | - * |
---|
11 | | - * This program is distributed in the hope that it will be useful, |
---|
12 | | - * but WITHOUT ANY WARRANTY; without even the implied warranty of |
---|
13 | | - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
---|
14 | | - * GNU General Public License for more details. |
---|
15 | | - * |
---|
16 | | - * You should have received a copy of the GNU General Public License |
---|
17 | | - * along with this program. If not, see <http://www.gnu.org/licenses/>. |
---|
18 | 7 | */ |
---|
19 | 8 | |
---|
20 | 9 | #include <linux/linkage.h> |
---|
.. | .. |
---|
29 | 18 | * Returns: |
---|
30 | 19 | * x0 - address of first occurrence of 'c' or 0 |
---|
31 | 20 | */ |
---|
32 | | -WEAK(strchr) |
---|
| 21 | +SYM_FUNC_START_WEAK(strchr) |
---|
33 | 22 | and w1, w1, #0xff |
---|
34 | 23 | 1: ldrb w2, [x0], #1 |
---|
35 | 24 | cmp w2, w1 |
---|
.. | .. |
---|
39 | 28 | cmp w2, w1 |
---|
40 | 29 | csel x0, x0, xzr, eq |
---|
41 | 30 | ret |
---|
42 | | -ENDPROC(strchr) |
---|
| 31 | +SYM_FUNC_END(strchr) |
---|
| 32 | +EXPORT_SYMBOL_NOKASAN(strchr) |
---|