Re: [PATCH] dlpar: Fix a missing-check bug in dlpar_parse_cc_property()

2019-06-03 Thread Michael Ellerman
On Sun, 2019-05-26 at 02:42:40 UTC, Gen Zhang wrote: > In dlpar_parse_cc_property(), 'prop->name' is allocated by kstrdup(). > kstrdup() may return NULL, so it should be checked and handle error. > And prop should be freed if 'prop->name' is NULL. > > Signed-off-by: Gen Zhang > Acked-by: Nathan

[PATCH] dlpar: Fix a missing-check bug in dlpar_parse_cc_property()

2019-05-29 Thread Gen Zhang
In dlpar_parse_cc_property(), 'prop->name' is allocated by kstrdup(). kstrdup() may return NULL, so it should be checked and handle error. And prop should be freed if 'prop->name' is NULL. Signed-off-by: Gen Zhang Acked-by: Nathan Lynch --- diff --git a/arch/powerpc/platforms/pseries/dlpar.c

Re: [PATCH] dlpar: Fix a missing-check bug in dlpar_parse_cc_property()

2019-05-28 Thread Nathan Lynch
Gen Zhang writes: > In dlpar_parse_cc_property(), 'prop->name' is allocated by kstrdup(). > kstrdup() may return NULL, so it should be checked and handle error. > And prop should be freed if 'prop->name' is NULL. > > Signed-off-by: Gen Zhang > --- > diff --git

[PATCH] dlpar: Fix a missing-check bug in dlpar_parse_cc_property()

2019-05-25 Thread Gen Zhang
In dlpar_parse_cc_property(), 'prop->name' is allocated by kstrdup(). kstrdup() may return NULL, so it should be checked and handle error. And prop should be freed if 'prop->name' is NULL. Signed-off-by: Gen Zhang --- diff --git a/arch/powerpc/platforms/pseries/dlpar.c