From: Radim Krcmar <rkrcmar@redhat.com>
To: Vitaly Kuznetsov <vkuznets@redhat.com>
Cc: devel@linuxdriverproject.org, linux-kernel@vger.kernel.org,
"K. Y. Srinivasan" <kys@microsoft.com>,
Haiyang Zhang <haiyangz@microsoft.com>,
Alex Ng <alexng@microsoft.com>, Cathy Avery <cavery@redhat.com>
Subject: Re: [PATCH] Drivers: hv: vmbus: handle various crash scenarios
Date: Fri, 18 Mar 2016 17:11:50 +0100 [thread overview]
Message-ID: <20160318161150.GB1800@potion.brq.redhat.com> (raw)
In-Reply-To: <87d1qr3hq6.fsf@vitty.brq.redhat.com>
2016-03-18 16:53+0100, Vitaly Kuznetsov:
> Radim Krcmar <rkrcmar@redhat.com> writes:
>> 2016-03-18 13:33+0100, Vitaly Kuznetsov:
>>> @@ -530,9 +542,17 @@ static void vmbus_wait_for_unload(void)
>>
>> (I'm not a huge fan of the unloaded variable; what about remembering the
>> header/msgtype here ...
>>
>>> unloaded = true;
>>>
>>> vmbus_signal_eom(msg);
>>
>> and checking its value here?)
>>
>
> Sure, but we'll have to use a variable for that ... why would it be
> better than 'unloaded'?
It's easier to understand IMO,
x = mem | x = mem
if *x == sth | z = *x
u = true |
eoi() | eoi()
if u | if z == sth
break | break
And you can replace msg with the new variable,
z = *mem
eoi()
if z == sth
break
>> Can't this be NULL?
>
> It can't, we allocate it from hv_synic_alloc() (and we don't support cpu
> onlining/offlining on WS2012R2+).
Reviewed-by: Radim Krčmář <rkrcmar@redhat.com>
Thanks.
>>> + msg = (struct hv_message *)page_addr + VMBUS_MESSAGE_SINT;
>>> + msg->header.message_type = HVMSG_NONE;
>>> }
>>
>> (And, this block belongs to a separate function. ;])
>
> I thought about moving it to hv_crash_handler() but then I decided to
> leave it here as the need for this fixup is rather an artifact of how we
> recieve the message. But I'm flexible here)
Ok, clearing all VCPUs made me think that it would be generally useful.
next prev parent reply other threads:[~2016-03-18 16:11 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-03-18 12:33 Vitaly Kuznetsov
2016-03-18 15:20 ` Radim Krcmar
2016-03-18 15:53 ` Vitaly Kuznetsov
2016-03-18 16:11 ` Radim Krcmar [this message]
2016-03-18 18:02 ` KY Srinivasan
2016-03-21 7:51 ` Vitaly Kuznetsov
2016-03-21 22:44 ` KY Srinivasan
2016-03-22 9:47 ` Vitaly Kuznetsov
2016-03-22 14:00 ` Vitaly Kuznetsov
2016-03-22 14:18 ` KY Srinivasan
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20160318161150.GB1800@potion.brq.redhat.com \
--to=rkrcmar@redhat.com \
--cc=alexng@microsoft.com \
--cc=cavery@redhat.com \
--cc=devel@linuxdriverproject.org \
--cc=haiyangz@microsoft.com \
--cc=kys@microsoft.com \
--cc=linux-kernel@vger.kernel.org \
--cc=vkuznets@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®