Thanks to visit codestin.com
Credit goes to github.com

Skip to content
Closed
Show file tree
Hide file tree
Changes from 10 commits
Commits
Show all changes
78 commits
Select commit Hold shift + click to select a range
eebe170
Merge branches 'sunxi/clk-for-4.15', 'sunxi/dt-for-4.15' and 'sunxi/d…
mripard Sep 17, 2017
1718bc7
Merge branch 'sunxi/core-for-4.15' into sunxi/for-next
mripard Sep 22, 2017
3b428b0
Merge branches 'sunxi/dt-for-4.15' and 'sunxi/dt64-for-4.15' into sun…
wens Sep 27, 2017
67bf861
Merge branches 'sunxi/clk-for-4.15' and 'sunxi/dt64-for-4.15' into su…
wens Sep 29, 2017
bba731a
Merge branch 'sunxi/clk-for-4.15' into sunxi/for-next
mripard Oct 6, 2017
42d7dbe
Merge branches 'sunxi/clk-for-4.15' and 'sunxi/dt-for-4.15' into sunx…
wens Oct 11, 2017
be2aeaf
Merge branch 'sunxi/for-next', remote-tracking branch 'drm-misc/drm-m…
wens Oct 11, 2017
2960446
Merge remote-tracking branch 'regulator/topic/axp20x' into sunxi-next
wens Oct 11, 2017
10d1bcf
Merge branches 'sunxi/clk-for-4.15' and 'sunxi/dt-for-4.15' into sunx…
mripard Oct 13, 2017
3be7629
Merge branch 'sunxi/for-next' into sunxi-next
wens Oct 13, 2017
9221d86
Merge remote-tracking branch 'bluetooth-next/master' into sunxi-next
wens Oct 16, 2017
36680a7
Merge branches 'sunxi/clk-for-4.15' and 'sunxi/dt-for-4.15' into sunx…
wens Oct 18, 2017
217a487
Merge branch 'sunxi/for-next' into sunxi-next
wens Oct 18, 2017
8c95670
Merge remote-tracking branch 'drm-misc/drm-misc-next' into sunxi-next
wens Oct 18, 2017
8c05c03
Merge branch 'sunxi/dt-for-4.15' into sunxi/for-next
wens Oct 22, 2017
54c9bca
Merge branch 'sunxi/for-next' into sunxi-next
wens Oct 22, 2017
dad1b42
Merge remote-tracking branch 'slave-dma/topic/sun' into sunxi-next
wens Oct 23, 2017
b599669
Merge branches 'sunxi/dt-for-4.15' and 'sunxi/dt64-for-4.15' into sun…
mripard Nov 2, 2017
9dad3f6
Merge remote-tracking branch 'mfd/for-mfd-next' into sunxi-next
wens Nov 2, 2017
f9a642e
Merge remote-tracking branch 'sunxi-korg/sunxi/for-next' into sunxi-next
wens Nov 2, 2017
c3d8195
Merge remote-tracking branch 'asoc/topic/sunxi' into sunxi-next
wens Nov 9, 2017
c74b34f
fbdev: ssd1306: abort probe if we cannot talk to the display
oliv3r Aug 8, 2017
0bed2fc
fbdev: ssd1307: rename i2c device ids
oliv3r Dec 19, 2017
3b4ca60
fbdev: ssd1306: make output a little more consistent
oliv3r Dec 18, 2017
bc8c3e6
fbdev: ssd1306: use ratelimited error printing
oliv3r Dec 18, 2017
e19c8b8
leds: pca963x: abort probe if device is not connected
oliv3r Aug 8, 2017
683f502
leds: pca963x: alphabetize headers
May 29, 2015
e516b80
leds: pca963x: add defines and remove some magic values
oliv3r Dec 16, 2015
4121ef1
leds: pca963x: save mode when setting power_state
oliv3r Oct 4, 2017
10fd376
leds: pca963x: refactor initial led output a little
oliv3r Oct 4, 2017
1568dc6
leds: pca963x: remove whitespace and checkpatch problems
oliv3r Apr 5, 2016
acf0551
leds: pca963x: set DMBLNK as default during probe
oliv3r Mar 17, 2017
ed038f4
mfd: axp20x: fixup includes
oliv3r Jan 3, 2017
4a4efcf
mfd: axp20x: use explicit bit defines
Oct 4, 2017
03ce04d
power: suppy: axp20x: add missing include bitops.h
oliv3r Jan 3, 2017
dd35aa4
power: suppy: axp288: use the BIT() macro
oliv3r Jan 3, 2017
13b162f
regulator: axp20x: use defines for masks
oliv3r Jan 3, 2017
bb946f3
regulator: axp20x: name voltage ramping define properly
oliv3r Oct 9, 2017
27bef6e
regulator: enable power later when setting up constraints
Mar 6, 2017
c4c4e61
regulator: axp20x: AXP209: add support for set_ramp_delay
oliv3r Mar 2, 2017
aee0eb0
regulator: axp20x: add software based soft_start for LDO3
oliv3r Mar 2, 2017
eedcd47
arm: dts: sunxi: enable soft-start and ramp delay for the OLinuXino L…
oliv3r Mar 3, 2017
2d11ed2
dts: sunxi: Lime2: add full voltage range to LDO4
oliv3r Dec 11, 2017
d2ab365
dts: sunxi: OLinuXino Lime2: set proper lradc vref
oliv3r Dec 18, 2017
aeea6b1
pwm: core: do not block apply->state on period
oliv3r Mar 8, 2017
ed71150
input: of_touchscreen: fix whitespace
oliv3r Dec 11, 2017
de61fc5
input: of_touchscreen: shorten variable names
oliv3r Dec 11, 2017
3d28f05
input: of_touchscreen: rename touchscreen-size-[xy]
oliv3r Dec 11, 2017
fe30204
input: of_touchscreen: add support for minimum sizes
oliv3r Dec 13, 2017
688d6e2
input: edt-ft5x06: add support for the ft5426 controller
oliv3r Dec 13, 2017
0d4e3e7
input: edt-ft5x06: cleanup headers
oliv3r Dec 13, 2017
c957a5d
input: edt-ft5x06: only enable the irq when needed
oliv3r Dec 13, 2017
fb86a27
input: edt-ft5x06: fix some whitespace/ident issues
oliv3r Dec 14, 2017
d862555
input: edt-ft5x06: minor consistency cleanup/line length reduction
oliv3r Dec 14, 2017
5f01050
input: edt-ft5x06: shorten defines
oliv3r Dec 14, 2017
992e1c7
input: edt-ft5x06: use less magic and more defines
oliv3r Dec 15, 2017
046c810
input: edt-ft5x06: silence deferral error
oliv3r Dec 15, 2017
7207bb7
input: edt-ft5x06: sanity check on input
oliv3r Dec 18, 2017
b68c90b
input: edt-ft5x06: fix multi-touch handling
oliv3r Dec 18, 2017
cb474ef
input: edt-ft5x06: take into account the number of fingers
oliv3r Dec 18, 2017
15ecee1
input: edt-ft5x06: add polldev as an option
oliv3r Dec 18, 2017
5777ab1
input: edt-ft5x06: group r, w and rw functions
oliv3r Dec 19, 2017
4f8b339
input: edt-ft5x06: Force touchscreen to remain active
oliv3r Dec 19, 2017
93bf96d
input: ar1021: fix typo in define
oliv3r Oct 19, 2017
35ba713
gpio: pca953x: add support for the NXP pca9570
oliv3r Dec 18, 2017
8872877
ASoC: sun4i-is: also check for NULL on reset pin request
oliv3r Oct 9, 2017
b126923
serial: 8250_dw: minor code cleanup
oliv3r Mar 29, 2017
40d3e78
serial: do not treat the IIR register as a bitfield
oliv3r Mar 29, 2017
6b66bba
serial: tegra: map the iir register to default defines
oliv3r Mar 29, 2017
0365eb6
serial work
oliv3r Apr 21, 2017
7d6eb22
drm/sun4i: i2c: consolidate ddc items
oliv3r Sep 4, 2017
0200fbe
drm: sun4i: fix indenting
oliv3r Oct 10, 2017
80e9170
wip hdmi-i2c, TODO: legacy clocks not working
oliv3r Oct 20, 2017
beb2e13
fix whitespace (kconfig)
oliv3r Feb 6, 2018
6d00bfc
fix hdmi freq divider
oliv3r Feb 6, 2018
795cc47
rtc: sun6i: add missing header
oliv3r Feb 6, 2018
14d6182
of_get_matching_data
oliv3r Feb 6, 2018
ac68ebb
of_reset_control_get_exclusive helper
oliv3r Feb 6, 2018
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions drivers/clk/sunxi-ng/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ lib-$(CONFIG_SUNXI_CCU) += ccu_gate.o
lib-$(CONFIG_SUNXI_CCU) += ccu_mux.o
lib-$(CONFIG_SUNXI_CCU) += ccu_mult.o
lib-$(CONFIG_SUNXI_CCU) += ccu_phase.o
lib-$(CONFIG_SUNXI_CCU) += ccu_sdm.o

