mirror of
git://git.kernel.org/pub/scm/linux/kernel/git/xiang/erofs.git
synced 2026-11-01 06:46:35 +01:00
Since commit7852028a35("mmc: block: register RPMB partition with the RPMB subsystem"), each mmc RPMB partition is represented by two device objects: - the mmc-owned device (`rpmb->dev`, backing the legacy /dev/mmcblkXrpmb char device) and - the rpmb-core device (`rdev`, backing /dev/rpmbN). The child RPMB device holds a reference to its parent, so the parent's release callback cannot be invoked if the child device is still registered. Remove rpmb_dev_unregister() from the parent release handler and unregister the child RPMB device in the remove path before tearing down the parent device. Also delete the extra blank line between mmc_blk_remove_rpmb_part() and {. Fixes:7852028a35("mmc: block: register RPMB partition with the RPMB subsystem") Cc: [email protected] Signed-off-by: Jiazi Li <[email protected]> Signed-off-by: Ao Sun <[email protected]> Reviewed-by: Avri Altman <[email protected]> Signed-off-by: Ulf Hansson <[email protected]>