Lines Matching refs:stdev

47 	struct switchtec_dev *stdev;  member
144 dev_err(&sndev->stdev->dev, in switchtec_ntb_part_op()
282 dev_dbg(&sndev->stdev->dev, "MW %d: part %d addr %pad size %pap\n", in switchtec_ntb_mw_set_trans()
299 dev_err(&sndev->stdev->dev, in switchtec_ntb_mw_set_trans()
325 dev_err(&sndev->stdev->dev, in switchtec_ntb_mw_set_trans()
421 struct switchtec_dev *stdev = sndev->stdev; in switchtec_ntb_part_link_speed() local
423 &stdev->mmio_part_cfg_all[partition]; in switchtec_ntb_part_link_speed()
426 u32 linksta = ioread32(&stdev->mmio_pff_csr[pff].pci_cap_region[13]); in switchtec_ntb_part_link_speed()
512 dev_info(&sndev->stdev->dev, "ntb link %s\n", in switchtec_ntb_link_status_update()
534 dev_info(&sndev->stdev->dev, "ntb link forced down\n"); in check_link_status_work()
552 static void switchtec_ntb_link_notification(struct switchtec_dev *stdev) in switchtec_ntb_link_notification() argument
554 struct switchtec_ntb *sndev = stdev->sndev; in switchtec_ntb_link_notification()
579 dev_dbg(&sndev->stdev->dev, "enabling link\n"); in switchtec_ntb_link_enable()
593 dev_dbg(&sndev->stdev->dev, "disabling link\n"); in switchtec_ntb_link_disable()
700 (unsigned long)sndev->stdev->mmio; in switchtec_ntb_peer_db_addr()
805 (unsigned long)sndev->stdev->mmio; in switchtec_ntb_peer_spad_addr()
846 sndev->ntb.pdev = sndev->stdev->pdev; in switchtec_ntb_init_sndev()
853 sndev->self_partition = sndev->stdev->partition; in switchtec_ntb_init_sndev()
855 sndev->mmio_ntb = sndev->stdev->mmio_ntb; in switchtec_ntb_init_sndev()
867 if (sndev->stdev->partition_count != 2) { in switchtec_ntb_init_sndev()
868 dev_err(&sndev->stdev->dev, in switchtec_ntb_init_sndev()
874 dev_err(&sndev->stdev->dev, in switchtec_ntb_init_sndev()
882 dev_err(&sndev->stdev->dev, in switchtec_ntb_init_sndev()
889 dev_err(&sndev->stdev->dev, in switchtec_ntb_init_sndev()
895 dev_dbg(&sndev->stdev->dev, "Partition ID %d of %d\n", in switchtec_ntb_init_sndev()
896 sndev->self_partition, sndev->stdev->partition_count); in switchtec_ntb_init_sndev()
941 dev_err(&sndev->stdev->dev, in config_rsvd_lut_win()
959 dev_err(&sndev->stdev->dev, in config_req_id_table()
975 dev_dbg(&sndev->stdev->dev, in config_req_id_table()
988 dev_err(&sndev->stdev->dev, in config_req_id_table()
1053 dev_err(&sndev->stdev->dev, in crosslink_setup_mws()
1090 &sndev->stdev->mmio_part_cfg_all[sndev->peer_partition]; in crosslink_enum_partition()
1093 &sndev->stdev->mmio_pff_csr[pff]; in crosslink_enum_partition()
1106 dev_dbg(&sndev->stdev->dev, in crosslink_enum_partition()
1132 dev_info(&sndev->stdev->dev, "Using crosslink configuration\n"); in switchtec_ntb_init_crosslink()
1137 dev_err(&sndev->stdev->dev, in switchtec_ntb_init_crosslink()
1163 sndev->mmio_xlink_win = pci_iomap_range(sndev->stdev->pdev, bar, in switchtec_ntb_init_crosslink()
1181 pci_iounmap(sndev->stdev->pdev, sndev->mmio_xlink_win); in switchtec_ntb_deinit_crosslink()
1207 dev_dbg(&sndev->stdev->dev, "MWs: %d direct, %d lut\n", in switchtec_ntb_init_mw()
1217 dev_dbg(&sndev->stdev->dev, "Peer MWs: %d direct, %d lut\n", in switchtec_ntb_init_mw()
1254 dev_dbg(&sndev->stdev->dev, "dbs: shift %d/%d, mask %016llx\n", in switchtec_ntb_init_db()
1301 sndev->self_shared->partition_id = sndev->stdev->partition; in switchtec_ntb_init_shared()
1305 resource_size_t sz = pci_resource_len(sndev->stdev->pdev, bar); in switchtec_ntb_init_shared()
1327 sndev->self_shared = dma_alloc_coherent(&sndev->stdev->pdev->dev, in switchtec_ntb_init_shared_mw()
1332 dev_err(&sndev->stdev->dev, in switchtec_ntb_init_shared_mw()
1345 sndev->peer_shared = pci_iomap(sndev->stdev->pdev, self_bar, LUT_SIZE); in switchtec_ntb_init_shared_mw()
1351 dev_dbg(&sndev->stdev->dev, "Shared MW Ready\n"); in switchtec_ntb_init_shared_mw()
1355 dma_free_coherent(&sndev->stdev->pdev->dev, LUT_SIZE, in switchtec_ntb_init_shared_mw()
1364 pci_iounmap(sndev->stdev->pdev, sndev->peer_shared); in switchtec_ntb_deinit_shared_mw()
1367 dma_free_coherent(&sndev->stdev->pdev->dev, LUT_SIZE, in switchtec_ntb_deinit_shared_mw()
1377 dev_dbg(&sndev->stdev->dev, "doorbell\n"); in switchtec_ntb_doorbell_isr()
1393 dev_dbg(&sndev->stdev->dev, "message: %d %08x\n", in switchtec_ntb_message_isr()
1414 event_irq = ioread32(&sndev->stdev->mmio_part_cfg->vep_vector_number); in switchtec_ntb_init_db_msg_irq()
1422 dev_dbg(&sndev->stdev->dev, "irqs - event: %d, db: %d, msgs: %d\n", in switchtec_ntb_init_db_msg_irq()
1433 sndev->doorbell_irq = pci_irq_vector(sndev->stdev->pdev, doorbell_irq); in switchtec_ntb_init_db_msg_irq()
1434 sndev->message_irq = pci_irq_vector(sndev->stdev->pdev, message_irq); in switchtec_ntb_init_db_msg_irq()
1466 dev_info(&sndev->stdev->dev, "reinitialize shared memory window\n"); in switchtec_ntb_reinit_peer()
1475 struct switchtec_dev *stdev = to_stdev(dev); in switchtec_ntb_add() local
1479 stdev->sndev = NULL; in switchtec_ntb_add()
1481 if (stdev->pdev->class != (PCI_CLASS_BRIDGE_OTHER << 8)) in switchtec_ntb_add()
1488 sndev->stdev = stdev; in switchtec_ntb_add()
1525 stdev->sndev = sndev; in switchtec_ntb_add()
1526 stdev->link_notifier = switchtec_ntb_link_notification; in switchtec_ntb_add()
1545 struct switchtec_dev *stdev = to_stdev(dev); in switchtec_ntb_remove() local
1546 struct switchtec_ntb *sndev = stdev->sndev; in switchtec_ntb_remove()
1551 stdev->link_notifier = NULL; in switchtec_ntb_remove()
1552 stdev->sndev = NULL; in switchtec_ntb_remove()