WSL2-Linux-Kernel/drivers/iio/adc
Linus Torvalds 291b38a756 Annotation of module parameters that specify device settings
-----BEGIN PGP SIGNATURE-----
 
 iQIVAwUAWPiW6vSw1s6N8H32AQLOrw/+NTqGf7bjq+64YKS6NfR0XDgE+wNJltGO
 ck7zJW3NHIg76RNu8s0I9xg5aVmwizz3Z5DGROZquaolnezux4tQihZ3AFyxIzLc
 +Y3WHYagcML7yFfjl/WznCLRD5EW3yPln4lCvQO0nW/xICRYeRI057JaIbi2Dtek
 BhcXt3c4AjXDLdYJkgtHV3p2R2mt8hcdFdWqqx6s7JaIThZNRGNzxAgtbcB9k5IW
 HVG9ZEIL73VBYWHrYivzjHYF5rBnNCPt87eOwDQeTOSkhv8te+u9k+bH8vxZw1T0
 XUtDrLBndKiuVo2GUfLkkF8LItx3Q9eLCJYy0joaIliyPqTEsPx9KjQ+Af0cxS9s
 ZPCZ5SYf96stKmDeL5xaMfrAmeyVHJ4lc4JTOqdzbIT8blsOSfYO/03p0ALShSDv
 /RQLaKGlf8Bjoy8PwKFcXb4sIDufcd/U1Av/EMFXxOfgN/u2JUkGKq6EaIM5B68L
 fHPje+aR9VNELPmPjwNOWtmN4I79EH3EItQf7zv0KG+UeKhcHLx/EAcSJ3ZRKEkH
 Lathg7pPOEJGArPiVO79TZzBG01ADn1aiwv65XObMzNZ+54xI/mN/Y1DNF/kL5jU
 XzvNzEjFt8mwMIZGVNdAt4+pDyMfIZGZSyUkSRKFnaQZMIvQrfQIU9RLBYLX5eOx
 +/p0VkIwDpg=
 =lbS7
 -----END PGP SIGNATURE-----

Merge tag 'hwparam-20170420' of git://git.kernel.org/pub/scm/linux/kernel/git/dhowells/linux-fs

