1. 24 6月, 2019 4 次提交
    • S
      bus_find_device: Unify the match callback with class_find_device · 418e3ea1
      Suzuki K Poulose 提交于
      There is an arbitrary difference between the prototypes of
      bus_find_device() and class_find_device() preventing their callers
      from passing the same pair of data and match() arguments to both of
      them, which is the const qualifier used in the prototype of
      class_find_device().  If that qualifier is also used in the
      bus_find_device() prototype, it will be possible to pass the same
      match() callback function to both bus_find_device() and
      class_find_device(), which will allow some optimizations to be made in
      order to avoid code duplication going forward.  Also with that, constify
      the "data" parameter as it is passed as a const to the match function.
      
      For this reason, change the prototype of bus_find_device() to match
      the prototype of class_find_device() and adjust its callers to use the
      const qualifier in accordance with the new prototype of it.
      
      Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com>
      Cc: Andrew Lunn <andrew@lunn.ch>
      Cc: Andreas Noever <andreas.noever@gmail.com>
      Cc: Arnd Bergmann <arnd@arndb.de>
      Cc: Bjorn Helgaas <bhelgaas@google.com>
      Cc: Corey Minyard <minyard@acm.org>
      Cc: Christian Borntraeger <borntraeger@de.ibm.com>
      Cc: David Kershner <david.kershner@unisys.com>
      Cc: "David S. Miller" <davem@davemloft.net>
      Cc: David Airlie <airlied@linux.ie>
      Cc: Felipe Balbi <balbi@kernel.org>
      Cc: Frank Rowand <frowand.list@gmail.com>
      Cc: Grygorii Strashko <grygorii.strashko@ti.com>
      Cc: Harald Freudenberger <freude@linux.ibm.com>
      Cc: Hartmut Knaack <knaack.h@gmx.de>
      Cc: Heiko Stuebner <heiko@sntech.de>
      Cc: Jason Gunthorpe <jgg@ziepe.ca>
      Cc: Jonathan Cameron <jic23@kernel.org>
      Cc: "James E.J. Bottomley" <jejb@linux.ibm.com>
      Cc: Len Brown <lenb@kernel.org>
      Cc: Mark Brown <broonie@kernel.org>
      Cc: Michael Ellerman <mpe@ellerman.id.au>
      Cc: Michael Jamet <michael.jamet@intel.com>
      Cc: "Martin K. Petersen" <martin.petersen@oracle.com>
      Cc: Peter Oberparleiter <oberpar@linux.ibm.com>
      Cc: Sebastian Ott <sebott@linux.ibm.com>
      Cc: Srinivas Kandagatla <srinivas.kandagatla@linaro.org>
      Cc: Yehezkel Bernat <YehezkelShB@gmail.com>
      Cc: rafael@kernel.org
      Acked-by: NCorey Minyard <minyard@acm.org>
      Acked-by: NDavid Kershner <david.kershner@unisys.com>
      Acked-by: NMark Brown <broonie@kernel.org>
      Acked-by: NRafael J. Wysocki <rafael.j.wysocki@intel.com>
      Acked-by: NSrinivas Kandagatla <srinivas.kandagatla@linaro.org>
      Acked-by: Wolfram Sang <wsa@the-dreams.de> # for the I2C parts
      Acked-by: NRob Herring <robh@kernel.org>
      Signed-off-by: NSuzuki K Poulose <suzuki.poulose@arm.com>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      418e3ea1
    • S
      acpi: utils: Cleanup acpi_dev_match_cb · e6374f6b
      Suzuki K Poulose 提交于
      The prototype of bus_find_device() will be unified with that of
      class_find_device() subsequently, but for this purpose the callback
      functions passed to it need to take (const void *) as the second
      argument.  Consequently, they cannot modify the memory pointed to by
      that argument which currently is not the case for acpi_dev_match_cb().
      However, acpi_dev_match_cb() really need not modify the "match" object
      passed to it, because acpi_dev_get_first_match_dev() which uses it via
      bus_find_device() can easily convert the result of bus_find_device()
      into the pointer to return.
      
      For this reason, update acpi_dev_match_cb() to avoid the redundant
      memory updates.
      
      Cc: Len Brown <lenb@kernel.org>
      Cc: linux-acpi@vger.kernel.org
      Signed-off-by: NSuzuki K Poulose <suzuki.poulose@arm.com>
      Reviewed-by: NRafael J. Wysocki <rafael.j.wysocki@intel.com>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      e6374f6b
    • S
      mfd: Remove unused helper syscon_regmap_lookup_by_pdevname · 29d14b66
      Suzuki K Poulose 提交于
      Nobody uses the exported helper syscon_regmap_lookup_by_pdevname,
      to lookup a device by name. Let us remove it.
      Suggested-by: NArnd Bergman <arnd@arnd.de>
      Cc: Arnd Bergman <arnd@arnd.de>
      Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
      Cc: "Rafael J. Wysocki" <rafael@kernel.org>
      Signed-off-by: NSuzuki K Poulose <suzuki.poulose@arm.com>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      29d14b66
    • S
      staging: most-core: Use bus_find_device_by_name · 209de310
      Suzuki K Poulose 提交于
      Use bus_find_device_by_name() helper instead of writing our
      own helper.
      
      Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
      Cc: "Rafael J. Wysocki" <rafael@kernel.org>
      Cc: Christian Gromm <christian.gromm@microchip.com>
      Cc: "Gustavo A. R. Silva" <gustavo@embeddedor.com>
      Cc: Colin Ian King <colin.king@canonical.com>
      Signed-off-by: NSuzuki K Poulose <suzuki.poulose@arm.com>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      209de310
  2. 23 6月, 2019 1 次提交
  3. 21 6月, 2019 7 次提交
  4. 20 6月, 2019 2 次提交
  5. 18 6月, 2019 10 次提交
  6. 12 6月, 2019 3 次提交
  7. 11 6月, 2019 3 次提交
  8. 03 6月, 2019 1 次提交
  9. 02 6月, 2019 3 次提交
    • Q
      drivers/iommu/intel-iommu.c: fix variable 'iommu' set but not used · d3ed71e5
      Qian Cai 提交于
      Commit cf04eee8 ("iommu/vt-d: Include ACPI devices in iommu=pt")
      added for_each_active_iommu() in iommu_prepare_static_identity_mapping()
      but never used the each element, i.e, "drhd->iommu".
      
      drivers/iommu/intel-iommu.c: In function
      'iommu_prepare_static_identity_mapping':
      drivers/iommu/intel-iommu.c:3037:22: warning: variable 'iommu' set but
      not used [-Wunused-but-set-variable]
       struct intel_iommu *iommu;
      
      Fixed the warning by appending a compiler attribute __maybe_unused for it.
      
      Link: http://lkml.kernel.org/r/20190523013314.2732-1-cai@lca.pwSigned-off-by: NQian Cai <cai@lca.pw>
      Suggested-by: NAndrew Morton <akpm@linux-foundation.org>
      Cc: Joerg Roedel <jroedel@suse.de>
      Cc: David Woodhouse <dwmw2@infradead.org>
      Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      d3ed71e5
    • M
      treewide: fix typos of SPDX-License-Identifier · 8e82fe2a
      Masahiro Yamada 提交于
      Prior to the adoption of SPDX, it was difficult for tools to determine
      the correct license due to incomplete or badly formatted license text.
      The SPDX solves this issue, assuming people can correctly spell
      "SPDX-License-Identifier" although this assumption is broken in some
      places.
      
      Since scripts/spdxcheck.py parses only lines that exactly matches to
      the correct tag, it cannot (should not) detect this kind of error.
      
      If the correct tag is missing, scripts/checkpatch.pl warns like this:
      
       WARNING: Missing or malformed SPDX-License-Identifier tag in line *
      
      So, people should notice it before the patch submission, but in reality
      broken tags sometimes slip in. The checkpatch warning is not useful for
      checking the committed files globally since large number of files still
      have no SPDX tag.
      
      Also, I am not sure about the legal effect when the SPDX tag is broken.
      
      Anyway, these typos are absolutely worth fixing. It is pretty easy to
      find suspicious lines by grep.
      
        $ git grep --not -e SPDX-License-Identifier --and -e SPDX- -- \
          :^LICENSES :^scripts/spdxcheck.py :^*/license-rules.rst
        arch/arm/kernel/bugs.c:// SPDX-Identifier: GPL-2.0
        drivers/phy/st/phy-stm32-usbphyc.c:// SPDX-Licence-Identifier: GPL-2.0
        drivers/pinctrl/sh-pfc/pfc-r8a77980.c:// SPDX-Lincense-Identifier: GPL 2.0
        lib/test_stackinit.c:// SPDX-Licenses: GPLv2
        sound/soc/codecs/max9759.c:// SPDX-Licence-Identifier: GPL-2.0
      Signed-off-by: NMasahiro Yamada <yamada.masahiro@socionext.com>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      8e82fe2a
    • A
      crypto: ux500 - fix license comment syntax error · 62e139eb
      Alex Xu (Hello71) 提交于
      Causes error: drivers/crypto/ux500/cryp/Makefile:5: *** missing
      separator.  Stop.
      
      Fixes: af873fce ("treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 194")
      Signed-off-by: NAlex Xu (Hello71) <alex_y_xu@yahoo.ca>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      62e139eb
  10. 01 6月, 2019 1 次提交
    • P
      leds: avoid flush_work in atomic context · 8c0f693c
      Pavel Machek 提交于
      It turns out that various triggers use led_blink_setup() from atomic
      context, so we can't do a flush_work there. Flush is still needed for
      slow LEDs, but we can move it to sysfs code where it is safe.
      
          WARNING: inconsistent lock state
          5.2.0-rc1 #1 Tainted: G        W
          --------------------------------
          inconsistent {SOFTIRQ-ON-W} -> {IN-SOFTIRQ-W} usage.
          swapper/1/0 [HC0[0]:SC1[1]:HE1:SE0] takes:
          000000006e30541b
          ((work_completion)(&led_cdev->set_brightness_work)){+.?.}, at:
          +__flush_work+0x3b/0x38a
          {SOFTIRQ-ON-W} state was registered at:
            lock_acquire+0x146/0x1a1
           __flush_work+0x5b/0x38a
           flush_work+0xb/0xd
           led_blink_setup+0x1e/0xd3
           led_blink_set+0x3f/0x44
           tpt_trig_timer+0xdb/0x106
           ieee80211_mod_tpt_led_trig+0xed/0x112
      
      Fixes: 0db37915 ("leds: avoid races with workqueue")
      Signed-off-by: NPavel Machek <pavel@ucw.cz>
      Tested-by: NHugh Dickins <hughd@google.com>
      Signed-off-by: NJacek Anaszewski <jacek.anaszewski@gmail.com>
      8c0f693c
  11. 31 5月, 2019 5 次提交