Re: [PATCH v2] thunderbolt: Fix to check the return value of kmemdup

2019-03-25 Thread Mika Westerberg
On Sat, Mar 23, 2019 at 03:20:33PM -0500, Aditya Pakki wrote: > uuid in add_switch is allocted via kmemdup which can fail. The patch > logs the error and cleans up the allocated memory for switch. > > Signed-off-by: Aditya Pakki > > --- > v1: Change error handling from WARN_ONCE to return after

[PATCH v2] thunderbolt: Fix to check the return value of kmemdup

2019-03-23 Thread Aditya Pakki
uuid in add_switch is allocted via kmemdup which can fail. The patch logs the error and cleans up the allocated memory for switch. Signed-off-by: Aditya Pakki --- v1: Change error handling from WARN_ONCE to return after clean up. --- drivers/thunderbolt/icm.c | 5 + 1 file changed, 5 insert