WSL2-Linux-Kernel/drivers/watchdog
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 watchdog: retu: restore MFD dependency 2017-03-01 06:15:10 -08:00
Makefile watchdog: zx2967: add watchdog controller driver for ZTE's zx2967 family 2017-02-24 14:00:23 -08:00
acquirewdt.c
advantechwdt.c
alim1535_wdt.c
alim7101_wdt.c
ar7_wdt.c
asm9260_wdt.c watchdog: constify watchdog_ops structures 2017-02-24 14:00:23 -08:00
aspeed_wdt.c watchdog: aspeed_wdt: Convert to use device managed functions 2017-02-24 14:00:23 -08:00
at32ap700x_wdt.c
at91rm9200_wdt.c
at91sam9_wdt.c
at91sam9_wdt.h
ath79_wdt.c
atlas7_wdt.c watchdog: constify watchdog_ops structures 2017-02-24 14:00:23 -08:00
bcm47xx_wdt.c watchdog: bcm47xx_wdt: Don't validate platform data on remove 2017-02-24 14:00:23 -08:00
bcm63xx_wdt.c
bcm2835_wdt.c scripts/spelling.txt: add "partiton" pattern and fix typo instances 2017-02-27 18:43:46 -08:00
bcm7038_wdt.c watchdog: constify watchdog_info structures 2017-02-24 14:00:23 -08:00
bcm_kona_wdt.c watchdog: constify watchdog_ops structures 2017-02-24 14:00:23 -08:00
bfin_wdt.c
booke_wdt.c watchdog: constify watchdog_ops structures 2017-02-24 14:00:23 -08:00
cadence_wdt.c watchdog: constify watchdog_info structures 2017-02-24 14:00:23 -08:00
coh901327_wdt.c watchdog: coh901327_wdt: Use dev variable instead of pdev->dev 2017-02-24 14:00:23 -08:00
cpu5wdt.c Annotate hardware config module parameters in drivers/watchdog/ 2017-04-20 12:02:32 +01:00
cpwd.c watchdog: cpwd: remove memory allocate failure message 2016-12-16 06:53:55 -08:00
da9052_wdt.c watchdog: da9052_wdt: Convert to use device managed functions 2017-02-24 14:00:23 -08:00
da9055_wdt.c watchdog: da9055_wdt: Convert to use device managed functions 2017-02-24 14:00:23 -08:00
da9062_wdt.c watchdog: da9062_wdt: Convert to use device managed functions 2017-02-24 14:00:23 -08:00
da9063_wdt.c watchdog: da9063_wdt: Convert to use device managed functions 2017-02-24 14:00:23 -08:00
davinci_wdt.c watchdog: davinci: add support for deferred probing 2016-12-16 06:53:53 -08:00
diag288_wdt.c watchdog: constify watchdog_ops structures 2017-02-24 14:00:23 -08:00
digicolor_wdt.c watchdog: constify watchdog_ops structures 2017-02-24 14:00:23 -08:00
dw_wdt.c watchdog: dw_wdt: Use watchdog core to install restart handler 2017-02-24 14:00:23 -08:00
ebc-c384_wdt.c watchdog: ebc-c384_wdt: Utilize devm_ functions in driver probe callback 2017-02-24 14:00:23 -08:00
ep93xx_wdt.c watchdog: ep93xx_wdt: cleanup and let the core handle the heartbeat 2017-02-24 14:00:23 -08:00
eurotechwdt.c Annotate hardware config module parameters in drivers/watchdog/ 2017-04-20 12:02:32 +01:00
f71808e_wdt.c
gef_wdt.c
gemini_wdt.c watchdog: add driver for Cortina Gemini watchdog 2017-02-24 14:00:23 -08:00
geodewdt.c
gpio_wdt.c
hpwdt.c drivers/watchdog/hpwdt.c: use set_memory.h header 2017-05-08 17:15:14 -07:00
i6300esb.c
iTCO_vendor.h
iTCO_vendor_support.c
iTCO_wdt.c watchdog: iTCO_wdt: Add PMC specific noreboot update api 2017-04-28 21:51:28 +03:00
ib700wdt.c
ibmasr.c
ie6xx_wdt.c
imgpdc_wdt.c watchdog: constify watchdog_info structures 2017-02-24 14:00:23 -08:00
imx2_wdt.c watchdog: imx2_wdt: add pretimeout function support 2016-10-08 10:27:30 +02:00
indydog.c
intel-mid_wdt.c watchdog: intel-mid_wdt: Convert to use device managed functions 2017-02-24 14:00:23 -08:00
intel_scu_watchdog.c
intel_scu_watchdog.h
iop_wdt.c
it87_wdt.c watchdog: it87_wdt: add IT8620E ID 2016-12-16 06:53:56 -08:00
it8712f_wdt.c
ixp4xx_wdt.c
jz4740_wdt.c watchdog: jz4740: Fix modular build 2016-12-16 06:53:54 -08:00
kempld_wdt.c watchdog: kempld: fix gcc-4.3 build 2017-03-01 06:15:10 -08:00
ks8695_wdt.c
lantiq_wdt.c watchdog: update my email address 2017-02-24 14:00:23 -08:00
loongson1_wdt.c watchdog: loongson1: Add Loongson1 SoC watchdog driver 2016-12-16 06:53:55 -08:00
lpc18xx_wdt.c watchdog: constify watchdog_info structures 2017-02-24 14:00:23 -08:00
m54xx_wdt.c
machzwd.c
max63xx_wdt.c
max77620_wdt.c watchdog: max77620_wdt: fix module autoload 2016-12-16 06:53:53 -08:00
mei_wdt.c Watchdog updates for v4.10 2016-12-24 11:27:45 -08:00
mena21_wdt.c watchdog: mena21_wdt: Convert to use device managed functions and other improvements 2017-02-24 14:00:23 -08:00
menf21bmc_wdt.c
meson_gxbb_wdt.c watchdog: meson: Remove unneeded platform MODULE_ALIAS 2016-12-16 06:53:53 -08:00
meson_wdt.c watchdog: meson_wdt: Convert to use device managed functions and other improvements 2017-02-24 14:00:23 -08:00
mixcomwd.c
moxart_wdt.c
mpc8xxx_wdt.c watchdog: mpc8xxx: Remove unneeded linux/miscdevice.h include 2016-12-16 06:53:55 -08:00
mt7621_wdt.c watchdog: constify watchdog_ops structures 2017-02-24 14:00:23 -08:00
mtk_wdt.c
mtx-1_wdt.c
mv64x60_wdt.c
ni903x_wdt.c
nic7018_wdt.c watchdog: nic7018_wdt: Add NIC7018 watchdog driver 2017-02-24 14:00:23 -08:00
nuc900_wdt.c
nv_tco.c
nv_tco.h
octeon-wdt-main.c Watchdog updates for v4.10 2016-12-24 11:27:45 -08:00
octeon-wdt-nmi.S
of_xilinx_wdt.c
omap_wdt.c
omap_wdt.h
orion_wdt.c watchdog: orion: fix spelling mistake: "harcoded" -> "hardcoded" 2017-02-24 14:00:23 -08:00
pc87413_wdt.c Annotate hardware config module parameters in drivers/watchdog/ 2017-04-20 12:02:32 +01:00
pcwd.c
pcwd_pci.c
pcwd_usb.c
pic32-dmt.c
pic32-wdt.c
pika_wdt.c watchdog: pika_wdt: add __ro_after_init to ident 2017-02-24 14:00:23 -08:00
pnx833x_wdt.c
pnx4008_wdt.c
pretimeout_noop.c watchdog: pretimeout: add noop pretimeout governor 2016-10-08 10:27:13 +02:00
pretimeout_panic.c watchdog: pretimeout: add panic pretimeout governor 2016-10-08 10:27:17 +02:00
qcom-wdt.c watchdog: qcom: fix kernel panic due to external abort on non-linefetch 2016-12-16 06:53:54 -08:00
rc32434_wdt.c
rdc321x_wdt.c
renesas_wdt.c
retu_wdt.c
riowd.c
rn5t618_wdt.c watchdog: constify watchdog_info structures 2017-02-24 14:00:23 -08:00
rt2880_wdt.c watchdog: constify watchdog_ops structures 2017-02-24 14:00:23 -08:00
s3c2410_wdt.c watchdog: s3c2410: Add prefix to local function 2017-02-24 14:00:23 -08:00
sa1100_wdt.c watchdog: sa11x0/pxa: fix error path of driver initialization 2017-02-24 14:00:23 -08:00
sama5d4_wdt.c watchdog: sama5d4: Implement resume hook 2017-02-24 14:00:23 -08:00
sb_wdog.c
sbc60xxwdt.c
sbc7240_wdt.c
sbc8360.c
sbc_epx_c3.c
sbc_fitpc2_wdt.c
sbsa_gwdt.c watchdog: constify watchdog_ops structures 2017-02-24 14:00:23 -08:00
sc520_wdt.c
sc1200wdt.c Annotate hardware config module parameters in drivers/watchdog/ 2017-04-20 12:02:32 +01:00
sch311x_wdt.c
scx200_wdt.c
shwdt.c
sirfsoc_wdt.c watchdog: constify watchdog_ops structures 2017-02-24 14:00:23 -08:00
smsc37b787_wdt.c
softdog.c watchdog: softdog: fire watchdog even if softirqs do not get to run 2017-03-01 06:15:10 -08:00
sp805_wdt.c
sp5100_tco.c
sp5100_tco.h
st_lpc_wdt.c
stmp3xxx_rtc_wdt.c
sun4v_wdt.c watchdog: constify watchdog_ops structures 2017-02-24 14:00:23 -08:00
sunxi_wdt.c watchdog: sunxi_wdt: Convert to use device managed functions and other improvements 2017-02-24 14:00:23 -08:00
tangox_wdt.c watchdog: tangox: Use watchdog core to install restart handler 2017-02-24 14:00:23 -08:00
tegra_wdt.c watchdog: tegra_wdt: Convert to use device managed functions 2017-02-24 14:00:23 -08:00
ts72xx_wdt.c watchdog: ts72xx_wdt: convert driver to watchdog core 2017-02-24 14:00:23 -08:00
ts4800_wdt.c
twl4030_wdt.c
txx9wdt.c
ux500_wdt.c
via_wdt.c
w83627hf_wdt.c watchdog: constify watchdog_info structures 2017-02-24 14:00:23 -08:00
w83877f_wdt.c
w83977f_wdt.c
wafer5823wdt.c
watchdog_core.c
watchdog_core.h
watchdog_dev.c watchdog: Introduce watchdog_stop_on_unregister helper 2017-02-24 14:00:23 -08:00
watchdog_pretimeout.c watchdog: pretimeout: add pretimeout_available_governors attribute 2016-10-08 10:27:24 +02:00
watchdog_pretimeout.h watchdog: pretimeout: add pretimeout_available_governors attribute 2016-10-08 10:27:24 +02:00
wd501p.h
wdat_wdt.c watchdog: wdat_wdt: Ping the watchdog on resume 2016-10-21 01:28:33 +02:00
wdrtas.c
wdt.c Annotate hardware config module parameters in drivers/watchdog/ 2017-04-20 12:02:32 +01:00
wdt285.c
wdt977.c
wdt_pci.c
wm831x_wdt.c watchdog: wm831x_wdt: Convert to use device managed functions 2017-02-24 14:00:23 -08:00
wm8350_wdt.c
xen_wdt.c
ziirave_wdt.c
zx2967_wdt.c watchdog: zx2967: add watchdog controller driver for ZTE's zx2967 family 2017-02-24 14:00:23 -08:00