Message ID | 1581068800-13817-2-git-send-email-qiwuchen55@gmail.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
Series | [1/2] pstore/platform: fix potential mem leak if pstore_init_fs failed | expand |
On Fri, Feb 07, 2020 at 05:46:40PM +0800, qiwuchen55@gmail.com wrote: > From: chenqiwu <chenqiwu@xiaomi.com> > > Remove unnecessary ramoops_unregister_dummy() if ramoops > platform device register failed. > > Signed-off-by: chenqiwu <chenqiwu@xiaomi.com> Thanks! Applied to for-next/pstore. -Kees > --- > fs/pstore/ram.c | 1 - > 1 file changed, 1 deletion(-) > > diff --git a/fs/pstore/ram.c b/fs/pstore/ram.c > index 013486b..7956221 100644 > --- a/fs/pstore/ram.c > +++ b/fs/pstore/ram.c > @@ -963,7 +963,6 @@ static void __init ramoops_register_dummy(void) > pr_info("could not create platform device: %ld\n", > PTR_ERR(dummy)); > dummy = NULL; > - ramoops_unregister_dummy(); > } > } > > -- > 1.9.1 >
diff --git a/fs/pstore/ram.c b/fs/pstore/ram.c index 013486b..7956221 100644 --- a/fs/pstore/ram.c +++ b/fs/pstore/ram.c @@ -963,7 +963,6 @@ static void __init ramoops_register_dummy(void) pr_info("could not create platform device: %ld\n", PTR_ERR(dummy)); dummy = NULL; - ramoops_unregister_dummy(); } }