From: Pete Zaitcev <zaitcev@redhat.com>
To: David Brownell <david-b@pacbell.net>
Cc: linux-kernel@vger.kernel.org, greg@kroah.com,
linux-usb-devel@lists.sourceforge.net, zaitcev@redhat.com
Subject: Re: usbmon, usb core, ARM
Date: Thu, 20 Jan 2005 11:35:45 -0800 [thread overview]
Message-ID: <20050120113545.58ce18a3@localhost.localdomain> (raw)
In-Reply-To: <200501190908.35210.david-b@pacbell.net>
On Wed, 19 Jan 2005 09:08:34 -0800, David Brownell <david-b@pacbell.net> wrote:
> On Wednesday 19 January 2005 7:42 am, Pete Zaitcev wrote:
> > Relying on pipe makes
> > tests dependant on URB only. No references to bus or HCD, therefore no
> > extra refcounts or worries about oopses. Also, HC drivers zero out the
> > urb->dev in giveback sequence which is a royal pain when trying to identify
> > a root hub.
>
> That was a 2.4-ism, it should now be gone. So an inlined function to
> test whether urb->dev is the root hub should suffice; I know there's
> code that does that already.
I do not like to refer to a dev because I do not quite understand where
the necessary usb_dev_get/_put are now. But if you guarantee that the
urb->dev is refcounted properly while urb is processed by usb_hcd_giveback_urb,
I do not mind an extra indirection.
What would be the right test in usb_hcd_giveback_urb, then?
It looks to me that you want me to use this:
urb_is_for_root_hub(urb) {
return urb->dev == urb->dev->bus->hcpriv->self.root_hub;
}
This is just ... ewwwww. Can we use pipe for now or do you have
a better idea?
-- Pete
next prev parent reply other threads:[~2005-01-20 19:48 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-01-19 5:20 usbmon, usb core, ARM Pete Zaitcev
2005-01-19 6:14 ` David Brownell
2005-01-19 15:42 ` Pete Zaitcev
2005-01-19 15:54 ` Oliver Neukum
2005-01-19 17:08 ` David Brownell
2005-01-20 19:35 ` Pete Zaitcev [this message]
2005-01-21 6:28 ` David Brownell
2005-01-22 8:12 ` Pete Zaitcev
2005-01-23 23:34 ` [linux-usb-devel] " David Brownell
2005-01-24 1:17 ` Pete Zaitcev
2005-01-24 2:08 ` David Brownell
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=20050120113545.58ce18a3@localhost.localdomain \
--to=zaitcev@redhat.com \
--cc=david-b@pacbell.net \
--cc=greg@kroah.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-usb-devel@lists.sourceforge.net \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox