diff options
Diffstat (limited to 'drivers/ps3')
-rw-r--r-- | drivers/ps3/vuart.c | 17 | ||||
-rw-r--r-- | drivers/ps3/vuart.h | 1 |
2 files changed, 18 insertions, 0 deletions
diff --git a/drivers/ps3/vuart.c b/drivers/ps3/vuart.c index a72da8f651f8..ef8fd4c30875 100644 --- a/drivers/ps3/vuart.c +++ b/drivers/ps3/vuart.c | |||
@@ -867,6 +867,22 @@ static int ps3_vuart_remove(struct device *_dev) | |||
867 | return 0; | 867 | return 0; |
868 | } | 868 | } |
869 | 869 | ||
870 | static void ps3_vuart_shutdown(struct device *_dev) | ||
871 | { | ||
872 | struct ps3_vuart_port_device *dev = to_ps3_vuart_port_device(_dev); | ||
873 | struct ps3_vuart_port_driver *drv = | ||
874 | to_ps3_vuart_port_driver(_dev->driver); | ||
875 | |||
876 | dev_dbg(&dev->core, "%s:%d: %s\n", __func__, __LINE__, | ||
877 | dev->core.bus_id); | ||
878 | |||
879 | if (drv->shutdown) | ||
880 | drv->shutdown(dev); | ||
881 | else | ||
882 | dev_dbg(&dev->core, "%s:%d: %s no shutdown method\n", __func__, | ||
883 | __LINE__, dev->core.bus_id); | ||
884 | } | ||
885 | |||
870 | /** | 886 | /** |
871 | * ps3_vuart - The vuart instance. | 887 | * ps3_vuart - The vuart instance. |
872 | * | 888 | * |
@@ -878,6 +894,7 @@ struct bus_type ps3_vuart = { | |||
878 | .match = ps3_vuart_match, | 894 | .match = ps3_vuart_match, |
879 | .probe = ps3_vuart_probe, | 895 | .probe = ps3_vuart_probe, |
880 | .remove = ps3_vuart_remove, | 896 | .remove = ps3_vuart_remove, |
897 | .shutdown = ps3_vuart_shutdown, | ||
881 | }; | 898 | }; |
882 | 899 | ||
883 | int __init ps3_vuart_init(void) | 900 | int __init ps3_vuart_init(void) |
diff --git a/drivers/ps3/vuart.h b/drivers/ps3/vuart.h index 11c421cf7a03..2cbf728a3a0b 100644 --- a/drivers/ps3/vuart.h +++ b/drivers/ps3/vuart.h | |||
@@ -30,6 +30,7 @@ struct ps3_vuart_port_driver { | |||
30 | struct device_driver core; | 30 | struct device_driver core; |
31 | int (*probe)(struct ps3_vuart_port_device *); | 31 | int (*probe)(struct ps3_vuart_port_device *); |
32 | int (*remove)(struct ps3_vuart_port_device *); | 32 | int (*remove)(struct ps3_vuart_port_device *); |
33 | void (*shutdown)(struct ps3_vuart_port_device *); | ||
33 | int (*tx_event)(struct ps3_vuart_port_device *dev); | 34 | int (*tx_event)(struct ps3_vuart_port_device *dev); |
34 | int (*rx_event)(struct ps3_vuart_port_device *dev); | 35 | int (*rx_event)(struct ps3_vuart_port_device *dev); |
35 | int (*disconnect_event)(struct ps3_vuart_port_device *dev); | 36 | int (*disconnect_event)(struct ps3_vuart_port_device *dev); |