[PATCH v2] spmi: Fix controller->node != parent->node breakage

AngeloGioacchino Del Regno angelogioacchino.delregno at collabora.com
Mon Jan 13 05:52:09 PST 2025


Il 13/01/25 14:02, Konrad Dybcio ha scritto:
> From: Konrad Dybcio <konrad.dybcio at oss.qualcomm.com>
> 
> On some platforms, like recent Qualcomm SoCs with multi-bus SPMI
> arbiters, controller->node must be assigned to the individual buses'
> subnodes, as the slave devices are children of these, like so:
> 
> arbiter at c400000
> 	spmi at c42d000
> 		pmic at 0
> 
> 	spmi at c432000
> 		pmic at 0
> 
> The commit referenced in Fixes changed that assignment, such that
> spmi_controller_alloc() always assumes the PMICs come directly under
> the arbiter node (which is true when there's only a single bus per
> controller).
> 
> Make controller->node specifiable to both benefit from Joe's refcount
> improvements and un-break the aforementioned platforms.
> 
> Fixes: 821b07853e32 ("spmi: hisi-spmi-controller: manage the OF node reference in device initialization and cleanup")
> Signed-off-by: Konrad Dybcio <konrad.dybcio at oss.qualcomm.com>

for spmi.c/.h, spmi-devres and for MediaTek:

Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno at collabora.com>

Cheers!



More information about the linux-arm-kernel mailing list