forked from Minki/linux
889c2b7ec4
Initially, the meson clock directory only hosted 2 controllers drivers, for meson8 and gxbb. At the time, both used the same set of clock drivers so managing the dependencies was not a big concern. Since this ancient time, entropy did its job, controllers with different requirement and specific clock drivers have been added. Unfortunately, we did not do a great job at managing the dependencies between the controllers and the different clock drivers. Some drivers, such as clk-phase or vid-pll-div, are compiled even if they are useless on the target (meson8). As we are adding new controllers, we need to be able to pick a driver w/o pulling the whole thing. The patch aims to clean things up by: * providing a dedicated CONFIG_ for each clock drivers * allowing clock drivers to be compiled as a modules, if possible * stating explicitly which drivers are required by each controller. Signed-off-by: Jerome Brunet <jbrunet@baylibre.com> Signed-off-by: Neil Armstrong <narmstrong@baylibre.com> Link: https://lkml.kernel.org/r/20190201125841.26785-5-jbrunet@baylibre.com
34 lines
683 B
C
34 lines
683 B
C
/* SPDX-License-Identifier: GPL-2.0 */
|
|
/*
|
|
* Copyright (c) 2019 BayLibre, SAS.
|
|
* Author: Jerome Brunet <jbrunet@baylibre.com>
|
|
*/
|
|
|
|
#ifndef __MESON_CLK_DUALDIV_H
|
|
#define __MESON_CLK_DUALDIV_H
|
|
|
|
#include <linux/clk-provider.h>
|
|
#include "parm.h"
|
|
|
|
struct meson_clk_dualdiv_param {
|
|
unsigned int n1;
|
|
unsigned int n2;
|
|
unsigned int m1;
|
|
unsigned int m2;
|
|
unsigned int dual;
|
|
};
|
|
|
|
struct meson_clk_dualdiv_data {
|
|
struct parm n1;
|
|
struct parm n2;
|
|
struct parm m1;
|
|
struct parm m2;
|
|
struct parm dual;
|
|
const struct meson_clk_dualdiv_param *table;
|
|
};
|
|
|
|
extern const struct clk_ops meson_clk_dualdiv_ops;
|
|
extern const struct clk_ops meson_clk_dualdiv_ro_ops;
|
|
|
|
#endif /* __MESON_CLK_DUALDIV_H */
|