1. 06 5月, 2010 1 次提交
    • M
      UBI: init even if MTD device cannot be attached, if built into kernel · af7ad7a0
      Marc Kleine-Budde 提交于
      UBI can be built into the kernel or be compiled as a kernel module.
      Further on the command line one can specify MTD devices to be attach to
      UBI while loading. In the current implementation the UBI driver refuses
      to load if one of the MTD devices cannot be attached.
      
      Consider:
      1) UBI compiled into the kernel and
      2) a MTD device specified on the command line and
      3) this MTD device contains bogus data (for whatever reason).
      
      During init UBI tries to attach the MTD device is this fails the whole
      UBI subsystem isn't initialized. Later the userspace cannot attach any
      MTD to UBI because UBI isn't loaded.
      
      This patch keeps the current behaviour: if UBI is compiled as a module
      and a MTD device cannot be attached the UBI module cannot be loaded,
      but changes it for the UBI-is-built-into-the-kernel usecase.
      
      If UBI is builtin, a not attachable MTD device doen't stop UBI from
      initializing. This slightly modifies the behaviour if multiple MTD
      devices are specified on the command line. Now every MTD device is
      probed and, if possible, attached, i.e. a faulty MTD device doesn't
      stop the others from being attached.
      
      Artem: tweaked the patch
      Signed-off-by: NMarc Kleine-Budde <mkl@pengutronix.de>
      Signed-off-by: NArtem Bityutskiy <Artem.Bityutskiy@nokia.com>
      af7ad7a0
  2. 03 5月, 2010 1 次提交
  3. 20 4月, 2010 1 次提交
  4. 19 4月, 2010 9 次提交
  5. 18 4月, 2010 1 次提交
  6. 17 4月, 2010 2 次提交
  7. 16 4月, 2010 5 次提交
  8. 14 4月, 2010 11 次提交
  9. 13 4月, 2010 5 次提交
  10. 12 4月, 2010 2 次提交
  11. 10 4月, 2010 2 次提交
    • S
      firewire: cdev: fix information leak · 9cac00b8
      Stefan Richter 提交于
      A userspace client got to see uninitialized stack-allocated memory if it
      specified an _IOC_READ type of ioctl and an argument size larger than
      expected by firewire-core's ioctl handlers (but not larger than the
      core's union ioctl_arg).
      
      Fix this by clearing the requested buffer size to zero, but only at _IOR
      ioctls.  This way, there is almost no runtime penalty to legitimate
      ioctls.  The only legitimate _IOR is FW_CDEV_IOC_GET_CYCLE_TIMER with 12
      or 16 bytes to memset.
      
      [Another way to fix this would be strict checking of argument size (and
      possibly direction) vs. command number.  However, we then need a lookup
      table, and we need to allow for slight size deviations in case of 32bit
      userland on 64bit kernel.]
      Reported-by: NClemens Ladisch <clemens@ladisch.de>
      Signed-off-by: NStefan Richter <stefanr@s5r6.in-berlin.de>
      9cac00b8
    • C
      firewire: cdev: require quadlet-aligned headers for transmit packets · 385ab5bc
      Clemens Ladisch 提交于
      The definition of struct fw_cdev_iso_packet seems to imply that the
      header_length must be quadlet-aligned, and in fact, specifying an
      unaligned header has never really worked when using multiple packet
      structures, because the position of the next control word is computed by
      rounding the header_length _down_, so the last one to three bytes of the
      header would overlap the next control word.
      
      To avoid this problem, check that the header length is properly aligned.
      Signed-off-by: NClemens Ladisch <clemens@ladisch.de>
      Signed-off-by: NStefan Richter <stefanr@s5r6.in-berlin.de>
      385ab5bc