The transport registration may fail. Make sure the errors are propagated to the callers.
Showing the changes to include/linux (1 of 2 files). Show all
Unified · Split
| @@ -62,16 +62,16 @@ struct transport_container { · 61 unmodified lines | |||
| 62 | container_of(x, struct transport_container, ac) | 62 | container_of(x, struct transport_container, ac) |
| 63 | 63 | ||
| 64 | void transport_remove_device(struct device *); | 64 | void transport_remove_device(struct device *); |
| 65 | void transport_add_device(struct device *); | 65 | int transport_add_device(struct device *); |
| 66 | void transport_setup_device(struct device *); | 66 | void transport_setup_device(struct device *); |
| 67 | void transport_configure_device(struct device *); | 67 | void transport_configure_device(struct device *); |
| 68 | void transport_destroy_device(struct device *); | 68 | void transport_destroy_device(struct device *); |
| 69 | 69 | ||
| 70 | static inline void | 70 | static inline int |
| 71 | transport_register_device(struct device *dev) | 71 | transport_register_device(struct device *dev) |
| 72 | { | 72 | { |
| 73 | transport_setup_device(dev); | 73 | transport_setup_device(dev); |
| 74 | transport_add_device(dev); | 74 | return transport_add_device(dev); |
| 75 | } | 75 | } |
| 76 | 76 | ||
| 77 | static inline void | 77 | static inline void |