On 2020-04-25 13:51, Andy Shevchenko wrote: > device_create_file() is called the last in ->probe() but pca954x_cleanup(), > which is called earlier in error path, tries to remove never created file. > Move device_remove_file() call outside of pca954x_cleanup() to make it > slightly closer to what pca954x_init() is doing. > > Signed-off-by: Andy Shevchenko <andriy.shevchenko@xxxxxxxxxxxxxxx> Reviewed-by: Peter Rosin <peda@xxxxxxxxxx> Cheers, Peter