Counter fixes for 7.2

A fix for microchip-tcb-capture to read the devicetree "reg" cell into a
 u32 variable to match the expected data type.
 -----BEGIN PGP SIGNATURE-----
 
 iHUEABYKAB0WIQSNN83d4NIlKPjon7a1SFbKvhIjKwUCanKmzAAKCRC1SFbKvhIj
 K9D8AP9S+jkZMclWio1OB6iwKRX4BVSQSJrsHiodVLRiBcvSigEAtH78hWxmq3zt
 GuJ86IV1zhS2S0Ezo5E9q0Ivxn0/PQQ=
 =VIpu
 -----END PGP SIGNATURE-----

Merge tag 'counter-fixes-for-7.2' of ssh://gitolite.kernel.org/pub/scm/linux/kernel/git/wbg/counter into char-misc-linus

William writes:

Counter fixes for 7.2

A fix for microchip-tcb-capture to read the devicetree "reg" cell into a
u32 variable to match the expected data type.

* tag 'counter-fixes-for-7.2' of ssh://gitolite.kernel.org/pub/scm/linux/kernel/git/wbg/counter:
  counter: microchip-tcb-capture: Fix DT channel validation
This commit is contained in:
Greg Kroah-Hartman 2026-08-06 11:03:41 +02:00
commit 2c30f97456

View File

@ -483,7 +483,7 @@ static int mchp_tc_probe(struct platform_device *pdev)
char clk_name[7];
struct regmap *regmap;
struct clk *clk[3];
int channel;
u32 channel;
int ret, i;
counter = devm_counter_alloc(&pdev->dev, sizeof(*priv));
@ -517,7 +517,7 @@ static int mchp_tc_probe(struct platform_device *pdev)
priv->channel[i] = channel;
snprintf(clk_name, sizeof(clk_name), "t%d_clk", channel);
snprintf(clk_name, sizeof(clk_name), "t%u_clk", channel);
clk[i] = of_clk_get_by_name(np->parent, clk_name);
if (IS_ERR(clk[i])) {