tpm_tis: fix the error handling of init_tis()
PATCH 1/1 tpm_tis: fix the error handling of init_tis()
From: Wei Yongjun <[email protected]>
Add the missing platform_driver_unregister() and remove the duplicate platform_device_unregister(force_pdev) in the error handling case.
--- drivers/char/tpm/tpm_tis.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/char/tpm/tpm_tis.c +1 -1
@@ -432,7 +432,7 @@ static int __init init_tis(void)acpi_bus_unregister_driver (&tis_acpi_driver); err_acpi:#endif -platform_device_unregister (force_pdev); +platform_driver_unregister (&tis_drv); err_platform:if (force_pdev)platform_device_unregister (force_pdev);
Quoted 9 lines · Wei Yongjun
From: Wei Yongjun <[email protected]>
Add the missing
platform_driver_unregister()and remove the duplicateplatform_device_unregister(force_pdev)in the error handling case.Fixes 00194826e6be ("tpm_tis: Clean up the force=1 module parameter")Signed-off-by Wei Yongjun <[email protected]>drivers/char/tpm/tpm_tis.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
Yep. Thanks
Jason
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most engaging tech sites, SlashDot.org! http://sdm.link/slashdot
Quoted 7 lines · Wei Yongjun
From: Wei Yongjun <[email protected]>
Add the missing
platform_driver_unregister()and remove the duplicateplatform_device_unregister(force_pdev)in the error handling case.Fixes 00194826e6be ("tpm_tis: Clean up the force=1 module parameter")Signed-off-by Wei Yongjun <[email protected]>
/Jarkko
Quoted 10 lines
--- drivers/char/tpm/tpm_tis.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)drivers/char/tpm/tpm_tis.c +0
-0
drivers/char/tpm/tpm_tis.c static int __init init_tis(void) · line 438
Quoted 8 lines
drivers/char/tpm/tpm_tis.c +1
-1@@ -432,7 +432,7 @@ static int __init init_tis(void)acpi_bus_unregister_driver (&tis_acpi_driver); err_acpi:#endif -platform_device_unregister (force_pdev); +platform_driver_unregister (&tis_drv); err_platform:if (force_pdev)platform_device_unregister (force_pdev);
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most engaging tech sites, SlashDot.org! http://sdm.link/slashdot
Jarkko Sakkinen
AppliedQuoted 10 lines · Jarkko Sakkinen
Quoted 7 lines · Wei Yongjun
From: Wei Yongjun <[email protected]>
Add the missing
platform_driver_unregister()and remove the duplicateplatform_device_unregister(force_pdev)in the error handling case.Fixes 00194826e6be ("tpm_tis: Clean up the force=1 module parameter")Signed-off-by Wei Yongjun <[email protected]>
I applied this and added cc to stable.
/Jarkko
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most engaging tech sites, SlashDot.org! http://sdm.link/slashdot