All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Diego Elio Pettenò" <flameeyes@flameeyes.com>
To: "Greg KH" <gregkh@linuxfoundation.org>
Cc: linux-usb@vger.kernel.org, "Pete Zaitcev" <zaitcev@redhat.com>,
	"Paolo Abeni" <pabeni@redhat.com>,
	"Kris Katterjohn" <katterjohn@gmail.com>
Subject: Re: [PATCH] usbmon: expose the usbmon structures and constants as an UAPI header.
Date: Mon, 06 Jul 2020 13:21:22 +0100	[thread overview]
Message-ID: <c93d4a89-ed87-4fc0-94f2-e6c8a6ef04c3@www.fastmail.com> (raw)
In-Reply-To: <20200706103026.GA10624@kroah.com>

On Mon, Jul 6, 2020, at 11:30, Greg KH wrote:
> You can't change someone's copyright lines, sorry.

Then I hope Paolo can send a follow-up patch updating his email address — email.it doesn't seem to exist anymore/doesn't seem to have his address anymore.

> Put the copyright notices back in here.

Done.

> And you see the kbuild error for this, please fix that up.

This should be fixed now by dropping the conditional, which AIUI is the right thing to do in this case? I couldn't find any documentation referencing what to do with CONFIG_COMPAT for headers, but I assume that anything optionally available should be exposed in UAPI and worst case fail at runtime.

> As you are making this a "real" uapi .h file, you have to use the "real"
> data types as well.  That means using __u32 and not u32.  Same for all
> others.

Done, and in the documentation.

> Does this cross the user/kernel boundry?  Ick, no wonder we need compat
> fixups :(

I fear so. The usbmon interface is fairly long-living, and I don't think it matches most of the best practices of today.

I keep telling myself I should spend more time trying to figure out what I can improve overall, because I fear this is better served by having a good thought on the design, and be replaced. But that's a topic for another thread.

Although if someone is interested in whiteboarding an alternative design, I'd be happy to start such a thread or have an offline chat. My current castle-in-the-sky would involve integrating BPF so that capture filters can be applied — and I think that the modern way to stream data from the kernel to userspace would be netlink?

  reply	other threads:[~2020-07-06 12:23 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-07-05 15:02 [PATCH] usbmon: expose the usbmon structures and constants as an UAPI header Diego Elio Pettenò
2020-07-06  3:51 ` Pete Zaitcev
2020-07-06  8:32   ` Diego Elio Pettenò
2020-07-06 15:01     ` Pete Zaitcev
2020-07-06  5:46 ` kernel test robot
2020-07-06  5:46   ` kernel test robot
2020-07-06 10:30 ` Greg KH
2020-07-06 12:21   ` Diego Elio Pettenò [this message]
2020-07-06 12:15 ` [PATCH v2] " Diego Elio Pettenò
2020-07-06 12:49   ` Greg KH
2020-07-06 13:10     ` Diego Elio Pettenò
2020-07-06 16:15     ` Pete Zaitcev
2020-07-06 13:10 ` [PATCH v3 1/2] Remove documentation line that adds nothing and sounds condescending Diego Elio Pettenò
2020-07-06 13:10   ` [PATCH v3 2/2] usbmon: expose the usbmon structures and constants as an UAPI header Diego Elio Pettenò
2020-07-06 16:35     ` Greg KH
2020-07-06 16:34   ` [PATCH v3 1/2] Remove documentation line that adds nothing and sounds condescending Greg KH
2020-07-06 22:44 ` [PATCH v4 " Diego Elio Pettenò
2020-07-06 22:44   ` [PATCH v4 2/2] usbmon: expose the usbmon structures and constants as an UAPI header Diego Elio Pettenò
2020-07-09 16:04     ` Greg KH
2020-07-11 13:14     ` kernel test robot
2020-07-11 13:14       ` kernel test robot
2020-07-09 16:03   ` [PATCH v4 1/2] Remove documentation line that adds nothing and sounds condescending Greg KH

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=c93d4a89-ed87-4fc0-94f2-e6c8a6ef04c3@www.fastmail.com \
    --to=flameeyes@flameeyes.com \
    --cc=gregkh@linuxfoundation.org \
    --cc=katterjohn@gmail.com \
    --cc=linux-usb@vger.kernel.org \
    --cc=pabeni@redhat.com \
    --cc=zaitcev@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.