Skip to content

Commit

Permalink
Merge pull request torvalds#161 in PROCESSOR-SDK/processor-sdk-linux …
Browse files Browse the repository at this point in the history
…from PLSDK-2796 to processor-sdk-linux-4.19.y

* commit '14e3f3061675348e4a492e7089c07ee5e7926884':
  net: ethernet: prueth: fix hsr/prp timestamping mem offset
  • Loading branch information
Aaron Kramer committed May 31, 2019
2 parents 32e73c6 + 14e3f30 commit cc96065
Showing 1 changed file with 2 additions and 8 deletions.
10 changes: 2 additions & 8 deletions drivers/net/ethernet/ti/prueth.c
Original file line number Diff line number Diff line change
Expand Up @@ -2246,7 +2246,6 @@ static irqreturn_t red_emac_rx_thread(int irq, void *dev_id)
const struct prueth_queue_info *rxqueue_p;

void *ocmc_ram = (__force void *)emac->prueth->mem[PRUETH_MEM_OCMC].va;
int read_block, read_block_o;
u32 pkt_ts, pkt_ts_o;
u32 iep_wrap, iep_cmp_cfg;

Expand Down Expand Up @@ -2326,15 +2325,10 @@ static irqreturn_t red_emac_rx_thread(int irq, void *dev_id)
parse_packet_info(prueth, rd_buf_desc, &pkt_info);
parse_packet_info(prueth, rd_buf_desc_o, &pkt_info_o);

read_block = (bd_rd_ptr - rxqueue->buffer_desc_offset) /
BD_SIZE;
read_block_o = (bd_rd_ptr_o - rxqueue_o->buffer_desc_offset) /
BD_SIZE;

pkt_ts = readl(ocmc_ram + TIMESTAMP_ARRAY_OFFSET +
(read_block * BD_SIZE));
bd_rd_ptr - SRAM_START_OFFSET);
pkt_ts_o = readl(ocmc_ram + TIMESTAMP_ARRAY_OFFSET +
(read_block_o * BD_SIZE));
bd_rd_ptr_o - SRAM_START_OFFSET);

if (!port0_q_empty && !port1_q_empty) {
/* Packets in both port queues */
Expand Down

0 comments on commit cc96065

Please sign in to comment.