netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* HW communication debugging interface - ideas?
@ 2015-09-30 13:51 Jiri Pirko
  2015-10-05  8:54 ` Jiri Pirko
                   ` (4 more replies)
  0 siblings, 5 replies; 23+ messages in thread
From: Jiri Pirko @ 2015-09-30 13:51 UTC (permalink / raw)
  To: davem; +Cc: netdev, eladr, idosch

Hi Dave/all.

There is quite common for drivers to speak with HW using "packet-like"
messages. In our case, we put message into skb and push that out as
an ordinary packet. HW then sends us reply in a packet, similar to other
rx-ed packets.

It makes sense to monitor this communication. Not only for debugging
during development, but mainly for collecting data for error reports
from users.

Very cool usecase is to teach wireshark to parse this communication so
one can actually see online what is going on.

Now the question is, what is the correct way to expose this
communication to userspace. Naturally, this interface should be read-only.
Also, the interface should be generic enough so it can be used for all
drivers, including non-net drivers.

1) Special monitoring netdev.
Might make sense to use a separate netdev. Is is easy to tap the
communication. Driver would just create new netdev and push incoming and
outgoing messages there. Downside is that there would be needed to wrap the
messages with some metadata header, which seems quite odd.

2) generic Netlink (genl) interface. Easy to put metadata in, including the
device identificator (pci address). User then can use nlmon in order to
be able to use wireshark to see the netlink messages.

Looks like 2) might be viable, well-defined, generic interface to carry
this info. What do you think? Does this make sense?

Thanks!

Jiri

^ permalink raw reply	[flat|nested] 23+ messages in thread

end of thread, other threads:[~2015-11-02  6:13 UTC | newest]

Thread overview: 23+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-09-30 13:51 HW communication debugging interface - ideas? Jiri Pirko
2015-10-05  8:54 ` Jiri Pirko
2015-10-05  9:38   ` David Miller
2015-10-05  9:45     ` Jiri Pirko
2015-10-05  9:54 ` Rosen, Rami
2015-10-05  9:56   ` Jiri Pirko
2015-10-05 14:49     ` Andrew Lunn
2015-10-05 14:55       ` Jiri Pirko
2015-10-05 14:58         ` Andrew Lunn
2015-10-05 15:18           ` Jiri Pirko
2015-10-05 15:29             ` John Fastabend
2015-10-05 15:35               ` Jiri Pirko
2015-10-05 15:47                 ` John Fastabend
2015-10-06  8:14                   ` Jiri Pirko
2015-10-06 14:54                     ` John Fastabend
2015-10-06 15:02                       ` Jiri Pirko
2015-10-06 15:02                       ` Andrew Lunn
2015-11-01 17:58                         ` Guy Harris
2015-10-05 12:28 ` Thomas Graf
2015-10-05 18:32 ` Marcelo Ricardo Leitner
2015-10-05 20:40   ` Jiri Pirko
2015-11-01 16:51 ` David Miller
2015-11-02  6:13   ` Jiri Pirko

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).