1. 23 Jun, 2005 5 commits
    • Dave Airlie's avatar
      drm: 32/64-bit DRM ioctl compatibility patch · 9a186645
      Dave Airlie authored
      The patch is against a 2.6.11 kernel tree.  I am running this with a
      32-bit X server (compiled up from X.org CVS as of a couple of weeks
      ago) and 32-bit DRI libraries and clients.  All the userland stuff is
      identical to what I am using under a 32-bit kernel on my G4 powerbook
      (which is a 32-bit machine of course).  I haven't tried compiling up a
      64-bit X server or clients yet.
      In the compatibility routines I have assumed that the kernel can
      safely access user addresses after set_fs(KERNEL_DS).  That is, where
      an ioctl argument structure contains pointers to other structures, and
      those other structures are already compatible between the 32-bit and
      64-bit ABIs (i.e. they only contain things like chars, shorts or
      ints), I just check the address with access_ok() and then pass it
      through to the 64-bit ioctl code.  I believe this approach may not
      work on sparc64, but it does work on ppc64 and x86_64 at least.
      One tricky area which may need to be revisited is the question of how
      to handle the handles which we pass back to userspace to identify
      mappings.  These handles are generated in the ADDMAP ioctl and then
      passed in as the offset value to mmap.  However, offset values for
      mmap seem to be generated in other ways as well, particularly for AGP
      The approach I have ended up with is to generate a fake 32-bit handle
      only for _DRM_SHM mappings.  The handles for other mappings (AGP, REG,
      FB) are physical addresses which are already limited to 32 bits, and
      generating fake handles for them created all sorts of problems in the
      mmap/nopage code.
      This patch has been updated to use the new compatibility ioctls.
      From: Paul Mackerras <paulus@samba.org>
      Signed-off-by: default avatarDave Airlie <airlied@linux.ie>
    • Linus Torvalds's avatar
    • Linus Torvalds's avatar
    • Greg Kroah-Hartman's avatar
      [PATCH] driver core: Fix up the device_attach() error handling in bus_add_device() · d377e85b
      Greg Kroah-Hartman authored
      Don't error out if something "bad" happens when trying to bind a driver to a
      device.  We want the sysfs attributes to be present for later when we try to
      tear down the device.
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
    • Stelian Pop's avatar
      [PATCH] USB: fix hid core to return proper error code from probe · 479f6ea8
      Stelian Pop authored
      Drivers need to return -ENODEV when they can't bind to a device.
      Anything else stops the "bind a device to a driver" search.
      From: Stelian Pop <stelian@popies.net>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
  2. 22 Jun, 2005 35 commits