aboutsummaryrefslogtreecommitdiff
path: root/drivers/misc/pvpanic.c
AgeCommit message (Collapse)AuthorFilesLines
2019-01-18misc: pvpanic: fix warning implicit declarationAnders Roxell1-0/+4
When building and have fragment CONFIG_NO_IOPORT_MAP enabled then the following warning: ../drivers/misc/pvpanic.c: In function ‘pvpanic_walk_resources’: ../drivers/misc/pvpanic.c:73:10: error: implicit declaration of function ‘ioport_map’; did you mean ‘ioremap’? [-Werror=implicit-function-declaration] base = ioport_map(r.start, resource_size(&r)); ^~~~~~~~~~ Since commmit 5d32a66541c4 ("PCI/ACPI: Allow ACPI to be built without CONFIG_PCI set"), its now possible to have ACPI enabled without haveing PCI enabled. However, the pvpanic driver depends on HAS_IOPORT_MAP or HAVE_IOREMAP_PROT when ACPI is enabled. It was fine until commit 725eba2928ad ("misc/pvpanic: add MMIO support") got added. Rework so that we do a extra check ifdef CONFIG_HAS_IOPORT_MAP. Fixes: 5d32a66541c4 ("PCI/ACPI: Allow ACPI to be built without CONFIG_PCI set") Suggested-by: Arnd Bergmann <[email protected]> Signed-off-by: Anders Roxell <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
2018-11-27misc/pvpanic: fix a NULL vs IS_ERR() checkDan Carpenter1-2/+2
The devm_ioremap_resource() function doesn't return NULL, it returns error pointers. Fixes: 46f934c9a12f ("misc/pvpanic: add support to get pvpanic device info FDT") Signed-off-by: Dan Carpenter <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
2018-11-07misc/pvpanic: remove a redundant commaPeng Hao1-1/+1
Remove a redundant comma in pvpanic_device_ids. Reviewed-by: Andy Shevchenko <[email protected]> Acked-by: Mark Rutland <[email protected]> Signed-off-by: Peng Hao <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
2018-11-07misc/pvpanic: convert to SPDX license tagsPeng Hao1-15/+2
Updates license to use SPDX-License-Identifier instead of verbose license text. Reviewed-by: Andy Shevchenko <[email protected]> Acked-by: Mark Rutland <[email protected]> Signed-off-by: Peng Hao <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
2018-11-07misc/pvpanic: change header file sort stylePeng Hao1-1/+1
Make header files alphabetical order. Signed-off-by: Peng Hao <[email protected]> Reviewed-by: Andy Shevchenko <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
2018-11-07misc/pvpanic: remove unnecessary header filePeng Hao1-1/+0
Remove unnecessary header file init.h. Reviewed-by: Andy Shevchenko <[email protected]> Acked-by: Mark Rutland <[email protected]> Signed-off-by: Peng Hao <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
2018-11-07misc/pvpanic : break dependency on ACPIPeng Hao1-2/+21
The pvpanic driver is available for architectures that do not support ACPI.So break the dependency. Reviewed-by: Andy Shevchenko <[email protected]> Signed-off-by: Peng Hao <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
2018-11-07misc/pvpanic : grouping ACPI related stuffPeng Hao1-22/+21
Grouping ACPI related stuff and make preparation to break the ACPI dependency w/o any functional change. Reviewed-by: Andy Shevchenko <[email protected]> Signed-off-by: Peng Hao <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
2018-11-07misc/pvpanic: add support to get pvpanic device info FDTPeng Hao1-1/+63
By default, when ACPI tables and FDT coexist for ARM64, current kernel takes precedence over FDT to get device information. Virt machine in qemu provides both FDT and ACPI table. Increases the way to get information through FDT. Acked-by: Mark Rutland <[email protected]> Signed-off-by: Peng Hao <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
2018-11-07misc/pvpanic: add MMIO supportPeng Hao1-5/+10
On some architectures (e.g. arm64), it's preferable to use MMIO, since this can be used standalone. Add MMIO support to the pvpanic driver. Suggested-by: Andy Shevchenko <[email protected]> [Use acpi_dev_resource_memory API. - Andy] Reviewed-by: Andy Shevchenko <[email protected]> Acked-by: Mark Rutland <[email protected]> Signed-off-by: Peng Hao <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
2018-11-07misc/pvpanic: simplify the code using acpi_dev_resource_ioPeng Hao1-8/+5
Use acpi_dev_resource_io API. Suggested-by: Andy Shevchenko <[email protected]> Reviewed-by: Andy Shevchenko <[email protected]> Acked-by: Mark Rutland <[email protected]> Signed-off-by: Peng Hao <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
2018-11-07pvpanic: move pvpanic to misc as common driverPeng Hao1-0/+124
Move pvpanic.c from drivers/platform/x86 to drivers/misc. Following patches will use pvpanic device in arm64. Reviewed-by: Andy Shevchenko <[email protected]> Acked-by: Mark Rutland <[email protected]> Signed-off-by: Peng Hao <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>