bg2.c (45ba387511149a5c71d0f720366be64898bc9129) bg2.c (acafe7e30216166a17e6e226aadc3ecb63993242)
1// SPDX-License-Identifier: GPL-2.0
2/*
3 * Copyright (c) 2014 Marvell Technology Group Ltd.
4 *
5 * Sebastian Hesselbarth <sebastian.hesselbarth@gmail.com>
6 * Alexandre Belloni <alexandre.belloni@free-electrons.com>
1/*
2 * Copyright (c) 2014 Marvell Technology Group Ltd.
3 *
4 * Sebastian Hesselbarth <sebastian.hesselbarth@gmail.com>
5 * Alexandre Belloni <alexandre.belloni@free-electrons.com>
6 *
7 * This program is free software; you can redistribute it and/or modify it
8 * under the terms and conditions of the GNU General Public License,
9 * version 2, as published by the Free Software Foundation.
10 *
11 * This program is distributed in the hope it will be useful, but WITHOUT
12 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
13 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
14 * more details.
15 *
16 * You should have received a copy of the GNU General Public License along with
17 * this program. If not, see <http://www.gnu.org/licenses/>.
7 */
8
9#include <linux/clk.h>
10#include <linux/clk-provider.h>
11#include <linux/kernel.h>
12#include <linux/of.h>
13#include <linux/of_address.h>
14#include <linux/slab.h>

--- 478 unchanged lines hidden (view full) ---

493 struct device_node *parent_np = of_get_parent(np);
494 const char *parent_names[9];
495 struct clk *clk;
496 struct clk_hw *hw;
497 struct clk_hw **hws;
498 u8 avpll_flags = 0;
499 int n, ret;
500
18 */
19
20#include <linux/clk.h>
21#include <linux/clk-provider.h>
22#include <linux/kernel.h>
23#include <linux/of.h>
24#include <linux/of_address.h>
25#include <linux/slab.h>

--- 478 unchanged lines hidden (view full) ---

504 struct device_node *parent_np = of_get_parent(np);
505 const char *parent_names[9];
506 struct clk *clk;
507 struct clk_hw *hw;
508 struct clk_hw **hws;
509 u8 avpll_flags = 0;
510 int n, ret;
511
501 clk_data = kzalloc(sizeof(*clk_data) +
502 sizeof(*clk_data->hws) * MAX_CLKS, GFP_KERNEL);
512 clk_data = kzalloc(struct_size(clk_data, hws, MAX_CLKS), GFP_KERNEL);
503 if (!clk_data)
504 return;
505 clk_data->num = MAX_CLKS;
506 hws = clk_data->hws;
507
508 gbase = of_iomap(parent_np, 0);
509 if (!gbase)
510 return;

--- 174 unchanged lines hidden ---
513 if (!clk_data)
514 return;
515 clk_data->num = MAX_CLKS;
516 hws = clk_data->hws;
517
518 gbase = of_iomap(parent_np, 0);
519 if (!gbase)
520 return;

--- 174 unchanged lines hidden ---