Skip to content

Commit e82b5b6

Browse files
committed
Merge tag 'at91-fixes-6.1' of https://git.kernel.org/pub/scm/linux/kernel/git/at91/linux into arm/fixes
AT91 fixes for 6.1 It contains: - signal name fix for a pin on SAMA7G5 - memory self-refresh fix for SAMA7G5 by avoid soft resetting AC DLL which can introduce glitches in RAM controller and lead to unexpected behavior - led support fix for lan966x-pcb8291 board by enabling sgpio node * tag 'at91-fixes-6.1' of https://git.kernel.org/pub/scm/linux/kernel/git/at91/linux: ARM: at91: pm: avoid soft resetting AC DLL ARM: dts: lan966x: Enable sgpio on pcb8291 ARM: dts: at91: sama7g5: fix signal name of pin PB2 Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Arnd Bergmann <[email protected]>
2 parents 67b7458 + cef8cdc commit e82b5b6

File tree

4 files changed

+31
-3
lines changed

4 files changed

+31
-3
lines changed

arch/arm/boot/dts/lan966x-pcb8291.dts

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -69,6 +69,12 @@
6969
pins = "GPIO_35", "GPIO_36";
7070
function = "can0_b";
7171
};
72+
73+
sgpio_a_pins: sgpio-a-pins {
74+
/* SCK, D0, D1, LD */
75+
pins = "GPIO_32", "GPIO_33", "GPIO_34", "GPIO_35";
76+
function = "sgpio_a";
77+
};
7278
};
7379

7480
&can0 {
@@ -118,6 +124,20 @@
118124
status = "okay";
119125
};
120126

127+
&sgpio {
128+
pinctrl-0 = <&sgpio_a_pins>;
129+
pinctrl-names = "default";
130+
microchip,sgpio-port-ranges = <0 3>, <8 11>;
131+
status = "okay";
132+
133+
gpio@0 {
134+
ngpios = <64>;
135+
};
136+
gpio@1 {
137+
ngpios = <64>;
138+
};
139+
};
140+
121141
&switch {
122142
status = "okay";
123143
};

arch/arm/boot/dts/sama7g5-pinfunc.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -261,7 +261,7 @@
261261
#define PIN_PB2__FLEXCOM6_IO0 PINMUX_PIN(PIN_PB2, 2, 1)
262262
#define PIN_PB2__ADTRG PINMUX_PIN(PIN_PB2, 3, 1)
263263
#define PIN_PB2__A20 PINMUX_PIN(PIN_PB2, 4, 1)
264-
#define PIN_PB2__FLEXCOM11_IO0 PINMUX_PIN(PIN_PB2, 6, 3)
264+
#define PIN_PB2__FLEXCOM11_IO1 PINMUX_PIN(PIN_PB2, 6, 3)
265265
#define PIN_PB3 35
266266
#define PIN_PB3__GPIO PINMUX_PIN(PIN_PB3, 0, 0)
267267
#define PIN_PB3__RF1 PINMUX_PIN(PIN_PB3, 1, 1)

arch/arm/mach-at91/pm_suspend.S

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -169,10 +169,15 @@ sr_ena_2:
169169
cmp tmp1, #UDDRC_STAT_SELFREF_TYPE_SW
170170
bne sr_ena_2
171171

172-
/* Put DDR PHY's DLL in bypass mode for non-backup modes. */
172+
/* Disable DX DLLs for non-backup modes. */
173173
cmp r7, #AT91_PM_BACKUP
174174
beq sr_ena_3
175175

176+
/* Do not soft reset the AC DLL. */
177+
ldr tmp1, [r3, DDR3PHY_ACDLLCR]
178+
bic tmp1, tmp1, DDR3PHY_ACDLLCR_DLLSRST
179+
str tmp1, [r3, DDR3PHY_ACDLLCR]
180+
176181
/* Disable DX DLLs. */
177182
ldr tmp1, [r3, #DDR3PHY_DX0DLLCR]
178183
orr tmp1, tmp1, #DDR3PHY_DXDLLCR_DLLDIS

include/soc/at91/sama7-ddr.h

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,10 @@
2626
#define DDR3PHY_PGSR (0x0C) /* DDR3PHY PHY General Status Register */
2727
#define DDR3PHY_PGSR_IDONE (1 << 0) /* Initialization Done */
2828

29-
#define DDR3PHY_ACIOCR (0x24) /* DDR3PHY AC I/O Configuration Register */
29+
#define DDR3PHY_ACDLLCR (0x14) /* DDR3PHY AC DLL Control Register */
30+
#define DDR3PHY_ACDLLCR_DLLSRST (1 << 30) /* DLL Soft Reset */
31+
32+
#define DDR3PHY_ACIOCR (0x24) /* DDR3PHY AC I/O Configuration Register */
3033
#define DDR3PHY_ACIOCR_CSPDD_CS0 (1 << 18) /* CS#[0] Power Down Driver */
3134
#define DDR3PHY_ACIOCR_CKPDD_CK0 (1 << 8) /* CK[0] Power Down Driver */
3235
#define DDR3PHY_ACIORC_ACPDD (1 << 3) /* AC Power Down Driver */

0 commit comments

Comments
 (0)