1. 09 11月, 2018 1 次提交
    • A
      ACPI / PMIC: xpower: fix IOSF_MBI dependency · 017ce359
      Arnd Bergmann 提交于
      We still get a link failure with IOSF_MBI=m when the xpower driver
      is built-in:
      
      drivers/acpi/pmic/intel_pmic_xpower.o: In function `intel_xpower_pmic_update_power':
      intel_pmic_xpower.c:(.text+0x4f2): undefined reference to `iosf_mbi_block_punit_i2c_access'
      intel_pmic_xpower.c:(.text+0x5e2): undefined reference to `iosf_mbi_unblock_punit_i2c_access'
      
      This makes the dependency stronger, so we can only build when IOSF_MBI
      is built-in.
      
      Fixes: 6a9b593d (ACPI / PMIC: xpower: Add depends on IOSF_MBI to Kconfig entry)
      Signed-off-by: NArnd Bergmann <arnd@arndb.de>
      Signed-off-by: NRafael J. Wysocki <rafael.j.wysocki@intel.com>
      017ce359
  2. 25 10月, 2018 1 次提交
  3. 16 10月, 2018 1 次提交
  4. 12 10月, 2018 1 次提交
    • B
      ACPI: remove redundant 'default n' from Kconfig · 56f57c07
      Bartlomiej Zolnierkiewicz 提交于
      'default n' is the default value for any bool or tristate Kconfig
      setting so there is no need to write it explicitly.
      
      Also since commit f467c564 ("kconfig: only write '# CONFIG_FOO
      is not set' for visible symbols") the Kconfig behavior is the same
      regardless of 'default n' being present or not:
      
          ...
          One side effect of (and the main motivation for) this change is making
          the following two definitions behave exactly the same:
      
              config FOO
                      bool
      
              config FOO
                      bool
                      default n
      
          With this change, neither of these will generate a
          '# CONFIG_FOO is not set' line (assuming FOO isn't selected/implied).
          That might make it clearer to people that a bare 'default n' is
          redundant.
          ...
      Signed-off-by: NBartlomiej Zolnierkiewicz <b.zolnierkie@samsung.com>
      Signed-off-by: NRafael J. Wysocki <rafael.j.wysocki@intel.com>
      56f57c07
  5. 23 8月, 2018 1 次提交
  6. 24 7月, 2018 1 次提交
    • A
      arm64: fix ACPI dependencies · 2c870e61
      Arnd Bergmann 提交于
      Kconfig reports a warning on x86 builds after the ARM64 dependency
      was added.
      
      drivers/acpi/Kconfig:6:error: recursive dependency detected!
      drivers/acpi/Kconfig:6:       symbol ACPI depends on EFI
      
      This rephrases the dependency to keep the ARM64 details out of the
      shared Kconfig file, so Kconfig no longer gets confused by it.
      
      For consistency, all three architectures that support ACPI now
      select ARCH_SUPPORTS_ACPI in exactly the configuration in which
      they allow it. We still need the 'default x86', as each one
      wants a different default: default-y on x86, default-n on arm64,
      and always-y on ia64.
      
      Fixes: 5bcd4408 ("drivers: acpi: add dependency of EFI for arm64")
      Reviewed-by: NRafael J. Wysocki <rafael.j.wysocki@intel.com>
      Acked-by: NWill Deacon <will.deacon@arm.com>
      Signed-off-by: NArnd Bergmann <arnd@arndb.de>
      Signed-off-by: NWill Deacon <will.deacon@arm.com>
      2c870e61
  7. 23 7月, 2018 1 次提交
  8. 18 5月, 2018 1 次提交
  9. 20 3月, 2018 1 次提交
    • R
      ACPI: Add Time and Alarm Device (TAD) driver · 95c513ec
      Rafael J. Wysocki 提交于
      Introduce a driver for the ACPI Time and Alarm Device (TAD) based on
      Section 9.18 of ACPI 6.2.
      
      This driver only supports the system wakeup capabilities of the TAD
      which are mandatory.  Support for the RTC capabilities of the TAD
      will be added to it in the future.
      
      This driver is entirely sysfs-based.  It provides attributes (under
      the TAD platform device) to allow user space to manage the AC and DC
      wakeup timers of the TAD: set and read their values, set and check
      their expire timer wake policies, check and clear their status and
      check the capabilities of the TAD reported by AML.  The DC timer
      attributes are only present if the TAD supports a separate DC alarm
      timer.
      
      The wakeup events handling and power management of the TAD is
      expected to be taken care of by the ACPI PM domain attached to its
      platform device.
      Signed-off-by: NRafael J. Wysocki <rafael.j.wysocki@intel.com>
      Reviewed-by: NMika Westerberg <mika.westerberg@linux.intel.com>
      Tested-by: NMika Westerberg <mika.westerberg@linux.intel.com>
      95c513ec
  10. 19 3月, 2018 1 次提交
  11. 07 2月, 2018 1 次提交
  12. 15 1月, 2018 1 次提交
  13. 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
  14. 13 10月, 2017 1 次提交
  15. 11 10月, 2017 1 次提交
    • S
      ACPI / LPIT: Add Low Power Idle Table (LPIT) support · eeb2d80d
      Srinivas Pandruvada 提交于
      Add functionality to read LPIT table, which provides:
      
       - Sysfs interface to read residency counters via
         /sys/devices/system/cpu/cpuidle/low_power_idle_cpu_residency_us
         /sys/devices/system/cpu/cpuidle/low_power_idle_system_residency_us
      
      Here the count "low_power_idle_cpu_residency_us" shows the time spent
      by CPU package in low power state.  This is read via MSR interface,
      which points to MSR for PKG C10.
      
      Here the count "low_power_idle_system_residency_us" show the count the
      system was in low power state. This is read via MMIO interface. This
      is mapped to SLP_S0 residency on modern Intel systems. This residency
      is achieved only when CPU is in PKG C10 and all functional blocks are
      in low power state.
      
      It is possible that none of the above counters present or anyone of the
      counter present or all counters present.
      
      For example: On my Kabylake system both of the above counters present.
      After suspend to idle these counts updated and prints:
      
       6916179
       6998564
      
      This counter can be read by tools like turbostat to display. Or it can
      be used to debug, if modern systems are reaching desired low power state.
      
       - Provides an interface to read residency counter memory address
      
         This address can be used to get the base address of PMC memory
         mapped IO.  This is utilized by intel_pmc_core driver to print
         more debug information.
      
      In addition, to avoid code duplication to read iomem, removed the read of
      iomem from acpi_os_read_memory() in osl.c and made a common function
      acpi_os_read_iomem(). This new function is used for reading iomem in
      in both osl.c and acpi_lpit.c.
      
      Link: http://www.uefi.org/sites/default/files/resources/Intel_ACPI_Low_Power_S0_Idle.pdfSigned-off-by: NSrinivas Pandruvada <srinivas.pandruvada@linux.intel.com>
      Signed-off-by: NRafael J. Wysocki <rafael.j.wysocki@intel.com>
      eeb2d80d
  16. 03 10月, 2017 1 次提交
    • R
      ACPI / PMIC: Add TI PMIC TPS68470 operation region driver · e13452ac
      Rajmohan Mani 提交于
      The Kabylake platform coreboot (Chrome OS equivalent of
      BIOS) has defined 4 operation regions for the TI TPS68470 PMIC.
      These operation regions are to enable/disable voltage
      regulators, configure voltage regulators, enable/disable
      clocks and to configure clocks.
      
      This config adds ACPI operation region support for TI TPS68470 PMIC.
      TPS68470 device is an advanced power management unit that powers
      a Compact Camera Module (CCM), generates clocks for image sensors,
      drives a dual LED for flash and incorporates two LED drivers for
      general purpose indicators.
      
      This driver enables ACPI operation region support to control voltage
      regulators and clocks for the TPS68470 PMIC.
      Signed-off-by: NRajmohan Mani <rajmohan.mani@intel.com>
      Acked-by: NSakari Ailus <sakari.ailus@linux.intel.com>
      Signed-off-by: NRafael J. Wysocki <rafael.j.wysocki@intel.com>
      e13452ac
  17. 27 4月, 2017 1 次提交
  18. 20 4月, 2017 2 次提交
  19. 10 4月, 2017 2 次提交
    • B
      EDAC: Remove EDAC_MM_EDAC · e3c4ff6d
      Borislav Petkov 提交于
      Move all the EDAC core functionality behind CONFIG_EDAC and get rid of
      that indirection. Update defconfigs which had it.
      
      While at it, fix dependencies such that EDAC depends on RAS for the
      tracepoints.
      Signed-off-by: NBorislav Petkov <bp@suse.de>
      Cc: linux-arm-kernel@lists.infradead.org
      Cc: linuxppc-dev@lists.ozlabs.org
      Cc: Chris Metcalf <cmetcalf@mellanox.com>
      Cc: linux-edac@vger.kernel.org
      e3c4ff6d
    • B
      ACPI/extlog: Add EDAC dependency · 9613916b
      Borislav Petkov 提交于
      We are calling EDAC functions - make the proper dependencies explicit.
      Signed-off-by: NBorislav Petkov <bp@suse.de>
      Cc: linux-acpi@vger.kernel.org
      9613916b
  20. 08 4月, 2017 1 次提交
  21. 05 4月, 2017 1 次提交
  22. 14 12月, 2016 1 次提交
  23. 24 10月, 2016 1 次提交
  24. 28 9月, 2016 1 次提交
  25. 24 9月, 2016 1 次提交
    • M
      ACPI / watchdog: Add support for WDAT hardware watchdog · 058dfc76
      Mika Westerberg 提交于
      Starting from Intel Skylake the iTCO watchdog timer registers were moved to
      reside in the same register space with SMBus host controller.  Not all
      needed registers are available though and we need to unhide P2SB (Primary
      to Sideband) device briefly to be able to read status of required NO_REBOOT
      bit. The i2c-i801.c SMBus driver used to handle this and creation of the
      iTCO watchdog platform device.
      
      Windows, on the other hand, does not use the iTCO watchdog hardware
      directly even if it is available. Instead it relies on ACPI Watchdog Action
      Table (WDAT) table to describe the watchdog hardware to the OS. This table
      contains necessary information about the the hardware and also set of
      actions which are executed by a driver as needed.
      
      This patch implements a new watchdog driver that takes advantage of the
      ACPI WDAT table. We split the functionality into two parts: first part
      enumerates the WDAT table and if found, populates resources and creates
      platform device for the actual driver. The second part is the driver
      itself.
      
      The reason for the split is that this way we can make the driver itself to
      be a module and loaded automatically if the WDAT table is found. Otherwise
      the module is not loaded.
      Signed-off-by: NMika Westerberg <mika.westerberg@linux.intel.com>
      Reviewed-by: NGuenter Roeck <linux@roeck-us.net>
      Signed-off-by: NRafael J. Wysocki <rafael.j.wysocki@intel.com>
      058dfc76
  26. 13 9月, 2016 1 次提交
  27. 09 9月, 2016 1 次提交
  28. 24 7月, 2016 1 次提交
  29. 22 7月, 2016 2 次提交
  30. 21 7月, 2016 1 次提交
    • S
      ACPI / DPTF: Add DPTF power participant driver · 6256ebd5
      Srinivas Pandruvada 提交于
      This driver adds support for Dynamic Platform and Thermal Framework
      (DPTF) Platform Power Participant device (INT3407) support.
      
      This participant is responsible for exposing platform telemetry such as:
          max_platform_power
          platform_power_source
          adapter_rating
          battery_steady_power
          charger_type
      
      These attributes are presented via sysfs interface under the INT3407
      platform device:
      $ls /sys/bus/platform/devices/INT3407\:00/dptf_power/
          adapter_rating_mw
          battery_steady_power_mw
          charger_type
          max_platform_power_mw
          platform_power_source
          `
      ACPI methods description used in this driver:
          PMAX: Maximum platform power that can be supported by the battery in
                mW.
          PSRC: System charge source,
                  0x00 = DC
                  0x01 = AC
                  0x02 = USB
                  0x03 = Wireless Charger
          ARTG: Adapter rating in mW (Maximum Adapter power) Must be 0 if no
                AC adapter is plugged in.
          CTYP: Charger Type,
                  Traditional : 0x01
                  Hybrid: 0x02
                  NVDC: 0x03
          PBSS: Returns max sustained power for battery in milliWatts.
      
      The INT3407 also contains _BTS and _BIX objects, which are compliant to
      ACPI 5.0, specification. Those objects are already used by ACPI battery
      (PNP0C0A) driver and information about them is exported via Linux power
      supply class registration.
      Signed-off-by: NSrinivas Pandruvada <srinivas.pandruvada@linux.intel.com>
      Signed-off-by: NRafael J. Wysocki <rafael.j.wysocki@intel.com>
      6256ebd5
  31. 09 7月, 2016 1 次提交
  32. 24 6月, 2016 1 次提交
  33. 22 6月, 2016 2 次提交
  34. 11 6月, 2016 1 次提交
  35. 27 4月, 2016 2 次提交