Lines Matching refs:ps
45 struct hellcreek_port_hwtstamp *ps = in hellcreek_set_hwtstamp_config() local
53 clear_bit_unlock(HELLCREEK_HWTSTAMP_ENABLED, &ps->state); in hellcreek_set_hwtstamp_config()
111 set_bit(HELLCREEK_HWTSTAMP_ENABLED, &ps->state); in hellcreek_set_hwtstamp_config()
120 struct hellcreek_port_hwtstamp *ps; in hellcreek_port_hwtstamp_set() local
124 ps = &hellcreek->ports[port].port_hwtstamp; in hellcreek_port_hwtstamp_set()
134 memcpy(&ps->tstamp_config, &config, sizeof(config)); in hellcreek_port_hwtstamp_set()
144 struct hellcreek_port_hwtstamp *ps; in hellcreek_port_hwtstamp_get() local
147 ps = &hellcreek->ports[port].port_hwtstamp; in hellcreek_port_hwtstamp_get()
148 config = &ps->tstamp_config; in hellcreek_port_hwtstamp_get()
161 struct hellcreek_port_hwtstamp *ps = in hellcreek_should_tstamp() local
169 if (!test_bit(HELLCREEK_HWTSTAMP_ENABLED, &ps->state)) in hellcreek_should_tstamp()
218 struct hellcreek_port_hwtstamp *ps, int port) in hellcreek_txtstamp_work() argument
226 if (!ps->tx_skb) in hellcreek_txtstamp_work()
250 if (time_is_before_jiffies(ps->tx_tstamp_start + in hellcreek_txtstamp_work()
274 tmp_skb = ps->tx_skb; in hellcreek_txtstamp_work()
275 ps->tx_skb = NULL; in hellcreek_txtstamp_work()
281 clear_bit_unlock(HELLCREEK_HWTSTAMP_TX_IN_PROGRESS, &ps->state); in hellcreek_txtstamp_work()
289 dev_kfree_skb_any(ps->tx_skb); in hellcreek_txtstamp_work()
290 ps->tx_skb = NULL; in hellcreek_txtstamp_work()
291 clear_bit_unlock(HELLCREEK_HWTSTAMP_TX_IN_PROGRESS, &ps->state); in hellcreek_txtstamp_work()
297 struct hellcreek_port_hwtstamp *ps, in hellcreek_get_rxts() argument
343 struct hellcreek_port_hwtstamp *ps, in hellcreek_rxtstamp_work() argument
348 skb = skb_dequeue(&ps->rx_queue); in hellcreek_rxtstamp_work()
350 hellcreek_get_rxts(hellcreek, ps, skb, &ps->rx_queue, port); in hellcreek_rxtstamp_work()
360 struct hellcreek_port_hwtstamp *ps; in hellcreek_hwtstamp_work() local
365 ps = &hellcreek->ports[i].port_hwtstamp; in hellcreek_hwtstamp_work()
367 if (test_bit(HELLCREEK_HWTSTAMP_TX_IN_PROGRESS, &ps->state)) in hellcreek_hwtstamp_work()
368 restart |= hellcreek_txtstamp_work(hellcreek, ps, i); in hellcreek_hwtstamp_work()
370 hellcreek_rxtstamp_work(hellcreek, ps, i); in hellcreek_hwtstamp_work()
380 struct hellcreek_port_hwtstamp *ps; in hellcreek_port_txtstamp() local
385 ps = &hellcreek->ports[port].port_hwtstamp; in hellcreek_port_txtstamp()
404 &ps->state)) { in hellcreek_port_txtstamp()
409 ps->tx_skb = clone; in hellcreek_port_txtstamp()
414 ps->tx_tstamp_start = jiffies; in hellcreek_port_txtstamp()
423 struct hellcreek_port_hwtstamp *ps; in hellcreek_port_rxtstamp() local
426 ps = &hellcreek->ports[port].port_hwtstamp; in hellcreek_port_rxtstamp()
431 if (ps->tstamp_config.rx_filter != HWTSTAMP_FILTER_PTP_V2_EVENT) in hellcreek_port_rxtstamp()
444 skb_queue_tail(&ps->rx_queue, skb); in hellcreek_port_rxtstamp()
453 struct hellcreek_port_hwtstamp *ps = in hellcreek_hwtstamp_port_setup() local
456 skb_queue_head_init(&ps->rx_queue); in hellcreek_hwtstamp_port_setup()