1. 10 7月, 2007 4 次提交
    • T
      libata: reimplement ACPI invocation · 6746544c
      Tejun Heo 提交于
      This patch reimplements ACPI invocation such that, instead of
      exporting ACPI details to the rest of libata, ACPI event handlers -
      ata_acpi_on_resume() and ata_acpi_on_devcfg() - are used.  These two
      functions are responsible for determining whether specific ACPI method
      is used and when.
      
      On resume, _GTF is scheduled by setting ATA_DFLAG_ACPI_PENDING device
      flag.  This is done this way to avoid performing the action on wrong
      device device (device swapping while suspended).
      
      On every ata_dev_configure(), ata_acpi_on_devcfg() is called, which
      performs _SDD and _GTF.  _GTF is performed only after resuming and, if
      SATA, hardreset as the ACPI spec specifies.  As _GTF may contain
      arbitrary commands, IDENTIFY page is re-read after _GTF taskfiles are
      executed.
      
      If one of ACPI methods fails, ata_acpi_on_devcfg() retries on the
      first failure.  If it fails again on the second try, ACPI is disabled
      on the device.  Note that successful configuration clears ACPI failed
      status.
      
      With all feature checks moved to the above two functions,
      do_drive_set_taskfiles() is trivial and thus collapsed into
      ata_acpi_exec_tfs(), which is now static and converted to return the
      number of executed taskfiles to be used by ata_acpi_on_resume().  As
      failures are handled properly, ata_acpi_push_id() now returns -errno
      on errors instead of unconditional zero.
      Signed-off-by: NTejun Heo <htejun@gmail.com>
      Signed-off-by: NJeff Garzik <jeff@garzik.org>
      6746544c
    • T
      libata-acpi: miscellaneous cleanups · 69b16a5f
      Tejun Heo 提交于
      * Add missing LOCKING: and RETURNS: to function comment.
      
      * Don't conditionalize warning messages with ata_msg_probe().  Print
        directly with KERN_WARNING.
      
      * Drop duplicate debug messages.
      Signed-off-by: NTejun Heo <htejun@gmail.com>
      Signed-off-by: NJeff Garzik <jeff@garzik.org>
      69b16a5f
    • T
      libata-acpi: clean up ata_acpi_exec_tfs() · 4700c4bc
      Tejun Heo 提交于
      This patch cleans up ata_acpi_exec_tfs() and its friends.
      
      * Rename taskfile_array to ata_acpi_gtf and make it __packed as it's
        used as argument to ACPI method, and use pointer to ata_acpi_gtf and
        number of taskfiles to represent _GTF taskfiles instead of a pointer
        casted into unsigned long and byte count.  This makes argument
        re-checking in do_drive_set_taskfiles() unnecessary.
      
      * Pointer in void * not in unsigned long.
      
      * Clean up do_drive_get_GTF() error handling and make
        do_drive_get_GTF() return number of taskfiles on success, 0 if _GTF
        doesn't exist or doesn't contain valid ata.  -errno on other errors.
      
      * Remove superflous check for acpi->buffer.pointer.
      
      * Update taskfile_load_raw() such that printed messages look similar
        to the messages printed by ata_eh_report().
      
      * s/do_drive_get_GTF/ata_dev_get_GTF/
        s/do_drive_set_taskfiles/ata_dev_set_taskfiles/
      Signed-off-by: NTejun Heo <htejun@gmail.com>
      Signed-off-by: NJeff Garzik <jeff@garzik.org>
      4700c4bc
    • T
      libata-acpi: implement ata_acpi_associate() · fafbae87
      Tejun Heo 提交于
      * Add acpi_handle to ata_host and ata_port.  Rename
        ata_device->obj_handle to ->acpi_handle and move it above such that
        it doesn't get cleared on reconfiguration.
      
      * Replace ACPI node association which ata_acpi_associate() which is
        called once during host initialization.  Unlike the previous
        implementation, ata_acpi_associate() uses ATA_FLAG_ACPI_SATA to
        choose between IDE or SATA ACPI hierarchy and uses simple child look
        up instead of recursive walk to match the nodes.  This is way safer
        and simpler.  Please read the following message for more info.
      
        http://article.gmane.org/gmane.linux.ide/17554Signed-off-by: NTejun Heo <htejun@gmail.com>
      Signed-off-by: NJeff Garzik <jeff@garzik.org>
      fafbae87
  2. 09 7月, 2007 4 次提交
  3. 08 7月, 2007 6 次提交
    • B
      qd65xx: fix PIO mode selection · 4660897e
      Bartlomiej Zolnierkiewicz 提交于
      PIO4 is a maximum PIO mode supported by a driver.  Using "255" as a max_mode
      argument to ide_get_best_pio_mode() could result in wrong timings being used
      by a driver (for "pio" equal to 5) or OOPS (for "pio" values > 5 && < 255).
      Signed-off-by: NBartlomiej Zolnierkiewicz <bzolnier@gmail.com>
      Acked-by: NSergei Shtylyov <sshtylyov@ru.mvista.com>
      Reviewed-by: NAlan Cox <alan@lxorguk.ukuu.org.uk>
      4660897e
    • U
      sis5513: adding PCI-ID · 4c6c914e
      Uwe Koziolek 提交于
      The SiS966 has one additional PCI-ID 1180.
      
      If the chipset is using this PCI-ID, the primary channel is connected to the
      first PATA-port. The secondary channel is connected to SATA-ports in IDE
      emulation mode.  The legacy IO-ports are used.
      
      The including of the PCI-ID into pata_sis is not sufficient, because the legacy
      driver in drivers/ide is initialized before pata_sis.
      Signed-off-by: NUwe Koziolek <uwe.koziolek@gmx.net>
      Signed-off-by: NBartlomiej Zolnierkiewicz <bzolnier@gmail.com>
      4c6c914e
    • A
      DLM must depend on SYSFS · 95511ad4
      Adrian Bunk 提交于
      The dependency of DLM on SYSFS got lost in
      commit 6ed7257b resulting in the
      following compile error with CONFIG_DLM=y, CONFIG_SYSFS=n:
      
      <--  snip  -->
      
      ...
        LD      .tmp_vmlinux1
      fs/built-in.o: In function `dlm_lockspace_init':
      /home/bunk/linux/kernel-2.6/linux-2.6.22-rc6-mm1/fs/dlm/lockspace.c:231: undefined reference to `kernel_subsys'
      fs/built-in.o: In function `configfs_init':
      /home/bunk/linux/kernel-2.6/linux-2.6.22-rc6-mm1/fs/configfs/mount.c:143: undefined reference to `kernel_subsys'
      make[1]: *** [.tmp_vmlinux1] Error 1
      
      <--  snip  -->
      Signed-off-by: NAdrian Bunk <bunk@stusta.de>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      95511ad4
    • D
      Clean up E7520/7320/7525 quirk printk. · 38377be8
      Dave Jones 提交于
      The printk level in this printk is bogus, as the previous printk
      didn't have a terminating \n resulting in ..
      
      Intel E7520/7320/7525 detected.<6>Disabling irq balancing and affinity
      
      It also never printed a \n at all in the case where we didn't do
      the quirk.
      
      Change it to only make noise if it actually does something useful.
      Signed-off-by: NDave Jones <davej@redhat.com>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      38377be8
    • A
      include/linux/kallsyms.h must #include <linux/errno.h> · 40e48eed
      Adrian Bunk 提交于
      This patch fixes the following 2.6.22 regression with CONFIG_KALLSYMS=n:
      
      <--  snip  -->
      
      ...
        CC      arch/m32r/kernel/traps.o
      In file included from /home/bunk/linux/kernel-2.6/linux-2.6.22-rc6-mm1/arch/m32r/kernel/traps.c:14:
      /home/bunk/linux/kernel-2.6/linux-2.6.22-rc6-mm1/include/linux/kallsyms.h: In function 'lookup_symbol_name':
      /home/bunk/linux/kernel-2.6/linux-2.6.22-rc6-mm1/include/linux/kallsyms.h:66: error: 'ERANGE' undeclared (first use in this function)
      /home/bunk/linux/kernel-2.6/linux-2.6.22-rc6-mm1/include/linux/kallsyms.h:66: error: (Each undeclared identifier is reported only once
      /home/bunk/linux/kernel-2.6/linux-2.6.22-rc6-mm1/include/linux/kallsyms.h:66: error: for each function it appears in.)
      /home/bunk/linux/kernel-2.6/linux-2.6.22-rc6-mm1/include/linux/kallsyms.h: In function 'lookup_symbol_attrs':
      /home/bunk/linux/kernel-2.6/linux-2.6.22-rc6-mm1/include/linux/kallsyms.h:71: error: 'ERANGE' undeclared (first use in this function)
      make[2]: *** [arch/m32r/kernel/traps.o] Error 1
      
      <--  snip  -->
      Signed-off-by: NAdrian Bunk <bunk@stusta.de>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      40e48eed
    • D
      Fix use-after-free oops in Bluetooth HID. · 1c39858b
      David Woodhouse 提交于
      When cleaning up HIDP sessions, we currently close the ACL connection
      before deregistering the input device. Closing the ACL connection
      schedules a workqueue to remove the associated objects from sysfs, but
      the input device still refers to them -- and if the workqueue happens to
      run before the input device removal, the kernel will oops when trying to
      look up PHYSDEVPATH for the removed input device.
      
      Fix this by deregistering the input device before closing the
      connections.
      Signed-off-by: NDavid Woodhouse <dwmw2@infradead.org>
      Acked-by: NMarcel Holtmann <marcel@holtmann.org>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      1c39858b
  4. 07 7月, 2007 14 次提交
  5. 06 7月, 2007 12 次提交