clk: tegra: Constify peripheral clock registers
The peripheral clock registers are defined in static tables. These tables never need to be modified at runtime, so they can reside in read-only memory. Signed-off-by: Thierry Reding <treding@nvidia.com>
This commit is contained in:
@@ -84,7 +84,7 @@ static int (*special_reset_assert)(unsigned long);
|
||||
static int (*special_reset_deassert)(unsigned long);
|
||||
static unsigned int num_special_reset;
|
||||
|
||||
static struct tegra_clk_periph_regs periph_regs[] = {
|
||||
static const struct tegra_clk_periph_regs periph_regs[] = {
|
||||
[0] = {
|
||||
.enb_reg = CLK_OUT_ENB_L,
|
||||
.enb_set_reg = CLK_OUT_ENB_SET_L,
|
||||
@@ -182,7 +182,7 @@ static int tegra_clk_rst_deassert(struct reset_controller_dev *rcdev,
|
||||
return -EINVAL;
|
||||
}
|
||||
|
||||
struct tegra_clk_periph_regs *get_reg_bank(int clkid)
|
||||
const struct tegra_clk_periph_regs *get_reg_bank(int clkid)
|
||||
{
|
||||
int reg_bank = clkid / 32;
|
||||
|
||||
|
Reference in New Issue
Block a user