1. 09 9月, 2005 1 次提交
    • K
      [PATCH] USB: real nodes instead of usbfs · fbf82fd2
      Kay Sievers 提交于
      This patch introduces a /sys/class/usb_device/ class
      where every connected usb-device will show up:
      
        tree /sys/class/usb_device/
        /sys/class/usb_device/
        |-- usb1.1
        |   |-- dev
        |   `-- device -> ../../../devices/pci0000:00/0000:00:1d.0/usb1
        |-- usb2.1
        |   |-- dev
        |   `-- device -> ../../../devices/pci0000:00/0000:00:1d.1/usb2
        ...
      
      The presence of the "dev" file lets udev create real device nodes.
        kay@pim:~/src/linux-2.6> tree /dev/bus/usb/
        /dev/bus/usb/
        |-- 1
        |   `-- 1
        |-- 2
        |   `-- 1
        ...
      
      udev rule:
        SUBSYSTEM="usb_device", PROGRAM="/sbin/usb_device %k", NAME="%c"
        (echo $1 | /bin/sed 's/usb\([0-9]*\)\.\([0-9]*\)/bus\/usb\/\1\/\2/')
      
      This makes libusb pick up the real nodes instead of the mounted usbfs:
        export USB_DEVFS_PATH=/dev/bus/usb
      
      Background:
        All this makes it possible to manage usb devices with udev instead of
        the devfs solution. We are currently working on a pam_console/resmgr
        replacement driven by udev and a pam-helper. It applies ACL's to device
        nodes, which is required for modern desktop functionalty like
        "Fast User Switching" or multiple local login support.
      
      New patch with its own major. I've succesfully disabled usbfs and use real
      nodes only on my box. With: "export USB_DEVFS_PATH=/dev/bus/usb" libusb picks
      up the udev managed nodes instead of reading usbfs files.
      
      This makes udev to provide symlinks for libusb to pick up:
        SUBSYSTEM="usb_device", PROGRAM="/sbin/usbdevice %k", SYMLINK="%c"
      
      /sbin/usbdevice:
        #!/bin/sh
        echo $1 | /bin/sed 's/usbdev\([0-9]*\)\.\([0-9]*\)/bus\/usb\/\1\/\2/'
      Signed-off-by: NKay Sievers <kay.sievers@suse.de>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
      fbf82fd2
  2. 05 9月, 2005 1 次提交
  3. 13 7月, 2005 1 次提交
  4. 28 6月, 2005 3 次提交
    • A
      [PATCH] USB: usbcore: inverted test for resuming interfaces · 0ed0c0c4
      Alan Stern 提交于
      This one-liner fixes a test for interfaces that are already resumed.
      
      It would be nice if this could get into 2.6.12, but it's not critical
      since it only affects people doing selective (runtime) suspend/resume.
      Signed-off-by: NAlan Stern <stern@rowland.harvard.edu>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
      0ed0c0c4
    • A
      [PATCH] usbcore: Remove hub_set_power_budget · 7d35b929
      Alan Stern 提交于
      This patch removes the hub_set_power_budget routine, which was used by a
      couple of HCDs to indicate that the root hub was running on battery power.
      In its place is a new field added to struct usb_hcd, which HCDs can set
      before the root hub is registered.  Special-case code in the hub driver
      knows to look at this field when configuring a root hub.
      Signed-off-by: NAlan Stern <stern@rowland.harvard.edu>
      Acked-by: NDavid Brownell <dbrownell@users.sourceforge.net>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
      7d35b929
    • A
      [PATCH] usbcore support for root-hub IRQ instead of polling · d5926ae7
      Alan Stern 提交于
      This is a revised version of an earlier patch to add support to usbcore
      for driving root hubs by interrupts rather than polling.
      
      There's a temporary flag added to struct usb_hcd, marking devices whose
      drivers are aware of the new mechanism.  By default that flag doesn't get
      set so drivers will continue to see the same polling behavior as before.
      This way we can convert the HCDs one by one to use interrupt-based event
      reporting, and the temporary flag can be removed when they're all done.
      
      Also included is a small change to the hcd_disable_endpoint routine.
      Although endpoints normally shouldn't be disabled while a controller is
      suspended, it's legal to do so when the controller's driver is being
      rmmod'ed.
      
      Lastly the patch adds a new callback, .hub_irq_enable, for use by HCDs
      where the root hub's port-change interrupts are level-triggered rather
      than edge-triggered.  The callback is invoked each time khubd has finished
      processing a root hub, to let the HCD know that the interrupt can safely
      be re-enabled.
      Signed-off-by: NAlan Stern <stern@rowland.harvard.edu>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
      d5926ae7
  5. 26 6月, 2005 1 次提交
    • C
      [PATCH] Cleanup patch for process freezing · 3e1d1d28
      Christoph Lameter 提交于
      1. Establish a simple API for process freezing defined in linux/include/sched.h:
      
         frozen(process)		Check for frozen process
         freezing(process)		Check if a process is being frozen
         freeze(process)		Tell a process to freeze (go to refrigerator)
         thaw_process(process)	Restart process
         frozen_process(process)	Process is frozen now
      
      2. Remove all references to PF_FREEZE and PF_FROZEN from all
         kernel sources except sched.h
      
      3. Fix numerous locations where try_to_freeze is manually done by a driver
      
      4. Remove the argument that is no longer necessary from two function calls.
      
      5. Some whitespace cleanup
      
      6. Clear potential race in refrigerator (provides an open window of PF_FREEZE
         cleared before setting PF_FROZEN, recalc_sigpending does not check
         PF_FROZEN).
      
      This patch does not address the problem of freeze_processes() violating the rule
      that a task may only modify its own flags by setting PF_FREEZE. This is not clean
      in an SMP environment. freeze(process) is therefore not SMP safe!
      Signed-off-by: NChristoph Lameter <christoph@lameter.com>
      Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
      3e1d1d28
  6. 19 4月, 2005 3 次提交
  7. 17 4月, 2005 1 次提交
    • L
      Linux-2.6.12-rc2 · 1da177e4
      Linus Torvalds 提交于
      Initial git repository build. I'm not bothering with the full history,
      even though we have it. We can create a separate "historical" git
      archive of that later if we want to, and in the meantime it's about
      3.2GB when imported into git - space that would just make the early
      git days unnecessarily complicated, when we don't have a lot of good
      infrastructure for it.
      
      Let it rip!
      1da177e4