usb: sierra: fix a missing check of device_create_file
authorKangjie Lu <kjlu@umn.edu>
Mon, 25 Mar 2019 03:08:28 +0000 (22:08 -0500)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 26 Mar 2019 07:42:52 +0000 (16:42 +0900)
commit1a137b47ce6bd4f4b14662d2f5ace913ea7ffbf8
tree7e4c3959a045eade84af2ad671329517bc2ae678
parentf926da42218c9d6a6e34a314cd5c9535bcd81627
usb: sierra: fix a missing check of device_create_file

device_create_file() could fail and return an error code. The fix
captures the error and returns the error code upstream in case it
indeed failed.

Signed-off-by: Kangjie Lu <kjlu@umn.edu>
Acked-by: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/usb/storage/sierra_ms.c