Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

pwm: loongson: Fix LOONGSON_PWM_FREQ_DEFAULT

Per the 7A1000 and 7A2000 user manual, the clock frequency of their
PWM controllers is 50 MHz, not 50 kHz.

Fixes: 2b62c89448dd ("pwm: Add Loongson PWM controller support")
Signed-off-by: Xi Ruoyao <xry111@xry111.site>
Reviewed-by: Binbin Zhou <zhoubinbin@loongson.cn>
Reviewed-by: Huacai Chen <chenhuacai@loongson.cn>
Link: https://lore.kernel.org/r/20250816104904.4779-2-xry111@xry111.site
Cc: stable@vger.kernel.org
Signed-off-by: Uwe Kleine-König <ukleinek@kernel.org>

authored by

Xi Ruoyao and committed by
Uwe Kleine-König
75604e9a 8f5ae30d

+1 -1
+1 -1
drivers/pwm/pwm-loongson.c
··· 49 49 #define LOONGSON_PWM_CTRL_REG_DZONE BIT(10) /* Anti-dead Zone Enable Bit */ 50 50 51 51 /* default input clk frequency for the ACPI case */ 52 - #define LOONGSON_PWM_FREQ_DEFAULT 50000 /* Hz */ 52 + #define LOONGSON_PWM_FREQ_DEFAULT 50000000 /* Hz */ 53 53 54 54 struct pwm_loongson_ddata { 55 55 struct clk *clk;