diff options
| author | Linus Torvalds <torvalds@linux-foundation.org> | 2019-09-02 12:30:34 -0400 |
|---|---|---|
| committer | Linus Torvalds <torvalds@linux-foundation.org> | 2019-09-02 12:30:34 -0400 |
| commit | 49ffdb4c7c65082cee24a53a7ebd62e00eb2e9e9 (patch) | |
| tree | 6b029d762e206d5dead319b560687caaa040e9a1 /drivers | |
| parent | 2c248f92fa4fae3036e656da2f9a077020a99f6e (diff) | |
| parent | 8919dfcb31161fae7d607bbef5247e5e82fd6457 (diff) | |
Merge tag 'char-misc-5.3-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/char-misc
Pull char/misc driver fixes from Greg KH:
"Here are some small char and misc driver fixes for reported issues for
5.3-rc7
Also included in here is the documentation for how we are handling
hardware issues under embargo that everyone has finally agreed on, as
well as a MAINTAINERS update for the suckers who agreed to handle the
LICENSES/ files.
All of these have been in linux-next last week with no reported
issues"
* tag 'char-misc-5.3-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/char-misc:
fsi: scom: Don't abort operations for minor errors
vmw_balloon: Fix offline page marking with compaction
VMCI: Release resource if the work is already queued
Documentation/process: Embargoed hardware security issues
lkdtm/bugs: fix build error in lkdtm_EXHAUST_STACK
mei: me: add Tiger Lake point LP device ID
intel_th: pci: Add Tiger Lake support
intel_th: pci: Add support for another Lewisburg PCH
stm class: Fix a double free of stm_source_device
MAINTAINERS: add entry for LICENSES and SPDX stuff
fpga: altera-ps-spi: Fix getting of optional confd gpio
Diffstat (limited to 'drivers')
| -rw-r--r-- | drivers/fpga/altera-ps-spi.c | 11 | ||||
| -rw-r--r-- | drivers/fsi/fsi-scom.c | 8 | ||||
| -rw-r--r-- | drivers/hwtracing/intel_th/pci.c | 10 | ||||
| -rw-r--r-- | drivers/hwtracing/stm/core.c | 1 | ||||
| -rw-r--r-- | drivers/misc/lkdtm/bugs.c | 4 | ||||
| -rw-r--r-- | drivers/misc/mei/hw-me-regs.h | 2 | ||||
| -rw-r--r-- | drivers/misc/mei/pci-me.c | 2 | ||||
| -rw-r--r-- | drivers/misc/vmw_balloon.c | 10 | ||||
| -rw-r--r-- | drivers/misc/vmw_vmci/vmci_doorbell.c | 6 |
9 files changed, 36 insertions, 18 deletions
diff --git a/drivers/fpga/altera-ps-spi.c b/drivers/fpga/altera-ps-spi.c index a13f224303c6..0221dee8dd4c 100644 --- a/drivers/fpga/altera-ps-spi.c +++ b/drivers/fpga/altera-ps-spi.c | |||
| @@ -210,7 +210,7 @@ static int altera_ps_write_complete(struct fpga_manager *mgr, | |||
| 210 | return -EIO; | 210 | return -EIO; |
| 211 | } | 211 | } |
| 212 | 212 | ||
| 213 | if (!IS_ERR(conf->confd)) { | 213 | if (conf->confd) { |
| 214 | if (!gpiod_get_raw_value_cansleep(conf->confd)) { | 214 | if (!gpiod_get_raw_value_cansleep(conf->confd)) { |
| 215 | dev_err(&mgr->dev, "CONF_DONE is inactive!\n"); | 215 | dev_err(&mgr->dev, "CONF_DONE is inactive!\n"); |
| 216 | return -EIO; | 216 | return -EIO; |
| @@ -289,10 +289,13 @@ static int altera_ps_probe(struct spi_device *spi) | |||
| 289 | return PTR_ERR(conf->status); | 289 | return PTR_ERR(conf->status); |
| 290 | } | 290 | } |
| 291 | 291 | ||
| 292 | conf->confd = devm_gpiod_get(&spi->dev, "confd", GPIOD_IN); | 292 | conf->confd = devm_gpiod_get_optional(&spi->dev, "confd", GPIOD_IN); |
| 293 | if (IS_ERR(conf->confd)) { | 293 | if (IS_ERR(conf->confd)) { |
| 294 | dev_warn(&spi->dev, "Not using confd gpio: %ld\n", | 294 | dev_err(&spi->dev, "Failed to get confd gpio: %ld\n", |
| 295 | PTR_ERR(conf->confd)); | 295 | PTR_ERR(conf->confd)); |
| 296 | return PTR_ERR(conf->confd); | ||
| 297 | } else if (!conf->confd) { | ||
| 298 | dev_warn(&spi->dev, "Not using confd gpio"); | ||
| 296 | } | 299 | } |
| 297 | 300 | ||
| 298 | /* Register manager with unique name */ | 301 | /* Register manager with unique name */ |
diff --git a/drivers/fsi/fsi-scom.c b/drivers/fsi/fsi-scom.c index 343153d47e5b..004dc03ccf09 100644 --- a/drivers/fsi/fsi-scom.c +++ b/drivers/fsi/fsi-scom.c | |||
| @@ -38,8 +38,7 @@ | |||
| 38 | #define SCOM_STATUS_PIB_RESP_MASK 0x00007000 | 38 | #define SCOM_STATUS_PIB_RESP_MASK 0x00007000 |
| 39 | #define SCOM_STATUS_PIB_RESP_SHIFT 12 | 39 | #define SCOM_STATUS_PIB_RESP_SHIFT 12 |
| 40 | 40 | ||
| 41 | #define SCOM_STATUS_ANY_ERR (SCOM_STATUS_ERR_SUMMARY | \ | 41 | #define SCOM_STATUS_ANY_ERR (SCOM_STATUS_PROTECTION | \ |
| 42 | SCOM_STATUS_PROTECTION | \ | ||
| 43 | SCOM_STATUS_PARITY | \ | 42 | SCOM_STATUS_PARITY | \ |
| 44 | SCOM_STATUS_PIB_ABORT | \ | 43 | SCOM_STATUS_PIB_ABORT | \ |
| 45 | SCOM_STATUS_PIB_RESP_MASK) | 44 | SCOM_STATUS_PIB_RESP_MASK) |
| @@ -251,11 +250,6 @@ static int handle_fsi2pib_status(struct scom_device *scom, uint32_t status) | |||
| 251 | /* Return -EBUSY on PIB abort to force a retry */ | 250 | /* Return -EBUSY on PIB abort to force a retry */ |
| 252 | if (status & SCOM_STATUS_PIB_ABORT) | 251 | if (status & SCOM_STATUS_PIB_ABORT) |
| 253 | return -EBUSY; | 252 | return -EBUSY; |
| 254 | if (status & SCOM_STATUS_ERR_SUMMARY) { | ||
| 255 | fsi_device_write(scom->fsi_dev, SCOM_FSI2PIB_RESET_REG, &dummy, | ||
| 256 | sizeof(uint32_t)); | ||
| 257 | return -EIO; | ||
| 258 | } | ||
| 259 | return 0; | 253 | return 0; |
| 260 | } | 254 | } |
| 261 | 255 | ||
diff --git a/drivers/hwtracing/intel_th/pci.c b/drivers/hwtracing/intel_th/pci.c index c0378c3de9a4..91dfeba62485 100644 --- a/drivers/hwtracing/intel_th/pci.c +++ b/drivers/hwtracing/intel_th/pci.c | |||
| @@ -165,6 +165,11 @@ static const struct pci_device_id intel_th_pci_id_table[] = { | |||
| 165 | .driver_data = (kernel_ulong_t)0, | 165 | .driver_data = (kernel_ulong_t)0, |
| 166 | }, | 166 | }, |
| 167 | { | 167 | { |
| 168 | /* Lewisburg PCH */ | ||
| 169 | PCI_DEVICE(PCI_VENDOR_ID_INTEL, 0xa226), | ||
| 170 | .driver_data = (kernel_ulong_t)0, | ||
| 171 | }, | ||
| 172 | { | ||
| 168 | /* Gemini Lake */ | 173 | /* Gemini Lake */ |
| 169 | PCI_DEVICE(PCI_VENDOR_ID_INTEL, 0x318e), | 174 | PCI_DEVICE(PCI_VENDOR_ID_INTEL, 0x318e), |
| 170 | .driver_data = (kernel_ulong_t)&intel_th_2x, | 175 | .driver_data = (kernel_ulong_t)&intel_th_2x, |
| @@ -199,6 +204,11 @@ static const struct pci_device_id intel_th_pci_id_table[] = { | |||
| 199 | PCI_DEVICE(PCI_VENDOR_ID_INTEL, 0x45c5), | 204 | PCI_DEVICE(PCI_VENDOR_ID_INTEL, 0x45c5), |
| 200 | .driver_data = (kernel_ulong_t)&intel_th_2x, | 205 | .driver_data = (kernel_ulong_t)&intel_th_2x, |
| 201 | }, | 206 | }, |
| 207 | { | ||
| 208 | /* Tiger Lake PCH */ | ||
| 209 | PCI_DEVICE(PCI_VENDOR_ID_INTEL, 0xa0a6), | ||
| 210 | .driver_data = (kernel_ulong_t)&intel_th_2x, | ||
| 211 | }, | ||
| 202 | { 0 }, | 212 | { 0 }, |
| 203 | }; | 213 | }; |
| 204 | 214 | ||
diff --git a/drivers/hwtracing/stm/core.c b/drivers/hwtracing/stm/core.c index e55b902560de..181e7ff1ec4f 100644 --- a/drivers/hwtracing/stm/core.c +++ b/drivers/hwtracing/stm/core.c | |||
| @@ -1276,7 +1276,6 @@ int stm_source_register_device(struct device *parent, | |||
| 1276 | 1276 | ||
| 1277 | err: | 1277 | err: |
| 1278 | put_device(&src->dev); | 1278 | put_device(&src->dev); |
| 1279 | kfree(src); | ||
| 1280 | 1279 | ||
| 1281 | return err; | 1280 | return err; |
| 1282 | } | 1281 | } |
diff --git a/drivers/misc/lkdtm/bugs.c b/drivers/misc/lkdtm/bugs.c index 1606658b9b7e..24245ccdba72 100644 --- a/drivers/misc/lkdtm/bugs.c +++ b/drivers/misc/lkdtm/bugs.c | |||
| @@ -22,7 +22,7 @@ struct lkdtm_list { | |||
| 22 | * recurse past the end of THREAD_SIZE by default. | 22 | * recurse past the end of THREAD_SIZE by default. |
| 23 | */ | 23 | */ |
| 24 | #if defined(CONFIG_FRAME_WARN) && (CONFIG_FRAME_WARN > 0) | 24 | #if defined(CONFIG_FRAME_WARN) && (CONFIG_FRAME_WARN > 0) |
| 25 | #define REC_STACK_SIZE (CONFIG_FRAME_WARN / 2) | 25 | #define REC_STACK_SIZE (_AC(CONFIG_FRAME_WARN, UL) / 2) |
| 26 | #else | 26 | #else |
| 27 | #define REC_STACK_SIZE (THREAD_SIZE / 8) | 27 | #define REC_STACK_SIZE (THREAD_SIZE / 8) |
| 28 | #endif | 28 | #endif |
| @@ -91,7 +91,7 @@ void lkdtm_LOOP(void) | |||
| 91 | 91 | ||
| 92 | void lkdtm_EXHAUST_STACK(void) | 92 | void lkdtm_EXHAUST_STACK(void) |
| 93 | { | 93 | { |
| 94 | pr_info("Calling function with %d frame size to depth %d ...\n", | 94 | pr_info("Calling function with %lu frame size to depth %d ...\n", |
| 95 | REC_STACK_SIZE, recur_count); | 95 | REC_STACK_SIZE, recur_count); |
| 96 | recursive_loop(recur_count); | 96 | recursive_loop(recur_count); |
| 97 | pr_info("FAIL: survived without exhausting stack?!\n"); | 97 | pr_info("FAIL: survived without exhausting stack?!\n"); |
diff --git a/drivers/misc/mei/hw-me-regs.h b/drivers/misc/mei/hw-me-regs.h index 6c0173772162..77f7dff7098d 100644 --- a/drivers/misc/mei/hw-me-regs.h +++ b/drivers/misc/mei/hw-me-regs.h | |||
| @@ -81,6 +81,8 @@ | |||
| 81 | 81 | ||
| 82 | #define MEI_DEV_ID_ICP_LP 0x34E0 /* Ice Lake Point LP */ | 82 | #define MEI_DEV_ID_ICP_LP 0x34E0 /* Ice Lake Point LP */ |
| 83 | 83 | ||
| 84 | #define MEI_DEV_ID_TGP_LP 0xA0E0 /* Tiger Lake Point LP */ | ||
| 85 | |||
| 84 | #define MEI_DEV_ID_MCC 0x4B70 /* Mule Creek Canyon (EHL) */ | 86 | #define MEI_DEV_ID_MCC 0x4B70 /* Mule Creek Canyon (EHL) */ |
| 85 | #define MEI_DEV_ID_MCC_4 0x4B75 /* Mule Creek Canyon 4 (EHL) */ | 87 | #define MEI_DEV_ID_MCC_4 0x4B75 /* Mule Creek Canyon 4 (EHL) */ |
| 86 | 88 | ||
diff --git a/drivers/misc/mei/pci-me.c b/drivers/misc/mei/pci-me.c index 57cb68f5cc64..541538eff8b1 100644 --- a/drivers/misc/mei/pci-me.c +++ b/drivers/misc/mei/pci-me.c | |||
| @@ -98,6 +98,8 @@ static const struct pci_device_id mei_me_pci_tbl[] = { | |||
| 98 | 98 | ||
| 99 | {MEI_PCI_DEVICE(MEI_DEV_ID_ICP_LP, MEI_ME_PCH12_CFG)}, | 99 | {MEI_PCI_DEVICE(MEI_DEV_ID_ICP_LP, MEI_ME_PCH12_CFG)}, |
| 100 | 100 | ||
| 101 | {MEI_PCI_DEVICE(MEI_DEV_ID_TGP_LP, MEI_ME_PCH12_CFG)}, | ||
| 102 | |||
| 101 | {MEI_PCI_DEVICE(MEI_DEV_ID_MCC, MEI_ME_PCH12_CFG)}, | 103 | {MEI_PCI_DEVICE(MEI_DEV_ID_MCC, MEI_ME_PCH12_CFG)}, |
| 102 | {MEI_PCI_DEVICE(MEI_DEV_ID_MCC_4, MEI_ME_PCH8_CFG)}, | 104 | {MEI_PCI_DEVICE(MEI_DEV_ID_MCC_4, MEI_ME_PCH8_CFG)}, |
| 103 | 105 | ||
diff --git a/drivers/misc/vmw_balloon.c b/drivers/misc/vmw_balloon.c index 8840299420e0..5e6be1527571 100644 --- a/drivers/misc/vmw_balloon.c +++ b/drivers/misc/vmw_balloon.c | |||
| @@ -691,7 +691,6 @@ static int vmballoon_alloc_page_list(struct vmballoon *b, | |||
| 691 | } | 691 | } |
| 692 | 692 | ||
| 693 | if (page) { | 693 | if (page) { |
| 694 | vmballoon_mark_page_offline(page, ctl->page_size); | ||
| 695 | /* Success. Add the page to the list and continue. */ | 694 | /* Success. Add the page to the list and continue. */ |
| 696 | list_add(&page->lru, &ctl->pages); | 695 | list_add(&page->lru, &ctl->pages); |
| 697 | continue; | 696 | continue; |
| @@ -930,7 +929,6 @@ static void vmballoon_release_page_list(struct list_head *page_list, | |||
| 930 | 929 | ||
| 931 | list_for_each_entry_safe(page, tmp, page_list, lru) { | 930 | list_for_each_entry_safe(page, tmp, page_list, lru) { |
| 932 | list_del(&page->lru); | 931 | list_del(&page->lru); |
| 933 | vmballoon_mark_page_online(page, page_size); | ||
| 934 | __free_pages(page, vmballoon_page_order(page_size)); | 932 | __free_pages(page, vmballoon_page_order(page_size)); |
| 935 | } | 933 | } |
| 936 | 934 | ||
| @@ -1005,6 +1003,7 @@ static void vmballoon_enqueue_page_list(struct vmballoon *b, | |||
| 1005 | enum vmballoon_page_size_type page_size) | 1003 | enum vmballoon_page_size_type page_size) |
| 1006 | { | 1004 | { |
| 1007 | unsigned long flags; | 1005 | unsigned long flags; |
| 1006 | struct page *page; | ||
| 1008 | 1007 | ||
| 1009 | if (page_size == VMW_BALLOON_4K_PAGE) { | 1008 | if (page_size == VMW_BALLOON_4K_PAGE) { |
| 1010 | balloon_page_list_enqueue(&b->b_dev_info, pages); | 1009 | balloon_page_list_enqueue(&b->b_dev_info, pages); |
| @@ -1014,6 +1013,11 @@ static void vmballoon_enqueue_page_list(struct vmballoon *b, | |||
| 1014 | * for the balloon compaction mechanism. | 1013 | * for the balloon compaction mechanism. |
| 1015 | */ | 1014 | */ |
| 1016 | spin_lock_irqsave(&b->b_dev_info.pages_lock, flags); | 1015 | spin_lock_irqsave(&b->b_dev_info.pages_lock, flags); |
| 1016 | |||
| 1017 | list_for_each_entry(page, pages, lru) { | ||
| 1018 | vmballoon_mark_page_offline(page, VMW_BALLOON_2M_PAGE); | ||
| 1019 | } | ||
| 1020 | |||
| 1017 | list_splice_init(pages, &b->huge_pages); | 1021 | list_splice_init(pages, &b->huge_pages); |
| 1018 | __count_vm_events(BALLOON_INFLATE, *n_pages * | 1022 | __count_vm_events(BALLOON_INFLATE, *n_pages * |
| 1019 | vmballoon_page_in_frames(VMW_BALLOON_2M_PAGE)); | 1023 | vmballoon_page_in_frames(VMW_BALLOON_2M_PAGE)); |
| @@ -1056,6 +1060,8 @@ static void vmballoon_dequeue_page_list(struct vmballoon *b, | |||
| 1056 | /* 2MB pages */ | 1060 | /* 2MB pages */ |
| 1057 | spin_lock_irqsave(&b->b_dev_info.pages_lock, flags); | 1061 | spin_lock_irqsave(&b->b_dev_info.pages_lock, flags); |
| 1058 | list_for_each_entry_safe(page, tmp, &b->huge_pages, lru) { | 1062 | list_for_each_entry_safe(page, tmp, &b->huge_pages, lru) { |
| 1063 | vmballoon_mark_page_online(page, VMW_BALLOON_2M_PAGE); | ||
| 1064 | |||
| 1059 | list_move(&page->lru, pages); | 1065 | list_move(&page->lru, pages); |
| 1060 | if (++i == n_req_pages) | 1066 | if (++i == n_req_pages) |
| 1061 | break; | 1067 | break; |
diff --git a/drivers/misc/vmw_vmci/vmci_doorbell.c b/drivers/misc/vmw_vmci/vmci_doorbell.c index bad89b6e0802..345addd9306d 100644 --- a/drivers/misc/vmw_vmci/vmci_doorbell.c +++ b/drivers/misc/vmw_vmci/vmci_doorbell.c | |||
| @@ -310,7 +310,8 @@ int vmci_dbell_host_context_notify(u32 src_cid, struct vmci_handle handle) | |||
| 310 | 310 | ||
| 311 | entry = container_of(resource, struct dbell_entry, resource); | 311 | entry = container_of(resource, struct dbell_entry, resource); |
| 312 | if (entry->run_delayed) { | 312 | if (entry->run_delayed) { |
| 313 | schedule_work(&entry->work); | 313 | if (!schedule_work(&entry->work)) |
| 314 | vmci_resource_put(resource); | ||
| 314 | } else { | 315 | } else { |
| 315 | entry->notify_cb(entry->client_data); | 316 | entry->notify_cb(entry->client_data); |
| 316 | vmci_resource_put(resource); | 317 | vmci_resource_put(resource); |
| @@ -361,7 +362,8 @@ static void dbell_fire_entries(u32 notify_idx) | |||
| 361 | atomic_read(&dbell->active) == 1) { | 362 | atomic_read(&dbell->active) == 1) { |
| 362 | if (dbell->run_delayed) { | 363 | if (dbell->run_delayed) { |
| 363 | vmci_resource_get(&dbell->resource); | 364 | vmci_resource_get(&dbell->resource); |
| 364 | schedule_work(&dbell->work); | 365 | if (!schedule_work(&dbell->work)) |
| 366 | vmci_resource_put(&dbell->resource); | ||
| 365 | } else { | 367 | } else { |
| 366 | dbell->notify_cb(dbell->client_data); | 368 | dbell->notify_cb(dbell->client_data); |
| 367 | } | 369 | } |
