Home
last modified time | relevance | path

Searched refs:sas_phy (Results 1 – 25 of 50) sorted by relevance

12

/Linux-v4.19/drivers/scsi/aic94xx/
Daic94xx_scb.c56 struct sas_phy *sas_phy = phy->sas_phy.phy; in get_lrate_mode() local
61 phy->sas_phy.linkrate = SAS_LINK_RATE_6_0_GBPS; in get_lrate_mode()
62 phy->sas_phy.phy->negotiated_linkrate = SAS_LINK_RATE_6_0_GBPS; in get_lrate_mode()
65 phy->sas_phy.linkrate = SAS_LINK_RATE_3_0_GBPS; in get_lrate_mode()
66 phy->sas_phy.phy->negotiated_linkrate = SAS_LINK_RATE_3_0_GBPS; in get_lrate_mode()
69 phy->sas_phy.linkrate = SAS_LINK_RATE_1_5_GBPS; in get_lrate_mode()
70 phy->sas_phy.phy->negotiated_linkrate = SAS_LINK_RATE_1_5_GBPS; in get_lrate_mode()
73 sas_phy->negotiated_linkrate = phy->sas_phy.linkrate; in get_lrate_mode()
74 sas_phy->maximum_linkrate_hw = SAS_LINK_RATE_3_0_GBPS; in get_lrate_mode()
75 sas_phy->minimum_linkrate_hw = SAS_LINK_RATE_1_5_GBPS; in get_lrate_mode()
[all …]
Daic94xx_hwi.c78 if (phy->sas_phy.role & PHY_ROLE_INITIATOR) in asd_init_phy_identify()
79 phy->identify_frame->initiator_bits = phy->sas_phy.iproto; in asd_init_phy_identify()
80 if (phy->sas_phy.role & PHY_ROLE_TARGET) in asd_init_phy_identify()
81 phy->identify_frame->target_bits = phy->sas_phy.tproto; in asd_init_phy_identify()
84 phy->identify_frame->phy_id = phy->sas_phy.id; in asd_init_phy_identify()
89 struct asd_ha_struct *asd_ha = phy->sas_phy.ha->lldd_ha; in asd_init_phy()
90 struct asd_sas_phy *sas_phy = &phy->sas_phy; in asd_init_phy() local
92 sas_phy->enabled = 1; in asd_init_phy()
93 sas_phy->class = SAS; in asd_init_phy()
94 sas_phy->iproto = SAS_PROTOCOL_ALL; in asd_init_phy()
[all …]
/Linux-v4.19/include/scsi/
Dscsi_transport_sas.h59 struct sas_phy { struct
88 container_of((d), struct sas_phy, dev) argument
174 int (*get_linkerrors)(struct sas_phy *);
177 int (*phy_reset)(struct sas_phy *, int);
178 int (*phy_enable)(struct sas_phy *, int);
179 int (*phy_setup)(struct sas_phy *);
180 void (*phy_release)(struct sas_phy *);
181 int (*set_phy_speed)(struct sas_phy *, struct sas_phy_linkrates *);
190 extern struct sas_phy *sas_phy_alloc(struct device *, int);
191 extern void sas_phy_free(struct sas_phy *);
[all …]
Dlibsas.h133 struct sas_phy *phy;
196 struct sas_phy *phy;
326 struct sas_phy *phy;
398 struct asd_sas_phy **sas_phy; /* array of valid pointers, must be set */ member
458 static inline void sas_put_local_phy(struct sas_phy *phy) in sas_put_local_phy()
674 int sas_set_phy_speed(struct sas_phy *phy,
676 int sas_phy_reset(struct sas_phy *phy, int hard_reset);
717 struct sas_phy *sas_get_local_phy(struct domain_device *dev);
/Linux-v4.19/drivers/scsi/libsas/
Dsas_host_smp.c25 struct sas_phy *phy; in sas_host_smp_discover()
34 phy = sas_ha->sas_phy[phy_id]->phy; in sas_host_smp_discover()
38 memcpy(resp_data + 24, sas_ha->sas_phy[phy_id]->attached_sas_addr, in sas_host_smp_discover()
45 if (!sas_ha->sas_phy[phy_id]->port || in sas_host_smp_discover()
46 !sas_ha->sas_phy[phy_id]->port->port_dev) in sas_host_smp_discover()
49 rphy = sas_ha->sas_phy[phy_id]->port->port_dev->rphy; in sas_host_smp_discover()
154 if (!sas_ha->sas_phy[phy_id]->port) in sas_report_phy_sata()
157 rphy = sas_ha->sas_phy[phy_id]->port->port_dev->rphy; in sas_report_phy_sata()
159 sas_ha->sas_phy[phy_id]->port->port_dev->frame_rcvd; in sas_report_phy_sata()
165 memcpy(resp_data + 16, sas_ha->sas_phy[phy_id]->attached_sas_addr, in sas_report_phy_sata()
[all …]
Dsas_init.c201 static int sas_get_linkerrors(struct sas_phy *phy) in sas_get_linkerrors()
206 struct asd_sas_phy *asd_phy = sas_ha->sas_phy[phy->number]; in sas_get_linkerrors()
243 static int transport_sas_phy_reset(struct sas_phy *phy, int hard_reset) in transport_sas_phy_reset()
255 struct asd_sas_phy *asd_phy = sas_ha->sas_phy[phy->number]; in transport_sas_phy_reset()
276 static int sas_phy_enable(struct sas_phy *phy, int enable) in sas_phy_enable()
289 struct asd_sas_phy *asd_phy = sas_ha->sas_phy[phy->number]; in sas_phy_enable()
309 int sas_phy_reset(struct sas_phy *phy, int hard_reset) in sas_phy_reset()
325 struct asd_sas_phy *asd_phy = sas_ha->sas_phy[phy->number]; in sas_phy_reset()
338 int sas_set_phy_speed(struct sas_phy *phy, in sas_set_phy_speed()
360 struct asd_sas_phy *asd_phy = sas_ha->sas_phy[phy->number]; in sas_set_phy_speed()
[all …]
Dsas_event.c119 struct asd_sas_phy *sas_phy; in sas_enable_revalidation() local
127 sas_phy = container_of(port->phy_list.next, struct asd_sas_phy, in sas_enable_revalidation()
129 ha->notify_port_event(sas_phy, PORTE_BROADCAST_RCVD); in sas_enable_revalidation()
Dsas_internal.h44 struct sas_phy *phy;
91 int sas_smp_get_phy_events(struct sas_phy *phy);
157 struct sas_phy *phy = p->phy; in sas_phy_set_target()
DMakefile26 sas_phy.o \
/Linux-v4.19/drivers/scsi/hisi_sas/
Dhisi_sas_main.c25 static int hisi_sas_control_phy(struct asd_sas_phy *sas_phy, enum phy_func func,
511 struct asd_sas_phy *sas_phy = &phy->sas_phy; in hisi_sas_bytes_dmaed() local
518 sas_ha->notify_phy_event(sas_phy, PHYE_OOB_DONE); in hisi_sas_bytes_dmaed()
520 if (sas_phy->phy) { in hisi_sas_bytes_dmaed()
521 struct sas_phy *sphy = sas_phy->phy; in hisi_sas_bytes_dmaed()
523 sphy->negotiated_linkrate = sas_phy->linkrate; in hisi_sas_bytes_dmaed()
545 sas_phy->frame_rcvd_size = phy->frame_rcvd_size; in hisi_sas_bytes_dmaed()
546 sas_ha->notify_port_event(sas_phy, PORTE_BYTES_DMAED); in hisi_sas_bytes_dmaed()
715 struct asd_sas_phy *sas_phy = &phy->sas_phy; in hisi_sas_phyup_work() local
716 int phy_no = sas_phy->id; in hisi_sas_phyup_work()
[all …]
Dhisi_sas_v3_hw.c460 struct asd_sas_phy *sas_phy = &phy->sas_phy; in init_reg_v3_hw() local
463 if (!sas_phy->phy || (sas_phy->phy->maximum_linkrate < in init_reg_v3_hw()
467 enum sas_linkrate max = sas_phy->phy->maximum_linkrate; in init_reg_v3_hw()
821 struct asd_sas_phy *sas_phy = &phy->sas_phy; in phys_init_v3_hw() local
823 if (!sas_phy->phy->enabled) in phys_init_v3_hw()
1165 struct asd_sas_phy *sas_phy = &phy->sas_phy; in phy_up_v3_hw() local
1181 sas_phy->linkrate = link_rate; in phy_up_v3_hw()
1204 sas_phy->oob_mode = SATA_OOB_MODE; in phy_up_v3_hw()
1207 memcpy(sas_phy->attached_sas_addr, in phy_up_v3_hw()
1210 memcpy(sas_phy->frame_rcvd, fis, in phy_up_v3_hw()
[all …]
Dhisi_sas_v2_hw.c1225 struct asd_sas_phy *sas_phy = &phy->sas_phy; in init_reg_v2_hw() local
1228 if (!sas_phy->phy || (sas_phy->phy->maximum_linkrate < in init_reg_v2_hw()
1232 enum sas_linkrate max = sas_phy->phy->maximum_linkrate; in init_reg_v2_hw()
1556 struct asd_sas_phy *sas_phy = &phy->sas_phy; in phy_get_events_v2_hw() local
1557 struct sas_phy *sphy = sas_phy->phy; in phy_get_events_v2_hw()
1578 struct asd_sas_phy *sas_phy = &phy->sas_phy; in phys_init_v2_hw() local
1580 if (!sas_phy->phy->enabled) in phys_init_v2_hw()
2601 struct asd_sas_phy *sas_phy; in hisi_sas_internal_abort_quirk_timeout() local
2609 list_for_each_entry(sas_phy, &asd_sas_port->phy_list, port_phy_el) { in hisi_sas_internal_abort_quirk_timeout()
2610 struct hisi_sas_phy *phy = sas_phy->lldd_phy; in hisi_sas_internal_abort_quirk_timeout()
[all …]
Dhisi_sas_v1_hw.c1372 struct asd_sas_phy *sas_phy = &phy->sas_phy; in int_phyup_v1_hw() local
1373 int i, phy_no = sas_phy->id; in int_phyup_v1_hw()
1375 u32 *frame_rcvd = (u32 *)sas_phy->frame_rcvd; in int_phyup_v1_hw()
1412 sas_phy->linkrate = link_rate; in int_phyup_v1_hw()
1413 sas_phy->oob_mode = SAS_OOB_MODE; in int_phyup_v1_hw()
1414 memcpy(sas_phy->attached_sas_addr, in int_phyup_v1_hw()
1458 struct asd_sas_phy *sas_phy = &phy->sas_phy; in int_bcast_v1_hw() local
1461 int phy_no = sas_phy->id; in int_bcast_v1_hw()
1475 sha->notify_port_event(sas_phy, PORTE_BROADCAST_RCVD); in int_bcast_v1_hw()
1489 struct asd_sas_phy *sas_phy = &phy->sas_phy; in int_abnormal_v1_hw() local
[all …]
/Linux-v4.19/drivers/scsi/smartpqi/
Dsmartpqi_sas_transport.c28 struct sas_phy *phy; in pqi_alloc_sas_phy()
50 struct sas_phy *phy = pqi_sas_phy->phy; in pqi_free_sas_phy()
63 struct sas_phy *phy; in pqi_sas_port_add_phy()
291 static int pqi_sas_get_linkerrors(struct sas_phy *phy) in pqi_sas_get_linkerrors()
307 static int pqi_sas_phy_reset(struct sas_phy *phy, int hard_reset) in pqi_sas_phy_reset()
312 static int pqi_sas_phy_enable(struct sas_phy *phy, int enable) in pqi_sas_phy_enable()
317 static int pqi_sas_phy_setup(struct sas_phy *phy) in pqi_sas_phy_setup()
322 static void pqi_sas_phy_release(struct sas_phy *phy) in pqi_sas_phy_release()
326 static int pqi_sas_phy_speed(struct sas_phy *phy, in pqi_sas_phy_speed()
/Linux-v4.19/drivers/scsi/mvsas/
Dmv_sas.c89 while (sha->sas_phy[j]) { in mvs_find_dev_mvi()
90 if (sha->sas_phy[j] == phy) in mvs_find_dev_mvi()
118 while (sha->sas_phy[j]) { in mvs_find_dev_phyno()
119 if (sha->sas_phy[j] == phy) in mvs_find_dev_phyno()
179 int mvs_phy_control(struct asd_sas_phy *sas_phy, enum phy_func func, in mvs_phy_control() argument
182 int rc = 0, phy_id = sas_phy->id; in mvs_phy_control()
184 struct sas_ha_struct *sha = sas_phy->ha; in mvs_phy_control()
187 while (sha->sas_phy[i]) { in mvs_phy_control()
188 if (sha->sas_phy[i] == sas_phy) in mvs_phy_control()
238 struct asd_sas_phy *sas_phy = &phy->sas_phy; in mvs_bytes_dmaed() local
[all …]
Dmv_init.c94 struct asd_sas_phy *sas_phy = &phy->sas_phy; in mvs_phy_init() local
99 sas_phy->enabled = (phy_id < mvi->chip->n_phy) ? 1 : 0; in mvs_phy_init()
100 sas_phy->class = SAS; in mvs_phy_init()
101 sas_phy->iproto = SAS_PROTOCOL_ALL; in mvs_phy_init()
102 sas_phy->tproto = 0; in mvs_phy_init()
103 sas_phy->type = PHY_TYPE_PHYSICAL; in mvs_phy_init()
104 sas_phy->role = PHY_ROLE_INITIATOR; in mvs_phy_init()
105 sas_phy->oob_mode = OOB_NOT_CONNECTED; in mvs_phy_init()
106 sas_phy->linkrate = SAS_LINK_RATE_UNKNOWN; in mvs_phy_init()
108 sas_phy->id = phy_id; in mvs_phy_init()
[all …]
Dmv_sas.h79 #define MVS_PHY_ID (1U << sas_phy->id)
224 struct asd_sas_phy sas_phy; member
454 int mvs_phy_control(struct asd_sas_phy *sas_phy, enum phy_func func,
465 void mvs_port_formed(struct asd_sas_phy *sas_phy);
466 void mvs_port_deformed(struct asd_sas_phy *sas_phy);
/Linux-v4.19/drivers/scsi/isci/
Dphy.c993 spin_lock_irqsave(&iphy->sas_phy.frame_rcvd_lock, flags); in sci_phy_frame_handler()
995 spin_unlock_irqrestore(&iphy->sas_phy.frame_rcvd_lock, flags); in sci_phy_frame_handler()
1036 spin_lock_irqsave(&iphy->sas_phy.frame_rcvd_lock, flags); in sci_phy_frame_handler()
1040 spin_unlock_irqrestore(&iphy->sas_phy.frame_rcvd_lock, flags); in sci_phy_frame_handler()
1403 iphy->sas_phy.enabled = 0; in isci_phy_init()
1404 iphy->sas_phy.id = index; in isci_phy_init()
1405 iphy->sas_phy.sas_addr = &iphy->sas_addr[0]; in isci_phy_init()
1406 iphy->sas_phy.frame_rcvd = (u8 *)&iphy->frame_rcvd; in isci_phy_init()
1407 iphy->sas_phy.ha = &ihost->sas_ha; in isci_phy_init()
1408 iphy->sas_phy.lldd_phy = iphy; in isci_phy_init()
[all …]
Dphy.h98 struct asd_sas_phy sas_phy; member
106 static inline struct isci_phy *to_iphy(struct asd_sas_phy *sas_phy) in to_iphy() argument
108 struct isci_phy *iphy = container_of(sas_phy, typeof(*iphy), sas_phy); in to_iphy()
Dport.c165 __func__, iphy, &iphy->sas_phy); in isci_port_bc_change_received()
167 ihost->sas_ha.notify_port_event(&iphy->sas_phy, PORTE_BROADCAST_RCVD); in isci_port_bc_change_received()
183 spin_lock_irqsave(&iphy->sas_phy.frame_rcvd_lock, flags); in isci_port_link_up()
190 iphy->sas_phy.oob_mode = SATA_OOB_MODE; in isci_port_link_up()
191 iphy->sas_phy.frame_rcvd_size = sizeof(struct dev_to_host_fis); in isci_port_link_up()
205 memcpy(&iphy->sas_phy.attached_sas_addr, in isci_port_link_up()
208 iphy->sas_phy.oob_mode = SAS_OOB_MODE; in isci_port_link_up()
209 iphy->sas_phy.frame_rcvd_size = sizeof(struct sas_identify_frame); in isci_port_link_up()
212 memcpy(iphy->sas_phy.attached_sas_addr, in isci_port_link_up()
219 iphy->sas_phy.phy->negotiated_linkrate = sci_phy_linkrate(iphy); in isci_port_link_up()
[all …]
/Linux-v4.19/drivers/scsi/pm8001/
Dpm8001_hwi.c3240 struct asd_sas_phy *sas_phy = &phy->sas_phy; in pm8001_bytes_dmaed() local
3246 if (sas_phy->phy) { in pm8001_bytes_dmaed()
3247 struct sas_phy *sphy = sas_phy->phy; in pm8001_bytes_dmaed()
3248 sphy->negotiated_linkrate = sas_phy->linkrate; in pm8001_bytes_dmaed()
3266 sas_phy->frame_rcvd_size = phy->frame_rcvd_size; in pm8001_bytes_dmaed()
3267 pm8001_ha->sas->notify_port_event(sas_phy, PORTE_BYTES_DMAED); in pm8001_bytes_dmaed()
3273 struct sas_phy *sas_phy = phy->sas_phy.phy; in pm8001_get_lrate_mode() local
3277 phy->sas_phy.linkrate = SAS_LINK_RATE_12_0_GBPS; in pm8001_get_lrate_mode()
3278 phy->sas_phy.phy->negotiated_linkrate = SAS_LINK_RATE_12_0_GBPS; in pm8001_get_lrate_mode()
3281 phy->sas_phy.linkrate = SAS_LINK_RATE_6_0_GBPS; in pm8001_get_lrate_mode()
[all …]
Dpm8001_init.c123 struct asd_sas_phy *sas_phy = &phy->sas_phy; in pm8001_phy_init() local
126 sas_phy->enabled = (phy_id < pm8001_ha->chip->n_phy) ? 1 : 0; in pm8001_phy_init()
127 sas_phy->class = SAS; in pm8001_phy_init()
128 sas_phy->iproto = SAS_PROTOCOL_ALL; in pm8001_phy_init()
129 sas_phy->tproto = 0; in pm8001_phy_init()
130 sas_phy->type = PHY_TYPE_PHYSICAL; in pm8001_phy_init()
131 sas_phy->role = PHY_ROLE_INITIATOR; in pm8001_phy_init()
132 sas_phy->oob_mode = OOB_NOT_CONNECTED; in pm8001_phy_init()
133 sas_phy->linkrate = SAS_LINK_RATE_UNKNOWN; in pm8001_phy_init()
134 sas_phy->id = phy_id; in pm8001_phy_init()
[all …]
Dpm80xx_hwi.c2893 phy->sas_phy.oob_mode = SAS_OOB_MODE; in hw_event_port_recover()
2968 phy->sas_phy.oob_mode = SAS_OOB_MODE; in hw_event_sas_phy_up()
2969 sas_ha->notify_phy_event(&phy->sas_phy, PHYE_OOB_DONE); in hw_event_sas_phy_up()
2970 spin_lock_irqsave(&phy->sas_phy.frame_rcvd_lock, flags); in hw_event_sas_phy_up()
2974 pm8001_get_attached_sas_addr(phy, phy->sas_phy.attached_sas_addr); in hw_event_sas_phy_up()
2975 spin_unlock_irqrestore(&phy->sas_phy.frame_rcvd_lock, flags); in hw_event_sas_phy_up()
3016 phy->sas_phy.oob_mode = SATA_OOB_MODE; in hw_event_sata_phy_up()
3017 sas_ha->notify_phy_event(&phy->sas_phy, PHYE_OOB_DONE); in hw_event_sata_phy_up()
3018 spin_lock_irqsave(&phy->sas_phy.frame_rcvd_lock, flags); in hw_event_sata_phy_up()
3024 pm8001_get_attached_sas_addr(phy, phy->sas_phy.attached_sas_addr); in hw_event_sata_phy_up()
[all …]
/Linux-v4.19/drivers/scsi/
Dscsi_transport_sas.c427 struct sas_phy *phy = transport_class_to_phy(dev); \
441 struct sas_phy *phy = transport_class_to_phy(dev); \
457 struct sas_phy *phy = transport_class_to_phy(dev); \
469 struct sas_phy *phy = transport_class_to_phy(dev); \
501 struct sas_phy *phy = transport_class_to_phy(dev); \
521 struct sas_phy *phy = transport_class_to_phy(dev); in show_sas_device_type()
532 struct sas_phy *phy = transport_class_to_phy(dev); in do_sas_phy_enable()
569 struct sas_phy *phy = transport_class_to_phy(dev); in show_sas_phy_enable()
580 struct sas_phy *phy = transport_class_to_phy(dev); in do_sas_phy_reset()
629 struct sas_phy *phy = dev_to_phy(dev); in sas_phy_setup()
[all …]
/Linux-v4.19/Documentation/scsi/
Dlibsas.txt42 struct sas_phy --------------------
47 struct sas_phy sas_phy;
54 initialize the sas_phy struct, along with your own
105 of your callbacks and passes you a phy. If the sas_phy is
144 sas_phy -- an array of pointers to structures. (see
147 num_phys -- the number of phys present in the sas_phy array,
157 void (*notify_port_event)(struct sas_phy *, enum port_event);
158 void (*notify_phy_event)(struct sas_phy *, enum phy_event);
167 void (*lldd_port_formed)(struct sas_phy *);
168 void (*lldd_port_deformed)(struct sas_phy *);
[all …]

12