| .. | .. |
|---|
| 1 | +// SPDX-License-Identifier: GPL-2.0 |
|---|
| 1 | 2 | /* |
|---|
| 2 | 3 | * SH generic board support, using device tree |
|---|
| 3 | 4 | * |
|---|
| 4 | 5 | * Copyright (C) 2015-2016 Smart Energy Instruments, Inc. |
|---|
| 5 | | - * |
|---|
| 6 | | - * This file is subject to the terms and conditions of the GNU General Public |
|---|
| 7 | | - * License. See the file "COPYING" in the main directory of this archive |
|---|
| 8 | | - * for more details. |
|---|
| 9 | 6 | */ |
|---|
| 10 | 7 | |
|---|
| 11 | 8 | #include <linux/of.h> |
|---|
| .. | .. |
|---|
| 52 | 49 | |
|---|
| 53 | 50 | extern const struct of_cpu_method __cpu_method_of_table[]; |
|---|
| 54 | 51 | const struct of_cpu_method __cpu_method_of_table_sentinel |
|---|
| 55 | | - __section(__cpu_method_of_table_end); |
|---|
| 52 | + __section("__cpu_method_of_table_end"); |
|---|
| 56 | 53 | |
|---|
| 57 | 54 | static void sh_of_smp_probe(void) |
|---|
| 58 | 55 | { |
|---|
| .. | .. |
|---|
| 64 | 61 | |
|---|
| 65 | 62 | init_cpu_possible(cpumask_of(0)); |
|---|
| 66 | 63 | |
|---|
| 67 | | - for_each_node_by_type(np, "cpu") { |
|---|
| 64 | + for_each_of_cpu_node(np) { |
|---|
| 68 | 65 | const __be32 *cell = of_get_property(np, "reg", NULL); |
|---|
| 69 | 66 | u64 id = -1; |
|---|
| 70 | 67 | if (cell) id = of_read_number(cell, of_n_addr_cells(np)); |
|---|
| .. | .. |
|---|
| 117 | 114 | early_init_fdt_scan_reserved_mem(); |
|---|
| 118 | 115 | } |
|---|
| 119 | 116 | |
|---|
| 120 | | -static void __init sh_of_time_init(void) |
|---|
| 121 | | -{ |
|---|
| 122 | | - pr_info("SH generic board support: scanning for clocksource devices\n"); |
|---|
| 123 | | - timer_probe(); |
|---|
| 124 | | -} |
|---|
| 125 | | - |
|---|
| 126 | 117 | static void __init sh_of_setup(char **cmdline_p) |
|---|
| 127 | 118 | { |
|---|
| 128 | 119 | struct device_node *root; |
|---|
| 129 | | - |
|---|
| 130 | | - board_time_init = sh_of_time_init; |
|---|
| 131 | 120 | |
|---|
| 132 | 121 | sh_mv.mv_name = "Unknown SH model"; |
|---|
| 133 | 122 | root = of_find_node_by_path("/"); |
|---|