.. | .. |
---|
| 1 | +// SPDX-License-Identifier: GPL-2.0-or-later |
---|
1 | 2 | /* |
---|
2 | 3 | * clk-xgene.c - AppliedMicro X-Gene Clock Interface |
---|
3 | 4 | * |
---|
4 | 5 | * Copyright (c) 2013, Applied Micro Circuits Corporation |
---|
5 | 6 | * Author: Loc Ho <lho@apm.com> |
---|
6 | | - * |
---|
7 | | - * This program is free software; you can redistribute it and/or |
---|
8 | | - * modify it under the terms of the GNU General Public License as |
---|
9 | | - * published by the Free Software Foundation; either version 2 of |
---|
10 | | - * the License, or (at your option) any later version. |
---|
11 | | - * |
---|
12 | | - * This program is distributed in the hope that it will be useful, |
---|
13 | | - * but WITHOUT ANY WARRANTY; without even the implied warranty of |
---|
14 | | - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
---|
15 | | - * GNU General Public License for more details. |
---|
16 | | - * |
---|
17 | | - * You should have received a copy of the GNU General Public License |
---|
18 | | - * along with this program; if not, write to the Free Software |
---|
19 | | - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, |
---|
20 | | - * MA 02111-1307 USA |
---|
21 | | - * |
---|
22 | 7 | */ |
---|
23 | 8 | #include <linux/module.h> |
---|
24 | 9 | #include <linux/spinlock.h> |
---|
.. | .. |
---|
142 | 127 | { |
---|
143 | 128 | struct xgene_clk_pll *apmclk; |
---|
144 | 129 | struct clk *clk; |
---|
145 | | - struct clk_init_data init = {}; |
---|
| 130 | + struct clk_init_data init; |
---|
146 | 131 | |
---|
147 | 132 | /* allocate the APM clock structure */ |
---|
148 | 133 | apmclk = kzalloc(sizeof(*apmclk), GFP_KERNEL); |
---|
.. | .. |
---|
262 | 247 | else |
---|
263 | 248 | __acquire(fd->lock); |
---|
264 | 249 | |
---|
265 | | - val = clk_readl(fd->reg); |
---|
| 250 | + val = readl(fd->reg); |
---|
266 | 251 | |
---|
267 | 252 | if (fd->lock) |
---|
268 | 253 | spin_unlock_irqrestore(fd->lock, flags); |
---|
.. | .. |
---|
333 | 318 | else |
---|
334 | 319 | __acquire(fd->lock); |
---|
335 | 320 | |
---|
336 | | - val = clk_readl(fd->reg); |
---|
| 321 | + val = readl(fd->reg); |
---|
337 | 322 | val &= ~fd->mask; |
---|
338 | 323 | val |= (scale << fd->shift); |
---|
339 | | - clk_writel(val, fd->reg); |
---|
| 324 | + writel(val, fd->reg); |
---|
340 | 325 | |
---|
341 | 326 | if (fd->lock) |
---|
342 | 327 | spin_unlock_irqrestore(fd->lock, flags); |
---|
.. | .. |
---|
359 | 344 | u8 width, u64 denom, u32 clk_flags, spinlock_t *lock) |
---|
360 | 345 | { |
---|
361 | 346 | struct xgene_clk_pmd *fd; |
---|
362 | | - struct clk_init_data init = {}; |
---|
| 347 | + struct clk_init_data init; |
---|
363 | 348 | struct clk *clk; |
---|
364 | 349 | |
---|
365 | 350 | fd = kzalloc(sizeof(*fd), GFP_KERNEL); |
---|
.. | .. |
---|
643 | 628 | { |
---|
644 | 629 | struct xgene_clk *apmclk; |
---|
645 | 630 | struct clk *clk; |
---|
646 | | - struct clk_init_data init = {}; |
---|
| 631 | + struct clk_init_data init; |
---|
647 | 632 | int rc; |
---|
648 | 633 | |
---|
649 | 634 | /* allocate the APM clock structure */ |
---|