1. 10 1月, 2018 2 次提交
  2. 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
  3. 26 7月, 2017 1 次提交
  4. 10 7月, 2017 1 次提交
  5. 05 7月, 2017 1 次提交
  6. 21 5月, 2017 1 次提交
    • J
      iio: adc: Add support for TI ADC108S102 and ADC128S102 · 7e87d11c
      Jan Kiszka 提交于
      This is an upstream port of an IIO driver for the TI ADC108S102 and
      ADC128S102. The former can be found on the Intel Galileo Gen2 and the
      Siemens SIMATIC IOT2000. For those boards, ACPI-based enumeration is
      included.
      
      Due to the lack of regulators under ACPI, we hard-code the voltage
      provided to the VA pin of the ADC to 5 V, the value used on Galileo and
      IOT2000. For DT usage, the regulator "vref-supply" provides this
      information. Note that DT usage has not been tested.
      
      Original author: Bogdan Pricop <bogdan.pricop@emutex.com>
      Ported from Intel Galileo Gen2 BSP to Intel Yocto kernel:
      Todor Minchev <todor@minchev.co.uk>.
      Signed-off-by: NJan Kiszka <jan.kiszka@siemens.com>
      Signed-off-by: NJonathan Cameron <jic23@kernel.org>
      7e87d11c
  7. 14 5月, 2017 1 次提交
  8. 27 4月, 2017 1 次提交
  9. 14 4月, 2017 1 次提交
    • A
      iio: adc: add max1117/max1118/max1119 ADC driver · a9e9c715
      Akinobu Mita 提交于
      This adds max1117/max1118/max1119 8-bit, dual-channel ADC driver.
      
      This new driver uses the zero length spi_transfers with the cs_change
      flag set and/or the non-zero delay_usecs.
      
      1. The zero length transfer with the spi_transfer.cs_change set is
      required in order to select CH1.  The chip select line must be brought
      high and low again without transfer.
      
      2. The zero length transfer with the spi_transfer.delay_usecs > 0 is
      required for waiting the conversion to be complete.  The conversion
      begins with the falling edge of the chip select.  During the conversion
      process, SCLK is ignored.
      
      These two usages are unusual.  But the spi controller drivers that use
      a default implementation of transfer_one_message() are likely to work.
      (I've tested this adc driver with spi-omap2-mcspi and spi-xilinx)
      
      On the other hand, some spi controller drivers that have their own
      transfer_one_message() may not work.  But at least for the zero length
      transfer with delay_usecs > 0, I'm proposing a new testcase for the
      spi-loopback-test that can test whether the delay_usecs setting has
      taken effect.
      Acked-by: NRob Herring <robh@kernel.org>
      Signed-off-by: NAkinobu Mita <akinobu.mita@gmail.com>
      Cc: Jonathan Cameron <jic23@kernel.org>
      Cc: Hartmut Knaack <knaack.h@gmx.de>
      Cc: Lars-Peter Clausen <lars@metafoo.de>
      Cc: Peter Meerwald-Stadler <pmeerw@pmeerw.net>
      Cc: Rob Herring <robh+dt@kernel.org>
      Cc: Mark Rutland <mark.rutland@arm.com>
      Cc: Mark Brown <broonie@kernel.org>
      Signed-off-by: NJonathan Cameron <jic23@kernel.org>
      a9e9c715
  10. 09 4月, 2017 3 次提交
    • L
      iio: adc: add a driver for Qualcomm PM8xxx HK/XOADC · 63c3ecd9
      Linus Walleij 提交于
      The Qualcomm PM8xxx PMICs contain a simpler ADC than its
      successors (already in the kernel as qcom-spmi-vadc.c):
      the HK/XO ADC (Housekeeping/Chrystal oscillator ADC).
      
      As far as I can understand this is equal to the PMICs
      using SSBI transport and encompass PM8018, PM8038,
      PM8058, and PM8921, so this is shortly named PM8xxx.
      
      This ADC monitors a bunch of on-board voltages and the die
      temperature of the PMIC itself, but it can also be routed
      to convert a few external MPPs (multi-purpose pins). On
      the APQ8060 DragonBoard this feature is used to let this
      ADC convert an analog ALS (Ambient Light Sensor) voltage
      signal from a Capella CM3605 ALS into a LUX value.
      
      Developed and tested with APQ8060 DragonBoard based on
      Ivan's driver and Rama Krishna's patches. The SPMI VADC
      driver is quite different, but share enough minor
      functionality that I have split out to the common file
      in a previous patch.
      
      Cc: linux-arm-kernel@lists.infradead.org
      Cc: linux-arm-msm@vger.kernel.org
      Cc: Ivan T. Ivanov <iivanov.xz@gmail.com>
      Cc: Andy Gross <andy.gross@linaro.org>
      Cc: Bjorn Andersson <bjorn.andersson@linaro.org>
      Cc: Stephen Boyd <sboyd@codeaurora.org>
      Cc: Srinivas Kandagatla <srinivas.kandagatla@linaro.org>
      Cc: Rama Krishna Phani A <rphani@codeaurora.org>
      Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
      Signed-off-by: NJonathan Cameron <jic23@kernel.org>
      63c3ecd9
    • L
      iio: adc: break out common code from SPMI VADC · e932d4f0
      Linus Walleij 提交于
      The SPMI VADC and the earlier XOADC share a subset of
      common code, so to be able to use the same code in both
      drivers, we break out a separate file with the common code,
      prefix exported functions that are no longer static with
      qcom_* and bake an object qcom-spmi-vadc.o that contains both
      files: qcom-vadc-common.o and qcom-spmi-vadc-core.o.
      
      As we need to follow the procedure for making a kernel module
      or compiled in object from several files, but still want to
      produce the same module name, rename the qcom-spmi-vadc.c
      file to qcom-spmi-vadc-core.c so we can bake the two objects
      into qcom-spmi-vadc.o
      
      Cc: linux-arm-kernel@lists.infradead.org
      Cc: linux-arm-msm@vger.kernel.org
      Cc: Ivan T. Ivanov <iivanov.xz@gmail.com>
      Cc: Andy Gross <andy.gross@linaro.org>
      Cc: Bjorn Andersson <bjorn.andersson@linaro.org>
      Cc: Stephen Boyd <sboyd@codeaurora.org>
      Cc: Srinivas Kandagatla <srinivas.kandagatla@linaro.org>
      Cc: Rama Krishna Phani A <rphani@codeaurora.org>
      Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
      Signed-off-by: NJonathan Cameron <jic23@kernel.org>
      e932d4f0
    • J
      iio: adc: Add Maxim max9611 ADC driver · 69780a3b
      Jacopo Mondi 提交于
      Add iio driver for Maxim max9611 and max9612 current-sense amplifiers
      with 12-bits ADC interface.
      
      Datasheet publicly available at:
      https://datasheets.maximintegrated.com/en/ds/MAX9611-MAX9612.pdfSigned-off-by: NJacopo Mondi <jacopo+renesas@jmondi.org>
      Signed-off-by: NJonathan Cameron <jic23@kernel.org>
      69780a3b
  11. 02 4月, 2017 1 次提交
  12. 01 4月, 2017 1 次提交
  13. 31 3月, 2017 1 次提交
    • T
      iio: adc: cpcap: Add minimal support for CPCAP PMIC ADC · 25ec2496
      Tony Lindgren 提交于
      On Motorola phones like droid 4 there is a custom CPCAP PMIC. This PMIC
      has ADCs that are used for battery charging and USB PHY VBUS and ID pin
      detection.
      
      Unfortunately the only documentation for this ADC seems to be the
      Motorola mapphone Linux kernel tree. I have tested that reading raw and
      scaled values works, but I have not used the timed sampling that the ADC
      seems to support.
      
      Let's add a minimal support for it so we can eventually provide IIO
      channels for the related battery charging and USB PHY drivers.
      
      Cc: devicetree@vger.kernel.org
      Cc: Marcel Partap <mpartap@gmx.net>
      Cc: Michael Scott <michael.scott@linaro.org>
      Cc: Sebastian Reichel <sre@kernel.org>
      Signed-off-by: NTony Lindgren <tony@atomide.com>
      Acked-by: NRob Herring <robh@kernel.org>
      Signed-off-by: NJonathan Cameron <jic23@kernel.org>
      25ec2496
  14. 23 3月, 2017 2 次提交
  15. 09 3月, 2017 1 次提交
    • Q
      iio: adc: add support for Allwinner SoCs ADC · d1caa990
      Quentin Schulz 提交于
      The Allwinner SoCs all have an ADC that can also act as a touchscreen
      controller and a thermal sensor. This patch adds the ADC driver which is
      based on the MFD for the same SoCs ADC.
      
      This also registers the thermal adc channel in the iio map array so
      iio_hwmon could use it without modifying the Device Tree. This registers
      the driver in the thermal framework.
      
      The thermal sensor requires the IP to be in touchscreen mode to return
      correct values. Therefore, if the user is continuously reading the ADC
      channel(s), the thermal framework in which the thermal sensor is
      registered will switch the IP in touchscreen mode to get a temperature
      value and requires a delay of 100ms (because of the mode switching),
      then the ADC will switch back to ADC mode and requires also a delay of
      100ms. If the ADC readings are critical to user and the SoC temperature
      is not, this driver is capable of not registering the thermal sensor in
      the thermal framework and thus, "quicken" the ADC readings.
      
      This driver probes on three different platform_device_id to take into
      account slight differences (registers bit and temperature computation)
      between Allwinner SoCs ADCs.
      Signed-off-by: NQuentin Schulz <quentin.schulz@free-electrons.com>
      Acked-by: NMaxime Ripard <maxime.ripard@free-electrons.com>
      Acked-by: NJonathan Cameron <jic23@kernel.org>
      Acked-for-MFD-by: NLee Jones <lee.jones@linaro.org>
      Signed-off-by: NJonathan Cameron <jic23@kernel.org>
      d1caa990
  16. 11 2月, 2017 2 次提交
    • J
      staging:iio:adc:lpc32xx Move out of staging. · 0097e20e
      Jonathan Cameron 提交于
      There are a few more little cleanups that could be done on this driver, but
      I don't think any are sufficient to justify not moving it out of staging.
      
      It's a very simple driver (presumably for a simple part) so not much that can
      go wrong.  I think it was only ever in staging because that's where IIO was
      as a whole at the time and then we forgot about it!
      Signed-off-by: NJonathan Cameron <jic23@kernel.org>
      Cc: Roland Stigge <stigge@antcom.de>
      Signed-off-by: NJonathan Cameron <jic23@kernel.org>
      0097e20e
    • J
      staging:iio:adc:spear Move out of staging. · af8f651b
      Jonathan Cameron 提交于
      There are some unanswered questions due to disagreements between the code
      and various datasheets (including between different datasheets for the same
      part).
      
      I don't think that is necessarily a reason to keep it in staging however.
      I'm partly posting this patch inorder to reignite debate and with a bit
      of luck find someone who has one of these to test!
      Signed-off-by: NJonathan Cameron <jic23@kernel.org>
      af8f651b
  17. 28 1月, 2017 2 次提交
    • M
      iio: adc: add a driver for the SAR ADC found in Amlogic Meson SoCs · 3adbf342
      Martin Blumenstingl 提交于
      This adds support for the SAR (Successive Approximation Register) ADC
      on the Amlogic Meson SoCs.
      
      The code is based on the public S805 (Meson8b) and S905 (GXBB)
      datasheets (see [0] and [1]), as well as by reading (various versions
      of) the vendor driver and by inspecting the registers on the vendor
      kernels of my testing-hardware.
      
      Currently the GXBB, GXL and GXM SoCs are supported. GXBB hardware has
      10-bit ADC resolution, while GXL and GXM have 12-bit ADC resolution.
      The code was written to support older SoCs (Meson8 and Meson8b) as well,
      but due to lack of actual testing-hardware no of_device_id was added for
      these.
      
      Two "features" from the vendor driver are currently missing:
      - the vendor driver uses channel #7 for calibration (this improves the
        accuracy of the results - in my tests the results were less than 3%
        off without calibration compared to the vendor driver). Adding support
        for this should be easy, but is not required for most applications.
      - channel #6 is connected to the SoCs internal temperature sensor.
        Adding support for this is probably not so easy since (based on the
        u-boot sources) most SoC versions are using different registers and
        algorithms for the conversion from "ADC value" to temperature.
      
      Supported by the hardware but currently not supported by the driver:
      - reading multiple channels at the same time (the hardware has a FIFO
        buffer which stores multiple results)
      - continuous sampling (this would require a way to enable this
        individually because otherwise the ADC would be drawing power
        constantly)
      - interrupt support (similar to the vendor driver this new driver is
        polling the results. It is unclear if the IRQ-mode is supported on
        older (Meson6 or Meson8) hardware as well or if there are any errata)
      
      [0]
      http://dn.odroid.com/S805/Datasheet/S805_Datasheet%20V0.8%2020150126.pdf
      [1] http://dn.odroid.com/S905/DataSheet/S905_Public_Datasheet_V1.1.4.pdfSigned-off-by: NMartin Blumenstingl <martin.blumenstingl@googlemail.com>
      Tested-by: NNeil Armstrong <narmstrong@baylibre.com>
      Signed-off-by: NJonathan Cameron <jic23@kernel.org>
      3adbf342
    • M
      iio: adc: Add Renesas GyroADC driver · 059c53b3
      Marek Vasut 提交于
      Add IIO driver for the Renesas RCar GyroADC block. This block is a
      simple 4/8-channel ADC which samples 12/15/24 bits of data every
      cycle from all channels.
      Signed-off-by: NMarek Vasut <marek.vasut+renesas@gmail.com>
      Cc: Geert Uytterhoeven <geert+renesas@glider.be>
      Cc: Simon Horman <horms+renesas@verge.net.au>
      Cc: Jonathan Cameron <jic23@kernel.org>
      Cc: linux-renesas-soc@vger.kernel.org
      Cc: Wolfram Sang <wsa@the-dreams.de>
      Signed-off-by: NJonathan Cameron <jic23@kernel.org>
      059c53b3
  18. 22 1月, 2017 1 次提交
  19. 21 1月, 2017 1 次提交
  20. 11 1月, 2017 1 次提交
  21. 03 12月, 2016 1 次提交
  22. 19 11月, 2016 2 次提交
  23. 13 11月, 2016 1 次提交
  24. 28 9月, 2016 1 次提交
  25. 04 9月, 2016 1 次提交
    • W
      iio: stx104: Add IIO support for the ADC channels · 4075a283
      William Breathitt Gray 提交于
      The Apex Embedded Systems STX104 features 16 channels of single-ended (8
      channels of true differential) 16-bit analog input. Differential input
      configuration may be selected via a physical jumper on the device.
      Similarly, input polarity (unipolar/bipolar) is configured via a
      physical jumper on the device.
      
      Input gain selection is available to the user via software, thus
      allowing eight possible input ranges: +-10V, +-5V, +-2.5V, +-1.25V,
      0 to 10V, 0 to 5V, 0 to 2.5V, and 0 to 1.25V. Four input gain
      configurations are supported: x1, x2, x4, and x8.
      
      This ADC resolution is 16-bits (1/65536 of full scale). Analog input
      samples are taken on software trigger; neither FIFO sampling nor
      interrupt triggering is supported by this driver.
      
      The Apex Embedded Systems STX104 is primarily an analog-to-digital
      converter device. The STX104 IIO driver was initially placed in the DAC
      directory because only the DAC portion of the STX104 was supported at
      the time. Now that ADC support has been added to the STX104 IIO driver,
      the driver should be moved to the more appropriate ADC directory.
      Signed-off-by: NWilliam Breathitt Gray <vilhelm.gray@gmail.com>
      Signed-off-by: NJonathan Cameron <jic23@kernel.org>
      4075a283
  26. 01 9月, 2016 1 次提交
  27. 29 8月, 2016 1 次提交
  28. 22 8月, 2016 1 次提交
  29. 21 8月, 2016 1 次提交
  30. 03 7月, 2016 1 次提交
  31. 13 3月, 2016 1 次提交
  32. 14 2月, 2016 1 次提交
  33. 11 2月, 2016 1 次提交