Thomas Körper wrote:
> Hi,
>
>>>> Also, how can it happen that the FIFO is full? As I see it,
>>>> only esd331_start_xmit() is writing to the FIFO one message at the time.
>>> Ah, that's right! So this should never happen and we'll just drop then:
>>>
>>> can_put_echo_skb(skb, dev, 0);
>>> if (unlikely(esd331_write(&msg, priv->board))) {
>>> can_free_echo_skb(dev, 0);
>>> stats->tx_dropped++;
>>> return NETDEV_TX_OK;
>>> }
>> Yes. As this event is not expected to happen, an error message would
>> make sense here.
>
> Sorry, I think a kfree_skb() had to be there, too.
I don't think so, see:
http://lxr.linux.no/#linux+v2.6.32/drivers/net/can/dev.c#L330
> if (unlikely(esd331_write(&msg, priv->board))) {
> can_free_echo_skb(dev, 0);
> kfree_skb(skb);
> dev_err(dev->dev.parent, "Couldn't write frame to card's
> FIFO!\n");
For the SVN repository, s/dev->dev.parent/ND2D(dev)/ please.
> stats->tx_dropped++;
> return NETDEV_TX_OK;
> }
>
> If that's OK then, this is the final patch:
For some reason, I cannot apply your patch here:
$ cd trunk
patch -p0 ../esd_pci331.patch
patching file kernel/2.6/drivers/net/can/esd_pci331.c
Hunk #1 FAILED at 318.
Hunk #2 FAILED at 583.
Hunk #3 FAILED at 693.
3 out of 3 hunks FAILED
Hm, does it work for you?
Just for curiosity, how many packets per second can the driver send at
1MB/s.
Wolfgang.
_______________________________________________
Socketcan-core mailing list
[email protected]
https://lists.berlios.de/mailman/listinfo/socketcan-core