# Multi-factor clocks
lib-$(CONFIG_SUNXI_CCU) += ccu_nk.o
Expand Down
26 changes: 20 additions & 6 deletions drivers/clk/sunxi-ng/ccu-sun4i-a10.c
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@
#include "ccu_nkmp.h"
#include "ccu_nm.h"
#include "ccu_phase.h"
#include "ccu_sdm.h"

#include "ccu-sun4i-a10.h"

Expand All @@ -51,16 +52,29 @@ static struct ccu_nkmp pll_core_clk = {
* the base (2x, 4x and 8x), and one variable divider (the one true
* pll audio).
*
* We don't have any need for the variable divider for now, so we just
* hardcode it to match with the clock names.
* With sigma-delta modulation for fractional-N on the audio PLL,
* we have to use specific dividers. This means the variable divider
* can no longer be used, as the audio codec requests the exact clock
* rates we support through this mechanism. So we now hard code the
* variable divider to 1. This means the clock rates will no longer
* match the clock names.
*/
#define SUN4I_PLL_AUDIO_REG 0x008

static struct ccu_sdm_setting pll_audio_sdm_table[] = {
{ .rate = 22579200, .pattern = 0xc0010d84, .m = 8, .n = 7 },
{ .rate = 24576000, .pattern = 0xc000ac02, .m = 14, .n = 14 },
};

static struct ccu_nm pll_audio_base_clk = {
.enable = BIT(31),
.n = _SUNXI_CCU_MULT_OFFSET(8, 7, 0),
.m = _SUNXI_CCU_DIV_OFFSET(0, 5, 0),
.sdm = _SUNXI_CCU_SDM(pll_audio_sdm_table, 0,
0x00c, BIT(31)),
.common = {
.reg = 0x008,
.features = CCU_FEATURE_SIGMA_DELTA_MOD,
.hw.init = CLK_HW_INIT("pll-audio-base",
"hosc",
&ccu_nm_ops,
Expand Down Expand Up @@ -1021,9 +1035,9 @@ static struct ccu_common *sun4i_sun7i_ccu_clks[] = {
&out_b_clk.common
};

/* Post-divider for pll-audio is hardcoded to 4 */
/* Post-divider for pll-audio is hardcoded to 1 */
static CLK_FIXED_FACTOR(pll_audio_clk, "pll-audio",
"pll-audio-base", 4, 1, CLK_SET_RATE_PARENT);
"pll-audio-base", 1, 1, CLK_SET_RATE_PARENT);
static CLK_FIXED_FACTOR(pll_audio_2x_clk, "pll-audio-2x",
"pll-audio-base", 2, 1, CLK_SET_RATE_PARENT);
static CLK_FIXED_FACTOR(pll_audio_4x_clk, "pll-audio-4x",
Expand Down Expand Up @@ -1420,10 +1434,10 @@ static void __init sun4i_ccu_init(struct device_node *node,
return;
}

/* Force the PLL-Audio-1x divider to 4 */
/* Force the PLL-Audio-1x divider to 1 */
val = readl(reg + SUN4I_PLL_AUDIO_REG);
val &= ~GENMASK(29, 26);
writel(val | (4 << 26), reg + SUN4I_PLL_AUDIO_REG);
writel(val | (1 << 26), reg + SUN4I_PLL_AUDIO_REG);

/*
* Use the peripheral PLL6 as the AHB parent, instead of CPU /
Expand Down
27 changes: 20 additions & 7 deletions drivers/clk/sunxi-ng/ccu-sun5i.c
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@
#include "ccu_nkmp.h"
#include "ccu_nm.h"
#include "ccu_phase.h"
#include "ccu_sdm.h"

#include "ccu-sun5i.h"

Expand All @@ -49,11 +50,20 @@ static struct ccu_nkmp pll_core_clk = {
* the base (2x, 4x and 8x), and one variable divider (the one true
* pll audio).
*
* We don't have any need for the variable divider for now, so we just
* hardcode it to match with the clock names
* With sigma-delta modulation for fractional-N on the audio PLL,
* we have to use specific dividers. This means the variable divider
* can no longer be used, as the audio codec requests the exact clock
* rates we support through this mechanism. So we now hard code the
* variable divider to 1. This means the clock rates will no longer
* match the clock names.
*/
#define SUN5I_PLL_AUDIO_REG 0x008

static struct ccu_sdm_setting pll_audio_sdm_table[] = {
{ .rate = 22579200, .pattern = 0xc0010d84, .m = 8, .n = 7 },
{ .rate = 24576000, .pattern = 0xc000ac02, .m = 14, .n = 14 },
};

static struct ccu_nm pll_audio_base_clk = {
.enable = BIT(31),
.n = _SUNXI_CCU_MULT_OFFSET(8, 7, 0),
Expand All @@ -63,8 +73,11 @@ static struct ccu_nm pll_audio_base_clk = {
* offset
*/
.m = _SUNXI_CCU_DIV_OFFSET(0, 5, 0),
.sdm = _SUNXI_CCU_SDM(pll_audio_sdm_table, 0,
0x00c, BIT(31)),
.common = {
.reg = 0x008,
.features = CCU_FEATURE_SIGMA_DELTA_MOD,
.hw.init = CLK_HW_INIT("pll-audio-base",
"hosc",
&ccu_nm_ops,
Expand Down Expand Up @@ -597,9 +610,9 @@ static struct ccu_common *sun5i_a10s_ccu_clks[] = {
&iep_clk.common,
};

/* We hardcode the divider to 4 for now */
/* We hardcode the divider to 1 for now */
static CLK_FIXED_FACTOR(pll_audio_clk, "pll-audio",
"pll-audio-base", 4, 1, CLK_SET_RATE_PARENT);
"pll-audio-base", 1, 1, CLK_SET_RATE_PARENT);
static CLK_FIXED_FACTOR(pll_audio_2x_clk, "pll-audio-2x",
"pll-audio-base", 2, 1, CLK_SET_RATE_PARENT);
static CLK_FIXED_FACTOR(pll_audio_4x_clk, "pll-audio-4x",
Expand Down Expand Up @@ -980,10 +993,10 @@ static void __init sun5i_ccu_init(struct device_node *node,
return;
}

/* Force the PLL-Audio-1x divider to 4 */
/* Force the PLL-Audio-1x divider to 1 */
val = readl(reg + SUN5I_PLL_AUDIO_REG);
val &= ~GENMASK(19, 16);
writel(val | (3 << 16), reg + SUN5I_PLL_AUDIO_REG);
val &= ~GENMASK(29, 26);
writel(val | (0 << 26), reg + SUN5I_PLL_AUDIO_REG);

/*
* Use the peripheral PLL as the AHB parent, instead of CPU /
Expand Down
38 changes: 25 additions & 13 deletions drivers/clk/sunxi-ng/ccu-sun6i-a31.c
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@
#include "ccu_nkmp.h"
#include "ccu_nm.h"
#include "ccu_phase.h"
#include "ccu_sdm.h"

#include "ccu-sun6i-a31.h"

Expand All @@ -48,18 +49,29 @@ static SUNXI_CCU_NKM_WITH_GATE_LOCK(pll_cpu_clk, "pll-cpu",
* the base (2x, 4x and 8x), and one variable divider (the one true
* pll audio).
*
* We don't have any need for the variable divider for now, so we just
* hardcode it to match with the clock names
* With sigma-delta modulation for fractional-N on the audio PLL,
* we have to use specific dividers. This means the variable divider
* can no longer be used, as the audio codec requests the exact clock
* rates we support through this mechanism. So we now hard code the
* variable divider to 1. This means the clock rates will no longer
* match the clock names.
*/
#define SUN6I_A31_PLL_AUDIO_REG 0x008

static SUNXI_CCU_NM_WITH_GATE_LOCK(pll_audio_base_clk, "pll-audio-base",
"osc24M", 0x008,
8, 7, /* N */
0, 5, /* M */
BIT(31), /* gate */
BIT(28), /* lock */
CLK_SET_RATE_UNGATE);
static struct ccu_sdm_setting pll_audio_sdm_table[] = {
{ .rate = 22579200, .pattern = 0xc0010d84, .m = 8, .n = 7 },
{ .rate = 24576000, .pattern = 0xc000ac02, .m = 14, .n = 14 },
};

static SUNXI_CCU_NM_WITH_SDM_GATE_LOCK(pll_audio_base_clk, "pll-audio-base",
"osc24M", 0x008,
8, 7, /* N */
0, 5, /* M */
pll_audio_sdm_table, BIT(24),
0x284, BIT(31),
BIT(31), /* gate */
BIT(28), /* lock */
CLK_SET_RATE_UNGATE);

static SUNXI_CCU_NM_WITH_FRAC_GATE_LOCK(pll_video0_clk, "pll-video0",
"osc24M", 0x010,
Expand Down Expand Up @@ -950,9 +962,9 @@ static struct ccu_common *sun6i_a31_ccu_clks[] = {
&out_c_clk.common,
};

/* We hardcode the divider to 4 for now */
/* We hardcode the divider to 1 for now */
static CLK_FIXED_FACTOR(pll_audio_clk, "pll-audio",
"pll-audio-base", 4, 1, CLK_SET_RATE_PARENT);
"pll-audio-base", 1, 1, CLK_SET_RATE_PARENT);
static CLK_FIXED_FACTOR(pll_audio_2x_clk, "pll-audio-2x",
"pll-audio-base", 2, 1, CLK_SET_RATE_PARENT);
static CLK_FIXED_FACTOR(pll_audio_4x_clk, "pll-audio-4x",
Expand Down Expand Up @@ -1221,10 +1233,10 @@ static void __init sun6i_a31_ccu_setup(struct device_node *node)
return;
}

/* Force the PLL-Audio-1x divider to 4 */
/* Force the PLL-Audio-1x divider to 1 */
val = readl(reg + SUN6I_A31_PLL_AUDIO_REG);
val &= ~GENMASK(19, 16);
writel(val | (3 << 16), reg + SUN6I_A31_PLL_AUDIO_REG);
writel(val | (0 << 16), reg + SUN6I_A31_PLL_AUDIO_REG);

/* Force PLL-MIPI to MIPI mode */
val = readl(reg + SUN6I_A31_PLL_MIPI_REG);
Expand Down
38 changes: 25 additions & 13 deletions drivers/clk/sunxi-ng/ccu-sun8i-a23.c
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@
#include "ccu_nkmp.h"
#include "ccu_nm.h"
#include "ccu_phase.h"
#include "ccu_sdm.h"

#include "ccu-sun8i-a23-a33.h"

Expand All @@ -52,18 +53,29 @@ static struct ccu_nkmp pll_cpux_clk = {
* the base (2x, 4x and 8x), and one variable divider (the one true
* pll audio).
*
* We don't have any need for the variable divider for now, so we just
* hardcode it to match with the clock names
* With sigma-delta modulation for fractional-N on the audio PLL,
* we have to use specific dividers. This means the variable divider
* can no longer be used, as the audio codec requests the exact clock
* rates we support through this mechanism. So we now hard code the
* variable divider to 1. This means the clock rates will no longer
* match the clock names.
*/
#define SUN8I_A23_PLL_AUDIO_REG 0x008

static SUNXI_CCU_NM_WITH_GATE_LOCK(pll_audio_base_clk, "pll-audio-base",
"osc24M", 0x008,
8, 7, /* N */
0, 5, /* M */
BIT(31), /* gate */
BIT(28), /* lock */
CLK_SET_RATE_UNGATE);
static struct ccu_sdm_setting pll_audio_sdm_table[] = {
{ .rate = 22579200, .pattern = 0xc0010d84, .m = 8, .n = 7 },
{ .rate = 24576000, .pattern = 0xc000ac02, .m = 14, .n = 14 },
};

static SUNXI_CCU_NM_WITH_SDM_GATE_LOCK(pll_audio_base_clk, "pll-audio-base",
"osc24M", 0x008,
8, 7, /* N */
0, 5, /* M */
pll_audio_sdm_table, BIT(24),
0x284, BIT(31),
BIT(31), /* gate */
BIT(28), /* lock */
CLK_SET_RATE_UNGATE);

static SUNXI_CCU_NM_WITH_FRAC_GATE_LOCK(pll_video_clk, "pll-video",
"osc24M", 0x010,
Expand Down Expand Up @@ -538,9 +550,9 @@ static struct ccu_common *sun8i_a23_ccu_clks[] = {
&ats_clk.common,
};

/* We hardcode the divider to 4 for now */
/* We hardcode the divider to 1 for now */
static CLK_FIXED_FACTOR(pll_audio_clk, "pll-audio",
"pll-audio-base", 4, 1, CLK_SET_RATE_PARENT);
"pll-audio-base", 1, 1, CLK_SET_RATE_PARENT);
static CLK_FIXED_FACTOR(pll_audio_2x_clk, "pll-audio-2x",
"pll-audio-base", 2, 1, CLK_SET_RATE_PARENT);
static CLK_FIXED_FACTOR(pll_audio_4x_clk, "pll-audio-4x",
Expand Down Expand Up @@ -720,10 +732,10 @@ static void __init sun8i_a23_ccu_setup(struct device_node *node)
return;
}

/* Force the PLL-Audio-1x divider to 4 */
/* Force the PLL-Audio-1x divider to 1 */
val = readl(reg + SUN8I_A23_PLL_AUDIO_REG);
val &= ~GENMASK(19, 16);
writel(val | (3 << 16), reg + SUN8I_A23_PLL_AUDIO_REG);
writel(val | (0 << 16), reg + SUN8I_A23_PLL_AUDIO_REG);

/* Force PLL-MIPI to MIPI mode */
val = readl(reg + SUN8I_A23_PLL_MIPI_REG);
Expand Down
38 changes: 25 additions & 13 deletions drivers/clk/sunxi-ng/ccu-sun8i-h3.c
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@
#include "ccu_nkmp.h"
#include "ccu_nm.h"
#include "ccu_phase.h"
#include "ccu_sdm.h"

#include "ccu-sun8i-h3.h"

Expand All @@ -44,18 +45,29 @@ static SUNXI_CCU_NKMP_WITH_GATE_LOCK(pll_cpux_clk, "pll-cpux",
* the base (2x, 4x and 8x), and one variable divider (the one true
* pll audio).
*
* We don't have any need for the variable divider for now, so we just
* hardcode it to match with the clock names
* With sigma-delta modulation for fractional-N on the audio PLL,
* we have to use specific dividers. This means the variable divider
* can no longer be used, as the audio codec requests the exact clock
* rates we support through this mechanism. So we now hard code the
* variable divider to 1. This means the clock rates will no longer
* match the clock names.
*/
#define SUN8I_H3_PLL_AUDIO_REG 0x008

static SUNXI_CCU_NM_WITH_GATE_LOCK(pll_audio_base_clk, "pll-audio-base",
"osc24M", 0x008,
8, 7, /* N */
0, 5, /* M */
BIT(31), /* gate */
BIT(28), /* lock */
CLK_SET_RATE_UNGATE);
static struct ccu_sdm_setting pll_audio_sdm_table[] = {
{ .rate = 22579200, .pattern = 0xc0010d84, .m = 8, .n = 7 },
{ .rate = 24576000, .pattern = 0xc000ac02, .m = 14, .n = 14 },
};

static SUNXI_CCU_NM_WITH_SDM_GATE_LOCK(pll_audio_base_clk, "pll-audio-base",
"osc24M", 0x008,
8, 7, /* N */
0, 5, /* M */
pll_audio_sdm_table, BIT(24),
0x284, BIT(31),
BIT(31), /* gate */
BIT(28), /* lock */
CLK_SET_RATE_UNGATE);

static SUNXI_CCU_NM_WITH_FRAC_GATE_LOCK(pll_video_clk, "pll-video",
"osc24M", 0x0010,
Expand Down Expand Up @@ -707,9 +719,9 @@ static struct ccu_common *sun50i_h5_ccu_clks[] = {
&gpu_clk.common,
};

/* We hardcode the divider to 4 for now */
/* We hardcode the divider to 1 for now */
static CLK_FIXED_FACTOR(pll_audio_clk, "pll-audio",
"pll-audio-base", 4, 1, CLK_SET_RATE_PARENT);
"pll-audio-base", 1, 1, CLK_SET_RATE_PARENT);
static CLK_FIXED_FACTOR(pll_audio_2x_clk, "pll-audio-2x",
"pll-audio-base", 2, 1, CLK_SET_RATE_PARENT);
static CLK_FIXED_FACTOR(pll_audio_4x_clk, "pll-audio-4x",
Expand Down Expand Up @@ -1129,10 +1141,10 @@ static void __init sunxi_h3_h5_ccu_init(struct device_node *node,
return;
}

/* Force the PLL-Audio-1x divider to 4 */
/* Force the PLL-Audio-1x divider to 1 */
val = readl(reg + SUN8I_H3_PLL_AUDIO_REG);
val &= ~GENMASK(19, 16);
writel(val | (3 << 16), reg + SUN8I_H3_PLL_AUDIO_REG);
writel(val | (0 << 16), reg + SUN8I_H3_PLL_AUDIO_REG);

sunxi_ccu_probe(node, reg, desc);

Expand Down
1 change: 1 addition & 0 deletions drivers/clk/sunxi-ng/ccu_common.h
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@
#define CCU_FEATURE_ALL_PREDIV BIT(4)
#define CCU_FEATURE_LOCK_REG BIT(5)
#define CCU_FEATURE_MMC_TIMING_SWITCH BIT(6)
#define CCU_FEATURE_SIGMA_DELTA_MOD BIT(7)

/* MMC timing mode switch bit */
#define CCU_MMC_NEW_TIMING_MODE BIT(30)
Expand Down
Loading