diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2013-07-26 14:36:12 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2013-07-26 14:36:12 -0400 |
commit | 05e4cb7c25c1ac35a6a61c79ad40cf69dd3538bf (patch) | |
tree | 5afe08194536045b97c16edf768e50805acf70fd /drivers | |
parent | 8f074a557104aed6f7b0a0913227039481da3449 (diff) | |
parent | 9b0ee8cf70457520c144e944bcf8df2324bad880 (diff) |
Merge tag 'char-misc-3.11-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/char-misc
Pull char/misc patches from Greg KH:
"Here are some char/misc patches for 3.11-rc3. It's pretty much just:
- mei fixes
- hyperv fixes
- new ja_JP translation update
all tiny stuff, but fixes for issues people have reported."
* tag 'char-misc-3.11-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/char-misc:
HOWTO ja_JP sync
mei: me: fix waiting for hw ready
mei: don't have to clean the state on power up
mei: me: fix reset state machine
mei: hbm: fix typo in error message
Tools: hv: KVP: Fix a bug in IPV6 subnet enumeration
Drivers: hv: balloon: Do not post pressure status if interrupted
Drivers: hv: balloon: Fix a bug in the hot-add code
Drivers: hv: vmbus: incorrect device name is printed when child device is unregistered
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/hv/hv_balloon.c | 21 | ||||
-rw-r--r-- | drivers/hv/vmbus_drv.c | 8 | ||||
-rw-r--r-- | drivers/misc/mei/hbm.c | 2 | ||||
-rw-r--r-- | drivers/misc/mei/hw-me.c | 14 | ||||
-rw-r--r-- | drivers/misc/mei/init.c | 3 |
5 files changed, 30 insertions, 18 deletions
diff --git a/drivers/hv/hv_balloon.c b/drivers/hv/hv_balloon.c index 4c605c70ebf9..deb5c25305af 100644 --- a/drivers/hv/hv_balloon.c +++ b/drivers/hv/hv_balloon.c | |||
@@ -562,7 +562,7 @@ static void hv_mem_hot_add(unsigned long start, unsigned long size, | |||
562 | struct hv_hotadd_state *has) | 562 | struct hv_hotadd_state *has) |
563 | { | 563 | { |
564 | int ret = 0; | 564 | int ret = 0; |
565 | int i, nid, t; | 565 | int i, nid; |
566 | unsigned long start_pfn; | 566 | unsigned long start_pfn; |
567 | unsigned long processed_pfn; | 567 | unsigned long processed_pfn; |
568 | unsigned long total_pfn = pfn_count; | 568 | unsigned long total_pfn = pfn_count; |
@@ -607,14 +607,11 @@ static void hv_mem_hot_add(unsigned long start, unsigned long size, | |||
607 | 607 | ||
608 | /* | 608 | /* |
609 | * Wait for the memory block to be onlined. | 609 | * Wait for the memory block to be onlined. |
610 | * Since the hot add has succeeded, it is ok to | ||
611 | * proceed even if the pages in the hot added region | ||
612 | * have not been "onlined" within the allowed time. | ||
610 | */ | 613 | */ |
611 | t = wait_for_completion_timeout(&dm_device.ol_waitevent, 5*HZ); | 614 | wait_for_completion_timeout(&dm_device.ol_waitevent, 5*HZ); |
612 | if (t == 0) { | ||
613 | pr_info("hot_add memory timedout\n"); | ||
614 | has->ha_end_pfn -= HA_CHUNK; | ||
615 | has->covered_end_pfn -= processed_pfn; | ||
616 | break; | ||
617 | } | ||
618 | 615 | ||
619 | } | 616 | } |
620 | 617 | ||
@@ -978,6 +975,14 @@ static void post_status(struct hv_dynmem_device *dm) | |||
978 | dm->num_pages_ballooned + | 975 | dm->num_pages_ballooned + |
979 | compute_balloon_floor(); | 976 | compute_balloon_floor(); |
980 | 977 | ||
978 | /* | ||
979 | * If our transaction ID is no longer current, just don't | ||
980 | * send the status. This can happen if we were interrupted | ||
981 | * after we picked our transaction ID. | ||
982 | */ | ||
983 | if (status.hdr.trans_id != atomic_read(&trans_id)) | ||
984 | return; | ||
985 | |||
981 | vmbus_sendpacket(dm->dev->channel, &status, | 986 | vmbus_sendpacket(dm->dev->channel, &status, |
982 | sizeof(struct dm_status), | 987 | sizeof(struct dm_status), |
983 | (unsigned long)NULL, | 988 | (unsigned long)NULL, |
diff --git a/drivers/hv/vmbus_drv.c b/drivers/hv/vmbus_drv.c index a2464bf07c49..e8e071fc1d6d 100644 --- a/drivers/hv/vmbus_drv.c +++ b/drivers/hv/vmbus_drv.c | |||
@@ -690,7 +690,7 @@ int vmbus_device_register(struct hv_device *child_device_obj) | |||
690 | if (ret) | 690 | if (ret) |
691 | pr_err("Unable to register child device\n"); | 691 | pr_err("Unable to register child device\n"); |
692 | else | 692 | else |
693 | pr_info("child device %s registered\n", | 693 | pr_debug("child device %s registered\n", |
694 | dev_name(&child_device_obj->device)); | 694 | dev_name(&child_device_obj->device)); |
695 | 695 | ||
696 | return ret; | 696 | return ret; |
@@ -702,14 +702,14 @@ int vmbus_device_register(struct hv_device *child_device_obj) | |||
702 | */ | 702 | */ |
703 | void vmbus_device_unregister(struct hv_device *device_obj) | 703 | void vmbus_device_unregister(struct hv_device *device_obj) |
704 | { | 704 | { |
705 | pr_debug("child device %s unregistered\n", | ||
706 | dev_name(&device_obj->device)); | ||
707 | |||
705 | /* | 708 | /* |
706 | * Kick off the process of unregistering the device. | 709 | * Kick off the process of unregistering the device. |
707 | * This will call vmbus_remove() and eventually vmbus_device_release() | 710 | * This will call vmbus_remove() and eventually vmbus_device_release() |
708 | */ | 711 | */ |
709 | device_unregister(&device_obj->device); | 712 | device_unregister(&device_obj->device); |
710 | |||
711 | pr_info("child device %s unregistered\n", | ||
712 | dev_name(&device_obj->device)); | ||
713 | } | 713 | } |
714 | 714 | ||
715 | 715 | ||
diff --git a/drivers/misc/mei/hbm.c b/drivers/misc/mei/hbm.c index f9296abcf02a..6127ab64bb39 100644 --- a/drivers/misc/mei/hbm.c +++ b/drivers/misc/mei/hbm.c | |||
@@ -167,7 +167,7 @@ int mei_hbm_start_req(struct mei_device *dev) | |||
167 | 167 | ||
168 | dev->hbm_state = MEI_HBM_IDLE; | 168 | dev->hbm_state = MEI_HBM_IDLE; |
169 | if (mei_write_message(dev, mei_hdr, dev->wr_msg.data)) { | 169 | if (mei_write_message(dev, mei_hdr, dev->wr_msg.data)) { |
170 | dev_err(&dev->pdev->dev, "version message writet failed\n"); | 170 | dev_err(&dev->pdev->dev, "version message write failed\n"); |
171 | dev->dev_state = MEI_DEV_RESETTING; | 171 | dev->dev_state = MEI_DEV_RESETTING; |
172 | mei_reset(dev, 1); | 172 | mei_reset(dev, 1); |
173 | return -ENODEV; | 173 | return -ENODEV; |
diff --git a/drivers/misc/mei/hw-me.c b/drivers/misc/mei/hw-me.c index e4f8dec4dc3c..b22c7e247225 100644 --- a/drivers/misc/mei/hw-me.c +++ b/drivers/misc/mei/hw-me.c | |||
@@ -239,14 +239,18 @@ static int mei_me_hw_ready_wait(struct mei_device *dev) | |||
239 | if (mei_me_hw_is_ready(dev)) | 239 | if (mei_me_hw_is_ready(dev)) |
240 | return 0; | 240 | return 0; |
241 | 241 | ||
242 | dev->recvd_hw_ready = false; | ||
242 | mutex_unlock(&dev->device_lock); | 243 | mutex_unlock(&dev->device_lock); |
243 | err = wait_event_interruptible_timeout(dev->wait_hw_ready, | 244 | err = wait_event_interruptible_timeout(dev->wait_hw_ready, |
244 | dev->recvd_hw_ready, MEI_INTEROP_TIMEOUT); | 245 | dev->recvd_hw_ready, |
246 | mei_secs_to_jiffies(MEI_INTEROP_TIMEOUT)); | ||
245 | mutex_lock(&dev->device_lock); | 247 | mutex_lock(&dev->device_lock); |
246 | if (!err && !dev->recvd_hw_ready) { | 248 | if (!err && !dev->recvd_hw_ready) { |
249 | if (!err) | ||
250 | err = -ETIMEDOUT; | ||
247 | dev_err(&dev->pdev->dev, | 251 | dev_err(&dev->pdev->dev, |
248 | "wait hw ready failed. status = 0x%x\n", err); | 252 | "wait hw ready failed. status = %d\n", err); |
249 | return -ETIMEDOUT; | 253 | return err; |
250 | } | 254 | } |
251 | 255 | ||
252 | dev->recvd_hw_ready = false; | 256 | dev->recvd_hw_ready = false; |
@@ -483,7 +487,9 @@ irqreturn_t mei_me_irq_thread_handler(int irq, void *dev_id) | |||
483 | /* check if ME wants a reset */ | 487 | /* check if ME wants a reset */ |
484 | if (!mei_hw_is_ready(dev) && | 488 | if (!mei_hw_is_ready(dev) && |
485 | dev->dev_state != MEI_DEV_RESETTING && | 489 | dev->dev_state != MEI_DEV_RESETTING && |
486 | dev->dev_state != MEI_DEV_INITIALIZING) { | 490 | dev->dev_state != MEI_DEV_INITIALIZING && |
491 | dev->dev_state != MEI_DEV_POWER_DOWN && | ||
492 | dev->dev_state != MEI_DEV_POWER_UP) { | ||
487 | dev_dbg(&dev->pdev->dev, "FW not ready.\n"); | 493 | dev_dbg(&dev->pdev->dev, "FW not ready.\n"); |
488 | mei_reset(dev, 1); | 494 | mei_reset(dev, 1); |
489 | mutex_unlock(&dev->device_lock); | 495 | mutex_unlock(&dev->device_lock); |
diff --git a/drivers/misc/mei/init.c b/drivers/misc/mei/init.c index ed1d75203af6..e6f16f83ecde 100644 --- a/drivers/misc/mei/init.c +++ b/drivers/misc/mei/init.c | |||
@@ -148,7 +148,8 @@ void mei_reset(struct mei_device *dev, int interrupts_enabled) | |||
148 | 148 | ||
149 | dev->hbm_state = MEI_HBM_IDLE; | 149 | dev->hbm_state = MEI_HBM_IDLE; |
150 | 150 | ||
151 | if (dev->dev_state != MEI_DEV_INITIALIZING) { | 151 | if (dev->dev_state != MEI_DEV_INITIALIZING && |
152 | dev->dev_state != MEI_DEV_POWER_UP) { | ||
152 | if (dev->dev_state != MEI_DEV_DISABLED && | 153 | if (dev->dev_state != MEI_DEV_DISABLED && |
153 | dev->dev_state != MEI_DEV_POWER_DOWN) | 154 | dev->dev_state != MEI_DEV_POWER_DOWN) |
154 | dev->dev_state = MEI_DEV_RESETTING; | 155 | dev->dev_state = MEI_DEV_RESETTING; |