Lines Matching full:pdc
7 * Broadcom PDC Mailbox Driver
8 * The PDC provides a ring based programming interface to one or more hardware
9 * offload engines. For example, the PDC driver works with both SPU-M and SPU2
10 * cryptographic offload hardware. In some chips the PDC is referred to as MDE,
11 * and in others the FA2/FA+ hardware is used with this PDC driver.
13 * The PDC driver registers with the Linux mailbox framework as a mailbox
14 * controller, once for each PDC instance. Ring 0 for each PDC is registered as
15 * a mailbox channel. The PDC driver uses interrupts to determine when data
16 * transfers to and from an offload engine are complete. The PDC driver uses
20 * The PDC driver allows multiple messages to be pending in the descriptor
24 * an rx interrupt indicates a response is ready, the PDC driver processes numd
52 /* # entries in PDC dma ring */
83 * PDC driver reserves ringset 0 on each SPU for its own use. The driver does
84 * not currently support use of multiple ringsets on a single PDC engine.
158 PDC_HW /* PDC/MDE hardware (i.e. Northstar 2, Pegasus) */
194 /* PDC registers */
206 u32 intrcvlazy_0; /* 0x030 (Only in PDC, not FA2) */
207 u32 intrcvlazy_1; /* 0x034 (Only in PDC, not FA2) */
208 u32 intrcvlazy_2; /* 0x038 (Only in PDC, not FA2) */
209 u32 intrcvlazy_3; /* 0x03c (Only in PDC, not FA2) */
212 u32 fa_intrecvlazy; /* 0x100 (Only in FA2, not PDC) */
238 u32 hw_war; /* 0x1e4 (Only in PDC, not FA2) */
276 /* PDC state structure */
278 /* Index of the PDC whose state is in this structure instance */
281 /* Platform device for this PDC instance */
285 * Each PDC instance has a mailbox controller. PDC receives request
319 struct pdc_regs *regs; /* start of PDC registers */
404 /* hardware type - FA2 or PDC/MDE */
417 /* top level debug FS directory for PDC driver */
438 "PDC requests....................%u\n", in pdc_debugfs_read()
441 "PDC responses...................%u\n", in pdc_debugfs_read()
484 * @pdcs: PDC state structure
493 snprintf(spu_stats_name, 16, "pdc%d_stats", pdcs->pdc_idx); in pdc_setup_debugfs()
510 * @pdcs: PDC state for SPU that will generate result
523 "Writing rx descriptor for PDC %u at index %u with length %u. flags %#x\n", in pdc_build_rxd()
538 * @pdcs: PDC state for the SPU that will process this request
551 "Writing tx descriptor for PDC %u at index %u with length %u, flags %#x\n", in pdc_build_txd()
565 * @pdcs: PDC state for the SPU to receive from
612 dev_dbg(dev, "PDC %u reclaimed %d tx descriptors", in pdc_receive_one()
628 dev_dbg(dev, "PDC %u reclaimed %d rx descriptors", in pdc_receive_one()
632 "PDC %u txin %u, txout %u, rxin %u, rxout %u, last_rx_curr %u\n", in pdc_receive_one()
666 * @pdcs: PDC state
693 * @pdcs: PDC state for the SPU that will process this request
742 * If sg buffer larger than PDC limit, split across in pdc_tx_list_sg_add()
775 * @pdcs: PDC state for SPU to process the request
796 * pdc_rx_list_init() - Start a new receive descriptor list for a given PDC.
797 * @pdcs: PDC state for SPU handling request
860 * @pdcs: PDC state for the SPU that will process this request
900 * If sg buffer larger than PDC limit, split across in pdc_rx_list_sg_add()
974 * @pdcs: PDC instance state
1114 * @pdcs: PDC state
1151 * Return: true if PDC can accept another message on this channel
1265 "Shutdown mailbox channel for PDC %u", pdcs->pdc_idx); in pdc_shutdown()
1272 * @pdcs: state of the PDC
1285 dev_dbg(dev, "PDC %u initial values:", pdcs->pdc_idx); in pdc_hw_init()
1325 * @pdcs: PDC state structure
1341 * @pdcs: PDC state structure
1343 * The metadata is not returned to the mailbox client. So the PDC driver
1361 pdcs->rx_buf_pool = dma_pool_create("pdc rx bufs", dev, in pdc_rx_buf_pool_create()
1371 * pdc_interrupts_init() - Initialize the interrupt configuration for a PDC and
1374 * @pdcs: PDC state
1401 dev_dbg(dev, "pdc device %s irq %u for pdcs %p", in pdc_interrupts_init()
1423 * @pdcs: PDC state
1425 * Each PDC is a mailbox controller. Each ringset is a mailbox channel. Kernel
1426 * driver only uses one ringset and thus one mb channel. PDC uses the transmit
1459 "Failed to register PDC mailbox controller. Error %d.", in pdc_mb_init()
1471 {.compatible = "brcm,iproc-pdc-mbox", .data = &pdc_hw},
1480 * @pdcs: PDC state
1515 * pdc_probe() - Probe function for PDC driver.
1516 * @pdev: PDC platform device
1520 * Initialize a mailbox controller for each PDC.
1532 /* PDC state for one SPU */ in pdc_probe()
1546 dev_warn(dev, "PDC device cannot perform DMA. Error %d.", err); in pdc_probe()
1551 pdcs->ring_pool = dma_pool_create("pdc rings", dev, PDC_RING_SIZE, in pdc_probe()
1567 dev_dbg(dev, "PDC register region res.start = %pa, res.end = %pa", in pdc_probe()
1623 .name = "brcm-iproc-pdc-mbox",
1630 MODULE_DESCRIPTION("Broadcom PDC mailbox driver");