1. 12 5月, 2018 1 次提交
  2. 03 3月, 2018 1 次提交
  3. 02 12月, 2017 2 次提交
  4. 02 11月, 2017 1 次提交
    • G
      License cleanup: add SPDX GPL-2.0 license identifier to files with no license · b2441318
      Greg Kroah-Hartman 提交于
      Many source files in the tree are missing licensing information, which
      makes it harder for compliance tools to determine the correct license.
      
      By default all files without license information are under the default
      license of the kernel, which is GPL version 2.
      
      Update the files which contain no license information with the 'GPL-2.0'
      SPDX license identifier.  The SPDX identifier is a legally binding
      shorthand, which can be used instead of the full boiler plate text.
      
      This patch is based on work done by Thomas Gleixner and Kate Stewart and
      Philippe Ombredanne.
      
      How this work was done:
      
      Patches were generated and checked against linux-4.14-rc6 for a subset of
      the use cases:
       - file had no licensing information it it.
       - file was a */uapi/* one with no licensing information in it,
       - file was a */uapi/* one with existing licensing information,
      
      Further patches will be generated in subsequent months to fix up cases
      where non-standard license headers were used, and references to license
      had to be inferred by heuristics based on keywords.
      
      The analysis to determine which SPDX License Identifier to be applied to
      a file was done in a spreadsheet of side by side results from of the
      output of two independent scanners (ScanCode & Windriver) producing SPDX
      tag:value files created by Philippe Ombredanne.  Philippe prepared the
      base worksheet, and did an initial spot review of a few 1000 files.
      
      The 4.13 kernel was the starting point of the analysis with 60,537 files
      assessed.  Kate Stewart did a file by file comparison of the scanner
      results in the spreadsheet to determine which SPDX license identifier(s)
      to be applied to the file. She confirmed any determination that was not
      immediately clear with lawyers working with the Linux Foundation.
      
      Criteria used to select files for SPDX license identifier tagging was:
       - Files considered eligible had to be source code files.
       - Make and config files were included as candidates if they contained >5
         lines of source
       - File already had some variant of a license header in it (even if <5
         lines).
      
      All documentation files were explicitly excluded.
      
      The following heuristics were used to determine which SPDX license
      identifiers to apply.
      
       - when both scanners couldn't find any license traces, file was
         considered to have no license information in it, and the top level
         COPYING file license applied.
      
         For non */uapi/* files that summary was:
      
         SPDX license identifier                            # files
         ---------------------------------------------------|-------
         GPL-2.0                                              11139
      
         and resulted in the first patch in this series.
      
         If that file was a */uapi/* path one, it was "GPL-2.0 WITH
         Linux-syscall-note" otherwise it was "GPL-2.0".  Results of that was:
      
         SPDX license identifier                            # files
         ---------------------------------------------------|-------
         GPL-2.0 WITH Linux-syscall-note                        930
      
         and resulted in the second patch in this series.
      
       - if a file had some form of licensing information in it, and was one
         of the */uapi/* ones, it was denoted with the Linux-syscall-note if
         any GPL family license was found in the file or had no licensing in
         it (per prior point).  Results summary:
      
         SPDX license identifier                            # files
         ---------------------------------------------------|------
         GPL-2.0 WITH Linux-syscall-note                       270
         GPL-2.0+ WITH Linux-syscall-note                      169
         ((GPL-2.0 WITH Linux-syscall-note) OR BSD-2-Clause)    21
         ((GPL-2.0 WITH Linux-syscall-note) OR BSD-3-Clause)    17
         LGPL-2.1+ WITH Linux-syscall-note                      15
         GPL-1.0+ WITH Linux-syscall-note                       14
         ((GPL-2.0+ WITH Linux-syscall-note) OR BSD-3-Clause)    5
         LGPL-2.0+ WITH Linux-syscall-note                       4
         LGPL-2.1 WITH Linux-syscall-note                        3
         ((GPL-2.0 WITH Linux-syscall-note) OR MIT)              3
         ((GPL-2.0 WITH Linux-syscall-note) AND MIT)             1
      
         and that resulted in the third patch in this series.
      
       - when the two scanners agreed on the detected license(s), that became
         the concluded license(s).
      
       - when there was disagreement between the two scanners (one detected a
         license but the other didn't, or they both detected different
         licenses) a manual inspection of the file occurred.
      
       - In most cases a manual inspection of the information in the file
         resulted in a clear resolution of the license that should apply (and
         which scanner probably needed to revisit its heuristics).
      
       - When it was not immediately clear, the license identifier was
         confirmed with lawyers working with the Linux Foundation.
      
       - If there was any question as to the appropriate license identifier,
         the file was flagged for further research and to be revisited later
         in time.
      
      In total, over 70 hours of logged manual review was done on the
      spreadsheet to determine the SPDX license identifiers to apply to the
      source files by Kate, Philippe, Thomas and, in some cases, confirmation
      by lawyers working with the Linux Foundation.
      
      Kate also obtained a third independent scan of the 4.13 code base from
      FOSSology, and compared selected files where the other two scanners
      disagreed against that SPDX file, to see if there was new insights.  The
      Windriver scanner is based on an older version of FOSSology in part, so
      they are related.
      
      Thomas did random spot checks in about 500 files from the spreadsheets
      for the uapi headers and agreed with SPDX license identifier in the
      files he inspected. For the non-uapi files Thomas did random spot checks
      in about 15000 files.
      
      In initial set of patches against 4.14-rc6, 3 files were found to have
      copy/paste license identifier errors, and have been fixed to reflect the
      correct identifier.
      
      Additionally Philippe spent 10 hours this week doing a detailed manual
      inspection and review of the 12,461 patched files from the initial patch
      version early this week with:
       - a full scancode scan run, collecting the matched texts, detected
         license ids and scores
       - reviewing anything where there was a license detected (about 500+
         files) to ensure that the applied SPDX license was correct
       - reviewing anything where there was no detection but the patch license
         was not GPL-2.0 WITH Linux-syscall-note to ensure that the applied
         SPDX license was correct
      
      This produced a worksheet with 20 files needing minor correction.  This
      worksheet was then exported into 3 different .csv files for the
      different types of files to be modified.
      
      These .csv files were then reviewed by Greg.  Thomas wrote a script to
      parse the csv files and add the proper SPDX tag to the file, in the
      format that the file expected.  This script was further refined by Greg
      based on the output to detect more types of files automatically and to
      distinguish between header and source .c files (which need different
      comment types.)  Finally Greg ran the script using the .csv files to
      generate the patches.
      Reviewed-by: NKate Stewart <kstewart@linuxfoundation.org>
      Reviewed-by: NPhilippe Ombredanne <pombredanne@nexb.com>
      Reviewed-by: NThomas Gleixner <tglx@linutronix.de>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      b2441318
  5. 26 4月, 2017 1 次提交
  6. 26 3月, 2017 1 次提交
  7. 04 2月, 2017 1 次提交
  8. 31 12月, 2016 1 次提交
    • L
      iio: light: add driver for Capella CM3605 · 8afa505c
      Linus Walleij 提交于
      This adds a driver for the Capella Microsystems CM3605 Ambient
      Light Sensor and proximity sensor. This is a pretty simple entirely
      analog device that is interfaced with the target system using
      the POUT (proximity out) and AOUT (ambient light out) signals.
      
      The POUT signal is a simple high/low signal that indicates whether
      an object is in proximity, most typically used to detect a face
      in front of a mobile device. The signal requires that an infrared
      LED is mounted next to the device, making IR light reflect off
      the object in proximity and triggering the POUT signal. We grab
      a GPIO pin to handle the POUT signal as an interrupt line and
      register this as an event channel for the sensor.
      
      Since the proximity sensor requires an IR LED, we add a LED trigger
      named "cm3605" so that the infrared LED can just associate with
      this trigger to be sure it is always on when the proximity sensor
      needs it.
      
      The AOUT is an analog voltage between 0 and 1550 mV that indicate
      the LUX value in the ambient light: this is orthogonal to the
      proximity sensor functionality. Since this analog voltage needs
      to be converted into a digital value, the driver grabs an IIO
      channel named "aout" associated with the device.
      
      This patch created a combined ALS and proximity sensor driver.
      The former supports raw reads of the LUX value and the latter
      will generate proximity events.
      
      To integrate this properly with Linux we also add a supply
      regulator for the VDD pin (driving both functions) and add device
      tree bindings to define the RSET resistor that in turn configures
      the luminosity range of the ALS sensor.
      
      Since the sensor needs to be on more or less constantly, we
      restrict the power management to system suspend/resume: we
      disable the IR LED and disable the regulator for VDD on suspend
      and take them back up on resume.
      
      Tests:
      cd /sys/bus/iio/devices/iio:device1
      cat in_illuminance_raw
      304
      (hold hand over sensor)
      cat in_illuminance_raw
      17
      iio_event_monitor cm3605
      Found IIO device with name cm3605 with device number 1
      (hold hand over sensor)
      Event: time: 2444842301447, type: proximity, channel: 0,
        evtype: thresh, direction: falling
      (remove hand over sensor)
      Event: time: 2445583440706, type: proximity, channel: 0,
        evtype: thresh, direction: rising
      
      Cc: Capella Microsystems <capellamicro@gmail.com>
      Cc: Kevin Tsai <ktsai@capellamicro.com>
      Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
      Signed-off-by: NJonathan Cameron <jic23@kernel.org>
      8afa505c
  9. 13 11月, 2016 1 次提交
  10. 24 10月, 2016 1 次提交
  11. 19 9月, 2016 1 次提交
  12. 24 4月, 2016 1 次提交
  13. 20 4月, 2016 1 次提交
  14. 17 4月, 2016 1 次提交
    • L
      iio: light: new driver for the ROHM BH1780 · 1f0477f1
      Linus Walleij 提交于
      This is a reimplementation of the old misc device driver for the
      ROHM BH1780 ambient light sensor (drivers/misc/bh1780gli.c).
      
      Differences from the old driver:
      - Uses the IIO framework
      - Uses runtime PM to idle the hardware after 5 seconds
      - No weird custom power management from userspace
      - No homebrewn values in sysfs
      
      This uses the same (undocumented) device tree compatible-string
      as the old driver ("rohm,bh1780gli").
      
      Cc: Arnd Bergmann <arnd@arndb.de>
      Cc: Ulf Hansson <ulf.hansson@linaro.org>
      Cc: Daniel Mack <daniel@caiaq.de>
      Cc: Peter Meerwald-Stadler <pmeerw@pmeerw.net>
      Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
      Reviewed-by: NUlf Hansson <ulf.hansson@linaro.org>
      Signed-off-by: NJonathan Cameron <jic23@kernel.org>
      1f0477f1
  15. 24 9月, 2015 1 次提交
  16. 31 8月, 2015 1 次提交
  17. 21 7月, 2015 2 次提交
  18. 21 6月, 2015 1 次提交
  19. 11 5月, 2015 3 次提交
  20. 15 3月, 2015 1 次提交
  21. 28 1月, 2015 1 次提交
  22. 08 11月, 2014 1 次提交
  23. 11 9月, 2014 1 次提交
  24. 07 7月, 2014 2 次提交
  25. 22 2月, 2014 1 次提交
  26. 13 1月, 2014 1 次提交
  27. 01 1月, 2014 1 次提交
  28. 18 10月, 2013 1 次提交
  29. 15 9月, 2013 3 次提交
  30. 04 8月, 2013 2 次提交
  31. 28 1月, 2013 1 次提交
  32. 07 9月, 2012 1 次提交