1. 06 Jul, 2020 21 commits
    • Lee Jones's avatar
      mfd: tps65218: Repair incorrect function argument name 's/tps65218/tps/' · 9c3739ee
      Lee Jones authored
      The kerneldocs for both tps65218_reg_write() and tps65218_update_bits()
      describe their first arguments as 'tps65218', when in reality these are
      simply called 'tps'.
      
      Fixes the following W=1 warnings:
      
       drivers/mfd/tps65218.c:58: warning: Function parameter or member 'tps' not described in 'tps65218_reg_write'
       drivers/mfd/tps65218.c:58: warning: Excess function parameter 'tps65218' description in 'tps65218_reg_write'
       drivers/mfd/tps65218.c:90: warning: Function parameter or member 'tps' not described in 'tps65218_update_bits'
       drivers/mfd/tps65218.c:90: warning: Excess function parameter 'tps65218' description in 'tps65218_update_bits'
      
      Cc: Tony Lindgren <tony@atomide.com>
      Cc: J Keerthy <j-keerthy@ti.com>
      Cc: linux-omap@vger.kernel.org
      Signed-off-by: default avatarLee Jones <lee.jones@linaro.org>
      9c3739ee
    • Lee Jones's avatar
      mfd: cros_ec_dev: Fix cros_feature_to_{name,cells} struct descriptions · 5ae3d1bc
      Lee Jones authored
      Kerneldoc expects kernel structures to be prefixed with 'struct'.
      
      Fixes the following W=1 level warnings:
      
       drivers/mfd/cros_ec_dev.c:32: warning: cannot understand function prototype: 'struct cros_feature_to_name '
       drivers/mfd/cros_ec_dev.c:44: warning: cannot understand function prototype: 'struct cros_feature_to_cells '
      
      Cc: Benson Leung <bleung@chromium.org>
      Cc: Guenter Roeck <groeck@chromium.org>
      Cc: Bill Richardson <wfrichar@chromium.org>
      Signed-off-by: default avatarLee Jones <lee.jones@linaro.org>
      Acked-by: default avatarEnric Balletbo i Serra <enric.balletbo@collabora.com>
      Signed-off-by: default avatarLee Jones <lee.jones@linaro.org>
      5ae3d1bc
    • Lee Jones's avatar
      mfd: altera-sysmgr: Supply descriptions for 'np' and 'property' function args · 0824c889
      Lee Jones authored
      Kerneldoc syntax is used, but not complete.  Arg descriptions are required.
      
      Fixes the following W=1 build warnings:
      
       drivers/mfd/altera-sysmgr.c:95: warning: Function parameter or member 'np' not described in 'altr_sysmgr_regmap_lookup_by_phandle'
       drivers/mfd/altera-sysmgr.c:95: warning: Function parameter or member 'property' not described in 'altr_sysmgr_regmap_lookup_by_phandle'
      
      Cc: Thor Thayer <thor.thayer@linux.intel.com>
      Signed-off-by: default avatarLee Jones <lee.jones@linaro.org>
      0824c889
    • Lee Jones's avatar
      mfd: atmel-smc: Add missing colon(s) for 'conf' arguments · 1574360a
      Lee Jones authored
      Kerneldoc valication gets confused if syntax isn't "@.*: ".
      
      Adding the missing colons squashes the following W=1 warnings:
      
      drivers/mfd/atmel-smc.c:247: warning: Function parameter or member 'conf' not described in 'atmel_smc_cs_conf_apply'
      drivers/mfd/atmel-smc.c:268: warning: Function parameter or member 'conf' not described in 'atmel_hsmc_cs_conf_apply'
      
      Cc: Nicolas Ferre <nicolas.ferre@microchip.com>
      Cc: Alexandre Belloni <alexandre.belloni@bootlin.com>
      Cc: Ludovic Desroches <ludovic.desroches@microchip.com>
      Cc: Boris Brezillon <boris.brezillon@free-electrons.com>
      Signed-off-by: default avatarLee Jones <lee.jones@linaro.org>
      1574360a
    • Lee Jones's avatar
      mfd: omap-usb-tll: Provide description for 'pdev' argument to .probe() · 55bbf5d4
      Lee Jones authored
      Kerneldoc syntax is used, but not complete.  Arg descriptions required.
      
      Prevents warnings like:
      
       drivers/mfd/omap-usb-tll.c:204: warning: Function parameter or member 'pdev' not described in 'usbtll_omap_probe
      
      Cc: Tony Lindgren <tony@atomide.com>
      Cc: Keshava Munegowda <keshava_mgowda@ti.com>
      Cc: Roger Quadros <rogerq@ti.com>
      Cc: linux-omap@vger.kernel.org
      Signed-off-by: default avatarLee Jones <lee.jones@linaro.org>
      55bbf5d4
    • Lee Jones's avatar
      mfd: omap-usb-host: Provide description for 'pdev' argument to .probe() · 3fc65627
      Lee Jones authored
      Kerneldoc syntax is used, but not complete.  Arg descriptions required.
      
      Prevents warnings like:
      
       drivers/mfd/omap-usb-host.c:531: warning: Function parameter or member 'pdev' not described in 'usbhs_omap_probe'
      
      Cc: Tony Lindgren <tony@atomide.com>
      Cc: Keshava Munegowda <keshava_mgowda@ti.com>
      Cc: Roger Quadros <rogerq@ti.com>
      Cc: linux-omap@vger.kernel.org
      Signed-off-by: default avatarLee Jones <lee.jones@linaro.org>
      3fc65627
    • Lee Jones's avatar
      mfd: omap-usb-host: Remove invalid use of kerneldoc syntax · 5d36df75
      Lee Jones authored
      Kerneldoc is for documenting function arguments and return values.
      
      Prevents warnings like:
      
       drivers/mfd/omap-usb-host.c:128: warning: cannot understand function prototype: 'const char * const port_modes[] = '
      
      Cc: Tony Lindgren <tony@atomide.com>
      Cc: Keshava Munegowda <keshava_mgowda@ti.com>
      Cc: Roger Quadros <rogerq@ti.com>
      Cc: linux-omap@vger.kernel.org
      Signed-off-by: default avatarLee Jones <lee.jones@linaro.org>
      5d36df75
    • Lee Jones's avatar
      mfd: db8500-prcmu: Remove incorrect function header from .probe() function · 07d88c97
      Lee Jones authored
      Not only is the current header incorrect, the isn't actually a
      need to document the ubiquitous platform probe call.
      
      Cc: Linus Walleij <linus.walleij@linaro.org>
      Signed-off-by: default avatarLee Jones <lee.jones@linaro.org>
      07d88c97
    • Lee Jones's avatar
      mfd: db8500-prcmu: Add description for 'reset_reason' in kerneldoc · 3ecbcd20
      Lee Jones authored
      Each function parameter should be documented in kerneldoc format.
      
      Squashes the following W=1 warnings:
      
       drivers/mfd/db8500-prcmu.c:2281: warning: Function parameter or member 'reset_code' not described in 'db8500_prcmu_system_reset'
       drivers/mfd/db8500-prcmu.c:3012: warning: Function parameter or member 'pdev' not described in 'db8500_prcmu_probe'
      
      Cc: Linus Walleij <linus.walleij@linaro.org>
      Signed-off-by: default avatarLee Jones <lee.jones@linaro.org>
      3ecbcd20
    • Lee Jones's avatar
      mfd: mfd-core: Complete kerneldoc header for devm_mfd_add_devices() · 5a0ffef8
      Lee Jones authored
      Each function parameter should be documented in kerneldoc format.
      
      Squashes the following W=1 warnings:
      
       drivers/mfd/mfd-core.c:326: warning: Function parameter or member 'dev' not described in 'devm_mfd_add_devices'
       drivers/mfd/mfd-core.c:326: warning: Function parameter or member 'id' not described in 'devm_mfd_add_devices'
       drivers/mfd/mfd-core.c:326: warning: Function parameter or member 'cells' not described in 'devm_mfd_add_devices'
       drivers/mfd/mfd-core.c:326: warning: Function parameter or member 'n_devs' not described in 'devm_mfd_add_devices'
       drivers/mfd/mfd-core.c:326: warning: Function parameter or member 'mem_base' not described in 'devm_mfd_add_devices'
       drivers/mfd/mfd-core.c:326: warning: Function parameter or member 'irq_base' not described in 'devm_mfd_add_devices'
       drivers/mfd/mfd-core.c:326: warning: Function parameter or member 'domain' not described in 'devm_mfd_add_devices'
      Signed-off-by: default avatarLee Jones <lee.jones@linaro.org>
      5a0ffef8
    • Lee Jones's avatar
      mfd: wm8350-core: Supply description wm8350_reg_{un}lock args · afb718a8
      Lee Jones authored
      Kerneldoc syntax is used, but not complete.  Descriptions required.
      
      Prevents warnings like:
      
       drivers/mfd/wm8350-core.c:136: warning: Function parameter or member 'wm8350' not described in 'wm8350_reg_lock'
       drivers/mfd/wm8350-core.c:165: warning: Function parameter or member 'wm8350' not described in 'wm8350_reg_unlock'
      
      Cc: patches@opensource.cirrus.com
      Signed-off-by: default avatarLee Jones <lee.jones@linaro.org>
      afb718a8
    • Lee Jones's avatar
      mfd: wm831x-core: Supply description wm831x_reg_{un}lock args · 38ea9f47
      Lee Jones authored
      Kerneldoc syntax is used, but not complete.  Descriptions required.
      
      Prevents warnings like:
      
       drivers/mfd/wm831x-core.c:119: warning: Function parameter or member 'wm831x' not described in 'wm831x_reg_lock'
       drivers/mfd/wm831x-core.c:145: warning: Function parameter or member 'wm831x' not described in 'wm831x_reg_unlock'
      
      Cc: Mark Brown <broonie@opensource.wolfsonmicro.com>
      Cc: patches@opensource.cirrus.com
      Signed-off-by: default avatarLee Jones <lee.jones@linaro.org>
      Acked-by: default avatarCharles Keepax <ckeepax@opensource.cirrus.com>
      Signed-off-by: default avatarLee Jones <lee.jones@linaro.org>
      38ea9f47
    • Lee Jones's avatar
      mfd: wm8400-core: Supply description for wm8400_reset_codec_reg_cache's arg · f139ef70
      Lee Jones authored
      Kerneldoc syntax is used, but not complete.  Descriptions required.
      
      Prevents warnings like:
      
       drivers/mfd/wm8400-core.c:113: warning: Function parameter or member 'wm8400' not described in 'wm8400_reset_codec_reg_cache'
      
      Cc: Mark Brown <broonie@opensource.wolfsonmicro.com>
      Cc: patches@opensource.cirrus.com
      Signed-off-by: default avatarLee Jones <lee.jones@linaro.org>
      Acked-by: default avatarCharles Keepax <ckeepax@opensource.cirrus.com>
      Signed-off-by: default avatarLee Jones <lee.jones@linaro.org>
      f139ef70
    • Lee Jones's avatar
      mfd: tc3589x: Remove invalid use of kerneldoc syntax · 0dfae4a3
      Lee Jones authored
      Kerneldoc is for documenting function arguments and return values.
      
      Prevents warnings like:
      
       drivers/mfd/tc3589x.c:32: warning: Enum value 'TC3589X_TC35890' not described in enum 'tc3589x_version'
       drivers/mfd/tc3589x.c:32: warning: Enum value 'TC3589X_TC35892' not described in enum 'tc3589x_version'
       drivers/mfd/tc3589x.c:32: warning: Enum value 'TC3589X_TC35893' not described in enum 'tc3589x_version'
       drivers/mfd/tc3589x.c:32: warning: Enum value 'TC3589X_TC35894' not described in enum 'tc3589x_version'
       drivers/mfd/tc3589x.c:32: warning: Enum value 'TC3589X_TC35895' not described in enum 'tc3589x_version'
       drivers/mfd/tc3589x.c:32: warning: Enum value 'TC3589X_TC35896' not described in enum 'tc3589x_version'
       drivers/mfd/tc3589x.c:32: warning: Enum value 'TC3589X_UNKNOWN' not described in enum 'tc3589x_version'
      Signed-off-by: default avatarLee Jones <lee.jones@linaro.org>
      0dfae4a3
    • Lee Jones's avatar
      mfd: ab8500-debugfs: Fix incompatible types in comparison expression issue · ddb6b26c
      Lee Jones authored
      Smatch reports:
      
       drivers/mfd/ab8500-debugfs.c:1804:20: error: incompatible types in comparison expression (different type sizes):
       drivers/mfd/ab8500-debugfs.c:1804:20:    unsigned int *
       drivers/mfd/ab8500-debugfs.c:1804:20:    unsigned long *
      
      This is due to mixed types being compared in a min() comparison.  Fix
      this by treating values as signed and casting them to the same type
      as the receiving variable.
      
      Cc: Linus Walleij <linus.walleij@linaro.org>
      Signed-off-by: default avatarLee Jones <lee.jones@linaro.org>
      ddb6b26c
    • Lee Jones's avatar
      mfd: ab3100-core: Fix incompatible types in comparison expression warning · 54daa5d4
      Lee Jones authored
      Smatch reports:
      
       drivers/mfd/ab3100-core.c:501:20: error: incompatible types in comparison expression (different type sizes):
       drivers/mfd/ab3100-core.c:501:20:    unsigned int *
       drivers/mfd/ab3100-core.c:501:20:    unsigned long *
       drivers/mfd/ab8500-debugfs.c:1804:20: error: incompatible types in comparison expression (different type sizes):
       drivers/mfd/ab8500-debugfs.c:1804:20:    unsigned int *
       drivers/mfd/ab8500-debugfs.c:1804:20:    unsigned long *
      
      Since the second min() argument can be less than 0 a signed
      variable is required for assignment.  However, the non-sized
      type size_t is passed in from the userspace handlers.  In order
      to firstly compare, then assign the smallest value, we firstly
      need to cast them both to the same as the receiving size_t typed
      variable.
      
      Cc: Linus Walleij <linus.walleij@linaro.org>
      Signed-off-by: default avatarLee Jones <lee.jones@linaro.org>
      54daa5d4
    • Lee Jones's avatar
      mfd: sprd-sc27xx-spi: Fix symbol 'sprd_pmic_detect_charger_type' was not declared warning · 3d4a8757
      Lee Jones authored
      Sparse reports:
      
       drivers/mfd/sprd-sc27xx-spi.c:59:23: warning: symbol 'sprd_pmic_detect_charger_type' was not declared. Should it be static?
      
      ... due to a missing header file.
      
      Cc: Orson Zhai <orsonzhai@gmail.com>
      Cc: Chunyan Zhang <zhang.lyra@gmail.com>
      Signed-off-by: default avatarLee Jones <lee.jones@linaro.org>
      Reviewed-by: default avatarBaolin Wang <baolin.wang7@gmail.com>
      Signed-off-by: default avatarLee Jones <lee.jones@linaro.org>
      3d4a8757
    • Lee Jones's avatar
      mfd: altera-sysmgr: Fix physical address storing hacks · d9ca7801
      Lee Jones authored
      Sparse reports:
      
       drivers/mfd/altera-sysmgr.c:150:30: warning: incorrect type in assignment (different address spaces)
       drivers/mfd/altera-sysmgr.c:150:30:    expected unsigned int [usertype] *base
       drivers/mfd/altera-sysmgr.c:150:30:    got void [noderef] <asn:2> *
       drivers/mfd/altera-sysmgr.c:156:26: warning: incorrect type in argument 3 (different address spaces)
       drivers/mfd/altera-sysmgr.c:156:26:    expected void [noderef] <asn:2> *regs
       drivers/mfd/altera-sysmgr.c:156:26:    got unsigned int [usertype] *base
      
      It appears as though the driver data property 'resource_size_t *base'
      was being used to store 2 different types of addresses (physical and
      IO-mapped) under a single declared type.
      
      Fortunately, no value is recalled from the driver data entry, so it
      can be easily omitted.  Instead we can use the value obtained directly
      from the platform resource to pass through  Regmap into the call-backs
      to be used for the SMCC call and use a local dedicated __iomem
      variable for IO-remapping.
      
      Cc: Thor Thayer <thor.thayer@linux.intel.com>
      Signed-off-by: default avatarLee Jones <lee.jones@linaro.org>
      d9ca7801
    • Lee Jones's avatar
      mfd: tps6586x: Fix cast to restricted __le32 warning · c504a248
      Lee Jones authored
      Silences Sparse warning(s):
      
       drivers/mfd/tps6586x.c:323:16: warning: cast to restricted __le32
       drivers/mfd/tps6586x.c:323:16: warning: cast to restricted __le32
       drivers/mfd/tps6586x.c:323:16: warning: cast to restricted __le32
       drivers/mfd/tps6586x.c:323:16: warning: cast to restricted __le32
       drivers/mfd/tps6586x.c:323:16: warning: cast to restricted __le32
       drivers/mfd/tps6586x.c:323:16: warning: cast to restricted __le32
      
      Cc: Mike Rapoport <mike@compulab.co.il>
      Cc: Eric Miao <eric.miao@marvell.com>
      Signed-off-by: default avatarLee Jones <lee.jones@linaro.org>
      c504a248
    • Lee Jones's avatar
      mfd: twl4030-irq: Fix cast to restricted __le32 warning · b174015b
      Lee Jones authored
      Silences Sparse warning(s):
      
       drivers/mfd/twl4030-irq.c:573:40: warning: cast to restricted __le32
       drivers/mfd/twl4030-irq.c:573:40: warning: cast to restricted __le32
       drivers/mfd/twl4030-irq.c:573:40: warning: cast to restricted __le32
       drivers/mfd/twl4030-irq.c:573:40: warning: cast to restricted __le32
       drivers/mfd/twl4030-irq.c:573:40: warning: cast to restricted __le32
       drivers/mfd/twl4030-irq.c:573:40: warning: cast to restricted __le32
      
      Cc: Tony Lindgren <tony@atomide.com>
      Cc: Kai Svahn <kai.svahn@nokia.com>
      Cc: Syed Khasim <x0khasim@ti.com>
      Cc: linux-omap@vger.kernel.org
      Signed-off-by: default avatarLee Jones <lee.jones@linaro.org>
      b174015b
    • Lee Jones's avatar
      mfd: twl4030-irq: Fix incorrect type in assignment warning · 6fef0d4e
      Lee Jones authored
      Silences Sparse warning:
      
       drivers/mfd/twl4030-irq.c:485:26: warning: incorrect type in assignment (different base types)
       drivers/mfd/twl4030-irq.c:485:26:    expected unsigned int [usertype] word
       drivers/mfd/twl4030-irq.c:485:26:    got restricted __le32 [usertype]
      
      Cc: Tony Lindgren <tony@atomide.com>
      Cc: Kai Svahn <kai.svahn@nokia.com>
      Cc: Syed Khasim <x0khasim@ti.com>
      Cc: linux-omap@vger.kernel.org
      Signed-off-by: default avatarLee Jones <lee.jones@linaro.org>
      6fef0d4e
  2. 01 Jul, 2020 1 commit
    • Johan Hovold's avatar
      mfd: lm3533: Expand control-bank accessors · 4d3ec936
      Johan Hovold authored
      Expand the control-bank accessors that were implemented using macros.
      This allows the definitions of these exported functions to be found more
      easily and specifically avoids a W=1 compiler warning due to the
      redundant brightness sanity check:
      
      drivers/mfd/lm3533-ctrlbank.c: In function 'lm3533_ctrlbank_set_brightness':
      drivers/mfd/lm3533-ctrlbank.c:98:10: warning: comparison is always false due to limited range of data type [-Wtype-limits]
         98 |  if (val > LM3533_##_NAME##_MAX)     \
            |          ^
      drivers/mfd/lm3533-ctrlbank.c:125:1: note: in expansion of macro 'lm3533_ctrlbank_set'
        125 | lm3533_ctrlbank_set(brightness, BRIGHTNESS);
            | ^~~~~~~~~~~~~~~~~~~
      Signed-off-by: default avatarJohan Hovold <johan@kernel.org>
      Signed-off-by: default avatarLee Jones <lee.jones@linaro.org>
      4d3ec936
  3. 30 Jun, 2020 3 commits
  4. 25 Jun, 2020 4 commits
  5. 18 Jun, 2020 11 commits