Home
last modified time | relevance | path

Searched refs:dbt (Results 1 – 14 of 14) sorted by relevance

/linux-6.1.9/drivers/net/can/dev/
Dcalc_bittiming.c179 const struct can_bittiming *dbt, in can_calc_tdco() argument
192 if (dbt->brp == 1 || dbt->brp == 2) { in can_calc_tdco()
194 u32 sample_point_in_tc = (CAN_SYNC_SEG + dbt->prop_seg + in can_calc_tdco()
195 dbt->phase_seg1) * dbt->brp; in can_calc_tdco()
Dnetlink.c271 struct can_bittiming dbt; in can_changelink() local
286 memcpy(&dbt, nla_data(data[IFLA_CAN_DATA_BITTIMING]), in can_changelink()
287 sizeof(dbt)); in can_changelink()
288 err = can_get_bittiming(dev, &dbt, in can_changelink()
295 if (priv->bitrate_max && dbt.bitrate > priv->bitrate_max) { in can_changelink()
320 memcpy(&priv->data_bittiming, &dbt, sizeof(dbt)); in can_changelink()
/linux-6.1.9/include/linux/can/
Ddev.h117 const struct can_bittiming *dbt = &priv->data_bittiming; in can_get_relative_tdco() local
118 s32 sample_point_in_tc = (CAN_SYNC_SEG + dbt->prop_seg + in can_get_relative_tdco()
119 dbt->phase_seg1) * dbt->brp; in can_get_relative_tdco()
Dbittiming.h122 const struct can_bittiming *dbt,
135 const struct can_bittiming *dbt, in can_calc_tdco() argument
/linux-6.1.9/drivers/net/can/ifi_canfd/
Difi_canfd.c651 const struct can_bittiming *dbt = &priv->can.data_bittiming; in ifi_canfd_set_bittiming() local
666 brp = dbt->brp - 2; in ifi_canfd_set_bittiming()
667 sjw = dbt->sjw - 1; in ifi_canfd_set_bittiming()
668 tseg1 = dbt->prop_seg + dbt->phase_seg1 - 1; in ifi_canfd_set_bittiming()
669 tseg2 = dbt->phase_seg2 - 2; in ifi_canfd_set_bittiming()
677 tdc = dbt->brp * (dbt->prop_seg + dbt->phase_seg1); in ifi_canfd_set_bittiming()
/linux-6.1.9/drivers/net/can/flexcan/
Dflexcan-core.c1186 struct can_bittiming *dbt = &priv->can.data_bittiming; in flexcan_set_bittiming_cbt() local
1215 if (bt->brp != dbt->brp) in flexcan_set_bittiming_cbt()
1217 dbt->brp, bt->brp); in flexcan_set_bittiming_cbt()
1227 if (dbt->phase_seg1 > 0x8) { in flexcan_set_bittiming_cbt()
1228 dbt->prop_seg += (dbt->phase_seg1 - 0x8); in flexcan_set_bittiming_cbt()
1229 dbt->phase_seg1 = 0x8; in flexcan_set_bittiming_cbt()
1239 reg_fdcbt |= FIELD_PREP(FLEXCAN_FDCBT_FPRESDIV_MASK, dbt->brp - 1) | in flexcan_set_bittiming_cbt()
1240 FIELD_PREP(FLEXCAN_FDCBT_FRJW_MASK, dbt->sjw - 1) | in flexcan_set_bittiming_cbt()
1241 FIELD_PREP(FLEXCAN_FDCBT_FPROPSEG_MASK, dbt->prop_seg) | in flexcan_set_bittiming_cbt()
1242 FIELD_PREP(FLEXCAN_FDCBT_FPSEG1_MASK, dbt->phase_seg1 - 1) | in flexcan_set_bittiming_cbt()
[all …]
/linux-6.1.9/drivers/net/can/usb/kvaser_usb/
Dkvaser_usb_core.c583 struct can_bittiming *dbt = &priv->can.data_bittiming; in kvaser_usb_set_data_bittiming() local
586 int tseg1 = dbt->prop_seg + dbt->phase_seg1; in kvaser_usb_set_data_bittiming()
587 int tseg2 = dbt->phase_seg2; in kvaser_usb_set_data_bittiming()
588 int sjw = dbt->sjw; in kvaser_usb_set_data_bittiming()
595 busparams.bitrate = cpu_to_le32(dbt->bitrate); in kvaser_usb_set_data_bittiming()
/linux-6.1.9/drivers/dma/
Dsa11x0-dma.c113 u32 dbt[2]; member
1022 p->dbt[0] = readl_relaxed(p->base + DMA_DBTB); in sa11x0_dma_suspend()
1024 p->dbt[1] = readl_relaxed(p->base + DMA_DBTA); in sa11x0_dma_suspend()
1029 p->dbt[0] = readl_relaxed(p->base + DMA_DBTA); in sa11x0_dma_suspend()
1031 p->dbt[1] = readl_relaxed(p->base + DMA_DBTB); in sa11x0_dma_suspend()
1065 writel_relaxed(p->dbt[0], p->base + DMA_DBTA); in sa11x0_dma_resume()
1067 writel_relaxed(p->dbt[1], p->base + DMA_DBTB); in sa11x0_dma_resume()
/linux-6.1.9/drivers/net/can/spi/mcp251xfd/
Dmcp251xfd-core.c506 const struct can_bittiming *dbt = &priv->can.data_bittiming; in mcp251xfd_set_bittiming() local
560 val = FIELD_PREP(MCP251XFD_REG_DBTCFG_BRP_MASK, dbt->brp - 1) | in mcp251xfd_set_bittiming()
562 dbt->prop_seg + dbt->phase_seg1 - 1) | in mcp251xfd_set_bittiming()
564 dbt->phase_seg2 - 1) | in mcp251xfd_set_bittiming()
565 FIELD_PREP(MCP251XFD_REG_DBTCFG_SJW_MASK, dbt->sjw - 1); in mcp251xfd_set_bittiming()
572 tdco = clamp_t(int, dbt->brp * (dbt->prop_seg + dbt->phase_seg1), in mcp251xfd_set_bittiming()
/linux-6.1.9/drivers/net/can/ctucanfd/
Dctucanfd_base.c278 struct can_bittiming *dbt = &priv->can.data_bittiming; in ctucan_set_data_bittiming() local
281 return ctucan_set_btr(ndev, dbt, false); in ctucan_set_data_bittiming()
293 struct can_bittiming *dbt = &priv->can.data_bittiming; in ctucan_set_secondary_sample_point() local
303 if (dbt->bitrate > 1000000) { in ctucan_set_secondary_sample_point()
305 ssp_offset = (priv->can.clock.freq / 1000) * dbt->sample_point / dbt->bitrate; in ctucan_set_secondary_sample_point()
/linux-6.1.9/drivers/net/can/m_can/
Dm_can.c1164 const struct can_bittiming *dbt = &cdev->can.data_bittiming; in m_can_set_bittiming() local
1180 brp = dbt->brp - 1; in m_can_set_bittiming()
1181 sjw = dbt->sjw - 1; in m_can_set_bittiming()
1182 tseg1 = dbt->prop_seg + dbt->phase_seg1 - 1; in m_can_set_bittiming()
1183 tseg2 = dbt->phase_seg2 - 1; in m_can_set_bittiming()
1189 if (dbt->bitrate > 2500000) { in m_can_set_bittiming()
1195 ssp = dbt->sample_point; in m_can_set_bittiming()
1201 ssp / dbt->bitrate; in m_can_set_bittiming()
/linux-6.1.9/drivers/net/can/usb/
Dgs_usb.c663 struct gs_device_bittiming dbt = { in gs_usb_set_bittiming() local
675 dev->channel, 0, &dbt, sizeof(dbt), 1000, in gs_usb_set_bittiming()
683 struct gs_device_bittiming dbt = { in gs_usb_set_data_bittiming() local
699 dev->channel, 0, &dbt, sizeof(dbt), 1000, in gs_usb_set_data_bittiming()
/linux-6.1.9/drivers/net/can/
Dxilinx_can.c419 struct can_bittiming *dbt = &priv->can.data_bittiming; in xcan_set_bittiming() local
452 btr0 = dbt->brp - 1; in xcan_set_bittiming()
463 btr1 = dbt->prop_seg + dbt->phase_seg1 - 1; in xcan_set_bittiming()
466 btr1 |= (dbt->phase_seg2 - 1) << priv->devtype.btr_ts2_shift; in xcan_set_bittiming()
469 btr1 |= (dbt->sjw - 1) << priv->devtype.btr_sjw_shift; in xcan_set_bittiming()
/linux-6.1.9/drivers/net/can/rcar/
Drcar_canfd.c1300 const struct can_bittiming *dbt = &priv->can.data_bittiming; in rcar_canfd_set_bittiming() local
1321 brp = dbt->brp - 1; in rcar_canfd_set_bittiming()
1322 sjw = dbt->sjw - 1; in rcar_canfd_set_bittiming()
1323 tseg1 = dbt->prop_seg + dbt->phase_seg1 - 1; in rcar_canfd_set_bittiming()
1324 tseg2 = dbt->phase_seg2 - 1; in rcar_canfd_set_bittiming()