diff options
Diffstat (limited to 'include/scsi/libsas.h')
-rw-r--r-- | include/scsi/libsas.h | 17 |
1 files changed, 11 insertions, 6 deletions
diff --git a/include/scsi/libsas.h b/include/scsi/libsas.h index 0f9cbf96c093..ee1b25299dd6 100644 --- a/include/scsi/libsas.h +++ b/include/scsi/libsas.h | |||
@@ -292,6 +292,7 @@ struct asd_sas_port { | |||
292 | struct asd_sas_event { | 292 | struct asd_sas_event { |
293 | struct sas_work work; | 293 | struct sas_work work; |
294 | struct asd_sas_phy *phy; | 294 | struct asd_sas_phy *phy; |
295 | int event; | ||
295 | }; | 296 | }; |
296 | 297 | ||
297 | static inline struct asd_sas_event *to_asd_sas_event(struct work_struct *work) | 298 | static inline struct asd_sas_event *to_asd_sas_event(struct work_struct *work) |
@@ -301,17 +302,21 @@ static inline struct asd_sas_event *to_asd_sas_event(struct work_struct *work) | |||
301 | return ev; | 302 | return ev; |
302 | } | 303 | } |
303 | 304 | ||
305 | static inline void INIT_SAS_EVENT(struct asd_sas_event *ev, | ||
306 | void (*fn)(struct work_struct *), | ||
307 | struct asd_sas_phy *phy, int event) | ||
308 | { | ||
309 | INIT_SAS_WORK(&ev->work, fn); | ||
310 | ev->phy = phy; | ||
311 | ev->event = event; | ||
312 | } | ||
313 | |||
314 | |||
304 | /* The phy pretty much is controlled by the LLDD. | 315 | /* The phy pretty much is controlled by the LLDD. |
305 | * The class only reads those fields. | 316 | * The class only reads those fields. |
306 | */ | 317 | */ |
307 | struct asd_sas_phy { | 318 | struct asd_sas_phy { |
308 | /* private: */ | 319 | /* private: */ |
309 | struct asd_sas_event port_events[PORT_NUM_EVENTS]; | ||
310 | struct asd_sas_event phy_events[PHY_NUM_EVENTS]; | ||
311 | |||
312 | unsigned long port_events_pending; | ||
313 | unsigned long phy_events_pending; | ||
314 | |||
315 | int error; | 320 | int error; |
316 | int suspended; | 321 | int suspended; |
317 | 322 | ||