Pull hw lockdown support from David Howells:
 "Annotation of module parameters that configure hardware resources
  including ioports, iomem addresses, irq lines and dma channels.

  This allows a future patch to prohibit the use of such module
  parameters to prevent that hardware from being abused to gain access
  to the running kernel image as part of locking the kernel down under
  UEFI secure boot conditions.

  Annotations are made by changing:

        module_param(n, t, p)
        module_param_named(n, v, t, p)
        module_param_array(n, t, m, p)

  to:

        module_param_hw(n, t, hwtype, p)
        module_param_hw_named(n, v, t, hwtype, p)
        module_param_hw_array(n, t, hwtype, m, p)

  where the module parameter refers to a hardware setting

  hwtype specifies the type of the resource being configured. This can
  be one of:

        ioport          Module parameter configures an I/O port
        iomem           Module parameter configures an I/O mem address
        ioport_or_iomem Module parameter could be either (runtime set)
        irq             Module parameter configures an I/O port
        dma             Module parameter configures a DMA channel
        dma_addr        Module parameter configures a DMA buffer address
        other           Module parameter configures some other value

  Note that the hwtype is compile checked, but not currently stored (the
  lockdown code probably won't require it). It is, however, there for
  future use.

  A bonus is that the hwtype can also be used for grepping.

  The intention is for the kernel to ignore or reject attempts to set
  annotated module parameters if lockdown is enabled. This applies to
  options passed on the boot command line, passed to insmod/modprobe or
  direct twiddling in /sys/module/ parameter files.

  The module initialisation then needs to handle the parameter not being
  set, by (1) giving an error, (2) probing for a value or (3) using a
  reasonable default.

  What I can't do is just reject a module out of hand because it may
  take a hardware setting in the module parameters. Some important
  modules, some ipmi stuff for instance, both probe for hardware and
  allow hardware to be manually specified; if the driver is aborts with
  any error, you don't get any ipmi hardware.

  Further, trying to do this entirely in the module initialisation code
  doesn't protect against sysfs twiddling.

  [!] Note that in and of itself, this series of patches should have no
      effect on the the size of the kernel or code execution - that is
      left to a patch in the next series to effect. It does mark
      annotated kernel parameters with a KERNEL_PARAM_FL_HWPARAM flag in
      an already existing field"

* tag 'hwparam-20170420' of git://git.kernel.org/pub/scm/linux/kernel/git/dhowells/linux-fs: (38 commits)
  Annotate hardware config module parameters in sound/pci/
  Annotate hardware config module parameters in sound/oss/
  Annotate hardware config module parameters in sound/isa/
  Annotate hardware config module parameters in sound/drivers/
  Annotate hardware config module parameters in fs/pstore/
  Annotate hardware config module parameters in drivers/watchdog/
  Annotate hardware config module parameters in drivers/video/
  Annotate hardware config module parameters in drivers/tty/
  Annotate hardware config module parameters in drivers/staging/vme/
  Annotate hardware config module parameters in drivers/staging/speakup/
  Annotate hardware config module parameters in drivers/staging/media/
  Annotate hardware config module parameters in drivers/scsi/
  Annotate hardware config module parameters in drivers/pcmcia/
  Annotate hardware config module parameters in drivers/pci/hotplug/
  Annotate hardware config module parameters in drivers/parport/
  Annotate hardware config module parameters in drivers/net/wireless/
  Annotate hardware config module parameters in drivers/net/wan/
  Annotate hardware config module parameters in drivers/net/irda/
  Annotate hardware config module parameters in drivers/net/hamradio/
  Annotate hardware config module parameters in drivers/net/ethernet/
  ...
2017-05-10 19:13:03 -07:00
..
Kconfig Staging/IIO patches for 4.12-rc1 2017-05-05 18:16:23 -07:00
Makefile Staging/IIO patches for 4.12-rc1 2017-05-05 18:16:23 -07:00
ad799x.c iio: adc: ad799x: constify attribute_group structures 2017-03-29 22:12:41 +01:00
ad7266.c
ad7291.c
ad7298.c
ad7476.c
ad7766.c
ad7791.c
ad7793.c
ad7887.c
ad7923.c
ad_sigma_delta.c
aspeed_adc.c iio: Aspeed ADC 2017-04-01 11:53:20 +01:00
at91-sama5d2_adc.c
at91_adc.c
axp20x_adc.c iio: adc: add support for X-Powers AXP20X and AXP22X PMICs ADCs 2017-04-27 09:25:07 +01:00
axp288_adc.c
bcm_iproc_adc.c
berlin2-adc.c
cc10001_adc.c
cpcap-adc.c iio: adc: cpcap: Add minimal support for CPCAP PMIC ADC 2017-03-30 19:25:23 +01:00
da9150-gpadc.c
envelope-detector.c
exynos_adc.c iio: adc: Remove unnecessary cast on void pointer 2017-04-02 09:46:25 +01:00
fsl-imx25-gcq.c
hi8435.c
hx711.c iio: adc: hx711: constify attribute_group structures 2017-04-01 11:39:04 +01:00
imx7d_adc.c iio: adc: Remove unnecessary cast on void pointer 2017-04-02 09:46:25 +01:00
ina2xx-adc.c iio: adc: ina2xx: Add OF device ID table 2017-03-19 10:47:53 +00:00
lp8788_adc.c
lpc18xx_adc.c
lpc32xx_adc.c staging:iio:adc:lpc32xx Move out of staging. 2017-02-11 11:19:25 +00:00
ltc2485.c
ltc2497.c iio:adc: Driver for Linear Technology LTC2497 ADC 2017-04-02 10:56:59 +01:00
max1027.c iio: adc: Remove unnecessary cast on void pointer 2017-04-02 09:46:25 +01:00
max1118.c iio: adc: add max1117/max1118/max1119 ADC driver 2017-04-14 15:09:06 +01:00
max1363.c iio: adc: max1363: constify attribute_group structures 2017-03-29 22:10:58 +01:00
max9611.c iio: adc: Add Maxim max9611 ADC driver 2017-04-08 17:26:06 +01:00
max11100.c iio: adc: replace comma with a semicolon 2017-03-30 19:11:27 +01:00
mcp320x.c
mcp3422.c
men_z188_adc.c
meson_saradc.c iio: adc: meson-saradc: add calibration 2017-03-25 14:55:03 +00:00
mt6577_auxadc.c
mxs-lradc-adc.c iio: adc: mxs-lradc: Add support for ADC driver 2017-03-23 12:28:43 +00:00
nau7802.c
palmas_gpadc.c iio: adc: palmas_gpadc: retrieve a valid iio_dev in suspend/resume 2017-01-21 14:26:03 +00:00
qcom-pm8xxx-xoadc.c iio: adc: add a driver for Qualcomm PM8xxx HK/XOADC 2017-04-08 17:42:26 +01:00
qcom-spmi-iadc.c
qcom-spmi-vadc.c iio: adc: break out common code from SPMI VADC 2017-04-08 17:40:49 +01:00
qcom-vadc-common.c iio: adc: break out common code from SPMI VADC 2017-04-08 17:40:49 +01:00
qcom-vadc-common.h iio: adc: break out common code from SPMI VADC 2017-04-08 17:40:49 +01:00
rcar-gyroadc.c iio: adc: handle unknow of_device_id data 2017-02-05 09:30:15 +00:00
rockchip_saradc.c iio: adc: Remove unnecessary cast on void pointer 2017-04-02 09:46:25 +01:00
spear_adc.c staging:iio:adc:spear Move out of staging. 2017-02-11 11:17:33 +00:00
stm32-adc-core.c iio: adc: stm32: add optional dma support 2017-01-29 12:49:17 +00:00
stm32-adc-core.h iio: adc: stm32: add optional dma support 2017-01-29 12:49:17 +00:00
stm32-adc.c iio: adc: stm32: add dt option to set resolution 2017-04-03 20:46:01 +01:00
stx104.c Annotation of module parameters that specify device settings 2017-05-10 19:13:03 -07:00
sun4i-gpadc-iio.c iio: adc: sun4i-gpadc-iio: add support for A33 thermal sensor 2017-04-08 17:35:47 +01:00
ti-adc081c.c
ti-adc128s052.c
ti-adc161s626.c
ti-adc0832.c
ti-adc12138.c
ti-ads1015.c iio: adc: ti-ads1015: Add OF device ID table 2017-03-19 10:56:58 +00:00
ti-ads7950.c iio: adc: ti-ads7950: Change regulator matching string to "vref" 2017-01-15 13:56:08 +00:00
ti-ads8688.c
ti-tlc4541.c iio: adc: tlc4541: add support for TI tlc4541 adc 2017-01-22 13:21:28 +00:00
ti_am335x_adc.c iio: adc: ti_am335x_adc: fix fifo overrun recovery 2017-03-15 19:47:23 +00:00
twl4030-madc.c
twl6030-gpadc.c
vf610_adc.c iio: adc: Remove unnecessary cast on void pointer 2017-04-02 09:46:25 +01:00
viperboard_adc.c
xilinx-xadc-core.c iio: adc: xilinx: Fix error handling 2017-02-25 16:39:32 +00:00
xilinx-xadc-events.c
xilinx-xadc.h