Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1451501

Re: [RFC] usb: host: u132-hcd: Remove deprecated create_singlethread_workqueue

From Alan Stern <stern@rowland.harvard.edu>
Newsgroups linux.kernel
Subject Re: [RFC] usb: host: u132-hcd: Remove deprecated create_singlethread_workqueue
Date 2016-07-27 22:50 +0200
Message-ID <rZDW9-4k0-7@gated-at.bofh.it> (permalink)
References <rZCGJ-3Dk-3@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On Wed, 27 Jul 2016, Tejun Heo wrote:

> Hello, Alan.
> 
> On Wed, Jul 27, 2016 at 02:54:51PM -0400, Alan Stern wrote:
> > > Hmm... I didn't know the whole USB stack could operate without
> > > allocating memory.  Does usb stack have mempools and stuff all the way
> > > through?
> > 
> > No -- the USB stack does need to allocate memory in order to operate.  
> > But it is careful to use GFP_NOIO or GFP_ATOMIC for allocations that
> > might be on the block-device path.
> 
> Hmm... That doesn't really make them dependable during memory reclaim.

True.  But it does mean that they can't cause a deadlock by waiting
indefinitely for some other memory to be paged out to the very device
they are on the access pathway for.

> What happens when those allocations fail?

The same thing that happens when any allocation fails -- the original
I/O request fails with -ENOMEM or the equivalent.  In the case of 
usb-storage, this is likely to trigger error recovery, which will need 
to allocate memory of its own...  A bad situation to get into.

Alan Stern

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

[RFC] usb: host: u132-hcd: Remove deprecated  create_singlethread_workqueue Bhaktipriya Shridhar <bhaktipriya96@gmail.com> - 2016-07-27 11:30 +0200
  Re: [RFC] usb: host: u132-hcd: Remove deprecated  create_singlethread_workqueue Oliver Neukum <oneukum@suse.com> - 2016-07-27 11:40 +0200
    Re: [RFC] usb: host: u132-hcd: Remove deprecated  create_singlethread_workqueue Tejun Heo <tj@kernel.org> - 2016-07-27 20:10 +0200
      Re: [RFC] usb: host: u132-hcd: Remove deprecated create_singlethread_workqueue Alan Stern <stern@rowland.harvard.edu> - 2016-07-27 21:00 +0200
        Re: [RFC] usb: host: u132-hcd: Remove deprecated  create_singlethread_workqueue Tejun Heo <tj@kernel.org> - 2016-07-27 21:30 +0200
          Re: [RFC] usb: host: u132-hcd: Remove deprecated create_singlethread_workqueue Alan Stern <stern@rowland.harvard.edu> - 2016-07-27 22:50 +0200
            Re: [RFC] usb: host: u132-hcd: Remove deprecated  create_singlethread_workqueue Tejun Heo <tj@kernel.org> - 2016-07-29 15:20 +0200
              Re: [RFC] usb: host: u132-hcd: Remove deprecated  create_singlethread_workqueue Michal Hocko <mhocko@kernel.org> - 2016-08-01 16:00 +0200
                Re: [RFC] usb: host: u132-hcd: Remove deprecated  create_singlethread_workqueue Tejun Heo <tj@kernel.org> - 2016-08-01 16:30 +0200
                Re: [RFC] usb: host: u132-hcd: Remove deprecated create_singlethread_workqueue Alan Stern <stern@rowland.harvard.edu> - 2016-08-01 21:10 +0200
                Re: [RFC] usb: host: u132-hcd: Remove deprecated  create_singlethread_workqueue Michal Hocko <mhocko@kernel.org> - 2016-08-01 21:40 +0200
                Re: [RFC] usb: host: u132-hcd: Remove deprecated  create_singlethread_workqueue Oliver Neukum <oneukum@suse.com> - 2016-08-02 10:20 +0200
                Re: [RFC] usb: host: u132-hcd: Remove deprecated  create_singlethread_workqueue Michal Hocko <mhocko@kernel.org> - 2016-08-02 10:40 +0200
                Re: [RFC] usb: host: u132-hcd: Remove deprecated  create_singlethread_workqueue Oliver Neukum <oneukum@suse.com> - 2016-08-02 12:10 +0200
                Re: [RFC] usb: host: u132-hcd: Remove deprecated  create_singlethread_workqueue Michal Hocko <mhocko@kernel.org> - 2016-08-02 14:00 +0200
                Re: [RFC] usb: host: u132-hcd: Remove deprecated  create_singlethread_workqueue Oliver Neukum <oneukum@suse.com> - 2016-08-02 15:40 +0200
                Re: [RFC] usb: host: u132-hcd: Remove deprecated  create_singlethread_workqueue Tejun Heo <tj@kernel.org> - 2016-08-02 21:20 +0200
                Re: [RFC] usb: host: u132-hcd: Remove deprecated  create_singlethread_workqueue Michal Hocko <mhocko@kernel.org> - 2016-08-02 23:40 +0200
                Re: [RFC] usb: host: u132-hcd: Remove deprecated  create_singlethread_workqueue Michal Hocko <mhocko@kernel.org> - 2016-08-02 16:00 +0200
                Re: [RFC] usb: host: u132-hcd: Remove deprecated  create_singlethread_workqueue Oliver Neukum <oneukum@suse.com> - 2016-08-02 19:20 +0200

csiph-web